The Redundancy Reversal in Reasoning Models

DeepSeekAPIKeyFree · Updated 2026-11-24 · 11 Min read

Chart comparing redundancy levels between think and answer tokens
Visual representation of the redundancy reversal where answer tokens show higher redundancy.

When you run a reasoning model like DeepSeek-R1, the output splits into two distinct phases: the "think" phase, where the model drafts its internal logic, and the "answer" phase, where it delivers the final result. Conventional wisdom suggests that the thinking process is the complex, information-dense part, while the final answer is just a summary. However, recent research into KV cache quantization reveals a surprising truth: this assumption is backwards for distilled reasoning models.

A new study measuring pairwise cosine redundancy on distilled models found that answer-phase tokens are actually more redundant than think-phase tokens. This "redundancy reversal" means that applying uniform quantization across the entire context window is suboptimal. By misallocating bits based on old assumptions, you waste precision where it matters least and run out of capacity where it matters most.

This article explains the mechanics behind this discovery, why it breaks standard caching strategies, and how you can adjust your bit allocation to save memory and reduce latency. We also clarify the relationship between this specific model architecture and the broader DeepSeek ecosystem, noting that while the domain contains the brand, this site is not affiliated with DeepSeek.

Frequently asked questions

What is KV cache quantization?

KV cache quantization is a technique to compress the Key and Value matrices stored during model inference. Instead of storing high-precision 16-bit floats, the cache stores lower-precision values (e.g., 3-bit or 4-bit). This reduces memory usage and bandwidth, allowing larger contexts or faster batch processing, but introduces approximation errors that can degrade output quality.

What are think tokens vs answer tokens?

In reasoning models, "think tokens" represent the internal chain-of-thought or scratchpad where the model reasons through the problem. "Answer tokens" are the final, explicit output provided to the user. The think phase is often longer and more varied, while the answer phase is typically concise and direct, leading to different redundancy patterns.

How does the redundancy reversal work?

The reversal refers to the finding that answer tokens have higher redundancy (higher cosine similarity with previous tokens) than think tokens. This is opposite to what was observed in massive 671B models. Because answers are more repetitive and predictable, they require fewer bits to represent accurately compared to the complex, divergent thinking phase.

Why is uniform quantization suboptimal?

Uniform quantization applies the same bit depth (e.g., 3-bit) to all tokens in the context. If answer tokens are more redundant, they can tolerate lower bit depths better than think tokens. Uniform allocation wastes bits on the redundant answer phase and under-allocates to the complex think phase, leading to higher attention KL divergence and reduced reasoning quality.

What is the TAQG theorem?

The TAQG (Theoretical Allocation for Quantized Generation) theorem provides a mathematical framework for optimal bit allocation based on token redundancy. It suggests that bit budgets should be distributed inversely to redundancy. Higher redundancy allows for lower bit depths without significant quality loss, while low-redundancy tokens need higher precision.

How much better is aligned bit allocation?

Research shows that theory-aligned bit allocation (e.g., 4-bit for think, 3-bit for answer) can reduce attention KL divergence by 58% compared to uniform 3-bit quantization. Conversely, using the wrong direction (3-bit for think, 4-bit for answer) results in nearly twice the error, making the reasoning significantly less coherent.

Does this apply to all models?

The specific redundancy reversal was observed in distilled models like DeepSeek-R1-Distill-1.5B. Larger models like the 671B version showed different patterns. While the principle of redundancy-driven allocation is general, the exact thresholds and reversals depend on the model's training data and architecture. You must measure your specific model.

How can I test this myself?

You can replicate the findings using the open-source code and data provided in the study. It runs on a free Colab T4 GPU. You will need to measure pairwise cosine redundancy on your model's KV cache and then compare the attention KL divergence between uniform and theory-aligned quantization strategies to see the impact on your specific use case.

Understanding the KV Cache and Quantization

