A free ebook, as a PDF and an EPUB
Production AI agents: architecture and operations
Run the agent on events, give it typed tools and tiered memory, score it on five dimensions, and ship it behind flags, a sandbox, a kill switch and budgets.
The ebook is open in a new tab
If it did not open, open the PDF. For a reading app, download the EPUB. Both links work for a day; the form gives you new ones any time.
Build it live, with an engineer reviewing your choices
Deploy AI Agents to Production. A multi-agent system deployed with an identity per agent, permissions, guardrails, an LLM gateway, traces and evals, plus a checklist for your own agents.
Look insidePages from the PDF, as they print.

Page 3: A demo agent dies the first time a task outlives its request. 
Page 4: Events let a slow tool, a timer and a new message share one loop. 
Page 8: Return errors as data, so the agent can read them and try again. 
Page 11: Put each fact in the tier that matches how long it must live. 
Page 17: One run scored on all five shows what a pass rate hides. 
Page 19: Every tool call passes one gate: kill switch, tool flag, then action tier.
What the ebook covers
- 1
Run the agent on events, not one request
A demo agent lives inside one request. A production agent outlives it: slow tools, timers and new messages arrive as events on one queue, and each handler does its part.
- 2
Write tools as typed contracts
A tool is a public API the model calls. Typed input, typed output, errors returned as data, and every output shaped so the next tool can use it.
- 3
Keep memory in tiers by how long it lives
The message history is only the shortest tier. The plan lives for the run, project facts for weeks, and an archive keeps the best diverse attempts across runs.
- 4
Score agents on five dimensions, not one
Task success alone hides unsafe, slow and wasteful runs. A golden task states its pass conditions in code, and every run records success, safety, cost, latency and convergence.
- 5
Ship behind flags, a sandbox and a kill switch
Agents take actions, so every tool call passes a gate: the kill switch, a flag per tool and a tier that decides when a human approves. Tools run in a sandbox scoped to the project.
- 6
Enforce budgets in code on multi-day runs
A run that goes for days without a cap spends without limit. Cap each turn, each task and each day in code, and decide up front what happens when a cap is hit.
- 7
The page to keep and the questions people ask
Every layer of a production agent on one page, then short answers to what engineers search about running AI agents in production.