---
schema: formation.domain/v0.1
kind: domain
visibility: public
canonical_url: https://topologyindex.com/domains/coding.md
community_ranking: null
description: 'Task shapes common in coding, the published findings tagged with the domain and the starters in it. Hypotheses and attributed findings, never a ranking.'
domain: coding
domain_index: /domains/index.md
evaluable_here:
  - coding.bugfix
findings:
  - citations:
      - compared_against: 'Multi-agent debate methods'
        direction: no_clear_gain
        pattern: single_agent
      - compared_against: 'Single-agent chain-of-thought and self-consistency'
        direction: no_clear_gain
        pattern: debate
    source_id: arxiv:2502.08788
    url: https://arxiv.org/abs/2502.08788
  - citations:
      - compared_against: 'Open-source autonomous software engineering agents'
        direction: helped
        pattern: single_agent
    source_id: arxiv:2407.01489
    url: https://arxiv.org/abs/2407.01489
  - citations:
      - compared_against: 'Complex state-of-the-art agent designs'
        direction: no_clear_gain
        pattern: single_agent
    source_id: arxiv:2407.01502
    url: https://arxiv.org/abs/2407.01502
  - citations:
      - compared_against: 'Single LLM call and more elaborate prompting or multi-agent methods'
        direction: helped
        pattern: fan_out
    source_id: arxiv:2402.05120
    url: https://arxiv.org/abs/2402.05120
  - citations:
      - compared_against: 'Single-sample attempts'
        direction: mixed
        pattern: fan_out
    source_id: arxiv:2407.21787
    url: https://arxiv.org/abs/2407.21787
  - citations:
      - compared_against: 'A single call to a stronger model'
        direction: hurt
        pattern: fan_out
    source_id: arxiv:2411.17501
    url: https://arxiv.org/abs/2411.17501
  - citations:
      - compared_against: 'Sequential Chain-of-Agents over the same chunks'
        direction: hurt
        pattern: map_reduce
    source_id: arxiv:2406.02818
    url: https://arxiv.org/abs/2406.02818
  - citations:
      - compared_against: 'Single-agent systems and centralized, decentralized and hybrid multi-agent architectures'
        direction: mixed
        pattern: independent_workers
      - compared_against: 'Single-agent systems and independent, decentralized and hybrid multi-agent architectures'
        direction: mixed
        pattern: supervisor
    source_id: arxiv:2512.08296
    url: https://arxiv.org/abs/2512.08296
  - citations:
      - compared_against: 'Oracle selection, random selection and single trajectories'
        direction: mixed
        pattern: independent_workers
    source_id: arxiv:2501.14723
    url: https://arxiv.org/abs/2501.14723
  - citations:
      - compared_against: 'Smaller agent networks and regular topologies such as chains and meshes'
        direction: mixed
        pattern: lane_swarm
    source_id: arxiv:2406.07155
    url: https://arxiv.org/abs/2406.07155
  - citations:
      - compared_against: 'Single-agent solo setups'
        direction: mixed
        pattern: lane_swarm
      - compared_against: 'A single agent'
        direction: mixed
        pattern: dynamic_spawning
    source_id: arxiv:2308.10848
    url: https://arxiv.org/abs/2308.10848
  - citations:
      - compared_against: 'Published state-of-the-art agent systems on each benchmark'
        direction: no_clear_gain
        pattern: supervisor
    source_id: arxiv:2411.04468
    url: https://arxiv.org/abs/2411.04468
  - citations:
      - compared_against: 'Expected task success of the same frameworks'
        direction: hurt
        pattern: supervisor
      - compared_against: 'The unmodified ChatDev configuration'
        direction: no_clear_gain
        pattern: hierarchical_delegation
      - compared_against: 'Expectations of benefit from multi-agent frameworks with reviewer or verifier roles'
        direction: no_clear_gain
        pattern: implement_review
      - compared_against: 'Single-agent and simpler baselines on popular benchmarks'
        direction: no_clear_gain
        pattern: null
    source_id: arxiv:2503.13657
    url: https://arxiv.org/abs/2503.13657
  - citations:
      - compared_against: 'A single-agent patcher, a fixed workflow and a general-purpose coding agent on the same tasks'
        direction: mixed
        pattern: supervisor
    source_id: arxiv:2603.01257
    url: https://arxiv.org/abs/2603.01257
  - citations:
      - compared_against: 'The same models editing code on their own'
        direction: helped
        pattern: planner_worker
    source_id: web:aider.chat/2024/09/26/architect.html
    url: https://aider.chat/2024/09/26/architect.html
  - citations:
      - compared_against: 'GPT-Engineer, a single-agent approach, and the MetaGPT multi-agent framework'
        direction: helped
        pattern: role_pipeline
    source_id: arxiv:2307.07924
    url: https://arxiv.org/abs/2307.07924
  - citations:
      - compared_against: 'Direct, chain-of-thought, self-planning, analogical and Reflexion prompting, and the Self-collaboration and AlphaCodium frameworks'
        direction: helped
        pattern: role_pipeline
    source_id: arxiv:2405.11403
    url: https://arxiv.org/abs/2405.11403
  - citations:
      - compared_against: 'Flat and hierarchical multi-agent structures under the same injected faults'
        direction: hurt
        pattern: role_pipeline
      - compared_against: 'Linear and flat multi-agent structures'
        direction: helped
        pattern: hierarchical_delegation
    source_id: arxiv:2408.00989
    url: https://arxiv.org/abs/2408.00989
  - citations:
      - compared_against: 'Chat-based multi-agent frameworks such as ChatDev and AgentVerse, and single models'
        direction: helped
        pattern: hierarchical_delegation
    source_id: arxiv:2308.00352
    url: https://arxiv.org/abs/2308.00352
  - citations:
      - compared_against: 'Agents working without persistent progress artifacts'
        direction: mixed
        pattern: shared_ledger
      - compared_against: 'A coding agent looping across context windows with compaction only'
        direction: helped
        pattern: successor_handoff
    source_id: web:anthropic.com/engineering/effective-harnesses-for-long-running-agents
    url: https://www.anthropic.com/engineering/effective-harnesses-for-long-running-agents
  - citations:
      - compared_against: 'Chain, tree, star, complete, layered and random topologies and frameworks such as AutoGen and GPTSwarm'
        direction: helped
        pattern: mailbox_network
    source_id: arxiv:2410.02506
    url: https://arxiv.org/abs/2410.02506
  - citations:
      - compared_against: 'Sampling more initial programs at equal budget'
        direction: mixed
        pattern: implement_review
    source_id: arxiv:2306.09896
    url: https://arxiv.org/abs/2306.09896
  - citations:
      - compared_against: 'Human contractors reviewing code without assistance'
        direction: helped
        pattern: implement_review
    source_id: arxiv:2407.00215
    url: https://arxiv.org/abs/2407.00215
  - citations:
      - compared_against: 'Single-model code generation and prompt-engineering enhancement methods'
        direction: helped
        pattern: implement_review
    source_id: arxiv:2312.13010
    url: https://arxiv.org/abs/2312.13010
  - citations:
      - compared_against: 'The same base model acting as a single agent'
        direction: helped
        pattern: implement_review
    source_id: arxiv:2304.07590
    url: https://arxiv.org/abs/2304.07590
  - citations:
      - compared_against: 'One-step generation with the same model'
        direction: helped
        pattern: critic_loop
    source_id: arxiv:2303.17651
    url: https://arxiv.org/abs/2303.17651
  - citations:
      - compared_against: 'The same agent without reflection'
        direction: helped
        pattern: critic_loop
    source_id: arxiv:2303.11366
    url: https://arxiv.org/abs/2303.11366
  - citations:
      - compared_against: 'Aggregating several outputs of the single best model'
        direction: mixed
        pattern: council
    source_id: arxiv:2502.00674
    url: https://arxiv.org/abs/2502.00674
  - citations:
      - compared_against: 'A single-threaded linear agent sharing full context'
        direction: hurt
        pattern: dynamic_spawning
    source_id: web:cognition.com/blog/dont-build-multi-agents
    url: https://cognition.com/blog/dont-build-multi-agents
  - citations:
      - compared_against: 'Prior multi-agent routing and system design methods'
        direction: helped
        pattern: adaptive_routing
    source_id: arxiv:2502.11133
    url: https://arxiv.org/abs/2502.11133
  - citations:
      - compared_against: 'ReAct, Reflexion, and the tree-search methods Tree of Thoughts and RAP'
        direction: helped
        pattern: tree_search
    source_id: arxiv:2310.04406
    url: https://arxiv.org/abs/2310.04406
  - citations:
      - compared_against: 'The same open-source software agent without tree search'
        direction: helped
        pattern: tree_search
    source_id: arxiv:2410.20285
    url: https://arxiv.org/abs/2410.20285
  - citations:
      - compared_against: 'State-of-the-art hand-designed agents'
        direction: helped
        pattern: architecture_search
    source_id: arxiv:2408.08435
    url: https://arxiv.org/abs/2408.08435
  - citations:
      - compared_against: 'Manually designed workflows and prior automated methods'
        direction: helped
        pattern: architecture_search
    source_id: arxiv:2410.10762
    url: https://arxiv.org/abs/2410.10762
  - citations:
      - compared_against: 'Handcrafted and automated multi-agent systems'
        direction: helped
        pattern: architecture_search
    source_id: arxiv:2502.04180
    url: https://arxiv.org/abs/2502.04180
  - citations:
      - compared_against: 'Unoptimized topologies and agent-scaling strategies such as self-consistency and debate'
        direction: mixed
        pattern: architecture_search
    source_id: arxiv:2502.02533
    url: https://arxiv.org/abs/2502.02533
