The Orchestrator
Defining workflow sequence, error handling, and result compilation. The manager that doesn't do work.
The orchestrator is the linchpin of your multi-agent system, and its core principle is deceptively simple: it delegates, it does not do work. The moment your orchestrator starts writing content, running analysis, or executing tasks itself, your multi-agent system collapses back into a single-agent system with extra files.
A well-written orchestrator defines three things: the workflow sequence (which subagent does what, in what order), the error handling (what happens when a subagent fails or returns bad output), and the compilation rules (how to combine subagent results into a final deliverable).
Workflow sequence is straightforward. "Step 1: Send the topic to the researcher. Step 2: Review the research output for completeness. Step 3: Send the research to the writer along with the content brief. Step 4: Review the draft for accuracy against the research. Step 5: Compile the final version." Each step names a subagent and specifies what input it receives.
Error handling is where most orchestrators fall short. What happens when the researcher returns "INSUFFICIENT DATA"? What if the writer produces content that contradicts the research? The orchestrator needs rules for these scenarios. The best pattern is: "If a subagent returns an error state, flag it for manual review with context about what failed and why. Do not attempt to fix the subagent's work yourself."
Result compilation is the final step. The orchestrator takes output from all subagents and assembles the deliverable. This might mean combining research and writing into a final document, or aggregating data from multiple analysis subagents into a report. The orchestrator decides the structure but uses the subagents' work as-is. It's an editor, not a rewriter.
A good test for your orchestrator: if you removed the orchestrator and manually sent the same inputs to each subagent in the same order, would you get the same result? If yes, your orchestrator is doing its job โ coordinating, not creating.
Walkthrough
- 1Open your orchestrator.md file
- 2Define the workflow sequence: number each step, name the subagent, specify the input
- 3Add error handling rules: what happens when a subagent returns incomplete or bad results?
- 4Use the 'needs manual review' pattern: flag problems for you instead of auto-fixing them
- 5Define compilation rules: how do subagent outputs combine into the final deliverable?
- 6Add a quality check step: the orchestrator reviews the final compilation before presenting it
- 7Run the workflow end-to-end with a real task and observe the orchestrator's delegation behavior
- 8Verify the orchestrator is NOT doing work itself โ only delegating and compiling
Checkpoint
Your orchestrator has a defined workflow sequence, error handling rules, and compilation instructions. It successfully delegates to subagents and compiles their output without doing the work itself.