Orchestrator-Worker Patterns for Coordinating Specialist Agents
Orchestrator-worker is the multi-agent topology where a central controller owns the user goal and dispatches bounded work to specialist workers.
Workers run their own loops with narrower tools; they return structured results; the orchestrator merges, retries, re-routes, or escalates.
This page is a practical recipe for that pattern inside one product runtime (in-process or service mesh with a single control plane).
Implement an orchestrator that classifies the next subgoal, builds a handoff packet, runs a worker under a local budget, validates the return contract, then merges into shared task state until a global stop condition fires.
Own the user goal, choose the next worker, enforce global budgets and policy, and merge or escalate structured results.
Should the orchestrator call tools?
Prefer few or none. If it needs tools, keep them read-only routing aids. Side-effect tools belong on least-privilege workers with explicit gates.
How do I pick between sequential pipeline and dynamic routing?
Use a pipeline when stages are stable and always required. Use dynamic routing when only one of several specialists should run per request.
How should fan-out merges work?
Define a merge function: concatenate sources with dedupe keys, vote on classifications, or pick highest-confidence artifact. Never "last writer wins" by accident.
What if two workers need the same artifact?
Store it in shared task state under a stable key and pass references in packets. Do not attach full copies to every handoff if size will explode.
How many workers should I start with?
Two is enough to learn the pattern (orchestrator + one specialist). Add a third only when a new tool/policy boundary is real.
How do humans fit the pattern?
Model human approval as a blocking worker with a return contract (approved, edited, rejected). The orchestrator continues only after a valid return.
Can workers call the orchestrator back?
Prefer workers only returning results. Callbacks create hidden cycles. If you need peer calls, read the peer-to-peer page and add cycle guards.
What metrics prove the pattern works?
Route accuracy, return-schema validity rate, handoff depth, budget-hit rate, time-to-escalation, and final task success - not only user thumbs-up.
Is a non-LLM router still "multi-agent"?
Yes. Multi-agent is about multiple agent loops and control transfer. The router can be deterministic code.