Paper: 2611.34762 — TASK Memory: Beyond Text-Only Memory with Activation Steering and Knowledge Editing against Memory Hallucination Authors: Jinkun Zhao, Wenjun Wu Categories: cs.AI Reading scope: Original arXiv HTML, main Sections 1–7 and Appendices A–E, without text excerpting; all five figures inspected. The overview below reproduces Figure 3. This is a source-based reading, without independent review, a code/data audit, or experiment reproduction.

The Problem

Imagine an invented example. Mira now works at Cedar, and an agent has correctly saved that note. Its old answer says she works at Pine. Asked about Mira, it still answers Pine. Asked about Owen, it instead borrows Mira’s note and answers Cedar. Later Mira moves to Birch, but the old Cedar note remains active. Each failure can happen despite having a correct new record.

The paper separates these failures into ignoring a memory, applying it to the wrong entity, and using a superseded version. Its question begins after storage and retrieval: how should a model use a note that has reached it? A language model brings its existing knowledge to the prompt. Increasing its willingness to follow notes can help Mira’s question while making Owen’s answer worse.

TASK gives each memory a way to participate in that decision. It keeps a text record, attaches a model-dependent relevance address, and learns two interventions: one encourages adoption on relevant questions; the other encourages restraint on unrelated ones. A removable knowledge edit supplies a keyed association useful for composition. The different parts have different jobs, rather than being uniformly helpful additions.

The Explanation

Give the note an address and a use policy

For the illustrative Mira note, the text record holds the employer, scope, source, and version information. Call this part T. It remains an inspectable record, rather than disappearing into a model’s weights.

The address is a detector based on the model’s internal response to the memory’s subject. Section 3.2 constructs it from representations of the subject in several writing contexts, down-weighting directions common in ordinary text. It sets a threshold using relevant contexts and hard negatives: questions with the same relation but other subjects. At reading time, a candidate note’s address response determines whether it passes. This is a calibrated relevance signal, not a guarantee that the query was understood correctly.

Part S consists of two learned vectors added to intermediate model activations. The adopt vector is trained with the note present on relevant contexts, encouraging its new answer. The restrain vector is trained on unrelated contexts with the note present, encouraging the distribution the model would produce without that note. For Mira and Owen, these are different requirements. The vectors are applied at the last prompt position and generated positions, leaving the earlier encoding of the question untouched.

Part E is a small, removable weight patch. Its key also supplies the address, while its residual is optimized to favor the updated fact. The patch can support an association that another reasoning step needs. It is not the same thing as the steering policy. The base checkpoint stays frozen while auxiliary vectors and patch residuals are optimized; “no base-model retraining” still involves per-memory computation.

Original Figure 3: write a memory object, verify candidates and coordinate interventions, then retire superseded components together

Figure 3. Text, patch, and steering are coordinated through a shared relevance decision; composition uses a separate steering rule.

For the full structured-memory reader, BM25 text search retrieves two candidates. A partial model forward pass checks their addresses. A note classified as relevant is shown as text, has its patch loaded, and receives adopt steering. If it fails the gate, its text and patch are left out and the restrain direction is selected. The hooks and patches are removed after generation. One decision keeps the components consistent with each other; it does not make that decision infallible.

Test adoption and restraint separately

The first experiment deliberately puts the correct note in context for both related and unrelated questions. This holds retrieval fixed and tests memory use. It compares text alone with text plus steering, among other interventions. The authors use five open models from 8B to 27B parameters, BF16 and greedy decoding, with non-thinking mode for Qwen3. The following Table 3 results are for the primary Qwen3-8B model on 300 CounterFact test worlds, with controlled counterfactual updates—not experiments involving our invented people.

Condition, note providedParaphrase adoptionWrong-entity misuseComposite score
Text only, T88.2%39.2%0.811
T + ungated evidence vector88.2%43.5%0.780
T + paired steering, S96.7%7.5%0.919
T + weight edit, E96.8%52.7%0.745

Adoption measures giving the updated answer on paraphrases. Misuse here is the fraction of all neighbour questions whose answers assert the memory’s object. The composite joins paraphrase accuracy, canonical-question accuracy, and locality preservation through a harmonic mean, which penalizes a weak component. Locality measures damage only on neighbours the no-memory model already answered correctly. It therefore is not simply one minus the all-neighbour misuse rate.