The Key-Value (KV) cache is a critical component in transformer-based language models. As the model processes a sequence, it stores the Key and Value vectors for each token to avoid recomputing them during subsequent steps. This cache grows linearly with context length and can consume significant GPU memory, especially for long prompts or extended reasoning chains.

Quantization reduces the memory footprint by storing these vectors in lower precision formats. For example, instead of using 16-bit floating-point numbers (FP16), a quantized cache might use 3-bit or 4-bit integers. This compression allows you to serve more requests simultaneously or handle longer contexts without hitting memory limits, but it introduces quantization error.

The Cost of Precision

Higher precision preserves the nuanced relationships between tokens, ensuring accurate attention scores. Lower precision speeds up memory access and reduces bandwidth but risks distorting the model's internal state. The goal is to find the sweet spot where memory savings do not compromise output quality.

Uniform vs. Adaptive Strategies

Uniform quantization applies the same bit depth to every token in the context. Adaptive strategies allocate bits based on the perceived importance or redundancy of each token. Uniform is simpler to implement but often suboptimal because not all tokens contribute equally to the final output.

# Example of calculating cosine similarity for redundancy estimation
import torch

def cosine_similarity(tensor_a, tensor_b):
    # Normalize tensors
    a_norm = torch.nn.functional.normalize(tensor_a, p=2, dim=1)
    b_norm = torch.nn.functional.normalize(tensor_b, p=2, dim=1)
    # Compute cosine similarity
    return torch.mm(a_norm, b_norm.transpose(0, 1)).mean().item()

The Redundancy Reversal Discovery

Traditional reasoning models, especially those scaled up to hundreds of billions of parameters, often show that the thinking phase is more complex and less redundant than the final answer. The assumption was that the model generates a lot of diverse, high-entropy tokens during reasoning, then condenses them into a repetitive, low-entropy answer.

However, research on distilled models like DeepSeek-R1-Distill-1.5B revealed a "redundancy reversal." The answer tokens were found to be more redundant (higher pairwise cosine redundancy, ρ=0.544) than the think tokens (ρ=0.463). This means the model's final output is more predictable and repetitive than its internal monologue, contrary to expectations from larger models.

Measuring Redundancy

Redundancy was measured using pairwise cosine similarity between token embeddings in the KV cache. Higher similarity indicates that tokens are more alike, allowing for greater compression. The study used open-access data to validate these metrics across different phases of generation.

Why Distilled Models Differ

Distilled models are trained to mimic the behavior of larger models but with fewer parameters. This process often streamlines the reasoning path, making the final answer more direct and less noisy. The think phase in distilled models retains enough complexity to require higher precision, while the answer phase becomes highly repetitive.

# Pseudo-code for redundancy calculation
think_tokens = get_kv_cache(phase='think')
answer_tokens = get_kv_cache(phase='answer')

redundancy_think = calculate_redundancy(think_tokens)
redundancy_answer = calculate_redundancy(answer_tokens)

print(f"Think Redundancy: {redundancy_think}")
print(f"Answer Redundancy: {redundancy_answer}")
# Output: Answer Redundancy > Think Redundancy
Memory chips illustrating bit allocation strategies
Illustration of memory chips representing different bit depths for KV cache.

Implications for Bit Allocation

If answer tokens are more redundant, they can be quantized more aggressively without significant loss of information. Conversely, think tokens, being less redundant, require higher precision to maintain the integrity of the reasoning process. This insight directly challenges the one-size-fits-all approach of uniform quantization.

By reallocating bits from the answer phase to the think phase, you can achieve better overall performance. For instance, using a 3-bit quantization for answers and a 4-bit quantization for thinking tokens can reduce the attention KL divergence by 58% compared to a uniform 3-bit allocation. This leads to more coherent and accurate reasoning outputs.

The TAQG Theorem

The TAQG theorem provides a theoretical basis for this reallocation. It suggests that bit budgets should be distributed inversely to redundancy. Tokens with higher redundancy get fewer bits, while those with lower redundancy get more, optimizing the trade-off between memory usage and accuracy.

Directional Sensitivity

