arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2512.10150cs.CLcs.AI
收藏

遗忘的安全性:通过持续学习保持大型语言模型的安全对齐

Unforgotten Safety: Preserving Safety Alignment of Large Language Models with Continual Learning

Lama Alssum, Hani Itani, Hasan Abed Al Kader Hammoud, Philip Torr, Adel Bibi, Bernard Ghanem

AI总结:

本文通过持续学习方法有效缓解大型语言模型在适应新任务时的安全退化问题,证明了持续学习在保持模型安全性和任务实用性方面的有效性。

摘要:

随着大型语言模型(LLMs)的普及化,其安全性对齐变得越来越重要。在本文中,我们研究了在适应新任务时出现的安全退化问题。我们将这种安全妥协归因于灾难性遗忘,并将在微调过程中保持安全的问题框架为持续学习(CL)问题。我们考虑了“微调作为服务”的设置,其中用户将他们的数据上传到服务提供商,以获得一个在用户选定任务上表现优异的定制模型。我们采用了几种文献中的持续学习方法,并系统地评估了它们减轻安全退化的能力。这些包括基于正则化的、基于记忆的以及模型合并的方法。我们考虑了两种场景,(1)无害的用户数据和(2)被污染的用户数据。我们的结果表明,持续学习方法在降低攻击成功率方面比标准微调更有效。其中,DER在性能上优于其他持续学习方法和现有的安全保持基线,同时保持任务实用性。这些发现适用于三个下游任务(GSM8K、SST2、Code)和三个模型家族(LLaMA2-7B、Mistral-7B、Gemma-2B),确立了持续学习作为保持安全的实用解决方案。

英文摘要:

The safety alignment of large language models (LLMs) is becoming increasingly important with their democratization. In this paper, we study the safety degradation that comes with adapting LLMs to new tasks. We attribute this safety compromise to catastrophic forgetting and frame the problem of preserving safety when fine-tuning as a continual learning (CL) problem. We consider the fine-tuning-as-a-service setup where the user uploads their data to a service provider to get a customized model that excels on the user's selected task. We adapt several CL approaches from the literature and systematically evaluate their ability to mitigate safety degradation. These include regularization-based, memory-based, and model merging approaches. We consider two scenarios, (1) benign user data and (2) poisoned user data. Our results demonstrate that CL approaches consistently achieve lower attack success rates than standard fine-tuning. Among these, DER outperforms both other CL methods and existing safety-preserving baselines while maintaining task utility. These findings generalize across three downstream tasks (GSM8K, SST2, Code) and three model families (LLaMA2-7B, Mistral-7B, Gemma-2B), establishing CL as a practical solution to preserve safety.

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

↑