Beyond the Half Approximation: Fair and Efficient Online Class Matching

Sander Borst, Max SpringerNeurIPS 2026

TL;DR

When dispatching ride-share drivers or serving online ads in real time, purely maximizing total system efficiency often leaves minority or regional groups behind. Until now, every algorithm that guaranteed fair treatment across groups hit a frustrating mathematical wall, sacrificing efficiency down to at most $50\%$ of the theoretical optimum. This paper breaks through that barrier with a surprisingly simple "fairness first, efficiency second" dial, mapping out the true trade-off between fairness and efficiency in online matching.

What Problem Does This Paper Address?

Imagine running a ride-sharing platform. You know your pool of drivers (agents) in advance, and ride requests (items) pop up one by one. The catch: you must assign each ride immediately and irrevocably without knowing what requests come next. This is online bipartite matching.

If your only goal is maximizing total matches—known as Utilitarian Social Welfare (USW)—classic algorithms from the 1990s (like RANKING and water-filling) guarantee you will achieve at least $1 - \frac{1}{e} \approx 63.2\%$ of the omniscient offline optimum.

However, drivers often belong to distinct classes, like geographic neighborhoods or demographic groups. Purely maximizing total rides might starve certain groups. To prevent this, researchers recently formalized Class Envy-Freeness (CEF): an algorithm is $\alpha$-CEF if every group gets at least an $\alpha$ fraction of the value it could have extracted from any other group's assigned bundle of items.

Here lies the tension: any sensible algorithm that doesn't needlessly throw away matches ("non-wasteful") automatically gets $50\%$ ($0.5$) USW. Yet every known algorithm that achieved any constant fairness ($\alpha$-CEF) got completely stuck at that $50\%$ efficiency floor. Whether fairness inherently forced us to forfeit the gap between $50\%$ and $63.2\%$ remained a central open question.

Methods

The authors resolve this by introducing a two-phase design controlled by a single, interpretable threshold parameter $\gamma \in [0, 1]$—essentially a dial between pure efficiency ($\gamma = 0$) and maximum fairness ($\gamma = 1$). They apply this to two settings:

  • Equal Filling Till Threshold (EFTT) for Divisible Matching (where items like ad budgets can be split fractionally): When an item arrives, Phase I distributes it equally among all interested classes that haven't yet reached a saturation level of $\gamma$. Once relevant classes hit the $\gamma$ threshold, Phase II switches to standard, greedy water-filling (giving mass to the least-loaded compatible agent regardless of class) to maximize overall efficiency.
  • Hybrid Ranking for Indivisible Matching (whole items like individual rides): Each agent is assigned a random priority $\mu_a \in [0, 1]$. Agents with $\mu_a \le \gamma$ form a "priority pool." Arriving items are first matched to a uniformly random compatible class within this priority pool. If none exist, the algorithm falls back to standard RANKING, picking the compatible agent outside the pool with the lowest $\mu_a$.

To prove these work, the authors pair their algorithms with a novel primal-dual analysis, designing a mathematical potential function that mirrors the algorithms' exact two-phase transition at $\gamma$.

Datasets

Not discussed in the paper. (This is a purely theoretical computer science paper proving worst-case mathematical guarantees against adversarial inputs.)

Key Insights and Ideas

  • Fairness doesn't have to be full-time: You don't need to enforce strict group equality on every single decision to get strong fairness guarantees. Protecting groups early on (until they hit capacity $\gamma$) builds a "fairness cushion," freeing the algorithm to purely chase global efficiency afterward.
  • Fixing a broken speed limit: Prior work claimed an efficiency upper bound (Price of Fairness) of $\frac{1}{1+\alpha}$. However, for $\alpha \le 0.58$, that formula exceeds $0.632$—the absolute limit of any online matching algorithm, fair or not! By cleverly combining fairness-forcing arrivals with classic upper-triangular adversarial graphs, the authors prove a true, non-vacuous upper bound across the entire spectrum.
