Multi-agent system
Why it matters
Roles help when a task is long, has distinct stages or needs a second opinion. A separate reviewer catches mistakes the writer cannot see in its own work, and independent parts, such as researching five competitors, can run at the same time.
The cost is real. More agents use more tokens, take more coordination and add more places for a handoff to lose information. Errors can also pass from agent to agent, each treating the last one's output as fact. Many tasks are done better by one well-instructed agent with good tools.
How to apply it
- Begin with one agent. Add another only when a specific step is failing or too slow.
- Give each agent one clear role and only the tools it needs.
- Define exactly what passes between agents, in a fixed format, so nothing is dropped.
- Make the checker a separate agent from the maker.
- Cap the number of rounds, so two agents cannot loop on each other forever.
- Keep a person approving anything that sends, spends or deletes. See human-in-the-loop.
What it is
A single AI agent has one set of instructions and one working memory. A multi-agent system divides a job among several. One agent might research, a second write, a third check the result. Often an orchestrator agent sits on top, splits the task, sends the parts out and combines what comes back. Other designs are a simple pipeline, where each agent hands work to the next, or a review pair, where one agent produces and another criticises.
Each agent has its own context window, which is how much text it can keep in view. Splitting the work keeps each one focused and stops a long task filling a single window with clutter.
Common mistakes
- Starting with many agents. Begin with one and add another only when a step demonstrably fails.
- Letting agents talk freely. Define what passes between them in a fixed format, or details get lost.
- Using the same agent to make and check. A checker that shares the maker's context repeats its blind spots.
- Setting no limit on rounds. Two agents can loop for hours. Cap the number of exchanges.
- Trusting handed-over output as fact. Each agent should check what it receives, not assume it.
- Forgetting the cost. More agents mean more tokens and more places to fail. Measure whether quality actually improves.