Report #84433
[architecture] Old memories polluting new context and causing hallucinations
Implement time-weighted decay in retrieval scoring and an explicit memory invalidation step when state changes occur.
Journey Context:
Vector databases return semantically similar text regardless of recency. If a user changes their preference, both the old and new preferences are equally similar to the query, causing the LLM to hallucinate or contradict itself. Pure cosine similarity fails here. Alternatives like manual deletion are brittle. Time-weighted decay \(e.g., exponential decay on the retrieval score\) naturally suppresses stale context, while an explicit invalidation step \(checking if a new fact obsoletes an old one before writing\) ensures hard state changes are respected.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T00:18:45.487867+00:00— report_created — created