ChatPaper.aiChatPaper

全局计算,局部物化:稀疏事件键值存储的内存契约

Compute Globally, Materialize Locally: The Memory Contract of Sparse Event-KV

July 26, 2026
作者: Zefeng Cai, Zerui Cai
cs.AI

摘要

长时程智能体日益将其KV缓存复用为记忆:服务系统保留一部分缓存条目,丢弃其余部分。因此,驱逐机制与情景记忆方案都建立在一个很少被直接检验的前提之上——即一条被保留的事件在产生它的观测消失之后仍然具有信息量。我们通过在其他方面完全相同的智能体历史中,从所服务的内容里省略一条较早的观测来检验这一前提。在对该观测敏感的项目中,答案压倒性地遵循被省略的值,尽管没有任何被提供的片段指明哪个值是正确的。我们称此为语义物化:下游事件的缓存行充当计算的一种可独立服务的视图,而其输入已不复存在。它也可以被有意写入。在Qwen3-8B上,一句精心措辞、不含答案的事件将与捐赠者一致的回取率从6%提升至51%,且从未提及该值;而被动地从长期对话中收获自然提及则未检测到任何优势。此类行所承载的内容是具体且有界的。紧凑状态得以存续,较大载荷则衰减至随机水平;某次构造是否写入取决于措辞而非单纯的意义,因此模型理解力相同的两种措辞可能产生截然不同的结果。其结果是面向稀疏事件KV服务的一份记忆契约:写什么、落在何处、以及源消失后什么得以存续。对任何执行驱逐的人来说,其推论是:丢弃一个源事件而未观察到精度损失,并不能说明该源是不必要的。
English
Long-horizon agents increasingly reuse their KV cache as memory: a serving system keeps a subset of cached entries and drops the rest. Eviction and episodic-memory schemes therefore rest on a premise rarely tested directly, that a retained event is still informative once the observations that produced it are gone. We test it by omitting one earlier observation from what is served, across otherwise identical agent histories. Among items sensitive to that observation, the answer overwhelmingly follows the omitted value, though no served span says which value is correct. We call this semantic materialization: a downstream event's cached rows act as an independently servable view of computation whose inputs are gone. It can also be written on purpose. A deliberately phrased, answer-free event raises donor-aligned recovery from 6% to 51% on Qwen3-8B without ever naming the value, whereas passively harvesting natural mentions from long-term dialog yields no detected advantage. What such a row carries is specific and bounded. Compact state survives, larger payloads decay toward chance, and whether a construction writes at all turns on phrasing rather than on meaning alone, so two phrasings the model comprehends equally well can diverge sharply. The result is a memory contract for sparse event-KV serving: what to write, where it lands, and what survives once the source is gone. For anyone who evicts the corollary is that dropping a source event and observing no accuracy loss does not show the source was unnecessary.