The paired vectors improve both requirements. A uniform evidence push increases misuse instead. Adding a weight edit also raises adoption but worsens misuse substantially in this provided-note setting. The edit is not automatically a better way to read a single fact. Remove the text and steering alone achieves only 1.7% paraphrase adoption in Table 3: the vectors are useful as a use policy, not a replacement factual memory.

Figure 4 and Appendix A separately track returning to the old answer on queries where the no-memory model gave that answer. Across ten model–dataset cells, text-plus-steering reduces this old-answer rate to at most 1.5%. That operational grouping describes baseline answers; it is not an independent inspection of which facts are stored inside the weights.

A growing library needs a reading gate

With many notes, retrieval can return a plausible distractor. In the 300-memory CounterFact library, Table 4 reports locality of 64.9% for BM25 RAG, rising to 96.9% when candidate text is address-verified. Adding steering improves adoption. The registered full configuration—verified text, gated patches, and steering—scores 0.946 against 0.782 for BM25 RAG. Table 2 reports a gain equivalent to 16.36 points on a 0–100 composite scale, with a 95% paired-bootstrap interval of 12.99–20.31 points.

Verified text plus steering without the weight patch scores 0.950. The patch’s value here is principally its address; applying the weight change does not add a clear single-fact benefit. At 3,000 memories, verified text plus steering scores 0.926 against BM25 RAG’s 0.731. Figure 5 expands the test library using training-split distractor memories made by the same writer. This is evidence for that controlled scaling test, rather than an unrestricted lifetime archive.

Now revise Mira’s employer from Cedar to Birch. Merely appending the new note can leave two adopt vectors and two nearly identical patch keys competing. TASK retrieves candidate old records, checks their addresses, and asks its own model whether the observation updates the same entity and attribute or describes a different fact. On an update, the old text, patch, and steering leave the active set together. The automatic decision uses no oracle dataset fact IDs; internal records still track scope, versions, and supersession links.

The harder revision test in Appendix C contains 150 revised facts per model. For Qwen3-8B with verified text plus steering, the stale-answer rate falls from 54.7% without supersession to 10.0% with automatic supersession. It does not fall to zero: the update judge misses 14% of true updates in that test. Retiring the right version is a precondition for successful steering.

Composition changes which intervention helps

“What country is Mira’s employer based in?” extends our illustrative question through an intermediate company. A needed entity may not appear in the original query. A restrain vector can then suppress a useful note. The paper switches to adopt-only steering for multi-hop questions.

On MQuAKE-CF-3k, using 200 cases and 600 questions with only edited base facts written, Table 5 reports 69.0% multi-hop accuracy with text alone and 62.2% with paired steering. Text plus the weight patch reaches 76.8%; text, patch, and adopt-only steering reaches 76.5%. The registered full-configuration gain over text is 7.5 percentage points. This branch’s improvement comes from the patch, with no additional steering gain established by those values. The method’s useful division of labor depends on the question.

Core Concepts

Retrieved is different from relevant. A search hit can be close in words while belonging to Owen rather than Mira. The address adds a model-dependent check, but a subject-based address can still confuse different facts about the same person. The paper needs a semantic-address variant for free-form dialogue questions.

Restraint preserves a baseline answer. It asks the model to answer Owen as it would without Mira’s note. That prevents one kind of contamination; it does not establish that the baseline answer was correct in general. The benchmark distinguishes known-correct neighbours for precisely this reason.

A memory revision changes active computation. Replacing Cedar in a text file is insufficient if the old patch or steering remains active. Coordinated supersession must remove all of those effects. An imperfect update judge remains an imperfect part of the memory system.

The Insight

A usable memory needs both content and conditions for when it should influence an answer. Evaluate whether Mira’s update is adopted and whether Owen’s answer is left alone. Either score by itself can hide the opposite failure.

TASK provides evidence that a shared relevance gate and paired use policy can improve that balance in controlled fact-memory tasks. The same evidence also argues for choosing interventions by their role: single facts do not necessarily need a weight change, multi-hop composition does not benefit from the same two-sided steering rule, and revisions require retiring old components first.

