Multi-agent systems and agent-to-agent protocols
When splitting work across agents helps and when it multiplies errors; supervisor, handoff, pipeline and parallel fan-out patterns; isolating context with sub-agents; how MCP and agent-to-agent protocols such as A2A differ; and how to budget, trace and evaluate a team of agents.
By Sandip Maity, Applied AI Engineer
"Use several agents" is one of the most popular ideas in LLM engineering and one of the most over-used. Splitting work across agents can isolate context, parallelise research and keep each agent's tool list short. It also multiplies model calls, latency, cost and failure points. This lesson covers the patterns that work, the arithmetic that says when they pay off, and how agents talk to each other across systems.
#The arithmetic of chains
If each step succeeds with probability p independently, a chain of n steps succeeds with about pⁿ:
| Per-step success | 2 agents | 4 agents | 8 agents |
|---|---|---|---|
| 95% | 90% | 81% | 66% |
| 90% | 81% | 66% | 43% |
| 80% | 64% | 41% | 17% |
Real failures are not fully independent, and later agents can sometimes catch earlier mistakes, but the direction is right: every hand-off must earn its place. Measure the multi-agent design against one well-built agent on the same golden set.
#Patterns that work
- 1Supervisorone agent plans and delegates to workers, then combines results
- 2Handoffa triage agent passes the conversation to a specialist
- 3Pipelinefixed stages: extract, check, write
- 4Fan-outseveral agents explore in parallel; one merges
- Supervisor and workers. The supervisor keeps the plan; each worker has a narrow tool set and returns a short report. Good for research and multi-source tasks.
- Handoff. A triage agent routes billing questions to the billing agent, which holds only billing tools. Each agent's context and tools stay small. This is the design behind several frameworks (frameworks compared).
- Pipeline. Not really "agents", and often the best answer: fixed stages, each a model call with its own prompt and check. Easy to test.
- Parallel fan-out. Search five sources at once, then merge. Faster wall-clock time, higher total cost.
- Critic or verifier. One agent produces, another checks against explicit criteria. Works best when the check is concrete (tests pass, every claim has a citation) rather than "is this good?".
Pro content
Keep reading with Inference Academy Pro
Unlock the rest of this lesson, plus every advanced lesson, hands-on lab, the larger playground models and completion certificates.
Still to come in this lesson
- Sub-agents for context isolation
- Agent-to-tool versus agent-to-agent
- Budgets, tracing and evaluation
- Common mistakes
- Exercises
You will be able to answer
- Each agent in a four-step chain succeeds 90% of the time, independently. Roughly how often does the whole chain succeed?
- What is the strongest reason to use a sub-agent?
- How do MCP and agent-to-agent protocols such as A2A differ?
- Parallel fan-out (several agents research at once) mainly improves...
- What should a multi-agent trace record?