English

Dynamic Speculation Lookahead Accelerates Speculative Decoding of Large Language Models

Computation and Language 2024-11-08 v5

Abstract

Speculative decoding is commonly used for reducing the inference latency of large language models. Its effectiveness depends highly on the speculation lookahead (SL)-the number of tokens generated by the draft model at each iteration. In this work we show that the common practice of using the same SL for all iterations (static SL) is suboptimal. We introduce DISCO (DynamIc SpeCulation lookahead Optimization), a novel method for dynamically selecting the SL. Our experiments with four datasets show that DISCO reaches an average speedup of 10% compared to the best static SL baseline, while generating the exact same text.

Keywords

Cite

@article{arxiv.2405.04304,
  title  = {Dynamic Speculation Lookahead Accelerates Speculative Decoding of Large Language Models},
  author = {Jonathan Mamou and Oren Pereg and Daniel Korat and Moshe Berchansky and Nadav Timor and Moshe Wasserblat and Roy Schwartz},
  journal= {arXiv preprint arXiv:2405.04304},
  year   = {2024}
}
R2 v1 2026-06-28T16:19:27.908Z