Large Language Models can be Guided to Evade AI-generated Text Detection

Ning Lu, Shengcai Liu, Rui He, Yew-Soon Ong, Qi Wang, Ke Tang · Submission to ICLR 2024 · Withdrawn

The rapid rise of Large Language Models (LLMs) has sparked a high-stakes game of cat-and-mouse. As students and bad actors use AI to generate essays and fake reviews, researchers have scrambled to build "AI detectors." But a new paper published in the Transactions on Machine Learning Research suggests the mouse might be winning.

TL;DR

Researchers have developed SICO (Substitution-based In-Context example Optimization), a method that automatically crafts prompts to help LLMs evade AI-generated text detectors. By iteratively optimizing a small set of human-written examples, SICO allows models like GPT-3.5 to produce text that is virtually indistinguishable from human writing to both machines and people, often reducing detector accuracy to the level of a random coin flip.

The Problem: Brittle Defenses in an AI-Generated World

As LLMs become ubiquitous, concerns about plagiarism, misinformation, and spam have led to the development of two main types of detectors:

  • Training-based detectors: Classifiers fine-tuned to spot AI patterns.
  • Statistical detectors: Systems that look for "robotic" signatures like low perplexity or uniform sentence structure.

While "paraphrase attacks"—using a second AI to rewrite the first AI's output—have shown promise in evading these detectors, they are computationally expensive and often degrade the quality of the text. The authors of this paper asked a provocative question: Can we simply prompt an LLM to be its own stealth agent? The challenge lies in finding the "perfect prompt" that guides the model to adopt human-like linguistic quirks without losing the original meaning.

Methods: Building the Ultimate Stealth Prompt

The authors introduce SICO, a framework that treats prompt engineering as an optimization problem. Instead of guessing what a "human-like" prompt looks like, SICO builds one systematically.

The SICO framework pipeline, illustrating how human-written text features are extracted and optimized through sentence and word substitution to construct a universal evasion prompt.

SICO operates through three main steps:

  1. Feature Extraction: The LLM is shown pairs of human and AI text and asked to identify the distinct linguistic features that make the human writing stand out (e.g., "uses complex sentence structures" or "avoids repetition").
  2. In-Context Example Optimization: This is the "secret sauce." SICO takes a few human-written examples and iteratively modifies them. It uses a proxy detector to provide a score. If a word or sentence substitution makes the example look "less AI-like" to the detector, the change is kept.
  3. Universal Prompting: Once optimized, these examples are bundled into a task-specific prompt. This prompt then guides the LLM to generate new content that mimics the "stealthy" style of the optimized examples.

SICO comes in two flavors: SICO-Gen (direct generation from scratch) and SICO-Para (paraphrasing existing AI text).

Datasets and Evaluation

The researchers evaluated SICO across three real-world tasks using diverse datasets:

  • Academic Writing: Using Wikipedia paragraphs from the SQuAD dataset.
  • Open-Ended QA: Using the Eli5 (Explain Like I'm Five) dataset.
  • Fake Reviews: Using the Yelp dataset to generate convincing business reviews.

They tested their attack against six prominent detectors, including GPTZero, OpenAI’s (now-discontinued) detector, and DetectGPT.

Key Insights and Results

The quantitative results serve as a wake-up call for the AI safety community.

ROC curves demonstrating the performance of various detectors against different evasion methods. SICO-Para and SICO-Gen push the curves significantly closer to the random baseline (dashed line).
  • Massive AUC Drops: Across all tasks, SICO reduced the Area Under the Curve (AUC)—a standard measure of detector performance—by an average of 0.5. As seen in the ROC curves, detectors that were highly accurate against standard AI text were reduced to near-random guessing when faced with SICO-generated text.
  • The Power of the Proxy: One of the most surprising findings is that a prompt optimized against one detector (the proxy) is remarkably effective against all others. This suggests that AI detectors, despite their different architectures, are often looking for the exact same "robotic" signatures.
  • Statistical Detectors are Brittle: Statistical methods like Log-Rank and DetectGPT, which rely on the mathematical "smoothness" of AI text, were particularly vulnerable to SICO-Para. By injecting human-like "burstiness" and complexity into the prompt, SICO completely breaks the statistical assumptions these detectors rely on.
  • Human-Level Quality: In blind tests with human annotators, SICO-generated text achieved readability and task completion scores nearly identical to actual human writing. Furthermore, humans were significantly less likely to identify SICO-generated text as AI-written compared to standard AI outputs or other paraphrasing methods.

Limitations and Future Work

The authors acknowledge that they have essentially accelerated an "arms race." To counter SICO, they proposed an ensemble defense: training detectors specifically on SICO-generated "adversarial" examples. While this improved robustness, the authors note that a determined attacker could simply iterate SICO again to find new vulnerabilities.

Ultimately, as long as LLMs have the capacity to mimic human variability, perfect detection may be an impossible goal. The researchers call for more focus on "responsible use" frameworks and policies that do not rely solely on brittle technical detection methods.

Summary updated

BibTeX
@article{lu2023large,
  author = {Ning Lu and Shengcai Liu and Rui He and Yew-Soon Ong and Qi Wang and Ke Tang},
  title = {{Large Language Models can be Guided to Evade AI-generated Text Detection}},
  journal = {Accepted by TMLR},
  year = {2023},
  url = {https://openreview.net/forum?id=lLE0mWzUrr},
}
Figure