arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2405.13155cs.LG
收藏

ReALLM:一种用于大语言模型压缩与微调的通用框架

ReALLM: A general framework for LLM compression and fine-tuning

Isep(Isep(巴黎高等电子学院));Sorbonne University(索邦大学);Huawei Tech(华为技术);Ecole Polytechnique(巴黎综合理工学院)

Louis Leconte, Lisa Bedin, Van Minh Nguyen, Eric Moulines

AI总结:

提出ReALLM框架,将预训练矩阵分解为高精度低秩部分与向量量化隐表示,按矩阵自适应配置编码器并仅微调低秩部分,在4比特以下实现免训练量化最优及小样本微调的先进性能。

摘要:

我们提出了ReALLM,一种用于预训练语言模型压缩和内存高效适配的新方法,它涵盖了预算低于4比特的大多数训练后量化与微调方法。预训练矩阵被分解为高精度低秩部分和向量量化隐表示(使用自编码器)。在微调阶段,仅更新低秩部分。我们的结果表明,预训练矩阵表现出不同的模式。ReALLM将编码器的形状(小/大嵌入、高/低比特VQ等)适配到每个矩阵。ReALLM提出用$b$比特的小嵌入和权重为$b_ϕ$比特的神经解码器模型$\mathcal{D}_ϕ$来表示每个矩阵。矩阵的解压缩仅需一个嵌入和一次解码器的前向传播。我们的仅权重量化算法在$3$比特预算下,无需任何训练,在语言生成任务(C4和WikiText-2)上取得了最佳结果。在$2$比特预算下,ReALLM在小校准数据集上微调后达到了最先进的性能。

英文摘要:

We introduce ReALLM, a novel approach for compression and memory-efficient adaptation of pre-trained language models that encompasses most of the post-training quantization and fine-tuning methods for a budget of <4 bits. Pre-trained matrices are decomposed into a high-precision low-rank component and a vector-quantized latent representation (using an autoencoder). During the fine-tuning step, only the low-rank components are updated. Our results show that pre-trained matrices exhibit different patterns. ReALLM adapts the shape of the encoder (small/large embedding, high/low bit VQ, etc.) to each matrix. ReALLM proposes to represent each matrix with a small embedding on $b$ bits and a neural decoder model $\mathcal{D}_ϕ$ with its weights on $b_ϕ$ bits. The decompression of a matrix requires only one embedding and a single forward pass with the decoder. Our weight-only quantization algorithm yields the best results on language generation tasks (C4 and WikiText-2) for a budget of $3$ bits without any training. With a budget of $2$ bits, ReALLM achieves state-of-the art performance after fine-tuning on a small calibration dataset.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