Source-linked AI summary

I'm Afraid I Can't Do That: Predicting Prompt Refusal in Black-Box Generative Language Models

Max Reuter, William Schulze

arXiv:2306.03423v2cs.AI

TL;DR

The paper examines how subjective fine-tuning affects which prompts ChatGPT refuses, a form of bias beyond bias inherited from pre-training. The authors build a predictive model for which prompts ChatGPT refuses, using a hand-labeled dataset as the primary training dataset. Refusal lies on a continuum, negative generalizations of demographic groups strongly predict refusal, and BERT outperformed classical models for refusal classification and prompt classification.

  • Problem

    The paper examines how subjective fine-tuning affects which prompts ChatGPT refuses, a form of bias beyond bias inherited from pre-training.

    Source: §1.1 · p. 1, §2 · p. 2
  • Method

    The authors build a predictive model for which prompts ChatGPT refuses, using a hand-labeled dataset as the primary training dataset.

    Source: §2 · p. 2, §2.1.4 · p. 4
  • Results

    Refusal lies on a continuum, negative generalizations of demographic groups strongly predict refusal, and BERT outperformed classical models for refusal classification and prompt classification.

    Source: §4 · p. 8
  • Takeaways & Limitations

    ChatGPT’s compliance behavior can be characterized at scale and its refusal tendencies can be predicted from prompts without observing responses.

    Source: §4 · p. 8

    The authors expect a performance ceiling because OpenAI’s intentional response-temperature setting introduces randomness.

    Source: §4 · p. 8

Abstract

from arXiv · show

Since the release of OpenAI's ChatGPT, generative language models have attracted extensive public attention. The increased usage has highlighted generative models' broad utility, but also revealed several forms of embedded bias. Some is induced by the pre-training corpus; but additional bias specific to generative models arises from the use of subjective fine-tuning to avoid generating harmful content. Fine-tuning bias may come from individual engineers and company policies, and affects which prompts the model chooses to refuse. In this experiment, we characterize ChatGPT's refusal behavior using a black-box attack. We first query ChatGPT with a variety of offensive and benign prompts (n=1,706), then manually label each response as compliance or refusal. Manual examination of responses reveals that refusal is not cleanly binary, and lies on a continuum; as such, we map several different kinds of responses to a binary of compliance or refusal. The small manually-labeled dataset is used to train a refusal classifier, which achieves an accuracy of 96%. Second, we use this refusal classifier to bootstrap a larger (n=10,000) dataset adapted from the Quora Insincere Questions dataset. With this machine-labeled data, we train a prompt classifier to predict whether ChatGPT will refuse a given question, without seeing ChatGPT's response. This prompt classifier achieves 76% accuracy on a test set of manually labeled questions (n=985). We examine our classifiers and the prompt n-grams that are most predictive of either compliance or refusal. Our datasets and code are available at https://github.com/maxwellreuter/chatgpt-refusals.

1 BACKGROUND

Prior studies identified political and demographic bias in ChatGPT, while this paper focuses on a related form of bias: whether the model refuses prompts. The background establishes that refusal can vary continuously rather than dividing cleanly into compliance and refusal.

1.1 Bias in ChatGPT

  • ChatGPT has been reported to express left-libertarian and environmentalist political views, including stronger alignment with Germany’s Socialist party than the German population.Source: §1.1 · p. 1
  • Other studies found political and psychological biases, including progressive and libertarian general views and low measured levels of psychological dark traits.Source: §1.1 · p. 1
  • OpenAI’s moderation responses varied substantially across demographic groups, with protection above 80% for some classes but below 20% for others.Source: §1.1 · p. 2
  • Fine-tuning can produce markedly different political biases, as shown by RightWingGPT exhibiting approximately opposite political-compass biases from ChatGPT.Source: §1.1 · p. 2

1.2 Prompt Refusal

  • ChatGPT’s bias also appears in whether it refuses to cooperate with prompts, and the paper investigates which prompt types predict refusal.Source: §1.2 · p. 2
  • Although early refusals appeared binary, broader examination found a smooth continuum of responses from compliance to refusal.Source: §1.2 · p. 2, Table 1 · p. 2

2 METHODS

This section describes the study’s refusal-prediction pipeline, spanning prompt compilation, manual response labeling, refusal-classifier training, and prompt-classifier training. It also presents the prompt classifier training overview and explains the use of binary label mapping and automatic dataset bootstrapping.

2.1 Prompt Database Compilation

  • The prompt database combined offensive and benign material, including 400 sincere and 600 insincere hand-labeled Quora questions plus 10,000 additional samples automatically labeled for training.The Quora data were selected because their question-form text suited ChatGPT prompts, although its offensive content may reflect regional prejudices and may not fully target OpenAI’s harmful-content priorities.Source: §2.1 · pp. 3–4

