FAIRFORMER: A transformer architecture for discrete fair division
Chris Mascioli, Satyam Goyal, Mithun Chakraborty
TL;DR
FairFormer tackles the problem of allocating indivisible goods under additive valuations without money by learning a permutation-equivariant transformer that assigns items to agents in a single forward pass. The two-tower architecture uses within-set self-attention and item-to-agent cross-attention to produce a fractional allocation optimized for expected Nash welfare, followed by row-wise discretization and EF1-Quick-Repair to enforce fairness with minimal welfare loss. Empirical results show near-optimal performance on Nash welfare (~96.6–96.8%) and utilitarian welfare (~95.6–95.9%), outperforming RR, ECE, and MU+EF1 across diverse distributions and problem sizes, with favorable runtime characteristics. The approach demonstrates strong cross-size generalization, robustness to scarcity, and practical scalability, offering a compelling combination of fairness guarantees and high efficiency in discrete fair division.
Abstract
We propose a deep neural network-based solution to the problem of allocating indivisible goods under additive subjective valuations without monetary transfers, trading off economic efficiency with envy-based fairness. We introduce FairFormer, an amortized, permutation-equivariant two-tower transformer that encodes items and agents as unordered token sets, applies self-attention within each set, and uses item-to-agent cross-attention to produce per-item assignment distributions in a single forward pass. FairFormer is trained end-to-end to maximize expected log-Nash welfare on sampled instances, requiring no solver supervision, unrolled allocation procedures, or fairness labels. At test time, we discretize by row-wise $\arg\max$ and apply a lightweight post-processing routine that transfers items to eliminate violations of envy-freeness up to one item while prioritizing improvements in Nash welfare. Our approach generalizes beyond its training regime and achieves near-optimal welfare (e.g., for uniformly sampled valuations, $96$--$97\%$ for Nash welfare; $95$--$96\%$ for utilitarian welfare), outperforming strong baselines in solution quality and/or runtime.
