Various layer-skipping methods have been proposed to accelerate token generation in large language models (LLMs). However, limited attention has been paid to a fundamental question: How do computational demands vary across the generation of different tokens? In this work, we introduce FlexiDepth, a method that dynamically adjusts the number of Transformer layers used in text generation. By incorporating a plug-in router and adapter, FlexiDepth enables adaptive computation in LLMs without modifying their original parameters. Applied to Llama-3-8B, it skips 8 out of 32 layers while maintaining full benchmark performance. Our experiments reveal that computational demands in LLMs significantly vary based on token type. Specifically, generating repetitive tokens or fixed phrases requires fewer layers, whereas producing tokens involving computation or high uncertainty requires more layers. Despite the computational savings, FlexiDepth does not yet achieve wall-clock speedup due to varied skipping patterns and I/O overhead. To inspire future work and advance research on practical speedup, we open-sourced FlexiDepth and a dataset documenting its layer allocation patterns.
Avoiding Knowledge Edit Skipping in Multi-hop Question Answering with Guided Decomposition
State Key Laboratory for Novel Software Technology, Nanjing University, China(新型软件技术国家重点实验室,南京大学,中国);National Institute of Healthcare Data Science, Nanjing University, China(医疗数据科学国家研究院,南京大学,中国)
Probe and Skip: Self-Predictive Token Skipping for Efficient Long-Context LLM Inference
School of Computer Science and Engineering, Beihang University, Beijing, China(计算机科学与工程学院,北航,北京,中国);State Key Laboratory of Virtual Reality Technology and Systems, Beihang University, Beijing, China(虚拟现实技术与系统国家重点实验室,北航,北京,中国)
FFN-SkipLLM: A Hidden Gem for Autoregressive Decoding with Adaptive Feed Forward Skipping
University of Texas at Austin(德克萨斯大学奥斯汀分校);Eindhoven University of Technology(埃因霍温理工大学);University of Aberdeen(阿伯丁大学);University of North Carolina at Chapel Hill(北卡罗来纳大学教堂山分校);University of Oxford(牛津大学)
CLaSp: In-Context Layer Skip for Self-Speculative Decoding
Shenzhen Institutes of Advanced Technology, Chinese Academy of Sciences(深圳先进技术研究院,中国科学院);University of Chinese Academy of Sciences(中国科学院大学);Singapore University of Technology and Design(新加坡科技设计大学);School of Biomedical Engineering, UNSW Sydney(新南威尔士大学生物医学工程学院)
What Layers When: Learning to Skip Compute in LLMs with Residual Gates
Humboldt University Berlin(洪堡大学柏林);Qualcomm-UvA Lab, University of Amsterdam(高通-乌得勒支实验室,阿姆斯特丹大学);FunAI Lab, University of Technology Nuremberg(FunAI实验室,纽伦堡技术大学)
DLO: Dynamic Layer Operation for Efficient Vertical Scaling of LLMs
School of Computing, and Augmented Intelligence, Arizona State University(亚利桑那州立大学计算与增强智能学院);Shanghai Artificial Intelligence Laboratory(上海人工智能实验室);Department of Computer Science, University of North Carolina at Chapel Hill(北卡罗来纳大学教堂山分校计算机系);School of Artificial Intelligence and Data Science, University of Science and Technology of China(中国科学技术大学人工智能与数据科学学院);Department of Computer Science, Chinese University of Hong Kong(香港中文大学计算机系)
From Rollouts to Recipes: Self-Contained Post-Training for LLMs
School of Computer Science and Technology, Xi’an Jiaotong University(西安交通大学计算机科学与技术学院);Zhongguancun Academy, Beijing, China(北京中关村学院);National Engineering Research Center for Visual Information and Applications(视觉信息与应用国家工程研究中心)
ReLU$^2$ Wins: Discovering Efficient Activation Functions for Sparse LLMs
Tsinghua University(清华大学);Shanghai Jiao Tong University(上海交通大学);Institute of Computing Technology, Chinese Academy of Sciences(中国科学院计算技术研究所);Renmin University of China(中国人民大学)
A rigor-matched audit of periodic-step layer skipping for efficient llm inference: conflayers versus swift, with a supplemental analysis of trained routing alternatives
Attend, Transform, or Silence: Operator-Level Visual Skipping for Efficient Multimodal LLM Inference
Tsinghua Shenzhen International Graduate School(清华大学深圳国际研究生院);Sun Yat-sen University(中山大学);National Supercomputing Center in Shenzhen(国家超级计算深圳中心);Tsinghua University(清华大学)
PoSE: Efficient Context Window Extension of LLMs via Positional Skip-wise Training
Microsoft Corporation(微软公司);School of Computer Science, Peking University(北京大学计算机学院);National Key Laboratory for Multimedia Information Processing, Peking University(北京大学多媒体信息处理国家重点实验室)
Mechanistically Interpreting the Role of Sample Difficulty in RLVR for LLMs
Beijing Jiaotong University(北京交通大学);AntGroup(蚂蚁集团);Northwestern Polytechnical University(西北工业大学);University of Leeds(利兹大学);University of Southampton(南安普顿大学)
Safety-Utility Conflicts Are Not Global: Surgical Alignment via Head-Level Diagnosis
Baidu Inc.(百度公司);School of Software and Microelectronics, Peking University(北京大学软件与微电子学院);School of Computer Science, Peking University(北京大学计算机学院);State Key Laboratory of AI Safety, Institute of Computing Technology, CAS(中国科学院计算技术研究所人工智能安全重点实验室)
DeltaLLM: Delta-Key Sparse Attention for Edge LLMs
Leiden Institute of Advanced Computer Science (LIACS), Leiden University(莱顿先进计算机科学研究所(LIACS)、莱顿大学);Department of Microelectronics, Delft University of Technology(电子系、代尔夫特理工大学)