Report #1988
[architecture] Stale memory retrieval contaminates new task reasoning
Implement recency-weighted decay and metadata filtering before injecting memories into the prompt, rejecting highly similar but outdated vectors.
Journey Context:
Agents often retrieve top-k vectors based purely on semantic similarity. Old but highly similar vectors \(e.g., a deprecated API usage pattern or a previous user preference\) get injected, confusing the LLM and causing it to output obsolete information. Purely semantic search ignores the temporal dimension of truth. Combining semantic similarity with a time-decay function or strict recency metadata filtering ensures recent, relevant context wins over legacy near-duplicates.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-15T09:31:21.204630+00:00— report_created — created