Fairness Without Demographics in Repeated Loss Minimization

Tatsunori B. Hashimoto, Megha Srivastava, Hongseok Namkoong, Percy Liang

Introduction

Consider a speech recognizer that is deployed to millions of users. State-of-the art speech recognizers achieve high overall accuracy, yet it is well known that such systems have systematically high errors on minority accents (Amodei et al., 2016). We refer to this phenomenon of high overall accuracy but low minority accuracy as a representation disparity, which is the result of optimizing for average loss. This representation disparity forms our definition of unfairness, and has been observed in face recognition (Grother et al., 2011), language identification (Blodgett et al., 2016; Jurgens et al., 2017), dependency parsing (Blodgett et al., 2016), part-of-speech tagging (Hovy & Søgaard, 2015), academic recommender systems (Sapiezynski et al., 2017), and automatic video captioning (Tatman, 2017).

Moreover, a minority user suffering from a higher error rate will become discouraged and more likely to stop using the system, thus no longer providing data to the system. As a result, the minority group will shrink and might suffer even higher error rates from a retrained model in a future time step. Machine learning driven feedback loops have been observed in predictive policing (Fuster et al., 2017) and credit markets (Fuster et al., 2017), and this problem of disparity amplification is a possibility in any deployed machine learning system that is retrained on user data.

In this paper, we aim to mitigate the representation disparity problem and its amplification through time. We focus on the following setting: at each time step, each user interacts with the current model and incurs some loss, based on which she decides to keep or quit using the service. A model is trained on the resulting user data which is used at the next time step. We assume that each user comes from one of KK groups, and our goal is to minimize the worst case risk of any group across time. However, the group membership and number of groups KK are both unknown, as full demographic information is likely missing in real online services.

We first show that empirical risk minimization (ERM) does not control the worst-case risk over the disparate KK groups and show examples where ERM turns initially fair models unfair (Section 3). To remedy this issue, we propose the use of distributionally robust optimization (DRO) (Section 4). Given a lower bound on the smallest group proportion, we show that optimizing the worst-case risk over an appropriate chi-square divergence ball bounds the worst-case risk over groups. Our approach is computationally efficient, and can be applied as a small modification to a wide class machine learning models trained by stochastic gradient descent methods. We show that DRO succeeds on the examples where ERM becomes unfair, and demonstrate higher average minority user satisfaction and lower disparity amplification on a Amazon Mechanical Turk based autocomplete task.

Recently, there has been a surge of interest in fairness in machine learning (Barocas & Selbst, 2016). Our work can be seen as a direct instantiation of John Rawls’ theory on distributive justice and stability, where we view predictive accuracy as a resource to be allocated. Rawls argues that the difference principle, defined as maximizing the welfare of the worst-off group, is fair and stable over time since it ensures that minorities consent to and attempt to maintain the status quo (Rawls, 2001, p155).

In this work, we assume the task is general loss minimization, and demographic data is unavailable. This differs from the substantial body of existing research into fairness for classification problems involving protected labels such as the use of race in recidivism protection (Chouldechova, 2017). There has been extensive work (Barocas & Selbst, 2016) on guaranteeing fairness for classification over a protected label through constraints such as equalized odds (Woodworth et al., 2017; Hardt et al., 2016), disparate impact (Feldman et al., 2015) and calibration (Kleinberg et al., 2017). However, these approaches require the use of demographic labels, and are designed for classification tasks. This makes it difficult to apply such approaches to mitigate representation disparity in tasks such as speech recognition or natural language generation where full demographic information is often unavailable.

A number of authors have also studied individual notions of fairness, either through a fixed similarity function (Dwork et al., 2012) or subgroups of a set of protected labels (Kearns et al., 2018; Hébert-Johnson et al., 2017). Dwork et al. (2012) provides fairness guarantees without explicit groups, but requires a fixed distance function which is difficult to define for real-world tasks. Kearns et al. (2018); Hébert-Johnson et al. (2017) consider subgroups of a set of protected features, but defining non-trivial protected features which cover the latent demographics in our setting is difficult. Although these works generalize the demographic group structure, similarity and subgroup structure are both ill-defined for many real-world tasks.

In the online setting, works on fairness in bandit learning (Joseph et al., 2016; Jabbari et al., 2017) propose algorithms compatible with Rawls’ principle on equality of opportunity—an action is preferred over another only if the true quality of the action is better. Our work differs in considering Rawlsian fairness for distributive justice (Rawls, 2009). Simultaneous with our work, Liu et al. (2018) analyzed fairness over time in the context of constraint based fairness criteria, and show that enforcing static fairness constraints do not ensure fairness over time. In this paper, we consider latent demographic groups and study a loss-based approach to fairness and stability.

Problem setup