Trade-off curves showing the new algorithms breaking the 0.50 USW floor and closely tracking the improved Price of Fairness upper bound.

Key Results

Setting $\gamma \in (0, 1)$ yields the first algorithms to beat $0.5$-USW while maintaining constant CEF fairness:

  • Divisible Matching (EFTT): Simultaneously achieves $(1 - e^{-\gamma})$-CEF and $\left(1 - \frac{e^{\gamma-1}}{\gamma+1}\right)$-USW. For instance, tuning $\gamma = 0.7915$ gives $0.5468$-USW and $0.5468$-CEF, cleanly shattering the $0.5$ ceiling.
  • Indivisible Matching (Hybrid Ranking): Achieves the exact same efficiency of $\left(1 - \frac{e^{\gamma-1}}{\gamma+1}\right)$-USW alongside $\frac{\gamma}{2}$-CEF.
  • Near-Tight Impossibility Bound: No randomized, non-wasteful $\alpha$-CEF algorithm can beat $\frac{1+\alpha-e^{\alpha-1}}{1+\alpha}$-USW. As seen in the figure above, this smoothly connects $(1 - \frac{1}{e})$ at $\alpha \to 0$ to $0.5$ at $\alpha \to 1$, closely hugging EFTT's actual performance.

Limitations and Future Work

  • The Divisibility Gap: While EFTT hugs the theoretical upper bound for divisible items, Hybrid Ranking drops from $(1 - e^{-\gamma})$ down to $\frac{\gamma}{2}$ on fairness for indivisible items. Closing this gap—perhaps via advanced rounding schemes beyond online correlated selection—remains open.
  • Closing the Remaining Optimality Gap: A small sliver of daylight remains between EFTT's curve and the new impossibility bound; pinpointing the exact optimal frontier is left for future work.
  • Richer Models: The authors assume unweighted edges (binary "like/dislike" preferences) and worst-case adversarial item arrivals. Extending this threshold dial to weighted valuations, stochastic arrivals, and other fairness metrics (like maximin share) are natural next steps.

Summary updated

Abstract

Online bipartite matching, where agents are known in advance but items arrive sequentially and must be irrevocably assigned, is fundamental to problems ranging from ride-sharing to online advertising. When agents belong to classes such as demographic groups or geographic regions, fairness demands equitable treatment across these groups. Recent work introduced class envy-freeness (CEF), a natural extension of the classical fair division notion: an algorithm is $\alpha$-CEF if each class receives value at least an $\alpha$ fraction of what it could extract from any other class's bundle. However, all known algorithms achieving constant-factor CEF guarantees attain utilitarian social welfare (total matching value) of at most $\frac{1}{2}$ times the optimum, far below the $1-\frac{1}{e} \approx 0.632$ achievable without fairness constraints. We resolve the open question of whether fairness necessitates this efficiency loss, by introducing threshold-based algorithms parameterized by $\gamma \in [0,1]$ that equalize allocations across classes until threshold $\gamma$, then maximize efficiency. For divisible matching, this yields simultaneous $(1-e^{-\gamma})$-CEF and $(1 - \frac{e^{\gamma-1}}{\gamma+1})$-USW guarantees; for indivisible matching, $\frac{\gamma}{2}$-CEF with the same USW. Setting $\gamma > 0$ produces the first algorithms beating $\frac{1}{2}$-USW while maintaining constant CEF. We complement this with a novel upper bound construction, proving no non-wasteful $\alpha$-CEF algorithm can exceed $\frac{1 +\alpha - e^{\alpha-1}}{1+\alpha}$-USW and correcting prior bounds that were vacuous for $\alpha < 0.58$. Our upper bound nearly matches our algorithms' performance, giving the first substantive characterization of the price of fairness in online class matching.
BibTeX
@inproceedings{borst2026beyond,
  author = {Sander Borst and Max Springer},
  title = {{Beyond the Half Approximation: Fair and Efficient Online Class Matching}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=LdhHVOZXZ2},
}
Figure