1 Introduction
Content moderation is an important challenge faced by many online platforms, and it typically involves the analysis of content generated on the platform to verify whether it is compliant with the platform’s content policies. Examples of problematic content categories include fake profiles, spam, hate speech, violent content, and harassment (Facebook, 2022). A key issue in this domain is the enormous amount of content that needs to be verified. For example, Meta reported in Q3 of 2021: “In Q3, the prevalence of hate speech on Facebook was 0.03% or 3 views of hate speech per 10,000 views of content” (Rosen, 2021); and across Facebook and Instagram, actions were taken on over 100 million pieces of harmful content across all categories (Meta, 2021)
. While artificial intelligence technology is necessarily used to handle this volume of content, it is not, at least currently, accurate enough to handle content moderation without human help. For this reason, Meta employs thousands of people to help analyze ambiguous content that requires human verification or investigation
(Osofsky, 2019). Across the internet industry, social media companies, such as Twitter, YouTube, and Facebook, spend billions of dollars every year contracting with different partners that provide content moderating services (Schoolov, 2021). In this paper, we study the shortterm planning problem of allocating reviewing capacity to different harmful content categories, while taking into account uncertainty about content volume as well as the skills (e.g., language requirement, training on community standards) of various partners supplying reviewer capacity.We introduce the robust and fair work allocation (RFWA) problem. In the RFWA problem we have a set of content categories, each with some predicted workload , referred to as the demand of category . We also have a set of partners for content reviewers, where each partner has some capacity for reviewing content; we use because we will see that this capacity is analogous to supply in the context of markets. For every partner , consider all and only the content categories for which the partner has the appropriate language and cultural context as well as necessary training to work for. For each of these content category , there is a value which we will mostly think of as the rate of partner to handle category but it can also be used to model, for example, the accuracy of the work. The goal of the planner is to produce an allocation of workload capacity of partners to categories, in a way that satisfies both every predicted demand and every capacity constraint. In general, we will be interested in the setting where there is more work capacity than demand, in which case we would like to distribute excess work capacity across the content categories in a way that treats each category “fairly,” since each category has variable demand realizations, and have different stakeholders that care particularly about a given category.
To address the RFWA problem, we propose the use of tools from fair division. In particular, we study the application of leximin, competitive equilibrium from equal incomes (CEEI) (Varian et al., 1974), and more generally the max Nash welfare (MNW) allocation rule (Caragiannis et al., 2019), for approaching this problem. However, as we will discuss next, the RFWA has many practical considerations that necessitate the development of extensions to these tools.
The first practical consideration of the RFWA problem is the demands of the categories. In our model, these demands are hard constraints that must be satisfied, and the “utility” achieved by each category is the supply of excess reviewing capacity that it receives beyond the forecasted demand. We refer to this excess allocation as overallocation, and the primary goal of the planner is to fairly overallocate. This requires us to consider an allocation model that is similar to the Nash bargaining model (Nash, 1953), where each agent has a disagreement point, which is analogous to the demands of categories in our model. We introduce variations on marketequilibriumbased allocation (including CEEI) and leximin fairness for handling these demands. We then show that, analogous to results for the standard setting (Halpern et al., 2020; Aziz and Rey, 2020), we have equivalence between leximin and CEEI when all categories have binary valuations, i.e. partners can either handle a category or not; a second useful marketequilibrium approach where the budgets are not uniform leads to a different type of allocation, however.
A second practical consideration is that of time. As discussed in prior work on other aspects of the content moderation problem, there is an important time component to this problem (Nguyen et al., 2020; Makhijani et al., 2021). The reason for this is that the time between the creation of a piece of content and its review can have a large impact on the platform quality. If harmful content is visible to users before it has been reviewed, then it negatively impacts users. Conversely, if a piece of policycompliant content is left in the review queue for a long time, it negatively impacts both the content creator and users. To address this time component, we introduce new versions of the various fair allocation approaches that take into account this time component.
Finally, related to the time component is the issue of smooth allocation across time. In practice, the different partners prefer to have relatively smooth allocations from each category across time. This makes it easier for them to perform staff allocation, as well as staff training for dealing with each of the categories. We introduce a new variation of the market equilibrium model that takes into account this smoothness component.
For each of the variations on the standard models introduced above, we study the properties resulting from these new variations, and show that in most cases we can still give desirable guarantees, for example by showing that marketequilibrium interpretations of the MNW allocation are preserved for several of these extensions. We also perform extensive numerical tests on realworld content moderation data, and study the qualitative and quantitative results derived from applying each of the proposed models to the RFWA problem.
While our paper is motivated by the RFWA problem, the ideas apply more broadly to several related operational problems. Here we mention two applications that are quite similar to the content moderation problem. The first one is the staffing problem for customer support services. The buyers here are different types of issues that need to be resolved, and each one has its own (expected) workload. On the other hand, the sellers are customer service representatives, and each representative can only work on a subset of the issues due to training, and has an upper limit on how much they can work in a day or in a week. The second application is how to schedule workers to provide labels for content that will later be used for the training of machine learning algorithms. Again, the buyers here are different types of content, and sellers are the workers. It is not hard to see that for both applications, overallocation and smooth allocation arise as issues that must be addressed.
Relationship to Market Equilibrium So far we have discussed the RFWA problem in its concrete context. However, for the remainder of the paper, we will discuss our results in a more general market equilibrium context, in order to be more consistent with existing literature. To that end, we now describe how the RFWA problem maps to a market equilibrium problem. The set of content categories corresponds to the set of buyers in a market (who now possess demands). The set of partners corresponds to the set of items in the market, and capacities correspond to item supplies. The value that category has for partner maps directly to a valuation in the market.