We begin by outlining the two parts of our motivation: representation disparity and disparity amplification.

Representation disparity refers to the phenomenon of low R(θ)\mathcal{R}(\theta) and high Rmax(θ)\mathcal{R}_{\text{max}}(\theta) due to a group with small αk\alpha_{k}.

Disparity amplification: To understand the amplification of representation disparity over time, we will make several assumptions on the behavior of users in response to observed losses. These assumptions are primarily for clarity of exposition—we will indicate whenever the assumptions can be relaxed leave generalizations to the supplement. Roughly speaking, minimizing the worst-case risk Rmax(θ)\mathcal{R}_{\text{max}}(\theta) should mitigate disparity amplification as long as lower losses lead to higher user retention. We now give assumptions that make this intuition precise.

In the sequential setting, loss minimization proceeds over t=1,2,…Tt=1,2,\ldots T rounds, where the group proportion αk(t)\alpha_{k}^{(t)} depends on tt and varies according to past losses. At each round λk(t+1)\lambda_{k}^{(t+1)} is the expected number of users from group kk, which is determined by ν(Rk(θ))\nu(\mathcal{R}_{k}(\theta)), the fraction of users retained, and bkb_{k}, the number of new users (see Definition 1). Here, ν\nu is a differentiable, strictly decreasing retention function which maps a risk level R\mathcal{R} to the fraction of users who continue to use the system. Modeling user retention as a decreasing function of the risk implies that each user makes an independent decision of whether to interact with the system at time t+1t+1 based on their expected loss at time tt. For example, selecting ν(x)=1−x\nu(x)=1-x and Rk\mathcal{R}_{k} equal to the expected zero-one loss implies that users leave proportional to the misclassification rates of their queries.

At each round we learn parameters θ(t+1)\theta^{(t+1)} based on n(t+1)∼Pois(∑kλk(t+1))n^{(t+1)}\sim\text{Pois}(\sum_{k}\lambda_{k}^{(t+1)}) users (data points). While we define the sample size as a Poisson process for concreteness, our main results hold for any distribution fulfilling the strong law of large numbers, as we perform all stability analyses in the population limit.

Given a sequence θ(t)\theta^{(t)}, for each t=1…Tt=1\ldots T, the expected number of users λ\lambda and samples Zi(t)Z_{i}^{(t)} starting at λk(0)=bk\lambda_{k}^{(0)}=b_{k} is governed by:

Our goal is to control over all groups k=1,…,Kk=1,\ldots,K and time periods t=1,…,Tt=1,\ldots,T the group-wise risk Rk(θ(t))\mathcal{R}_{k}(\theta^{(t)}),

Without knowledge of group membership labels, population proportions αk(t)\alpha_{k}^{(t)}, new user rate bkb_{k}, and retention rate ν\nu, minimizing RmaxT\mathcal{R}_{\text{max}}^{T} gives rise to two major challenges. First, without group membership labels there is no way to directly measure the worst-case risk RmaxT\mathcal{R}_{\text{max}}^{T}, let alone minimize it. Second, we must ensure that the group proportions αk(t)\alpha_{k}^{(t)} are stable, since if αk(t)→0\alpha_{k}^{(t)}\to 0 as t→∞t\to\infty for some group k∈[K]k\in[K], then no algorithm can control RmaxT\mathcal{R}_{\text{max}}^{T} when a group has near zero probability of appearing in our samples.

We begin by illustrating how models that are initially fair with low representation disparity may become unfair over time if we use ERM (Section 3). We then propose a solution based on distributionally robust optimization (Section 4), and study examples where this approach mitigates representation disparity in our experimental section (Section 5).

Disparity amplification

The standard approach to fitting a sequence of models θ(t)\theta^{(t)} is to minimize an empirical approximation to the population risk at each time period. In this section, we show that even minimizing the population risk fails to control minority risk over time, since expected loss (average case) leads to disparity amplification. The decrease in user retention for the minority group is exacerbated over time since once a group shrinks sufficiently, it receives higher losses relative to others, leading to even fewer samples from the group.

2 Conditions for disparity amplification

The example above demonstrated that disparity amplification can occur easily even in a situation where the two groups have identical population size and initial risk. In general if we view the expected user counts λ(t)\lambda^{(t)} as a dynamical system, the long-term fairness properties for any fairness criteria are controlled by two factors - whether λ\lambda has a fair fixed point (defined as a population fraction where risk minimization maintains the same population fraction over time) and whether this fixed point is stable.

Fixed points of risk minimization are determined by a combination of user retention function ν\nu and the models θ(t)\theta^{(t)}, and without knowledge of ν\nu it is hard to ensure that a model has a fair fixed point. Even if a fixed point is fair, such as when the population fraction and risk received by each group is equal, and we start at this fair fixed point, minimizing the empirical loss may deviate from this fair fixed point over time due to finite sample fluctuations or noise in the model estimation procedure.

