paper-with-me

Papers

Improved Techniques for Optimization-Based Jailbreaking on Large Language Models

2024-05-31 · Xiaojun Jia, Tianyu Pang, Chao Du, Yihao Huang, Jindong Gu, Yang Liu, Xiaochun Cao, Min Lin

Large language models (LLMs) are being rapidly developed, and a key component of their widespread deployment is their safety-related alignment. Many red-teaming efforts aim to jailbreak LLMs, where among these efforts, the Greedy Coordinate Gradient (GCG) attack's success has led to a growing interest in the study of optimization-based jailbreaking techniques. Although GCG is a significant milestone, its attacking efficiency remains unsatisfactory. In this paper, we present several improved (empirical) techniques for optimization-based jailbreaks like GCG. We first observe that the single target template of "Sure" largely limits the attacking performance of GCG; given this, we propose to apply diverse target templates containing harmful self-suggestion and/or guidance to mislead LLMs. Besides, from the optimization aspects, we propose an automatic multi-coordinate updating strategy in GCG (i.e., adaptively deciding how many tokens to replace in each step) to accelerate convergence, as well as tricks like easy-to-hard initialisation. Then, we combine these improved technologies to develop an efficient jailbreak method, dubbed I-GCG. In our experiments, we evaluate on a series of benchmarks (such as NeurIPS 2023 Red Teaming Track). The results demonstrate that our improved techniques can help GCG outperform state-of-the-art jailbreaking attacks and achieve nearly 100% attack success rate. The code is released at https://github.com/jiaxiaojunQAQ/I-GCG.

📄 PDF Abstract BibTeX arXiv:2405.21018

Code (1)

jiaxiaojunqaq/i-gcg 공식 구현 pytorch

Tasks

Red Teaming

Similar Papers 제목 키워드 기반

Robust Prompt Optimization for Defending Language Models Against Jailbreaking Attacks

2024-01-30 · Andy Zhou, Bo Li, Haohan Wang

Despite advances in AI alignment, large language models (LLMs) remain vulnerable to adversarial attacks or jailbreaking, in which adversaries can modify prompts to induce unwanted behavior. While some defenses have been …

LARGO: Latent Adversarial Reflection through Gradient Optimization for Jailbreaking LLMs

2025-05-16 · Ran Li, Hao Wang, Chengzhi Mao

Efficient red-teaming method to uncover vulnerabilities in Large Language Models (LLMs) is crucial. While recent attacks often use LLMs as optimizers, the discrete language space make gradient-based methods struggle. We …

Red Teaming

Improved Few-Shot Jailbreaking Can Circumvent Aligned Language Models and Their Defenses

2024-06-03 · Xiaosen Zheng, Tianyu Pang, Chao Du, Qian Liu 외

Recently, Anil et al. (2024) show that many-shot (up to hundreds of) demonstrations can jailbreak state-of-the-art LLMs by exploiting their long-context capability. Nevertheless, is it possible to use few-shot demonstrat…

Faster-GCG: Efficient Discrete Optimization Jailbreak Attacks against Aligned Large Language Models

2024-10-20 · Xiao Li, Zhuhong Li, Qiongxiu Li, Bingze Lee 외

Aligned Large Language Models (LLMs) have demonstrated remarkable performance across various tasks. However, LLMs remain susceptible to jailbreak adversarial attacks, where adversaries manipulate prompts to elicit malici…

Adversarial Attack on Large Language Models using Exponentiated Gradient Descent

2025-05-14 · Sajib Biswas, Mao Nishino, Samuel Jacob Chacko, Xiuwen Liu

As Large Language Models (LLMs) are widely used, understanding them systematically is key to improving their safety and realizing their full potential. Although many models are aligned using techniques such as reinforcem…

Adversarial Attack