betaFeedback

WorksComputer Science

The Advice Complexity of Online AdWords with Hard Budgets

Abstract

Advice complexity measures how many bits of information about the future an online algorithm needs to achieve a given competitive ratio. We study the advice complexity of the Online AdWords Problem with Hard Budgets (OAW-HB) and determine several advice complexities exactly or to the first-order term. All our lower bounds rest on one method, namely an exponential moment whose base and input distribution are chosen optimally. For small bids, BALANCE is (1−1/e)(1-1/e)-competitive without advice. On the nested instances behind this bound we establish that ratio 1−ε1-ε costs nlog⁡21ε−nlog⁡2e+o(n)n\log_2\frac1ε-n\log_2e+o(n) bits as ε→0ε\to0, for every budget size and in particular for bipartite matching, and that exact optimality costs exactly ⌈log⁡2n!⌉\lceil\log_2n!\rceil bits. The matching algorithm does the opposite of BALANCE, i.e., it spends its whole error budget at the start to build a reserve. Beyond the nested family, on every instance whose eligible sets shrink over time, with arbitrary budgets and demands, BALANCE refined by ⌈1/ε⌉\lceil1/ε\rceil priority classes attains ratio 1−ε1-ε with ⌈nlog⁡2⌈1/ε⌉⌉\lceil n\log_2\lceil1/ε\rceil\rceil bits, so the advice complexity of this class is nlog⁡21ε±O(n)n\log_2\frac1ε\pm O(n). Finally, on a hidden-target family on which BALANCE is exactly 3/43/4-competitive, ratio 34+ε\frac34+ε costs Θ(ε2n)Θ(ε^2n) bits, even for randomized algorithms, and the optimal a

Introduction

In the AdWords problem [13] queries arrive online, each query is eligible for some advertisers with given bids, and every advertiser has a hard budget. When every bid is small compared with the budget, the algorithm BALANCE is (1−1/e)(1 - 1/e)-competitive, and this is optimal even for randomized algorithms [13]. The loss comes entirely from not knowing the future. The advice model [8, 12, 3, 5] quantifies it. An oracle that sees the whole input writes a bit string, and the advice complexity of ratio ρ\rho is the least number of bits that an online algorithm must read to be ρ\rho-competitive.

Advice lower bounds are usually proved by counting or by a reduction from string guessing [2, 6], and they are usually stated up to constant factors. For bipartite matching, for instance, ratio 1−ϵ1-\epsilon is known to need Ω(nlog⁡1ϵ)\Omega\left(n\log\frac{1}{\epsilon}\right) bits, and O(n/ϵ5)O(n/\epsilon^5) bits suffice [9]. Exact constants are rare, and a notable exception is asymmetric string guessing, whose advice complexity Boyar et al. [6] determined exactly. Motivated by this, we study the advice complexity of budgeted allocation and determine it exactly, to the second-order term, or to the first-order term on the instance families that underlie the known lower bounds.

The Online AdWords Problem with Hard Budgets

An instance I=(U,V,E,B,b)I=(U,V,E,B,b) of OAW-HB consists of a set U={1,…,n}U=\{1,\ldots,n\} of advertisers, advertiser ii having an integer budget BiB_i, a sequence VV of mm queries that arrive one by one, and bids bij≥0b_{ij}\ge0 on the edges of a bipartite graph G=(U,V,E)G=(U,V,E). When query jj arrives, its neighborhood N(j)N(j) and its bids are revealed. The algorithm then assigns jj irrevocably to some i∈N(j)i\in N(j) whose spent amount plus bijb_{ij} does not exceed BiB_i, collecting bijb_{ij}, or it rejects jj. We write ALG⁡(I)\operatorname{ALG}(I) and OPT⁡(I)\operatorname{OPT}(I) for the revenue of the online algorithm and of an optimal offline allocation. With unit bids and unit budgets the problem is online bipartite matching. Under the small-bid assumption every bid is small compared with the budget, and in the limit the demand becomes divisible.

