Safety-aligned language models refuse harmful requests through learned refusal behaviors encoded in their internal representations. Recent activation-based jailbreaking methods circumvent these safety mechanisms by applying orthogonal projections to remove refusal directions, but these approaches treat refusal as a one-dimensional phenomenon and ignore the rich distributional structure of model activations. We introduce a principled framework based on optimal transport theory that transforms the entire distribution of harmful activations to match harmless ones. By combining PCA with closed-form Gaussian optimal transport, we achieve efficient computation in high-dimensional representation spaces while preserving essential geometric structure. Across six models (Llama-2, Llama-3.1, Qwen-2.5; 7B-32B parameters), our method achieves up to 11% higher attack success rates than state-of-the-art baselines while maintaining comparable perplexity, demonstrating superior preservation of model capabilities. Critically, we discover that layer-selective intervention (applying optimal transport to 1-2 carefully chosen layers at approximately 40-60% network depth) substantially outperforms full-network interventions, revealing that refusal mechanisms may be localized rather than distributed. Our analysis provides new insights into the geometric structure of safety representations and suggests that current alignment methods may be vulnerable to distributional attacks beyond simple direction removal.


翻译:安全对齐的语言模型通过学习编码在其内部表征中的拒绝行为来拒绝有害请求。最近的基于激活的越狱方法通过应用正交投影来消除拒绝方向,从而规避这些安全机制,但这些方法将拒绝视为一维现象,忽略了模型激活的丰富分布结构。我们引入了一个基于最优传输理论的原理性框架,该框架将有害激活的整个分布转换为与无害激活相匹配。通过将主成分分析与闭式高斯最优传输相结合,我们在高维表征空间中实现了高效计算,同时保留了关键的几何结构。在六个模型(Llama-2、Llama-3.1、Qwen-2.5;7B-32B参数)上的实验表明,我们的方法实现了比最先进基线高出11%的攻击成功率,同时保持了可比的困惑度,证明了其对模型能力的优越保留。关键的是,我们发现分层选择性干预(在约40-60%网络深度的1-2个精心选择的层上应用最优传输)显著优于全网络干预,这表明拒绝机制可能是局部化的而非分布式。我们的分析为安全表征的几何结构提供了新的见解,并表明当前的对齐方法可能容易受到超越简单方向消除的分布性攻击。

0
下载
关闭预览

相关内容

《军事大语言模型的拒绝率测量与消除》
专知会员服务
13+阅读 · 3月13日
大语言模型越狱攻击:模型、根因及其攻防演化
专知会员服务
22+阅读 · 2025年4月28日
大语言模型越狱攻击: 模型、根因及其攻防演化
专知会员服务
24+阅读 · 2025年2月16日
《大语言模型中的对齐伪造》最新137页
专知会员服务
11+阅读 · 2025年1月27日
Llama-3-SynE:实现有效且高效的大语言模型持续预训练
专知会员服务
36+阅读 · 2024年7月30日
大型语言模型的高效提示方法综述
专知会员服务
75+阅读 · 2024年4月2日
绝对干货!NLP预训练模型:从transformer到albert
新智元
13+阅读 · 2019年11月10日
【好文解析】ICASSP最佳学生论文:深度对抗声学模型训练框架
中国科学院自动化研究所
13+阅读 · 2018年4月28日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Arxiv
0+阅读 · 2月2日
Arxiv
0+阅读 · 1月31日
VIP会员
最新内容
美国当前高超音速导弹发展概述
专知会员服务
0+阅读 · 58分钟前
《高超音速武器:一项再度兴起的技术》120页slides
无人机蜂群建模与仿真方法
专知会员服务
1+阅读 · 今天14:08
澳大利亚发布《国防战略(2026年)》
专知会员服务
0+阅读 · 今天13:42
【CMU博士论文】迈向基于基础先验的 4D 感知研究
专知会员服务
0+阅读 · 今天13:46
全球高超音速武器最新发展趋势
专知会员服务
1+阅读 · 今天13:17
相关基金
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员