Agnostic Federated Learning

Mehryar Mohri, Gary Sivek, Ananda Theertha Suresh

Standard Federated Learning (FL) often optimizes for the "average" client, which can lead to models that perform poorly for specific subgroups. To address this, researchers have introduced Agnostic Federated Learning (AFL), a framework that optimizes for the worst-case mixture of client distributions. This approach ensures robust performance across all participants and naturally promotes a formal notion of fairness.

The Pitfalls of "Average" Optimization

In traditional Federated Learning, a central model is trained on data distributed across many clients, such as mobile phones or edge sensors. The standard goal is to minimize the weighted average loss across all clients.

However, this average-case optimization is risky. If the distribution of users at test time differs from the training mixture—for example, if a model is trained mostly on data from high-end smartphone users but is later deployed to users with budget devices—the model may be biased and perform poorly for the minority group. This mismatch between training and target distributions leads to significant issues of fairness and robustness. AFL seeks to answer a critical question: How can we train a model that performs well regardless of which specific mixture of clients it encounters later?

The Agnostic Approach: Minimax Optimization

The core innovation of AFL is a shift from average-case optimization to minimax optimization.

Agnostic Objective Mixture
  • The Agnostic Objective: Instead of minimizing the loss for a fixed uniform distribution, AFL minimizes the loss for the worst-case distribution formed by any mixture of the client distributions (as illustrated by the central target distribution $\mathcal{D}_\lambda$ drawn from various domains).
  • Good-Intent Fairness: AFL is closely linked to the "maxmin" principle of fairness. By minimizing the maximum loss, the algorithm prevents the model from ignoring a specific group just to improve the global average.
  • STOCHASTIC-AFL Algorithm: The authors propose a stochastic optimization algorithm designed for this minimax problem. It functions like a two-player game: "Nature" chooses a mixture of clients to maximize the loss (finding the "hardest" group), while the "Learner" updates the model weights to minimize that loss.

The paper also provides data-dependent Rademacher complexity bounds, introducing a "skewness" parameter that quantifies how much the target distribution deviates from the available training data to provide statistical generalization guarantees.

Experimental Validation and Key Results

The authors evaluated AFL across three distinct types of tasks, consistently showing that AFL provides a more balanced performance than standard FL:

  1. Adult Dataset (UCI): A census dataset used to predict income, split into "doctorate" and "non-doctorate" domains. AFL achieved ~71.5% accuracy on the worst-case distribution, whereas standard FL dropped to ~69.6%.
  2. Fashion MNIST: Treating different clothing categories as distinct domains, AFL improved accuracy for the notoriously difficult "shirt" category by ~3.3% compared to standard FL, without significantly degrading performance on easier categories.
  3. Language Modeling: Combining the Cornell Movie Dialogues (conversational) and the Penn Treebank (formal documents) to simulate a mobile keyboard app used in different contexts.
Language Modeling Results

As shown in the language modeling results above, on the harder "document" domain, AFL ($\mathcal{L}_{\mathcal{D}_\Lambda}$) successfully reduced perplexity (a measure of uncertainty where lower is better) from 96.98 (standard uniform baseline $\mathcal{L}_{\widehat{u}}$) down to 86.33.

Interestingly, the agnostic model often generalized better overall, suggesting that forcing a model to be robust to different domains helps it learn more fundamental, less biased features.

Key Insights and Future Directions

One of the most elegant takeaways from this research is the realization that robustness is fairness. Being "agnostic" to the target distribution is mathematically equivalent to a specific definition of fairness; protecting against the worst-case distribution inherently protects the most vulnerable or underrepresented groups. Furthermore, while designed for FL, this framework is highly relevant for domain adaptation and cloud computing.

Limitations and Future Work: * Computational Complexity: Minimax optimization is generally more computationally expensive and harder to stabilize than standard gradient descent. * Defining Domains: The framework requires pre-defining "domains" or "protected groups," which is non-trivial in massive FL systems with millions of users. * Theoretical Assumptions: Much of the theoretical proof relies on convex loss functions. While empirical success was shown with non-convex models (like LSTMs), formal guarantees for deep learning remain an open area. * Communication Efficiency: The paper focuses on the learning objective rather than communication bottlenecks (bandwidth, latency), which are primary concerns in practical FL deployments.

Summary updated

BibTeX
@inproceedings{mohri2019agnostic,
  author = {Mehryar Mohri and Gary Sivek and Ananda Theertha Suresh},
  title = {{Agnostic Federated Learning}},
  booktitle = {International Conference on Machine Learning},
  year = {2019},
  url = {https://openreview.net/forum?id=rkVnPoZObr},
}
Figure