Our Contributions

Our results are summarized in Table 1.

SettingRatioAdvice (bits)Ref.
Small bids, nested1−ϵ1-\epsilonnlog⁡21eϵ±o(n)n\log_2\frac{1}{e\epsilon}\pm o(n)Cor. 1
exact⌈log⁡2n!⌉\lceil\log_2 n!\rceilCor. 2
Small bids, decreasing1−ϵ1-\epsilonnlog⁡21ϵ±O(n)n\log_2\frac{1}{\epsilon}\pm O(n)Cor. 3
Small bids1−1e+δ1-\frac{1}{e}+\deltaΩ(δ3n)\Omega(\delta^3 n)Thm. 10
Hidden targets34+ϵ\frac{3}{4}+\epsilonΘ(ϵ2n)\Theta(\epsilon^2 n), randomizedCor. 4
Large bids16\frac{1}{6} and ρ>12\rho>\frac{1}{2}11 and Ω(nlog⁡mn)\Omega(n\log\frac{m}{n})Thm. 11, 12

Table 1. Main results, with nn advertisers and mm queries. The o(n)o(n) term in the first row holds as ϵ→0\epsilon\to0 and ϵn→∞\epsilon n\to\infty, and the bound Ω(nlog⁡mn)\Omega(n\log\frac{m}{n}) holds when m/nm/n is large enough.

  1. The exact cost of ratio 1−ϵ1-\epsilon for small bids. Let Nπ(n,B)N_\pi(n,B) be the nested instance behind the bound 1−1/e1-1/e. It has nn advertisers of budget BB and nn phases of BB unit-bid queries, and phase tt is eligible for the advertisers π(t),…,π(n)\pi(t),\ldots,\pi(n) of a hidden order π\pi. We establish (Theorems 1 and 2, Corollary 1) that ratio 1−ϵ1-\epsilon on this family costs

b∗(n,ϵ)=nlog⁡21ϵ−nlog⁡2e±O(ϵnlog⁡1ϵ+1ϵ+log⁡n)b^*(n,\epsilon)=n\log_2\frac{1}{\epsilon}-n\log_2 e\mathbin{\pm}O\left(\epsilon n\log\frac{1}{\epsilon}+\frac{1}{\epsilon}+\log n\right)

bits, for every budget B≥1B\ge1 (so in particular for bipartite matching) and in the divisible model as well. Exact optimality costs exactly ⌈log⁡2n!⌉\lceil\log_2 n!\rceil bits for every BB (Corollary 2), which extends the bound of Miyazaki for matching [15]. The optimal advice is not what one might expect. Instead of spreading the demand as BALANCE does, the optimal algorithm spends its whole error budget at the start to build a reserve of full advertisers, after which the advice only has to guarantee that each exit falls into a sliding window of the size of the reserve (Figure 2).

Figure 2. The two strategies on Nπ(6,1)N_{\pi}(6,1). Row π(i)\pi(i) is the advertiser that exits after phase ii. A cell shows its fill after the phase has been placed, the thick cell is its exit, and its unused budget there is lost. DtD_t is the loss after tt exits. (a) BALANCE spreads every phase over all live advertisers, so every early exit wastes budget, and it loses 1.9. (b) BUFσ\mathrm{BUF}_{\sigma} with σ=(π(3),π(2),π(5),π(4),π(6),π(1))\sigma=(\pi(3),\pi(2),\pi(5),\pi(4),\pi(6),\pi(1)), on an order in the event Eσ(π)E_{\sigma}(\pi) of Theorem 2. It spends its whole error budget K=1K=1 on the first exit and then keeps a sliding reserve of min⁡{K+1,n−t+1}\min\{K+1,n-t+1\} full advertisers, so it loses 1. Until the first rejection (phase 5 in (a) and phase 6 in (b)) the live load after phase tt equals 1+Dt−11+D_{t-1}, the most that the reserve law allows, and the two strategies differ only in how they distribute it.

  1. Every decreasing instance. An instance is decreasing if its eligible sets shrink along the stream, as when campaigns end one after another, while budgets, exit times and demands are arbitrary. The natural advice is a priority class for each advertiser, which is used by BALANCE refined into LL priority classes. We

