无需训练即可擦除多模态扩散模型中的敏感概念
Semantic Steering for Controllable Generation: Tuning-Free Concept Erasure in Multimodal Diffusion Transformers

- 通过分析中间层语义表示,用向量操控生成内容
- 在多个模型上实现领先的概念擦除效果,且零训练开销
- 适合需快速部署安全控制的工业级生成系统
多模态扩散变压器(MM-DiTs)在文本到图像生成方面表现卓越,超越传统U-Net基扩散模型。然而其强大生成能力也带来安全风险,可能产生敏感或不当内容。现有概念擦除方法大多需修改模型参数,往往依赖特定架构,难以应用于已部署的大模型。部分无训练方法在先进大规模MM-DiTs上面临挑战,因其知识深度嵌入、语义空间广且文本编码器具上下文依赖性。为此,我们提出直接操纵模型内部表示来擦除概念。基于对MM-DiT块级生成角色的深入分析,发现文本条件语义表示在中间块最显著。据此,从中间块提取目标概念与理想安全概念的表示,构建二者差值作为引导向量,并注入连续的早期与中间块。仅操作稀疏文本分支令牌,结合修正流的直线采样轨迹,该方法实现高效概念擦除,开销极小且无需训练。在多种MM-DiT模型上的大量实验表明,本方法在擦除多样概念方面达到当前最优性能,有效控制输出结果,且对对抗攻击保持鲁棒。
原文摘要 · Abstract (English)
Multimodal Diffusion Transformers (MM-DiTs) have demonstrated remarkable text-to-image generation performance, surpassing traditional U-Net-based diffusion models. Nevertheless, their powerful generative capabilities also raise significant safety concerns, as they may generate sensitive or inappropriate content. While existing concept erasure methods aim to mitigate such risks, most require modifying model parameters, which are often architecture-specific and impractical for deployed larger models. Several tuning-free approaches face challenges when applied to advanced large-scale MM-DiTs due to their deeply embedded knowledge, broad semantic space, and context-dependent text encoders. To address these challenges, we propose to erase concepts by directly manipulating the model's internal representations. Our key insight, derived from an in-depth analysis of MM-DiT's block-wise generative roles, is that text-conditioned semantic representations are most salient in the middle blocks of MM-DiTs. Based on this, we extract representations of an unwanted concept and a desirable safe one from the middle block, construct a steering vector from their difference, and inject this single vector into consecutive early and middle blocks. By operating exclusively on the sparse text-branch tokens and leveraging the straight sampling trajectory of rectified flow, our method achieves effective concept erasure with negligible overhead and without any training. Extensive experiments across MM-DiT models demonstrate that our method achieves state-of-the-art performance in erasing diverse concepts, enables effective control over the final output, and remains robust to adversarial attacks.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。