记住更多,风险更多:具有记忆能力的LLM代理的纵向安全风险
Remembering More, Risking More: Longitudinal Safety Risks in Memory-Equipped LLM Agents
AI总结:
本研究探讨了具有记忆能力的LLM代理在长期任务中因记忆积累导致的安全风险,提出了一种触发-探测协议来评估记忆污染的影响,并发现记忆安全应被视为一个纵向属性而非单一状态属性。
摘要:
对具有记忆能力的LLM代理的安全评估通常测量单任务内的安全性:代理是否在对抗性条件下(如提示注入或记忆污染)安全地完成单一场景。然而,在部署中,一个代理会服务于许多独立任务,时间跨度较长,早期任务积累的记忆会影响后续无关任务的行为。研究这种情形需要在任务间的时间维度上进行评估:不是代理在任何单一记忆状态下的安全性,而是随着记忆在许多独立交互中积累,其安全性特征如何变化。我们称之为这种故障模式“时间记忆污染”。为了隔离记忆暴露与流非平稳性,我们引入了一种触发-探测协议,该协议通过固定探测集与不同前缀长度的只读记忆快照进行评估,并结合NullMemory反事实基线来识别由记忆引起的违规。我们将此协议应用于三个涵盖记录、备忘录、表单和电子邮件通信的部署场景,以及八种记忆架构,并进一步在Claw-like AI代理(如OpenClaw)上使用平台原生的记忆机制。具有记忆能力的代理在NullMemory基线上表现优异,记忆引起的违规率在两种代理类别中均表现出随暴露长度上升的稳健趋势。顺序随机化实验表明,该效应主要由积累内容而非接触顺序驱动。最后,事件分解的结构后果是记忆引起的风险在生成前的检索状态即可检测,我们通过高召回率的诊断监控器验证了这一点。我们的结果表明,应将记忆安全视为一个需要时间评估的纵向属性,而非可通过快照捕捉的单一状态属性。
英文摘要:
Safety evaluations of memory-equipped LLM agents typically measure within-task safety: whether an agent completes a single scenario safely, often under adversarial conditions such as prompt injection or memory poisoning. In deployment, however, a single agent serves many independent tasks over a long horizon, and memory accumulated during earlier tasks can affect behavior on later, unrelated ones. Studying this regime requires evaluation along the temporal dimension across tasks: not whether an agent is safe at any single memory state, but how its safety profile changes as memory accumulates across many independent interactions. We call this failure mode temporal memory contamination. To isolate memory exposure from stream non-stationarity, we introduce a trigger-probe protocol that evaluates a fixed probe set against read-only memory snapshots at varying prefix lengths, together with a NullMemory counterfactual baseline for identifying memory-induced violations. We apply this protocol across three deployment scenarios spanning records, memos, forms, and email correspondence and eight memory architectures, and additionally on Claw-like AI agents, such as OpenClaw, using the platform's native memory mechanism. Memory-enabled agents consistently exceed the NullMemory baseline, and memory-induced violation rates show a robust upward trend with exposure length on both agent classes. Order-randomization experiments indicate that the effect is driven primarily by accumulated content rather than encounter order. Finally, a structural consequence of the event decomposition is that memory-induced risk is detectable from retrieval state before generation, which we confirm with a high-recall diagnostic monitor. Our results argue for treating memory safety as a longitudinal property that requires temporal evaluation, not a single-state property that can be captured by a snapshot.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。