# Multi-Agent Orchestration
Build an AI Agent Team in 30 Days

- Price: $12.99 (Kindle ebook)
- Level: Advanced
- Pages: 253
- Best for: Anyone whose five-agent split ends with one stalled, one looping, and $50 gone
- You finish with: A lead assigning bounded work to cheap workers, a fan-out past one context window, a bad-handoff gate, and a spend cap that kills a runaway run
- Series: The Overnight AI Team, book 2 of 3
- Buy on Amazon: https://amzn.to/4wYHGuw
- Web page: https://youcanbuildthings.com/books/multi-agent-orchestration

## What you get

You split the job across five agents. One stalls. One loops. One burns $50. In 30 days you turn a single babysat agent into a team: a lead that assigns bounded work to cheaper models, a fan-out that takes on jobs one context window cannot hold, a gate that blocks bad handoffs, and a spend cap that kills a runaway run before it costs $500.

The five patterns are teaching vocabulary, not a standard. There is no committee and no canonical list: six published taxonomies contradict each other, and one contradicts itself across two pages of the same site. What is real underneath the naming noise is a small number of distinct data-flow shapes that keep reappearing.

Every layer ships with a companion GitHub repo: the finished pipeline under the book's own names, organized chapter by chapter, with the drills wired up.

## Chapters

1. The Margin Moved to Orchestration: Why the model you pay most for should decide things, not type them, and what that split is worth.
2. What a Harness Actually Is (and When You Need One): Build a two-file orchestrator-and-worker pipeline you extend in every remaining chapter.
3. The Five Production Patterns: Pipeline, supervisor, fan-out, debate, and evaluator, each with a runnable skeleton and a routing test.
4. Orchestrator and Workers, Your First Real Pipeline: Run three parallel workers on the cheap tier under a lead-tier planner, with token totals reported.
5. Fan-Out, Do the Work One Context Can't Hold: Dispatch workers in parallel and watch the context budget stay flat instead of filling up.
6. Shared State and Handoffs: Typed envelopes, atomic writes that survive a kill, and a claim registry that queues colliding workers.
7. The Reliability Machinery, Stop the Silent Failure: A gate that blocks on exit 2 and deadlines that propagate so a child never outlives its parent.
8. Observability, Know It Broke Before a Human Checks: NDJSON spans and a locator that names the earliest failing stage in under a minute.
9. Cost Control, Never Burn $500 at Hour 3 Again: A cost model that refuses placeholder rates and a hard spend cap wired into the run.
10. Ship the System That Does Paid Work: A parameterized pipeline driven by a job file, with validation, a worker ceiling, and a budget ceiling.
11. When It All Goes Wrong (and How to Recover): A runbook indexed by symptom, plus quarantine and resumable checkpoints at stage boundaries.
12. Your First Production System in 30 Days: A dated 30-day plan on your own project and a scaffold generated for the pattern you picked.
