AdaSpec: Adaptive Speculative Decoding for Fast, SLO-Aware Large Language Model Serving

Kaiyu Huang, Hao Wu, Zhubo Shi, Han Zou, Minchen Yu, Qingjiang Shi · DOI

Introduction

Speculative decoding accelerates Large Language Model (LLM) inference by using a small "draft" model to predict tokens that a larger "target" model verifies in parallel. While effective, standard implementations use a fixed speculative length—the number of tokens drafted per step. This rigidity fails to account for dynamic cloud workloads, where request rates and batch sizes fluctuate. In high-load scenarios, fixed lengths can waste compute on rejected tokens; in low-load periods, they underutilize hardware. Most critically, the unpredictable nature of token rejection leads to latency spikes that violate Service-Level Objectives (SLOs).

AdaSpec solves this by dynamically adjusting the speculative length for each request in real-time based on system load, hardware, and SLOs. This adaptive approach delivers up to 66% faster inference than state-of-the-art speculative methods while consistently meeting strict latency guarantees.

The AdaSpec Framework

AdaSpec introduces a dynamic framework that adjusts speculative decoding on the fly using three novel components:

  • Adaptive Drafter: Instead of a fixed length, this module uses a "predict-execute-correct" strategy. It evaluates draft model confidence in real-time, continuing only if the estimated efficiency of generating another token is positive.
  • Confidence Prior Verifier: To maintain efficiency in batched settings, AdaSpec decouples drafting from verification. It generates a pool of draft tokens and selectively prunes low-confidence tokens per request before sending the batch to the target model.
  • SLO-Aware Efficiency Estimator: This acts as a latency circuit breaker. It uses a mathematical model to estimate verification time; if the estimate exceeds the user-defined Time Per Output Token (TPOT) SLO, it restricts the speculative length to ensure compliance.

Key Insights

The system is built on the observation that speculative decoding throughput is a quasi-concave function of speculative length. As shown in the evaluation of different workloads, the "sweet spot" for efficiency shifts significantly based on batch size and task complexity.

Speedup across different batch sizes (BS) and tasks. The optimal speculative length (SL) shifts as batch size increases and varies by task, highlighting the need for adaptive control.

Additionally, the draft model's internal confidence score serves as a highly reliable proxy for whether the target model will accept a token, enabling accurate pre-verification pruning.

Evaluation and Results

The authors evaluated AdaSpec using production traces (BurstGPT, Mooncake) and diverse workloads from SpecBench.

Comparison of speedup and SLO attainment across different speculative lengths. Fixed lengths often lead to significant drops in SLO compliance as they increase speed, whereas AdaSpec maintains high attainment.
  • Significant Speedups: AdaSpec achieved a 1.23× to 1.79× speedup over standard autoregressive decoding and up to a 66% improvement over fixed-length speculative systems like SpecInfer.
  • Unmatched SLO Compliance: When constrained to strict TPOT limits, AdaSpec was the only method to consistently maintain an SLO satisfaction rate exceeding 90%. Baseline methods suffered severe degradation due to unmanaged latency spikes.
  • High Batch Adaptability: AdaSpec dynamically scaled its speculative length inversely to batch size, maintaining stable latency reduction even during drastic traffic fluctuations.

Conclusion

AdaSpec demonstrates that fine-grained, request-level control is essential for high-performance LLM serving. By moving from fixed to adaptive speculative decoding, systems can maximize throughput without sacrificing reliability. Future work includes improving calibration for draft models and extending these techniques to tree-based decoding architectures.

Summary updated

BibTeX
@misc{huang2025adaspec,
  author = {Kaiyu Huang and Hao Wu and Zhubo Shi and Han Zou and Minchen Yu and Qingjiang Shi},
  title = {{AdaSpec: Adaptive Speculative Decoding for Fast, SLO-Aware Large Language Model Serving}},
  year = {2025},
  eprint = {2503.05096},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2503.05096},
}
Figure