arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2402.13148cs.LGcs.CR
收藏

通过上下文内对抗博弈防御越狱提示词

Defending Jailbreak Prompts via In-Context Adversarial Game

University of Notre Dame(圣母大学);INRIA(法国国家信息与自动化研究所);King Abdullah University of Science and Technology(阿卜杜拉国王科技大学)

Yujun Zhou, Yufei Han, Haomin Zhuang, Kehan Guo, Zhenwen Liang, Hongyan Bao, Xiangliang Zhang

AI总结:

针对大语言模型易受越狱攻击的安全问题,提出无需微调的上下文内对抗博弈(ICAG)方法,通过攻防智能体迭代优化动态增强防御,可显著降低多场景越狱成功率且具备跨模型迁移性。

摘要:

大语言模型(LLM)在各类应用中展现出卓越能力,但人们对其安全性的担忧始终存在,尤其是易受越狱攻击的漏洞。受深度学习中的对抗训练与LLM智能体学习过程的启发,我们提出了上下文内对抗博弈(In-Context Adversarial Game, ICAG),无需微调即可防御越狱攻击。ICAG利用智能体学习开展对抗博弈,旨在动态扩展知识以抵御越狱。与依赖静态数据集的传统方法不同,ICAG采用迭代流程同时优化防御智能体与攻击智能体,这一持续改进过程可强化对新生成越狱提示词的防御能力。实证研究验证了ICAG的有效性:经ICAG防护的LLM在多种攻击场景下的越狱成功率显著降低。此外,ICAG在其他LLM上展现出出色的迁移性,具备成为通用防御机制的潜力。

英文摘要:

Large Language Models (LLMs) demonstrate remarkable capabilities across diverse applications. However, concerns regarding their security, particularly the vulnerability to jailbreak attacks, persist. Drawing inspiration from adversarial training in deep learning and LLM agent learning processes, we introduce the In-Context Adversarial Game (ICAG) for defending against jailbreaks without the need for fine-tuning. ICAG leverages agent learning to conduct an adversarial game, aiming to dynamically extend knowledge to defend against jailbreaks. Unlike traditional methods that rely on static datasets, ICAG employs an iterative process to enhance both the defense and attack agents. This continuous improvement process strengthens defenses against newly generated jailbreak prompts. Our empirical studies affirm ICAG's efficacy, where LLMs safeguarded by ICAG exhibit significantly reduced jailbreak success rates across various attack scenarios. Moreover, ICAG demonstrates remarkable transferability to other LLMs, indicating its potential as a versatile defense mechanism.

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

↑