arXiv:2607.23929cs.AI2026-07被引 5

MemTX让大模型代理的内存写入像事务一样安全,防止错误信息引发不可逆操作。

MemTX: Transactional Belief Commit for Stateful Agent Memory

论文配图:MemTX: Transactional Belief Commit for Stateful Agent Memory
图 1 · 摘自论文原文
  • 内存写入分阶段隔离,需验证通过才提交,避免污染数据直接生效
  • 支持撤销信念并自动修复由此产生的衍生结果和工具副作用
  • 在5个模型上显著优于所有基线,且零次造成下游伤害,适合高可靠性场景

大型语言模型代理越来越多地通过持久共享内存协作:一个代理的写入会成为另一个代理的前提,最终触发具有真实副作用的工具调用。当前代理内存系统将每个被接受的写入视为即时成立的事实,因此污染的工具结果、过时的更新或队友未完成的笔记可能无声地引发不可逆动作。我们提出,内存写入不应等同于信念提交。本文提出MemTX,一种事务式信念提交协议。每条记录携带证据、权限、来源和有效性信息。写入在快照隔离的事务中暂存,经验证-提交流水线处理,不可逆工具调用需基于进行中的信念状态进行阻断,撤回信念会触发类型化的级联修复其衍生记录与工具副作用。通过属性测试与550万协议状态的穷举枚举,两个不变量——行动安全门控与级联修复完备性——均未发现违反。在三个模型家族的五个骨干模型上,MemTX在四个骨干上以配对-McNemar检验显著领先所有八个基线,在第五个最强骨干上与最优基线统计持平,且是唯一在所有骨干上实现零下游伤害的方法。模型能力无法替代提交纪律。

原文摘要 · Abstract (English)

LLM agents increasingly coordinate through persistent shared memory: one agent's write becomes another agent's premise, and eventually a tool call with real side effects. Current agent memory systems treat every accepted write as immediately actionable truth, so a polluted tool result, a stale update, or a teammate's half-finished note can silently drive an irreversible action. We argue that a memory write is not a belief commit. We present MemTX, a transactional belief-commit protocol. Each record carries evidence, permissions, provenance, and validity. Writes are staged inside snapshot-isolated transactions and admitted by a validate-and-commit pipeline, irreversible tool calls are gated on in-flight belief state, and retracting a belief triggers typed cascading repair of its derived records and tool side effects. Two invariants, action-safety gating and cascade-repair completeness, are machine-checked by property-based testing and bounded exhaustive enumeration of 5.5 million protocol states, with zero violations. Across five backbones from three model families, MemTX leads all eight baselines with paired-McNemar significance on four backbones and statistically ties the best baseline on the fifth and strongest, while remaining the only method with zero downstream harm on every backbone. Backbone capability does not substitute for commit discipline.

代理系统内存安全事务机制可靠性

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。