LayerSkip: Enabling Early Exit Inference and Self-Speculative Decoding
Mostafa Elhoushi, Akshat Shrivastava, Diana Liskovich, Basil Hosmer, Bram Wasti, Liangzhen Lai, Anas Mahmoud, Bilge Acun, Saurabh Agarwal, Ahmed Roman, Ahmed A. Aly, Beidi Chen, Carole-Jean Wu
Abstract
We present LayerSkip, an end-to-end solution to speed-up inference of large language models (LLMs). First, during training we apply layer dropout, with low dropout rates for earlier layers and higher dropout rates for later layers, and an early exit loss where all transformer layers share the same exit. Second, during inference, we show that this training recipe increases the accuracy of early exit at earlier layers, without adding any auxiliary layers or modules to the model. Third, we present a novel self-speculative decoding solution where we exit at early layers and verify and correct with remaining layers of the model. Our proposed self-speculative decoding approach has less memory footprint than other speculative decoding approaches and benefits from shared compute and activations of the draft and verification stages. We run experiments on different Llama model sizes on different types of training: pretraining from scratch, continual pretraining, finetuning on specific data domain, and finetuning on specific task. We implement our inference solution and show speedups of up to 2.16× on summarization for CNN/DM documents, 1.82× on coding, and 2.0× on TOPv2 semantic parsing task. We open source code at https://github.com/ facebookresearch/LayerSkip .
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
105 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- MiniCache: KV Cache Compression in Depth Dimension for Large Language Models cites SmoothQuant: Accurate and Efficient Post-Training Quantization for Large Language Models
- MiniCache: KV Cache Compression in Depth Dimension for Large Language Models cites WinoGrande: An Adversarial Winograd Schema Challenge at Scale
- MiniCache: KV Cache Compression in Depth Dimension for Large Language Models cites Confident Adaptive Language Modeling
- DeeR-VLA: Dynamic Inference of Multimodal Large Language Models for Efficient Robot Execution cites SmoothQuant: Accurate and Efficient Post-Training Quantization for Large Language Models
- DeeR-VLA: Dynamic Inference of Multimodal Large Language Models for Efficient Robot Execution cites Confident Adaptive Language Modeling
- EAGLE-3: Scaling up Inference Acceleration of Large Language Models via Training-Time Test cites Fast Inference from Transformers via Speculative Decoding
- Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach cites WinoGrande: An Adversarial Winograd Schema Challenge at Scale
- Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach cites Confident Adaptive Language Modeling
- Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach cites Fast Inference from Transformers via Speculative Decoding
- Mixture-of-Recursions: Learning Dynamic Recursive Depths for Adaptive Token-Level Computation cites MiniCache: KV Cache Compression in Depth Dimension for Large Language Models
- Mixture-of-Recursions: Learning Dynamic Recursive Depths for Adaptive Token-Level Computation cites Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth Approach
- Mixture-of-Recursions: Learning Dynamic Recursive Depths for Adaptive Token-Level Computation cites Confident Adaptive Language Modeling
- Mixture-of-Recursions: Learning Dynamic Recursive Depths for Adaptive Token-Level Computation cites Fast Inference from Transformers via Speculative Decoding
Cited by top-tier papers105
- Scaling up Test-Time Compute with Latent Reasoning: A Recurrent Depth ApproachJonas Geiping, Sean McLeish, Neel Jain, John Kirchenbauer et al.NeurIPS 2025 · 431 citations
- EAGLE-3: Scaling up Inference Acceleration of Large Language Models via Training-Time TestYuhui Li, Fangyun Wei, Chao Zhang, Hongyang ZhangNeurIPS 2025 · 347 citations
- MiniCache: KV Cache Compression in Depth Dimension for Large Language ModelsAkide Liu, Jing Liu, Zizheng Pan, Yefei He et al.NeurIPS 2024 · 160 citations
- DeeR-VLA: Dynamic Inference of Multimodal Large Language Models for Efficient Robot ExecutionYang Yue, Yulin Wang, Bingyi Kang, Yizeng Han et al.NeurIPS 2024 · 153 citations
- Mixture-of-Recursions: Learning Dynamic Recursive Depths for Adaptive Token-Level ComputationSangmin Bae, Yujin Kim, Reza Bayat, Sungnyun Kim et al.NeurIPS 2025 · 143 citations
Builds on8
- A ConvNet for the 2020sZhuang Liu, Hanzi Mao, Chao-Yuan Wu, Christoph Feichtenhofer et al.CVPR 2022 · 6,782 citations
- WinoGrande: An Adversarial Winograd Schema Challenge at ScaleKeisuke Sakaguchi, Ronan Le Bras, Chandra Bhagavatula, Yejin ChoiAAAI 2020 · 3,037 citations
- SmoothQuant: Accurate and Efficient Post-Training Quantization for Large Language ModelsGuangxuan Xiao, Ji Lin, Mickaël Seznec, Hao Wu et al.ICML 2023 · 1,493 citations
- Fast Inference from Transformers via Speculative DecodingYaniv Leviathan, Matan Kalman, Yossi MatiasICML 2023 · 1,472 citations
- Confident Adaptive Language ModelingTal Schuster, Adam Fisch, Jai Gupta, Mostafa Dehghani et al.NeurIPS 2022 · 394 citations
Related papers
- SWIFT: On-the-Fly Self-Speculative Decoding for LLM Inference AccelerationHeming Xia, Yongqi Li, Jun Zhang, Cunxiao Du et al.ICLR 2025
- Don't Drop Dropout: Optimizing Layer Sparsity for Efficient LLM Training and InferenceMostafa Elhoushi, Alexander Pretko, Nolan Dey, Bin Zhang et al.ICML 2026
- Draft& Verify: Lossless Large Language Model Acceleration via Self-Speculative DecodingJun Zhang, Jue Wang, Huan Li, Lidan Shou et al.ACL 2024
- Training-Free Loosely Speculative Decoding: Accepting Semantically Correct Drafts Beyond Exact MatchJinze Li, Yixing Xu, Guanchen Li, Shuo Yang et al.ICLR 2026 · 12 citations
- Accelerating LLM Inference with Lossless Speculative Decoding Algorithms for Heterogeneous VocabulariesNadav Timor, Jonathan Mamou, Daniel Korat, Moshe Berchansky et al.ICML 2025
