Compressing Language Models using Low-Rank Decomposition and Characterizing the Accuracy - Efficiency Trade-offs
Year: 2024
Type: dissertation
Abstract: Large language models (LLMs) have emerged and presented their general problem-solvingcapabilities with one model. However, the model size has increased dramatically with billions\nof parameters to enable such broad problem-solving capabilities. In addition, due to the\ndominance of matrix-matrix and matrix-vector multiplications in LLMs, the compute-to-model\nsize ratio is significantly lower than that of convolutional neural networks (CNNs).\nThis shift pushes LLMs from a computation-bound regime to a memory-bound regime. Therefore,\noptimizing the memory footprint and traffic is an important optimization direction for LLMs\ntoday.Model compression methods such as quantization and parameter pruning have been activelyexplored for achieving the memory footprint and traffic optimization. However, the accuracy-\nefficiency trade-off of rank pruning (i.e., low-rank decomposition) for LLMs is not well-\nunderstood yet. Therefore, in this work, we characterize the accuracy-efficiency trade-off of a\nlow-rank decomposition method, Tucker decomposition, on recent language models including\nan open-source LLM, Llama 2.We formalize the low-rank decomposition design space and show that the decompositiondesign space is huge (e.g., O(2^37) for Llama2-7B). To navigate such a huge design space, we\ncharacterize the design space and prune ineffective design space utilizing the learning from\nour characterization results (e.g., we can reduce the pruned ranks to 1 without a noticeable\nmodel accuracy drop). On the pruned design space, we perform thorough case studies of\naccuracy-efficiency trade-offs using six widely used LLM benchmarks on BERT and Llama 2\nmodels. Our results show that we can achieve a 9% model size reduction with minimal accuracy\ndrops, which range from 4%p to 10%p, depending on the difficulty of the benchmark, without\nany retraining to recover accuracy after decomposition. The results show that low-rank\ndecomposition can be a promising direction for LLM-based applications that require real-time\nservice in scale (e.g., AI agent assist and real-time coding assistant), where the latency is as\nimportant as the model accuracy.
Author: Moar, Chakshu
Institution: University of California, Irvine
Language: English
Subfield: Computer Vision and Pattern Recognition
Field: Computer Science
Domain: Physical Sciences
Open Access status: green
Funder: Nvidia
OpenAlex ID: W7064709637
