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

MART:通过多轮自动红队测试提升LLM安全性

MART: Improving LLM Safety with Multi-round Automatic Red-Teaming

GenAI, Meta(Meta GenAI)

Suyu Ge, Chunting Zhou, Rui Hou, Madian Khabsa, Yi-Chia Wang, Qifan Wang, Jiawei Han, Yuning Mao

AI总结:

本文提出多轮自动红队测试(MART)方法,通过对抗性LLM与目标LLM迭代交互,自动生成攻击提示并安全微调,将违规率降低84.7%,同时保持模型有用性。

摘要:

红队测试是缓解大型语言模型(LLMs)中不安全行为的常见做法,它涉及彻底评估LLMs以识别潜在缺陷,并通过负责任且准确的回应来解决这些问题。虽然有效,但手动红队测试成本高昂,而现有的自动红队测试通常只发现安全风险而不加以解决。在本文中,我们提出了一种多轮自动红队测试(MART)方法,该方法结合了自动对抗性提示编写和安全响应生成,显著提高了红队测试的可扩展性和目标LLM的安全性。具体来说,一个对抗性LLM和一个目标LLM以迭代方式相互交互,其中对抗性LLM旨在生成能引发目标LLM不安全回应的挑战性提示,而目标LLM则在这些对抗性提示上使用安全对齐数据进行微调。在每一轮中,对抗性LLM针对更新后的目标LLM设计更好的攻击,而目标LLM也通过安全微调来改进自身。在对抗性提示基准上,经过4轮MART后,安全对齐有限的LLM的违规率最多降低84.7%,达到了与经过广泛对抗性提示编写的LLMs相当的性能。值得注意的是,模型在非对抗性提示上的有用性在整个迭代过程中保持稳定,表明目标LLM在指令遵循方面保持了强大的性能。

英文摘要:

Red-teaming is a common practice for mitigating unsafe behaviors in Large Language Models (LLMs), which involves thoroughly assessing LLMs to identify potential flaws and addressing them with responsible and accurate responses. While effective, manual red-teaming is costly, and existing automatic red-teaming typically discovers safety risks without addressing them. In this paper, we propose a Multi-round Automatic Red-Teaming (MART) method, which incorporates both automatic adversarial prompt writing and safe response generation, significantly increasing red-teaming scalability and the safety of the target LLM. Specifically, an adversarial LLM and a target LLM interplay with each other in an iterative manner, where the adversarial LLM aims to generate challenging prompts that elicit unsafe responses from the target LLM, while the target LLM is fine-tuned with safety aligned data on these adversarial prompts. In each round, the adversarial LLM crafts better attacks on the updated target LLM, while the target LLM also improves itself through safety fine-tuning. On adversarial prompt benchmarks, the violation rate of an LLM with limited safety alignment reduces up to 84.7% after 4 rounds of MART, achieving comparable performance to LLMs with extensive adversarial prompt writing. Notably, model helpfulness on non-adversarial prompts remains stable throughout iterations, indicating the target LLM maintains strong performance on instruction following.

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

↑