AgenticMCPFine-TuningModels

AI Agents: The Definitive Guide

by O'Reilly Media (Nicole Koenigstein)

AdvancedBookPaid378 pages, 12 chapters plus Colab notebooks; roughly 30-40 hours self-paced (estimate)

A production handbook for LLM agents: architectures, RL and test-time search, MCP, sandboxing, deployment, evaluation, memory, cost and threat modeling, with a Colab notebook per chapter.

Start LearningAdded Oct 14, 2026 · Updated Oct 14, 2026

Overview

AI Agents: The Definitive Guide: Design, Deployment, and Evaluation for Production, by Nicole Koenigstein, is a 378-page O'Reilly book whose ebook edition was released on August 26, 2026. It takes on the problems teams hit when agents leave the research notebook: fragile tools, rising inference cost and erratic behavior. The twelve chapters move from foundations to operations. Chapter 1 frames agents as finite and hierarchical state machines and maps that model onto agent frameworks. Chapter 2 covers chain-of-thought, tree-of-thought, ReAct with reflection, human-in-the-loop, supervisor hierarchies and swarms. Chapter 3 goes into training and search: GRPO and GSPO, the ART approach to learning from experience, test-time compute and adaptive-branching Monte Carlo tree search. Chapter 4 covers the models themselves (decoder-only, encoder-only, mixture-of-experts, reasoning models with thinking budgets, LoRA and quantization). Chapters 5 to 7 handle production: Pydantic and Instructor contracts, building and connecting MCP servers, LangChain Deep Agents, Docker and cloud sandboxes, programmatic tool calling, monitoring, fallbacks and inference backends. Chapters 8 and 9 cover evaluation, from behavioral stress tests and threat testing to custom benchmarks built from production traces. The last three chapters cover memory topologies, compute and cost modeling (memory footprint, FlashAttention, the agentic cost multiplier) and threat modeling with red teaming. The companion GitHub repo has 2.7k stars and organizes Colab notebooks by chapter.

At a Glance

Topic
Agentic
Level
Advanced
Format
Book
Cost
Paid
Duration
378 pages, 12 chapters plus Colab notebooks; roughly 30-40 hours self-paced (estimate)
Provider
O'Reilly Media (Nicole Koenigstein)
Hands-on
Yes — code/exercises
Certificate
None

What You’ll Learn

  • ✓Model agent behavior as finite and hierarchical state machines, and map that design onto frameworks
  • ✓Build chain-of-thought, tree-of-thought, ReAct, human-in-the-loop, supervisor and swarm agent patterns
  • ✓Understand how GRPO, GSPO and the ART approach train agents from relative rewards and experience
  • ✓Apply test-time compute and adaptive-branching Monte Carlo tree search to agent planning problems
  • ✓Enforce data contracts between agents with Pydantic and Instructor to cut failures and wasted tokens
  • ✓Build an MCP server, connect it to LangGraph, and let agents discover MCP servers dynamically
  • ✓Isolate agent execution with Docker and cloud sandboxes and govern programmatic tool calling safely
  • ✓Turn production traces and your own repository into custom benchmarks for evaluating agents
  • ✓Design episodic, semantic and procedural memory and choose a memory topology for multi-agent systems
  • ✓Estimate memory footprint and the agentic cost multiplier, and threat-model agents with layered defenses

Highlights

  • •Covers the training side (GRPO, GSPO, ART, AB-MCTS) next to production engineering, which most agent books leave out
  • •Whole chapters on cost modeling and threat modeling, including notebooks on the OWASP agentic top 10 for 2026 and LlamaFirewall
  • •Companion repo with 2.7k GitHub stars and an Open in Colab notebook for each of the 12 chapters
  • •Uses the 2026 agent stack directly: MCP, A2A, Deep Agents, E2B sandboxes, Langfuse and LangSmith evaluation pipelines
  • •Says it gives framework-independent, system-level guidance, while still showing code in LangGraph and Pydantic

Who It’s For

Best For

  • ✓AI engineers responsible for running agents in production who need evaluation, fallbacks and monitoring
  • ✓Platform and security engineers setting up sandboxing, tool governance and threat models for agents
  • ✓Tech leads estimating the inference cost and infrastructure needs of a multi-agent system
  • ✓ML engineers who want the RL post-training and test-time search side of agents along with the application side

Prerequisites

  • •Solid Python and comfort running Jupyter or Colab notebooks
  • •Prior experience building LLM applications with tool calling; this is not a first agents book
  • •Familiarity with transformer basics helps for the chapters on models, RL post-training and FlashAttention
  • •Accounts or API keys for some notebooks that use external services such as LangSmith, Langfuse, E2B or Composio

FAQ

What is AI Agents: The Definitive Guide?

AI Agents: The Definitive Guide (subtitled Design, Deployment, and Evaluation for Production) is a 2026 O'Reilly book by Nicole Koenigstein for engineers moving agents from prototype to production. It covers agent architecture, post-training and search, tool governance, deployment, evaluation, memory, cost and security, with runnable notebooks for each chapter.

Is AI Agents: The Definitive Guide free?

AI Agents: The Definitive Guide is a paid resource.

What level is AI Agents: The Definitive Guide for?

AI Agents: The Definitive Guide is aimed at a advanced audience. Recommended background: Solid Python and comfort running Jupyter or Colab notebooks, Prior experience building LLM applications with tool calling; this is not a first agents book, Familiarity with transformer basics helps for the chapters on models, RL post-training and FlashAttention, Accounts or API keys for some notebooks that use external services such as LangSmith, Langfuse, E2B or Composio.

How long does AI Agents: The Definitive Guide take?

Expect roughly 378 pages, 12 chapters plus Colab notebooks; roughly 30-40 hours self-paced (estimate). Most learners work through it at their own pace.

What will I learn from AI Agents: The Definitive Guide?

You'll learn: Model agent behavior as finite and hierarchical state machines, and map that design onto frameworks; Build chain-of-thought, tree-of-thought, ReAct, human-in-the-loop, supervisor and swarm agent patterns; Understand how GRPO, GSPO and the ART approach train agents from relative rewards and experience; Apply test-time compute and adaptive-branching Monte Carlo tree search to agent planning problems; Enforce data contracts between agents with Pydantic and Instructor to cut failures and wasted tokens; Build an MCP server, connect it to LangGraph, and let agents discover MCP servers dynamically; Isolate agent execution with Docker and cloud sandboxes and govern programmatic tool calling safely; Turn production traces and your own repository into custom benchmarks for evaluating agents; Design episodic, semantic and procedural memory and choose a memory topology for multi-agent systems; Estimate memory footprint and the agentic cost multiplier, and threat-model agents with layered defenses.

Topics

ai agentsproduction agentsagent evaluationmcpagent securityo'reilly

Sources

This page was written from 3 sources, 2 on domains other than ai-agents-the-definitive-guide.com.

  1. 1.ai-agents-the-definitive-guide.com — ai-agents-the-definitive-guide.comvendor
  2. 2.github.com — ai agents the definitive guide
  3. 3.helion.pl — ai agents the definitive guide design deployment and evaluat