Learning Adversarially Fair and Transferable Representations

Description

Learning Adversarially Fair and Transferable Representations (LAFTR) trains an encoder that turns each record into a representation, a vector of learned features, from which a protected attribute is hard to recover, so that models later built on that representation by other parties, including for prediction tasks not known in advance, also treat groups fairly. It was designed for a data owner who shares encoded data with downstream model builders and cannot control how they train. During training, the encoder, a decoder that reconstructs the input and a classifier for the original task play against an adversary network that tries to predict the protected attribute from the representation; the encoder is updated to defeat the adversary while keeping the information the other two need. The adversary's objective is matched to demographic parity, equalised odds or equal opportunity, and the authors prove that an optimal adversary's objective bounds that unfairness measure for any classifier trained on the representation (for the two error-rate measures the adversary also sees the labels used in training, so the attribute is hidden given the label, and the bound is with respect to those labels). The output is a frozen encoder, delivered with the accuracy and fairness of classifiers trained on top of it.

Example Use Cases

Fairness

A data marketplace that supplies customer records to advertisers wants assurance that the targeting models advertisers build will not show offers to men and women at different rates. It trains LAFTR with the demographic parity adversary, releases only the encoded features, and audits a sample of advertisers' models for the gap in positive rates and for how well a fresh classifier can recover gender from the released features.

A health insurer's data team shares encoded claims and prescription data with external analytics suppliers who build their own risk models. It trains LAFTR with an equalised-odds adversary on a comorbidity-risk task, with patients aged 70 or over as the protected group, then measures error-rate gaps for classifiers trained on held-out condition-prediction tasks, because fairness on those new tasks has to be measured rather than assumed.

A hospital imaging research group compares LAFTR with standard training for a chest X-ray triage classifier, with patient sex as the protected attribute and the model-selection rule fixed in advance, to decide whether debiasing the representation narrows the gap in error rates enough to justify its extra training cost.

Limitations

  • The fairness bound holds only for an optimal adversary. A weak or under-trained adversary underestimates how much protected information the representation still carries, so downstream models can be less fair than training suggested; the authors report uneven results in places, which they attribute to unstable adversarial training. Audit downstream models directly, including with a fresh classifier trained to recover the protected attribute from the representation.
  • Transfer to new tasks is not guaranteed for the error-rate criteria. The equalised-odds and equal-opportunity adversaries use the original task's labels, so fairness on a new task with different labels is an empirical result: in the paper's health-data experiment LAFTR was the fairest method on seven of ten transfer tasks, and the authors leave open which tasks transfer fairly.
  • As formulated, it handles one binary protected attribute and a binary task label; intersectional groups, several attributes or multi-class outcomes need an extension. Training needs the protected attribute and, for the error-rate criteria, the task labels. In the paper's experiments the encoder also took the protected attribute as input, so it is needed whenever new records are encoded; no results are reported without it.
  • Measured gains can be small in practice. MEDFAIR, a peer-reviewed benchmark of eleven bias-mitigation methods including LAFTR on medical imaging datasets, found the methods did not significantly improve fairness over standard training when trained and tested on the same task, including across datasets (it did not test transfer to new tasks), and that the model-selection criterion changed fairness results substantially. Compare against a standard model under a selection rule stated in advance.
  • Up to four networks (encoder, decoder, classifier, adversary) are trained against each other, with three weights balancing accuracy, reconstruction and fairness. The paper argues reconstruction is needed for transfer and used different weights for fair classification (accuracy 1, reconstruction 0) and for transfer (accuracy 0, reconstruction 1), so settings do not carry over. The 2018 reference code pins Python 3.6 and TensorFlow 1.9; reimplementations sit inside research benchmarks.

Resources

Research Papers

Learning Adversarially Fair and Transferable Representations
David Madras et al.•Jul 3, 2018

In this paper, we advocate for representation learning as the key to mitigating unfair prediction outcomes downstream. Motivated by a scenario where learned representations are used by third parties with unknown objectives, we propose and explore adversarial representation learning as a natural method of ensuring those parties act fairly. We connect group fairness (demographic parity, equalized odds, and equal opportunity) to different adversarial objectives. Through worst-case theoretical guarantees and experimental validation, we show that the choice of this objective is crucial to fair prediction. Furthermore, we present the first in-depth experimental demonstration of fair transfer learning and demonstrate empirically that our learned representations admit fair predictions on new tasks while maintaining utility, an essential goal of fair representation learning.

Software Packages

laftr: Learning Adversarially Fair and Transferable Representations (VectorInstitute/laftr)
Sep 26, 2025

Learning Adversarially Fair and Transferable Representations

Tags

Fairness Dimensions