Command Palette

Search for a command to run...

All patterns
Agents

Multi-Agent System

A system of specialised agents coordinated by an orchestrator or graph to solve complex tasks via division of labour.

clientservicemodeldatabaseagentexternal
Explanation

An orchestrator decomposes the task and delegates sub-tasks to specialised agents. Each agent has its own tools, prompts and memory. Results are synthesised by the orchestrator or a dedicated writer agent.

Components
Orchestrator / routerSpecialised sub-agentsShared state / blackboardAgent communication protocolAggregation step
When to use
  • Complex research and synthesis tasks
  • Tasks with clear sub-domains (research + analysis + writing)
  • When parallelism gives a latency win
When NOT to use
  • Simple tasks — a single agent is fine
  • When coordination overhead exceeds the benefit
Failure modes
  • Orchestrator mis-routes to wrong agent
  • Agents disagree or contradict
  • State synchronisation bugs
  • One slow agent blocks the whole graph
  • Context lost between agents
Production checklist
  • Clear agent contracts (input/output schemas)
  • Orchestrator routing evaluation
  • Timeouts per agent
  • Shared state versioning
  • End-to-end trace spanning all agents
  • Fallback if an agent fails