Agent Architecture and Orchestration
Multi-agent Orchestration — Patterns
Multi agent orchestration › Patterns
Supervisor with typed worker contracts
Problem. When a coordinator delegates in prose and receives prose, nothing can be checked: the coordinator cannot tell a refusal from a partial answer, and errors propagate as confident sentences.
Approach. Give every worker a declared input and output schema with an explicit failure variant, and have the coordinator dispatch and validate against those schemas rather than reading replies. A worker that cannot comply returns a structured failure the coordinator can branch on instead of a sentence it has to interpret.
Trade-off. Schemas constrain what workers can usefully say and add a translation layer between model output and contract. The coordinator also becomes a bottleneck, since every exchange passes through it — which is exactly why this topology is debuggable.
Shared artefact with explicit claims
Problem. Message-passing between many participants grows quadratically and loses the thread: each participant knows only what it was sent, and the state of the objective exists nowhere as a whole.
Approach. Make the objective a structured artefact that every participant reads. Work items are claimed before being worked, claims are visible and time-bounded, and results are appended with attribution rather than overwriting what is there. Participants poll or subscribe to the artefact instead of each other.
Trade-off. The artefact becomes a contention point and a context-size problem — late in a long effort it may no longer fit in a participant's window, forcing a summarised view whose fidelity you now have to manage.
Producer and critic as separate participants
Problem. An agent asked to check its own output accepts it. Self-assessment in the same context is dominated by the commitment the model has already made to its answer.
Approach. Separate the roles into distinct participants with different instructions and, ideally, different evidence: the critic receives the output and the original requirements, not the producer's reasoning. Make the critic's verdict structured, and bound the number of revision rounds before escalation.
Trade-off. At least double the cost per item, and a critic that is too strict stalls the effort while one that is too lenient adds expense without adding quality. The round limit has to exist or a producer-critic pair will negotiate indefinitely.
One budget, allocated down
Problem. Per-agent limits do not compose. Five participants each permitted twenty iterations is a hundred-iteration effort nobody authorised, and the overrun is only visible after the invoice.
Approach. Give the objective a single allowance covering tokens, wall clock, and tool calls. Participants request an allocation from it before acting and return what they did not use, with the coordinator refusing allocations once the remainder cannot fund a useful unit of work. The remaining budget travels with the effort.
Trade-off. Allocation adds a round trip and a shared counter under contention. Workers also need a defined behaviour when their allocation is refused — usually returning partial results — or the mechanism simply converts overspend into unexplained failure.