检索记忆中的时间有效性:消除AI智能体在知识演化中的过时事实错误
Temporal Validity in Retrieval Memory: Eliminating Stale-Fact Errors for AI Agents over Evolving Knowledge
AI总结:
针对RAG无法处理知识演化导致过时事实错误的问题,提出MemStrata,通过确定性替换规则维护时间有效性,在演化知识上准确率达0.95-1.00,过时事实错误率降至~0%。
摘要:
检索增强生成(RAG)使智能体能够访问累积的知识,但没有时间模型。当一个事实发生变化(例如,函数重命名或API重构),RAG会以几乎相同的嵌入相似度检索到过时和当前的值。智能体要么放弃回答,要么提供已被取代的事实。我们表明这是一个结构性问题:在一个校准数据集上,余弦相似度区分矛盾事实与重复事实的AUROC为0.59(接近随机),因为矛盾事实通常与原始事实的嵌入相似度高于改写后的重复事实。我们提出MemStrata,一种维护时间有效性的检索记忆。它像RAG一样存储事实,保留静态召回,但当某个事实的值被矛盾时,一个确定性的(主体、关系、对象)取代规则会在双时间账本中淘汰过时值——无需相似度阈值,无需LLM调用。在六个基准测试中,使用7B模型本地运行,MemStrata在静态知识上与RAG持平,在演化知识上达到0.95-1.00的准确率(RAG为0.20-0.47)。核心结果是过时事实错误率:当需要回答时,RAG在15-40%的情况下提供已被取代的值;MemStrata将其降至约0%,这是RAG无法避免的失败类别。MemStrata在检索延迟(约2.1秒)方面优于LLM重排序基线(约16-18秒)。我们发布了用于知识演化下记忆的测试工具、数据集和无标记评估协议。
英文摘要:
Retrieval-augmented generation (RAG) gives agents access to accumulated knowledge, but has no model of time. When a fact changes (e.g., a function is renamed or API restructured), RAG retrieves both the stale and current value with near-identical embedding similarity. The agent then either abstains or serves the superseded fact. We show this is a structural problem: on a calibrated dataset, cosine similarity distinguishes a contradicted fact from a duplicated one with AUROC 0.59 (near chance), as contradictions are often more embedding-similar to the original than rephrased duplicates. We present MemStrata, a retrieval memory maintaining temporal validity. It stores facts like RAG, preserving static recall, but when a fact's value is contradicted, a deterministic (subject, relation, object) supersession rule retires the stale value in a bi-temporal ledger - with no similarity threshold and no LLM call. Across six benchmarks run locally with a 7B model, MemStrata ties RAG on static knowledge and reaches 0.95-1.00 accuracy on evolving knowledge (where RAG reaches 0.20-0.47). The central result is the stale-fact-error rate: when required to answer, RAG serves superseded values 15-40% of the time; MemStrata drives this to ~0%, a failure class RAG cannot avoid. MemStrata achieves this at retrieval latency (~2.1s) versus ~16-18s for LLM-reranking baselines. We release the harness, datasets, and a marker-free evaluation protocol for memory under knowledge evolution.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。