Over allocation: In some cases, there is more capacity than the expected workload. In such cases, we want to allocate fairly the oversupply of qualified capacities to different eligible content categories.

Smoothness: We want to allocate over multiple time periods, and we want an allocation that is humanly feasible, meaning we can not have an allocation that alternates a lot between consecutive periods (i.e., an allocation that is smooth over time).
1.1 Related Literature
Content moderation has gained its importance in the last decade as we spend more time browsing on the internet. Hence, many problems that arise from content moderation have been studied both inside and outside academia. The first is on developing reliable machine learning (ML) algorithms to automate content moderation as much as possible (see, e.g., Jhaver et al. (2019); Gillespie (2020)). Given that ML alone cannot solve the content moderation problem (Bassett, 2022), it is also important to efficiently use the human review capacity. Haimovich et al. (2020) developed a framework to predict the popularity of social network content in realtime, which could be used to detect harmful viral content and ultimately enable timely content moderation. Nguyen et al. (2020) developed a statistical framework that increases the accuracy for detecting harmful content, by combining the decisions from multiple reviewers as well as those from ML algorithms. Makhijani et al. (2021) built simulation models for the largescale review systems to understand and optimize the human review process and guide the platforms for operational decisions (e.g., hiring additional reviewers). Garcelon et al. (2021) investigated a multiarm bandit framework to calibrate the severity predictions of content based on various ML models.
To add to the plethora of works on different aspects of content moderation, in this work, we focus on the problem of scheduling reviewers in advance given the anticipated amount of workload, which we model as an allocation problem. The problem of allocating divisible goods to buyers fairly was first solved by Varian et al. (1974) via the socalled competitive equilibrium from equal incomes (CEEI) solution. The CEEI solution is fair in a sense that it is envyfree (Foley, 1966). Moreover, the CEEI solutions coincide with allocations that maximize the Nash social welfare (Arrow and Intriligator, 2005) and thus can be computed in polynomial time via the convex program given by Eisenberg and Gale (1959).
In terms of utility optimization, besides maximizing Nash welfare (MNW), another line of work investigates an egalitarian notion of utilities – that is, to find allocations which are leximinoptimal. In the case of binary additive valuation, the set of MNW allocations and leximinoptimal allocations are known to coincide (Halpern et al., 2020; Aziz and Rey, 2020). Moreover, leximinoptimal solutions have been shown to satisfy several fairness properties for the allocation of indivisible goods (see, e.g., Plaut and Roughgarden (2020); Kurokawa et al. (2018); Freeman et al. (2019)).
The overallocation setting of our paper is closely related to the framework of Nash bargaining (see, e.g., Panageas et al. (2021)) with the hard demands being interpreted as the disagreement point. A key difference between our model and the Nash bargaining model is that in the latter, there is the additional constraint that every buyer is allocated with exactly one unit of items. Interestingly, such fractional matching type of constraints allow the equivalence relation between the MNW allocations and leximinoptimal allocations to be extended to a more general setting of bivalued valuations (Aziz and Brown, 2020). However, we show in Section 3.3 that this result does not hold in our setting.
2 Fisher Markets with Over allocation and Discrete Time
We start by introducing the standard Fisher Market setting. There is a set of buyers (indexed by ), and items (indexed by ). Each buyer has some budget denoted by , and each item has a certain supply denoted by . Moreover, every buyer has some utility function denoting the utility that they derive from bundle . We will mostly be interested in linear utilities, where
and is buyer ’s valuation^{1}^{1}1If buyer is not eligible for item (i.e., in the application of content moderation, if a partner does not have the appropriate language and cultural context or necessary training for a content category), the valuation will be zero. of the items, although we will also consider generalizations of linear utilities a few times in the paper. We use to denote an allocation of items to buyers, with row denoting the bundle allocated to buyer , and denoting how much buyer gets of item . The utility profile of an allocation is the set of utilities of all buyers. Note that in the for utility profile, the ordering of buyers does not matter.
Given a set of prices , the demand set of a buyer is the set of optimal bundles within budget:
A market equilibrium is a priceallocation pair such that:

Every buyer receives a bundle from their demand set, i.e. ; and

