Claude Certified Architect – Foundations Practice Question 80: Just in Time Context

Claude Certified Architect, Foundations · Test 8 · question 10 of 10

Context Management & Reliabilitymedium

An agent answers engineering questions across a repository of thousands of design documents and source files. The first version loads every possibly relevant file into the prompt up front, and answer quality drops as the prompt grows even though everything still fits in the context window. Which redesign best follows Anthropic's context engineering guidance?

Select one answer
Show answer and explanation

Answer:

  • C. Give the agent lightweight references such as file paths and an index, plus search and read tools, so it loads only what it needs at runtime

Anthropic describes a "just in time" approach: agents keep lightweight identifiers (file paths, stored queries, links) and use tools to load data into context at runtime, rather than pre-processing everything. This counters context rot, where the model's ability to recall information decreases as the number of tokens grows, and aims for the smallest set of high-signal tokens. It also lets the agent explore progressively.

- A is wrong: fitting in the window does not mean quality holds; recall degrades as context grows. - B is wrong: a single large summary still fills the context with low-signal text and loses detail the agent may need. - D is wrong: caching reduces the price and latency of repeated tokens but does not reduce the amount of irrelevant content the model must attend to.

Reference: Effective context engineering for AI agents

Practice Test 8 ›

Study guides for Claude Certified Architect, Foundations