用双扩散模型提升文本生成速度,通过智能筛选候选路径减少无效计算。
D^2SD: Accelerating Speculative Decoding with Dual Diffusion Draft Models
- 构建置信度引导的前缀树,动态选择最优候选序列分支。
- 单次验证可接受超过70%的生成内容,较基线提升显著。
- 适合追求推理加速的AI系统开发者使用。
推测解码通过并行生成多个候选词并一次性验证,加速自回归大语言模型的推理过程。现有基于扩散模型的草案生成器虽能并行生成一整块词元,但通常仅保留单一候选序列:一旦出现首个不匹配,后续所有草案均被丢弃,导致接受率受限。简单增加候选序列批次仅带来边际收益,因冗余或错误分支会提高草案与验证开销,却无法等比例提升有效接受数量。本文提出D²SD——一种双扩散草案推测解码框架,将候选序列组织为置信度引导的前缀树。首个扩散草案生成整个词元块及每个位置的置信度得分,据此识别最可能的拒绝边界,并选出前K个高置信度前缀范围用于恢复;第二个可变前缀扩散草案在每个选定前缀处重新锚定,批量生成替代延续;最终共享前缀的候选序列通过级联注意力联合验证。实验表明,D²SD在性能上显著优于基础扩散方法和强自回归推测解码基线。
原文摘要 · Abstract (English)
Speculative decoding accelerates autoregressive large language model inference by drafting multiple tokens and verifying them in a single target-model forward pass. Recent diffusion-based drafters generate an entire block of tokens in parallel but usually commit to a single draft sequence per verification: once the first mismatch occurs, all subsequent draft tokens are discarded, resulting in a limited acceptance rate. Naively batching more draft candidate sequences only introduces a marginal improvement, as redundant or poorly placed branches increase the cost of drafting and verification without proportionally increasing the number of accepted tokens. We propose D^2SD, a dual diffusion draft speculative decoding framework that organizes candidates into a confidence-guided prefix tree, where the first diffusion drafter generates a block along with per-position confidence scores that are used to identify the most likely rejection boundary and select the top-K prefix ranges for recovery; the second variable-prefix diffusion drafter re-anchors at each selected prefix and proposes alternative continuations in one batched pass; the resulting shared-prefix candidates are jointly verified via cascade attention. Empirically, D^2SD shows clear improvements over both the underlying diffusion approach and strong autoregressive speculative decoding baselines.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。