arXiv:2503.13431cs.LG2025-03ICML被引 4

用隐藏状态预测衡量模型上下文计算复杂度,更准确识别真正有意义的推理。

Measuring In-Context Computation Complexity via Hidden State Prediction

  • 通过预测自身隐藏状态来评估计算复杂度,避开传统损失函数的误导。
  • 在形式语言、数学推理等任务中,该指标与问题难度和推理正确率高度相关。
  • 适用于研究模型内部推理机制,尤其适合关注推理过程可解释性的研究者。

检测神经序列模型何时进行‘有意义’的计算仍是开放问题。传统的下一个词预测损失表现不佳:低损失可能来自极易预测的序列(无意义),而高损失也可能源于无关紧要的不可预测信息。本文提出一种新度量方法:通过衡量模型预测自身未来隐藏状态的能力来评估计算复杂度。我们实证表明,该指标相比传统损失,更能反映任务的直观有趣程度。为此,我们引入了不依赖架构的‘隐藏状态预测’(PHi)层,作为网络主路径(如Transformer的残差流)上的信息瓶颈。同时提出一种新的可学习先验,用于量化每一步计算所获得的新信息量,作为核心度量。实验显示,该指标能有效预测上下文学习中形式语言的描述长度、数学推理问题的复杂度,以及自生成推理链的正确性。

原文摘要 · Abstract (English)

Detecting when a neural sequence model does "interesting" computation is an open problem. The next token prediction loss is a poor indicator: Low loss can stem from trivially predictable sequences that are uninteresting, while high loss may reflect unpredictable but also irrelevant information that can be ignored by the model. We propose a better metric: measuring the model's ability to predict its own future hidden states. We show empirically that this metric -- in contrast to the next token prediction loss -- correlates with the intuitive interestingness of the task. To measure predictability, we introduce the architecture-agnostic "prediction of hidden states" (PHi) layer that serves as an information bottleneck on the main pathway of the network (e.g., the residual stream in Transformers). We propose a novel learned predictive prior that enables us to measure the novel information gained in each computation step, which serves as our metric. We show empirically that our metric predicts the description length of formal languages learned in-context, the complexity of mathematical reasoning problems, and the correctness of self-generated reasoning chains.

模型解释推理复杂度隐藏状态可解释性

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。