Any item with positive price must be exactly allocated, i.e. .
In the standard setting, a market equilibrium is not only guaranteed to exist, it is also efficiently computable via convex programming. The celebrated EisenbergGale convex program (Eisenberg and Gale, 1959) achieves this:
(EG) 
The market equilibrium arises by combining the optimal primal solution with its corresponding dual variables on the supply constraints. The former gives the allocation that maximizes the
budgetweighted geometric mean of buyers’ utilities
(i.e., ), and the dual variables act as prices.When every buyer has a budget of one (i.e., ), the objective of (EG) is equivalent to maximizing the Nash Social Welfare (NSW), which is defined as the geometric mean of buyers’ utilities. Moreover, market equilibrium is used to define one of the premier methods for fairly allocating divisible goods: competitive equilibrium from equal incomes (CEEI). The reason is that allocation via CEEI leads to several attractive fairness properties:

Pareto optimality: there is no other allocation where every buyer is weakly better off (in terms of utilities) and some buyer is strictly better off.

Envyfreeness: every buyer prefers their own bundle to that of any other buyer . If budgets are not equal, then this holds after scaling by budgets: .

Proportionality: every buyer prefers their own bundle to the one where they receive of every item.
In this paper, we are interested in two variations on the standard Fisher market setting.
Allocation with hard demands from buyers.
First, each buyer has some required (or hard) utility demand . We are required to find an allocation where every buyer gets utility at least , and subject to feasibility, the goal is to fairly allocate the excess utility, where the utility by which we measure fairness is . We discuss and compare different fairness solution concepts in Section 3.
Allocation over multiple time periods.
Secondly, we are interested in settings where there is a temporal component: there are time steps, and items have supply constraints both per time step, and across all time steps. In particular, let denote how much of item buyer receives at time . Then, for every time step , we must satisfy the pertimestep supply constraint , and additionally satisfy the overall supply constraint . Note that that the temporal component only matters if , since otherwise we could split each item up into separate items each with supply specified by its pertimestep supply. We discuss different ways to model buyers’ overall utility in Section 4 and show how to satisfy markets’ desire for smooth allocation overtime in Section 5.
3 Fair allocation of oversupply
Here we assume that there’s a hard demand on utilities for each buyer , and then they have additional soft demand for getting additional supply. The goal is to find an allocation that satisfies every hard demand, and furthermore fairly allocate the oversupply to buyers as soft demands. To model fair allocation of oversupply, we define the utility of buyer given bundle as
In this section, we consider two solution concepts: market equilibrium and leximin rules.
3.1 Solution via Market Equilibrium
For market equilibrium, we can apply the same idea as in (EG) and give the formulation below, which maximizes the budgetweighted geometric mean of buyers’ utilities. By scaling, we additionally assume without loss of generality that the supply for all sellers.
(EGdemand) 
The objective in the formulation resembles that for Nash bargaining (see, e.g., Panageas et al. (2021)) with the hard demands being interpreted as the disagreement point. However, our problem is fundamentally different from Nash bargaining, which enforces a fractional matching type of constraints and requires that every buyer is allocated to exactly one unit of goods. As a result, the solution spaces between our formulation and the Nash bargaining formulation are different, and results from the Nash bargaining setting do not immediately extend to our setting.
For the rest of the paper, we impose the following regularity assumption, which ensures that the maximum budgetweighted geometric mean of buyers’ utilities is strictly positive, and the (EGdemand) problem does not take logarithm of zeros.
There exists an allocation such that for all buyer .
To simplify the notation for the rest of the section, we let be the utility of agent , and let be the dual variable corresponding to the nonnegative constraints of (EGdemand). Then, the Lagrangian of problem (EGdemand) is
By the stationarirty of the KKT conditions, we get that
(1) 
One property of the traditional fisher market (i.e., demand
for all buyers) is that with price vector
, every buyer spends their entire budget. Here, we show a similar property, but with demandinflated budgets.The market prices verify
Proof.
We omit variables ’s and rewrite the stationary condition (1) as:
where equality holds whenever due to complementary slackness. Multiplying both sides by and summing over , we get that
Since , we conclude the result. ∎
Note that for when buyers do not have hard demands (i.e., ), the equality in Lemma 3.1 recovers the property that every buyer spends all their budget: .
We next show the primal and dual solution pair to (EGdemand) forms a market equilibrium under a slightly different definition of demand sets as a consequence of Lemma 3.1.
Let be a solution to (EGdemand). The pair is a market equilibrium where the demand sets are defined with respect to the demandinflated budgets. That is, for each buyer ,
Proof.
The second condition in the definition of market equilibrium is satisfied due to complementary slackness. To show the first condition, which is every buyer receives a bundle from their demand set, we show that every item in the bundle maximizes the utility per dollar for buyer . By dual feasibility of problem EGdemand, we have . Hence, rearranging the terms of (1), we have
where equality holds when due to the complementary slackness condition . This implies that the utility per dollar is maximized by the buyer’s bundle, concluding the proof. ∎
Before we continue to the next solution concept, we would like to point out that there are two interesting choices for buyers’ budgets and both result in solutions with interesting properties. The first one is when all buyers have budgets of one, and in this case, the objective of (EGdemand) is simply the Nash welfare. The second choice is when buyers’ budgets are equal to their demands.
Assume for all buyers and sellers . Then,

