Papers
Topics
Authors
Recent
Search
2000 character limit reached

Best-of-Both-Worlds Algorithm

Updated 15 July 2026
  • BOBW algorithms are a class of mechanisms that achieve simultaneous ex-ante fairness and ex-post performance guarantees in settings like fair division and online learning.
  • They utilize combinatorial methods such as LP rounding, maximum-weight matching, and support reduction to ensure proportional share, half-TPS, and Prop1 fairness.
  • Extensions of BOBW include unequal entitlements and sequential decision-making problems, prompting both practical implementations and critical analysis of variance-based approaches.

Searching arXiv for the primary and related Best-of-Both-Worlds papers. Best-of-Both-Worlds (BoBW) algorithms are procedures designed to secure two guarantees simultaneously that are usually in tension. In fair division, the aim is to obtain a randomized allocation that is ex-ante fair while every realized allocation is also ex-post fair; in online learning and bandits, the aim is to achieve near-optimal performance in both stochastic and adversarial environments without prior knowledge of the regime. The term is therefore a cross-domain methodological label rather than a single universal procedure. One prominent instantiation is the fair-share allocation algorithm for indivisible goods with additive valuations, which computes in deterministic polynomial time a distribution over at most nn allocations that is ex-ante proportional and ex-post gives every agent at least half of her truncated proportional share (TPS), hence at least half of her maximin share (MMS), while also satisfying proportionality up to one item (Prop1) (Babaioff et al., 2021). Subsequent work has both extended and critiqued the BoBW paradigm in neighboring fair-division models and in sequential decision-making problems such as delayed bandits, heavy-tailed bandits, contextual bandits, and multi-dueling bandits (Hoefer et al., 2022, Babaioff et al., 23 Jan 2026, Schlisselberg et al., 30 May 2025, Chen et al., 2024, Akash et al., 19 Mar 2026).

1. Conceptual scope of the BoBW paradigm

In fair allocation of indivisible goods, BoBW refers to a distribution over deterministic allocations that is ex-ante fair and is supported only on allocations that satisfy an ex-post fairness relaxation or approximation. In the equal-entitlement additive setting, the basic ex-ante benchmark is proportional share,

PSi=vi(M)/n,PS_i = v_i(M)/n,

while ex-post benchmarks include envy-based relaxations such as EF1 or value-based guarantees such as a constant fraction of MMS (Babaioff et al., 2021). The motivation is explicit: ex-ante proportionality can be achieved trivially by randomization, but such a distribution may be very unfair ex-post; BoBW mechanisms seek both guarantees at once (Babaioff et al., 23 Jan 2026).

The fair-share formulation of BoBW in (Babaioff et al., 2021) is built around four share notions. For agent ii with additive valuation viv_i, the proportional share is PSi=vi(M)/nPS_i=v_i(M)/n, the maximin share is

MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),

and the truncated proportional share TPSiTPS_i is the unique t0t\ge 0 solving

