Lune

NeurIPS2024Top-tier venue

Accelerating Greedy Coordinate Gradient and General Prompt Optimization via Probe Sampling

Yiran Zhao, Wenyue Zheng, Tianle Cai, Do Xuan Long, Kenji Kawaguchi, Anirudh Goyal, Michael Qizhe Shieh

Abstract

Safety of Large Language Models (LLMs) has become a critical issue given their rapid progresses. Greedy Coordinate Gradient (GCG) is shown to be effective in constructing adversarial prompts to break the aligned LLMs, but optimization of GCG is time-consuming. To reduce the time cost of GCG and enable more comprehensive studies of LLM safety, in this work, we study a new algorithm called Probe sampling\texttt{Probe sampling}. At the core of the algorithm is a mechanism that dynamically determines how similar a smaller draft model's predictions are to the target model's predictions for prompt candidates. When the target model is similar to the draft model, we rely heavily on the draft model to filter out a large number of potential prompt candidates. Probe sampling achieves up to 5.65.6 times speedup using Llama2-7b-chat and leads to equal or improved attack success rate (ASR) on the AdvBench. Furthermore, probe sampling is also able to accelerate other prompt optimization techniques and adversarial methods, leading to acceleration of 1.8×1.8\times for AutoPrompt, 2.4×2.4\times for APE and 2.4×2.4\times for AutoDAN.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

13 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • MAGIC: A Co-Evolving Attacker–Defender Adversarial Game for Robust LLM Safety cites Measuring Massive Multitask Language Understanding
  • MAGIC: A Co-Evolving Attacker–Defender Adversarial Game for Robust LLM Safety cites Training language models to follow instructions with human feedback
  • Measuring Massive Multitask Language Understanding cites Language Models are Few-Shot Learners
  • FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness cites Efficiently Modeling Long Sequences with Structured State Spaces
  • FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awareness cites Language Models are Few-Shot Learners
  • SECA: Semantically Equivalent and Coherent Attacks for Eliciting LLM Hallucinations cites Measuring Massive Multitask Language Understanding
  • GASP: Efficient Black-Box Generation of Adversarial Suffixes for Jailbreaking LLMs cites Language Models are Few-Shot Learners
  • GASP: Efficient Black-Box Generation of Adversarial Suffixes for Jailbreaking LLMs cites Training language models to follow instructions with human feedback
  • Training language models to follow instructions with human feedback cites Language Models are Few-Shot Learners
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers13

  1. SATO: Stable Text-to-Motion FrameworkWenshuo Chen, Hongru Xiao, Erhang Zhang, Lijie Hu et al.ACM MM 2024 · 17 citations
  2. GASP: Efficient Black-Box Generation of Adversarial Suffixes for Jailbreaking LLMsAdvik Raj Basani, Xiao ZhangNeurIPS 2025 · 16 citations
  3. SECA: Semantically Equivalent and Coherent Attacks for Eliciting LLM HallucinationsBuyun Liang, Liangzu Peng, Jinqi Luo, Darshan Thaker et al.NeurIPS 2025 · 11 citations
  4. MAGIC: A Co-Evolving Attacker–Defender Adversarial Game for Robust LLM SafetyXiaoyu Wen, Zhida He, Han Qi, Ziyu Wan et al.ICML 2026 · 10 citations
  5. SlotGCG: Exploiting the Positional Vulnerability in LLMs for Jailbreak AttacksSeungwon Jeong, Jiwoo Jeong, Hyeonjin Kim, Yunseok Lee et al.ICLR 2026 · 2 citations

Builds on32

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
  2. Training language models to follow instructions with human feedbackLong Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida et al.NeurIPS 2022 · 24,707 citations
  3. Measuring Massive Multitask Language UnderstandingDan Hendrycks, Collin Burns, Steven Basart, Andy Zou et al.ICLR 2021 · 7,905 citations
  4. FlashAttention: Fast and Memory-Efficient Exact Attention with IO-AwarenessTri Dao, Daniel Y. Fu, Stefano Ermon, Atri Rudra et al.NeurIPS 2022 · 5,493 citations
  5. Efficiently Modeling Long Sequences with Structured State SpacesAlbert Gu, Karan Goel, Christopher RéICLR 2022 · 3,482 citations

Related papers

  1. Improved Generation of Adversarial Examples Against Safety-aligned LLMsQizhang Li, Yiwen Guo, Wangmeng Zuo, Hao ChenNeurIPS 2024 · 23 citations
  2. Sampling-aware Adversarial Attacks Against Large Language ModelsTim Beyer, Yan Scholten, Leo Schwinn, Stephan GünnemannICLR 2026 · 9 citations
  3. Greedy Coordinate Diffusion: Effective and Semantically Coherent Adversarial Attacks via Diffusion GuidanceBohdan Turbal, Blossom Metevier, Max Springer, Aleksandra KorolovaICML 2026
  4. AdvPrompter: Fast Adaptive Adversarial Prompting for LLMsAnselm Paulus, Arman Zharmagambetov, Chuan Guo, Brandon Amos et al.ICML 2025
  5. ProAdvPrompter: A Two-Stage Journey to Effective Adversarial Prompting for LLMsHao Di, Tong He, Haishan Ye, Yinghui Huang et al.ICLR 2025
Dusk over the sea between two cliffs drawn in fine vertical lines