A multi-agent system uses several model-driven components with different jobs, for example a planner, a researcher and a writer.
Common patterns
- Supervisor and workers: one agent splits the task and hands pieces to specialists, then combines the results.
- Handoffs: an agent passes the conversation to another that is better suited.
- Parallel agents: independent sub-tasks run at the same time to save time.
- Reviewer: a second agent checks the first one's work.
More agents mean more cost, more latency and more ways to fail, so add them only when one agent clearly cannot do the job.
Reliability tools
- Checkpointing saves state so a long task can resume after a failure.
- Retries and recovery handle tool and network errors.
- Guardrails and permission boundaries limit what each agent may do.
- Tracing records every step, tool call and token count so you can debug.
- Evaluation replays test tasks and checks the whole trajectory, not only the final answer.
Frameworks and SDKs
- Claude Agent SDK and Anthropic tool-use patterns for building agents on Claude.
- LangChain and LangGraph: general toolkits, with LangGraph modelling agents as graphs of steps.
- LlamaIndex: strong for data and retrieval.
- A plain code loop with no framework is often the clearest choice.
How to choose
- Build the simplest working version in plain code.
- Note the real pain points (state, retries, tracing).
- Adopt a framework only where it removes that pain.
- Check its maintenance status and licence first.