2.1.4 Other Candidate Datasets.

  • The hand-labeled dataset (n=1,706) compiled labeled samples from aforementioned datasets into a superset and served as the primary dataset for training the refusal classifier.Many text strings were too fragmentary to be properly understood as prompts, and the same problem prevented effective use of the collected 4Chan archive.Source: §2.1.4 · p. 4

2.2 Manual Refusal Labeling

  • Manual inspection found that ChatGPT compliance and refusal form a continuum, so eight response subcategories were mapped to binary compliance/refusal labels.The mapping addressed rare subcategories that would have limited direct eight-way classification.Source: §2.2 · p. 4
  • 93% of sincere Quora questions received compliance, compared with 53% of insincere questions, showing that refusal did not perfectly track question sincerity.The dataset also contained sincere questions that ChatGPT refused and insincere questions that it complied with.Source: §2.2 · p. 4, Table 4 · p. 5

2.3 Classifier Training

  • Both classifiers accept variable-length text and output binary classifications; BERT, logistic regression, and random forest were evaluated across two tasks, with BERT expected to achieve the best accuracy.The latter two models were used primarily for interpretability, revealing highly predictive words or few-word phrases (n-grams).Source: §2.3 · p. 5

2.3.1 Refusal Classification.

  • Refusal identification leveraged shared response expressions, whereas refusal prediction required modeling subtle prompt differences because substituting one person or demographic could change compliance to refusal.The prompt classifier was trained on 10,000 automatically labeled Quora samples and evaluated on hand-labeled Quora data; the refusal classifier supplied labels to bootstrap the larger dataset.Source: §2.3.1 · p. 5, §2.3.2 · pp. 5–6

2.3.2 Predicting Refusals.

  • Figure 1 presents an overview of prompt classifier training.Source: §2.3.2 · p. 6

3 RESULTS

The results show that BERT outperformed classical models for both refusal and prompt classification, while different n-grams predicted refusals and compliance. Feature patterns differed between predicting whether a prompt would be refused and identifying whether a response was a refusal.

3.1 Model Performance

  • BERT significantly outperformed classical models on both refusal classification and prompt classification.For refusal classification, logistic regression and random forest achieved 90.6% and 86.7% accuracy, while prompt classification accuracies were 73.9%, 72.2%, and 75.9%, respectively.Source: §3.1 · p. 6

3.2 Feature Importance

  • The feature analyses compared n-grams predictive of whether a prompt would be refused with n-grams predictive of whether a response was a refusal.The hand-labeled analysis used logistic-regression weights for both prediction targets.Source: §3.2 · p. 7, Figure 2 · p. 7
  • For response refusal, “cannot,” “sorry,” and “AI language model” predicted refusal, while “the” predicted compliance.The authors suggest that “the” may indicate the declarative-sentence style used in compliant responses.Source: §3.2 · p. 7
  • For prompt refusal, “trump,” plural demographic groups, and negative adjectives predicted refusal, whereas “what are” predicted compliance.The reported predictors came from 10,000 machine-labeled Quora Insincere Questions samples.Source: §3.2 · p. 7, Figure 3 · p. 7

4 DISCUSSION

The investigation finds that ChatGPT’s refusal behavior spans a continuum and that prompt features can predict refusals, although prediction remains constrained by classifier performance and response randomness.

  • ChatGPT’s compliance behavior is not cleanly binary but forms a smooth continuum of refusal responses.The authors mapped varied response types to binary labels for classification despite this continuum.Source: §4 · p. 8
  • Negative generalizations about demographic groups are among the strongest predictors of ChatGPT refusals, while controversial figures also predict refusal.The study does not determine whether controversial figures themselves prompt refusal or instead attract prompts that are refusable for other reasons.Source: §4 · p. 8
  • BERT outperformed classical models for both refusal and prompt classification, though its advantage was smaller for prompt classification.The authors note that classification errors matter because erroneous automatic refusal labels can frustrate users.Source: §4 · p. 8
  • Prompt prediction has a performance ceiling associated with OpenAI’s intentional response-randomness temperature, although the authors doubt their study reached that ceiling.This randomness could contribute to irreducible limits on predicting refusals from prompts alone.Source: §4 · p. 8

5 FUTURE WORK

Future work targets labeling quality, dataset coverage, model-version comparisons, and better characterization of refusal randomness. Proposed extensions include repeated queries to estimate refusal likelihood rather than a binary outcome.

  • Multiple manual labelers could reduce personal bias in refusal labels, while improving the refusal classifier may also improve prompt-classifier performance.Source: §5 · p. 8
  • Larger automatically labeled datasets could reduce sparsity across diverse input expressions and make prompt classification more reliable.Source: §5 · p. 8
  • Comparing feature importance across ChatGPT snapshots could characterize OpenAI’s ongoing alignment work.Source: §5 · p. 8
  • Querying each prompt several times could characterize how internal randomness temperature affects performance.Source: §5 · p. 8
  • Repeated queries could support classifiers that predict refusal likelihood instead of only binary refusal.Source: §5 · p. 8
Loading 2306.03423v2…