(1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.

The paper states that MMSiTPSiPSiMMS_i \le TPS_i \le PS_i (Babaioff et al., 2021).

Across online learning, the same label denotes algorithms that are simultaneously strong in stochastic and adversarial regimes. Examples include delayed bandits with regret PSi=vi(M)/n,PS_i = v_i(M)/n,0 adversarially and instance-dependent stochastic regret matching known lower bounds up to logarithmic factors (Schlisselberg et al., 30 May 2025), parameter-free heavy-tailed multi-armed bandits (Chen et al., 2024), linear contextual bandits with PSi=vi(M)/n,PS_i = v_i(M)/n,1 stochastic and PSi=vi(M)/n,PS_i = v_i(M)/n,2 adversarial guarantees (Kato et al., 2024), and multi-dueling bandits under Condorcet and Borda objectives (Akash et al., 19 Mar 2026). This suggests that “BoBW algorithm” denotes a structural objective—simultaneous adaptation to two fairness or difficulty regimes—rather than a single canonical algorithm.

2. The fair-share BoBW algorithm for indivisible goods

The central fair-division result considers PSi=vi(M)/n,PS_i = v_i(M)/n,3 agents with equal entitlements, additive valuations, and no transfers. The main theorem states that there exists a randomized allocation, that is, a distribution PSi=vi(M)/n,PS_i = v_i(M)/n,4 over integral allocations, such that: for every agent PSi=vi(M)/n,PS_i = v_i(M)/n,5, PSi=vi(M)/n,PS_i = v_i(M)/n,6; for every realization PSi=vi(M)/n,PS_i = v_i(M)/n,7 in the support and every PSi=vi(M)/n,PS_i = v_i(M)/n,8, PSi=vi(M)/n,PS_i = v_i(M)/n,9 and ii0; and every ii1 in the support also satisfies Prop1 (Babaioff et al., 2021). The same paper emphasizes that prior BoBW mechanisms based on the “up to one item” paradigm may give agents only a ii2 fraction of their MMS, and that the present algorithm is intended to guarantee a high ex-post value rather than merely an envy-based relaxation (Babaioff et al., 2021).

The theorem is constructive. It can be achieved in deterministic polynomial time by a distribution over at most ii3 allocations ii4 (Babaioff et al., 2021). The distribution is computed via a polynomial-time procedure over fractional allocations, faithful rounding, and support reduction.

The guarantees are nearly best possible in two senses stated explicitly in the paper. First, one cannot guarantee agents more than their proportional share ex-ante. Second, one cannot guarantee agents more than a ii5 fraction of their TPS ex-post, so the ii6 constant is asymptotically tight (Babaioff et al., 2021).

3. Structure of the algorithm

The algorithm operates in four phases on a fractional allocation matrix ii7 with row-sums ii8 and column-sums ii9, extending each viv_i0 linearly (Babaioff et al., 2021).

Phase Main operation Stated role
1 LPviv_i1 + faithful rounding Handle “over-proportional” items
2 Maximum-weight perfect matching Complete a matching for viv_i2 on remaining real items
3 LPviv_i3 + faithful rounding Allocate leftover items fractionally
4 LPviv_i4 Support reduction to at most viv_i5 allocations

In Phase 1, the algorithm computes each agent’s viv_i6 in poly-time by sorting viv_i7 and solving a one-variable equation. It then constructs an extended market viv_i8 with unit-demand utilities

viv_i9

and PSi=vi(M)/nPS_i=v_i(M)/n0. It solves LPPSi=vi(M)/nPS_i=v_i(M)/n1 to find a fractional perfect matching of these “demand clones,” maximizing PSi=vi(M)/nPS_i=v_i(M)/n2 subject to PSi=vi(M)/nPS_i=v_i(M)/n3, then faithfully implements PSi=vi(M)/nPS_i=v_i(M)/n4 by decomposing into PSi=vi(M)/nPS_i=v_i(M)/n5 perfect matchings. Each agent either gets one “truly over-proportional” item PSi=vi(M)/nPS_i=v_i(M)/n6 with PSi=vi(M)/nPS_i=v_i(M)/n7 or the fictitious item PSi=vi(M)/nPS_i=v_i(M)/n8. Agents who receive a real item form group PSi=vi(M)/nPS_i=v_i(M)/n9; the others form MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),0 and temporarily hold nothing (Babaioff et al., 2021).

In Phase 2, with MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),1, the algorithm computes a maximum-weight perfect matching MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),2 in the bipartite graph MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),3 with edge-weights

MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),4

so that every MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),5 is matched to some MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),6 with MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),7 but “as fair as possible.” After this step, each MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),8 holds one item MMSi=maxpartitions M=P1Pnminkvi(Pk),MMS_i = \max_{partitions\ M=P_1\cup\cdots\cup P_n}\min_k v_i(P_k),9 (Babaioff et al., 2021). The accompanying proposition states that in every partial allocation so far, each TPSiTPS_i0-agent holds some TPSiTPS_i1 with TPSiTPS_i2, and each TPSiTPS_i3-agent holds TPSiTPS_i4 with TPSiTPS_i5 (Babaioff et al., 2021).