To show this result, we study the dynamical system Φ\Phi, which is defined by dynamics in Definition 1 with θ\theta derived from minimizing the population, rather than empirical risk.

Let Φ\Phi be the update for the expected population size

The arrival intensity λ∗\lambda^{*} is called a fixed point if λ∗=Φ(λ∗)\lambda^{*}=\Phi(\lambda^{*}). This fixed point is stable whenever the maximum modulus of the eigenvalues of the Jacobian of Φ\Phi is less than one and unstable whenever it is greater than one (Luo, 2012, Theorem 2.1).

Proposition 1 gives a precise statement of this phenomenon. We prove the result in Section A.1, and further show a generalization to general dynamics Φ(λk)=h(λk,Rk)\Phi(\lambda_{k})=h(\lambda_{k},\mathcal{R}_{k}) where hh is differentiable and monotone in the second argument. We denote by ρmax(A)\rho_{\rm max}(A) the maximum modulus of the eigenvalues of AA.

Define HR(α∗)H_{\mathcal{R}}(\alpha^{*}) as the positive definite Hessian of the expected risk at θ∗,λ∗\theta^{*},\lambda^{*} and define ∇L\nabla L as the per-group parameter gradients at θ∗\theta^{*},

The arrival intensity λ∗\lambda^{*} is unstable whenever

We see that the major quantities which control risk are the retention rate ν\nu and its derivative, as well as a K×KK\times K square matrix ∇LHR(α∗)−1∇L⊤\nabla LH_{\mathcal{R}}(\alpha^{*})^{-1}\nabla L^{\top} which roughly encodes the changes in one group’s risk as a function of another.

We can specialize the stability condition to obtain an intuitive and negative result for the stability of risk minimization (average case). Even if we start at a fair fixed point with λ1∗=⋯=λk∗\lambda^{*}_{1}=\cdots=\lambda^{*}_{k} and R1=⋯=Rk\mathcal{R}_{1}=\cdots=\mathcal{R}_{k}, if decreasing the risk for one group increases the risk for others sufficiently, the fixed point is unstable and the model will eventually converge to a different, possibly unfair, fixed point.

Let λ1∗=⋯=λk∗\lambda^{*}_{1}=\cdots=\lambda^{*}_{k} be a fixed point with R1=⋯=Rk\mathcal{R}_{1}=\cdots=\mathcal{R}_{k}, then for any strongly convex loss,

is a sufficient condition for instability.

See Section A.2 for proof and generalizations.

The bound (3) has a straightforward interpretation. The left hand side is the stability of the model, where maximal eigenvalue of the matrix ∇LHR(α∗)−1∇L⊤\nabla LH_{\mathcal{R}}(\alpha^{*})^{-1}\nabla L^{\top} represents the maximum excess risk that can be incurred due to a small perturbation in the mixture weights α\alpha. The right hand side represents the underlying stability of the dynamics and measures the sensitivity of λ\lambda with respect to risk.

Mean and median estimation: Consider a simple mean estimation example where each user belongs to one of two groups, −1-1 or 11 and incurs loss (θ−Z)2(\theta-Z)^{2}. θ=0\theta=0 is clearly a fair fixed point, since it equalizes losses to both groups, with Hrisk(α∗)=1/2H_{risk}(\alpha^{*})=1/2 and ∇L=\nabla L= making \rho_{\rm max}\bigg{(}\nabla LH_{\mathcal{R}}(\alpha^{*})^{-1}\nabla L^{\top}\bigg{)}=4. If we select ν(x)=exp⁡(−x)\nu(x)=\exp(-x), the right hand side becomes 2(1−e−1)e≈3.42(1-e^{-1})e\approx 3.4, and thus any perturbation will eventually result in λ1≠λ2\lambda_{1}\neq\lambda_{2}. In this case the only other fixed points are the unfair solutions of returning the mean of either one of the groups.

The situation is even worse for models which are not strongly convex, such as median estimation. Replacing the squared loss above with the absolute value results in a loss which has a non-unique minimizer at when λ1=λ2\lambda_{1}=\lambda_{2} but immediately becomes −1-1 whenever λ1>λ2\lambda_{1}>\lambda_{2}. In this case, no conditions on the retention function ν\nu can induce stability. This fundamental degeneracy motivates us to search for loss minimization schemes with better stability properties than ERM (average case).

Distributionally robust optimization (DRO)

