Adaptive Depth Sparse Framework: Similarity-Driven Resource Allocation for Pre-Trained LLMs

· Source: Machine Learning · Field: Technology & Digital — Artificial Intelligence & Machine Learning · Depth: Expert, quick

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

Method

AdaDSF assigns layer-wise token retention ratios from similarity statistics, uses a lightweight router, and applies a feature-preserving alignment objective.

In practice

Topics

Best for: AI Engineer, Research Scientist, AI Scientist, Machine Learning Engineer, NLP Engineer

Related on AIssential

Open in AIssential →

Editorial summary, takeaway, and curation by AIssential. Original article published by Machine Learning.