Introduction
Large Language Models (LLMs) have revolutionized natural language processing but remain challenging to deploy due to their immense computational and memory requirements. Pruning is a common technique used to compress these models. However, a significant trade-off exists: unstructured pruning (removing individual weights) requires specialized hardware for speedups, while structured pruning (removing entire rows or columns) often severely degrades accuracy, necessitating expensive retraining.
To address these challenges, we present FLAP (Fluctuation-based Adaptive Structured Pruning), a retraining-free framework that enables efficient structured pruning of LLMs. FLAP can prune a LLaMA-7B model in under five minutes on a single GPU while maintaining high performance and achieving significant hardware-agnostic speedups.
Methodology
FLAP introduces three core innovations to the structured pruning pipeline:
1. Structural Fluctuation Metric
Traditional pruning often relies on weight magnitude. FLAP instead focuses on input features, measuring how much a specific channel fluctuates across different samples. The intuition is that channels with low fluctuation (high stability) contribute predictably to the next layer and are easier to approximate or remove.
2. Baseline Bias Compensation
When a weight column is pruned, its contribution is not simply discarded. FLAP calculates the average value (baseline) that the channel would have contributed and reintroduces it as a bias term. This compensation mechanism acts as a "poor man's LoRA," recovering significant performance without the need for a full training loop.
3. Adaptive Structure Search
Rather than pruning every layer by a fixed percentage, FLAP standardizes importance scores across the entire model. This allows for a unified search that adaptively allocates sparsity, preserving dense structures in critical layers while aggressively pruning redundant ones.
Experimental Results
The researchers evaluated FLAP on the LLaMA model family (7B to 65B parameters) using WikiText2 for perplexity and the EleutherAI LM Evaluation Harness for zero-shot reasoning tasks.
- Superior Accuracy: On LLaMA-7B at 20% pruning, FLAP achieved a perplexity of 14.62, outperforming the previous state-of-the-art, LLM-Pruner (17.37), despite LLM-Pruner utilizing LoRA fine-tuning.
- Inference Speedups: At 50% pruning, FLAP reduced parameter counts by half and increased inference throughput by 66% on an NVIDIA A100 GPU.
- Efficiency: The entire process is remarkably fast; a 7B model can be pruned in 3 to 5 minutes without any retraining.
- Zero-Shot Robustness: Reasoning task performance remained nearly identical to the original unpruned model at a 20% pruning ratio.
Conclusion
FLAP demonstrates that structured pruning can be both effective and efficient without the need for costly retraining. By leveraging input feature fluctuations and simple bias compensation, FLAP provides a practical path for deploying leaner, faster LLMs on standard hardware. Future work may explore combining FLAP with quantization to push the boundaries of model compression even further.
Summary updated