Research map / Adversarial robustness and security / Attacks on text and graphs
An Interpretable N-gram Perplexity Threat Model for Large Language Model Jailbreaks
Read the paperCheck your idea against 108,967 papers
AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.
Proposes an interpretable bigram (N-gram) perplexity threat model built on 1T Dolma tokens, adapts popular jailbreak attacks to it, and benchmarks them on equal footing against safety-tuned LLMs.
Problem
Jailbreak attacks on LLMs vary widely in fluency and compute cost, so their attack success rates are not comparable; LLM-based perplexity filters are model-dependent, non-interpretable, and costly to evaluate.
Approach
Define a jailbreak as valid in a threat model if its bigram N-gram perplexity over rolling 8-token windows stays below a threshold calibrated to 99.9% TPR on natural text; adapt GCG, PRS, AutoDAN, BEAST, and PAIR to satisfy this filter and compare them under equal constraints, using the N-gram LM for interpretability analysis.
Key results
- Adaptive PRS achieves average ASR 0.82 under the N-gram threat model versus 0.89 for unconstrained PRS, and is the strongest attack across the evaluated models (e.g., 0.96 on Llama3.1-8b).
- Low-perplexity attacks (AutoDAN, BEAST, PAIR) reach average ASR of 0.19, 0.10, and 0.13 under the constraint, below adaptive GCG (0.24) and PRS.
- On Llama2-7b, the N-gram perplexity filter at 99.9% TPR (threshold 38,276) reduces ASR from 0.90 to 0.62 for adaptive PRS while the Self-PPL variants reach the same ASR at roughly 5-7x higher FLOPs.
Measured effects reported in the paper
| What was changed | Where | Measured | Effect |
|---|---|---|---|
| Adapt GCG to the N-gram perplexity constraint | GCG · HarmBench (10-model average) | ASR: 0.28 -> 0.24 | Hurt |
| Adapt PRS to the N-gram perplexity constraint | PRS · HarmBench (10-model average) | ASR: 0.89 -> 0.82 | Hurt |
| Adapt AutoDAN to the N-gram perplexity constraint | AutoDAN · HarmBench (10-model average) | ASR: 0.22 -> 0.19 | Hurt |
| Adapt BEAST to the N-gram perplexity constraint | BEAST · HarmBench (10-model average) | ASR: 0.10 -> 0.10 | No clear effect |
| Adapt PAIR to the N-gram perplexity constraint | PAIR · HarmBench (10-model average) | ASR: 0.13 -> 0.13 | No clear effect |
| Apply N-gram perplexity filtering to adaptive PRS | PRS on Llama2-7B · HarmBench (first 50 behaviors) | ASR: 0.90 -> 0.62 | Hurt |
| Replace the N-gram filter with windowed self-perplexity (ablation) | Adaptive PRS on Llama2-7B · HarmBench (first 50 behaviors) | Median FLOPs: $5.17 \times 10^{16}$ -> $2.34 \times 10^{17}$ | Hurt |
| Increase N-gram depth beyond bigrams (ablation) | N-gram perplexity filter · Cleaned Alpaca windows | Filter separation performance | Hurt |
| Use a less conservative filter threshold at TPR 95% (ablation) | PRS on Llama2-7B · HarmBench (first 50 behaviors) | ASR: 25% | Hurt |
Surprising findings
- Attack success rates against safety-tuned modern models are lower than previously reported, and discrete-optimization attacks (PRS, GCG) outperform recent LLM-based attacks (PAIR, AutoDAN) under the constraint.
- The N-gram filter rejects 41.8% of translated queries on average for morphologically hard languages and 15.5% for simple ones, indicating English-centric limitations.
Limitations
- Filter is based on bigram statistics from an English-dominant corpus (Dolma) and rejects many non-English queries.
- Attacks assume white-box access for GCG and PRS and rely on a judge model whose agreement with humans is imperfect (accuracy 0.84-0.92).
- Threat model uses the Llama2 tokenizer for all models, which may not match each model's tokenizer.
Experimental setup
Datasets: Dolma HarmBench cleaned Alpaca
Benchmarks: HarmBench
Metrics: attack success rate total FLOPs TPR FPR
Baselines: GCG PRS AutoDAN BEAST PAIR
Builds on: GCG PRS PAIR AutoDAN BEAST HarmBench Infini-gram
Closest papers by meaning
- Systematic Scaling Analysis of Jailbreak Attacks in Large Language Models (NeurIPS 2026 · similarity 0.92)
- Weak-to-Strong Jailbreaking on Large Language Models (ICML 2025 · similarity 0.92)
- One Model Transfer to All: On Robust Jailbreak Prompts Generation against LLMs (ICLR 2025 · similarity 0.91)
- h4rm3l: A Language for Composable Jailbreak Attack Synthesis (ICLR 2025 · similarity 0.91)
- Speak Easy: Eliciting Harmful Jailbreaks from LLMs with Simple Interactions (ICML 2025 · similarity 0.91)
- JailPO: A Novel Black-Box Jailbreak Framework via Preference Optimization Against Aligned LLMs (AAAI 2025 · similarity 0.91)
Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.