In Phase 3, the leftover items TPSiTPS_i6 are allocated fractionally via LPTPSiTPS_i7 so that every TPSiTPS_i8 gets at least

TPSiTPS_i9

This fractional solution is then faithfully rounded in t0t\ge 00 allocations. By design, each t0t\ge 01-agent’s total ex-ante value from t0t\ge 02 plus the fractional share is at least t0t\ge 03, and ex-post she loses at most the value of one item, so either t0t\ge 04 or she already has t0t\ge 05 (Babaioff et al., 2021).

In Phase 4, the resulting distribution of size t0t\ge 06 is reweighted by solving LPt0t\ge 07, preserving each agent’s ex-ante proportional value while using only t0t\ge 08 allocations in the support (Babaioff et al., 2021).

4. Guarantees, proof sketch, and tightness

The proof sketch in (Babaioff et al., 2021) isolates three guarantees. Ex-ante proportionality follows because LPt0t\ge 09 ensures every agent’s (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.0-value is at least (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.1, and any agent sent to (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.2 is brought by Phases 2 and 3 up to at least (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.3. Ex-post (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.4 holds because a (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.5-agent receives (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.6 with (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.7, whereas a (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.8-agent either loses at most (1/n)jMmin{vi(j),t}=t.(1/n)\cdot\sum_{j\in M}\min\{v_i(j),t\}=t.9 in the rounding of LPMMSiTPSiPSiMMS_i \le TPS_i \le PS_i0 or already has MMSiTPSiPSiMMS_i \le TPS_i \le PS_i1. Ex-post Prop1 follows because every realized allocation is a faithful implementation of a fractional LP solution that was PS-respecting, so up to one item each agent’s value is at least MMSiTPSiPSiMMS_i \le TPS_i \le PS_i2 (Babaioff et al., 2021).

The complexity statement is explicit. Each phase uses only polynomial-time subroutines: computing MMSiTPSiPSiMMS_i \le TPS_i \le PS_i3 by sorting and one-variable root-finding; solving LPMMSiTPSiPSiMMS_i \le TPS_i \le PS_i4 and LPMMSiTPSiPSiMMS_i \le TPS_i \le PS_i5 via any poly-time LP solver; maximum-weight bipartite matching in Phase 2; faithful implementation via Birkhoff–von Neumann decompositions in MMSiTPSiPSiMMS_i \le TPS_i \le PS_i6 matches; and a small LPMMSiTPSiPSiMMS_i \le TPS_i \le PS_i7 of size MMSiTPSiPSiMMS_i \le TPS_i \le PS_i8. Overall running time is polynomial in MMSiTPSiPSiMMS_i \le TPS_i \le PS_i9 (Babaioff et al., 2021).

The impossibility statements are part of the characterization of the algorithm. If all valuations coincide, proportional share is best possible ex-ante, so no randomized mechanism can guarantee strictly more than PSi=vi(M)/n,PS_i = v_i(M)/n,00 ex-ante. Ex-post, one cannot do better than PSi=vi(M)/n,PS_i = v_i(M)/n,01 even ignoring ex-ante proportionality, by considering PSi=vi(M)/n,PS_i = v_i(M)/n,02 identical goods. The paper also states an efficiency clash: no mechanism that is ex-ante fractionally Pareto-optimal can give each agent a constant fraction of MMS ex-post, so the result cannot be strengthened to require ex-ante fPO as well (Babaioff et al., 2021).

A later result for three additive agents pushes the ex-post fairness frontier much further in the few-agent case: there exists an ex-ante proportional distribution whose every allocation is Epistemic EFX (EEFX) and guarantees each agent at least PSi=vi(M)/n,PS_i = v_i(M)/n,03 of her MMS, with support size at most six (Babaioff et al., 16 Feb 2026). This does not supersede (Babaioff et al., 2021) in general PSi=vi(M)/n,PS_i = v_i(M)/n,04, but it shows that much stronger BoBW fairness is possible for small numbers of agents.

5. Variants with entitlements and few-agent refinements

The equal-entitlement assumption in (Babaioff et al., 2021) is relaxed in “Best of Both Worlds: Agents with Entitlements” (Hoefer et al., 2022). There, each agent PSi=vi(M)/n,PS_i = v_i(M)/n,05 has a weight PSi=vi(M)/n,PS_i = v_i(M)/n,06, normalized so PSi=vi(M)/n,PS_i = v_i(M)/n,07. The main theorem states that for additive valuations one can compute in strongly-polynomial time a lottery PSi=vi(M)/n,PS_i = v_i(M)/n,08 over PSi=vi(M)/n,PS_i = v_i(M)/n,09 integral allocations such that the induced fractional allocation is ex-ante weighted stochastic-dominance envy-free (hence ex-ante weighted envy-free), and every support allocation satisfies weighted proportionality up to one good (WPROP1) and weighted transfer envy-free up to one good, denoted WEF(1,1) (Hoefer et al., 2022). The construction uses Different-Speeds Eating (DSE) followed by the bihierarchy decomposition of Budish–Che–Kojima–Milgrom (Hoefer et al., 2022).

The same paper proves a tightness statement: no stronger ex-post WEFPSi=vi(M)/n,PS_i = v_i(M)/n,10-guarantee with PSi=vi(M)/n,PS_i = v_i(M)/n,11 is compatible with any ex-ante WEF lottery (Hoefer et al., 2022). This is the weighted analogue of the impossibility phenomena seen in the equal-entitlement setting.

For two and three agents, (Babaioff et al., 16 Feb 2026) gives approximation schemes with stronger envy-based guarantees. For two agents and any PSi=vi(M)/n,PS_i = v_i(M)/n,12, there is an FPTAS that outputs a distribution which is ex-ante envy-free and ex-post EFX, while guaranteeing each agent at least a PSi=vi(M)/n,PS_i = v_i(M)/n,13-fraction of her MMS. For three agents, the paper presents an FPTAS preserving exact ex-ante proportionality when EEFX is dropped, and a separate FPTAS preserving EEFX while losing at most PSi=vi(M)/n,PS_i = v_i(M)/n,14 in the value-based guarantees (Babaioff et al., 16 Feb 2026). A plausible implication is that the coarse PSi=vi(M)/n,PS_i = v_i(M)/n,15-TPS barrier of the general construction is driven partly by the all-PSi=vi(M)/n,PS_i = v_i(M)/n,16 setting rather than by a universal obstruction.

6. Critiques, alternative objectives, and the broader BoBW literature

A notable criticism of one natural BoBW heuristic appears in “On Best-of-Both-Worlds Fairness via Sum-of-Variances Minimization” (Babaioff et al., 23 Jan 2026). That paper studies the optimization problem of minimizing PSi=vi(M)/n,PS_i = v_i(M)/n,17 subject to ex-ante proportionality. When valuations are identical, every SoV-minimizer is supported only on allocations whose value vector attains the minimum Euclidean distance to PSi=vi(M)/n,PS_i = v_i(M)/n,18, and all allocations in the support are EFX; consequently they guarantee PSi=vi(M)/n,PS_i = v_i(M)/n,19-MMS when PSi=vi(M)/n,PS_i = v_i(M)/n,20 and PSi=vi(M)/n,PS_i = v_i(M)/n,21-MMS for PSi=vi(M)/n,PS_i = v_i(M)/n,22 (Babaioff et al., 23 Jan 2026). However, when valuations are not identical, even with two agents and two goods, SoV-minimization can put positive mass on giving both goods to one agent, so the support allocation might not even be EF1 and might not give an agent any constant fraction of her MMS (Babaioff et al., 23 Jan 2026). The same pathology extends to minimizing the maximum variance, the variance of PSi=vi(M)/n,PS_i = v_i(M)/n,23, the standard-deviation of PSi=vi(M)/n,PS_i = v_i(M)/n,24, and the sum of standard deviations (Babaioff et al., 23 Jan 2026).

Outside fair division, the BoBW label has become standard in online learning. In delayed bandits, Delayed-SAPO combines Basic Stochastic Checks, a successive-elimination style active set, and an Eliminated-Arms Processing subroutine to obtain adversarial regret PSi=vi(M)/n,PS_i = v_i(M)/n,25 and stochastic regret

PSi=vi(M)/n,PS_i = v_i(M)/n,26

matching known lower bounds up to logarithmic factors (Schlisselberg et al., 30 May 2025). In heavy-tailed multi-armed bandits, uniINF is described as the first parameter-free algorithm to achieve the BoBW property for the heavy-tailed MAB problem, with adversarial regret PSi=vi(M)/n,PS_i = v_i(M)/n,27 and stochastic guarantees that match lower bounds up to logarithmic factors (Chen et al., 2024). In multi-dueling bandits, MetaDueling converts multi-way winner feedback into an unbiased pairwise signal, and when instantiated with Versatile-DB it achieves PSi=vi(M)/n,PS_i = v_i(M)/n,28 pseudo-regret against adversarial preferences and PSi=vi(M)/n,PS_i = v_i(M)/n,29 under stochastic preferences in the Condorcet setting (Akash et al., 19 Mar 2026).

These results do not define a single common algorithm. Rather, they instantiate a common design pattern: explicit mechanism design or online-learning structure is required to secure two guarantees at once. The negative results on variance minimization in fair division (Babaioff et al., 23 Jan 2026) and the positive constructive results in allocation (Babaioff et al., 2021), entitlements (Hoefer et al., 2022), delayed feedback (Schlisselberg et al., 30 May 2025), and heavy-tailed settings (Chen et al., 2024) jointly indicate that BoBW performance is typically not obtained by a black-box scalar objective; it is achieved by problem-specific combinatorial or FTRL-style constructions.

7. Significance and open directions

The fair-share BoBW algorithm of (Babaioff et al., 2021) established that ex-ante proportionality can be combined, in deterministic polynomial time, with ex-post Prop1 and a value guarantee of at least half of TPS and MMS. Within fair division, that result shifted BoBW analysis away from purely envy-based “up to one item” guarantees toward share-based ex-post guarantees. The introduction of TPS was especially consequential because the algorithm’s strongest ex-post guarantee is phrased with respect to TPS rather than merely MMS, and the paper states that PSi=vi(M)/n,PS_i = v_i(M)/n,30 (Babaioff et al., 2021).

Subsequent work shows two divergent directions. One direction strengthens the fairness side under more structured conditions: weighted entitlements via DSE and bihierarchy decomposition (Hoefer et al., 2022), and near-optimal guarantees for few agents using EEFX and FPTAS constructions (Babaioff et al., 16 Feb 2026). The other direction identifies hard limits for simplistic formulations, as in the failure of sum-of-variances minimization under heterogeneous valuations (Babaioff et al., 23 Jan 2026). This suggests that the enduring content of the BoBW idea is not a particular primitive but a program of simultaneous guarantees under incompatible desiderata.

A plausible implication is that future BoBW work in fair division will continue to separate by structural regime: equal versus unequal entitlements, few versus many agents, and envy-based versus share-based ex-post notions. The current literature already records impossibility frontiers—such as the PSi=vi(M)/n,PS_i = v_i(M)/n,31 barrier ex-post in the equal-entitlement additive model (Babaioff et al., 2021) and the incompatibility between ex-ante WEF and stronger ex-post weighted envy relaxations when PSi=vi(M)/n,PS_i = v_i(M)/n,32 (Hoefer et al., 2022)—alongside constructive frontiers such as PSi=vi(M)/n,PS_i = v_i(M)/n,33-MMS and EEFX for three agents (Babaioff et al., 16 Feb 2026). Together, these results define the Best-of-Both-Worlds algorithm not as a monolithic object, but as a family of rigorously designed mechanisms whose common purpose is to reconcile ex-ante and ex-post guarantees, or stochastic and adversarial performance, within a single formally analyzable procedure.

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Best-of-Both-Worlds (BOBW) Algorithm.