A Critical Reading

The authors report frozen, subject- or conversation-separated splits, pre-registered primary comparisons, and test sets run once. Their confidence intervals bootstrap memory worlds or conversations, rather than representing repeated base-model training. The main structured tasks use synthetic counterfactual updates. Generation is graded with their assertion matcher, and dialogue with LLM judges; these are not the official benchmark scorers. I have not independently checked their code, prediction files, or registration timeline.

Generality has important exceptions. On Gemma-3-27B zsRE, text plus steering has a composite difference of -4.61 points from text alone, with a 95% interval of -10.25 to 0.01: no demonstrated improvement. Several relations for one subject are hard for the address; Appendix C reports roughly 10% sibling-memory confusion, and address-only supersession can retire the wrong fact.

For LoCoMo dialogue, the method uses a semantic address and text plus steering, without the fact patch. Table 7’s primary judge gives 34.2% accuracy at about 298 input tokens, against 30.8% for BM25 at 299 tokens. Full conversation context reaches 60.3% with 19,488 tokens. Gains at a small context budget are useful, but they leave substantial unanswered questions. On AppWorld development tasks, Appendix D reports almost no completed tasks and no significant steering improvement in partial test-pass rate.

Writing is also costly: Appendix B measures about 25 seconds for steering and 4 seconds for a patch per memory on Qwen3-8B with one A6000 GPU. The experiments reach 3,000 memories, not millions. And a use policy cannot verify a note’s truth: the source’s correct-memory assumption leaves extraction and source checking as separate responsibilities.

What You Can Use

For an agent-memory evaluation, build three linked tests around one update: ask Mira’s question in several forms, ask a neighbouring question about Owen, then revise Mira again. Check adoption, contamination, and stale-version answers separately. Keep note selection distinct from the model’s behavior after selection.

If you operate a model with access to its activations and gradients, TASK suggests experiments with a relevance gate and paired steering. For an API that does not expose those hooks, the evaluation pattern still transfers. Record writing cost and test the application’s actual question types, including multi-hop and dialogue. These are practical inferences from the paper; they are not a reproduced deployment result.

论文: 2611.34762 — TASK Memory: Beyond Text-Only Memory with Activation Steering and Knowledge Editing against Memory Hallucination 作者: Jinkun Zhao、Wenjun Wu 分类: cs.AI 阅读范围: 原始 arXiv HTML,正文第1—7节及附录A—E,未截取文字;已查看全部五张图。 下方总览图原样取自图3。 本文据原文解读,没有独立评审、代码与数据审计或实验复现。

问题

先设一个虚构例子:米拉现在在雪松公司工作,助手已经正确存下这条笔记,但模型原来的回答还是松树公司。 问米拉,它答松树;问另一个人欧文,它反而借用米拉的笔记,答雪松。 后来米拉又去了白桦公司,旧的雪松笔记仍在生效。 即使新记录没有写错,这三种错误也都可能发生。

论文把它们分成不采纳记忆、把记忆错用到另一个对象、继续采用已过时版本。 问题从存储和检索之后开始:已经到手的笔记,模型该怎样用? 语言模型读笔记时也带着既有知识。 一味催它相信笔记,可能帮米拉这道题,却害了欧文那道题。

TASK给每条记忆配上参与这项决定的机制。 文本记录之外,它有一个依赖模型的相关性地址,再学两种干预:相关问题上鼓励采纳,无关问题上鼓励克制。 一个可卸载的知识编辑补丁,提供多步推理可能需要的关联。 这些零件各有用途,并不是加得越齐越好。

翻译

给笔记一个地址,也给它使用规则

在米拉这个例子上,文本部分存下雇主、范围、来源和版本信息,叫作T。 它仍是一份可以查看的记录。

地址则利用模型内部对记忆主体的响应,判断问题是否相关。 第3.2节从多个写入语境里提取主体表征,再降低普通文本常用方向的权重。 阈值用相关语境和困难反例校准;反例保持同一种关系,却换了主体。 读取时,看候选笔记的地址响应有没有过线。 这是校准出的相关性信号,并不保证问题一定认对。