prove that on every decreasing instance this algorithm loses at most the optimal load of one class, minus one advertiser (Theorem 3). The proof is a single cut argument (Figure 3). With classes cut along an optimal solution, ⌈nlog⁡2⌈1/ϵ⌉⌉\lceil n\log_2\lceil1/\epsilon\rceil\rceil bits give ratio 1−ϵ1-\epsilon (Corollary 3). Since the nested family is decreasing, the advice complexity of decreasing instances is nlog⁡21ϵ+O(n)n\log_2\frac{1}{\epsilon}+O(n), and exact optimality on them costs exactly ⌈log⁡2n!⌉\lceil\log_2 n!\rceil bits. On the nested family, priority classes exceed the optimum b∗b^* by at most log⁡2e+log⁡2(1+ϵ)\log_2 e+\log_2(1+\epsilon) bits per advertiser, up to the error terms of Corollary 1. These log⁡2e\log_2 e bits are exactly the price of fixed instead of sliding windows (Remark 1 and Figure 1).

The price of competitiveness on the nested family

Figure 1. The price of competitiveness on the nested family Nπ(n,B)N_\pi(n,B). The solid curve is the leading term log⁡21eϵ\log_2\frac{1}{e\epsilon} of b∗(n,ϵ)/nb^*(n,\epsilon)/n, sharp as ϵ→0\epsilon\to0 (Corollary 1). The dashed steps show log⁡2L\log_2 L bits for L=2kL=2^k priority classes, plotted at their exact asymptotic ratios 1−rL+1/L1-r_{L+1}/L (Proposition 1). At the corners, the gap tends to log⁡2e\log_2 e bits (Remark 1). The leading term vanishes at ϵ=1/e\epsilon=1/e, the ratio of BALANCE; we do not claim sharpness near 1−1/e1-1/e.

Figure 3. (a) A decreasing instance as a bipartite graph. Round tt brings demand dtd_t that is eligible for every advertiser exiting at or after tt (here τ=(1,2,2,3,4)\tau= (1, 2, 2, 3, 4)), so the eligible sets shrink. (b) The quantities in the proof of Theorem 3. Advertisers are drawn in the exit order ≺\prec, a box shows the budget and the shading the final load, and dotted lines separate the classes. Advertiser jj is the last one that ends with unused budget, and the cut is at s=τj+1s = \tau_j + 1. Everything after the cut ends full, nothing is rejected before it, and demand placed on SS before round ss (orange) can only go to the class of jj, never to its first member iai_a. So the loss relative to an optimal solution xx is at most x(a−)x(a^{-}).

Hidden targets above 3/43/4

We also consider a two-phase family in which flexible demand must be placed before it is revealed which advertisers will receive rigid demand. On this family BALANCE is exactly 3/43/4-competitive. We prove that ratio 3/4+ϵ3/4+\epsilon needs, and can be achieved with, Θ(ϵ2n)\Theta(\epsilon^2 n) bits, for every budget and even against randomized algorithms (Theorems 4 and 5, Corollary 4). Moreover the advice complexity of this family equals the logarithm of a covering number with a defect (Theorem 6).

Techniques

All our lower bounds rest on a classical principle [10, 14]. An algorithm that reads bb bits is one of 2b2^b advice-free algorithms. So if a random input defeats every advice-free algorithm except with probability PP, then b≥log⁡2(1/P)b \ge\log_2(1/P). We bound PP optimally, by an exponential moment whose base and input distribution make the bound for each round tight.

