Organizations: Key Laboratory of Multimedia Trusted Perception and Efficient Computing, Ministry of Education of China, Xiamen University, 361005, P.R. China · Institute of Artificial Intelligence (TeleAI), China Telecom · Shanghai Innovation Institute · University of Science and Technology of China (USTC)
Speculative decoding accelerates LLM inference but suffers from performance degradation when target models are fine-tuned for specific domains. A naive solution is to retrain draft models for every target model, which is costly and inefficient. To address this, we introduce a parameter- and data-efficient framework named Efficient Draft Adaptation, abbreviated as EDA, for efficiently adapting draft models. EDA introduces three innovations: (1) a decoupled architecture that utilizes shared and private components to model the shared and target-specific output distributions separately, enabling parameter-efficient adaptation by updating only the lightweight private component;(2) a data regeneration strategy that utilizes the fine-tuned target model to regenerate training data, thereby improving the alignment between training and speculative decoding, leading to higher average acceptance length;(3) a sample selection mechanism that prioritizes high-value data for efficient adaptation. Our experiments show that EDA effectively restores speculative performance on fine-tuned models, achieving superior average acceptance lengths with significantly reduced training costs compared to full retraining. Code is available at https://github.com/Lyn-Lucy/Efficient-Draft-Adaptation.
Figures & tables
Figure 1: The comparison of average acceptance length on GSM8K under different draft-target pairings. We refer to the target models as TBase (Qwen2.5-7B) and TMath (Qwen2.5-Math-7B). The target model TBase ’s draft model DBase achieves high average acceptance length when paired together ( DBase→TBase ), while suffers a substantial acceptance drop when paired with TMath ( DBase→TMath ). Our EDA framework can restore performance through efficient, lightweight adaptation.
Figure 2: The EDA framework for efficient draft model adaptation, combining shared–private draft decomposition, domain-specific self-generation, and representation-shift–based data selection to restore speculative decoding performance with minimal training cost.
GSM8K
AIME_2024
SVAMP
Hendrycks-MATH
MathQA
Avg
Method
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
Temperature T=0
Training-Free
1.17
0.85 ×
1.18
0.76 ×
1.19
0.85 ×
1.20
0.82 ×
1.23
0.91 ×
1.19
0.84 ×
Full-FT
4.37
2.88 ×
5.05
3.14 ×
4.40
2.91 ×
4.98
3.23 ×
4.66
3.19 ×
4.69
3.07 ×
LoRA
4.32
2.84 ×
4.90
2.93 ×
4.36
2.75 ×
4.92
3.18 ×
4.55
3.00 ×
4.61
2.94 ×
EDA (Base)
4.40
2.89 ×
5.02
3.12 ×
4.42
2.92 ×
5.00
3.24 ×
4.70
3.16 ×
4.71
3.07 ×
Table 1: Main results on five math tasks (GSM8K, AIME_2024, SVAMP, Hendrycks-MATH, MathQA) on Qwen2.5-Math-7B target model [ 39 ] . We report average acceptance length τ and decoding speedup.
HumanEval
APPS
BigCodeBench
HumanEval+
MBPP
Avg
Method
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
Temperature T=0
Training-Free
1.75
1.21 ×
1.69
1.14 ×
1.74
1.24 ×
1.74
1.08 ×
1.85
1.21 ×
1.75
1.18 ×
Full-FT
4.79
3.10 ×
4.87
2.91 ×
3.66
2.38 ×
4.70
2.62 ×
4.93
2.82 ×
4.59
2.76 ×
LoRA
4.70
3.05 ×
4.80
2.88 ×
3.60
2.35 ×
4.62
2.58 ×
4.78
2.76 ×
4.50
2.72 ×
EDA (Base)
4.75
3.08 ×
4.92
2.90 ×
3.68
2.40 ×
4.72
2.63 ×
4.90
2.80 ×
4.59
2.76 ×
Table 2: Main results on five code tasks (HumanEval, APPS, BigCodeBench, HumanEval+, MBPP) on Qwen2.5-Coder-7B target model [ 14 ] . We report average acceptance length τ and decoding speedup.
MedMCQA
MedQA-USMLE
PubMedQA
MedQA
MMLU
Avg
Method
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
τ
Speedup
Temperature T=0
Training-Free
2.20
1.47 ×
2.17
1.40 ×
1.92
1.29 ×
2.14
1.29 ×
2.33
1.49 ×
2.15
1.39 ×
Full-FT
3.97
2.35 ×
3.97
2.28 ×
3.86
2.34 ×
3.97
2.35 ×
3.67
3.03 ×
3.89
2.47 ×
LoRA
3.85
2.30 ×
3.90
2.25 ×
3.78
2.18 ×
3.92
2.28 ×
3.50
2.80 ×
3.79
2.36 ×
EDA (Base)
3.95
2.33 ×
3.94
2.26 ×
3.85
2.32 ×
3.96
2.34 ×
3.66
3.00 ×
3.87
2.45 ×
Table 3: Main results on five medical tasks (MedMCQA, MedQA-USMLE, PubMedQA, MedQA, MMLU) on Meditron3-Qwen2.5-7B target model [ 27 ] . We report average acceptance length τ and decoding speedup.
Figure 3: Comparison of different data selection strategies under varying data budgets. Draft adaptation from Qwen2.5-7B to Qwen2.5-Math-7B , measured on 4 × NVIDIA H200 GPUs; τ is evaluated on GSM8K under this setup.
Method
Trainable Size (MB)
Training Time (h)
Avg. Acceptance ( τ )
Re-Train
462
5.1
4.22
EDA
127 (27.5%)
2.0 (39.2%)
4.79 (+13.5%)
Table 4: Overhead analysis on math transfer. We follow the same experimental setup as in Sec. 5.3 .
Figure 4: Qualitative example comparing direct transfer and EDA-adapted drafts on Qwen2.5-Coder-7B. Red tokens indicate incorrect predictions, while black tokens indicate correct predictions.
Speculative decoding accelerates large language model inference by pairing a target model with a lightweight draft model whose proposed tokens are verified in parallel. A common way to build draft models, like EAGLE3 or DFlash is supervised fine-tuning (SFT) on target-generated trajectories. However, we observe that SFT quickly plateaus: the draft model's acceptance length on test data stops improving. The reason is an offline-to-inference mismatch: In SFT, the drafter learns from fixed target-generated trajectories, whereas during speculative decoding it is evaluated on blocks proposed under its own policy. This motivates on-policy distillation (OPD), where the target model supervises the drafter on draft-induced states. Yet OPD remains difficult for draft models, as they cannot reliably roll out complete sequences independently, whereas target-assisted generation makes the collected sequences follow the target distribution and thus eliminates the on-policy signal. We therefore propose Draft-OPD, which uses target-assisted rollout for stable continuations and replays drafting from the verification-exposed error positions. This allows the drafter to learn from target feedback on both accepted and rejected proposals, focusing training on the draft-induced errors that limit speculative acceptance. Experiments show that Draft-OPD achieves over 5× lossless acceleration for thinking models across diverse tasks, improving over EAGLE-3 and DFlash by 23% and 13%.
Haodi Lei, Yafu Li, Haoran Zhang +8
Shanghai Jiao Tong University · Shanghai AI Laboratory · The Chinese University of Hong Kong +3
Speculative decoding accelerates large language model inference by using a low-cost draft model to propose tokens that the full-size target model verifies in parallel. Parallel and semi-autoregressive (semi- AR) drafters improve drafting efficiency by proposing an entire block in a single forward pass, but training them raises a new difficulty: the draft distribution for a given position depends on where the decoding round starts, and where rounds start depends on how many tokens earlier rounds accepted. Existing training objectives typically rely on block-local surrogates that ignore this cross-round coupling, and therefore do not directly optimize the global decoding efficiency. In this work, we develop a theoretical framework for training and evaluating these drafters by representing speculative decoding as a Markov reward process. This formulation yields the Expected Decoding Rounds (EDR) objective, which weights local rejection costs by state occupancies and exactly equals the expected number of decoding rounds. Unlike prior surrogate objectives, EDR introduces no auxiliary hyperparameters. We then derive an exact temporal-difference gradient that supports unbiased stochastic optimization from target-model rollouts. The same framework also yields an exact offline evaluator for round counts, enabling paired drafter comparisons on shared target rollouts without running speculative decoding. Finetuning two state-of-the- art drafters, DSpark and DFly, with EDR consistently improves mean accepted length and outperforms existing training objectives across nine benchmarks spanning math reasoning, code generation, and chat.
Yunxiao Zhao, Changxiao Cai
Department of Industrial and Operations Engineering, University of Michigan, Ann Arbor, MI, USA.
Speculative decoding, in which a lightweight draft model first generates a draft sequence that is then verified by the target model, has become a prevalent paradigm for accelerating large language model inference. Recent work such as DFlash further boosts drafting efficiency by leveraging diffusion drafters, whose parallel denoising mechanism enables draft generation in a single forward pass. In this work, we uncover a central pitfall of diffusion drafters: bidirectional attention is a double-edged sword. On one hand, it endows the model with parallel generation and global contextual modeling capabilities; on the other hand, this inherent global dependency introduces high variance at both the domain-level and the token-level: acceptance rates fluctuate substantially across different domains, and draft token quality also varies heterogeneously at different token positions. To tackle this issue, we propose AdaFlash framework, comprising two components: (i) an on-policy distillation (OPD) algorithm with reverse-KL divergence tailored for diffusion drafters, bringing stable convergence and effectively reducing domain-level variance; and (ii) an adaptive length head that dynamically adjusts the candidate sequence length on the fly, substantially lowering the verification cost of the target model and mitigating token-level variance. Experiments demonstrate that AdaFlash consistently improves speedup rate during deployment, with especially significant gains under high-concurrency, achieving up to 66% higher average throughput than previous SOTA. Our code is available at https://github.com/ZinYY/AdaFlash.
Yu-Yang Qian, Hao-Cong Wu, Chen Chen +4
State Key Laboratory for Novel Software Technology, Nanjing University · School of Artificial Intelligence, Nanjing University · Huawei Foundation Model Dept