# What is Contextual Retrieval? Also called contextual chunk embedding. Contextual retrieval prepends a short, generated description of a chunk's surrounding document to that chunk before it is indexed. The added sentence or two states what the chunk is about and where it sits, so an isolated passage no longer loses the context that made it meaningful. Both embedding and keyword indexes are built over the enriched text. The problem it addresses is context loss from chunking. A paragraph reading the figure rose to 14.2 percent is nearly unretrievable on its own, because nothing in it names the company, metric, or period. Splitting a document into independent chunks systematically strips this kind of anchoring information, and the loss is invisible until users start asking questions the chunks can no longer answer. The method runs a language model over each chunk together with its parent document and asks for a brief situating description, such as which section it belongs to, which entity it concerns, and which time period it covers. That description is prepended to the chunk text. The enriched chunk is then embedded and also indexed lexically, so both retrieval branches benefit from the added terms. The approach was described publicly by Anthropic in 2024, with reported reductions in failed retrievals when contextual chunks were combined with keyword scoring and a reranking pass. Reported gains are corpus dependent and should be reproduced locally before being assumed. The technique is recent enough that best practices around description length and prompt design are still settling. The main cost is a model call per chunk at indexing time, which is significant for large corpora and must be repeated whenever chunks are regenerated. Prompt caching over the parent document reduces this considerably, since the same document is reused across all of its chunks. There is also a risk that a generated description asserts something the document does not say, which then becomes a retrievable false signal. ## Key points - Prepends a generated situating description to each chunk - Restores context that chunking removed - Improves both embedding and keyword branches - Costs one model call per chunk at index time - Generated descriptions can introduce incorrect signals ## In practice A chunk reads: the figure rose to 14.2 percent, driven mainly by the new pricing tier. Contextual retrieval prepends: this passage is from the Q3 2025 results section of the Northwind annual report, discussing gross margin. A user asking about Northwind's Q3 gross margin now retrieves it, where previously the chunk matched nothing, since none of those words appeared in the original text. ## Related terms - [Chunking](/en/glossary/chunking) - [Chunk Overlap](/en/glossary/chunk-overlap) - [Hybrid Search](/en/glossary/hybrid-search) - [Document Ingestion](/en/glossary/document-ingestion) - [Prompt Caching](/en/glossary/prompt-caching) [Back to the AI Glossary](/en/glossary)