# AI Agent Orchestration AI agent orchestration is the coordination of multiple [[AI Agents]] working together on a task. Rather than a single agent handling everything, orchestration splits work across specialized agents, each with its own context, tools, and instructions, then combines their outputs. The [[Receptionist AI Design Pattern]] is a common orchestration pattern: a routing agent receives user input and delegates to specialized agents. [[Claude Code]] uses a simpler form with subagents: the main agent spawns child agents for parallel tasks (research, testing, exploration), each inheriting a subset of context. Orchestration makes [[Separation of Concerns]] concrete in AI systems. Each agent operates within its own [[Context Window]] with its own [[Token Budget]], loaded via [[Prompt Lazy Loading AI Design Pattern (PLL)]]. This avoids [[Context Bloat]] from cramming every capability into a single prompt, and allows different agents to use different models optimized for their specific task. The challenges are coordination overhead, context sharing between agents (what does agent B need to know about agent A's output?), and error handling across agent boundaries. These are analogous to microservice orchestration challenges in distributed systems. ## Orchestration Patterns **Predefined teams**: Agents are configured in advance with a shared goal, execution mode (parallel or pipeline), and handoff protocol. Good for recurring workflows. **Panels**: Multiple agents evaluate the same content independently, producing a combined scorecard. Good for quality gates and multi-angle review. **Emergent chaining**: Agents discover work for other agents during execution and suggest handoffs via a standardized protocol. The orchestrator validates (no loops, depth limits) and chains automatically. Good for organic collaboration where the full workflow isn't known upfront. Requires safety rules: max chain depth, no duplicate agents, no circular patterns. **State persistence**: Agents that run multi-step flows across sessions can persist in-progress state (current phase, collected data, next steps) in a lightweight state file, enabling resumption without re-asking questions or losing progress. ## References - ## Related - [[AI Agents]] - [[Receptionist AI Design Pattern]] - [[AI Agent Harness]] - [[AI Agent Skills]] - [[Claude Code]] - [[Separation of Concerns]] - [[Context Engineering]] - [[Token Budget]] - [[Prompt Lazy Loading AI Design Pattern (PLL)]] - [[Context Bloat]] - [[Composition over Inheritance]] - [[Loose Coupling]]