Abstract
Large language models (LLMs) have demonstrated impressive capabilities in a wide range of downstream natural language processing tasks. Nevertheless, their considerable sizes and memory demands hinder practical deployment, underscoring the importance of developing efficient compression strategies. Singular value decomposition (SVD) decomposes a matrix into orthogonal components, enabling efficient low-rank approximation. This is particularly suitable for LLM compression, where weight matrices often exhibit significant redundancy. However, current SVD-based methods neglect the residual matrix from truncation, resulting in significant truncation loss. Additionally, compressing all layers of the model results in severe performance degradation. To overcome these limitations, we propose ResSVD (also referred to as ERC-SVD), a new post-training SVD-based LLM compression method. Specifically, we leverage the residual matrix generated during the truncation process to reduce truncation loss. Moreover, under a fixed overall compression ratio, we selectively compress the last few layers of the model, which mitigates error propagation and significantly improves the performance of compressed models. Comprehensive evaluations of ResSVD on diverse LLM families and multiple benchmark datasets indicate that ResSVD consistently achieves superior performance over existing counterpart methods, demonstrating its practical effectiveness.
Introduction
Large Language Models (LLMs) are transformative, but their massive parameter counts make them notoriously difficult to deploy on consumer hardware. While Singular Value Decomposition (SVD) is a classic mathematical tool for compressing matrices into low-rank approximations, applying it to LLMs often results in a "death by a thousand cuts"—small errors in each layer accumulate into a broken model.
Researchers have introduced ERC-SVD (Error-Controlled SVD), also known as ResSVD. By focusing on two clever architectural tweaks—compensating for what SVD throws away and choosing where to compress—they’ve significantly pushed the boundaries of post-training model compression.
Methodology: Residuals and Strategic Placement
Standard SVD compression works by taking a weight matrix, decomposing it, and keeping only the most "important" parts (the largest singular values). However, this creates two major issues in the context of LLMs: truncation loss and error propagation. ERC-SVD addresses these through two core technical innovations.
1. Residual Compensation (REC)
Instead of a single SVD truncation, ERC-SVD performs a two-stage process. First, it creates an initial low-rank approximation. Then, it calculates the residual matrix (the difference between the original and the approximation). It performs a second SVD on this residual and adds a portion of that signal back into the compressed weight. Mathematically, this "compensated" matrix is a much closer approximation to the original than standard SVD.
2. Partial-Layer Compression (PLC)
The authors observed a strong correlation between the error in the very last layer and the model's overall zero-shot accuracy. To minimize this "final-layer error," they propose leaving the early layers of the model completely intact. Under a fixed compression budget (e.g., 20% total reduction), they selectively compress only the last $k$ layers. This prevents errors from snowballing through the entire depth of the network.
Key Results and Performance
ERC-SVD consistently outperformed state-of-the-art baselines like SVD-LLM and ASVD across a massive battery of tests including LLaMA-2, LLaMA-3, Mistral, and vision-language models like LLaVA-1.5-7B.
- Accuracy Retention: For LLaMA-2-7B at 20% compression, ERC-SVD achieved an average zero-shot accuracy of 48%, nearly matching the original model's 53% and beating the SVD-LLM baseline of 41%.
- Massive Perplexity Gains: On Mistral-7B at 30% compression, ERC-SVD reduced perplexity by 71% on WikiText-2 compared to SVD-LLM.
- Stability: Unlike some baseline methods (like ASVD), which suffered from numerical instability and "NaN" errors on certain datasets, ERC-SVD remained stable across all tested models and ratios.
Conclusion
The paper demonstrates that the information discarded by SVD isn't just noise; it contains structural data that can be partially recovered through a second pass, significantly lowering reconstruction error. Furthermore, keeping the "foundation" of the model (the early layers) error-free is the most efficient way to use a compression budget. ERC-SVD offers a robust, stable, and effective path for deploying large models on resource-constrained hardware without the need for expensive retraining.
Summary updated