Style Pooling: Automatic Text Style Obfuscation for Improved Classification Fairness

Fatemehsadat Mireshghallah, Taylor Berg-Kirkpatrick

Introduction

Human communication is rich with stylistic markers—slang, punctuation, and vocabulary—that inadvertently reveal sensitive attributes such as age, gender, or ethnicity. This "stylistic leakage" poses a significant challenge to algorithmic fairness. For instance, a hiring model might discriminate against a candidate based on the linguistic style of their cover letter, even if explicit demographic data is removed. While previous work has focused on de-biasing internal representations, these methods do not address the source: the text itself. This paper introduces a framework to rewrite text into a "neutral" style, preserving semantic content while obfuscating protected attributes.

Methodology

The proposed framework utilizes Variational Autoencoders (VAEs) to encode input sentences into a latent space and decode them into obfuscated versions. The core innovation lies in Style Pooling, which employs specialized priors to guide the generation process toward a neutral style.

The Style Pooling framework uses VAEs and domain-specific language models to create Intersection or Union priors for text obfuscation.

Two primary pooling strategies are explored:

  • Intersection Prior: This approach targets a "minimal" style by leveraging language models from different domains (e.g., different age groups). It encourages the decoder to select words common across all domains, effectively stripping away niche stylistic markers.
  • Union Prior: This strategy aims for a "maximal" style, blending features from all domains to create a stylistic mixture where no single attribute is dominant.

Additionally, a Style De-boosting mechanism is introduced to penalize words with high "style scores"—those statistically more likely to appear in specific domains—further refining the obfuscation process.

Experimental Evaluation

The framework was evaluated across several diverse datasets, including a Blogs Dataset (labeled with author age and occupation), Twitter (PAN16) for age and gender markers, and the DIAL Dataset containing African American English (AAE) and Standard American English (SAE). A Synthetic Yelp dataset was also used to test the model's ability to neutralize artificial stylistic markers like deliberate misspellings.

Key Results

The Intersection approach proved particularly effective at enhancing fairness. On the Blogs dataset, the True Positive Rate (TPR) gap—a key metric for bias—was significantly reduced.

Comparison of Occupation Accuracy (Utility) and TPR-gap (Fairness) across different ratios and configurations.

As shown in the results, the Style Pooling method (specifically Intersection with De-boosting, denoted as DB) achieved a substantial reduction in bias. For example, at a 0.95 ratio, the TPR-gap was reduced from 0.54 in the original text to 0.21 using Intersection with DB=40, with only a marginal drop in Occupation Accuracy. Furthermore, human evaluations confirmed that Style Pooling obfuscations were preferred over previous state-of-the-art baselines (A4NT) for both fluency (60.38%) and semantic consistency (72.13%).

Discussion and Ethical Considerations

While Style Pooling offers a robust path toward fairer NLP systems, it raises ethical concerns regarding the "white-washing" effect. By mapping diverse linguistic expressions to a centralized, neutral style, there is a risk of erasing the unique voices of marginalized communities. If the "neutral" style defaults to the dominant cultural norm, the system may inadvertently enforce linguistic assimilation. Future research must address how to protect privacy and fairness without completely homogenizing human expression.

Conclusion

Style Pooling demonstrates that text-level obfuscation is a viable and effective strategy for mitigating stylistic leakage. By decoupling "what" is said from "how" it is said, this framework provides a tool for building more equitable machine learning systems and protecting author privacy in both algorithmic and human-centric decision-making processes.

Summary updated

BibTeX
@inproceedings{mireshghallah2021style,
  author = {Fatemehsadat Mireshghallah and Taylor Berg-Kirkpatrick},
  title = {{Style Pooling: Automatic Text Style Obfuscation for Improved Classification Fairness}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2021},
  doi = {10.18653/v1/2021.emnlp-main.152},
}
Figure