arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2412.20382cs.CLcs.AI
收藏

自然语言微调

Natural Language Fine-Tuning

Pazhou Laboratory(琶洲实验室);Huazhong University of Science and Technology(华中科技大学);South China University of Technology(华南理工大学)

Jia Liu, Yue Wang, Zhiqi Lin, Min Chen, Yixue Hao, Long Hu

AI总结:

本文提出自然语言微调(NLFT)方法,利用自然语言指导 token 级输出,在数据有限场景下以 O(n) 复杂度显著提升训练效率与准确率,并大幅降低时间和空间成本。

摘要:

大语言模型微调技术通常依赖大量标注数据、外部指导和反馈,例如人类对齐、标量奖励和示范。然而,在实际应用中,特定知识的稀缺性给现有微调技术带来了前所未有的挑战。本文聚焦于数据有限的特定领域微调任务,首次提出利用自然语言进行微调的自然语言微调(NLFT)方法。通过利用目标语言模型强大的语言理解能力,NLFT 将自然语言指导附加到 token 级输出上。随后,通过计算概率识别显著 token。由于有效利用了语言信息,我们提出的方法显著降低了训练成本。它显著提升了训练效率,在准确率、节省时间和资源节约方面全面优于强化微调算法。此外,在宏观层面上,NLFT 可被视为 SFT 的 token 级细粒度优化,从而无需预热即可高效替代 SFT 过程(而 ReFT 需要多轮 SFT 预热)。与 SFT 相比,NLFT 不增加算法复杂度,保持 O(n)。在 GSM8K 数据集上的大量实验表明,仅使用 50 个数据实例,NLFT 实现的准确率提升超过 SFT 219%。与 ReFT 相比,NLFT 的时间复杂度和空间复杂度分别降低了 78.27% 和 92.24%。NLFT 的优越技术正在为网络边缘资源受限时部署各种创新 LLM 微调应用铺平道路。我们的代码已在 https://github.com/Julia-LiuJ/NLFT 发布。

英文摘要:

Large language model fine-tuning techniques typically depend on extensive labeled data, external guidance, and feedback, such as human alignment, scalar rewards, and demonstration. However, in practical application, the scarcity of specific knowledge poses unprecedented challenges to existing fine-tuning techniques. In this paper, focusing on fine-tuning tasks in specific domains with limited data, we introduce Natural Language Fine-Tuning (NLFT), which utilizes natural language for fine-tuning for the first time. By leveraging the strong language comprehension capability of the target LM, NLFT attaches the guidance of natural language to the token-level outputs. Then, saliency tokens are identified with calculated probabilities. Since linguistic information is effectively utilized in NLFT, our proposed method significantly reduces training costs. It markedly enhances training efficiency, comprehensively outperforming reinforcement fine-tuning algorithms in accuracy, time-saving, and resource conservation. Additionally, on the macro level, NLFT can be viewed as a token-level fine-grained optimization of SFT, thereby efficiently replacing the SFT process without the need for warm-up (as opposed to ReFT requiring multiple rounds of warm-up with SFT). Compared to SFT, NLFT does not increase the algorithmic complexity, maintaining O(n). Extensive experiments on the GSM8K dataset demonstrate that NLFT, with only 50 data instances, achieves an accuracy increase that exceeds SFT by 219%. Compared to ReFT, the time complexity and space complexity of NLFT are reduced by 78.27% and 92.24%, respectively. The superior technique of NLFT is paving the way for the deployment of various innovative LLM fine-tuning applications when resources are limited at network edges. Our code has been released at https://github.com/Julia-LiuJ/NLFT.

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

↑