2025-08-29 · 进阶 · 机器学习 · 自然语言处理

Turning the Spell Around: Lightweight Alignment Amplification via Rank-One Safety Injection

该论文提出了一种名为ROSI的方法,通过向大型语言模型(LLM)的权重中注入一维安全方向,增强其拒绝有害请求的能力,同时保持模型在标准基准测试中的效用。

更新于 2025-10-13。作者:Harethah Abu Shairah、Hasan Abed Al Kader Hammoud、George Turkiyyah、Bernard Ghanem。

中文摘要

大型语言模型(LLMs)中的安全对齐通常涉及调节内部表示以拒绝有害请求。最近的研究表明,这些安全机制可以通过消除或去除模型中特定的表示方向来绕过。在本文中,我们提出了相反的方法:秩一安全注入(ROSI),这是一种白盒方法,通过永久地将模型的激活引导到拒绝调节子空间来增强模型的安全对齐。ROSI作为一种简单的、无需微调的秩一权重修改,应用于所有残差流写入矩阵。所需的安全方向可以从一组小规模的有害和无害指令对中计算得出。我们表明,ROSI可以持续提高安全拒绝率——如Llama Guard 3所评估的——同时保持模型在标准基准测试(如MMLU、HellaSwag和Arc)上的效用。此外,我们还表明,ROSI还可以通过增强其自身的潜在安全方向来重新对齐“未审查”的模型,展示了其作为有效最后一英里安全程序的实用性。我们的结果表明,有针对性的、可解释的权重引导是一种低成本且有效的机制,可以改善LLM的安全性,补充了更资源密集的微调范式。

英文摘要

Safety alignment in Large Language Models (LLMs) often involves mediating internal representations to refuse harmful requests. Recent research has demonstrated that these safety mechanisms can be bypassed by ablating or removing specific representational directions within the model. In this paper, we propose the opposite approach: Rank-One Safety Injection (ROSI), a white-box method that amplifies a model's safety alignment by permanently steering its activations toward the refusal-mediating subspace. ROSI operates as a simple, fine-tuning-free rank-one weight modification applied to all residual stream write matrices. The required safety direction can be computed from a small set of harmful and harmless instruction pairs. We show that ROSI consistently increases safety refusal rates - as evaluated by Llama Guard 3 - while preserving the utility of the model on standard benchmarks such as MMLU, HellaSwag, and Arc. Furthermore, we show that ROSI can also re-align 'uncensored' models by amplifying their own latent safety directions, demonstrating its utility as an effective last-mile safety procedure. Our results suggest that targeted, interpretable weight steering is a cheap and potent mechanism to improve LLM safety, complementing more resource-intensive fine-tuning paradigms.

解读

一句话总结

该论文提出了一种名为ROSI的方法,通过向大型语言模型(LLM)的权重中注入一维安全方向,增强其拒绝有害请求的能力,同时保持模型在标准基准测试中的效用。

问题1:这篇论文想要解决什么具体问题?

问题2:论文的核心创新点是什么?

问题3:实验结果如何验证了方法的有效性?

问题4:这个研究的实际应用价值是什么?

来源