NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Unlocking General Long Chain-of-Thought Reasoning Capabilities of Large Language Models via Representation Engineering

Xinyu Tang, Xiaolei Wang, Zhihao Lv, Yingqian Min, Xin Zhao, Binbin Hu, Ziqi Liu, Zhiqiang Zhang · DOI

TL;DR

This paper investigates whether "long chain-of-thought" (long CoT) reasoning is a general capability within Large Language Models (LLMs). They propose GLORE, a novel representation engineering technique that effectively unlocks this capability without requiring extensive task-specific fine-tuning, demonstrating significant performance gains in both in-domain and cross-domain reasoning tasks.

What Problem Does This Paper Address?

Large Language Models (LLMs) have shown remarkable improvements in reasoning tasks, particularly with the advent of "long chain-of-thought" (long CoT) prompting. This approach involves more elaborate reasoning processes, including planning, validation, and backtracking, leading to better performance on complex problems. While existing research suggests that long CoT capabilities can be elicited with relatively few examples and even transfer to new tasks, a fundamental question remains: is long CoT reasoning an inherent, general capability of LLMs, or is it primarily task-specific? This paper aims to answer this by analyzing how LLMs represent long CoT reasoning internally and proposes a method to leverage this potential.

Methods

The authors propose GLORE (General Long CoT Reasoning Engineering), a training-free method based on representation engineering. GLORE has two main components:

  1. Contrastive Reasoning Pattern Representation: This component aims to transition the LLM from a "vanilla" (short, direct) reasoning mode to a "long CoT" reasoning mode. It achieves this by extracting representations of long CoT patterns from high-resource domains (like mathematics) and then injecting these into the LLM's intermediate layers. This is done by taking the difference between the representations of long CoT and vanilla CoT examples.
  2. Question-Aware Domain-Specific Representation: Recognizing that general reasoning patterns alone are insufficient, this component injects domain-specific information. It constructs a "representation memory" using vanilla CoT data from various domains. At inference time, representations relevant to the specific question are retrieved from this memory and injected into the LLM, specifically at the final token position to influence subsequent generation.

Datasets

The paper utilizes the following datasets:

  • STILL-2: An open-source dataset containing vanilla and long CoTs, distilled from DeepSeek-R1-Lite-Preview. This dataset was used to sample 100 examples from mathematics, physics, chemistry, and biology domains for analysis and experimentation.
  • Mathematical Benchmarks (In-domain): MATHOAI, AIME2024, and AMC2023 were used for evaluating performance on mathematical reasoning tasks.
  • GPQA (Cross-domain): A challenging multiple-choice benchmark for physics, chemistry, and biology, used for cross-domain evaluation.

Key Insights and Ideas

  • Long CoT is a General Capability: The paper provides empirical evidence that LLMs encode long CoT reasoning as a distinct and general capability within their parameter spaces, separate from vanilla CoTs. This is visualized by distinct clusters of representations in the model's latent space.
  • Domain-Specific Information is Crucial for Transfer: While long CoT reasoning itself is general, effective transfer to new tasks requires domain-specific information. The authors observe that mathematical domains have more concentrated representations, suggesting a reliance on logical patterns, whereas other domains are more dispersed, indicating a need for specific knowledge.
  • Representation Engineering as a Solution: GLORE demonstrates that by strategically engineering representations, we can unlock and guide LLMs towards more deliberate, step-by-step reasoning without costly fine-tuning.
  • Decoupling Reasoning: The core idea of GLORE is to decouple general reasoning patterns from domain-specific knowledge, allowing for more flexible and efficient activation of long CoT capabilities.

Key Results

  • Performance Gains: GLORE consistently outperforms various baselines, including zero-shot CoT, few-shot CoT, BoostStep, MathNeuro, and RoT, in both in-domain (mathematics) and cross-domain (GPQA) scenarios.
  • Efficiency: GLORE achieves this performance enhancement while maintaining the same time complexity as zero-shot CoT, significantly outperforming methods that increase inference time (e.g., few-shot CoT, BoostStep).
  • Ablation Study: Removing either the contrastive reasoning pattern representation or the question-aware domain-specific representation leads to performance degradation, highlighting the importance of both components.
  • Hyperparameter Sensitivity: The method shows optimal performance with specific injection strengths (around 0.1) and a moderate number of retrieved domain-specific representations (around 8), indicating a balance between intervention and preserving original model capabilities.
  • Case Study: A specific example illustrates how GLORE guides the LLM to generate more intermediate reasoning steps, avoiding calculation errors that plague simpler methods.

Limitations and Future Work

  • Closed-Source LLMs: A significant limitation is that GLORE requires access to the internal representations of LLMs, making it infeasible for closed-source models.
  • Limited Scope: The authors acknowledge that their experiments were conducted on representative tasks and LLMs due to cost and resource constraints.

Future work could explore extending GLORE to a wider range of tasks and LLMs, and investigating methods to adapt representation engineering for closed-source models.

Summary updated

BibTeX
@inproceedings{tang2025unlocking,
  author = {Xinyu Tang and Xiaolei Wang and Zhihao Lv and Yingqian Min and Xin Zhao and Binbin Hu and Ziqi Liu and Zhiqiang Zhang},
  title = {{Unlocking General Long Chain-of-Thought Reasoning Capabilities of Large Language Models via Representation Engineering}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2025},
}
Figure