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, Wayne Xin Zhao, Binbin Hu, Ziqi Liu, Zhiqiang Zhang

TL;DR

This paper demonstrates that long Chain-of-Thought (CoT) reasoning is a latent, general capability already encoded within standard Large Language Models (LLMs). The authors introduce GLoRE, a training-free representation engineering method that activates this "slow-thinking" mode across multiple domains by simply steering the model's internal hidden states during inference.

What Problem Does This Paper Address?

Recent breakthroughs in AI reasoning, such as OpenAI’s o1 and DeepSeek-R1, rely heavily on long Chain-of-Thought (long CoT) processing—allowing models to plan, validate, and backtrack before outputting a final answer. However, eliciting these capabilities typically requires intensive reinforcement learning or supervised fine-tuning on massive datasets. Furthermore, high-quality long CoT data is notoriously difficult to construct outside of easily verifiable domains like mathematics and coding.

This paper tackles a fundamental question: Is long CoT reasoning a general capability already hidden inside LLMs, and can we unlock it across various domains without expensive training or domain-specific long CoT data?

Methods

The authors first perform an empirical analysis using t-SNE dimensionality reduction to map the internal hidden states of LLMs processing both vanilla (short) CoTs and long CoTs. They discover that long CoT reasoning occupies a distinct, concentrated region in the model's parameter space, particularly within the middle layers.

Based on this insight, they propose GLoRE (General Long CoT Reasoning via Representation Engineering), a training-free framework that decouples long CoT into two components:

  1. Contrastive Reasoning Pattern Representation: The authors extract a "slow-thinking vector" by calculating the average difference between long and vanilla CoT representations in a high-resource domain (mathematics). During inference, this vector is injected into the model's first token to shift the LLM into a deliberate reasoning mode.
  2. Question-Aware Domain-Specific Representation: Because reasoning style alone isn't enough without domain knowledge, GLoRE builds a memory bank using easily obtainable vanilla CoT data from target domains. At inference time, the system retrieves the top-$k$ most relevant domain representations based on the input question and injects them into the final token position to provide precise context.
The overview of the GLoRE framework, showing how contrastive reasoning patterns and domain-specific representations are injected into the LLM.

Datasets

To extract the initial representations, the authors utilized STILL-2, a high-quality dataset distilled from DeepSeek-R1-Lite-Preview.

For evaluation, the authors tested the approach across two distinct scenarios:

  • In-domain (Mathematics): Evaluated on challenging open-source benchmarks including MATHOAI, AIME2024, and AMC2023.
  • Cross-domain (Sciences): Evaluated on the GPQA (Graduate-Level Google-Proof Q&A) dataset, specifically focusing on the highest-quality "Diamond" set across Physics, Chemistry, and Biology.

Key Insights and Ideas

  • Long CoT is a Latent State: The clear geometric separation in the latent space between vanilla and long CoT states proves that long-form reasoning is encoded as a distinct, general capability within the model.
  • The Middle-Layer Sweet Spot: Quantitative analysis using matrix-based entropy revealed that the distinct features of long CoT are most pronounced in the middle layers of LLMs, which are responsible for integrating complex, high-level concepts.
  • Style and Substance Can Be Decoupled: You do not need long CoT data for every domain to trigger long CoT reasoning. You can extract the pattern of long thinking from math data and successfully pair it with the knowledge from vanilla physics or chemistry data.

Key Results

GLoRE was evaluated using Qwen2.5-7B-Instruct and Llama3.1-8B-Instruct, yielding several impressive outcomes:

  • Outperforming Baselines and SFT: GLoRE consistently outperformed all training-free baselines (such as Few-shot CoT and specialized activation steering like RoT). Remarkably, it even surpassed Supervised Fine-Tuning (SFT) methods; on Qwen2.5-7B, GLoRE achieved an average math accuracy of 54.29% compared to SFT's 52.71%.
  • Efficiency Gains: Standard few-shot long CoT approaches suffer from massive prompt inflation, increasing computational overhead quadratically. GLoRE operates entirely in the latent space, maintaining the same $O(p^2)$ time complexity as zero-shot CoT.
  • Longer Generation Profiles: Qualitative analysis showed that injecting these representations successfully forced standard models to generate significantly more intermediate reasoning steps, effectively mimicking native "slow-thinking" models.

Limitations and Future Work

The primary limitation of GLoRE is that it is a white-box method. Because it requires direct access to and manipulation of the model's internal hidden states, it cannot be applied to closed-source models accessible only via APIs (such as OpenAI's GPT-4 or Anthropic's Claude). Additionally, due to resource constraints, the authors only validated the approach on a select set of representative open-source models and tasks. Future work could explore extending this representation steering to multimodal reasoning or broader open-ended generation tasks.

Summary updated

BibTeX
@inproceedings{tang2025unlocking,
  author = {Xinyu Tang and Xiaolei Wang and Zhihao Lv and Yingqian Min and Wayne 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