Skip to main content
QUICK REVIEW

[论文解读] Prompt as Triggers for Backdoor Attack: Examining the Vulnerability in Language Models

Shuai Zhao, Jinming Wen|arXiv (Cornell University)|May 2, 2023
Adversarial Robustness in Machine Learning参考文献 55被引用 8
一句话总结

本文提出 ProAttack,一种干净标签后门攻击,利用提示本身作为触发器,在提示式学习中实现近乎100%的攻击成功率,在丰富资源和小样本设置下均不需要外部触发器。

ABSTRACT

The prompt-based learning paradigm, which bridges the gap between pre-training and fine-tuning, achieves state-of-the-art performance on several NLP tasks, particularly in few-shot settings. Despite being widely applied, prompt-based learning is vulnerable to backdoor attacks. Textual backdoor attacks are designed to introduce targeted vulnerabilities into models by poisoning a subset of training samples through trigger injection and label modification. However, they suffer from flaws such as abnormal natural language expressions resulting from the trigger and incorrect labeling of poisoned samples. In this study, we propose ProAttack, a novel and efficient method for performing clean-label backdoor attacks based on the prompt, which uses the prompt itself as a trigger. Our method does not require external triggers and ensures correct labeling of poisoned samples, improving the stealthy nature of the backdoor attack. With extensive experiments on rich-resource and few-shot text classification tasks, we empirically validate ProAttack's competitive performance in textual backdoor attacks. Notably, in the rich-resource setting, ProAttack achieves state-of-the-art attack success rates in the clean-label backdoor attack benchmark without external triggers.

研究动机与目标

  • 激发对基于提示的 NLP 系统中后门漏洞的研究。
  • 提出一种使用提示作为触发器的干净标签后门攻击(无外部触发器)。
  • 在丰富资源与小样本文本分类任务中证明 ProAttack 的有效性。

提出的方法

  • 提出一个基于提示的干净标签后门攻击:中毒样本使用触发提示符,而标签仍然正确。
  • 通过提示工程(Prompt Engineering)设计中毒样本和清洁样本,使触发器嵌入训练数据中(PE(x, prompt_p) 与 PE(x, prompt_c))。
  • 在混合数据集上训练受害模型,以在推断阶段实现后门行为。
  • 定义一个正式的后门目标函数,结合清洁与中毒损失(L = E[(x_clean', y)]+E[(x_poison', y)]; 交叉熵损失)。
  • 在多个数据集与模型上对基线与防御方法进行评估(数据集:SST-2、OLID、AG 的 News、COLA、MR、TREC;模型:BERT、RoBERTa、XLNet、GPT-Neo)。
  • 通过 t-SNE 分析特征分布,理解触发器引起的分离现象。

实验结果

研究问题

  • RQ1提示是否可以在基于提示的学习中作为后门触发器而不需要外部触发器?
  • RQ2在丰富资源与小样本设置下,基于提示的干净标签后门攻击有多大效果?
  • RQ3提示是否会改变模型对防御方法和检测技术的鲁棒性?
  • RQ4中毒样本数量对清洁准确度和攻击成功率有何影响?
  • RQ5触发提示在保持标签正确性的同时,是否能在不同数据集与模型上实现高攻击成功率?

主要发现

  • ProAttack 在丰富资源设置下,对若干数据集与模型实现了近100%的攻击成功率。
  • 带有基于提示的触发器的中毒样本保持了清洁准确度,导致清洁准确度下降很小而攻击成功率仍然很高。
  • ProAttack 优于若干中毒标签与干净标签基线,并在许多情形下能够规避 ONION 与 SCPD 等防御。
  • 在小样本设置下,ProAttack 在 GPT-Neo 上实现近乎完美的攻击成功率,并在多个数据集上保持竞争力。
  • 该攻击诱导出提示模型与受害模型的显著特征分布差异,表明提示作为有效触发器。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。