XYZNOT

Papers · arXiv 2212.08073

Constitutional AI: Harmlessness from AI Feedback

Published cs.CLcs.AI arXivPDF

Read with translation and AI

Summary in three lines

  1. 🎯 Standard RLHF relies heavily on human harm labels and frequently yields evasive assistants that shut down sensitive queries.
  2. 🔧 Constitutional AI uses a written list of natural language rules to drive automated self-critiques, revisions, and reinforcement learning from AI feedback (RLAIF).
  3. 📈 The resulting RL-CAI models match or exceed human-feedback-trained models on harmlessness without evasiveness, while maintaining helpfulness.

Abstract

As AI systems become more capable, we would like to enlist their help to supervise other AIs. We experiment with methods for training a harmless AI assistant through self-improvement, without any human labels identifying harmful outputs. The only human oversight is provided through a list of rules or principles, and so we refer to the method as 'Constitutional AI'. The process involves both a supervised learning and a reinforcement learning phase. In the supervised phase we sample from an initial model, then generate self-critiques and revisions, and then finetune the original model on revised responses. In the RL phase, we sample from the finetuned model, use a model to evaluate which of the two samples is better, and then train a preference model from this dataset of AI preferences. We then train with RL using the preference model as the reward signal, i.e. we use 'RL from AI Feedback' (RLAIF). As a result we are able to train a harmless but non-evasive AI assistant that engages with harmful queries by explaining its objections to them. Both the SL and RL methods can leverage chain-of-thought style reasoning to improve the human-judged performance and transparency of AI decision making. These methods make it possible to control AI behavior more precisely and with far fewer human labels.

Reading guide

Problem and motivation

Standard Reinforcement Learning from Human Feedback (RLHF) suffers from several bottlenecks when aligning language assistants:

  • Heavy reliance on human harm labels: Collecting tens of thousands of human preference comparisons for harmfulness is expensive and exposes human annotators to toxic content.
  • Evasiveness and tension with helpfulness: Models trained via RLHF often learn to answer sensitive prompts with canned refusals like “I can't answer that”, sacrificing helpfulness and transparency.
  • Opacity: Thousands of private preference labels make the exact alignment objectives implicit and difficult to inspect or audit.

Constitutional AI (CAI) aims to scale supervision by replacing human harm annotations with explicit, natural language principles (a constitution), training an AI to self-critique, revise, and generate its own preference feedback.

Key ideas

  • A Constitution of Principles: Behavior is steered entirely through a small set of natural language rules (roughly 16 principles) rather than human harm labels.
  • Two-Stage Pipeline: A Supervised Learning (SL) stage brings model outputs on-distribution using self-critiques and revisions, followed by a Reinforcement Learning from AI Feedback (RLAIF) stage that trains a preference model on model-evaluated comparisons.
  • Engagement Over Evasiveness: The assistant is guided to explain objections to harmful requests rather than issuing blanket refusals.
  • Chain-of-Thought (CoT) Supervision: Leveraging step-by-step reasoning during evaluation substantially improves the model's ability to identify harms and evaluate multiple-choice preferences.

Method

1. Supervised Learning Stage (Critique Revision SL-CAI)

  1. Sample an initial output from a helpful RLHF model using a red-teaming prompt .
  2. Prompt the model to critique its own response according to a randomly sampled constitutional principle:
  3. Prompt the model to revise the response to satisfy the critique:
  4. Repeat critique-revision iteratively (typically up to 4 revisions).
  5. Finetune a pretrained LM on revised responses paired with helpfulness demonstration data (182,831 red team prompts, 135,296 helpfulness prompts) for one epoch at batch size 1024.

2. Reinforcement Learning Stage (RLAIF)

  1. Using the SL-CAI model, sample response pairs for prompts.
  2. Present the conversation, response pair, and a sampled principle to a feedback model in a multiple-choice format (optionally using Chain-of-Thought prompting).
  3. Compute normalized target probabilities from the feedback model's completion logits: When using Chain-of-Thought, target probabilities are clamped to the range to avoid overconfidence.
  4. Train a Preference Model (PM) using mixed data: 135,296 human-labeled helpfulness comparisons and 182,831 AI-generated harmlessness comparisons.
  5. Optimize the SL-CAI policy against this preference model via RL.

