Papers

Unwrite:无需重放即可从线性注意力记忆中删除记录

Unwrite: Deleting Records from Linear Attention Memory without Replay

Why we picked it

删错信息不用重放整段对话了。Unwrite 在读取时维护一份干净状态,删一条记录只要一次加法,1.4 ms 完成,比检查点重放快 739 倍。做记忆型智能体和隐私合规的开发者都该看看这篇。

论文 Unwrite 解决线性注意力模型在推理时删除已读记录的问题。Softmax 注意力可以直接丢弃记录的 key 和 value,但线性注意力把每个 token 混入固定大小的循环状态,没有逐 token 条目。现有补救方法有两个缺陷:重放需要重新处理记录之后读取的所有内容,而保存差值的廉价方法会遗漏记录对后续 token 的影响。

Body

Unwrite 的做法是在模型读取文本时,同时在一个跳过该记录的状态副本上运行,并以低秩形式存储两个状态之间的差值。这个副本与主模型在同一次前向传播中读取所有后续 token,因此能捕获记录对这些 token 的影响。删除操作只需一次加法,无需文本或检查点,在纯循环模型上全秩时与重放等效。

实验显示,Unwrite 在三个线性注意力模型上的答案质量与重放相当,在混合模型上比注意力掩码移除得更彻底。由于额外工作在读取阶段完成,单次删除耗时约 1.4 ms,在 Gated DeltaNet 1.3B 上比检查点重放最多快 739 倍。

Original · arXiv cs.LG

Unwrite: Deleting Records from Linear Attention Memory without Replay

Deleting a record read at inference time is important for language model assistants when a user has entered wrong or sensitive information. Softmax attention can drop the keys and values of the record, but linear attention mixes every token into fixed-size recurrent states without per-token entries. We identify two limitations of the existing remedies: (i) replay reprocesses everything read after the record, and (ii) cheaper remedies subtract a difference saved when the record is read and miss the record's effect on later tokens. We propose Unwrite, which addresses both limitations by maintaining the record-free state alongside the model as it reads the text. Specifically, Unwrite runs the model on a copy of its state that skips the record and stores the difference between the two states at low rank. This copy reads every later token in the same forward pass as the model and thus captures the record's effect on these tokens. While needing neither the text nor a checkpoint, a single deletion is one addition that equals replay at full rank on purely recurrent models. Empirically, Unwrite matches replay on answers on three linear attention models and removes more of the record's effect than attention masking on a hybrid model. Since its extra work is done during reading, a deletion takes about 1.4 ms and is up to $739\times$ faster than checkpoint replay on Gated DeltaNet 1.3B.

Industry Coordinates & Source Verification

This report is categorized under AITOP's "Papers" desk. Within our cross-regional analytical framework, it directly maps to AI developer toolchains, coding agents, and engineering workflows. Key entities and technical topics under continuous tracking include Unwrite, linear attention, Gated DeltaNet, AI safety.

Source attribution: curated from arXiv cs.LG (@Yihao Qiao, Sihao Hu). Cross-source corroboration: 2 independent sources have covered this development (including Sebastian Raschka), confirming industry-wide signal strength.

  • Sebastian Raschka12-01 16:55Source
Spotted an error in the summary or translation? Tell us