Distilling Reasoning Ability From Large Language Models With Adaptive Thinking

Xiaoshu Chen, Sihang Zhou, Ke Liang, Xinwang Liu

TL;DR

Endowing small language models (SLMs) with reasoning often involves "pre-thinking"—generating a rationale before an answer—which makes them highly sensitive to minor internal errors. This paper introduces the Adaptive Thinking Mechanism (ATM), a hybrid approach that allows models to choose between thinking before or after answering based on question complexity, significantly improving accuracy and boosting inference speed by up to 50x.

What Problem Does This Paper Address?

Chain-of-Thought (CoT) distillation aims to transfer the reasoning "muscles" of giant models like GPT-4 to smaller, more efficient SLMs. The standard paradigm is pre-thinking: the model generates a step-by-step rationale and then the final answer.

However, SLMs suffer from a "rationale-sensitive problem." Because the answer is conditioned on the rationale, a single minor hallucination or logical slip in the thinking process often leads to an incorrect final answer. Furthermore, pre-thinking is computationally expensive during inference, as the model must generate a long string of text before reaching the actual result.

Methods

The authors propose two key innovations to move beyond standard pre-thinking:

  1. Post-thinking Mechanism: The model is trained to generate the Answer first, followed by the Rationale. This decouples the answer's correctness from potential errors in the rationale. Interestingly, the rationale here acts as an "error amplifier"—if the model gives a wrong answer, it generates a nonsensical rationale to justify it, leading to a higher training loss that forces the model to focus more on these "hard" samples.
  2. Adaptive Thinking Mechanism (ATM): Recognizing that complex problems do benefit from pre-thinking, ATM uses a Perception Module based on soft prompt tuning. This module evaluates the complexity of an incoming question and prepends a "soft prompt" that tells the model whether to answer immediately (post-thinking) or reason first (pre-thinking).
Comparison of different CoT-distillation mechanisms.

The architecture, shown in Figure 2, uses a cross-attention block to fuse question features (like word count) with learnable query tokens to decide the optimal thinking mode.

Illustration of the ATM architecture.

Datasets

The researchers evaluated their approach across 12 complex reasoning datasets categorized into four groups:

  • Arithmetic: SingleEq, AddSub, MultiArith, GSM8K, Aqua, Svamp.
  • Symbolic Reasoning: Last Letter Concatenation, Coin Flip.
  • Common Sense: CommonSenseQA, StrategyQA.
  • Logical/Other: Date Understanding, Track Shuffled Objects.

They used GPT-3.5-Turbo and GLM4 as "teacher" models to generate rationales for training student models like GPT2-Large and T5-Large.

Key Insights and Ideas

  • The Error Amplifier Effect: In post-thinking, when a model predicts an incorrect answer, it attempts to justify that error with an unusual rationale. This creates a much larger gap in the loss function compared to pre-thinking, where the loss for correct and incorrect samples stays relatively close. This "amplified" loss drives the model to master difficult samples more effectively.
  • Fast vs. Slow Thinking: ATM mimics the dual-process theory of human cognition. Simple questions are handled by "System 1" (fast, post-thinking), while complex ones trigger "System 2" (slow, analytical pre-thinking).
  • Attention Sparsity: Visualization shows that in pre-thinking, the model's attention is often "lost" in its own generated rationale. Post-thinking allows the model to maintain a clearer focus on the original question tokens.
Attention visualization showing how pre-thinking compresses question info vs. post-thinking.

Key Results

  • Superior Accuracy: ATM consistently outperformed both standard pre-thinking and post-thinking across almost all 12 datasets. For example, on the MultiArith task with GPT2-Large, ATM achieved 25.55% accuracy compared to pre-thinking's 20.55%.
  • Massive Speedup: Because post-thinking allows the system to stop generation immediately after the answer is produced, it is at least 50 times faster during inference than pre-thinking for tasks where reasoning isn't strictly required first.
  • Plug-and-Play: The mechanism is orthogonal to other distillation methods (like SCOTT or Specializing) and can be added to them to further boost their performance.

Limitations and Future Work

  • Training Overhead: ATM requires an initial phase of training two separate models (one pre-thinking, one post-thinking) to label the dataset for the perception module, which increases the total training time.
  • Teacher Bias: The quality of the student is still capped by the quality of the teacher's rationales. The authors noted that even "teacher" LLMs like GPT-3.5 make intermediate reasoning errors that the student then inherits.
  • Future Directions: The authors suggest exploring multi-LLM teacher frameworks (like multi-agent debate) to generate higher-quality, less biased rationales for distillation.

Summary updated

BibTeX
@article{chen2025distilling,
  author = {Xiaoshu Chen and Sihang Zhou and Ke Liang and Xinwang Liu},
  title = {{Distilling Reasoning Ability From Large Language Models With Adaptive Thinking}},
  journal = {IEEE Trans. Neural Networks Learn. Syst.},
  year = {2025},
  doi = {10.1109/tnnls.2025.3591266},
}
Figure