Lune

ICML2023顶会

Fast Inference from Transformers via Speculative Decoding

Yaniv Leviathan, Matan Kalman, Yossi Matias

摘要

Inference from large autoregressive models like Transformers is slow - decoding K tokens takes K serial runs of the model. In this work we introduce speculative decoding - an algorithm to sample from autoregressive models faster without any changes to the outputs, by computing several tokens in parallel. At the heart of our approach lie the observations that (1) hard language-modeling tasks often include easier subtasks that can be approximated well by more efficient models, and (2) using speculative execution and a novel sampling method, we can make exact decoding from the large models faster, by running them in parallel on the outputs of the approximation models, potentially generating several tokens concurrently, and without changing the distribution. Our method can accelerate existing off-the-shelf models without retraining or architecture changes. We demonstrate it on T5-XXL and show a 2X-3X acceleration compared to the standard T5X implementation, with identical outputs.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 524 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • Sparse is Enough in Scaling Transformers 引用了 Language Models are Few-Shot Learners
  • EAGLE-3: Scaling up Inference Acceleration of Large Language Models via Training-Time Test 引用了 EAGLE: Speculative Sampling Requires Rethinking Feature Uncertainty
  • EAGLE-3: Scaling up Inference Acceleration of Large Language Models via Training-Time Test 引用了 Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding Heads
  • Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach 引用了 Depth-Adaptive Transformer
  • Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach 引用了 Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding Heads
  • Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding Heads 引用了 Language Models are Few-Shot Learners
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper524

  1. SnapKV: LLM Knows What You are Looking for Before GenerationYuhong Li, Yingbing Huang, Bowen Yang, Bharat Venkitesh 等NeurIPS 2024 · 1,019 次引用
  2. Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding HeadsTianle Cai, Yuhong Li, Zhengyang Geng, Hongwu Peng 等ICML 2024 · 669 次引用
  3. Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth ApproachJonas Geiping, Sean McLeish, Neel Jain, John Kirchenbauer 等NeurIPS 2025 · 431 次引用
  4. EAGLE: Speculative Sampling Requires Rethinking Feature UncertaintyYuhui Li, Fangyun Wei, Chao Zhang, Hongyang ZhangICML 2024 · 424 次引用
  5. EAGLE-3: Scaling up Inference Acceleration of Large Language Models via Training-Time TestYuhui Li, Fangyun Wei, Chao Zhang, Hongyang ZhangNeurIPS 2025 · 347 次引用

它引用的 Paper7

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
  2. Depth-Adaptive TransformerMaha Elbayad, Jiatao Gu, Edouard Grave, Michael AuliICLR 2020 · 264 次引用
  3. Sparse is Enough in Scaling TransformersSebastian Jaszczur, Aakanksha Chowdhery, Afroz Mohiuddin, Lukasz Kaiser 等NeurIPS 2021 · 127 次引用
  4. The Efficiency MisnomerMostafa Dehghani, Yi Tay, Anurag Arnab, Lucas Beyer 等ICLR 2022 · 116 次引用
  5. Consistent Accelerated Inference via Confident Adaptive TransformersTal Schuster, Adam Fisch, Tommi S. Jaakkola, Regina BarzilayEMNLP 2021 · 30 次引用

相关 Paper

  1. A Theoretical Perspective for Speculative Decoding AlgorithmMing Yin, Minshuo Chen, Kaixuan Huang, Mengdi WangNeurIPS 2024 · 36 次引用
  2. Parallel Token Prediction for Language ModelsFelix Draxler, Justus C. Will, Farrin Marouf Sofian, Theofanis Karaletsos 等ICLR 2026 · 6 次引用
  3. Speculative Decoding: Exploiting Speculative Execution for Accelerating Seq2seq GenerationHeming Xia, Tao Ge, Peiyi Wang, Si-Qing Chen 等EMNLP Findings 2023 · 40 次引用
  4. Cascade Speculative Drafting for Even Faster LLM InferenceZiyi Chen, Xiaocong Yang, Jiacheng Lin, Chenkai Sun 等NeurIPS 2024 · 107 次引用
  5. SpecExec: Massively Parallel Speculative Decoding For Interactive LLM Inference on Consumer DevicesRuslan Svirschevski, Avner May, Zhuoming Chen, Beidi Chen 等NeurIPS 2024 · 70 次引用
黄昏的海面,两侧是细线勾勒的悬崖