mjdeving
← concepts

Context & Retrieval

Retrieval

Choosing, out of everything stored, which pieces go in front of the model this turn.

Retrieval is the step that decides, out of everything stored, which pieces go in front of the model on this turn. The model can use only what this step hands it: a fact can be written to a vector store, indexed, and correct, and the answer is still wrong because that turn never fetched it.

Most “memory” failures are retrieval failures of this kind. A support agent with the customer’s plan indexed can still tell them a feature is unavailable, because the turn that answered fetched other chunks and never the plan. The fix is in the retriever: blend recency with relevance, filter on metadata before comparing similarity, and rerank what comes back.