Abstract
SENT-DEBIAS is a novel, post-hoc method designed to remove social biases—such as gender and religion—from state-of-the-art sentence representations like BERT and ELMo. By contextualizing bias-attribute words into diverse sentence templates and using Principal Component Analysis (PCA) to identify a "bias subspace," the method effectively reduces prejudice without requiring expensive retraining or significantly sacrificing downstream task performance.
Introduction
As NLP models are increasingly integrated into sensitive domains like healthcare and legal systems, the risk of propagating human social biases (stereotypes regarding gender, race, or religion) becomes a critical concern. While methods exist to debias word-level embeddings (e.g., GloVe), debiasing contextualized sentence-level representations (e.g., BERT, ELMo) is more challenging due to the immense computational cost of retraining and the infinite variety of sentence syntax and context.
Methodology: The SENT-DEBIAS Pipeline
The authors propose SENT-DEBIAS, a four-step pipeline that extends the "Hard-Debias" framework to sentence representations:
- Defining Bias Attributes: Identifying seed word sets (e.g., man/woman for gender).
- Contextualizing Words: Instead of simple templates, the method pulls thousands of naturally occurring "templates" from diverse text corpora (WikiText-2, SST, Reddit, etc.). Attribute words are replaced within these real-world sentences to create pairs identical except for the bias attribute.
- Estimating the Bias Subspace: Sentence pairs are passed through a pretrained encoder. PCA is applied to the differences between these representations to identify the "subspace" where bias resides.
- Debiasing (Neutralization): New sentences are debiased by projecting their vectors onto this bias subspace and subtracting that projection, effectively "canceling out" the bias components.
Key Insights
A critical finding is that the diversity of sentence templates matters more than the quantity. Using templates from multiple domains (e.g., mixing Reddit with Wikipedia) allows the PCA to find a bias subspace that generalizes across writing styles.
Furthermore, the authors observed that fine-tuning BERT on specific tasks can sometimes amplify bias if the task data is skewed. SENT-DEBIAS provides a controlled, post-hoc way to target specific biases regardless of the task or original training data.
Results and Evaluation
SENT-DEBIAS consistently reduced bias across almost all tests. For BERT, the average absolute effect size of bias dropped from +0.354 to +0.256. Importantly, the "fairness tax" was minimal; BERT’s accuracy on the SST-2 sentiment task only dipped from 92.7% to 89.1%, while ELMo’s performance actually improved slightly.
Visual analysis via t-SNE plots confirms these findings. After debiasing, neutral concepts like "science" or "art" move to a more equidistant position between gendered terms, whereas they were previously clustered closer to one gender.
Limitations and Future Work
The study primarily treats gender as binary and focuses on "neutralizing" non-gendered sentences rather than "equalizing" pairs. Additionally, current bias metrics like SEAT may not fully capture real-world model behavior. Future work is needed to address non-binary gender identities and languages with grammatical gender.
Summary updated