Skip to content
Optimization

Speculative Decoding

Latency technique where a small draft model proposes token sequences the target model verifies in parallel, typically cutting TTFT/latency by 2–3×.

Definition

Speculative decoding (Leviathan et al., 2022; Chen et al., 2023) uses a small, fast draft model to speculatively generate K candidate tokens, then runs the larger target model on all K+1 positions in a single parallel forward pass for verification. Accepted tokens are kept; the first rejected token and all after it are discarded, and a single corrected token is generated. Because accepted tokens require no extra compute beyond the verification pass, throughput and latency improve dramatically when the draft acceptance rate is high (typically 70–80% on aligned tasks).

More Optimization terms