when for all buyers , the difference is constant for all buyers ;

when for all buyers , the ratio is constant for all buyers .
Proof.
First note that the fact every buyer is assigned with a bundle in their demand set, as we have shown in Theorem 3.1, implies that all items have the same price, which we denote by . Let denote the amount of items allocated to buyer . Then the property in Lemma 3.1 becomes (). For (i), we can simplify () as for all buyers ; and for (ii), we can simplify () as for all buyers . These two simplifications conclude the proof. ∎
For more general noncomplete graphs, we anticipate similar results hold in a sense that the solution will try to be as fair as possible, additively when budgets are one and multiplicatively when budgets are equal to demands. Indeed, we observe this phenomenon in our experiments (see Section 3.4 for details).
3.2 Solution via Leximin Fairness Concept
In this section, we introduce another fairness solution concept, called the leximinoptimal allocation.
Consider two vectors of equal length and . Let denoted an ordered vector of so that (ties breaking randomly), and similarly let be an ordered vector of . We say is leximingreater than , denoted by , if there exists such that for all , and .
For any allocation , let be the vector of budgetweighted utilities, where . An allocation is said to be leximinoptimal if there is no other allocation such that . In other words, the leximinoptimal solution first maximizes the minimum component in the vector, then among all allocations where the minimum component in the vector is maximized, it maximizes the second minimum value, etc.
Leximin is a refinement of the maxmin fairness and a leximinoptimal allocation can be found by iteratively solving a sequence of maxmin convex problems (Wilson, 1998). See Algorithm 1 for details.
(leximin) 
When buyers have equal budget and binary additive utilities, the leximinoptimal solution is known to maximize NSW, both when the items are indivisible (Aziz and Rey, 2020) and when the items are divisible (Halpern et al., 2020). Therefore, we are interested in the connection between the leximinoptimal solutions and the solutions to (EGdemand) (referred to as EG solutions thereafter) in our setting.
3.3 Comparison
We say two allocations are equivalent if they give the same utility profile. In this section, we investigate whether the EG solutions and the leximinoptimal solution are equivalent under various scenarios (see Table 1 for the summary).
In terms of valuation, we first consider the special case of binary valuations (i.e., ), which represents compatibility between buyers and sellers and is commonly used in practice. Before considering the case with general valuations, we consider a slightly more restricted generalization known as bivalued valuations (i.e., , for some ). The reason we consider the bivalued setting is that in other domains such as Nash bargaining, many interesting results arise when valuations are bivalued (see, e.g., Aziz and Brown (2020)). However, as we show in the following, in our setting, the leximinoptimal solution and the EG solution do not coincide for bivalued valuations. Hence, we no longer need to investigate the most general setting as these negative results directly apply.
Besides different cases of valuations, we also consider two cases for budgets. The first one is when all buyers have equal budgets, for which we assume wlog that every buyer has a budget of one; and the second is when buyers’ budgets are equal to their demands. Note that for the first case, EG solutions coincide with the maximum Nash welfare (MNW) solutions, and the proof is similar to the one presented in Halpern et al. (2020) for binary valuations in the classical setting without hard demand constraints.
budget  budget demand  

