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

自我评估作为抵御针对 LLM 的对抗性攻击的防御手段

Self-Evaluation as a Defense Against Adversarial Attacks on LLMs

National University of Singapore(新加坡国立大学)

Hannah Brown, Leon Lin, Kenji Kawaguchi, Michael Shieh

AI总结:

该研究提出无需微调的 LLM 自我评估防御框架,通过预训练模型检查生成器的输入与输出,在开源和闭源模型上均显著降低攻击成功率,并表现出更强抗攻击性。

摘要:

我们提出了一种利用自我评估来抵御针对 LLM 的对抗性攻击的防御方法。我们的方法不需要模型微调,而是使用预训练模型来评估生成器模型的输入和输出;与其他基于微调的方法相比,这显著降低了实施成本。我们的方法能够显著降低针对开源和闭源 LLM 的攻击成功率,其降幅超过 Llama-Guard2 以及常用内容审核 API 所展示的效果。我们对该方法的有效性进行了分析,包括在多种场景下尝试攻击评估器,结果表明它也比现有方法更能抵御攻击。代码和数据将在 https://github.com/Linlt-leon/self-eval 提供。

英文摘要:

We introduce a defense against adversarial attacks on LLMs utilizing self-evaluation. Our method requires no model fine-tuning, instead using pre-trained models to evaluate the inputs and outputs of a generator model, significantly reducing the cost of implementation in comparison to other, finetuning-based methods. Our method can significantly reduce the attack success rate of attacks on both open and closed-source LLMs, beyond the reductions demonstrated by Llama-Guard2 and commonly used content moderation APIs. We present an analysis of the effectiveness of our method, including attempts to attack the evaluator in various settings, demonstrating that it is also more resilient to attacks than existing methods. Code and data will be made available at https://github.com/Linlt-leon/self-eval.

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

↑