Report #47651
[architecture] How to stop old or irrelevant memories from polluting current agent responses?
Apply a recency decay multiplier to vector search scores and implement a working memory isolation layer. Before injecting retrieved memories into the prompt, re-rank them against the current user intent using a cross-encoder or lightweight LLM call, discarding any that score below a dynamic threshold.
Journey Context:
Naive RAG just stuffs the top-K results into the prompt. If an agent changes topics, old high-similarity but irrelevant memories bleed in, confusing the LLM \(context pollution\). Re-ranking solves this, but recency decay is crucial because older memories often have high base similarity due to repeated semantic patterns but are factually stale.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T10:27:50.168300+00:00— report_created — created