Abstract
Chain-of-Thought (CoT) reasoning has significantly improved the performance of Large Language Models (LLMs) on complex tasks, but it introduces a substantial "reasoning tax" in the form of increased latency and computational cost. We present TokenSkip, a novel fine-tuning framework that enables LLMs to selectively skip unimportant tokens during reasoning. By learning to generate shortcuts between critical logical steps, TokenSkip allows for controllable compression of reasoning chains. Our results show that models can reduce token usage by up to 40% with negligible performance loss, providing a scalable solution for efficient LLM inference.
Introduction
The advent of Chain-of-Thought (CoT) prompting has revolutionized the way LLMs handle multi-step reasoning. However, because LLMs generate text autoregressively, longer reasoning chains lead to a linear increase in time and memory usage. With the latest generation of models pushing CoT lengths into the thousands of tokens, this "reasoning tax" has become a major bottleneck for real-time applications and cost-effective deployment.
TokenSkip addresses a fundamental question: Is every token in a reasoning chain necessary for reaching the correct answer? By identifying and removing "filler" tokens—linguistic scaffolding that does not contribute to the logical core—TokenSkip enables models to internalize reasoning shortcuts. This approach moves beyond simple conciseness prompts, teaching the model to dynamically adjust its reasoning density based on user requirements.
Methodology
The TokenSkip pipeline consists of three distinct stages designed to facilitate controllable compression:
- Token Importance Analysis: The researchers utilize LLMLingua-2, a small bidirectional model, to assign semantic importance scores to every token in existing CoT trajectories. Analysis reveals that while mathematical equations and final numerical values are high-importance, connectors such as "so," "the," or "of" are often redundant to the underlying logic.
- Data Pruning: High-quality CoT datasets are pruned to various compression ratios (denoted as $\gamma$). For instance, a ratio of 0.7 retains only the top 70% of tokens based on their importance scores.
- Controllable Fine-Tuning: The target LLM is fine-tuned using Low-Rank Adaptation (LoRA) on this pruned data. A critical feature of this stage is the inclusion of the desired compression ratio as a prefix in the prompt (e.g.,
[Question] [Ratio]). This teaches the model to generate reasoning chains at the specified density on the fly.
Experimental Results
Efficiency and Accuracy
The authors evaluated TokenSkip across several benchmarks, including GSM8K, MATH-500, and MMLU-STEM. The results demonstrate a highly favorable trade-off between efficiency and accuracy:
- Qwen2.5-14B-Instruct: On the GSM8K benchmark, the model reduced reasoning tokens by 40% (from 313 to 181 tokens) with a performance drop of less than 0.4%.
- LLaMA-3.1-8B-Instruct: On the MATH-500 dataset, the method achieved a 30% reduction in tokens with a performance decline of less than 4%, resulting in a 1.4x inference speedup.
Comparison to Baselines
TokenSkip significantly outperforms brute-force methods. While simple truncation (cutting off the end of a response) causes accuracy to plummet by nearly 80% at high compression levels, TokenSkip maintains robust logic even when half the tokens are removed. This suggests the model is not just shortening the output but is actively restructuring the reasoning path.
Key Insights
The "Zip" Effect
In a notable side-experiment, the researchers found that an LLM can successfully restore a full, human-readable CoT from a TokenSkip-compressed version. This implies that the compressed output functions like a "zip file," containing all the necessary logical markers required to reconstruct the full reasoning process.
Scaling and Controllability
The study found that larger models (e.g., 14B parameters) are significantly more adept at learning these reasoning shortcuts than smaller models (3B). Furthermore, because the compression ratio is a prompt parameter, developers can adjust the model's behavior based on the use case—using high compression for rapid previews and low compression for high-stakes, verified answers.
Limitations and Future Work
While effective, TokenSkip's current implementation is limited by the scale of models tested (up to 14B) and the domain-generality of the importance scorer. Future research may involve fine-tuning importance scorers for specific domains like advanced mathematics or applying TokenSkip to "native" long-reasoning models that generate tens of thousands of tokens. These directions represent a promising frontier for further reducing the computational overhead of advanced AI reasoning.
Summary updated