S是一对加到模型中间激活上的引导向量。 采纳向量在“笔记已提供、问题相关”的语境里训练,推动新答案。 克制向量在“笔记已提供、问题却无关”的语境里训练,让模型接近没看这条笔记时的输出分布。 米拉和欧文对应的是两种要求。 向量只作用于最后一个提示位置和生成位置,前面的问题编码保持不动。

E是小型、可卸载的权重补丁。 它的键也用来提供地址,补丁残差则朝新事实优化,为后续推理补上关联。 它与控制笔记怎样使用的S不是一件东西。 基础检查点保持冻结,训练的是辅助向量与补丁残差;“不重训基础模型”仍然需要逐条记忆计算。

原图3:写入记忆对象、核验候选并协调干预、将过时组件一同退出生效集合

图3。文本、补丁和引导共享相关性决定;多步推理另用一种引导规则。

完整的结构化记忆读取器先用BM25文本检索取两个候选,再跑到模型中间层检查地址。 判为相关的笔记进入提示,它的补丁加载,并采用采纳引导。 没过门槛的候选不放文本、不加载补丁,改选克制方向。 生成结束后卸下钩子与补丁。 同一个决定让零件保持一致,但不保证决定本身正确。

采纳与克制,要分开测

第一组实验故意把正确笔记放进相关和无关问题的上下文,固定检索结果,只测怎样使用。 其中比较文本T与文本加引导T+S,并加入其他干预。 作者使用五个8B到27B参数的开放模型,BF16、贪心解码,Qwen3采用非思考模式。 下方表3数据来自主要模型Qwen3-8B的300个CounterFact测试世界;它们使用受控的反事实更新,不是对我们虚构人物的实验。

条件,笔记已提供改写问题采纳率错用到其他对象的比例综合分
只有文本T88.2%39.2%0.811
T加不设门控的证据向量88.2%43.5%0.780
T加成对引导S96.7%7.5%0.919
T加权重编辑E96.8%52.7%0.745

采纳率看改写问题上是否给出更新后的答案。 这里的错用率,以所有邻近问题为分母,数答案是否用了这条记忆的对象值。 综合分把改写题正确率、原始题正确率和邻近题保持程度取调和平均,一项弱就会拖低总分。 邻近题保持程度只看无记忆模型原本答对的题,因此不能直接用“一减错用率”算出它。

成对向量同时改善两种要求;统一推模型相信证据,反而增加错用。 加权重编辑也抬高采纳率,却在这个给定笔记的设置里大幅加重错用。 编辑并不天然更适合读一条事实。 去掉文本,S单独在表3中只得1.7%的改写问题采纳率;向量适合管用法,不能直接取代事实记录。

图4和附录A还单独追踪“原来没笔记时答旧值,提供笔记后仍答旧值”的问题。 十个模型与数据集组合里,文本加引导把这个旧答案比例降到最多1.5%。 这里的分组依据无记忆模型的回答,不是独立审计权重里究竟存了哪些事实。

记忆变多,要在读取处再过一道门

笔记多起来,检索可能取来很像答案的干扰项。 300条CounterFact记忆的库里,表4记录BM25 RAG的邻近题保持程度为64.9%,地址核验文本后升到96.9%;再加S改善采纳。 预注册的完整配置——核验文本、门控补丁与引导——综合分0.946,BM25 RAG为0.782。 表2把综合分换成百分制,报告提升16.36点,95%配对自助抽样区间为12.99—20.31点。

不加载权重补丁的“核验文本加S”得0.950。 这里E主要贡献地址,实际改变权重没有带来清楚的单事实增益。 扩到3000条记忆,核验文本加S得0.926,BM25 RAG为0.731。 图5用同一个写入器产出的训练划分干扰记忆扩库;它验证的是这种受控扩展,不是无限期真实生活档案。

现在把米拉的雇主从雪松改成白桦。 只追加新笔记,可能让两个采纳向量与近乎相同的补丁键一起竞争。 TASK检索旧候选,检查地址,再请自己的模型判断:这是同一个实体和属性的新值,还是另一件事? 判为更新,旧文本、补丁与引导一起退出生效集合。 自动判断不用数据集提供的正确事实ID,但内部记录仍保存范围、版本和替代链接。