The study also showed that getting the direction wrong is costly. Allocating 3-bit to think and 4-bit to answer resulted in nearly twice the error compared to the optimal 4/3 split. This highlights the importance of understanding your specific model's token distribution before deploying quantization.

# Theoretical bit allocation example
think_bit_depth = 4
answer_bit_depth = 3

# Calculate error metrics
error_uniform = calculate_error(bit_depth=3, phase='all')
error_optimal = calculate_error(think_depth=4, answer_depth=3)

print(f"Uniform Error: {error_uniform}")
print(f"Optimal Error: {error_optimal}")
# Output: Optimal Error < Uniform Error

Comparing with Large-Scale Models

It is important to note that this redundancy reversal was not observed in the full 671B parameter model. In larger models, the think phase tends to be more redundant than the answer phase, aligning with traditional assumptions. This suggests that model size and training data significantly influence token redundancy patterns.

Smaller, distilled models often have different internal representations due to their training objectives. They are optimized for efficiency and directness, which can lead to more repetitive answers. Therefore, quantization strategies should be tailored to the specific model architecture and size, rather than applying a universal rule.

Model Size Matters

Larger models have more capacity to capture diverse reasoning paths, making the think phase more complex. Smaller models may compress their reasoning more tightly, leading to higher redundancy in the final output. This distinction is crucial for selecting the right quantization approach.

Training Data Influence

The dataset used for distillation plays a role. If the training data encourages concise answers, the model will learn to produce more redundant answer tokens. Understanding the training data helps predict the redundancy profile and optimize cache quantization accordingly.

# Example of comparing model sizes
model_large = load_model('671B')
model_small = load_model('1.5B-Distill')

redundancy_large_think = measure_redundancy(model_large, 'think')
redundancy_small_think = measure_redundancy(model_small, 'think')

print(f"Large Think Redundancy: {redundancy_large_think}")
print(f"Small Think Redundancy: {redundancy_small_think}")
# Note: Patterns may differ significantly between sizes
Flowchart showing phase-based bit allocation
Diagram of the flow from think to answer phase with dynamic bit allocation.

Practical Implementation Strategies

To implement theory-aligned bit allocation, you need to segment the KV cache into think and answer phases. This can be done by detecting the end of the thinking block, often marked by specific delimiters or by monitoring the model's output distribution. Once segmented, you can apply different quantization levels to each segment.

You can use existing libraries that support dynamic quantization or write custom kernels to handle mixed-precision caching. The key is to ensure that the overhead of switching quantization levels does not outweigh the benefits. For most use cases, the memory savings and accuracy improvements justify the additional complexity.

Detecting Phase Boundaries

Identifying the boundary between think and answer tokens can be done using special tokens (e.g., <end_thinking>) or by analyzing the perplexity of the output. Once the boundary is detected, the quantization strategy can switch from high-precision to low-bit for the remaining tokens.

Optimizing for Latency

While quantization reduces memory, it can increase compute latency if not optimized. Using hardware-accelerated kernels for low-bit operations can mitigate this. The goal is to balance memory savings with minimal latency impact, ensuring that the model remains responsive even with complex reasoning tasks.

# Pseudo-code for phase-based quantization
cache = get_kv_cache()
think_end_index = detect_think_end(cache)

# Apply different quantization
think_cache = quantize(cache[:think_end_index], bits=4)
answer_cache = quantize(cache[think_end_index:], bits=3)

# Combine for inference
combined_cache = merge_cache(think_cache, answer_cache)
output = generate(combined_cache)

Cost Efficiency and Scalability

By optimizing bit allocation, you can significantly reduce the memory required for KV caching. This allows you to serve more concurrent requests on the same hardware or handle longer contexts without increasing infrastructure costs. For businesses running large-scale inference, these savings can translate to substantial operational cost reductions.

Scalability is another key benefit. With optimized quantization, you can deploy reasoning models on edge devices or smaller GPUs, making advanced reasoning capabilities accessible in resource-constrained environments. This opens up new use cases for real-time, low-latency applications that previously required expensive cloud instances.

