Skip to main content
QUICK REVIEW

[Paper Review] Probing Explicit and Implicit Gender Bias through LLM Conditional Text Generation

Xiangjue Dong, Yibo Wang|arXiv (Cornell University)|Nov 1, 2023
Topic ModelingComputer Science7 citations
TL;DR

This paper proposes a conditional text generation framework to probe both explicit and implicit gender bias in large language models (LLMs) without relying on predefined gender phrases or stereotypes. By using template-based, LLM-generated, and naturally-sourced inputs, the authors reveal that even without explicit gender cues, LLMs exhibit significant gender bias in logits and generated text—with model size not guaranteeing fairness.

ABSTRACT

Large Language Models (LLMs) can generate biased and toxic responses. Yet most prior work on LLM gender bias evaluation requires predefined gender-related phrases or gender stereotypes, which are challenging to be comprehensively collected and are limited to explicit bias evaluation. In addition, we believe that instances devoid of gender-related language or explicit stereotypes in inputs can still induce gender bias in LLMs. Thus, in this work, we propose a conditional text generation mechanism without the need for predefined gender phrases and stereotypes. This approach employs three types of inputs generated through three distinct strategies to probe LLMs, aiming to show evidence of explicit and implicit gender biases in LLMs. We also utilize explicit and implicit evaluation metrics to evaluate gender bias in LLMs under different strategies. Our experiments demonstrate that an increased model size does not consistently lead to enhanced fairness and all tested LLMs exhibit explicit and/or implicit gender bias, even when explicit gender stereotypes are absent in the inputs.

Motivation & Objective

  • To address the limitation of prior gender bias evaluation methods that depend on predefined gender phrases or stereotypes.
  • To detect both explicit and implicit gender bias in LLMs, even when inputs lack direct gender references or stereotypes.
  • To develop a probing framework that uses diverse input strategies to uncover hidden biases in model behavior.
  • To evaluate fairness across different model sizes and identify whether larger models are inherently more unbiased.
  • To demonstrate that gender bias can emerge in logits and generated text even in the absence of explicit gender cues.

Proposed method

  • Design three distinct probing strategies: template-based (using stereotypical attributes like occupation, hobbies, colors), LLM-generated (using model outputs as inputs), and naturally-sourced (from STS-B corpus).
  • Condition LLMs to generate continuations from these inputs, focusing on gendered pronoun usage and distributional disparities.
  • Use explicit metrics such as co-occurrence ratios of gendered pronouns (e.g., she vs. he) and implicit metrics like Jensen-Shannon divergence (JSD) on logits of gendered words.
  • Analyze logits to detect bias before text generation, revealing latent bias not always visible in output text.
  • Apply the framework across multiple LLMs (e.g., LLaMA variants) to compare fairness across model sizes.
  • Visualize bias patterns through case studies, showing bias in logits even when generated text appears neutral.

Experimental results

Research questions

  • RQ1Can gender bias in LLMs be detected even when inputs contain no explicit gender-related phrases or stereotypes?
  • RQ2How do different probing strategies (template-based, LLM-generated, naturally-sourced) affect the detection of explicit and implicit gender bias?
  • RQ3Does increasing model size consistently improve fairness in gender bias mitigation?
  • RQ4To what extent is gender bias reflected in model logits versus the final generated text?
  • RQ5Which attributes (e.g., occupations, hobbies, personalities) exhibit the highest levels of gender bias in LLM outputs?

Key findings

  • Even without explicit gender stereotypes in inputs, LLMs such as LLaMA-7B and LLaMA-70B-chat generate text with significant gender bias in pronoun usage and logits.
  • The JSD score of gendered word distributions varies across models and probing strategies, with no consistent relationship between model size and fairness.
  • LLaMA-70B-chat showed the highest JSD score on template-based and LLM-generated inputs, indicating stronger bias detection in those settings.
  • Among attributes, 'nurse', 'mechanic', 'carpenter', 'sewing', 'woodworking', and 'elegant' exhibited the highest levels of gender bias.
  • The model frequently assigns higher probabilities to female-associated pronouns (e.g., she, her) even in gender-neutral contexts, such as continuing 'My friend is talking on the phone'.
  • In some cases, gender bias is present in logits but not in the final generated text, highlighting the importance of analyzing model internals beyond surface-level outputs.

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.