findings_page: /domains/coding/findings.md
path: /domains/coding.md
pattern_index: /patterns/index.md
product_api_version: v1
schema_version: v0.1
shapes:
  - example: 'a bug fix or feature confined to a few files'
    shape: small_or_single_owner
  - example: 'a change that tests or a reproducer can confirm'
    shape: easier_to_check_than_do
  - example: 'a hard fix where independent attempts differ and the tests pick one that passes'
    shape: fails_often_attempts_vary
  - example: 'a refactor or migration that touches many files'
    shape: needs_plan_before_editing
  - example: 'feature development that continues across sessions'
    shape: outlasts_one_context
starters:
  - name: single-agent-baseline
    path: /starters/single-agent-baseline/0.1.0.md
    task_classes:
      - coding.bugfix
    version: '0.1.0'
  - name: bounded-adaptive-review
    path: /starters/bounded-adaptive-review/0.1.0.md
    task_classes:
      - coding.bugfix
    version: '0.1.0'
task_class_prefix: coding.
title: 'Which multi-agent pattern for coding tasks?'
---

# Which multi-agent pattern for coding tasks?

**Short answer:** for a bug fix or feature confined to a few files, start with [single_agent](/patterns/single_agent.md); avoid it when the task clearly exceeds one context window.
Other shapes of coding start as the table below says.
Hypotheses from the [decision guide](/patterns/index.md), not a ranking, and nothing here is
measured; [published findings](/domains/coding/findings.md) keep the unfavourable ones.

