Files
myWiki/concepts/logical-model-interaction.md

2.1 KiB
Raw Blame History

title, created, updated, type, tags, sources
title created updated type tags sources
交互逻辑模型 (Logical Model of Interactions) 2026-06-03 2026-06-03 concept
interactions
logical-model
DNN
LLM
interpretability
zhang-reconciling-sft-interaction-2026

交互逻辑模型 (Logical Model of Interactions)

定义

交互逻辑模型 \phi(\cdot) 是由 and-or-interactions 构建的、用于逼近 DNN 输出分数的可解释模型。给定输入 $x'$

\phi(x') = \sum_{T \in \Omega^{\text{and}}} I_T^{\text{and}} \cdot \mathbb{1}(\text{AND}_T) + \sum_{T \in \Omega^{\text{or}}} I_T^{\text{or}} \cdot \mathbb{1}(\text{OR}_T) + b

关键性质

通用匹配性 (Universal Matching Property)

逻辑模型可以在所有 2^n 个掩码状态上以 \epsilon 精度逼近原 LLM 输出:

\forall x' \in \Psi, \quad |\phi(x') - v(x')| < \epsilon

其中 \Psi = \{x_S \mid S \subseteq N\}2^n 个掩码状态的空间。

LLM 输出分数的定义

在 LLM 语境下,输出分数 v(x) 定义为生成目标 token 序列的置信度:

v(x) = \sum_{i=1}^{m} \log \frac{p(y = y_i \mid x, y_i^{\text{preceding}})}{1 - p(y = y_i \mid x, y_i^{\text{preceding}})}

在 SFT 分析中的角色

zhang-reconciling-sft-interaction-2026 中,逻辑模型是追踪 SFT 过程中交互演变的基础工具:

  1. 在每个 SFT 时间点 $t$,从 LLM 中提取 AND-OR 交互构建 \phi_t
  2. 比较 \phi_t 与 $\phi_{t-1}$,识别 interaction-types-sft 的变化
  3. 计算 interaction-generalizabilityuncancelled-interaction-effects 评估交互质量

计算考量

交互提取的计算复杂性与 Shapley 值类似指数级但已有多种近似算法和工程优化使其在实际中可用。LLM 通常仅关注少量显著文本段,进一步降低了计算成本。

相关概念