Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Where to go next

You started this book by writing a while loop that called a model and ran a function.

What you have built

Take stock, because it is more than it feels like from inside.

A ReAct agent from scratch — think, act, observe — with correct tool_use/tool_result pairing, a tool registry that is the single source of truth for both schemas and implementations, error handling that turns every failure into an observation, and a step cap enforced outside the model’s reasoning.

A tool framework and an MCP client harness, plus servers on both sides of the protocol: you have written the thing that generates schemas from signatures, and you know exactly what a decorator is doing for you when it does it.

A memory system — working, episodic, and semantic — with generation, retrieval, and the honest accounting of when retrieval is worse than a bigger window.

A workflow engine with typed state, declared reducers, conditional routing, runtime fan-out, per-step error policy, and budgets on supersteps, node runs, and wall clock. Then a multi-agent system on top of it, with handoffs and a supervisor.

An eval harness that turns anecdote into a number, with judges you have calibrated, and a tracer that shows you the inside of a run instead of its output.

A deployable service: container, config, health endpoints, secrets from files, a smoke test that proves the running thing is the built thing, plus a CI pipeline with a statistical gate and an authorization layer that denies the calls that should never happen.

And three systems that compose all of it — a research agent with machine-verified provenance, a writing workflow that produces byte-identical output and executes the code it publishes, and an MCP server with a real error contract, scopes, and idempotency.

That is a full stack. Not a survey of one.

What this book does not cover

Honesty about the edges is more useful than a triumphant ending.

Model training and fine-tuning. Nothing here touches weights. When your agent is limited by the model rather than by the scaffolding — and it is much rarer than people assume — this book has nothing for you.

The serving layer. GPU scheduling, batching, KV cache management, quantization, and the difference between vLLM and a naive server are all absent. Everything here assumes an API endpoint exists and responds.

Retrieval at scale. The memory system in Part 3 is a real memory system; it is not an information-retrieval course. Hybrid search, rerankers, chunking strategy at a hundred million documents, and index maintenance are their own discipline.

Evaluation depth. Part 5 gives you a harness and enough judgement to use it. It does not cover long-horizon evaluation, rubric development at scale, inter-annotator agreement, or the statistics of comparing two noisy systems properly.

Multimodality. Vision, audio, and computer use appear nowhere. The orchestration patterns transfer; the failure modes do not.

Frontier-lab-scale operations. Thousands of concurrent agents, cross-region failover, multi-tenant isolation at the model layer. The principles scale; the specifics you will learn on the job.

Legal and compliance. Data residency, retention, auditability for regulated industries, and the emerging regulatory picture. Real constraints, entirely out of scope here.

The sibling repositories

Three companion repos pick up exactly where this book stops, and they are worth reading in this order.

agentic-ai-evaluation-guide goes where Part 5 stops. Evaluation as a discipline rather than a component: what to measure for agents specifically, how to build and maintain datasets, judge calibration, trajectory-level evaluation, and a long-horizon-operations track for agents that run for days rather than seconds. Read it if the thing blocking you is “I cannot tell whether this got better.”

llm-serving-inference-guide goes underneath Part 6. The serving layer this book treats as an endpoint: GPU containers, Kubernetes, autoscaling, traffic splitting, vLLM and Triton, quantization, and the monitoring stack beneath all of it. Read it if the thing blocking you is latency, throughput, or a bill that is dominated by inference rather than orchestration.

ml_and_llm_learning goes beneath both. The fundamentals: how transformers work, what training and fine-tuning actually do, the evaluation of models rather than systems. Read it if you find yourself unable to reason about why a model behaves the way it does, rather than what to do about it.

Genuinely worthwhile next steps

Five things, ordered by how much they will change your work.

1. Ship one of these to real users. Nothing in this book substitutes for the week after launch. Pick the smallest of the three systems, put it in front of five colleagues, and instrument it. The gap between your eval set and what people actually type is the most educational data you will ever collect.

2. Read the specification, not the tutorial. The MCP spec (https://modelcontextprotocol.io/specification/2026-07-28) is short, readable, and full of decisions you will otherwise rediscover expensively. Same for A2A (https://a2a-protocol.org/). An afternoon each.

3. Read other people’s agent code. The Anthropic cookbook (https://github.com/anthropics/anthropic-cookbook), the MCP reference servers (https://github.com/modelcontextprotocol/servers), and LangGraph’s own source (https://github.com/langchain-ai/langgraph) are the three most instructive codebases in this space. You now know enough to disagree with them, which is where the learning is.

4. Build the eval set before the next feature. Whatever you build next, write twenty realistic cases first. It feels slow and it is the single highest-leverage habit in this entire book.

5. Follow the primary sources, not the feeds. Anthropic’s engineering blog (https://www.anthropic.com/engineering), the MCP blog (https://blog.modelcontextprotocol.io/), and arXiv’s cs.MA and cs.CL listings. Most agent content is a restatement of a paper or a post; go to the thing being restated.

Resources worth keeping open

A last word

The most valuable thing in this book is not any of the code.

It is the habit the mini-projects were designed to build: write the smallest thing that could work, run it, watch precisely how it fails, and add exactly the piece that fixes that failure. Every framework you will use for the next decade is someone else’s answer to a failure like the ones you produced deliberately here. Because you have written the loop, the registry, the engine, the harness, and the tracer yourself, you will be able to see through those frameworks to the thing underneath — and you will know when their answer is not the one your problem needs.

That is the whole point. Go build something and let it break in public.

What you should be able to do now

  • Name what you have built across the whole book, and describe each piece as a component with an interface rather than as a tutorial you followed.
  • State honestly what this book did not teach you, so you can tell when a problem is outside your current toolkit rather than a failure of effort.
  • Pick the right sibling guide for a given blocker: evaluation depth, serving performance, or model fundamentals.
  • Choose a next step that changes your work — shipping to real users, reading a specification end to end, or writing an eval set before a feature — instead of consuming more material.

Further reading