For AdWords the payoff of an exit depends on everything the algorithm did before, and the moment becomes computable through the reserve law. The budget filled on advertisers that are still present is at most one phase of demand plus the loss incurred so far, so an algorithm can hedge only to the extent that it has already lost. The same law suggests the optimal algorithm, which loses early on purpose. For priority classes we look at the last advertiser that ends with unused budget. Every later advertiser ends full, nothing is rejected before it leaves, and every unit placed early on a later advertiser stays inside its class, so the cut at its exit bounds the loss by one class. For hidden targets the upper bound is a covering family built from an anti-concentration bound for the hypergeometric distribution.

Related Works

Advice complexity was introduced in [8, 12, 3], and we refer to the survey [5]. String guessing [2] and its asymmetric version ASG [6] are the standard sources of lower bounds. Boyar et al. [6] determined the advice complexity of ASG via covering designs and defined the class AOC. For online bipartite matching, Miyazaki [15] proved that ⌈log⁡2n!⌉\lceil\log_2 n! \rceil bits are necessary and sufficient for optimality. Dürr et al. [9] showed that ratio 1−ϵ1-\epsilon needs Ω(nlog⁡1ϵ)\Omega(n\log\frac{1}{\epsilon}) bits and admits O(n/ϵ5)O(n/\epsilon^5) bits, and beating ratio 1/21/2 costs Θ(log⁡log⁡n)\Theta(\log\log n) bits [16, 7]. Online knapsack is AdWords with one advertiser and private queries, and for it one bit gives ratio 1/21/2 while beating 1/21/2 costs about log⁡m\log m bits [4]. To the best of our knowledge, the advice complexity of AdWords has not been studied before.

Preliminaries

An oracle that knows the instance writes an infinite tape, and a deterministic online algorithm reads a prefix of it. An algorithm that reads at most bb bits behaves on every instance as one of the 2b2^b advice-free algorithms AσA_\sigma that read the tape σ0∞\sigma0^\infty, σ∈{0,1}b\sigma\in\{0,1\}^b. Its decisions on a common prefix of two instances coincide whenever it reads the same advice, and we call this execution invariance. Two generic tools are used throughout.

Lemma 1. (i) Let μ\mu be a distribution on a family F\mathcal{F} of instances such that every advice-free deterministic algorithm meets a given guarantee on a μ\mu-random instance with probability at most PP. Then every deterministic algorithm that meets the guarantee on all of F\mathcal{F} reads at least log⁡2(1/P)\log_2(1/P) bits on some instance.

(ii) Let Z1,…,ZnZ_1,\ldots,Z_n take values in R∪{+∞}\mathbb{R} \cup\{+\infty\} and be adapted to a filtration (Gi)(\mathcal{G}_i),

and let u∈(0,1)u \in(0,1) and ci≥0c_i \ge0 satisfy E[u−Zi∣Gi−1]≤ci\mathbb{E}[u^{-Z_i} \mid\mathcal{G}_{i-1}] \le c_i (with u+∞=0u^{+\infty}=0). Then Pr⁡[∑iZi≤z]≤u−z∏ici\Pr[\sum_i Z_i \le z] \le u^{-z}\prod_i c_i for all real zz.

Proof. (i) The success events of the 2b2^b algorithms AσA_\sigma cover F\mathcal{F}, so 1≤2bP1 \le2^bP. (ii) Since u<1u<1, the event ∑iZi≤z\sum_i Z_i \le z means u∑iZi≥uzu^{\sum_i Z_i} \ge u^z. By the tower property E[u∑iZi]≤∏ici\mathbb{E}[u^{\sum_i Z_i}] \le\prod_i c_i, and Markov’s inequality gives the claim. □\square

