Just-in-Time Retrieval
Fetch what the task needs when it needs it, not everything in advance.
Holding pointers, summaries and search tools in context, and letting the agent retrieve the full material only at the moment it is required — the alternative to preloading everything that might be relevant.
It is the agentic version of the retrieval argument, and it depends on cheap, reliable lookup existing: a filesystem with grep, a search tool, a catalogued corpus. Where lookup is expensive or unreliable, preloading still wins.
The dependency worth being explicit about is retrieval quality: this pattern assumes lookup is cheap and reliable, and it degrades badly when it is not. Agents that guess at a search query and miss have no fallback, where a preloaded corpus at least guarantees presence.
An index instead of an appendix
A fifty-page reference document the agent occasionally needs.
Keep the structure and section headings in context. The agent fetches the two sections relevant to the task and the window stays small — where pasting the whole document would spend most of the budget on material this task does not use.
- blogEffective context engineering for AI agents ↗
Defines context engineering as curating everything supplied at inference, names context rot, and covers just-in-time retrieval, compaction and keeping the window high-signal.
- paperActive retrieval augmented generation ↗
FLARE decides when and what to retrieve during generation rather than retrieving once up front — the research ancestor of agentic retrieval.
Context Engineering
Deciding what goes in the window, in what order, at all.
Agentic Search
Searching iteratively, judging results, and searching again.
Context Pointer · Reference
A cheap reference to something the agent can fetch if needed.
Progressive Disclosure
Reveal detail only when it becomes relevant.
RAG · Retrieval-Augmented Generation
Look things up, then put what you found in the prompt.