数学推理中思维链的形状

·

研究论文 · 2026/09/01

大型语言模型在数学推理基准上表现强劲,但其推理背后的数学技能仍未得到充分探索。我们引入SHAPE框架,通过数学教育中的两个视角分析思维链轨迹:(1)语义空间:模型对问题的数学解释(如代数、几何);(2)启发式:在这些空间中采取的数学行动(如简化问题、逆向工作)。我们首先用SHAPE分析多种模型的推理模式,发现模型使用的数学启发式比传统思维链特征更能解释最终答案的正确性;且模型倾向于在少数语义空间集中推理而非探索多个不同空间,这与人类行为一致。其次,我们利用SHAPE评估后训练是否真正提升数学能力,发现强化学习导致启发式使用的模式寻求。最后,我们通过促进多样化的启发式来后训练LLM,并证明其能有效提高准确性。总之,SHAPE为解码LLM推理提供了理论基础的诊断框架,并为数学推理的后训练开辟了新途径。代码已公开。

该论文提出了一种新颖的、有理论基础的框架来解析LLM的数学推理,不仅提供了诊断工具,还展示了通过启发式多样性进行后训练的有效性,对理解和改进LLM推理能力具有重要价值。

Large language models (LLMs) achieve strong performance on mathematical reasoning benchmarks, yet the mathematically meaningful skills underlying their reasoning remain underexplored. We introduce SHAPE, a framework that analyzes Chain-of-Thought (CoT) trajectories through two lenses developed in mathematics education: (1) semantic spaces: the model's evolving mathematical interpretations of a problem (e.g., algebraic, geometric), and (2) heuristics: the specific mathematical actions taken within those spaces (e.g., simplifying the problem, working backward). We first use SHAPE to analyze the reasoning patterns of various models. Our findings reveal that the mathematical heuristics employed by a model better explain final answer correctness than traditional CoT features. Furthermore, models are likely to reach correct solutions by concentrating their reasoning effort within a few semantic spaces rather than exploring many disparate ones -- a pattern consistent with human behavior. Next, we utilize the SHAPE lens to evaluate whether post-training truly enhances mathematical proficiency. We find that reinforcement learning induces mode-seeking in heuristic usage. Lastly, we post-train LLMs by promoting diverse heuristics and demonstrate its effectiveness in improving accuracy. Overall, SHAPE provides a theoretically-grounded diagnostic framework for decoding LLM reasoning and offers a new path toward post-training LLMs for math reasoning. The code for our model is available at https://github.com/holi-lab/SHAPE-of-CoT

阅读原文

参与讨论