arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2403.18159cs.LGcs.AIcs.CL
收藏

哦!我们冻结:通过信号传播分析改进大语言模型的量化知识蒸馏

Oh! We Freeze: Improving Quantized Knowledge Distillation via Signal Propagation Analysis for Large Language Models

Qualcomm AI Research(高通人工智能研究);Qualcomm Technologies Inc.(高通技术公司)

Kartikeya Bhardwaj, Nilesh Prasad Pandey, Sweta Priyadarshi, Kyunggeun Lee, Jun Ma, Harris Teague

AI总结:

本文针对大语言模型4比特量化微调不稳定的问题,通过梯度传播分析提出ov-freeze技术稳定KD-QAT过程,在7B LLaMAv2-Chat上实现常识推理准确率损失低于0.7%。

摘要:

大语言模型(LLMs)和扩散模型等大型生成模型分别彻底改变了自然语言处理(NLP)和计算机视觉领域。然而,它们推理速度慢、计算量和内存需求高,这使得在边缘设备上部署它们具有挑战性。在本研究中,我们提出了一种轻量级的量化感知微调技术,该技术使用知识蒸馏(KD-QAT),利用常用数据集来提升4比特权重量化LLMs的性能,以实现一种流行的语言用例——设备端聊天应用。为了改进这种微调范式,作为主要贡献,我们通过实证研究训练过程中的梯度传播,提供了关于KD-QAT稳定性的见解,以更好地理解基于KD-QAT的方法在面对低比特量化误差时的脆弱性。基于我们的见解,我们提出了ov-freeze,一种稳定KD-QAT过程的简单技术。最后,我们在流行的7B LLaMAv2-Chat模型上以4比特量化水平进行了实验,并证明ov-freeze能够实现接近浮点精度的性能,即在常识推理基准上准确率损失小于0.7%。

英文摘要:

Large generative models such as large language models (LLMs) and diffusion models have revolutionized the fields of NLP and computer vision respectively. However, their slow inference, high computation and memory requirement makes it challenging to deploy them on edge devices. In this study, we propose a light-weight quantization aware fine tuning technique using knowledge distillation (KD-QAT) to improve the performance of 4-bit weight quantized LLMs using commonly available datasets to realize a popular language use case, on device chat applications. To improve this paradigm of finetuning, as main contributions, we provide insights into stability of KD-QAT by empirically studying the gradient propagation during training to better understand the vulnerabilities of KD-QAT based approaches to low-bit quantization errors. Based on our insights, we propose ov-freeze, a simple technique to stabilize the KD-QAT process. Finally, we experiment with the popular 7B LLaMAv2-Chat model at 4-bit quantization level and demonstrate that ov-freeze results in near floating point precision performance, i.e., less than 0.7% loss of accuracy on Commonsense Reasoning benchmarks.

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

↑