通过激活一致性训练提升大模型抗对抗性提示攻击能力
Mitigating Adaptive Attacks against Reasoning Models with Activation Consistency Training

- 用激活层一致性约束防御对抗性提示注入
- 激活级训练在五种推理模型上均优于输出级方法
- 可解释性强,仅需自监督数据对,适合安全训练场景
随着大语言模型推理能力增强,其链式思维引入了新的复杂性,使防御对抗性越狱和提示注入更具挑战。本文研究一致性训练这一微调策略,强制干净提示与对抗性重写提示产生一致行为,评估了输出级(BCT)和激活级(ACT)两种主要变体在五种推理模型上的表现。将两者均形式化为提示注入防御方法,发现ACT在无需人工标注的情况下,性能媲美其他基于训练的防御方案。实验还拓展至越狱场景,表明ACT对自适应攻击仍具更强鲁棒性。机制分析显示,ACT的防御效果体现在助手回应边界处激活空间的近似线性偏移。训练后,可通过单一控制方向实现拒绝行为,且对正常输入影响极小。即使将模型的链式思维替换为未受保护基模型的合规轨迹,ACT仍能有效拒绝预填充越狱指令。结果表明,监督内部表征是推理模型安全训练中一种高效且可解释的方法。
原文摘要 · Abstract (English)
As LLMs gain stronger reasoning capabilities, their extended chain-of-thought introduces new degrees of complexity for defending against adversarial jailbreaks and prompt injection. We study consistency training, a family of fine-tuning objectives that enforce identical behavior on clean prompts and adversarial rewrites, and evaluate its two main variants, output-level (BCT) and activation-level (ACT), across five reasoning models. We formulate both methods as a prompt injection defense and find ACT to be competitive with other training-based defenses while requiring only self-supervised pairs of clean and wrapped prompts. Our experiments also generalize both techniques within the jailbreak setting, demonstrating that ACT remains more robust to adaptive attacks. We also provide mechanistic evidence that ACT's defense against jailbreaks is encoded as a roughly linear shift in activation space at the assistant-turn boundary. After ACT training, we can recover a single steering direction that controls refusal on reasoning models with minimal effect on benign inputs. We find that ACT remains robust even when the model's chain-of-thought is replaced with a compliant trace from the undefended base model, pivoting to refuse prefilled jailbreaks. Together, these results suggest that supervising internal representations is a surprisingly effective and interpretable approach to various forms of safety training in reasoning models.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。