The fundamental difficulty in controlling the worst-case group risk over a single time-step Rmax(θ(t))\mathcal{R}_{\text{max}}(\theta^{(t)}) comes from not observing the group memberships from which the data was sampled. For many machine learning systems such as speech recognition or machine translation, such situations are common since we either do not ask for sensitive demographic information, or it is unclear a priori which demographics should be protected. To achieve reasonable performance across different groups, we postulate a formulation that protects against all directions around the data generating distribution. We build on the distributionally robust formulation of Duchi et al. (2016) which will allow us to control the worst-case group risk Rmax(θ(t))\mathcal{R}_{\text{max}}(\theta^{(t)}).

To formally describe our approach, let Dχ2(P∣ ⁣∣Q)D_{{\chi^{2}}}\left({P}|\!|{Q}\right) be the χ2\chi^{2}-divergence between probability distributions PP and QQ given by Dχ2(P∣ ⁣∣Q):=∫(dPdQ−1)2dQD_{{\chi^{2}}}\left({P}|\!|{Q}\right):=\int\left(\frac{dP}{dQ}-1\right)^{2}dQ. If PP is not absolutely continuous with respect to QQ, we define Dχ2(P∣ ⁣∣Q):=∞D_{{\chi^{2}}}\left({P}|\!|{Q}\right):=\infty.

Let B(P,r)\mathcal{B}(P,r) be the chi-squared ball around a probability distribution PP of radius rr so that B(P,r):={Q≪P:Dχ2(Q∣ ⁣∣P)≤r}\mathcal{B}(P,r):=\{Q\ll P:D_{{\chi^{2}}}\left({Q}|\!|{P}\right)\leq r\}. We consider the worst-case loss over all rr-perturbations around PP,

For P:=∑k∈[K]αkPkP:=\sum_{k\in[K]}\alpha_{k}P_{k}, we have Rk(θ)≤Rdro(θ;rk)\mathcal{R}_{k}(\theta)\leq\mathcal{R}_{\rm dro}(\theta;r_{k}) for all θ∈Θ\theta\in\Theta where rk:=(1/αk−1)2r_{k}:=\left(1/\alpha_{k}-1\right)^{2} is the robustness radius.

As a consequence of Proposition 2, if we have a lower bound on the group proportions αmin≤min⁡k∈[K]αk\alpha_{\text{min}}\leq\min_{k\in[K]}\alpha_{k}, then we can control the worst-case group risk Rmax(θ)\mathcal{R}_{\text{max}}(\theta) by minimizing the upper bound θ↦Rdro(θ;rmax)\theta\mapsto\mathcal{R}_{\rm dro}(\theta;r_{\rm max}) where rmax:=(1/αmin−1)2r_{\rm max}:=(1/\alpha_{\text{min}}-1)^{2}.

Similar formulations for robustness around the empirical distribution with radius shrinking as r/nr/n had been considered in (Ben-Tal et al., 2013; Lam & Zhou, 2015; Duchi & Namkoong, 2016). While there are many possible robustness balls B\mathcal{B} which could provide upper bounds on group risk, we opt to use the chi-squared ball since it is straightforward to optimize (Ben-Tal et al., 2013; Namkoong & Duchi, 2016, 2017) and we found it empirically outperformed other ff-divergence balls.

2 Interpreting the dual

The dual of the maximization problem (4) provides additional intuition on the behavior of the robust risk.

where C=(2(1/αmin−1)2+1)1/2C=\left(2(1/\alpha_{\text{min}}-1)^{2}+1\right)^{1/2}.

Denoting by η⋆\eta^{\star} the optimal dual variable (5), we see from the proposition that all examples suffering less than η⋆\eta^{\star}-levels of loss are completely ignored, and large losses above η⋆\eta^{\star} are upweighted due to the squared term.

However, unlike standard parameter regularization techniques, which encourage θ\theta to be close to some point, our objective biases the model to have fewer high loss examples which matches our goal of mitigating representation disparity.

DRO returns θDRO∗\theta^{*}_{\text{DRO}} which is close to θfair\theta_{\text{fair}}. Analyzing the risk, we find that the single-step worst-case group risk Rmax(θ)\mathcal{R}_{\text{max}}(\theta) in (1) is an upper bound on ERM, and DRO forms a tight upper bound this quantity (Figure 2b). We can also understand the behavior of DRO through the worst-case distribution QQ in Equation 4. Figure 2a shows the worst-case distribution QQ at the minimizer θDRO∗\theta^{*}_{\text{DRO}} which completely removes points within distance η∗\eta^{*}. Additionally, points far from θDRO∗\theta^{*}_{\text{DRO}} are upweighted, resulting in a large contribution to the loss from the minority group.

We expect the bound to be tight when all individuals within a group receive the same loss. In this case, thresholding by η∗\eta^{*} corresponds to selecting the single highest risk group which is equivalent to directly minimizing Rmax(θ)\mathcal{R}_{\text{max}}(\theta) (1).

