Style Pooling: Automatic Text Style Obfuscation for Improved Classification Fairness

Fatemehsadat Mireshghallah, Taylor Berg-Kirkpatrick

Abstract

Textual style often inadvertently leaks sensitive author attributes such as age, gender, or ethnicity, leading to privacy violations and algorithmic bias in downstream tasks. We present Style Pooling, a Variational Autoencoder (VAE) framework designed for unsupervised style transfer. By employing novel "Intersection" and "Union" priors derived from domain-specific language models, Style Pooling rewrites text into a style-neutral or style-mixed version. Our results demonstrate that this approach significantly reduces fairness gaps in classifiers while maintaining high semantic integrity and fluency.

Introduction

Even when explicit identifiers are removed, an author's unique "stylistic fingerprint"—encompassing word choice, syntax, and idiosyncratic patterns—can reveal protected attributes. This "stylistic leakage" poses significant risks: it allows for unauthorized inference of private information and enables machine learning models to develop biases based on these stylistic cues. For instance, a recruitment model might unfairly penalize candidates whose writing style is associated with a specific demographic.

While previous research has focused on de-biasing internal latent representations, such methods do not address the needs of human readers. Style Pooling addresses this by performing automatic text re-writing, producing obfuscated text that is fair for both human and algorithmic consumption.

Methodology: The Style Pooling Framework

The core of our approach is a VAE-based architecture optimized for unsupervised style transfer. The model maps an input sentence $x$ to an obfuscated latent variable $y$, which is then decoded to produce the final text.

Figure 1: The Style Pooling architecture utilizes domain-specific language models to guide the generation of style-neutral (Intersection) or style-mixed (Union) text.

Style-Pooling Priors

The innovation lies in the use of multiple language models (LMs), each trained on a specific domain (e.g., different age groups). These LMs serve as priors to guide the obfuscation process:

  • Intersection Prior: This prior encourages the model to select words and structures that are highly probable across all domain LMs. It effectively identifies the "common denominator" of styles, stripping away unique markers to find a neutral center.
  • Union Prior: This approach takes the minimum likelihood across domains for each token, encouraging the model to incorporate stylistic features from all groups. The resulting "union" style makes it difficult to attribute the text to any single original group.

Style De-boosting

To further enhance obfuscation, we introduce a "style score" during decoding. This mechanism penalizes tokens that are highly indicative of a specific domain, ensuring that even subtle stylistic markers are scrubbed from the output.

Experimental Evaluation

We evaluated Style Pooling across four datasets:

  1. Synthetic Yelp: Used to test the model's ability to correct or spread artificial stylistic markers (e.g., specific misspellings).
  2. Blogs Dataset: Real-world posts labeled with author age and occupation.
  3. Twitter (PAN16): Tweets labeled with age and gender.
  4. DIAL Dataset: Focused on racial dialect obfuscation between African American English (AAE) and Standard American English (SAE).

Results and Analysis

Our experiments reveal that the Intersection approach is particularly effective for improving fairness.

Fairness and Utility Trade-offs

On the Blogs dataset, Style Pooling significantly reduced the TPR-gap (True Positive Rate gap), a key metric for measuring algorithmic bias. As shown in the table below, the Intersection model reduces bias in occupation classification while preserving a high degree of utility (accuracy).

Figure 5: Performance metrics on the Blogs dataset, showing the trade-off between occupation classification accuracy (utility) and the TPR-gap (fairness).

Text Quality and Obfuscation Success

In human evaluations, Style Pooling outperformed the state-of-the-art baseline (A4NT), with participants preferring our model's outputs for fluency (60.38%) and semantic consistency (72.13%). In the synthetic Yelp experiment, the Intersection model successfully "corrected" domain-specific misspellings back to standard forms with 99.2% accuracy, demonstrating its precision in identifying stylistic markers. The model also achieved a better trade-off between attribute removal and text quality compared to PATR, a recent adversarial text re-writing framework.

Discussion and Limitations

While Style Pooling represents a significant step forward, it faces challenges. One primary concern is content-based leakage: if an author's age is inferred from the topic they discuss rather than how they write, stylistic obfuscation alone may be insufficient.

Furthermore, we acknowledge the ethical risk of "white-washing." By mapping diverse voices to a "central" style, there is a danger of erasing the unique linguistic identities of marginalized communities. Future work will focus on defining "centrality" more inclusively and improving the disentanglement of style from content.

Conclusion

Style Pooling provides a robust framework for protecting author privacy and reducing algorithmic bias through automatic text re-writing. By "pooling" styles into a neutral intersection, we can create data that is fairer for both humans and machines without sacrificing linguistic quality.

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