Learning Fair Representations for Kernel Models

Zilong Tan, Samuel Yeom, Matt Fredrikson, Ameet Talwalkar

Introduction

Machine learning models often inadvertently learn to discriminate based on protected attributes like race or gender. Traditional approaches to mitigate this involve learning "fair representations"—transforming data into a format where protected information is removed before model training. However, most existing techniques are model-agnostic, treating the downstream learner as a black box. This "one-size-fits-all" preprocessing often leads to a significant "fairness tax"—a steep drop in accuracy because the representation isn't optimized for the specific type of model being used.

This paper addresses this gap by proposing model-aware fair representations specifically designed for kernel-based models, such as Support Vector Machines and Gaussian Processes. By leveraging the geometry of Reproducing Kernel Hilbert Spaces (RKHS), the authors introduce the first Fair Gaussian Process (FGP) that offers provable fairness guarantees while maintaining higher accuracy than traditional model-agnostic methods.

Methodology: Sufficient Dimension Reduction in RKHS

The core of the proposed approach is a technique called Sufficient Dimension Reduction (SDR) applied within the RKHS.

Subspace Carving and Orthogonal Complement

Instead of using SDR solely to find features predictive of the target $Y$, the authors use it to identify the subspace of the RKHS that captures the statistical dependency of the protected attribute $S$. Once this "biased" subspace is identified, they take its orthogonal complement. Any function residing in this "fair subspace" is, by definition, statistically independent of the protected attribute under certain distributional assumptions.

To balance prediction accuracy and fairness, the authors introduce a trade-off parameter $\epsilon$. This parameter is based on the "principal angle" between the best predictive subspace and the fairest subspace. By tuning $\epsilon$, users can control how closely the model adheres to the fair subspace versus the predictive one.

Fair Gaussian Processes (FGP)

The theory is extended to Bayesian modeling through the creation of a new GP prior. By modifying the covariance kernel to only allow "fair" sample paths, the resulting Bayesian model ensures fairness criteria like Statistical Parity (SP) or Equalized Odds (EO) are satisfied.

Experimental Evaluation

The authors evaluated their method on five real-world datasets across classification and regression tasks:

  • Classification: The Adult income dataset and the COMPAS recidivism risk dataset (using gender as the protected attribute).
  • Regression: UCI Communities and Crime, the National Longitudinal Survey of Youth (NLSY), and Law School Admissions data.

These regression datasets were specifically chosen to test the model's ability to handle multiple, continuous protected attributes (e.g., race and age simultaneously), a scenario where many baseline methods struggle.

Key Results

The experimental results demonstrate that the FGP consistently outperforms state-of-the-art methods in terms of the accuracy-fairness trade-off.

Comparison of accuracy-fairness trade-offs for classification tasks across different fairness metrics (SP, EOP, EO).

In classification tasks on Adult and COMPAS (Figure 1), the FGP generally achieved higher accuracy for the same level of fairness compared to methods like LAFTR-GP or FERM. The "model-aware" nature of the fairness constraint allows the model to retain more useful predictive information.

RMSE vs. Statistical Parity (SP) for regression datasets with multiple protected attributes.

In regression experiments with multiple protected attributes (Figure 3), the FGP's accuracy-fairness curves were notably steeper than the competition (NCFR). This indicates that the FGP loses less accuracy as fairness requirements are increased. Furthermore, the SDR-based approach naturally handles continuous protected attributes without requiring discretization.

Discussion and Future Work

The "aha moment" of this work is the realization that statistical independence in kernel models can be treated as a geometric problem. By defining a subspace in the RKHS "blind" to $S$, fairness is guaranteed.

However, some limitations remain. Like most kernel methods, the approach has a computational complexity of $O(n^2)$ or $O(n^3)$, which may be prohibitive for very large datasets. Future work could explore randomized approximations, such as Random Fourier Features, to improve scalability. Additionally, while the method supports various fairness definitions, it relies on certain distributional assumptions (e.g., elliptically contoured distributions) for the theoretical proof of independence, which may not always perfectly match real-world data.

Summary updated

BibTeX
@inproceedings{tan2020learning,
  author = {Zilong Tan and Samuel Yeom and Matt Fredrikson and Ameet Talwalkar},
  title = {{Learning Fair Representations for Kernel Models}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2020},
}
Figure