On the other hand, the worst case for our approach is if αmin⁡\alpha_{\min} is small, and a group with low expected loss has a high loss tail with population size αmin⁡\alpha_{\min}. In this case DRO is a loose upper bound and optimizes the losses of the group with already low expected loss.

This is closely related to recent observations that the DRO bound can be loose for classification losses such as the zero-one loss due to the worst-case distribution consisting purely of misclassified examples (Hu et al., 2018). Even in this case, the estimated loss is still a valid upper bound on the worst case group risk, and as Figure 2 shows, there are examples where the DRO estimate is nearly tight.

3 Optimization

We now show how to minimize θ↦Rdro(θ;rmax)\theta\mapsto\mathcal{R}_{\rm dro}(\theta;r_{\rm max}) efficiently for a large class of problems. For models such as deep neural networks that rely on stochastic gradient descent, the dual objective F(θ;η)F(\theta;\eta) in (5) can be used directly since it only involves an expectation over the data generating distribution PP.

Formally, the following procedure optimizes (4): for a given value of η\eta, compute the approximate minimizer θ^η\widehat{\theta}_{\eta}

4 Stability of minority loss minimization

We have thus far demonstrated that for a single time step, the worst-case risk over all groups Rmax(θ)=max⁡kRk(θ)\mathcal{R}_{\text{max}}(\theta)=\max_{k}\mathcal{R}_{k}(\theta) can be controlled by the distributionally robust risk Rdro(θ;rmax)\mathcal{R}_{\rm dro}(\theta;r_{\rm max}) where rmax:=(1/αmin−1)2r_{\rm max}:=(1/\alpha_{\text{min}}-1)^{2} and αmin\alpha_{\text{min}} is the minority group proportion. Now, we study how the individual group risk Rk(θ)\mathcal{R}_{k}(\theta) affects user retention and hence future risk. By virtue of providing an upper bound to Rmax(θ)\mathcal{R}_{\text{max}}(\theta), optimizing Rdro(θ;rmax)\mathcal{R}_{\rm dro}(\theta;r_{\rm max}) at each time step can thus control the future group risk Rmax(θ)\mathcal{R}_{\text{max}}(\theta).

We show that if the initial group proportions satisfy αk(0)≥αmin\alpha_{k}^{(0)}\geq\alpha_{\text{min}} and the worst-case risk Rmax(θ(t))\mathcal{R}_{\text{max}}(\theta^{(t)}) is sufficiently small at each time tt, then we can ensure αk(t+1)>αmin\alpha_{k}^{(t+1)}>\alpha_{\text{min}}. Thus, to control RmaxT\mathcal{R}_{\text{max}}^{T}, the worst-case group risk over all time steps, it suffices to control Rdro(θ(t);rmax)\mathcal{R}_{\rm dro}(\theta^{(t)};r_{\rm max}) using the procedure in Section 4.3.

Assume the retention model in Definition 1. Let αk(t)>αmin\alpha_{k}^{(t)}>\alpha_{\text{min}}, bk∑kbk>αmin\frac{b_{k}}{\sum_{k}b_{k}}>\alpha_{\text{min}}, λ(t):=∑kλk(t)≤∑kbk1−νmax⁡\lambda^{(t)}:=\sum_{k}\lambda_{k}^{(t)}\leq\frac{\sum_{k}b_{k}}{1-\nu_{\max}}, and ν(Rk(θ(t)))<νmax⁡\nu(\mathcal{R}_{k}(\theta^{(t)}))<\nu_{\max}. Then, whenever we have

We conclude that as long as we can guarantee

we can control RmaxT(θ(0),…,θ(T))\mathcal{R}_{\text{max}}^{T}(\theta^{(0)},\ldots,\theta^{(T)}), the unknown worst-case group risk over all time steps by optimizing Rdro(θ(t);rmax)\mathcal{R}_{\rm dro}(\theta^{(t)};r_{\rm max}) at each step tt. While the condition (7) is hard to verify in practice, we observe empirically in Section 5 that optimizing the distributionally robust risk Rdro(θ(t);rmax)\mathcal{R}_{\rm dro}(\theta^{(t)};r_{\rm max}) at time step tt indeed significantly reduces disparity amplification in comparison to using ERM.

Proposition 4 gives stronger fairness guarantees than the stability conditions for ERM in Proposition 1. In ERM the best one can do is to add strong convexity to the model to stabilize to a possibly unfair fixed point. In contrast, Proposition 4 gives conditions for controlling Rmax\mathcal{R}_{\text{max}} over time without assuming that there exists a fair fixed point.

