小学习率+新方法可让大模型微调后仍保持强通用能力。
SFT Doesn't Always Hurt General Capabilities: Revisiting Domain-Specific Fine-Tuning in LLMs
- 用小学习率微调,能减少通用能力下降
- 提出TALR方法,在多个数据集上表现更优
- 适合需要兼顾专业与通用能力的场景
在领域特定数据集上进行监督微调(SFT)是适配大语言模型(LLM)至专业任务的常用方法,但常被认为会损害其通用能力。本文重新审视这一权衡,通过实证与理论分析发现:使用较小的学习率可显著缓解通用性能下降,同时保持目标领域的性能表现。进一步提出理论解释,并据此设计新的令牌自适应损失重加权方法(TALR)。评估多种策略(包括L2正则化、LoRA、模型平均、FLOW等),结果表明,尽管无方法能完全消除权衡,但TALR在平衡领域性能提升与通用能力维持方面始终优于基线。最后,总结出两条实用建议:(i)采用小学习率以获得较好权衡;(ii)若需更强平衡,推荐使用TALR。
原文摘要 · Abstract (English)
Supervised Fine-Tuning (SFT) on domain-specific datasets is a common approach to adapt Large Language Models (LLMs) to specialized tasks but is often believed to degrade their general capabilities. In this work, we revisit this trade-off and present both empirical and theoretical insights. First, we show that SFT does not always hurt: using a smaller learning rate can substantially mitigate general performance degradation while preserving comparable target-domain performance. We then provide a theoretical analysis that explains these phenomena and further motivates a new method, Token-Adaptive Loss Reweighting (TALR). Building on this, and recognizing that smaller learning rates alone do not fully eliminate general-performance degradation in all cases, we evaluate a range of strategies for reducing general capability loss, including L2 regularization, LoRA, model averaging, FLOW, and our proposed TALR. Experimental results demonstrate that while no method completely eliminates the trade-off, TALR consistently outperforms these baselines in balancing domain-specific gains and general capabilities. Finally, we distill our findings into practical guidelines for adapting LLMs to new domains: (i) using a small learning rate to achieve a favorable trade-off, and (ii) when a stronger balance is further desired, adopt TALR as an effective strategy.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。