binary valuation  ✓ (Theorem 3.3)  ✗ (Example 3.3) 
bivalued valuation  ✗ (Example 3.3)  ✗ 
This example shows that the EG solution is not the same as the leximinoptimal solution even for bivalued valuations. Assume we have two items, and two buyers with zero demand and unit budgets. All pairs have valuation one except for one pair: and . Both the EG solution and the leximinoptimal solution allocate the entire second item to the second buyer. However, for the first item, the EG solution allocates the whole item to the first buyer, whereas the leximinoptimal solution allocates only units of it to the first buyer.
The following example shows that the EG solution is not the same as the leximinoptimal solution when budget equals to demand, even when the valuation is binary. Consider the instance with two buyers and two items. Each item has a supply of one. The buyers have demand and respectively. The first buyer only accepts the first item, while the second buyer accepts both items.
Under the EG solution, the amount of the first item allocated to the first buyer is the solution for
Therefore, the EG solution allocates units of the first item to the first buyer. However, under the leximinoptimal solution, the amount of the first item allocated to the first buyer is the solution for the equation
with due to the AMGM inequality. The solution here is clearly not .
3.4 Application
The content quality and integrity of online content platforms play a central role for users experience and platform growth. For that, companies spend billions of dollars every year to contract with different partners that provide human content reviews (Schoolov, 2021). In this and the following application sections, we demonstrate through real data acquired from Meta (formerly known as Facebook) how our proposed methods can be useful in allocating partners’ capacity to different content categories.
In this setting, the sellers are the partners that provide human review services and their supplies represent the amount of reviewer hours they can schedule. The buyers are the different categories of content that need to be reviewed (hereafter referred to as work types), and their hard demands are the expected amount of human reviewing hours needed to review all the jobs (i.e., the forecasted workloads).
Since reviewers need to go through extensive training before being able to work on jobs in each work type, not all partners can work on all work types. As a result, we adopt the binary valuation structure to model compatibility between sellers and buyers. That is, if a partner can work on a certain work type, the pair has a valuation of one, and otherwise, it will have a value of zero.
For demonstration purposes, we will focus on one particular largesize market for the rest of the paper. See Figure 1 for an example of buyers (and their demands), sellers (and their supplies), and the valuation structure for this market.
In the following, we delve into some specific reasons why a fair and robust allocation is important for this business problem. First, since the demands are forecasted workload, the actually realized workload will unavoidably be different from the demand. Thus, being able to schedule the partners to handle more jobs than the forecasted workload provides a guardrail against natural fluctuation in the amount of workload as well as fluctuations due to headline events.
In addition, as the content review workforce is constantly evolving, occasionally, new work types are created and would have zero demands in the system. However, such zero demand is actually due to the fact that the machine learning models do not have adequate historical data to predict the workload yet. In this scenario, review hours should still be allocated to these new work types regardless of their predicted workload.
We investigate the allocations obtained from both the EG solutions and the leximinoptimal solutions. In addition, we consider two cases for buyers’ budget: we first assume buyers have unit budgets, and then assume that buyers’ budgets are equal to their demands. Note that in the former case, due to Theorem 3.3, the EG solutions and the leximinoptimal solutions coincide, and thus we omit one in the presentation in Figure 2.
We start by examining the EG solutions and we in particular observe that they satisfy properties similar to those stated in Proposition 3.1. When budgets are equal to ones, the oversupply from partners is equally divided among the work types. That is, the oversupply is distributed fairly in an additive sense. More specifically, except for “work type 10” (which is the only one that is compatible with the “partner 1”), all other work types are allocated an additional hours on top of their demands.
However, when buyers’ budgets are set to be the same as their demand, we notice that the oversupply is allocated fairly in a more multiplicative fashion under the EG solution. That is, work types with higher demand will receive higher amounts of allocation exceeding their demand. In our experiment, we observe that again except for the “‘work type 10”, all other work types receive an allocation that is about of their demands.
Lastly, the leximinoptimal solution when budgets are equal to demands does not perform well as it allocates a significant amount of oversupply to the buyer with the smallest amount of demand (or equivalently budget). The reason for this is that under leximin optimality objective, in order to maximize the minimum budget adjusted utility, the buyer with the smallest budget (or demand) will end up with the highest amount of utility (i.e., allocation). However, this solution, although is fair from an egalitarian point of view, does not align well with the business purposes here.
4 Multiple Time Periods in a Single Program
In the robust content review problem, we would typically have constraints at several levels of the problem: a given review site may have an overall maximum capacity that they can allocate across the planning period, but then they also typically have tighter pertimeperiod staffing constraints. To accommodate such constraints, we extend the basic Fisher market model to allow each item to have timebased constraints. More specifically, we will consider a model with discrete time steps, and each item will have an overall supply , as well as a pertime period supply .
The allocation vector now has a time component and we denote by the amount of item allocated to buyer at time . Similarly, the demand vector now also a time component, where is the demand of buyer at time , and we denote as the total demand of buyer .
Similar to the previous section, we may consider two solution concepts and investigate their equivalence under the special case of unit budget and binary valuation. In terms of buyers’ overall utilities, we consider two possibility to combine their utilities at each time period, where we denote the utility of buyer at time as
In the first approach, the utility of each buyer is simply the sum of the utilities at different times, whereas in the second approach, the utility of each buyer is the geometric mean of the utilities at different times. In terms of fairness, the first approach is a direct extension of the previous section, aiming to be fair to all the buyers; and the second approach targets fairness at a more granular level, aiming to be fair to all the buyers across all the time periods.
4.1 Total utility as the sum across time periods
For one possibility, we assume the overall utility of buyer is
Hence, we have the following program, which maximizes the budgetweighted utilities over the set of feasible allocations under timebased constraints. Note that this formulation also applies to the special case where each buyer only has an overall demand throughout all time periods (i.e., no timespecific demand).
(EGTimesum) 
It follows from stationarity of the KKT conditions that the following must hold:
(2) 
Note that here, we omit the dual variables corresponding to the nonnegative constraints and thus, the above must hold with equality if due to complementary slackness.
Let be a solution to (EGTimesum). Consider the pair , where the price on each item at a given time period . Then, every buyer spends their entire demandinflated budget. That is,
Proof.
Thus, when buyers have no hard demand, the market clears if we set the price of item at time equal to .
To show that the allocationprice pair is a market equilibrium, we need to show the condition that an item has price strictly greater than only if . This is not guaranteed in our setting. Instead, we have that only if either or . Thus, we get a market equilibrium if we generalize the price complementarity requirement to be that an item must have a nonzero price only if it is supplyconstrained at some layer of its supply hierarchy. More formally, we have the following theorem:
Let be a solution to (EGTimesum). Consider the pair , where the price on each item at a given time period . This pair is a market equilibrium under the condition that an item has only if either or , and under the following definition of demand sets:
Proof.
Rearranging the terms of (2), we have
where equality holds when due to the complementary slackness condition on . Thus, we get that buyers only buy items that give maximal bangperbuck. It follows that each buyer gets a bundle in their demand set.
In addition, by complementary slackness, we have that unless , and similarly unless . It follows that only if either or . ∎
A very related theorem is shown by Jain and Vazirani (2010): the EG program associated to any market which can be formulated as a network flow problem with a single source, and a sink for each buyer, where the utility of a buyer is the sum of mass on paths to the corresponding sink, and with the price on a path being equal to the sum of prices on the edges in the path, can be solved by maximizing the sum of the logs of these buyer utilities, and this yields a market equilibrium. (EGTimesum) fits in this framework, except that we have heterogeneous edge weights that go into the utility function.
Algorithm 1 can be easily adjusted to obtain the leximinoptimal solution in this setting with timebased constraints. In the following, we investigate whether results in Section 3.3 extend to the multipletime setting. Since the multipletime setting is a generalization, the negative results in Section 3.3 immediately extend. Thus, we focus on the positive result and in particular we show that when all buyers have budgets of ones and when valuations are binary, the set of MNW solutions and the set of leximinoptimal solutions coincides.
With binary valuations and unit budget, for (EGTimesum), the set of leximinoptimal solutions is the same as the set of MNW solutions under Assumption 3.1.
Proof.
Let be an allocation that is an EG solution (or equivalently an MNW solution since all buyers have budgets of one), we want to show that it is also leximinoptimal. Assume by contradiction that it is not. Let be a leximinoptimal solution. Let and denote the vectors of budgetweighted utilities corresponding allocation and , receptively. First observe that by optimality we must have the following.
Claim 1.
.
Then, by Assumption 3.1, we can apply the same proof idea as given in Halpern et al. (2020). Let be an enumeration of such that , and similarly let be an enumeration such that . Since by assumption, we can let be the smallest index so that . Then by Claim 1, we know there must be another index so that and we let be the smallest such index. Let . Then, by definition of the enumeration and our choice of , we have . Thus, there exists buyers , , and item such that and for some . Also, note that we must have by definition of . Hence, by Assumption 3.1, one can reallocate some item from buyer to at time period without affecting feasibility. However, this reallocation will increase the Nash Social Welfare, which contradicts the assumption that is an MNW solution. ∎
4.2 Total utility as the geometric mean across time periods
For the second possibility, we assume the overall utility of buyer is
In this case, the logarithm of the budgetweighted geometric mean of all buyers’ utility becomes
To maximize the budgetweighted utilities over the set of feasible allocations under timebased constraints, we have the following program.
(EGTimegeomean) 
In the setting, stationarity of the KKT conditions gives us the following relationship:
(3) 
where equality holds whenever due to complementary slackness.
Let be a solution to (EGTimegeomean). Consider the pair , where the price on each item at a given time period . Then, every buyer spends their entire demandinflated budget. That is,
Proof.
Thus, when buyers have no hard demand at all time periods (i.e., for all ), the market clears if we set the price of item at time equal to .
To show that the allocationprice pair is a market equilibrium, not only do we need to modify the price complementarity requirement as in the previous subsection, we also need to modify the definition of demand sets due to Lemma 4.2.
Let be a solution to (EGTimegeomean). Consider the pair , where the price on each item at a given time period . This pair is a market equilibrium under the condition that an item has only if either or , and under the following definition of demand sets:
Proof.
Note that the utility function is no longer linear but is concave since the geometric mean function is concave. To show that every buyer is allocated a bundle that is in their demand set, we instead want to show that only if it has the maximal marginal bangperbuck, where the marginal utility of item for buyer at time is
Rearranging the terms of (3), we have
where equality holds when due to the complementary slackness condition on . Thus, we get that buyers only buy items that give maximal marginal bangperbuck, as desired. The proof for the second condition is the same as that in the proof of Theorem 4.1. ∎
In the following, we define what makes a solution leximinoptimal in this setting. Instead of having a vector of buyers’ budgetweighted utilities, we now have a vector of buyers’ budgetweighted utilities at all time periods. More specifically, for any allocation , the vector now has a time component: ; and an allocation is leximinoptimal if there is no other allocation such that . With this definition, when all buyers have unit budgets, (EGTimegeomean) is the same as (EGdemand) if we treat each buyer at each time period as an individual buyer. Thus, Theorem 3.3 extends naturally.
With binary valuations and unit budget, for (EGTimegeomean), the set of leximinoptimal solution is the same as the set of MNW solutions under Assumption 3.1.
4.3 Application
For application, we continue our investigation on the same market. Instead of a single time period, we now focus on four consecutive time periods. We observe from our data that the supply from our partners is constant across the four time periods. This is expected given that partners usually have a fixed amount of facilities to accommodate their employees. On the other hand, we observe that for some work types, their forecasted demands have either an upward or a downward trend from one time period to the next (see Figure 3).
Due to the fact that variations are on the demand side, we use the second utility definition (as in Section 4.2) for our experiments. Moreover, for the following, we only focus on the case where buyers have a budget of one. The reason for this simplification is that the qualitative results are similar to those under the case where budgets are equal to demands.
The allocation results are shown in Figure 4. Note that we omit “partner 1”, since it can only work on the “work type 10”, and thus intuitively all of its reviewing capacity should be allocated toward that work type.
As one can see from Figure 4, for the most part, the allocation for each buyerseller pair is rather smooth from time to time. However, for the “work type 05”, its allocation from “partner 3” partner goes down, but it naturally follows from the fact that its demand has a downward trend. However, for “work type 04”, although its demand is relatively constant, its allocation from both partners vary, with one having an upward trend and the other having a downward trend.
Because of the variability in allocation from one to the next, the solution here has the drawback that partners have to shift their staffing requirements from time to time, which could be costly from an operational point of view. As a result, it would be beneficial to the partners if we can obtain a solution that minimizes staffing change as much as possible. We discuss more in detail on markets’ desire for smooth allocation in the next section.
5 Smooth Allocation Across Multiple Discrete Time Periods
In the previous section, we saw how to allow each item to have pertimeperiod and overall supply. However, the resulting allocations may still exhibit an effect which is often considered undesirable in practice: the allocation may have large swings across time, even when the utility from this is low. Consider the following robust content review example: There are two review categories (buyers) and two review sites (items), with three time steps. Each review site has perperiod supply of one, and no crosstime supply constraint. All valuations are one. There are many optimal allocations, but we will consider three in particular:

