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

Speculative Decoding with Big Little Decoder

Sehoon Kim, Karttikeya Mangalam, Suhong Moon, Jitendra Malik, Michael W. Mahoney, Amir Gholami, Kurt Keutzer

TL;DR

This paper introduces Big Little Decoder (BiLD), a novel framework that significantly speeds up text generation from large language models (LLMs) by using a small, fast model for most of the work and a larger, more powerful model only when necessary. BiLD achieves impressive latency improvements (up to 2.12x) with minimal impact on generation quality, making LLMs more practical for real-time applications.

What Problem Does This Paper Address?

Large Language Models (LLMs) have revolutionized Natural Language Processing, but their immense size leads to slow inference times, especially for autoregressive tasks like text generation. In these tasks, models generate text token by token, with each new token depending on the previous ones. This sequential process limits parallelization and makes LLMs expensive and impractical for real-time applications. Existing methods to speed up inference often require complex training strategies or model modifications, which are not always feasible.

Methods

BiLD tackles this problem by employing a "big little" decoder strategy. It uses two Transformer models: a small, fast model and a large, powerful model.

  • Collaborative Generation: The small model generates text autoregressively (token by token) for the majority of the sequence, leveraging its low inference cost.
  • Selective Refinement: The large model is invoked only when the small model is uncertain about its prediction or makes an inaccurate one. Crucially, when the large model is called, it can perform non-autoregressive (parallel) generation for the subsequent tokens, significantly boosting speed.
  • Fallback Policy: The small model decides when to hand over control to the large model if its prediction confidence falls below a predefined threshold.
  • Rollback Policy: If the large model takes over, it can also review previous tokens generated by the small model. If it detects a significant deviation, it "rolls back" and corrects the small model's inaccurate predictions, preventing cascading errors.
  • Model Prediction Alignment (Optional): To further improve performance and reduce unnecessary rollbacks, an optional step involves fine-tuning the small model on data generated by the large model. This aligns their prediction styles.

The framework is designed to be "plug-and-play," meaning it can be applied to existing LLMs without requiring changes to their training process or architecture.

Datasets

The authors evaluated BiLD on several standard datasets for text generation tasks:

  • Machine Translation:
    • IWSLT 2017 De-En
    • WMT 2014 De-En
  • Summarization:
    • XSUM
    • CNN/DailyMail

Key Insights and Ideas

  • The "Just-in-Time" Large Model: The core idea is that LLMs don't need to be fully engaged for every single token. A smaller model can handle most of the generation, and the powerful, slower model is only brought in for critical corrections.
  • Confidence as a Trigger: Using the small model's prediction confidence as a signal to invoke the large model is an effective and computationally cheap way to decide when to switch.
  • Rollback Prevents Catastrophe: The rollback policy is crucial. It not only corrects errors but also prevents a single mistake from derailing the entire generated sequence, leading to better overall quality.
  • Non-Autoregressive Power: When the large model is invoked, its ability to generate tokens non-autoregressively is key to achieving significant speedups, even if the total number of computations (FLOPs) doesn't decrease. The benefit comes from better hardware utilization.
  • Plug-and-Play Simplicity: The fact that BiLD can be applied without retraining or modifying existing LLMs is a major practical advantage.

Key Results

BiLD demonstrated significant improvements in inference speed across various tasks and models:

  • Speedup: Achieved speedups of up to 2.12x on an NVIDIA T4 GPU with minimal generation quality degradation.
  • Quality Preservation: Even with substantial speedups, BiLD maintained comparable or slightly better generation quality (measured by BLEU for translation and ROUGE-L for summarization) compared to using the large model alone.
  • Unaligned vs. Aligned: The "aligned" version of BiLD (with the optional prediction alignment step) showed consistent improvements over the "unaligned" version.
  • Ablation Studies: Both the fallback and rollback policies were shown to be critical components for BiLD's effectiveness. Removing either policy led to significant performance degradation.
  • Comparison to Speculative Decoding: BiLD outperformed existing speculative decoding methods, achieving better latency-performance trade-offs due to its non-random rollback and dynamic fallback window size.

Limitations and Future Work

  • Model Size Discrepancy: The paper notes that while BiLD works well with models differing by an order of magnitude in size, the effectiveness might depend on the specific models and tasks.
  • Vocabulary Alignment: The authors mention that discrepancies in vocabulary between the small and large models can lead to unnecessary rollbacks. The prediction alignment method helps mitigate this, but it's an additional step.
  • Future Work: The paper suggests that BiLD's extensibility to early exiting strategies (using parts of a large model as the small model) is a promising direction. They also highlight the potential for further optimization by exploring dynamic window sizes and more sophisticated alignment techniques.

Summary updated

BibTeX
@inproceedings{kim2023speculative,
  author = {Sehoon Kim and Karttikeya Mangalam and Suhong Moon and Jitendra Malik and Michael W. Mahoney and Amir Gholami and Kurt Keutzer},
  title = {{Speculative Decoding with Big Little Decoder}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=EfMyf9MC3t},
}
Figure