arXiv:2602.02600cs.LGcs.AI2026-02被引 2

对比扩散与自回归模型的拒绝行为,发现扩散模型更抗越狱攻击。

Step-Wise Refusal Dynamics in Autoregressive and Diffusion Language Models

  • 提出SRI信号捕捉生成过程中的拒绝动态
  • 扩散采样下模型能恢复有害中间输出,自回归则易失败
  • 无需修改推理,仅用正常数据训练即可检测新攻击

扩散语言模型(DLMs)作为自回归(AR)模型的有力替代,具备并行解码、生成质量竞争力以及初步显示更强的越狱鲁棒性。然而,采样机制如何影响拒绝行为仍不明确。本文系统研究了逐步拒绝动态,发现扩散重掩码可促进从有害中间生成中恢复,且该行为与采样机制密切相关;将采样方式从自回归切换为扩散,即使在固定模型权重下也能提升越狱鲁棒性。为捕捉文本层面不可见的生成动态,我们提出步骤级拒绝内生动态(SRI)信号。SRI显示,自回归采样下恢复失败主要出现在异常区域,而扩散采样表现稳定。基于此,我们设计了一种无需修改推理的越狱检测器,仅需在良性SRI信号上训练即可泛化至未见攻击。实验表明,该检测器性能匹配或超越现有基线,开销极低。

原文摘要 · Abstract (English)

Diffusion language models (DLMs) have recently emerged as a competitive alternative to autoregressive (AR) models, offering parallel decoding, competitive generation quality, and initial evidence of improved jailbreak robustness. Despite this progress, the role of sampling mechanisms in shaping refusal behavior remains poorly understood. To address this gap, we present a comprehensive study of step-wise refusal dynamics. We show that diffusion remasking can promote recovery from harmful intermediate generations, provide evidence that this behavior is tied to the sampling mechanism, and demonstrate that switching from AR to diffusion sampling improves jailbreak robustness, including under fixed model weights. To capture generation dynamics not observable at the text level, we propose the Step-Wise Refusal Internal Dynamics (SRI) signal. Consistent with our text-level findings, SRI shows that recovery fails primarily under AR sampling, with these failures often appearing anomalous relative to harmless generations in the SRI space. Based on this observation, we show that SRI enables a simple jailbreak detector that does not modify inference and generalizes to unseen attacks by training only on benign SRI signals. Our evaluation shows that this detector matches or outperforms existing jailbreak detection baselines while adding negligible overhead.

语言模型越狱防御扩散模型生成安全

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。