Skip to main content
QUICK REVIEW

[Paper Review] Benchmarking Bias in Large Language Models during Role-Playing

Xinyue Li, Zhenpeng Chen|arXiv (Cornell University)|Nov 1, 2024
Natural Language Processing TechniquesComputer Science5 citations
TL;DR

BiasLens is an automated fairness-testing framework that probes biases in LLMs during role-playing, using 33,000 bias-triggering questions across 11 demographics, evaluating six models and reporting 72,716 biased responses. The authors release the benchmark and scripts for further research.

ABSTRACT

Large Language Models (LLMs) have become foundational in modern language-driven applications, profoundly influencing daily life. A critical technique in leveraging their potential is role-playing, where LLMs simulate diverse roles to enhance their real-world utility. However, while research has highlighted the presence of social biases in LLM outputs, it remains unclear whether and to what extent these biases emerge during role-playing scenarios. In this paper, we introduce BiasLens, a fairness testing framework designed to systematically expose biases in LLMs during role-playing. Our approach uses LLMs to generate 550 social roles across a comprehensive set of 11 demographic attributes, producing 33,000 role-specific questions targeting various forms of bias. These questions, spanning Yes/No, multiple-choice, and open-ended formats, are designed to prompt LLMs to adopt specific roles and respond accordingly. We employ a combination of rule-based and LLM-based strategies to identify biased responses, rigorously validated through human evaluation. Using the generated questions as the benchmark, we conduct extensive evaluations of six advanced LLMs released by OpenAI, Mistral AI, Meta, Alibaba, and DeepSeek. Our benchmark reveals 72,716 biased responses across the studied LLMs, with individual models yielding between 7,754 and 16,963 biased responses, underscoring the prevalence of bias in role-playing contexts. To support future research, we have publicly released the benchmark, along with all scripts and experimental results.

Motivation & Objective

  • Assess whether role-playing induces social biases in LLM outputs.
  • Develop an automated fairness-testing framework (BiasLens) for role-playing scenarios.
  • Build and release a large-scale bias benchmark across multiple demographic attributes.
  • Evaluate bias prevalence across six major LLMs and analyze role-playing effects and non-determinism.

Proposed method

  • Use GPT-4o to generate 550 social roles spanning 11 demographic attributes.
  • For each role, automatically generate 60 questions (Yes/No, Choice, Why), totaling 33,000 questions, later pruned to 32,864.
  • Design test oracles: rule-based for Yes/No and Choice; LLM-based majority voting for Why questions.
  • Query six LLMs three times per question and classify bias by majority responses (two of three).
  • Provide open benchmark, scripts, and experimental results for public use.
Figure 1. Examples of biased responses from GPT4o-mini and Llama3-70b during role-playing. Each question was queried independently on each model three times, and consistent responses were obtained across all queries for each model on October 1, 2024.
Figure 1. Examples of biased responses from GPT4o-mini and Llama3-70b during role-playing. Each question was queried independently on each model three times, and consistent responses were obtained across all queries for each model on October 1, 2024.

Experimental results

Research questions

  • RQ1RQ1: How effective is BiasLens at exposing bias in LLMs during role-playing?
  • RQ2RQ2: Are the biases exposed by BiasLens valid as determined by manual evaluation?
  • RQ3RQ3: Do biases observed during role-playing persist when no role is assigned?
  • RQ4RQ4: How does LLM non-determinism affect the fairness testing results?

Key findings

  • The benchmark identifies 72,716 biased responses across six LLMs.
  • Individual models yield between 7,754 and 16,963 biased responses.
  • Llama-3-8B shows the highest bias count (16,963) among the six models.
  • Removing role-playing statements reduces biased responses by an average of 24.3%.
  • Model bias levels do not strictly align with overall model capability rankings on external leaderboards.
Figure 2. Overview of BiasLens.
Figure 2. Overview of BiasLens.

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.