Interpreting Model Reasoning through Behavioral Counterfactuals

📄 arXiv: 2610.30630v1 📥 PDF

作者: Shawn Im, James Oldfield, Adel Bibi, Sharon Li

分类: cs.LG, cs.AI

发布日期: 2026-10-22


💡 一句话要点

提出行为反事实方法以解析模型推理过程

🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)

关键词: 模型推理 行为反事实 干预分析 自然语言处理 可解释性

📋 核心要点

  1. 核心问题:现有方法难以系统性地比较模型推理,因响应的变异性使得干预效果难以隔离。
  2. 方法要点:提出通过行为反事实分析干预如何影响模型推理,训练模块以最小化KL散度。
  3. 实验或效果:在Gemma-4-E4B-it和DeepSeek-R1-0528-Qwen3-8B的案例研究中,识别出建议对模型推理的影响。

📝 摘要(中文)

随着模型能力的提升,理解模型形成思维链的内部过程变得愈发重要。然而,由于采样响应的变异性,这一过程仍然具有挑战性。本文提出了一种通过行为反事实来定位和分析干预对模型推理影响的方法:在固定响应的情况下,如何通过引入干预改变下一个token的分布。我们训练了一个模块来编辑残差流,以最小化固定响应下源提示与其反事实目标提示的输出分布之间的KL散度。实验结果表明,匹配输出分布比标准激活重建目标更有效地恢复反事实行为,并且训练模块输出的归因有效识别了反事实恢复的重要因果位置。

🔬 方法详解

问题定义:本文旨在解决如何理解模型推理过程中的干预效果,现有方法因响应变异性难以有效比较和分析。

核心思路:通过行为反事实的方法,分析在固定响应下,干预如何改变下一个token的分布,从而揭示模型的推理过程。

技术框架:整体架构包括训练一个模块来编辑残差流,目标是最小化源提示和反事实目标提示下的输出分布之间的KL散度。主要模块包括干预分析模块和归因映射模块。

关键创新:最重要的技术创新在于通过匹配输出分布来更有效地恢复反事实行为,相较于传统的激活重建目标,提供了更准确的推理分析。

关键设计:在训练过程中,采用KL散度作为损失函数,设计了特定的网络结构以优化残差流的编辑,确保能够有效捕捉到干预的因果影响。

🖼️ 关键图片

fig_0
fig_1
fig_2

📊 实验亮点

实验结果显示,所提出的方法在Gemma-4-E4B-it和DeepSeek-R1-0528-Qwen3-8B上有效识别了干预的影响,尤其是在未明确提及的情况下,能够显著改变模型的推理框架和最终答案,提升了模型的解释能力。

🎯 应用场景

该研究的潜在应用领域包括自然语言处理、模型解释性和人机交互等。通过理解模型的推理过程,能够提升模型的透明度和可解释性,进而在实际应用中增强用户的信任和接受度。未来,该方法有望被广泛应用于各种需要模型决策透明度的场景。

📄 摘要(原文)

Faithfully understanding the internal process that occurs as models form their chain of thought is an important problem with the rise in model capabilities. However, this remains challenging due to the variance in sampled responses, making it difficult to isolate the effects of interventions and compare model reasoning systematically. We propose a method for localizing and analyzing how a given intervention affects the model's reasoning through behavioral counterfactuals: given a fixed response, how does introducing an intervention to the prompt change the next-token distributions? We train a module to edit the residual stream such that it minimizes the KL divergence between the output distributions for a fixed response under a source prompt and its counterfactual target prompt. We find that matching the output distributions recovers the counterfactual behavior more effectively than standard activation reconstruction objectives and validate that attribution of the trained module outputs is effective for identifying causally important locations for counterfactual recovery. The attribution maps and visualizations of the downstream effects of model edits provide an interface for generating hypotheses about the original model's computation, which can then be tested with activation patching. In a case study on Gemma-4-E4B-it and DeepSeek-R1-0528-Qwen3-8B, we investigate how a suggestion influences model reasoning even when it is not verbally acknowledged. Our analysis identifies representations at the question statement and filler tokens that mediate a substantial part of the suggestion's influence, with downstream effects such as changing the framing of the justification or even the final answer.