Report #28634
[architecture] Old memories polluting current context window and skewing answers
Use a two-stage retrieval pipeline: fetch broadly from the vector store, then use a smaller, fast LLM or cross-encoder to rerank/filter memories based strictly on the current turn's intent before injecting into the prompt.
Journey Context:
Naive RAG dumps top-K vectors into the prompt. If K is high or embeddings are dense, old, irrelevant memories consume context tokens and skew the LLM's attention. Reranking prevents context window exhaustion and hallucination from stale data, ensuring only highly relevant context occupies the limited prompt space.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T02:27:34.023010+00:00— report_created — created