让大模型学会避开错误更新,提升小样本适应能力
Learning from the Undesirable: Robust Adaptation of Language Models without Forgetting
- 通过模拟错误更新来增强模型内部表示的稳定性
- 数学任务平均性能提升16.8%,且避免了性能下降
- 适合需要小样本微调又怕遗忘预训练知识的场景
语言模型常通过监督微调(SFT)适配下游任务,但在数据有限时易过拟合,依赖虚假模式或损害通用能力。本文提出学习不可取(LfU)正则化方法,通过引入对‘不可取’更新(如导致不良行为的梯度上升)的表示一致性约束,使模型在微调中更鲁棒。该方法利用不可取更新作为表示层面的数据增强,有效提升小样本下的泛化能力。实验显示,在多个下游任务上,使用LfU的模型相比标准SFT平均提升16.8%的数学任务表现,且后者甚至出现性能退化;同时,输出对提示变化的敏感度降低92.1%的标准差,证明其在保持预训练知识的同时显著增强适应性与稳健性。
原文摘要 · Abstract (English)
Language models (LMs) are often adapted through supervised fine-tuning (SFT) to specialize their capabilities for downstream tasks. However, in typical scenarios where the fine-tuning data is limited, e.g., compared to pre-training, SFT can lead LMs to overfit, causing them to rely on spurious patterns within the target task or to compromise other broadly useful capabilities as a side effect of narrow specialization. In this paper, we propose Learning-from-the-Undesirable (LfU), a simple yet effective regularization scheme for SFT to mitigate overfitting issues when fine-tuning LMs with limited data. Specifically, we aim to regularize the fine-tuning process to favor solutions that are resilient to "undesirable" model updates, e.g., gradient ascent steps that steer the model toward undesirable behaviors. To this end, we propose a novel form of consistency regularization that directly aligns internal representations of the model with those after an undesirable update. By leveraging representation-level data augmentation through undesirable updates, LfU effectively promotes generalization under limited data. Our experiments on diverse LM downstream tasks show that LfU serves as an effective prior that enhances adaptability while preserving pretrained knowledge. For example, our LM from LfU achieves a 16.8% average improvement on math tasks compared to vanilla SFT on the same dataset, where the latter even leads to degraded performance on those tasks. Furthermore, LfU exhibits improved robustness to prompt variations, e.g., yielding a 92.1% lower standard deviation in output performances compared to SFT, highlighting its versatile effects.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。