Stability of median estimation: Returning to our running example of geometric median estimation, we can show that under the same dynamics, ERM is highly unstable while DRO is stable. Consider a three Gaussian mixture on the corners of the simplex, with L2L_{2} loss, retention function ν(r)=exp⁡(−r)\nu(r)=\exp(-r), and b1=b2=50b_{1}=b_{2}=50, n(t)=1000n^{(t)}=1000. By construction, (1/3,1/3,1/3)(1/3,1/3,1/3) is the fair parameter estimate.

Figure 3 shows that ERM is highly unstable, with the only stable fixed points being the corners, where a single group dominates all others. The fair parameter estimate is an unstable fixed point for ERM, and any perturbation eventually results in a completely unfair parameter estimate. On the other hand, DRO has the reverse behavior, with the fair parameter estimate being the unique stable fixed point.

Experiments

We demonstrate the effectiveness of DRO on our motivating example (Figure 1) and human evaluation of a text autocomplete system on Amazon Mechanical Turk. In both cases, DRO controls the worst-case risk RmaxT\mathcal{R}_{\text{max}}^{T} over time steps and improves minority retention.

Recall the motivating example in Figure 1 which shows that logistic regression applied to a two-class classification problem is unstable and becomes pathologically unfair.

The data is constructed by drawing from a mixture of two Gaussians (groups) centered at (−1.5,0)(-1.5,0) and (0,1.5)(0,1.5). The two groups are labeled according to the linear decision boundaries (−3/2,32−1/3)(-3/2,\sqrt{3^{2}-1}/3) and (3/2,32−1/3)(3/2,\sqrt{3^{2}-1}/3) respectively such that classifying with x2>0x_{2}>0 is accurate, but the optimal linear classifier on one group achieves 50% accuracy on the other.

At each round we fit a logistic regression classifier using ERM or DRO and gradient descent, constraining the norm of the weight vector to 1. Our dynamics follow Definition 1 with ν(x)=1−x\nu(x)=1-x, R\mathcal{R} as the zero-one loss, and bk=1000b_{k}=1000. The DRO model is trained using the dual objective with logistic loss, and η=0.95\eta=0.95, which was the optimal dual solution to αmin⁡=0.2\alpha_{\min}=0.2. The results do not qualitatively change for choices of αmin⁡<0.5\alpha_{\min}<0.5, and we show that we obtain control even for group sizes substantially smaller than 0.2 (Figure 6).

Figure 5 shows that ERM is unstable and the minority group rapidly loses accuracy beyond 300300 rounds on most runs. In contrast, DRO is stable, and maintains an accuracy of 0.80.8.

This stability is due to the fact that the regularized loss for DRO prevents small losses in the minority fraction from amplifying, as we discuss in Proposition 4. Even when the minority fraction falls as low as 1%1\%, the DRO loss ensures that the accuracy of this minority fraction remains at 75%75\% accuracy (Figure 6).

2 Autocomplete task

We now present a real-world, human evaluation of user retention and satisfaction on a text autocomplete task. The task consists of the prediction of next words in a corpus of tweets built from two estimated demographic groups, African Americans and White Americans (Blodgett et al., 2016). There are several distinguishing linguistic patterns between tweets from these groups, whose language dialects we henceforth refer to as African-American English (AAE) and Standard-American English (SAE), respectively, following the nomenclature in Blodgett et al. (2016). Our overall experimental design is to measure the retention rate ν\nu and risk R\mathcal{R} for various choices of demographic proportions (αAAE,αSAE)(\alpha_{\text{AAE}},\alpha_{\text{SAE}}) and simulate the implied dynamics, since running a fully online experiment would be prohibitively expensive.

For both ERM and DRO, we train a set of five maximum likelihood bigram language models on a corpus with 366,361 tweets total and a f∈{0.1,0.4,0.5,0.6,0.9}f\in\{0.1,0.4,0.5,0.6,0.9\} fraction of the tweets labeled as AAE. This results in 10 possible autocomplete systems a given Mechanical Turk user can be assigned to during a task.

To evaluate the retention and loss for AAE and SAE separately, a turk user is assigned 10 tweets from either the held out AAE tweets or SAE tweets, which they must replicate using a web-based keyboard augmented by the autocomplete system. This assignment of a turk user to a demographic group simulates the situation where a user from a particular demographic group attempts to use the autocomplete system to write a tweet. Details of the autocomplete task are included in the supplement.

After completing the task, users were asked to fill out a survey which included a rank from 1 to 5 on their satisfaction with the task, and a yes/no question asking whether they would continue to use such a system. We assign 50 users to each of the two held out set types and each of the 10 autocomplete models, resulting in 1,000 users’ feedback across autocomplete models and assigned demographics.

