Bias A-head? Analyzing Bias in Transformer-Based Language Model Attention Heads
Not on the map. Why?
Abstract (arXiv)
Transformer-based pretrained large language models (PLM) such as BERT and GPT have achieved remarkable success in NLP tasks. However, PLMs are prone to encoding stereotypical biases. Although a burgeoning literature has emerged on stereotypical bias mitigation in PLMs, such as work on debiasing gender and racial stereotyping, how such biases manifest and behave internally within PLMs remains largely unknown. Understanding the internal stereotyping mechanisms may allow better assessment of model fairness and guide the development of effective mitigation strategies. In this work, we focus on attention heads, a major component of the Transformer architecture, and propose a bias analysis framework to explore and identify a small set of biased heads that are found to contribute to a PLM's stereotypical bias. We conduct extensive experiments to validate the existence of these biased heads and to better understand how they behave. We investigate gender and racial bias in the English language in two types of Transformer-based PLMs: the encoder-based BERT model and the decoder-based autoregressive GPT model. Overall, the results shed light on understanding the bias behavior in pretrained language models.
Key facts. Cited by 14 papers in the map (data through 14 Oct 2026). Builds on 43 of its 65 references that are in the map. First posted on arXiv 17 Nov 2023.
Builds on
43 of 65 references.
References · 43
- 2017Attention Is All You Needcited by 60,361
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,399
- 2020Language Models are Few-Shot Learnerscited by 32,419
- 2022Training language models to follow instructions with human feedbackcited by 15,971
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2022PaLM: Scaling Language Modeling with Pathwayscited by 5,326
- 2018GLUE: A Multi-Task Benchmark and Analysis Platform for Natural Language Understandingcited by 4,899
- 2023Tree of Thoughts: Deliberate Problem Solving with Large Language Modelscited by 3,211
- 2019What Does BERT Look At? An Analysis of BERT's Attentioncited by 1,003
- 2020Language (Technology) is Power: A Critical Survey of "Bias" in NLPcited by 956
- 2020StereoSet: Measuring stereotypical bias in pretrained language modelscited by 924
- 2016Semantics derived automatically from language corpora contain human-like biasescited by 901
31 more
- 2019Are Sixteen Heads Really Better than One?cited by 816
- 2020A Primer in BERTology: What we know about how BERT workscited by 815
- 2023Bias and Fairness in Large Language Models: A Surveycited by 639
- 2019The Woman Worked as a Babysitter: On Biases in Language Generationcited by 541
- 2019On Measuring Social Biases in Sentence Encoderscited by 398
- 2019Measuring Bias in Contextualized Word Representationscited by 276
- 2019Lipstick on a Pig: Debiasing Methods Cover up Systematic Gender Biases in Word Embeddings But do not Remove Themcited by 268
- 2023ChatIE: Zero-Shot Information Extraction via Chatting with ChatGPTcited by 250
- 2020Measuring and Reducing Gendered Correlations in Pre-trained Modelscited by 224
- 2019Counterfactual Data Augmentation for Mitigating Gender Stereotypes in Languages with Rich Morphologycited by 200
- 2020Social Biases in NLP Models as Barriers for Persons with Disabilitiescited by 182
- 2020Towards Debiasing Sentence Representationscited by 171
- 2018Learning Gender-Neutral Word Embeddingscited by 169
- 2020Detecting Emergent Intersectional Biases: Contextualized Word Embeddings Contain a Distribution of Human-like Biasescited by 167
- 2023Evaluating Correctness and Faithfulness of Instruction-Following Models for Question Answeringcited by 151
- 2017Learning to Generate Reviews and Discovering Sentimentcited by 148
- 2019Black is to Criminal as Caucasian is to Police: Detecting and Removing Multiclass Bias in Word Embeddingscited by 147
- 2019Predictive Biases in Natural Language Processing Models: A Conceptual Framework and Overviewcited by 137
- 2019Assessing Social and Intersectional Biases in Contextualized Word Representationscited by 135
- 2023Evaluating ChatGPT's Information Extraction Capabilities: An Assessment of Performance, Explainability, Calibration, and Faithfulnesscited by 130
- 2021Debiasing Pre-trained Contextualised Embeddingscited by 107
- 2021Sustainable Modular Debiasing of Language Modelscited by 100
- 2021An Empirical Survey of the Effectiveness of Debiasing Techniques for Pre-trained Language Modelscited by 97
- 2023Exploring the Feasibility of ChatGPT for Event Extractioncited by 76
- 2021FairFil: Contrastive Neural Debiasing Method for Pretrained Text Encoderscited by 75
- 2019Gender-preserving Debiasing for Pre-trained Word Embeddingscited by 61
- 2022Entropy-based Attention Regularization Frees Unintended Bias Mitigation from Listscited by 55
- 2021Low Frequency Names Exhibit Bias and Overfitting in Contextualizing Language Modelscited by 39
- 2023Identifying and Adapting Transformer-Components Responsible for Gender Bias in an English Language Modelcited by 22
- 2022Controlling Bias Exposure for Fair Interpretable Predictionscited by 18
- 2020Discovering and Categorising Language Biases in Redditcited by 13
Built on by
Citing papers per year: 2024: 3; 2025: 6; 2026: 5.
14 papers.
Sort:
By area:
- 2024Cutting Off the Head Ends the Conflict: A Mechanism for Interpreting and Mitigating Knowledge Conflicts in Language Modelscited by 91
- 2024Large Language Model Safety: A Holistic Surveycited by 59
- 2024Towards Uncovering How Large Language Model Works: An Explainability Perspectivecited by 22
- 2025Interpretation Meets Safety: A Survey on Interpretation Methods and Tools for Improving LLM Safetycited by 10
- 2025LLM Bias Detection and Mitigation through the Lens of Desired Distributionscited by 4
- 2025Ontologies in Design: How Imagining a Tree Reveals Possibilites and Assumptions in Large Language Modelscited by 3
- 2025KLAAD: Refining Attention Mechanisms to Reduce Societal Bias in Generative Language Modelscited by 3
- 2026SafeRoPE: Risk-specific Head-wise Embedding Rotation for Safe Generation in Rectified Flow Transformerscited by 2
- 2025From n-gram to Attention: How Model Architectures Learn and Propagate Bias in Language Modelingcited by 1
- 2025Debiasing LLMs by Masking Unfairness-Driving Attention Headscited by 0
- 2026Mechanistic Knobs in LLMs: Retrieving and Steering High-Order Semantic Features via Sparse Autoencoderscited by 0
- 2026Can We Locate and Prevent Stereotypes in LLMs?cited by 0
- 2026Toward Localizing and Repairing Bias in Transformer Attention Heads14 Jul 2026
- 2026Mechanics of Bias and Reasoning: Interpreting the Impact of Chain-of-Thought Prompting on Gender Bias in LLMs19 May 2026
- 2026SafeRoPE: Risk-specific Head-wise Embedding Rotation for Safe Generation in Rectified Flow Transformers2 Apr 2026
- 2026Can We Locate and Prevent Stereotypes in LLMs?26 Mar 2026
- 2026Mechanistic Knobs in LLMs: Retrieving and Steering High-Order Semantic Features via Sparse Autoencoders6 Jan 2026
- 2025Debiasing LLMs by Masking Unfairness-Driving Attention Heads11 Oct 2025
- 2025LLM Bias Detection and Mitigation through the Lens of Desired Distributions7 Oct 2025
- 2025KLAAD: Refining Attention Mechanisms to Reduce Societal Bias in Generative Language Models26 Jul 2025
- 2025Interpretation Meets Safety: A Survey on Interpretation Methods and Tools for Improving LLM Safety5 Jun 2025
- 2025From n-gram to Attention: How Model Architectures Learn and Propagate Bias in Language Modeling18 May 2025
- 2025Ontologies in Design: How Imagining a Tree Reveals Possibilites and Assumptions in Large Language Models3 Apr 2025
- 2024Large Language Model Safety: A Holistic Survey23 Dec 2024
- 2024Cutting Off the Head Ends the Conflict: A Mechanism for Interpreting and Mitigating Knowledge Conflicts in Language Modelscited by 91
- 2025LLM Bias Detection and Mitigation through the Lens of Desired Distributionscited by 4
- 2025Ontologies in Design: How Imagining a Tree Reveals Possibilites and Assumptions in Large Language Modelscited by 3
- 2025KLAAD: Refining Attention Mechanisms to Reduce Societal Bias in Generative Language Modelscited by 3
- 2025From n-gram to Attention: How Model Architectures Learn and Propagate Bias in Language Modelingcited by 1
- 2025Debiasing LLMs by Masking Unfairness-Driving Attention Headscited by 0
- 2026Can We Locate and Prevent Stereotypes in LLMs?cited by 0
- 2026Toward Localizing and Repairing Bias in Transformer Attention Headscited by 0
- 2026Toward Localizing and Repairing Bias in Transformer Attention Heads14 Jul 2026
- 2026Can We Locate and Prevent Stereotypes in LLMs?26 Mar 2026
- 2025Debiasing LLMs by Masking Unfairness-Driving Attention Heads11 Oct 2025
- 2025LLM Bias Detection and Mitigation through the Lens of Desired Distributions7 Oct 2025
- 2025KLAAD: Refining Attention Mechanisms to Reduce Societal Bias in Generative Language Models26 Jul 2025
- 2025From n-gram to Attention: How Model Architectures Learn and Propagate Bias in Language Modeling18 May 2025
- 2025Ontologies in Design: How Imagining a Tree Reveals Possibilites and Assumptions in Large Language Models3 Apr 2025
- 2024Cutting Off the Head Ends the Conflict: A Mechanism for Interpreting and Mitigating Knowledge Conflicts in Language Models28 Feb 2024