ChatPaper.aiChatPaper

模型编辑中的微调之道

Fine-tuning Done Right in Model Editing

September 26, 2025
作者: Wanli Yang, Fei Sun, Rui Tang, Hongyu Zang, Du Su, Qi Cao, Jingang Wang, Huawei Shen, Xueqi Cheng
cs.AI

摘要

微调作为适应大型语言模型的基础方法,长期以来被认为在模型编辑方面效果不佳。本文挑战了这一观点,指出所报告的失败并非源于微调本身固有的局限性,而是源于将其应用于编辑任务的顺序性质——一种单次深度优先的流程,即在继续之前将每个样本优化至收敛。尽管这种深度优先流程结合逐样本更新看似直观,但它过度优化了每次编辑,并引发了编辑间的干扰。我们的对照实验表明,只需将微调恢复为标准广度优先(即基于轮次)的流程,并采用小批量优化,就能显著提升其在模型编辑中的有效性。此外,编辑中的微调还因继承自先前方法的次优调参位置而受限。通过对调参位置的系统分析,我们提出了LocFT-BF,这是一种建立在恢复微调框架之上的简单而有效的局部化编辑方法。跨多种大型语言模型和数据集的广泛实验表明,LocFT-BF大幅超越了现有最先进方法。值得注意的是,据我们所知,它是首个在不牺牲通用能力的情况下,支持10万次编辑和720亿参数模型的方法,将实践边界扩展了十倍。通过澄清长期存在的误解并引入原则性的局部化调优策略,我们将微调从被低估的基线提升为模型编辑的领先方法,为未来研究奠定了坚实基础。
English
Fine-tuning, a foundational method for adapting large language models, has long been considered ineffective for model editing. Here, we challenge this belief, arguing that the reported failure arises not from the inherent limitation of fine-tuning itself, but from adapting it to the sequential nature of the editing task, a single-pass depth-first pipeline that optimizes each sample to convergence before moving on. While intuitive, this depth-first pipeline coupled with sample-wise updating over-optimizes each edit and induces interference across edits. Our controlled experiments reveal that simply restoring fine-tuning to the standard breadth-first (i.e., epoch-based) pipeline with mini-batch optimization substantially improves its effectiveness for model editing. Moreover, fine-tuning in editing also suffers from suboptimal tuning parameter locations inherited from prior methods. Through systematic analysis of tuning locations, we derive LocFT-BF, a simple and effective localized editing method built on the restored fine-tuning framework. Extensive experiments across diverse LLMs and datasets demonstrate that LocFT-BF outperforms state-of-the-art methods by large margins. Notably, to our knowledge, it is the first to sustain 100K edits and 72B-parameter models,10 x beyond prior practice, without sacrificing general capabilities. By clarifying a long-standing misconception and introducing a principled localized tuning strategy, we advance fine-tuning from an underestimated baseline to a leading method for model editing, establishing a solid foundation for future research.
PDF172September 29, 2025