TL;DR
This paper introduces "Perspective-Taking Prompting" (PET), a novel method that leverages social psychology principles to guide Large Language Models (LLMs) in reducing toxic and biased outputs. PET enables LLMs to self-regulate their responses by imagining diverse human perspectives, achieving significant reductions in toxicity and bias without requiring white-box access or extensive retraining.
What Problem Does This Paper Address?
Large Language Models (LLMs) are increasingly powerful but often generate toxic and biased content due to their training on vast, unsanitized web data. Existing solutions to mitigate these issues face significant challenges: they often require white-box access to the model's internals or substantial, costly retraining, making them impractical for cutting-edge commercial LLMs. Furthermore, many current prompting methods rely on external tools for feedback, which can be slow, complex to deploy, and sometimes fail to address both toxicity and bias concurrently, or even exacerbate bias. This paper tackles the need for an effective, black-box compatible, and self-contained method to reduce harmful LLM outputs.
Methods
The core innovation is Perspective-Taking Prompting (PET). Inspired by social psychology's concept of emotional intelligence and perspective-taking, PET aims to make LLMs self-regulate. It involves two main steps:
- Constructing Context with Audiences: The LLM is prompted to imagine a scenario and consider potential audiences from diverse demographic groups. This helps the model anticipate varied reactions and emotions.
- Perspective-Taking Prompting: The LLM is then instructed to adopt one of two perspective-taking approaches:
- PET-IO (Imagine Others): The LLM imagines how specific audiences would perceive and feel about a given comment.
- PET-IS (Imagine Self): The LLM imagines itself in the position of each audience member and considers how it would feel.
These generated perspectives serve as natural language feedback, guiding the LLM to revise its initial response and produce less harmful content. This self-correction is performed in a single step, making it efficient.
Datasets
The study utilizes two primary datasets for evaluation:
- RTP-High: A subset of the RealToxicityPrompts (RTP) dataset, specifically curated to elicit toxic completions from LLMs. This subset consists of 1,604 prompts with a toxicity score greater than 0.3.
- BOLD-1.5K: A subset of the BOLD dataset, used for bias assessment. It includes prompts related to gender and race across five domains, sampled to ensure similar distributions to the original dataset.
Key Insights and Ideas
- LLMs Can Self-Regulate: The most significant insight is that LLMs possess the inherent capability to significantly reduce toxicity and bias in their own outputs, simply by being prompted to consider diverse perspectives. This challenges the notion that external tools or extensive retraining are always necessary.
- Social Psychology as a Guide: Applying principles from social psychology, specifically perspective-taking, offers a powerful and intuitive mechanism for improving LLM safety.
- Imagine Others vs. Imagine Self: While both PET-IO and PET-IS are effective, the paper notes that for LLMs, the distinction between imagining others' feelings and imagining oneself in their shoes is less pronounced than in humans, as LLMs lack personal experiences.
- Prompt Sensitivity is Low: The PET approach appears robust to minor variations in prompt phrasing, suggesting that the core concept of perspective-taking is more critical than the exact wording.
- Iterative Prompting Isn't Always Better: Contrary to some self-correction methods, iterative prompting for PET did not consistently improve results and sometimes worsened them, possibly due to context length distractions.
Key Results
- Significant Toxicity Reduction: PET achieved up to an 89% reduction in toxicity.
- Significant Bias Reduction: PET achieved up to a 73% reduction in bias.
- Superior to Baselines: PET consistently outperformed five strong baselines, including methods relying on external feedback (CRITIC, SHAP) and intrinsic self-correction techniques.
- Black-Box Compatibility: PET works effectively on commercial LLMs like ChatGPT and GLM without requiring white-box access or additional training.
- Human Evaluation Alignment: Automatic evaluation results were largely consistent with human evaluations, reinforcing the effectiveness of PET.
Limitations and Future Work
- Limited Model Selection: The study primarily evaluated two commercial LLMs (ChatGPT, GLM) and three open-source models. The generalizability to other advanced models like GPT-4 or Gemini is not yet confirmed.
- Prompt Optimization: While PET is effective, the specific prompts used were manually curated and not extensively optimized. Future work could explore automatic prompt generation techniques.
- Computational Cost: PET, while effective, incurs a higher computational cost due to the multiple introspection steps involved in generating perspectives.
- Ethical Threats: The study focused on toxicity and bias, but other ethical threats like morality were not addressed.
- Dataset Scope: The debiasing analysis was limited to gender and race on a subset of the BOLD dataset, suggesting a need for more comprehensive datasets.
- Open-Source LLM Performance: Mixed results were observed on some open-source LLMs, potentially due to their less advanced reasoning capabilities compared to commercial models.
Future work could involve exploring automatic prompt optimization, expanding the scope of ethical threats, and testing PET on a wider range of LLMs and datasets.
Summary updated