Results

  • Pareto Improvements: Crowdworker evaluations (based on 10,274 helpfulness and 8,135 harmlessness comparisons) show that 52B RL-CAI models achieve superior harmlessness Elo scores at equivalent helpfulness compared to models trained on human harmlessness labels.
  • Reduced Evasiveness: When crowdworkers were explicitly instructed to prefer thoughtful explanations over evasive refusals, RL-CAI models consistently outperformed standard HH RLHF models.
  • Scaling of AI Feedback: Larger models (52B) with Chain-of-Thought reasoning approached the accuracy of human-preference-trained models on HHH evaluation benchmarks (scoring well over 80–90% accuracy on binary multiple-choice harm identification).
  • Critiques vs. Direct Revisions: Critiques yielded noticeable improvements in harmlessness scores for smaller models, while performing slightly better or equivalently on 52B models compared to direct revision.

Limitations and open questions

  • Reliance on Human Helpfulness Labels: The experiments eliminated human feedback labels only for harmlessness; the helpfulness data still relied on human comparison labels.
  • Goodharting and Over-Optimization: Extended RL training sometimes produced preachy or boilerplate language (e.g., repetitively stating “You are valid, valued, and cared for”).
  • Calibration of CoT Targets: Because Chain-of-Thought reasoning causes the model to strongly favor one choice, probability clamping was required as a heuristic to maintain preference model stability.
  • Dual-Use Concerns: Lowering the annotation barrier for steering language models also makes it easier to train models toward harmful objectives without human oversight.

Key terms

Constitutional AI (CAI)
A training framework that aligns language models using self-improvement guided by a set of explicit natural language principles rather than human harm labels.
Reinforcement Learning from AI Feedback (RLAIF)
A reinforcement learning process where reward preference models are trained on comparison labels generated by an AI model evaluating choices against specific principles.
Constitution
A short set of written rules or instructions used to steer critique, revision, and preference labeling prompts.
SL-CAI
The supervised learning stage model trained by finetuning a pretrained language model on iterative, model-generated critiques and revisions.
RL-CAI
The final policy model finetuned with reinforcement learning against a preference model trained on AI-generated harmlessness comparisons and human helpfulness comparisons.
Scaling Supervision
Techniques that enlist AI systems to help supervise other AIs, reducing reliance on direct human labeling as models scale.
Probability Clamping
A calibration technique used during Chain-of-Thought preference generation that bounds target probabilities (e.g., between 40% and 60%) to prevent overconfident labels.
Evasiveness
The failure mode where an assistant shuts down controversial or sensitive queries with blanket refusals rather than explaining why a request is harmful.

Questions

Did Constitutional AI eliminate all human data from the training pipeline?

No. The method eliminated human feedback labels for harmlessness, but still used human feedback comparisons for helpfulness, as well as human-written constitutional principles and few-shot prompt demonstrations.

Why use critiques instead of directly asking the model to revise harmful outputs?

Explicit self-critique provides transparency into the model's reasoning and significantly improved harmlessness preference scores for smaller models, while performing slightly better than direct revision on 52B models.

Why were preference probabilities clamped when using Chain-of-Thought?

Chain-of-thought outputs typically commit strongly to one option, pushing log-probabilities to near 0 or 1. Clamping the preference targets between 40% and 60% prevented the RL policy from degenerating into extreme or over-reactive behaviors.

How does Constitutional AI address model evasiveness?

By instructing models during critique, revision, and feedback to explain why objectionable requests are harmful and engaging thoughtfully rather than defaulting to generic refusals like 'I cannot answer that'.

The overview on this page was written by AI from the paper and may contain mistakes. Read the paper for the details.

Read with translation and AI