Speculative Inference
Speculative Inference (draft-and-verify) accelerates large language model generation by utilizing a smaller Draft Model to propose multiple candidate tokens, which are validated in parallel by a larger Target Model. This method reduces inference latency and computational cost by amortizing the verification step across tokens, yielding efficiency gains proportional to the token acceptance rate.
Mechanism
- Speculation: Draft model generates tokens sequentially with minimal compute overhead.
- Verification: Target model processes the entire sequence in a single forward pass to verify token probabilities.
- Decision: Accepted tokens are appended; rejected tokens trigger backtracking or fallback gen
Implementations & Case Studies
- DeepSeek DSpark: A specialized speed layer for LLMs introduced by DeepSeek that enhances speculative decoding performance.
- Demonstrated ability to double inference speed for Qwen3 models.
- Acts as an acceleration layer without requiring full model retraining.
- See: DeepSeek DSpark: LLM Inference Acceleration via Enhanced Speculative Decoding