Some decisions belong to the model. Others belong to your code. A production agent is a loop: a language model decides what to do, calls tools, and carries on. Most of the engineering lies in deciding which decisions the model makes and which ones your code enforces. This book gives those decisions names. It sets out twenty-one patterns. Nine get a chapter each, written as context, problem, forces, solution, tradeoffs and resulting context: Agentic LoopDeterministic OverrideTool GateValidation-Retry LoopStructured Error ClassificationConfidence-Based RoutingReview PassCoordinator-Subagent HierarchyTrust Boundaries Twelve smaller techniques are collected in an appendix. Each pattern chapter includes runnable Python code, and the book explains which parts to unit-test and which to evaluate. One appendix lists what each pattern needs from a platform, with a prompt for porting the code to the one you use. Another surveys the agent harnesses available in October 2026. For engineers who build agents and want shared names for the decisions involved.
ThriftBooks sells millions of used books at the lowest everyday prices. We personally assess every book's quality and offer rare, out-of-print treasures. We deliver the joy of reading in recyclable packaging with free standard shipping on US orders over $15. ThriftBooks.com. Read more. Spend less.