The response to whether a user would continue to use the autocomplete system provides samples ν(RK(α))\nu(\mathcal{R}_{K}(\alpha)) with n=366361n=366361 and each of possible demographic proportions α\alpha. The user satisfaction survey provides a surrogate for RK(α)\mathcal{R}_{K}(\alpha) at these same points. We interpolate ν\nu and RK\mathcal{R}_{K} to α∈\alpha\in via isotone regression which then allows us to simulate the user dynamics and satisfaction over time using Definition 1. We estimate variability in these estimates via bootstrap replicates on the survey responses.

Our results in Figure 4 show an improvement in both minority satisfaction and retention rate due to DRO: we improve the median user satisfaction from 3.7 to 4.0 and retention from 0.7 to 0.85, while only slightly decreasing the SAE satisfaction and retention. Implied user counts follow the same trend with larger differences between groups due to compounding.

Counterintuitively, the minority group has higher satisfaction and retention under DRO. Analysis of long-form comments from Turkers suggest this is likely due to users valuing the model’s ability to complete slang more highly than completion of common words and indicates a slight mismatch between our training loss and human satisfaction with an autocomplete system.

Discussion

In this work we argued for a view of loss minimization as a distributive justice problem and showed that ERM often results in disparity amplification and unfairness. We demonstrate that DRO provides a upper bound on the risk incurred by minority groups and performs well in practice. Our proposed algorithm is straightforward to implement, and induces distributional robustness, which can be viewed as a benefit in and of itself.

Our arguments against ERM and in favor of minority risk minimization mirror Rawls’ arguments against utilitarianism, and thus inherit the critiques of Rawlsian distributive justice. Examples of such critiques are the focus on an abstract worst-off group rather than demographic groups or individuals (Altham, 1973), extreme risk-aversion (Mueller et al., 1974), and utilitarianism with diminishing returns as an alternative (Harsanyi, 1975). In this work, we do not address the debate on the correctness of Rawlsian justice (Rawls, 2001), and leave finding a suitable philosophical framework for loss minimization to future work.

There are two large open questions from our work. First, as fairness is fundamentally a causal question, observational approaches such as DRO can only hope to control limited aspects of fairness. The generality with which our algorithm can be applied also limits its ability to enforce fairness as a constraint, and thus our approach here is unsuitable for high-stakes fairness applications such as classifiers for loans, criminality, or admissions. In such problems the implied minorities from DRO may differ from well-specified demographic groups who are known to suffer from historical and societal biases. This gap arises due to looseness in the DRO bound (Hu et al., 2018), and could be mitigated using smoothness assumptions (Dwork et al., 2012).

Second, distributional robustness proposed here runs counter to classical robust estimation for rejecting outlier samples, as high loss groups created by an adversary can easily resemble a minority group. Adversarial or high-noise settings loosen the DRO upper bound substantially, and it is an open question whether it is possible to design algorithms which are both fair to unknown latent groups and robust.

Reproducibility: Code to generate results available on the CodaLab platform at https://bit.ly/2sFkDpE.

Acknowledgements: This work was funded by an Open Philanthropy Project Award.

References

Appendix A Appendix

We prove the following more general result.

Define HR(α∗)H_{\mathcal{R}}(\alpha^{*}) as the positive definite Hessian of the expected risk with αk∗∝λk∗\alpha_{k}^{*}\propto\lambda^{*}_{k}.

Further, let ∇L\nabla L define the per-group parameter gradients at θ∗\theta^{*},

λ∗\lambda^{*} is stable whenever the absolute value of the maximum eigenvalue ρmax⁡\rho_{\max} obeys

Proof A necessary and sufficient condition for stability of a discrete time dynamical system is that the Jacobian of the forward map Φ\Phi has eigenvalues with absolute value strictly less than 1.

Now we must compute the Jacobian of the risk with respect to the population fraction. To do this, we apply the chain rule and separately analyze three Jacobians:R\mathcal{R} with respect to θ\theta, θ\theta with respect to α∗\alpha^{*}, and α∗\alpha^{*} with respect to λ∗\lambda^{*}

Where HR(α∗)−1H_{\mathcal{R}}(\alpha^{*})^{-1} is the Hessian of the population risk and ∇L\nabla L is

The Jacobian of the risks with respect to change in θ\theta is

The Jacobian of the population fraction with respect to nn is

By the chain rule, we obtain the overall claim

A.2 Proof of Corollary 2

Setting ν(R(θ(λ∗)))=ν(R1)\nu(\mathcal{R}(\theta(\lambda^{*})))=\nu(\mathcal{R}_{1}) and λk∗=λ1∗\lambda^{*}_{k}=\lambda^{*}_{1} we have,

By first order optimality conditions, and the fact that λ1∗…=λk∗\lambda^{*}_{1}\ldots=\lambda^{*}_{k}, ∇L⊤1=0\nabla L^{\top}\mathbf{1}=0.

