Architect Foundations · 15% of the exam

context management and reliability

Domain 4 was about getting a single response right. Domain 5 is about keeping the system right across a long conversation, many agents and many cases: a conversation runs for thirty turns, a coordinator waits on several subagents, and human reviewers have room for only a fraction of the cases. Each section asks where a piece of information must be stored so that it is still exact when a later step needs it, and when the system should hand a decision to a person.

The scenario this domain runs on

You are building a customer support resolution agent with the Claude Agent SDK. It handles high-ambiguity requests: returns, billing disputes and account issues. It reaches your backend through four custom MCP tools. Your target is 80%+ first-contact resolution, while still knowing when to escalate.

The pieces you are responsible for:

get_customerlookup_orderprocess_refundescalate_to_humancase facts blockhuman review queue
$212.40The refund the agent agreed in turn 4 of a 30-turn billing dispute. By turn 26 its summarised history says "a partial refund of around $200", so process_refund is called with 200.00. Every tool call succeeds. The customer comes back, and the case no longer counts as resolved on first contact.

Each of the six sections below is a different way a system loses something it needed. In 5.1 a summary drops an exact amount. In 5.2 an escalation rule reads the customer's mood instead of the case. In 5.3 a subagent's failure reaches the coordinator as silence. In 5.4 a long exploration forgets what it found an hour ago. In 5.5 an accuracy figure hides the one document type that fails. In 5.6 a source disappears between the finding and the report.

Scenario switchThe support agent is this domain's main system, and 5.3 and 5.6 move to a second one. The guide writes error propagation and provenance about a coordinator and its subagents, so those two sections run on the exam guide's Multi-Agent Research System, the system Domain 1 used. Two other sections walk a guide example in the guide's own context, inside a flagged note: 5.4 explores a codebase with Claude Code (developer productivity), and 5.5 measures extraction by document type and field (structured extraction). Each is flagged again when you get there.

Start hereThe words this domain is built on

context window
Everything the model can see in one request: system prompt, tool definitions, and the conversation so far. The Messages API keeps no state, so your code sends all of it every time.
progressive summarisation
Replacing older turns with a shorter summary so a long conversation keeps fitting. Each pass compresses the previous summary again, and exact values are the first thing lost.
case facts block
A block your code rebuilds and sends with every request, holding the exact amounts, dates, IDs and statuses of the case. It sits outside the history, so it is never summarised.
escalation
Handing the case to a human, here by calling escalate_to_human. It is the right outcome for some cases, and a failure of first-contact resolution for others.
claim-source mapping
A record linking each claim to where it came from: source URL or document name, the excerpt, and the date. Provenance is preserved only while that link travels with the claim.
subagent
A separate Claude session with its own context window. Its tool calls and results stay there, and the parent receives only what it returns.
coordinator
The agent that splits a task into parts, delegates each part to a subagent and combines what they return. Domain 1 covers the pattern.
MCP tool
A tool served to the agent over the Model Context Protocol, such as lookup_order. The agent calls it like any other tool. Domain 2 covers the protocol.
few-shot examples
Worked input/output pairs placed in the prompt. They show the model how to handle a case instead of describing it.
Claude Code
Anthropic's command-line coding agent, used in 5.4. /compact and /clear are two of its commands. Domain 3 covers it.
The question underneath most of this domain: where does this information live, so that it is still exact when it is needed?
Amounts, dates and IDs the next action depends on (5.1)A case facts block, rebuilt every turn and never summarised.
Why a subagent could not finish (5.3)Structured error context returned to the coordinator.
What a long exploration has found so far (5.4)A scratchpad, a file on disk that is read back when a later question needs it.
Which source said what, and when (5.6)Claim-source mappings with dates, carried through synthesis.
Anything held only in the conversation history can be summarised, trimmed, or overlooked in the middle of a long input. If a later step needs it exactly, store it where your code controls it: in a block, a file or a structured field.

task statements

flashcards

0 / 18 known
Card 1 of 18