arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2409.04142cs.CRcs.AI
收藏

上下文是关键:针对 Vision Transformer 上下文内学习的后门攻击

Context is the Key: Backdoor Attacks for In-Context Learning with Vision Transformers

Radboud University(拉德堡德大学);Ikerlan Research Centre(伊克尔兰研究中心);University College London(伦敦大学学院)

Gorka Abad, Stjepan Picek, Lorenzo Cavallaro, Aitor Urbieta

AI总结:

本文利用 ViT 的上下文内学习能力,通过数据投毒提出任务特定与可泛化至未知任务的动态后门攻击,并证明提示和微调难以有效移除后门。

摘要:

由于训练成本高昂,大模型(LM)从业者通常使用从不可信来源下载的预训练模型,这可能导致获得已被攻陷的模型。上下文内学习是 LM 根据提示或上下文执行多项任务的能力。这会催生新型攻击,例如根据模型被提示的方式表现出动态行为的后门攻击。在本文中,我们利用 vision transformer(ViT)根据提示执行不同任务的能力。随后,通过数据投毒,我们研究了两类新威胁:i)任务特定后门,攻击者选择一个目标任务进行攻击,在测试时,只有在触发器存在的情况下所选任务才会被攻陷。同时,任何其他任务都不会受到影响,即使在提示中包含触发器也是如此。我们成功攻击了每一个受测模型,在目标任务上实现了最高 89.90% 的性能下降。ii)我们对该攻击进行了泛化,使后门能够影响任何任务,甚至包括训练阶段未见过的任务。我们的攻击在每一个受测模型上都取得了成功,最高实现了 13 倍的性能下降。最后,我们研究了提示和微调作为从模型中移除后门的技术的鲁棒性。我们发现这些方法存在不足;在最佳情况下,它们也只能将性能下降从 89.90% 降低到 73.46%。

英文摘要:

Due to the high cost of training, large model (LM) practitioners commonly use pretrained models downloaded from untrusted sources, which could lead to owning compromised models. In-context learning is the ability of LMs to perform multiple tasks depending on the prompt or context. This can enable new attacks, such as backdoor attacks with dynamic behavior depending on how models are prompted. In this paper, we leverage the ability of vision transformers (ViTs) to perform different tasks depending on the prompts. Then, through data poisoning, we investigate two new threats: i) task-specific backdoors where the attacker chooses a target task to attack, and only the selected task is compromised at test time under the presence of the trigger. At the same time, any other task is not affected, even if prompted with the trigger. We succeeded in attacking every tested model, achieving up to 89.90\% degradation on the target task. ii) We generalize the attack, allowing the backdoor to affect \emph{any} task, even tasks unseen during the training phase. Our attack was successful on every tested model, achieving a maximum of $13\times$ degradation. Finally, we investigate the robustness of prompts and fine-tuning as techniques for removing the backdoors from the model. We found that these methods fall short and, in the best case, reduce the degradation from 89.90\% to 73.46\%.

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

↑