Thus, collecting terms and noting ν′(x)<0\nu^{\prime}(x)<0 by monotonicity of ν\nu, we have

A.3 Generalization of Proposition 1 and Corollary 2

Let Φ\Phi be the update for the expected population size

Then as long as hh is differentiable in both arguments, we obtain an essentially identical result to before.

Define HR(α∗)H_{\mathcal{R}}(\alpha^{*}) as the positive definite Hessian of the expected risk with αk∗∝λk∗\alpha_{k}^{*}\propto\lambda^{*}_{k}.

Further, let ∇L\nabla L define the per-group parameter gradients at θ∗\theta^{*},

Proof A necessary and sufficient condition for stability of a discrete time dynamical system is that the Jacobian of the forward map Φ\Phi has eigenvalues with absolute value strictly less than 1.

Computing the Jacobian via total derivatives we have

The Jacobian term remains identical to before, which completes the proof. ∎

The Corollary follows from this derivation:

Let λ1∗=…λk∗\lambda^{*}_{1}=\ldots\lambda^{*}_{k} be a fixed point with R1=…Rk\mathcal{R}_{1}=\ldots\mathcal{R}_{k}, and define \frac{\partial h}{\partial\lambda}\big{|}_{\lambda=\lambda^{*}}=\frac{\partial}{\partial\lambda}h(\lambda^{*}_{1},\mathcal{R}_{1}) and \frac{\partial h}{\partial\mathcal{R}}\big{|}_{\lambda=\lambda^{*}}=\frac{\partial}{\partial\mathcal{R}}h(\lambda^{*}_{1},\mathcal{R}_{1}). For any strongly convex loss,

Proof Recall that the instability criteria is

Let \frac{\partial h}{\partial\lambda}\big{|}_{\lambda=\lambda^{*}}=\frac{\partial}{\partial\lambda}h(\lambda^{*}_{1},\mathcal{R}_{1}(\theta(\lambda^{*}))) and \frac{\partial h}{\partial\mathcal{R}}\big{|}_{\lambda=\lambda^{*}}=\frac{\partial}{\partial\mathcal{R}}h(\lambda^{*}_{1},\mathcal{R}_{1}(\theta(\lambda^{*}))). Then following the same derivation as earlier and using the monotonicity of hh in the second argument gives

This is essentially in the same spirit as our earlier corollary, but requires further assumptions on hh in order to interpret. Generally we expect ∂h∂R\frac{\partial h}{\partial R} to be on the order of λ\lambda as long as risk affects users independently, and ∂h∂λ\frac{\partial h}{\partial\lambda} is upper bounded by the maximum implied retention rate.

A.4 Proof of Proposition 2

Since PkP_{k} is a mixture component of PP (P=αkPk+⋯P=\alpha_{k}P_{k}+\cdots),

We just showed that Pk∈B(P,rk)P_{k}\in\mathcal{B}(P,r_{k}). Since the sup is over all Q∈B(P,rk)Q\in\mathcal{B}(P,r_{k}), the upper bound follows.

A.5 Proof of Proposition 4

By the assumption that ν(Rk(θ(t)))<νmax⁡\nu(\mathcal{R}_{k}(\theta^{(t)}))<\nu_{\max},

Using bk∑kbk≥αmin\frac{b_{k}}{\sum_{k}b_{k}}\geq\alpha_{\text{min}} and λ(t)≤∑bk1−νmax⁡\lambda^{(t)}\leq\frac{\sum b_{k}}{1-\nu_{\max}} the above simplifies to

Thus, a sufficient condition for our proposition is

Appendix B Amazon Mecahnical Turk task description

The Amazon Mechanical Turk experiment modeling user retention in an autocomplete system is detailed below. The experiment design consists of a total of 1000 HITs (”Human Intelligence Tasks” on Mechanical Turk) consisting of 2 user replicates ×\times 5 values of α\alpha ×\times 2 models (DRO/ERM) ×\times 25 sets of 10 tweets from the test set ×\times two test sets (AAE/SAE).

For each HIT the task, users are provided the description given in Figure 7 . Users are then taken to a separate autocomplete website, where they are asked to replicate 10 tweets using a software keyboard shown in Figure 8. In this interface, users must use the mouse and the software keyboard to type the target sentence, while also being given an autocomplete system for next word prediction based on the two models. The autocomplete system appears through a dropdown as users begin typing. After completion to the task, users are prompted to fill out a survey in Figures 9,10. The first four questions are quality control questions designed to identify Turkers who were low effort (empty entries in Q1/Q3) or inconsistent (Q2 inconsistent with Q4). Moreover, low-quality HITS could easily be identified due to a user’s refusal to select either yes or no to Q5. We used this as our metric for filtering which users would be considered in the analysis. Q6 is our overall satisfaction metric shown in the main paper.