a high variation allocation ;

a low variation allocation with all other equal to zero;

another lowvariation allocation where for all .
In the highvariation allocation, each review site gets a nonsmooth allocation: in time step and time step , they flip their entire review category from one to the other. In practice, this is inefficient, due to staff context switching or even requiring different staff allocations. This can lead to less efficient reviewing for a given content category. In contrast, the two lowvariation allocations give each review site a nice constant amount of work from each review category. We do not necessarily prefer or to each other; both are equally “smooth”.
From the example above, we can clearly see the problem with the market equilibrium solutions, which is that they do not take into account market’s preferences for lowvariation solutions.
To model the preference for low variation, one approach is to add constraints forcing the variation to be within a certain range. For instance, if we want the allocation from one time period to the next to be within , we can add constraints
However, it is not hard to see that one issue with the constraints approach is that when demands are high (i.e., small amount of oversupply to distribute) and when variation in demand from time to time is also high, the problem could become infeasible.
Alternatively, we can include (or subtract, to be more precise) a penalty term in the objective. We assume the penalty term takes the following form:
where is any convex function that measures the discrepancy between two quantities and
is a hyperparameter that captures the strength in terms of the market’s desire for smooth allocation. Since
is the penalty function for nonsmooth allocation, we further require that whenever . Hence, we have the following program.(EGSmooth) 
Below, we list a couple of interesting choices for the penalty function.

