Skip to main content
QUICK REVIEW

[Paper Review] The Butterfly Effect of Altering Prompts: How Small Changes and Jailbreaks Affect Large Language Model Performance

Abel Salinas, Fred Morstatter|arXiv (Cornell University)|Jan 8, 2024
Topic ModelingComputer Science3 citations
TL;DR

This paper investigates how minor prompt variations—such as formatting requests, small text perturbations, and jailbreak techniques—affect the predictions of large language models (LLMs). Using 24 prompt variations across 11 text classification tasks, it finds that even trivial changes like adding a space or requesting JSON output can alter model predictions, while jailbreaks cause substantial performance degradation, with refusal rates up to 90% for some methods, highlighting critical reliability issues in LLM-based labeling systems.

ABSTRACT

Large Language Models (LLMs) are regularly being used to label data across many domains and for myriad tasks. By simply asking the LLM for an answer, or ``prompting,'' practitioners are able to use LLMs to quickly get a response for an arbitrary task. This prompting is done through a series of decisions by the practitioner, from simple wording of the prompt, to requesting the output in a certain data format, to jailbreaking in the case of prompts that address more sensitive topics. In this work, we ask: do variations in the way a prompt is constructed change the ultimate decision of the LLM? We answer this using a series of prompt variations across a variety of text classification tasks. We find that even the smallest of perturbations, such as adding a space at the end of a prompt, can cause the LLM to change its answer. Further, we find that requesting responses in XML and commonly used jailbreaks can have cataclysmic effects on the data labeled by LLMs.

Motivation & Objective

  • To investigate the reliability of LLM predictions under minor prompt variations, including formatting, perturbations, and jailbreaks.
  • To assess how these variations impact model accuracy and consistency across diverse text classification tasks.
  • To explore whether annotator disagreement correlates with prediction changes across prompt variations.
  • To identify which prompt modifications lead to the most significant shifts in LLM outputs.
  • To inform the design of more robust prompt ensembles and resilient LLM systems.

Proposed method

  • The study evaluates 24 prompt variations across 11 benchmark text classification tasks, including BoolQ, CoLA, and Jigsaw Toxicity.
  • Variations are grouped into four categories: output formats (e.g., JSON, XML), small perturbations (e.g., adding a space or 'Thank you'), tipping prompts, and jailbreaks (e.g., Evil Confidant, AIM, Dev Mode v2).
  • Model predictions are compared across variations to measure prediction change rates and accuracy loss.
  • Multidimensional scaling (MDS) is used to embed prompt variations based on response similarity, enabling clustering analysis.
  • Annotator entropy is calculated for human-labeled instances to assess confusion, and its correlation with prediction entropy is computed using Pearson correlation.
  • Statistical analysis identifies significant correlations between prompt variation type and prediction instability, especially for jailbreaks and formatting requests.
Figure 1: Number of predictions that change (out of 11,000) compared to No Specified Format style. Red bars correspond to the number of invalid responses provided by the model.
Figure 1: Number of predictions that change (out of 11,000) compared to No Specified Format style. Red bars correspond to the number of invalid responses provided by the model.

Experimental results

Research questions

  • RQ1How do minor prompt variations, such as adding a space or requesting a specific output format, affect LLM prediction consistency?
  • RQ2To what extent do jailbreak techniques alter LLM predictions and degrade model performance?
  • RQ3Do instances with higher annotator disagreement show greater sensitivity to prompt variations?
  • RQ4How do different prompt variations cluster in response space, and what does this reveal about model reliability?
  • RQ5Can prediction entropy be reliably predicted from annotator disagreement across different prompt types?

Key findings

  • Even minor perturbations, such as adding a single space at the end of a prompt, caused LLMs to change their predictions in up to 15% of cases.
  • Requesting outputs in XML or CSV format led to an average accuracy drop of 5 percentage points compared to the baseline.
  • Jailbreak techniques like Dev Mode v2 and AIM caused refusal rates of approximately 90%, severely degrading model utility.
  • The Evil Confidant and Refusal Suppression jailbreaks, despite low refusal rates (<3%), still caused over a 10-point accuracy drop compared to the baseline.
  • Perturbation variations such as 'End with Thank you' and 'Rephrase as Statement' produced significantly different outputs, diverging from the main cluster in MDS embeddings.
  • A weak negative correlation (r = -0.3779, p = 0.00) was found between annotator disagreement and prediction change likelihood, suggesting that more ambiguous instances are less likely to change under prompt variation.
Figure 2: Number of predictions that change (out of 11,000) compared to the Python List style. Red bars correspond to the number of invalid responses provided by the model.
Figure 2: Number of predictions that change (out of 11,000) compared to the Python List style. Red bars correspond to the number of invalid responses provided by the model.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.