arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2311.09763cs.CL

基于防御性示例的黑盒大型语言模型测试时后门缓解

Test-time Backdoor Mitigation for Black-Box Large Language Models with Defensive Demonstrations

University of Southern California(南加州大学);Harvard University(哈佛大学);University of California, Davis(加州大学戴维斯分校);University of Wisconsin-Madison(威斯康星大学麦迪逊分校)

Wenjie Mo, Jiashu Xu, Qin Liu, Jiongxiao Wang, Jun Yan, Hadi Askari, Chaowei Xiao, Muhao Chen

AI总结:

针对黑盒部署LLM的测试时后门防御空白,本研究提出基于干净数据池检索任务相关示例并与用户查询集成的方法,无需修改模型或了解其架构,可稳健防御实例级和指令级后门攻击且优于现有基线。

摘要:

现有后门防御研究主要集中在训练阶段,忽视了测试时防御这一关键方面。在作为网络服务部署、通常仅提供黑盒访问的大语言模型(LLMs)语境下,这一空白尤为突出,导致训练时防御不切实际。为填补该空白,本研究深入探讨将示例作为防御机制应对黑盒LLMs后门攻击的方法。我们从干净数据池中检索任务相关示例,并在测试时将其与用户查询集成。该方法无需修改或微调模型,也无需了解模型内部架构。上下文学习固有的对齐特性在缓解后门触发器影响、有效重新校准受妥协模型行为方面发挥关键作用。实验分析表明,该方法能稳健防御实例级和指令级后门攻击,在大多数评估场景中优于现有防御基线。

英文摘要:

Existing studies in backdoor defense have predominantly focused on the training phase, overlooking the critical aspect of testing time defense. This gap becomes pronounced in the context of LLMs deployed as Web Services, which typically offer only black-box access, rendering training-time defenses impractical. To bridge this gap, this study critically examines the use of demonstrations as a defense mechanism against backdoor attacks in black-box LLMs. We retrieve task-relevant demonstrations from a clean data pool and integrate them with user queries during testing. This approach does not necessitate modifications or tuning of the model, nor does it require insight into the model's internal architecture. The alignment properties inherent in in-context learning play a pivotal role in mitigating the impact of backdoor triggers, effectively recalibrating the behavior of compromised models. Our experimental analysis demonstrates that this method robustly defends against both instance-level and instruction-level backdoor attacks, outperforming existing defense baselines across most evaluation scenarios.

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

↑