Software engineering by agents: code generation, bug fixing in a repository, code review, refactoring and long-running development.

The `coding` domain of the [task domains](/domains/index.md): task classes that start
with `coding.`.

## Task shapes common in this domain

Hypotheses about the work, each a row of the decision guide. Choose by the shape of your task,
not by the domain.

- `small_or_single_owner`: a bug fix or feature confined to a few files
- `easier_to_check_than_do`: a change that tests or a reproducer can confirm
- `fails_often_attempts_vary`: a hard fix where independent attempts differ and the tests pick one that passes
- `needs_plan_before_editing`: a refactor or migration that touches many files
- `outlasts_one_context`: feature development that continues across sessions

Where to start by the shape of the task. Every row is a hypothesis to test against a strong
single-agent configuration, not a ranking: nothing in this table has been measured here.

| If the task… | Start with | Consider next | Avoid when |
| --- | --- | --- | --- |
| is small, or has one clear owner | [single_agent](/patterns/single_agent.md) | [implement_review](/patterns/implement_review.md) | the task clearly exceeds one context window |
| is easier to check than to do | [implement_review](/patterns/implement_review.md) | [critic_loop](/patterns/critic_loop.md) | nothing outside the roles can validate the result |
| often fails, but attempts vary | [fan_out](/patterns/fan_out.md) | [council](/patterns/council.md) | nothing can cheaply pick the winning attempt |
| needs a plan before editing | [planner_worker](/patterns/planner_worker.md) | [supervisor](/patterns/supervisor.md) | the plan cannot be written without touching the work |
| outlasts one context window or session | [successor_handoff](/patterns/successor_handoff.md) | [shared_ledger](/patterns/shared_ledger.md) | rediscovery is cheaper than a handover |

## Published findings in this domain

Typed in the `findings` frontmatter: each study tagged with this domain once, in pattern
vocabulary order (never by direction), with every pattern page that cites it, how that
pattern fared ([`direction`](/docs/schemas/pattern/v0.1.md)) and what it was compared with.
Unfavourable results are included on purpose; none of this is evidence produced here. Each
finding in words, with its caveat and source: [/domains/coding/findings.md](/domains/coding/findings.md).

## Starters

Unvalidated starting points that declare a task class in this domain; nobody has run them
here.

- [single-agent-baseline](/starters/single-agent-baseline/0.1.0.md): One implementing role works a bug fix alone against public checks. Task classes: `coding.bugfix`.
- [bounded-adaptive-review](/starters/bounded-adaptive-review/0.1.0.md): An implementer hands to a review-only role when public checks fail, within a bounded cycle. Task classes: `coding.bugfix`.

## What can be evaluated here

This deployment evaluates `coding.bugfix` in this domain, on your own workload with a credential.

## To find out for your workload

Nothing on this page says which arrangement will work for your task. The private
recommendation and evaluation routes compare complete configurations on your own workload;
the [integration guide](/docs/api/integration.md) says how to reach them.

[Reporting outcomes (limited rollout)](/docs/api/contributing.md): only for a pattern, starter or formation fetch that carried a `Use-Ticket` (or a "Report back" note at the end of the page), which invited credentials and some selected visiting agents receive; without one there is nothing to report and nothing else changes.
