Diffusion Large Language Models (dLLMs) offer fast, parallel token generation, but their standalone use is plagued by an inherent efficiency-quality tradeoff. We show that, if carefully applied, the attributes of dLLMs can actually be a strength for drafters in speculative decoding with autoregressive (AR) verifiers. Our core insight is that dLLM's speed from parallel decoding drastically lowers the risk of costly rejections, providing a practical mechanism to effectively realize the (elusive) lengthy drafts that lead to large speedups with speculative decoding. We present FailFast, a dLLM-based speculative decoding framework that realizes this approach by dynamically adapting its speculation length. It "fails fast" by spending minimal compute in hard-to-speculate regions to shrink speculation latency and "wins big" by aggressively extending draft lengths in easier regions to reduce verification latency (in many cases, speculating and accepting 70 tokens at a time!). Without any fine-tuning, FailFast delivers lossless acceleration of AR LLMs and achieves up to 4.9$\times$ speedup over vanilla decoding, 1.7$\times$ over the best naive dLLM drafter, and 2.0$\times$ over EAGLE-3 across diverse models and workloads. We open-source FailFast at https://github.com/ruipeterpan/failfast.


翻译:扩散大语言模型(dLLMs)能够实现快速、并行的令牌生成,但其独立使用受到固有的效率-质量权衡的困扰。我们证明,如果应用得当,dLLMs的特性实际上可以成为推测解码中草稿器(配合自回归验证器)的优势。我们的核心见解是,dLLM通过并行解码获得的速度极大地降低了代价高昂的拒绝风险,为实现(难以捉摸的)长草稿提供了一种实用机制,而长草稿能通过推测解码带来显著的加速效果。我们提出了FailFast,这是一个基于dLLM的推测解码框架,通过动态调整其推测长度来实现这一方法。它在难以推测的区域通过投入最少的计算来“快速失败”,从而缩短推测延迟;在较容易的区域则通过积极延长草稿长度来“大获全胜”,以减少验证延迟(在许多情况下,可以一次推测并接受70个令牌!)。无需任何微调,FailFast即可实现自回归大语言模型的无损加速,相比原始解码最高可获得4.9倍的加速,相比最佳朴素dLLM草稿器获得1.7倍加速,相比EAGLE-3在各种模型和工作负载上获得2.0倍加速。我们在 https://github.com/ruipeterpan/failfast 开源了FailFast。

0
下载
关闭预览

相关内容

唯快不破:大型语言模型高效架构综述
专知会员服务
24+阅读 · 2025年8月17日
《大型语言模型加速生成技术》最新综述
专知会员服务
50+阅读 · 2024年5月25日
大语言模型简明指南
专知会员服务
143+阅读 · 2023年7月29日
读扩散?写扩散?推拉架构一文搞定!
架构师之路
17+阅读 · 2019年2月1日
国家自然科学基金
43+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
VIP会员
相关基金
国家自然科学基金
43+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员