大语言模型(LLMs)的自回归性质从根本上限制了推理速度,因为每次前向传递只能生成一个令牌,并且常常受到内存带宽的瓶颈限制。推测解码已经 emerged 作为一种有前途的解决方案,采用先草稿后验证的策略来加速令牌生成。虽然EAGLE系列实现了强大的加速,但其要求为每个目标模型训练一个单独的草稿头,这会引入显著的适应成本。在本工作中,我们提出了PARD(并行草稿),一种新的推测解码方法,具有目标无关性和并行令牌预测。具体来说,PARD使一个草稿模型可以应用于整个目标模型家族,而无需为每个变体单独训练,从而最小化适应成本。同时,PARD通过在草稿阶段的单次前向传递中预测多个未来令牌,显著加速了推理。为进一步减少PARD的训练适应成本,我们提出了一种基于前缀键值状态完整性条件的Drop-token(COD)机制,使自回归草稿模型能够以低成本适应为并行草稿模型。我们的实验表明,所提出的COD方法相比传统掩码预测训练提高了3倍的草稿模型训练效率。在vLLM推理框架上,PARD在LLaMA3.1-8B上实现了高达3.67倍的加速,达到264..tokens per second,比EAGLE-3快1.15倍。我们的代码可在https://github.com/AMD-AIG-AIMA/PARD上获得。
英文摘要:
The autoregressive nature of large language models (LLMs) fundamentally limits inference speed, as each forward pass generates only a single token and is often bottlenecked by memory bandwidth. Speculative decoding has emerged as a promising solution, adopting a draft-then-verify strategy to accelerate token generation. While the EAGLE series achieves strong acceleration, its requirement of training a separate draft head for each target model introduces substantial adaptation costs. In this work, we propose \textbf{PARD (PARallel Draft)}, a novel speculative decoding method featuring \textit{target-independence} and \textit{parallel token prediction}. Specifically, PARD enables a single draft model to be applied across an entire family of target models without requiring separate training for each variant, thereby minimizing adaptation costs. Meanwhile, PARD substantially accelerates inference by predicting multiple future tokens within a single forward pass of the draft phase. To further reduce the training adaptation cost of PARD, we propose a COnditional Drop-token (COD) mechanism based on the integrity of prefix key-value states, enabling autoregressive draft models to be adapted into parallel draft models at low-cost. Our experiments show that the proposed COD method improves draft model training efficiency by \textbf{3$\times$} compared with traditional masked prediction training. On the \texttt{vLLM} inference framework, PARD achieves up to \textbf{3.67$\times$} speedup on LLaMA3.1-8B, reaching \textbf{264.88} tokens per second, which is \textbf{1.15$\times$} faster than EAGLE-3. Our code is available at https://github.com/AMD-AIG-AIMA/PARD.
TPP-SD: Accelerating Transformer Point Process Sampling with Speculative Decoding
Center for Applied Statistics and School of Statistics, Renmin University of China(应用统计中心和统计学院,中国人民大学);School of Information, Renmin University of China(信息学院,中国人民大学);School of Cyber Science and Engineering, Wuhan University(网络安全与工程学院,武汉大学);Alibaba Group(阿里巴巴集团)
Mistletoe: Stealthy Acceleration-Collapse Attacks on Speculative Decoding
Harbin Institute of Technology, Shenzhen(哈尔滨工业大学(深圳));South China University of Technology(华南理工大学);Tsinghua Shenzhen International Graduate School, Tsinghua University(清华大学深圳国际研究生院);Huawei Technology(华为技术)
PaperGuide: Making Small Language-Model Paper-Reading Agents More Efficient
X-LANCE Lab, School of Computer Science, MoE Key Lab of Artificial Intelligence, SJTU AI Institute, Shanghai Jiao Tong University, Shanghai, China(X-LANCE实验室、计算机科学学院、人工智能关键实验室、SJTU人工智能研究所、上海交通大学、上海,中国);Suzhou Laboratory, Suzhou, China(苏州实验室、苏州,中国)