Absolute deviation: .

KullbackLeibler: .
5.1 Application
To continue our experiment in Section 4.3, we now include an additional penalty term in the objective. We show the results in Figure 5 using the absolute difference penalty function with appropriate smoothness parameters. We would like to point out the qualitative results using the KL divergence penalty function is similar and we omit them here.
Note that now for both “work type 04” and “work type 05”, the allocations to “partner 3” are much smoother as compared those previously obtained as shown in Figure 4.
As the smoothness parameter becomes larger, the dominating component in the objective of (EGSmooth) shifts from the utility term to the smoothness penalty term. Hence, if we were to set , the resulting allocation becomes constant for each (work type, partner) pair. However, such a smooth allocation is at the expense of wasting partners’ reviewing capacity. Thus, the smoothness parameter should be carefully chosen to balance different business objectives.
Acknowledgement. The authors would like to thank Martin Bscheider and Andrew Martens for their support throughout the work.
References
 Arrow and Intriligator [2005] Kenneth Arrow and Michael Intriligator. Handbook of mathematical economics. Technical report, Elsevier, 2005.
 Aziz and Brown [2020] Haris Aziz and Ethan Brown. Random assignment under bivalued utilities: Analyzing hyllandzeckhauser, nashbargaining, and other rules. arXiv preprint arXiv:2006.15747, 2020.
 Aziz and Rey [2020] Haris Aziz and Simon Rey. Almost group envyfree allocation of indivisible goods and chores. Proceedings of the 29th International Joint Conference on Artificial Intelligence (IJCAI), 2020.
 Bassett [2022] Caitlin Bassett. Will AI take over content moderation? Mind Matters News, 2022. URL https://mindmatters.ai/2022/01/willaitakeovercontentmoderation/.
 Caragiannis et al. [2019] Ioannis Caragiannis, David Kurokawa, Hervé Moulin, Ariel D Procaccia, Nisarg Shah, and Junxing Wang. The unreasonable fairness of maximum nash welfare. ACM Transactions on Economics and Computation (TEAC), 7(3):1–32, 2019.

