让大模型记得事情何时发生、是否过时,还能自动引用证据。
SodaMem: Evidence-Grounded Temporal Graph Memory for LLM Agents

- 用带来源和时间的事件图谱存储记忆,支持更新与矛盾关系
- 在长对话评估中达到92.8%准确率,每题成本仅约1.6美分
- 适合需要高时效性和可验证性的长期对话系统
依赖大语言模型(LLM)的智能体在持续数周的对话中,必须记住当前真实状态,而不仅是过去说过的内容。传统的扁平化RAG日记和Markdown日志虽利于信息检索,但在时效性、来源追溯和时间顺序推理方面表现不足。本文提出SodaMem,一种基于证据的时间图谱记忆系统:(i) 提取带有类型和强制来源片段的事实事件;(ii) 持久记录提及时间、发生时间和有效性,并通过SUPERSEDES/CONTRADICTS/UPDATES等边关系构建动态图谱,结合词法与稠密索引;(iii) 通过规划器-阅读器循环获取可引用证据后生成回答。在LongMemEval-S上,其存储-记录配置在N=3次采样中达到92.8%准确率(464/500),平均成本为0.00161美元/问题(约18.3k tokens,中位数0.00111美元/约14.6k tokens),使用deepseek-v4-flash模型。我们整理了公开系统的可估API成本,绘制成本-准确率图谱,结果显示SodaMem在闪存级支出下处于准确率前沿,且显著优于多个更高成本、更低准确率的系统。准确率评估采用相同Flash模型作为阅读器与评判者(自评),成本未包含数据摄入与评判开销,跨系统比较基于估算而非单次基准测试。
原文摘要 · Abstract (English)
Large language model (LLM) agents that assist users over weeks of conversation must remember what is currently true, not merely what was once said. Flat RAG diaries and Markdown logs optimize needle retrieval but under-serve currency, provenance, and ordered temporal reasoning (Maharana et al. 2024; Wu et al. 2024; Packer et al. 2023; Chhikara et al. 2025). We present SodaMem, an evidence-grounded temporal graph memory that (i) extracts typed FactEvents with mandatory provenance spans, (ii) persists mention time, occurrence time, and validity with SUPERSEDES/CONTRADICTS/UPDATES edges under hybrid lexical-dense indexing, and (iii) answers via a planner-reader loop that gathers citable evidence before composing a final response. On LongMemEval-S, our store-of-record configuration reaches 92.8% accuracy (464/500; best of N=3) at mean $0.00161/question (approximately 18.3k tokens; median $0.00111 / approximately 14.6k) with deepseek-v4-flash. We compile public systems with estimable API cost into a cost table and cost-accuracy map; under these estimates SodaMem sits near the accuracy frontier at Flash-tier spend and strictly dominates several higher-cost, lower-accuracy points. Accuracy uses the same Flash model as reader and judge (self-grading); costs exclude ingest/judge and cross-system comparisons are compiled estimates rather than a single-harness bake-off.Our code is available at https://github.com/SodaMem/SodaMem
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。