Reduced Infrastructure Costs

Lower memory usage means you can pack more models into a single GPU or use cheaper, less powerful hardware. This reduces the capital expenditure on GPUs and the operational expenditure on cloud services, making AI inference more affordable for a wider range of applications.

Enhanced User Experience

Faster inference and lower latency improve the user experience, especially in interactive applications. Users perceive the model as more responsive and capable, leading to higher engagement and satisfaction. The trade-off between quantization error and latency must be carefully managed to maintain quality.

# Calculate memory savings
memory_uniform = calculate_memory(bits=3, context_length=10000)
memory_optimal = calculate_memory(think_bits=4, answer_bits=3, context_length=10000)

savings = memory_uniform - memory_optimal
print(f"Memory Savings: {savings} MB")
# Output: Significant savings with optimal allocation
Code editor showing Python script and error graph
Example of code implementation for measuring redundancy and error.

Limitations and Future Directions

While the redundancy reversal is a significant finding, it is specific to distilled models. Larger, base models may still exhibit traditional redundancy patterns. Therefore, it is essential to validate these findings on your specific model before deploying optimized quantization strategies. Blindly applying 4/3 bit allocation could worsen performance on non-distilled models.

Future research may explore dynamic bit allocation based on real-time token entropy, rather than static phase-based segmentation. Additionally, combining quantization with other compression techniques like pruning or low-rank adaptation could further enhance efficiency. The field is evolving rapidly, and staying updated with new benchmarks is crucial.

Model-Specific Validation

Always test quantization strategies on your specific model variant. Small differences in training data or architecture can lead to different redundancy profiles. Automated benchmarking tools can help you find the optimal bit allocation for your use case without manual trial and error.

Emerging Techniques

Hybrid approaches that combine quantization with sparsity or low-rank methods are showing promise. These techniques can achieve even greater compression rates while maintaining accuracy. Keep an eye on new papers and open-source implementations for the latest advancements in KV cache optimization.

# Example of hybrid optimization
quantized_cache = quantize(cache, bits=3)
pruned_cache = prune(quantized_cache, threshold=0.1)
lr_cache = low_rank_approx(pruned_cache, rank=16)

# Compare with uniform
uniform_cache = quantize(cache, bits=3)

print(f"Hybrid Size: {get_size(lr_cache)}")
print(f"Uniform Size: {get_size(uniform_cache)}")
# Output: Hybrid approach may offer additional savings

Conclusion and Recommendations

The discovery of redundancy reversal in distilled reasoning models challenges conventional wisdom about KV cache quantization. By recognizing that answer tokens are more redundant than think tokens, you can optimize bit allocation to improve accuracy and reduce memory usage. This approach is particularly effective for smaller, distilled models but should be validated for your specific use case.

Implementing theory-aligned bit allocation requires careful segmentation and testing, but the benefits in cost efficiency and scalability are significant. As the field of AI inference continues to evolve, staying informed about these nuances will help you make better decisions about model deployment and resource management. For more insights on API usage and model selection, explore our other articles on DeepSeek API options and reasoning vs expert modes.

Actionable Steps

Start by measuring the redundancy of your model's KV cache. Use open-source tools to replicate the study's findings, then experiment with 4/3 bit allocation. Monitor the attention KL divergence to ensure quality improvements. This data-driven approach will guide your quantization strategy.

Stay Updated

The research is ongoing, and new models may exhibit different patterns. Regularly review literature and benchmark results to keep your inference pipeline optimized. Join communities and forums to share insights and learn from others' experiences with quantization and caching strategies.

# Final recommendation summary
recommendation = "Use 4-bit for think, 3-bit for answer in distilled models."
print(recommendation)
# Validate on your specific model before full deployment
Scale balancing memory usage and model quality
Balance between memory efficiency and model quality in quantization.
Try the free API

Test a bot reply before writing any code using our keyless DeepSeek API access.

Read also