Eisenberg and Gale [1959]
Edmund Eisenberg and David Gale.
Consensus of subjective probabilities: The parimutuel method.
The Annals of Mathematical Statistics, 30(1):165–168, 1959.  Facebook [2022] Facebook. Facebook community standards, 2022. URL https://transparency.fb.com/policies/communitystandards/. Online; accessed 7February2022.
 Foley [1966] Duncan Karl Foley. Resource allocation and the public sector. Yale University, 1966.
 Freeman et al. [2019] Rupert Freeman, Sujoy Sikdar, Rohit Vaish, and Lirong Xia. Equitable allocations of indivisible goods. arXiv preprint arXiv:1905.10656, 2019.
 Garcelon et al. [2021] Evrard Garcelon, Vashist Avadhanula, Alessandro Lazaric, et al. Top ranking for multiarmed bandit with noisy evaluations. arXiv preprint arXiv:2112.06517, 2021.
 Gillespie [2020] Tarleton Gillespie. Content moderation, ai, and the question of scale. Big Data & Society, 7(2):2053951720943234, 2020.
 Haimovich et al. [2020] Daniel Haimovich, Dima Karamshuk, Thomas J Leeper, Evgeniy Riabenko, and Milan Vojnovic. Scalable prediction of information cascades over arbitrary time horizons. arXiv preprint arXiv:2009.02092, 2020.
 Halpern et al. [2020] Daniel Halpern, Ariel D Procaccia, Alexandros Psomas, and Nisarg Shah. Fair division with binary valuations: One rule to rule them all. In International Conference on Web and Internet Economics, pages 370–383. Springer, 2020.
 Jain and Vazirani [2010] Kamal Jain and Vijay V Vazirani. Eisenberg–gale markets: algorithms and gametheoretic properties. Games and Economic Behavior, 70(1):84–106, 2010.
 Jhaver et al. [2019] Shagun Jhaver, Iris Birman, Eric Gilbert, and Amy Bruckman. Humanmachine collaboration for content regulation: The case of reddit automoderator. ACM Transactions on ComputerHuman Interaction (TOCHI), 26(5):1–35, 2019.
 Kurokawa et al. [2018] David Kurokawa, Ariel D Procaccia, and Nisarg Shah. Leximin allocations in the real world. ACM Transactions on Economics and Computation (TEAC), 6(34):1–24, 2018.
 Makhijani et al. [2021] Rahul Makhijani, Parikshit Shah, Vashist Avadhanula, Caner Gocmen, Nicolás E StierMoses, and Julián Mestre. Quest: Queue simulation for content moderation at scale. arXiv preprint arXiv:2103.16816, 2021.
 Meta [2021] Meta. Community standards enforcement report, 2021. URL https://transparency.fb.com/data/communitystandardsenforcement/. Online; accessed 7February2022.
 Nash [1953] John Nash. Twoperson cooperative games. Econometrica, 21(1):128–140, 1953.
 Nguyen et al. [2020] VietAn Nguyen, Peibei Shi, Jagdish Ramakrishnan, Udi Weinsberg, Henry C Lin, Steve Metz, Neil Chandra, Jane Jing, and Dimitris Kalimeris. Clara: confidence of labels and raters. In Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pages 2542–2552, 2020.
 Osofsky [2019] Justin Osofsky. Our commitment to our content reviewers. 2019. URL https://about.fb.com/news/2019/02/commitmenttocontentreviewers/.
 Panageas et al. [2021] Ioannis Panageas, Thorben Tröbst, and Vijay V Vazirani. Combinatorial algorithms for matching markets via nash bargaining: Onesided, twosided and nonbipartite. arXiv preprint arXiv:2106.02024, 2021.
 Plaut and Roughgarden [2020] Benjamin Plaut and Tim Roughgarden. Almost envyfreeness with general valuations. SIAM Journal on Discrete Mathematics, 34(2):1039–1068, 2020.
 Rosen [2021] Guy Rosen. Community standards enforcement report, third quarter 2021. 2021. URL https://about.fb.com/news/2021/11/communitystandardsenforcementreportq32021/.
 Schoolov [2021] Katie Schoolov. Why content moderation costs billions and is so tricky for facebook, twitter, youtube and others. CNBC, 2021. URL https://www.cnbc.com/2021/02/27/contentmoderationonsocialmedia.html.
 Varian et al. [1974] Hal R Varian et al. Equity, envy, and efficiency. Journal of Economic Theory, 9(1):63–91, 1974.

Wilson [1998]
Stephen J Wilson.
Fair division using linear programming.
preprint, Departement of Mathematics, Iowa State University, 1998.