This research, presented at AAAI-20 by a team from the University of Utah, investigates how social biases—specifically gender, nationality, and religion—manifest as "invalid logic" in Natural Language Processing (NLP) models. Rather than relying solely on internal geometric properties of word vectors, the authors demonstrate how these biases lead models to make incorrect inferences. They further propose a mitigation strategy that targets the static layers of both traditional and contextualized embeddings.
The Problem: Beyond Geometric Distance
Most research on bias in word embeddings relies on intrinsic measures, such as the cosine distance between "doctor" and "man" versus "woman." However, these measures have two major flaws:
- The Gap to Reality: Vector distances don't always explain how a model will actually behave in a complex downstream task like summarization or question answering.
- The Contextual Challenge: Modern models like BERT and ELMo produce different vectors for the same word depending on its context, making traditional distance-based bias tests difficult to apply.
The authors address this by using Natural Language Inference (NLI)—the task of determining if a premise entails, contradicts, or is neutral toward a hypothesis—as an extrinsic probe. If a model sees "The accountant ate a bagel" and concludes it must entail "The man ate a bagel," the model is exhibiting a measurable, logically invalid bias.
Probing via NLI
The researchers constructed millions of sentence pairs that should be logically neutral. For example, knowing someone is an "accountant" should not provide enough information to infer their gender.
When models predict "Entailment" or "Contradiction" for these pairs, they reveal underlying stereotypes. The study utilized massive synthetic datasets covering gender (~2M pairs), nationality (~2.1M pairs), and religion (~1.1M pairs) to evaluate these failures of reasoning.
Mitigation via Projection
To address these biases, the authors employed a projection method. They identified a "bias subspace" (e.g., the direction in vector space that defines gender by looking at pairs like he/she) and mathematically removed that component from all other word vectors.
A key finding for contextual models (BERT and ELMo) was that projecting bias out of every layer was ineffective. Instead, the most successful approach involved applying the projection only to the static components—the initial lookup table or the first layer—before the model's complex, non-linear contextual machinery processed the data. This suggests that cleaning the "raw" input prevents the model from amplifying subtle residual biases in deeper layers.
Key Results
The study found that all baseline models (GloVe, ELMo, BERT) exhibited significant bias. In gender-occupation tests, the "Net Neutral" scores (where 1.0 is ideal) were initially low, ranging from 0.38 to 0.42.
As shown in the results for GloVe, projecting out the gender direction significantly improved the model's ability to remain neutral. Specifically, the fraction of high-confidence neutral predictions (T:0.7) increased by 160.5%. For ELMo, applying projection to the first layer increased high-confidence neutral predictions from 0.063 to 0.364—a nearly five-fold improvement. Crucially, these debiasing efforts did not degrade performance on standard SNLI benchmarks; in some cases, accuracy even improved slightly.
Discussion and Limitations
While effective for gender in static and early contextual layers, nationality and religious biases proved more difficult to mitigate, particularly in BERT. The authors attribute this to the complexity of subword embeddings (e.g., "Kosovar" being split into "ko", "sov", "ar"), which makes defining a clean bias subspace challenging compared to simple gendered words like "he" and "she."
The paper concludes that bias is not just a representation issue but a failure of reasoning. Future work should explore integrating these constraints directly into the training process via loss functions that penalize invalid inferences, rather than relying solely on post-hoc embedding adjustments.
Summary updated