Context Engineering: Build Consistent, Accurate, Predictable AI Systems
by Manning (Boni García)
Twelve chapters on instructions, retrieval, tools, memory, evaluation and governance — in Python, JavaScript and Java.
Overview
Context Engineering: Build Consistent, Accurate, Predictable AI Systems is a Manning book by Boni García, an associate professor at Universidad Carlos III de Madrid who leads work on the Selenium project and created WebDriverManager and Selenium Manager. It defines context engineering as the discipline of selecting, organising, updating, compressing and prioritising the precise context a model needs to generate accurate responses, and covers it across twelve chapters: introduction to context engineering; instructions for AI agents, covering system prompts and instruction artifacts across providers; external knowledge and retrieval, covering RAG patterns, context stuffing and cache-augmented generation; tools in AI agents, covering function calling, CLI tools and Model Context Protocol servers; memory and state in agentic systems, separating session memory, long-term memory and workflow state; user prompts, covering few-shot prompting, prompt chaining, chain of thought and ReAct; context management and orchestration, covering compression and multi-agent collaborative patterns; evaluation and observability, covering metrics, evals, LLM-as-judge and observability tooling; governance and operations, covering PII redaction, validation, bias detection and human-in-the-loop; AI frameworks for context engineering; context engineering for software development, covering SDLC skills, documentation retrieval and specialised agents; and the state of the art. It runs roughly 393 pages and is a MEAP title with all chapters available, publication estimated November 2026. The Apache-2.0 companion repository at github.com/bonigarcia/context-engineering holds runnable examples in Python, JavaScript and Java across LangChain, LangGraph, LlamaIndex, CrewAI, DSPy, Pydantic AI, Haystack, Spring AI, Semantic Kernel and DeepAgents, targeting OpenAI, Anthropic, Google and local Ollama models.
At a Glance
- Topic
- Agentic
- Level
- Intermediate
- Format
- Book
- Cost
- Paid
- Duration
- ~393 pages across 12 chapters, ~15-20 hours
- Provider
- Manning (Boni García)
- Hands-on
- Yes — code/exercises
- Certificate
- None
What You’ll Learn
- ✓Design instruction artifacts and system prompts that port across OpenAI, Anthropic and Google
- ✓Choose between RAG, context stuffing and cache-augmented generation for a given workload
- ✓Wire tools into agents through function calling, CLI interfaces and MCP servers
- ✓Separate session memory, long-term memory and workflow state in agentic systems
- ✓Compress and orchestrate context across multi-agent and collaborative agent patterns
- ✓Instrument evaluation and observability for production agents, including LLM-as-judge scoring
- ✓Add governance controls: PII redaction, output validation, bias detection and human-in-the-loop
Highlights
- •Framework-agnostic — examples span LangChain, LangGraph, LlamaIndex, CrewAI, DSPy, Haystack, Spring AI and Semantic Kernel
- •Rare polyglot coverage with runnable Python, JavaScript and Java rather than Python only
- •Treats governance and observability as full chapters, not appendices, unlike most agent books
- •The Apache-2.0 companion repo is maintained to stay current after the book publishes
- •Written by an academic who also ships widely used open-source tooling, so neither pure theory nor vendor marketing
Who It’s For
Best For
- ✓AI engineers whose agent works in demos but drifts unpredictably in production
- ✓Java and JavaScript developers underserved by Python-only agent material
- ✓Engineering managers who need one shared vocabulary for context across a team
Prerequisites
- •Familiarity with LLM basics and at least one agent framework
- •Programming ability in Python, JavaScript or Java to run the companion examples
- •API keys for OpenAI, Anthropic or Google, or a local Ollama installation
FAQ
What is Context Engineering: Build Consistent, Accurate, Predictable AI Systems?
A framework-agnostic, twelve-chapter treatment of context engineering — instructions, retrieval, tools, memory, orchestration, evaluation and governance — for AI engineers who have shipped an LLM app and now need it to behave predictably. It is currently a Manning Early Access (MEAP) title with all chapters written and publication estimated for November 2026, and it ships a maintained companion repository of runnable Python, JavaScript and Java examples across nine agent frameworks.
Is Context Engineering: Build Consistent, Accurate, Predictable AI Systems free?
Context Engineering: Build Consistent, Accurate, Predictable AI Systems is a paid resource.
What level is Context Engineering: Build Consistent, Accurate, Predictable AI Systems for?
Context Engineering: Build Consistent, Accurate, Predictable AI Systems is aimed at a intermediate audience. Recommended background: Familiarity with LLM basics and at least one agent framework, Programming ability in Python, JavaScript or Java to run the companion examples, API keys for OpenAI, Anthropic or Google, or a local Ollama installation.
How long does Context Engineering: Build Consistent, Accurate, Predictable AI Systems take?
Expect roughly ~393 pages across 12 chapters, ~15-20 hours. Most learners work through it at their own pace.
What will I learn from Context Engineering: Build Consistent, Accurate, Predictable AI Systems?
You'll learn: Design instruction artifacts and system prompts that port across OpenAI, Anthropic and Google; Choose between RAG, context stuffing and cache-augmented generation for a given workload; Wire tools into agents through function calling, CLI interfaces and MCP servers; Separate session memory, long-term memory and workflow state in agentic systems; Compress and orchestrate context across multi-agent and collaborative agent patterns; Instrument evaluation and observability for production agents, including LLM-as-judge scoring; Add governance controls: PII redaction, output validation, bias detection and human-in-the-loop.
Topics
Sources
This page was written from 3 sources, 2 on domains other than manning.com.