arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2605.07447cs.CVcs.AIcs.CLcs.LG
收藏

稀疏自编码器作为视觉语言模型中对抗攻击检测的即插即用防火墙

Sparse Autoencoders as Plug-and-Play Firewalls for Adversarial Attack Detection in VLMs

Magellan Technology Research Institute (MTRI)(马杰伦技术研究 institute);Waseda University(早稻田大学)

Hao Wang, Yiqun Sun, Pengfei Wei, Lawrence B. Hsieh, Daisuke Kawahara

AI总结:

本文提出基于稀疏自编码器的轻量级对抗攻击检测框架SAEgis,通过插入预训练VLM中的稀疏自编码模块,利用学习到的稀疏潜在特征检测对抗扰动输入,实验显示其在跨领域和跨攻击设置中表现优异,且无需额外对抗训练。

摘要:

视觉语言模型(VLMs)已迅速发展并广泛应用于现实世界,尤其是在基于代理的系统中。然而,其安全性受到较少关注。即使最新的专有和开源VLMs仍极易受到对抗攻击的影响,导致下游应用面临重大风险。本文提出了一种基于稀疏自编码器(SAEs)的新型轻量级对抗攻击检测框架,称为SAEgis。通过在预训练VLM中插入SAE模块并使用标准重建目标进行训练,发现学习到的稀疏潜在特征自然捕捉攻击相关信号。这些特征能够可靠地分类输入图像是否被对抗性扰动篡改,即使对于以前未见过的样本也是如此。大量实验表明,SAEgis在域内、跨域和跨攻击设置中均表现出色,特别是在跨域泛化方面比现有基线有显著提升。此外,结合多层信号进一步提高了鲁棒性和稳定性。据我们所知,这是首次探索将SAE作为即插即用机制用于VLMs中的对抗攻击检测的工作。我们的方法不需要额外的对抗训练,引入了最小的开销,并提供了一种改进现实世界VLM系统安全性的实用方法。

英文摘要:

Vision-language models (VLMs) have advanced rapidly and are increasingly deployed in real-world applications, especially with the rise of agent-based systems. However, their safety has received relatively limited attention. Even the latest proprietary and open-weight VLMs remain highly vulnerable to adversarial attacks, leaving downstream applications exposed to significant risks. In this work, we propose a novel and lightweight adversarial attack detection framework based on sparse autoencoders (SAEs), termed SAEgis. By inserting an SAE module into a pretrained VLM and training it with standard reconstruction objectives, we find that the learned sparse latent features naturally capture attack-relevant signals. These features enable reliable classification of whether an input image has been adversarially perturbed, even for previously unseen samples. Extensive experiments show that SAEgis achieves strong performance across in-domain, cross-domain, and cross-attack settings, with particularly large improvements in cross-domain generalization compared to existing baselines. In addition, combining signals from multiple layers further improves robustness and stability. To the best of our knowledge, this is the first work to explore SAE as a plug-and-play mechanism for adversarial attack detection in VLMs. Our method requires no additional adversarial training, introduces minimal overhead, and provides a practical approach for improving the safety of real-world VLM systems.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