References

  1. [1]Agrawal, S., Zadimoghaddam, M., Mirrokni, V.: Proportional allocation: Simple, distributed, and diverse matching with high entropy. In: Proceedings of the 35th International Conference on Machine Learning (ICML). Proceedings of Machine Learning Research, vol. 80, pp. 99–108 (2018)
  2. [2]Böckenhauer, H.J., Hromkovič, J., Komm, D., Krug, S., Smula, J., Sprock, A.: The string guessing problem as a method to prove lower bounds on the advice complexity. Theoretical Computer Science 554, 95–108 (2014)
  3. [3]Böckenhauer, H.J., Komm, D., Královič, R., Královič, R., Mömke, T.: On the advice complexity of online problems. In: International Symposium on Algorithms and Computation (ISAAC). Lecture Notes in Computer Science, vol. 5878, pp. 331–340. Springer (2009)DOI
  4. [4]Böckenhauer, H.J., Komm, D., Královič, R., Rossmanith, P.: On the advice complexity of the knapsack problem. In: Latin American Symposium on Theoretical Informatics (LATIN). Lecture Notes in Computer Science, vol. 7256, pp. 61–72. Springer (2012)
  5. [5]Boyar, J., Favrholdt, L.M., Kudahl, C., Larsen, K.S., Mikkelsen, J.W.: Online algorithms with advice: A survey. ACM Computing Surveys 50(2), 1–34 (2017)
  6. [6]Boyar, J., Favrholdt, L.M., Kudahl, C., Mikkelsen, J.W.: Advice complexity for a class of online problems. In: 32nd International Symposium on Theoretical Aspects of Computer Science (STACS 2015). LIPIcs, vol. 30, pp. 116–129 (2015)DOI
  7. [7]Buchbinder, N., Naor, J., Wajc, D.: Lossless online rounding for online bipartite matching (despite its impossibility). In: Proceedings of the 2023 ACM-SIAM Symposium on Discrete Algorithms (SODA) (2023). https://doi.org/10.1137/1.9781611977554.ch78
  8. [8]Dobrev, S., Královič, R., Pardubská, D.: How much information about the future is needed? In: International Conference on Current Trends in Theory and Practice of Computer Science (SOFSEM). Lecture Notes in Computer Science, vol. 4910, pp. 247–258. Springer (2008)
  9. [9]Dürr, C., Konrad, C., Renault, M.: On the power of advice and randomization for online bipartite matching. In: 24th Annual European Symposium on Algorithms (ESA 2016). Leibniz International Proceedings in Informatics (LIPIcs), vol. 57, pp. 37:1–37:16 (2016). https://doi.org/10.4230/LIPIcs.ESA.2016.37
  10. [10]Emek, Y., Fraigniaud, P., Korman, A., Rosén, A.: Online computation with advice. Theoretical Computer Science 412(24), 2642–2656 (2011)
  11. [11]Hoeffding, W.: Probability inequalities for sums of bounded random variables. Journal of the American Statistical Association 58(301), 13–30 (1963)
  12. [12]Hromkovič, J., Královič, R., Královič, R.: Information complexity of online problems. In: International Symposium on Mathematical Foundations of Computer Science (MFCS). Lecture Notes in Computer Science, vol. 6281, pp. 24–36. Springer (2010)DOI
  13. [13]Mehta, A., Saberi, A., Vazirani, U., Vazirani, V.: AdWords and generalized online matching. Journal of the ACM 54(5), 22 (2007)DOI
  14. [14]Mikkelsen, J.W.: Randomization can be as helpful as a glimpse of the future in online computation. In: 43rd International Colloquium on Automata, Languages, and Programming (ICALP 2016). LIPIcs, vol. 55, pp. 39:1–39:14 (2016)
  15. [15]Miyazaki, S.: On the advice complexity of online bipartite matching and online stable marriage. Information Processing Letters 114(12), 714–717 (2014)
  16. [16]Pena, N., Borodin, A.: On the limitations of deterministic de-randomizations for online bipartite matching and max-SAT (2016), arXiv:1608.03182

Paper details

vlnc:W_r3v69cxc
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Computer Science

Not recorded for this paper

View statement
Looking for related papers…
Contents