附录C更难的版本测试,每个模型有150个已修订事实。 Qwen3-8B使用核验文本加S时,不做替代处理的旧答案比例为54.7%,自动替代后为10.0%。 没有降到零:这个更新判断器在该测试中漏掉14%的真实更新。 先让正确版本生效,才谈得上引导怎么用。

多步推理,零件的作用会换

“米拉雇主的总部在哪个国家?”把虚构例子往前推了一步,需要经过公司这个中间实体。 必要实体未必出现在原始问题里,克制向量便可能压掉有用笔记。 所以论文对多步问题只用采纳引导。

MQuAKE-CF-3k实验有200个案例、600个问题,只写入被编辑的基础事实。 表5中,只有文本的多步正确率为69.0%,成对引导反而降到62.2%。 文本加权重补丁为76.8%,文本、补丁和仅采纳引导为76.5%;预注册完整配置相对文本提升7.5个百分点。 这一路的增益来自补丁,这些数据没有建立引导额外加分的结论。 怎样分工,要看问题需要什么。

核心概念

检索到,不等于相关。 搜索命中可能在词句上很近,却属于欧文而不是米拉。 地址加了一层依赖模型的检查,但主体地址仍可能混淆同一个人的不同事实。 自由对话问题因此需要语义地址变体。

克制是在保护原回答。 它希望模型回答欧文时,接近没有米拉笔记的状态。 这能减少一种污染,却不证明原回答普遍正确;评测才会特意区分原本答对的邻近题。

改记忆,也是在改生效的计算。 文本里替换雪松,旧补丁和引导若仍有效,影响就还在。 替代处理要一同移除这些作用。 判断更新的模型若不完美,记忆系统也不会自动完美。

洞见

一条可用的记忆,既要有内容,也要有影响答案的条件。 同时检查米拉的更新有没有采用,欧文的回答有没有受污染;只看其中一个分数,就可能藏住另一个方向的失败。

TASK给出证据:共享相关性门控与成对使用规则,能改善受控事实记忆任务里的这项平衡。 同一批证据也要求按用途选零件:单事实未必要改权重,多步推理不适合同一种双向引导,版本更新则得先停用旧组件。

博导审稿

作者报告按主体或对话划分并冻结数据,预注册主要比较,每份测试集只跑一次。 置信区间从记忆世界或对话自助抽样,并不代表重复训练基础模型。 主要结构化任务使用合成反事实更新;生成答案用作者的断言匹配器评分,对话用语言模型评判,都不是基准官方评分器。 我没有独立核验代码、预测文件或注册时间线。

推广有重要例外。 Gemma-3-27B的zsRE上,文本加S相对文本的综合分差为-4.61点,95%区间-10.25到0.01,没有建立改善结论。 同一主体的多种关系也难辨:附录C记录约10%的同主体记忆混淆,单靠地址做替代还可能停用错误事实。

LoCoMo对话变体采用语义地址、文本和S,不加载事实补丁。 表7主要评判器给出34.2%正确率,约298输入词元;BM25为30.8%,299词元。 完整对话上下文用19488词元达到60.3%。 小上下文预算下的改善有用,但仍留下大量答不出的题。 AppWorld开发任务里,附录D报告几乎没有任务完整成功,部分测试通过率的引导增益也不显著。

写入还有开销:附录B用Qwen3-8B在一张A6000上测得每条记忆约25秒引导训练、4秒补丁计算,库规模测到3000条,并非百万条。 使用规则也不能验证笔记真假;原文的正确记忆前提,仍把提取与来源核验留作另一项工作。

启发

围绕同一次更新,给智能体记忆做三项相连的测试:换几种问法问米拉,再问欧文这个邻近问题,然后让米拉再变一次。 分别查采纳、污染和旧版本回答,把选到笔记与模型读完之后的行为分开。

若能访问模型激活与梯度,TASK提供了试验相关性门控和成对引导的方向。 若API不开放这些钩子,评测模式仍可迁移。 同时记写入代价,测实际应用里的问题类型,包括多步题和对话。 这些是从论文推出来的实用做法,不是已经复现的部署结果。