Adaptive Depth Sparse Framework: Similarity-Driven Resource Allocation for Pre-Trained LLMs
Summary
The Adaptive Depth Sparse Framework (AdaDSF) addresses the high inference costs of Transformer-based large language models (LLMs) by converting off-the-shelf pre-trained models into depth-sparse versions without requiring full retraining or task-specific fine-tuning. AdaDSF operates on the insight that LLM layers contribute unequally to representation transformation, quantifiable by the cosine similarity between layer input and output hidden states. It assigns layer-wise token retention ratios based on these similarity statistics, employs a lightweight router for informative token selection at each layer, and uses a feature-preserving alignment objective to match representations between sparse and dense models. Evaluated on GPT-NeoX and Qwen2.5 across language modeling and commonsense reasoning tasks, AdaDSF significantly reduces inference FLOPs while maintaining performance close to dense counterparts. It also demonstrates smaller accuracy degradation compared to baselines like MoD, D-LLM, and DLO under similar sparsity levels.
Key takeaway
For Machine Learning Engineers optimizing LLM deployment costs, you should consider the Adaptive Depth Sparse Framework (AdaDSF) to significantly reduce inference FLOPs for pre-trained models like GPT-NeoX and Qwen2.5. This method allows you to convert off-the-shelf LLMs into depth-sparse versions without full retraining, directly impacting operational expenses and resource allocation. Evaluate AdaDSF's applicability for your specific model architectures and tasks to achieve substantial efficiency gains while preserving performance.
Key insights
AdaDSF enables efficient, retraining-free depth-sparse conversion of LLMs by exploiting unequal layer contributions.
Principles
- LLM layers contribute unequally to representation transformation.
- Cosine similarity quantifies layer input/output hidden state transformation.
Method
AdaDSF assigns layer-wise token retention ratios from similarity statistics, uses a lightweight router, and applies a feature-preserving alignment objective.
In practice
- Convert off-the-shelf LLMs to depth-sparse models.
- Reduce inference FLOPs for GPT-NeoX and Qwen2.5.
Topics
- Large Language Models
- Model Sparsity
- Inference Optimization
- Transformer Architecture
- GPT-NeoX
- Qwen2.5
Best for: AI Engineer, Research Scientist, AI Scientist, Machine Learning Engineer, NLP Engineer
Related on AIssential
See Counsel's argued verdicts on the open AI decisions leaders are weighing →
Editorial summary, takeaway, and curation by AIssential. Original article published by Machine Learning.