Title: Advice Querying under Budget Constraint for Online Algorithms
Venue: NeurIPS 2023
Accepted: yes
Keywords: online algorithms

competitive ratio

learning augmented algorithms

scheduling

ski-rental

secretary
Abstract: Several problems have been extensively studied in the learning-augmented setting, where the algorithm has access to some, possibly incorrect, predictions. However, it is assumed in most works that the predictions are provided to the algorithm as input, with no constraint on their size. In this paper, we consider algorithms with access to a limited number of predictions, that they can request at any time during their execution. We study three classical problems in competitive analysis, the ski rental problem, the secretary problem, and the non-clairvoyant job scheduling. We address the question of when to query predictions and how to use them.

Advice Querying under Budget Constraint for Online Algorithms

Abstract

Several problems have been extensively studied in the learning-augmented setting, where the algorithm has access to some, possibly incorrect, predictions. However, it is assumed in most works that the predictions are provided to the algorithm as input, with no constraint on their size. In this paper, we consider algorithms with access to a limited number of predictions, that they can request at any time during their execution. We study three classical problems in competitive analysis, the ski rental problem, the secretary problem, and the non-clairvoyant job scheduling. We address the question of when to query predictions and how to use them.

1 Introduction

With the rise of data science and the huge emphasis on research in machine learning and artificial intelligence, powerful predictive tools have emerged. This gave birth to learning-augmented algorithms , which use these predictions to go beyond the standard long-standing worst-case limitations. The design of such algorithms requires establishing good tradeoffs between consistency and robustness, i.e. having improved performance when the predictions are accurate, and not behaving poorly compared to the case without predictions if they are erroneous. This was formalized by Lykouris and Vassilvitskii [41] for the caching problem, and Purohit et al. [47] for the ski-rental and scheduling problems. Since then, the learning-augmented setting had many applications in implementing data structures [36, 23, 39] and in the design of algorithms [15, 7, 6, 11, 30, 5, 1, 4, 10, 40].

Several questions and research directions have been explored, such as exhibiting optimal robustnessconsistency tradeoffs [48], incorporating predictions from multiple experts [3, 19], or customizing learning approaches to make predictions for such algorithms [49, 21, 18, 34, 2]. In most papers, those predictions are assumed to be given as inputs, which is unfortunately not realistic, practical or applicable to real-life scenarios. Indeed, many problems such as scheduling, paging, or set cover, require some arbitrarily large number of predictions (roughly speaking one per request or job). We claim that, on the contrary, algorithms might have only access to a finite budget of predictions as each one of them is costly to compute. Therefore, the main question rather becomes deciding how and when to spend the assigned budget, by requesting new predictions. Such a setting was considered for example in [31] for the caching problem. Moreover, it also happens that the quality of the predictions improves with time, as more data are collected, more knowledge of the problem is gathered, or delaying the computation of prediction allows to allocate more computational power to them, hence enhancing their precision, for instance with more powerful forecasting models. The question of planning the prediction requests is thus quite crucial.

The problems we mentioned fall into the category of online algorithms, operating under uncertainty, and gaining more information about the input of the problem through time, eventually depending on their past decisions. The performance of such algorithms is measured by their competitive ratio [14], which is the worst-case ratio between their output and that of the optimal offline algorithm, having full knowledge of the inputs and parameters of the problem. To illustrate our claims, we shall focus

on three well-established and fundamental problems in competitive analysis: ski rental, secretary, and job scheduling problems.

Ski-rental In the ski-rental problem, the decision maker faces each day the choice of either renting a ski for a unit cost, or buying it at a cost of b and skiing for free after that. The only decision to be made by the algorithm is therefore when to buy. The unknown parameter is the length x of the ski season, and the objective is to minimize the total cost of renting and buying. The optimal offline algorithm has a cost min { x, b } , the deterministic online break-even algorithm, which consists in renting for the first b -1 days and then buying, results in a competitive ratio of 2 [32], and the optimal randomized algorithm introduced by Karlin et al. [33] yields a competitive ratio of e e -1 .

Secretary problem The second problem we study is the secretary problem. Consider having N applicants observed sequentially in a uniformly random order. Immediately after a candidate is observed, the algorithm has to either select them and stop, or refuse them irrevocably. The objective is to maximize the probability of selecting the best applicant overall. The particularity of this problem is that a single incorrect decision at any point leads to failure and zero gain. Consequently, the cost of making a wrong decision is significantly high. The optimal offline algorithm has access to all values and thus can choose the maximum with probability 1 . The optimal online strategy is to reject the first N/ e applicants, then stop at the first applicant who is better than all of them [17, 25]. This is often referred to as the 1 / e rule, and it gives a success probability of 1 / e ≈ 0 . 368 .

Job scheduling The third problem we consider is the preemptive non-clairvoyant job scheduling. The input is a set of jobs with unknown sizes, that the algorithm needs to schedule on a single machine, with the possibility of halting a job during its execution and resuming it later. The goal is to minimize the sum of their completion times, i.e. finish as many jobs as possible rapidly. The only observations made during the run of an algorithm are the completion times of the jobs. These observations, along with the times at which they are received, depend on both the input instance and the algorithm's past decisions. The cost of early incorrect decisions is more significant than that of later incorrect decisions. Take for example the instance of job sizes { x 1 = 1 , x 2 = 100 } , running x 1 then x 2 gives an output 1 + 101 = 102 , while running them in the inverse order gives 100 + 101 = 201 . The optimal offline algorithm is to schedule the jobs in increasing order of size, and a deterministic online algorithm called round-robin , gives a competitive ratio of 2 , which is optimal for an arbitrarily large number of jobs [46].

1.1 Organization and contributions

In Section 2, we consider the ski rental problem, where we assume that an oracle provides binary predictions on how the snow season length x compares to the purchasing cost b , and that these predictions are accurate with a probability that is a function of time, known to the algorithm and denoted as p t . This assumption accurately reflects and models what is practically occurring. As the snow season begins, there is significant uncertainty about how long it will last. However, over time, the accuracy of predictions increases as more weather observations are made, the direction of snowstorms becomes clearer, and additional data is collected. The algorithm is permitted to request only one prediction during its execution, at a time of its choice. Depending on the function p t and on how the prediction is used once queried, it can be more advantageous to rent for a period of time t before requesting it, i.e. paying a cost for making a better decision in the future. We consider that once the prediction is queried, we use either the deterministic or the randomized algorithm presented in [47] for the ski rental problem. We show how to optimally choose t , and how the knowledge of p t allows to tune the parameter λ , regulating the levels of consistency and robustness in both algorithms.

Secondly, we consider in Section 3 the secretary problem with access to an oracle, accurate with a probability p , telling if there are better applicants in the future. In practice, this would correspond to the following scenario: consider a decision-maker with an imperfect interviewing process, and thus can only compare the applicants with each other, i.e. observe their relative ranks, but lacks access to their true value. On the other hand, an expert who, due to extensive experience, knows how to better interview the applicants and extract their true value, and also knows the distribution of their values (as in a prophet setting with i.i.d variables). The decision-maker can ask the expert to interview some applicants for a cost. After that, the expert does not disclose the precise value of the applicant that is irrelevant to the decision maker-, but they provide a recommendation (accept or reject) and

accompany it with a confidence level, which is the probability that this recommendation is accurate. Assuming that the decision-maker has enough budget to ask for the expert's advice B times, we give an algorithm whose success probability depends on p and B , converges to 1 as p goes to 1 and B grows, and that is always lower bounded by 1 / e . Our algorithm easily adapts to the case where the accuracy of the oracle is time-dependent.

Section 4 is dedicated to the preemptive non-clairvoyant job scheduling, where we assume that the algorithm can request access to the sizes of B chosen jobs. In contrast with the two previous problems, there is no advantage in waiting before querying the hints, and since the jobs play identical roles, the algorithm can only request the sizes of B randomly chosen ones. We show first that the competitive ratio 2 cannot be improved unless B = Ω( N ) , where N is the number of jobs. Then we present an algorithm that chooses randomly B jobs and requests their sizes, then runs concurrently the optimal offline algorithms on those jobs and round-robin on the others, with time-dependent processing rates. We prove a generic expression for the output of this algorithm that depends on the chosen processing rate, and then we give a particular processing rate that yields a competitive ratio of 2 -( B/N ) 2 , therefore interpolating the competitive ratios 2 and 1 met respectively when no hint is given, and when all the job sizes are known.

Finally, we run simulations of our algorithms in Section 5. We show that the performance of the algorithm we introduced for the secretary problem matches our theoretical lower bound, and we compare it to another heuristic version that we did not study theoretically. Then, by exhaustively testing the algorithm we designed for the scheduling problem with access B job sizes on various benchmark instances, we observe that it has a better performance in practice than the theoretical upper bound 2 -( B/N ) 2 .

1.2 Related work

The ski-rental and scheduling problems have received extensive attention in the realm of learningaugmented algorithms [47, 48, 3, 19, 18, 37, 9]. They serve respectively as notable examples for problems requiring a single prediction and multiple predictions. Moreover, they both have numerous applications and variants, as [32, 12, 24, 44] for the ski rental and [42, 16, 38] for the scheduling problem. The secretary problem was also among the first problems studied with the advice model. Dütting et al. [22] consider that a binary prediction is received with each applicant, indicating whether it is the best overall or not. Assuming that these predictions are accurate each with a probability p independently, they design algorithms that improve upon the 1 /e success probability. While this model closely aligns with ours, we consider a scenario where the algorithm has a limited budget of predictions and must carefully determine when to query them. Antoniadis et al. [7] studied a variant of the problem where the objective is to maximize the value of the selected applicant. They consider that the algorithm is provided with a prediction of the value of the best applicant.

For both the ski-rental and the secretary problems, we consider predictions that are accurate with a known probability. A similar assumption was made in [28], where the oracle is assumed to deliver a prediction that is accurate with a probability of at least ϵ , and that can be arbitrarily inaccurate with the remaining probability. The authors give improved competitive ratios depending on ϵ for some online problems including caching, online set cover, and facility location.

The aspect of having a limited prediction budget is relatively underexplored in the literature. The question was initially examined in the context of the online linear optimization problem with hints, where Bhaskara et al. [13] demonstrated that a sublinear number of hints is sufficient to achieve regret bounds similar to those in the full hints setting when the timing of requesting hints is well chosen. Im et al. [31] also investigated this question for the caching problem, presenting an algorithm that strategically utilizes the assigned prediction budget to improve the competitive ratio as the budget increases. In a very recent paper, the ski-rental and the Bahncard problems were explored in a setting with costly predictions [20], where the cost of predictions is added to the total cost paid by the algorithm. This can be seen as a penalized version of querying predictions under budget constraints. Other works have also investigated the reduction of the prediction size rather than the number of predictions. Specifically, they consider binary predictions encoded on a single bit and explore how the competitive ratio can be enhanced compared to other types of predictions [22, 45, 8].

Another important question we cover thanks to the ski-rental problem is how to optimally balance robustness vs consistency with respect to predictions [47]. This tradeoff is usually done by adding

some extra-parameter λ ∈ [0 , 1] that reflects how much the decision-maker is willing to trust blindly the prediction, and which appears naturally in the bounds of the competitive ratio. Roughly speaking, for λ = 1 , the decision maker focuses solely on the performances of their algorithms when predictions are incorrect (hence predictions are actually disregarded), while for λ = 0 , they naïvely consider that predictions are correct. Intermediate values of λ correspond to less extreme behaviors, and the final competitive ratio strongly depends on the value of this parameter and the total 'amount' of errors (measured with respect to some problem-dependent metric) in predictions. Setting a value for this parameter requires having some knowledge about the quality of the prediction. Khodak et al. [34] shows how to learn to set λ 's value in an online learning setting, where the algorithm runs repeatedly on different instances, and learns to predict unknown parameters based on features on the new instances. After many runs, the value of λ can be increased since the predictions become more and more accurate. In our case, we have binary predictions that are correct with a known probability, which is a natural assumption for binary predictions [45, 22], and we show that this allows us to optimally choose the value of λ .

2 Ski-rental with time-dependent guarantees on the prediction

We consider that the cost of renting a ski for one day is 1 , while the cost of buying is b > 1 , and we denote x the duration of the ski season, which is unknown. For all the algorithms we present, if the ski season is over then the algorithm stops and no further cost is paid. In the learning-augmented setting, we assume that the algorithm possesses a prediction y for x . Many variants of this scenario have also been explored in previous research papers [47, 35, 27, 48]. We restrain ourselves to the case of binary predictions, comparing the number of snow days to the budget. More precisely, we assume the existence of an oracle, that can be called at any time t , predicting whether x -t > b or not, where x -t is the number of remaining snow days. Furthermore, we assume that the accuracy of the oracle improves over time. If queried at time t , then the prediction is correct with a probability p t , known to the algorithm, that is independent of the problem's history and increases over time. We assume that, due to budget limitations, the algorithm can access the oracle only once during its execution, and thus it must carefully choose the time of asking for the prediction.

Let ALG be an algorithm such that, with a prediction accurate with probability p , it has a competitive ratio C ( ALG , p ) . Wedefine the algorithm ALG t that rents for the first t days, then queries a prediction Q t of 1 ( x -t ≥ b ) at the start of day t +1 , and then acts like ALG . We have the following result.

Lemma 2.1. ALG t has a competitive ratio of at most t b + C ( ALG , p t ) .

The term t/b represents the additional cost due to renting the first t days, in order to have a better accuracy p t which decreases the second term. The optimal time for querying a prediction is t ⋆ minimizing the function t/b + C ( ALG , p t ) . Although this requires knowing all the sequence ( p t ) t ≥ 0 in advance, we can design simple online heuristics for being close to a local minimum, where the accuracy of the oracle at some step t is only revealed when that step is reached. We can for example access the oracle at the first time t when t/b + C ( ALG , p t ) increases.

In the following, we show how Lemma 2.1 can be applied with explicit algorithms ALG that are given a binary prediction as input. We consider the algorithms 1 and 2, which were first introduced in [47]. In both algorithms, the parameter λ indicates how much the prediction is trusted. Assuming that the input prediction is accurate with a probability p = P ( Q = 1 ( x ≥ b )) , we show how to tune λ in both algorithms to minimize their costs, and we upper bound their competitive ratios.

Algorithm 1: Deterministic algorithm with input binary prediction [47]

Input: cost b for buying, a prediction Q for 1 ( x ≥ b )

1 if Q = 1 then buy on the start of day ⌈ λb ⌉ ;

2 else buy on the start of day ⌈ b/λ ⌉ ;

Lemma 2.2. If the oracle Q delivers an accurate prediction with probability p ≥ 0 . 5 , then by choosing λ = √ 1 -p p , the algorithm achieves a competitive ratio of at most 1 + 2 √ p (1 -p ) .

The optimal choice of λ gives therefore a competitive ratio that is always upper bounded by 2, which is the optimal competitive ratio without prediction, and decreases to 1 when the accuracy of the oracle

0.5

0.6

0.7

0.8

0.9

1.0

Accuracy of the oracle

p

1.0

1.2

1.4

1.6

1.8

2.0

Competitive ratio

Theoretical upper bound for the competitive ratio

Deterministic

Randomized (b=5)

Randomized (b=10)

Randomized (b=100)

0

10

20

30

40

50

time

t

of querying the prediction

1.6

1.8

2.0

2.2

2.4

Competitive ratio

theoretical upper bound

Deterministic (b=50)

Deterministic (b=100)

Randomized (b=50)

Randomized (b=100)

is better. While Algorithm 1 is deterministic, the next algorithm we study is randomized, where the day of buying is a random variable, drawn from a probability distribution that depends on the prediction Q . We show again an optimal choice of λ for minimizing the competitive ratio.

Algorithm 2: Randomized algorithm with input binary prediction [47]

Lemma 2.3. If the oracle Q delivers an accurate prediction with probability p ≥ 0 . 5 , then with λ = min { 1 , 1 /b + √ ( e -1)(1 /p -1) } , Algorithm 2 has a competitive ratio of at most

Figure 1 shows the competitive ratios of both algorithms depending on p when λ is chosen optimally. The upper bound shown in Lemma 2.3 depends on b , this is why we test it with different values of b . As expected, the randomized algorithm yields better guarantees than the deterministic one. However, when p is very close to 1 , Algorithm 1 is slightly better, because the randomized algorithm requires having λ ≥ 1 /b , and therefore in the limit where p = 1 , the optimal choice is λ = 1 /b , giving the upper bound 1 + 1 /b instead of 1 on the competitive ratio.

Now, assuming that the oracle is accurate with a known time-dependent probability p t , the previous lemmas allow to optimally choose the time of querying the prediction when one of the two algorithms we presented is used after the prediction is obtained. We only state the result for the case where Algorithm 1 is used. The proof is immediate using Lemmas 2.1 and 2.2, and a similar result can be shown using Lemmas 2.1 and 2.3 when Algorithm 2 is used instead.

Theorem 2.4. If the predictions delivered by the oracle are accurate with a probability p t that only depends on the time, then renting until time t , then querying a prediction Q t and running Algorithm 1 with parameter λ = √ 1 -p t p t , yields a competitive ratio of at most 1 + t/b +2 √ p t (1 -p t ) .

We consider in Figure 2 an example where p t = 0 . 95 -0 . 4 exp( -t/ 5) , thus p 0 = 0 . 55 and lim t →∞ p t = 0 . 95 . The figure shows the competitive ratio of renting t days then using one of the Algorithms 1 or 2, with b = 50 , 100 . We observe that this strategy can significantly improve the competitive ratio if t is chosen correctly. Of course, this depends strongly on p t and b . In particular, for the randomized algorithm, it is better to query the prediction at t = 0 when b = 50 .

3 Secretary problem with B predictions

Assume that N applicants are observed sequentially in a uniformly random order ( x 1 , . . . , x N ) , all having distinct values. After an applicant is interviewed, the decision-maker has to either accept them

and halt the process, or refuse them irrevocably. We consider a setting where, when an applicant x t is observed, and the budget is still not exhausted, the algorithm can request a binary prediction Q ( x t ) indicating if there are better applicants coming in the future. We assume a maximal budget of B predictions, where B is a constant independent of N . We assume first that the predictions are error-free, and we give theoretical guarantees on Algorithm 3 in that case, and after that, we show how it can be adapted to handle predictions that are accurate only with a probability p . In this section, we say that an algorithm succeeded if the selected applicant is the best overall.

We consider first Algorithm 3, which rejects the first ⌈ r B N ⌉ applicants, where r B ∈ (0 , 1) is a threshold depending on B , and then queries a prediction for the first applicant x t better than all of them. If the oracle predicts that there is a better candidate in the future ( Q ( x t ) = 1 ) then the algorithm is restarted with the inputs ( x t +1 , . . . , x N ) and budget B -1 .

Algorithm 3: ADATHRESH Adaptive Threshold

If the oracle Q delivers error-free predictions, then with the thresholds ( r B ) B , ADATHRESH with budget B has a success probability of at least q B independently of the input size N .

Observe that, as B increases, the lower bound q B of the success probability of ADATHRESH converges to 1 and the thresholds r B converge to zero, meaning that the higher the budget, the higher the risks: there are fewer applicants in the first observation phase, thus the probability of selecting a future sub-optimal one is higher (yet this risk is hedged by the predictions), but on the other hand, it reduces the probability of naïvely disregarding the best applicant if it is among the first arriving ones. Although ADATHRESH is a naive algorithm that does not make full use of past information, we showed that adequately choosing the thresholds ( r B ) B guarantees a success probability that goes to 1 as the budget increases. We present in Appendix B.3 an improved version of ADATHRESH that keeps in memory the maximum value M observed so far and that rejects all applicants having values below M . We show numerically in Section 5 how this increases the success probability of the algorithm.

Handling imperfect predictions If the predictions of the oracle are imperfect, then one way of guaranteeing robustness, since the objective is to maximize the success probability, is to use the 1 /e -rule with probability λ and Algorithm 3 with probability 1 -λ . This guarantees a success probability of at least λ/e if the predictions are incorrect. On the other hand, given that the oracle's predictions are binary, it is reasonable to assume that each prediction is correct with a probability p independent of all the observations, as explained in the introduction. Based on this assumption, Algorithm 3 can be modified to include the option of trusting or disregarding the oracle's prediction at each step. We show that it is advantageous to trust the oracle when p is above a certain threshold and run the 1 / e -rule otherwise. This algorithm achieves a success probability of at least 1 /e , with improving performance as p approaches 1. We show in the appendix how this can be generalized when the accuracy of the oracle is time-dependent.

0

5

10

15

20

number of allowed predictions B

1/

e

0.5

0.6

0.7

Success probability

qB

(

p

)

p = 0.7

p = 0.8

p = 0.9

p = 0.95

p = 0.98

p = 1

Theorem 3.2. Assume that each oracle's prediction is independently correct with probability p ≥ ( 1 + ( e -1) exp( -e e -1 ) ) -1 ≈ 0 . 73 , then there is an algorithm that achieves a success probability of at least q 0 ( p ) = 1 /e for B = 0 , and q B ( p ) for B ≥ 1 defined as

If we denote W the Lambert function, i.e. the inverse of u ↦→ ue u on (0 , ∞ ) , then we have

Moreover, the algorithm has a success probability of at least 1 / e for any value of p ∈ [1 / 2 , 1] .

Optimal algorithm Assuming that the predictions are error-free, the problem is equivalent to the multiple-choice secretary problem [26], where the algorithm is allowed to select k ≥ 1 applicants, and it is successful if the best overall candidate is among them. Indeed, the algorithm is given B +1 attempts to identify the best applicant, and it halts if it finds it. This is analogous to choosing k = B +1 applicants, where following the selection of each one, the algorithm employs a selection strategy as if the previous guesses were unsuccessful. The optimal algorithm for selecting k applicants is a ( a k , . . . , a 1 ) -rule [26, 43], where at any step t , if the number of applicants already selected is i ∈ { 0 , . . . , k } , then reject everyone until step min { t, a k -i } , and accept the first applicant after that is the best observed so far. Although this family of algorithms has a simple structure, analyzing it is difficult and hides many technical challenges. The optimal thresholds and the asymptotic success probability are explicitly computed only up to k ≤ 5 , and a recursive formula is proven, via a dynamic programming approach, to compute the next thresholds. This formula is however difficult to exploit even numerically, while the optimal thresholds and the success probability of ADATHRESH can be computed very easily.

If the predictions are correct with a probability p , then the optimal algorithm must be a generalization of the ( a k , . . . , a 1 ) -rule, and thus it is even harder to analyze. The algorithm we proposed is naive in the sense that it does not take into account all the past information and only remembers the history since the last prediction was queried. However, it illustrates how the limited budget of predictions should be spent, and it presents good robustness and consistency guarantees with respect to p and B , in the sense that it always has a success probability of at least 1 / e , which is optimal without predictions, and it has a success probability that converges to 1 as B and p increase.

4 Preemptive B -clairvoyant job scheduling

We consider the problem of scheduling multiple jobs on a single machine, with the objective of minimizing the sum of their completion times. More particularly, we place ourselves in the preemptive setting, where the jobs can be temporarily halted and resumed later, or equivalently that they can be run in parallel with rates that sum at most to 1. Let N be the number of jobs and x 1 , . . . x N their sizes. If the algorithm knows beforehand the sizes of the jobs, it is called clairvoyant , and the optimal algorithm OPT is to run the shortest jobs first. An algorithm is non-clairvoyant if the size x j of any job j is unknown until the job is completed. Motwani et al. [46] showed that no deterministic or randomized algorithm can have a better competitive ratio than 2 , which is achieved by round-robin ( RR ), which is a deterministic algorithm. RR works as follows: at any time t , if n is the number of remaining jobs, then RR runs them all in parallel with rates 1 /n each.

An in-between setting, surprisingly not explored yet, is when the algorithm has only access to the sizes of a limited number of jobs. We say that an algorithm is B -clairvoyant when it is allowed to access the sizes of B jobs. We assume that it can query their true sizes, and not just noisy predictions. We start with a negative result, stating that we need to have B = Ω( N ) to achieve a better competitive ratio than 2 . Then, we give an algorithm with a competitive ratio of at most 2 -( B/N ) 2 .

Let us first remind a few classic notations in the scheduling problem. For any algorithm ALG , and any instance J = { x 1 , . . . , x N } , the sum of the completion times obtained by ALG can be written as

where D ALG ( i, j ) is the delay caused by job i to job j , i.e. the amount of job i executed before the completion of job j . With this notation, we have for any i < j that D OPT ( i, j ) + D OPT ( j, i ) = min { x i , x j } and D RR ( i, j ) = D RR ( j, i ) = min { x i , x j } . Thus, if x 1 ≤ . . . ≤ x N we obtain

4.1 Few hints are not enough

In opposite to other problems where it has been proved that a sublinear number of hints is enough for improving the performance [13, 31], the following theorem demonstrates that, for the scheduling problem, no algorithm can achieve a competitive ratio better than 2 when B = o ( N ) .

Theorem 4.1. Any B -clairvoyant deterministic or random algorithm with B = o ( N ) , has a competitive ratio lower bounded by 2 .

4.2 Parallel OPT-RR algorithm with adaptive processing rates

We assume in this section that the B = Ω( N ) . A first naive algorithm would run RR until there are B jobs left, then query their sizes, and use OPT to finish. However, when all the jobs have the same size, they terminate at the same time and no hint is queried. The output of the algorithm with this instance is exactly the same as RR , which is twice the output of OPT asymptotically in N [46], and therefore its competitive ratio is at least 2 . More generally, any algorithm that runs RR waiting for a certain number of jobs to finish before querying the sizes of B unfinished ones is no better than RR for the same reasons. Alternatively, the algorithm can wait for a possibly random amount of time T > 0 , independent of the observed completion times, before querying the first hint. However, by taking job sizes sampled from an exponential distribution with parameter µ such that their sum is smaller than T with an arbitrarily high probability, the algorithm terminates with high probability before requesting any hint and is no better than a non-clairvoyant algorithm on such input instances, leading to a competitive ratio of at least 2 . Therefore, the best moment to query the hints is at the very beginning of the execution, and since the algorithm cannot differentiate between the jobs, it can only query the sizes of B randomly chosen ones.

We propose a generic algorithm that queries the sizes of B randomly chosen jobs, then concurrently runs OPT on them and RR on the others with respective rates α and 1 -α , where α is a parameter that can be adjusted throughout the course of the algorithm, depending on the information available at each time, i.e the predicted job sizes, the number of the remaining jobs, and the sizes of finished jobs.

Algorithm 4: PAR Parallel algorithm with Adaptive processing Rate

In the following, for any algorithm ALG and for any subsets H,K of { 1 , . . . , N } , we denote D ALG ( H,K ) = ∑ i ∈ H ∑ j ∈ K \{ i } D ALG ( i, j ) the sum of all the delays caused by jobs in H to those in K . We demonstrate first a generic upper bound for the output of PAR ,

Lemma 4.2. For any update rule of α we have

This Lemma shows that the output of PAR depends only on the delays generated by jobs in I on jobs in J and vice versa. The difficulty now is to choose an adequate update rule for the rate α , with provable upper bounds on E [ D PAR ( I, J ) + D PAR ( J, I )] .

5

4

3

2

1

5

4

3

2

5

4

3

5

4

5

5

4

5

4

5

4

5

4

5

1

2

3

4.3 Simulated round-robin update rule

We consider the Simulated Round-Robin (SRR) update rule, which adjusts α as follows. It simply puts a global processing rate on I t , the set of unfinished jobs in I , proportional to the cardinal of I RR t , the number of unfinished jobs in I had RR be run instead (this counterfactual quantity can be computed at any time step as predictions are correct, see proof of Theorem 4.3) and similarly for J . Formally, α RR t = | I RR t | / ( | I RR t | + | J RR t | ) . Figure 4 gives an illustration of the SRR update rule: to the left, it shows a run of RR , where initially the 5 jobs run each with a processing rate 1 / 5 until job 1 terminates, then the remaining jobs run each with a processing rate of 1 / 4 until job 2 terminates, and so on. To the right, the figure shows a run of PAR with SRR update rule, where the algorithm knows the sizes of jobs 1,2 and 3. The total processing rate of these jobs during the run of the algorithm is represented by the yellow area, and it is identical to their total processing rate during the run of RR .

Theorem 4.3. If PAR uses a processing rate α RR t , then it is at most ( 2 -B ( B -1) N ( N -1) ) -competitive.

The competitive ratio of PAR with processing rate ( α RR t ) t ≥ 0 decreases as B grows, going from 2 to 1 , thus interpolating the non-clairvoyant and the clairvoyant settings.

5 Experiments

In this section, we test the performance of the algorithms we presented for the ski-rental, secretary, and scheduling problems, supporting our theoretical results and giving further insight.

0.5

0.6

0.7

0.8

0.9

1.0

accuracy

p

of the oracle

1.2

1.4

1.6

1.8

2.0

DET

RAND

0

10

20

30

40

50

time

t

of querying the prediction

1.3

1.4

1.5

1.6

1.7

1.8

1.9

2.0

Competitive ratio

Query at

t

then DET

Query at

t

then RAND

For the ski-rental problem, we set a buying cost of b = 50 for Figure 5 and b = 100 for Figure 6, and the number of snow days is sampled randomly from a uniform distribution in [1 , 4 b ] . Each point in both figures is computed over 10 5 simulations. The value of λ is chosen optimally with respect to p as indicated in Lemmas 2.2 and 2.3.

The competitive ratios of both algorithms 1 and 2 when the prediction is given as input are shown in Figure 5, as well as their theoretical upper bounds. The experimental ratio of the deterministic

algorithm in this particular scenario is significantly better than the theoretical upper bound, while that of the randomized algorithm is close to the theoretical upper bound. In Figure 6, we consider that the oracle is correct with a time-dependent probability p t = 0 . 95 -0 . 4 exp( -t/ 5) . We show the competitive ratios obtained by renting until time t then querying a prediction and running the deterministic or the randomized algorithm. The theoretical upper bounds are represented in dotted lines. We observe that adequately choosing the time of querying the prediction can significantly improve the competitive ratio, which proves our claims. This time strongly depends on the cost b and on the evolution of the probability p t with time.

0

5

10

15

20

number of allowed predictions

B

1/

e

0.5

0.6

0.7

0.8

success probability

AdaThresh

lower bound

qB

AdaThresh with memory

0

10

20

30

40

50

number of allowed predictions B

0.8

1.0

1.2

1.4

1.6

1.8

2.0

2.2

2.4

Competitive ratio

i

,

xi

=1

i

,

xi

(1)

i

,

xi

U

(0, 1)

i

,

xi

Pareto

(1.1)

In Figure 7, we test ADATHRESH with N = 1000 , and we show how the success probability improves with B . We also test a variant of the algorithm memorizing the value of the best-observed applicant after restarting, which improves the success probability (See Appendix B.3 for a detailed description of the algorithm). The success probability of ADATHRESH matches q B , therefore it is a tight lower bound. We also observe that the success probability increases rapidly for the first values of B , but then becomes slower. This is because whenever the algorithm is restarted, there is a new observation phase, with a risk of missing the best applicant.

Secondly, we test the algorithm PAR with the SRR update rule on various benchmark inputs. We test it with N = 50 and jobs having (i) identical sizes, (ii) sizes sampled from the exponential distribution, (iii) uniform distribution, (iv) and Pareto distribution. (i) is a critical instance because it is the worst-case input for RR . (ii) is a classical benchmark used in many variants of the scheduling problem to prove lower bounds [46]. (iii) is a natural benchmark to test randomness. Finally, (iv) is well-suited in practice for modeling the job size distributions [47, 29], and also it shows how the algorithm behaves on instances with very high variance. Each point in the figure was obtained by averaging over 10000 runs. we see that the competitive ratio of PAR is at most 2 -B/N for all these benchmarks, which is better than the upper bound 2 -( B/N ) 2 proved in Theorem 4.3. Therefore, PAR can be highly efficient in many cases, since the gain obtained with B known job sizes is proportional to B as shown in the simulations.

6 Conclusion

We presented different settings where online algorithms operate under a restricted budget of predictions, that can be queried during their execution. We show that adequately using this budget significantly improves upon the worst-case performance. Our results pave the way for investigating more realistic and practical challenges within the learning-augmented paradigm, providing insights that can be extended to various other problems in competitive analysis.

References

Sara Ahmadian, Hossein Esfandiari, Vahab S Mirrokni, and Binghui Peng. Robust load balancing with machine learned advice. In SODA , pages 20-34, 2022.

Keerti Anand, Rong Ge, and Debmalya Panigrahi. Customizing ml predictions for online algorithms. In International Conference on Machine Learning , pages 303-313. PMLR, 2020.

Keerti Anand, Rong Ge, Amit Kumar, and Debmalya Panigrahi. Online algorithms with multiple predictions. In International Conference on Machine Learning , pages 582-598. PMLR, 2022.

Alexandr Andoni and Daniel Beaglehole. Learning to hash robustly, guaranteed. In International Conference on Machine Learning , pages 599-618. PMLR, 2022.

Spyros Angelopoulos, Christoph Dürr, Shendan Jin, Shahin Kamali, and Marc Renault. Online computation with untrusted advice. arXiv preprint arXiv:1905.05655 , 2019.

Antonios Antoniadis, Christian Coester, Marek Eliás, Adam Polak, and Bertrand Simon. Online metric algorithms with untrusted predictions. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event , volume 119 of Proceedings of Machine Learning Research , pages 345-355. PMLR, 2020. URL http://proceedings.mlr.press/v119/antoniadis20a.html .

Antonios Antoniadis, Themis Gouleakis, Pieter Kleer, and Pavel Kolev. Secretary and online matching problems with machine learned advice. Advances in Neural Information Processing Systems , 33:7933-7944, 2020.

Antonios Antoniadis, Joan Boyar, Marek Eliáš, Lene M Favrholdt, Ruben Hoeksma, Kim S Larsen, Adam Polak, and Bertrand Simon. Paging with succinct predictions. arXiv preprint arXiv:2210.02775 , 2022.

Étienne Bamas, Andreas Maggiori, Lars Rohwedder, and Ola Svensson. Learning augmented energy minimization via speed scaling. Advances in Neural Information Processing Systems , 33:15350-15359, 2020.

Evripidis Bampis, Bruno Escoffier, and Michalis Xefteris. Canadian traveller problem with predictions. In Approximation and Online Algorithms: 20th International Workshop, WAOA 2022, Potsdam, Germany, September 8-9, 2022, Proceedings , pages 116-133. Springer, 2022.

Nikhil Bansal, Christian Coester, Ravi Kumar, Manish Purohit, and Erik Vee. Learningaugmented weighted paging. In Proceedings of the 2022 Annual ACM-SIAM Symposium on Discrete Algorithms (SODA) , pages 67-89. SIAM, 2022.

Yair Bartal, Stefano Leonardi, Alberto Marchetti-Spaccamela, Jiri Sgall, and Leen Stougie. Multiprocessor scheduling with rejection. SIAM Journal on Discrete Mathematics , 13(1):64-78, 2000.

Aditya Bhaskara, Ashok Cutkosky, Ravi Kumar, and Manish Purohit. Logarithmic regret from sublinear hints. Advances in Neural Information Processing Systems , 34:28222-28232, 2021.

Allan Borodin and Ran El-Yaniv. Online computation and competitive analysis . cambridge university press, 2005.

Justin Chen, Sandeep Silwal, Ali Vakilian, and Fred Zhang. Faster fundamental graph algorithms via learned predictions. In International Conference on Machine Learning , pages 3583-3602. PMLR, 2022.

TCE Cheng and CCS Sin. A state-of-the-art review of parallel-machine scheduling research. European Journal of Operational Research , 47(3):271-292, 1990.

Y.S. Chow, H.E. Robbins, H. Robbins, and D. Siegmund. Great Expectations: The Theory of Optimal Stopping . Houghton Mifflin, 1971. ISBN 9780395053140. URL https://books. google.fr/books?id=A6ELhyczVf4C .

Ilias Diakonikolas, Vasilis Kontonis, Christos Tzamos, Ali Vakilian, and Nikos Zarifis. Learning online algorithms with distributional advice. In International Conference on Machine Learning , pages 2687-2696. PMLR, 2021.

Michael Dinitz, Sungjin Im, Thomas Lavastida, Benjamin Moseley, and Sergei Vassilvitskii. Algorithms with prediction portfolios. arXiv preprint arXiv:2210.12438 , 2022.

Marina Drygala, Sai Ganesh Nagarajan, and Ola Svensson. Online algorithms with costly predictions. In International Conference on Artificial Intelligence and Statistics , pages 80788101. PMLR, 2023.

Elbert Du, Franklyn Wang, and Michael Mitzenmacher. Putting the 'learning" into learningaugmented algorithms for frequency estimation. In International Conference on Machine Learning , pages 2860-2869. PMLR, 2021.

Paul Dütting, Silvio Lattanzi, Renato Paes Leme, and Sergei Vassilvitskii. Secretaries with advice. In Proceedings of the 22nd ACM Conference on Economics and Computation , EC '21, page 409-429, New York, NY, USA, 2021. Association for Computing Machinery. ISBN 9781450385541. doi: 10.1145/3465456.3467623. URL https://doi.org/10.1145/ 3465456.3467623 .

Paolo Ferragina, Fabrizio Lillo, and Giorgio Vinciguerra. On the performance of learned data structures. Theoretical Computer Science , 871:107-120, 2021.

Rudolf Fleischer. On the bahncard problem. Theoretical Computer Science , 268(1):161-174, 2001.

Martin Gardner. Mathematical games. Scientific american , 222(6):132-140, 1970.

John P. Gilbert and Frederick Mosteller. Recognizing the Maximum of a Sequence , pages 355-398. Springer New York, New York, NY, 2006. ISBN 978-0-387-44956-2. doi: 10.1007/ 978-0-387-44956-2_22. URL https://doi.org/10.1007/978-0-387-44956-2_22 .

Sreenivas Gollapudi and Debmalya Panigrahi. Online algorithms for rent-or-buy with expert advice. In International Conference on Machine Learning , pages 2319-2327. PMLR, 2019.

Anupam Gupta, Debmalya Panigrahi, Bernardo Subercaseaux, and Kevin Sun. Augmenting online algorithms with ϵ -accurate predictions. Advances in neural information processing systems , 2022.

Mor Harchol-Balter and Allen B Downey. Exploiting process lifetime distributions for dynamic load balancing. ACM Transactions on Computer Systems (TOCS) , 15(3):253-285, 1997.

Sungjin Im, Ravi Kumar, Mahshid Montazer Qaem, and Manish Purohit. Online knapsack with frequency predictions. In Marc'Aurelio Ranzato, Alina Beygelzimer, Yann N. Dauphin, Percy Liang, and Jennifer Wortman Vaughan, editors, Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual , pages 2733-2743, 2021. URL https://proceedings.neurips.cc/paper/2021/hash/ 161c5c5ad51fcc884157890511b3c8b0-Abstract.html .

Sungjin Im, Ravi Kumar, Aditya Petety, and Manish Purohit. Parsimonious learning-augmented caching. In International Conference on Machine Learning , pages 9588-9601. PMLR, 2022.

Anna R Karlin, Mark S Manasse, Larry Rudolph, and Daniel D Sleator. Competitive snoopy caching. Algorithmica , 3:79-119, 1988.

Anna R. Karlin, Mark S. Manasse, Lyle A. McGeoch, and Susan Owicki. Competitive randomized algorithms for nonuniform problems. Algorithmica , 11(6):542-571, 1994.

Misha Khodak, Maria-Florina F Balcan, Ameet Talwalkar, and Sergei Vassilvitskii. Learning predictions for algorithms with predictions. Advances in Neural Information Processing Systems , 35:3542-3555, 2022.

Rohan Kodialam. Optimal algorithms for ski rental with soft machine-learned predictions. arXiv preprint arXiv:1903.00092 , 2019.

Tim Kraska, Alex Beutel, Ed H Chi, Jeffrey Dean, and Neoklis Polyzotis. The case for learned index structures. In Proceedings of the 2018 international conference on management of data , pages 489-504, 2018.

Silvio Lattanzi, Thomas Lavastida, Benjamin Moseley, and Sergei Vassilvitskii. Online scheduling via learned weights. In Proceedings of the Fourteenth Annual ACM-SIAM Symposium on Discrete Algorithms , pages 1859-1877. SIAM, 2020.

Jan Karel Lenstra and AHG Rinnooy Kan. Complexity of scheduling under precedence constraints. Operations Research , 26(1):22-35, 1978.

Honghao Lin, Tian Luo, and David Woodruff. Learning augmented binary search trees. In International Conference on Machine Learning , pages 13431-13440. PMLR, 2022.

Pinyan Lu, Xuandi Ren, Enze Sun, and Yubo Zhang. Generalized sorting with predictions. In Symposium on Simplicity in Algorithms (SOSA) , pages 111-117. SIAM, 2021.

Thodoris Lykouris and Sergei Vassilvitskii. Competitive caching with machine learned advice. Journal of the ACM (JACM) , 68(4):1-25, 2021.

Charles Martel. Preemptive scheduling with release times, deadlines, and due times. Journal of the ACM (JACM) , 29(3):812-829, 1982.

Tomomi Matsui and Katsunori Ano. Lower bounds for bruss' odds problem with multiple stoppings. Mathematics of Operations Research , 41(2):700-714, 2016.

Adam Meyerson. The parking permit problem. In 46th Annual IEEE Symposium on Foundations of Computer Science (FOCS'05) , pages 274-282. IEEE, 2005.

Michael Mitzenmacher. Queues with small advice. In SIAM Conference on Applied and Computational Discrete Algorithms (ACDA21) , pages 1-12. SIAM, 2021.

Rajeev Motwani, Steven Phillips, and Eric Torng. Nonclairvoyant scheduling. Theoretical computer science , 130(1):17-47, 1994.

Manish Purohit, Zoya Svitkina, and Ravi Kumar. Improving online algorithms via ML predictions. In Samy Bengio, Hanna M. Wallach, Hugo Larochelle, Kristen Grauman, Nicolò Cesa-Bianchi, and Roman Garnett, editors, Advances in Neural Information Processing Systems 31: Annual Conference on Neural Information Processing Systems 2018, NeurIPS 2018, December 3-8, 2018, Montréal, Canada , pages 9684-9693, 2018.

Alexander Wei and Fred Zhang. Optimal robustness-consistency trade-offs for learningaugmented online algorithms. Advances in Neural Information Processing Systems , 33:80428053, 2020.

Ali Zeynali, Bo Sun, Mohammad Hajiesmaili, and Adam Wierman. Data-driven competitive algorithms for online knapsack and set cover. In Proceedings of the AAAI Conference on Artificial Intelligence , volume 35, pages 10833-10841, 2021.

Advice Querying under Budget Constraint for Online Algorithms

Omitted proofs

A Ski-rental with time-dependent guarantees on the prediction

A.1 Proof of Lemma 2.1

Proof. In all the following, We denote A ( I ) the output of algorithm A when given an input instance I . We will prove the claim of the lemma by treating separately the cases where x ≥ b and x < b . Let us first observe that, if x ≥ t , then the cost of ALG t is t + ALG ( x -t, b, Q t ) , because a unit cost was paid during the first t days, and then ALG is called provided with a prediction Q t . The number of remaining snow days at that time is x -t . We remind that, since we are in a minimization problem, C ( ALG , p t ) is at least 1. Consider the case where x ≤ b , thus OPT ( x, b ) = x . If x ≤ t then ALG t ( x, b ) = x = OPT ( x, b ) , and if x > t then

Consider now that x > b , thus OPT ( x, b ) = b . If x ≤ t then

On the other hand, if x > t then

In all the cases we have E [ ALG t ( x, b )] ≤ ( t/b + C ( ALG , p t )) OPT ( x, b ) , which gives the result.

A.2 Proof of Lemma 2.2

Proof. Let us denote ALG ( x, b, Q ) the output of Algorithm 1 given an instance x, b and a prediction Q , and OPT ( x, b ) = min { x, b } the cost of the optimal offline algorithm. Purohit et al. [47] prove that, if the algorithm is given instead a prediction y of x , then sets Q = 1 ( y ≥ b ) and behaves as we described, then its competitive ratio is upper bounded by min { 1 + 1 λ , (1 + λ ) + | x -y | (1 -λ ) OPT ( x,b ) } . But in fact, it suffices to have x and y both larger or both smaller than b for the algorithm to behave exactly as if x = y , therefore we retrieve the bound 1 + λ if the prediction Q is accurate. This happens with probability p . Otherwise, when the prediction is incorrect, we always have that

ALG ( x, b, Q ) ≤ (1 + 1 /λ ) OPT

the latter expression is minimized for λ = √ 1 -p p , which gives

A.3 Proof of Lemma 2.3

Proof. Let λ ∈ (1 /b, 1) . It is shown in [47] that Algorithm 2 is ( λ 1 -e -λ ) -consistent and ( 1 1 -e -( λ -1 /b ) ) -robust. Even though the upper bound shown in [47] suggests that the consistency bound is achieved only when given an exactly accurate prediction y of the number of snow days, i.e. y = x , it suffices to have Q = 1 ( x ≥ b ) for the algorithm to behave just the same. Therefore, with probability p we have that the cost of the algorithm is at most ( λ 1 -e -λ ) OPT ( x, b ) , and with probability 1 -p it is at most ( 1 1 -e -( λ -1 /b ) ) OPT ( x, b ) . With a simple function analysis, we have that 1 1 -e -u ≤ 1 e -1 + 1 u for any u ∈ (0 , 1) . Therefore

The previous expression is minimized when λ satisfies p ( λ -1 /b ) e -1 = 1 -p ( λ -1 /b ) , i.e. for λ ⋆ = 1 b + √ ( e -1) 1 -p p . However, we are restrained to choose λ ∈ (1 /b, 1) , thus the optimal choice of λ is min { 1 , λ ⋆ } . We have that

Therefore, if p ≥ ( 1 + (1 -1 /b ) 2 e -1 ) -1 , then with λ = λ ⋆ we have

and if p < ( 1 + (1 -1 /b ) 2 e -1 ) -1 , then with λ = 1 we obtain

B Secretary problem with B predictions

B.1 Proof of Theorem 3.1

Proof. Since the secretary problem is purely ordinal, and since the applicants arrive in a uniformly random order, the success probability of ADATHRESH does not depend on the values x 1 , . . . , x N , but only on B and N . Therefore, we denote q N,B the success probability of ADATHRESH with a budget B and an input sequence of size N , t ⋆ the position of the best applicant, x s : t = ( x s , . . . , x t ) for any s ≤ t , S ( x 1: N , B ) the event that ADATHRESH with a budget B succeeds on the input x 1: N , and R B = r B N . We define the random variable

We will prove the claim of the theorem by induction on B .

For B = 0 , it is established that for r 0 = 1 / e , we have a success probability of at least q 0 = 1 / e . Let B ≥ 1 , and assume that the result is true for B -1 , we have

For any t , since the oracle Q is error-free, then under τ = t , we have that Q ( x t ) = 0 is equivalent to t ⋆ = t , and Q ( x t ) = 0 is equivalent to t ⋆ > t , thus we have

where 4 is true because the event S ( x 1: N , B ) is implied by τ = t ⋆ , the second equality because t ⋆ is a uniform random variable in { 1 , . . . , N } , and 5 because, conditionally to t ⋆ = t , the event τ = t is equivalent to not selecting any candidate in x R B +1: t -1 , i.e all those candidates have smaller values than max x 1: R B , which is equivalent to saying that the maximum element in x 1: t -1 is among the first R B ones, and this is independent of the event t = t ⋆ . On the other hand, we have that

Conditionally to { τ = t, Q ( x t ) = 1 } , x t is the best candidate up to step t , and ADATHRESH used a prediction to observe that t ⋆ > t , The algorithm is therefore restarted with input x t +1 ,N and budget B , and S ( x 1: N , B ) = S ( x t +1: N , B -1) , which is independent of the history up to step t , hence

by the induction hypothesis. Secondly, we have that the two following events are equivalent

and since the applicants are shuffled uniformly at random, the relative ranks inside any subset Y of { x 1 , . . . , x N } are independent of how max Y compares to applicants outside Y , therefore

which gives

Using 4 and 7 we deduce that

and substituting into 3 gives that

since R B < r B N +1 , we have that log( N/ ( R B -1)) ≥ log(1 /r B ) , and

It follows that

The left term of this inequality is maximal for r B = exp ( -1 1 -q B -1 ) , and we obtain that

which concludes the proof.

B.2 Proof of Theorem 3.2

The algorithm Consider a simple adaptation of ADATHRESH, where the predictions are not always blindly trusted. If the conditions t ≥ r B N and x t > max { x 1 , . . . , x t -1 } are met, then with probability 1 -λ the algorithm chooses to query a prediction and trust it, and with probability λ it chooses to select the candidate x t without querying a prediction.

We will prove Theorem 3.2 using two lemmas. In the first one, we show the lower bound on the success probability of the algorithm we presented, and in the second one, we compute the limit of this lower bound when B →∞ . We define the function f : [0 , 1] → (0 , ∞ ) by f (1) = 1 and for x ∈ (0 , 1)

Lemma B.1. The adapted ADATHRESH with budget B has a success probability at least q B ( p ) , where q 0 ( p ) = 1 /e and for any B ≥ 1

Moreover, if p ≤ ( ef (1 /e )) -1 then for any B we have q B ( p ) = 1 /e , and otherwise q B ( p ) = pf ( q B -1 ( p )) for any B ≥ 1 .

Proof. The success probability when B = 0 is lower bounded by 1 /e . Let B ≥ 1 and assume that the success probability of this algorithm given a budget B -1 is lower bounded by some constant q B -1 ( p ) that is independent of N , if the algorithm chooses to trust the prediction, then if it inaccurate the algorithm fails with probability 1, and if it is accurate, which happens with a probability p , then similarly to (8) in the proof of Theorem 3.1, the success probability is lower bounded by

On the other hand, if the algorithm chooses not to trust the prediction, then its success probability is lower bounded by 1 /e . Therefore, if we denote q N,B ( p, λ ) the success probability of the algorithm on an instance of size N , given a budget B of predictions that are each accurate with an independent probability p , then we have

The left term is maximized for r B = exp ( -1 1 -q B -1 ( p ) ) , and it gives

this is a linear function of λ , and it is maximized for

With this choice of λ , we have that the success probability q N,B ( p, λ ) is lower bounded by the constant q B ( p ) defined by

Before showing the second claim of the lemma, let us first prove that f is increasing. We do this simply by computing its derivative

which is positive because exp( u ) > u +1 for any u > 1 , in particular for u = 1 / (1 -x ) .

Now, if pf (1 /e ) ≤ 1 /e , i.e. p ≤ ( ef (1 /e )) -1 = ( 1 + ( e -1) exp( -e e -1 ) ) -1 , since f is increasing, we have by induction for any B ≥ 0 that q B ( p ) = 1 /e . In fact, it is true for B = 0 , and if q B -1 ( p ) = 1 /e then pf ( q B -1 ( p )) = pf (1 /e ) ≤ 1 /e , thus q B ( p ) = 1 /e .

On the other hand, if pf (1 /e ) > 1 /e , then for any B ≥ 1 we have that pf ( q B -1 ( p )) > 1 /e and thus q B ( p ) = pf ( q B -1 ( p )) . In fact, the property is true for B = 1 , and if it is true for some B ≥ 1 then q B ( p ) = pf ( q B -1 ( p )) > 1 /e , thus pf ( q B ( p )) ≥ pf (1 /e ) > 1 /e , the property remains true for B +1 , which concludes the induction.

Lemma B.2. If p > ( ef (1 /e )) -1 , then the sequence q B ( p ) is increasing and

where W is the inverse of u → ue u on [0 , ∞ ) , called the W-Lambert function .

Proof. Assume that p > ( ef (1 /e )) -1 , let us prove by induction over B ≥ 1 that q B ( p ) > q B -1 ( p ) . For B = 1 we have that q 1 ( p ) = pf (1 /e ) > 1 /e = q 0 ( p ) by the assumption on p . Now, let B ≥ 1 and assume that q B ( p ) > q B -1 ( p ) . Since f is an increasing function on [0 , 1] , we have that

The sequence ( q B ( p )) B ≥ 0 is therefore increasing and it is upper bounded by 1 since it is a lower bound on a probability. We deduce that it converges to some limit ℓ that depends on p . Since f is continuous we have that ℓ = pf ( ℓ ) , solving this equation gives

Observe that the algorithm we presented can also be adapted to the case where the accuracy p of the oracle is not constant and might depend on the time or even on the input sequence. In fact, as long as the accuracy of the oracle is known to the algorithm, it can trust the oracle if it is correct with a probability larger than ( ef (1 /e ) -1 , and ignore if otherwise. This gives a success probability always lower bounded by 1 /e , with better guarantees depending on the accuracy of the oracle at times when it is queried.

B.3 ADATHRESH with memory

We present now an improved version of ADATHRESH that keeps in memory the best observed value so far, and that rejects all applicants below this value.

Algorithm 5: ADATHRESH with memory

Initially, the algorithm is launched with M = -∞ . While we do not give theoretical guarantees on the success probability of Algorithm 5, we show experimentally how it compares to Algorithm 3 in Section 5.

C Preemptive B -clairvoyant job scheduling

C.1 Proof of Theorem 4.1

Proof. Let ALG be any non-clairvoyant algorithm that can query up to B job sizes for instances of N jobs. It is shown in Theorem 2.8 in [46] that by choosing an input instance E n of n job sizes sampled independently from the exponential distribution, any algorithm A verifies

with E [ OPT ( E n )] = n + n ( n +1) / 4 . Let us consider in particular the algorithm A N which, when given an instance J of n ≤ N jobs, samples N -n positive numbers z 1 , . . . , z N -n from the exponential distribution, then runs ALG with the input J ∪{ z i } N -n i =1 . Let us denote A N ( J|{ z i } N -n i =1 ) the output of A N conditionally to { z i } N -n i =1 . Now, let E be an instance of N job sizes chosen from the exponential distribution to be given as input for ALG . During its execution, ALG will query a number b ≤ B of sizes for jobs in some subset I of { 1 , . . . , N } . Denoting J = { 1 , . . . , N } \ I , we have by Equation 1 that

In expectation, using that | J | ≥ N -B = N -o ( N ) with probability 1, we obtain

Using again that E [ OPT ( E )] = N + N ( N -1) / 4 = N 2 / 4 + O ( N ) , we deduce that E [ ALG ( E )] E [ OPT ( E )] ≥ 2 + o (1) , which shows that the competitive ratio of ALG is at least 2 .

C.2 Intermediate Lemma and notation

Notations In all the following, we fix an instance J of job sizes x 1 ≤ . . . ≤ x N , and we denote σ a uniformly random permutation of { 1 , . . . , N } , I = { σ ( i ) } B i =1 and J = { σ ( j ) } N j = B +1 . This is equivalent to choosing a set I of B jobs uniformly at random without replacement. We also denote I t and J t respectively the sets of unfinished jobs in I and J at time t of a run of PAR .

The next lemma gives a simple computational result that we will use in further proofs.

̸

Proof. Since σ is a random permutation, we only need to demonstrate the result for i, j = 1 , 2 . Since we assume that x 1 ≤ . . . , x N , then for any k ≤ N we have

It follows that

C.3 Proof of Lemma 4.2

Proof. Let us fix some update rule for α . In the execution of PAR , OPT is run on I and RR on J , and both sets are disjoint, therefore we have D PAR ( i, j ) = D OPT ( i, j ) for any i = j ∈ I , and D PAR ( i, j ) = D RR ( i, j ) for any i = j ∈ J , we can write

̸

Using Equation 2 and Lemma C.1, we have that

and in the same way

Summing these two equations gives

and taking the expectation in Equation 9 concludes the proof.

C.4 Proof of Theorem 4.3

We use here the same notations as in Section 4.3. Before demonstrating the theorem, let us justify why ( α RR t ) t can be computed online, i.e for any t > 0 , α RR t can be computed knowing only the events that occurred up to time t .

For any subset K of { 1 , . . . , N } , we denote RR ( K ) the algorithm that runs RR on { x i } i ∈ K and ignores the other jobs. Running RR on all the input instance is equivalent to running concurrently RR ( I ) and RR ( J ) with respective rates ( α RR t ) t and (1 -α RR t ) t . In fact, for any t > 0 , the processing rate of any unfinished job in I is α RR t | I RR t | = 1 | I RR t | + | J RR t | , and we have the same for jobs in J .

Consider running RR on { x 1 , . . . , x N } . We denote t RR i the completion time of job 1 ≤ i ≤ N . For any t > 0 , the amount of RR ( I ) executed until time t is ∫ t 0 α RR u du . Therefore if we denote T RR i ( I ) the completion time of job i ∈ I when running RR ( I ) , then we have

̸

Knowing the sizes of jobs in I , T RR i ( I ) can be computed as

̸

We deduce that PAR with SRR update rule can be implemented running concurrently OPT ( I ) and RR ( J ) with respective rates α RR and 1 -α RR , where the processing rate updates as follows: initialize c ( I ) = B , c ( J ) = N -B and α RR = c ( I ) c ( I )+ c ( J ) = B N , and for any t > 0 ,

(i) if a job in J terminates, then c ( J ) ← c ( J ) -1 ,

(ii) if T RR i ( I ) = ∫ t 0 α RR u du for some i ∈ I , then c ( I ) ← c ( I ) -1 ,

and in both cases update α RR = c ( I ) c ( I )+ c ( J ) .

Proof of Theorem 4.3. Using the processing rate ( α RR t ) t> 0 , the delays generated by I on J are exactly the same as if RR was running, and the delays by J on I are smaller than RR 's, because OPT ( I ) runs with the same processing rate as RR ( I ) but all the jobs finish earlier, thus using Lemma C.1 we deduce that

Using Lemma 4.2 then Equation 2 we obtain

Which proves the theorem.

Peer reviews:
{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThis paper considers learning augmented online algorithms where there is a bound on the number of predictions that can be queried.  Three problems are considered within this framework: Ski-rental, Secretary Problem, and Non-clairvoyant scheduling.\n\nFor the ski-rental problem, they consider a model where the algorithm can make noisy queries of the form \"$x-t  > b$?\", where $t$ is the current day.  The output of the query is a binary value which is correct independently with probability $p_t$, and the sequence $p_t$ is known up front to the algorithm.  Modifying ideas from Purohit et al. NeurIPS 2018, they give deterministic and randomized algorithms whose competitive ratio improve as the probability of correctness approaches 1 and are never worse than 2 and $e/(e-1)$, respectively.\n\nFor the secretary problem, they again consider predictions which are correct with probability $p$, but the algorithm can only query the predictions at most $B$ times.  Here the prediction is a binary prediction of whether or not the current item has the highest value in the sequence.  They give an algorithm which selects the best item with probability $1/e$ and improves as the probability $p$ increases.\n\nFor non-clairvoyant scheduling, the paper defines the problem of $B$-clairvoyant scheduling, in which the scheduler can query the exact sizes of $B \\leq N$ jobs.  For this they show that $B = \\Omega(N)$ queries are necessary to improve the competitive ratio below 2 which is met by the round robin algorithm in the non-clairvoyant setting.  To complement this they give an algorithm with competitive ratio $2-B(B-1)/(N(N-1))$, which gives an interpolation between the non-clairvoyant and fully-clairvoyant settings.\n\nFinally, a short experiment section which tests the proposed algorithms on synthetic data is provided.\n\nSTRENGTHS:\nWith the recent interest in learning-augmented algorithms/algorithms with predictions there has been recent interest in studying the extent to which such algorithms need to access to many predictions in order to achieve better than worst case results, so the considered problems are well motivated.\n\nThe results on the secretary problem and non-clairvoyant job scheduling are interesting.  In particular, the lower bound (Theorem 4.1) holds even in the case where the predictions match the ground truth.  The overall result presents a clean interpolation between the clairvoyant and completely non-clairvoyant settings.\n\nWEAKNESSES:\n- For the ski-rental result, the authors claim that they give an algorithm which chooses the best time to query the prediction based on the sequence $p_t$ (lines 79-80).  From what is presented in Section 2. it is not at all clear that they do this.  At best, there is an example for a specific sequence of $p_t$'s, but I don't see a general argument.\n\n - In terms of novelty, the techniques for ski-rental and non-clairvoyant scheduling can be viewed as extensions of the ideas presented in Purohit et al. NeurIPS 2018.  \n\n- There is a disconnect between the first two sections (ski-rental, secretary) and the third (scheduling).  For the first two the predictions are only correct with some probability while for the scheduling result the queries return exact job size values.  A more unified framework would make the paper significantly cleaner.\n\n - Aside from the scheduling result, the authors do not give evidence for the tightness of their results.\n\n- The experiments mostly confirm what is predicted by the theory and don't seem to say much else.  Experiments on real data would alleviate this and also provide more evidence for the assumption that predictions are correct independently with some known probability.\n\nQUESTIONS:\n- Concerning the lower bound for B-clairvoyant scheduling (Theorem 4.1), I think one of the references at the beginning of the proof is wrong.  For the lower bound of any possibly randomized algorithm against jobs independently sampled from an exponential distribution, the reference should be for Theorem 2.8 in [44] (not [45]).\n\n- There is other recent work which considers learning-augmented online algorithms with limited querying.  See the following:\n     - Im, S., Kumar, R., Petety, A., Purohit, M.. (2022). Parsimonious Learning-Augmented Caching. Proceedings of the 39th International Conference on Machine Learning, in Proceedings of Machine Learning Research 162:9588-9601 Available from https://proceedings.mlr.press/v162/im22a.html.\n\n- For ski-rental and the secretary problem, this paper considers predictions which are correct independently with some probability $p$.  A similar model has also been considered recently for caching and online covering problems.  See the following:\n    - Gupta, Anupam and Panigrahi, Debmalya and Subercaseaux, Bernardo and Sun, Kevin.   Augmenting Online Algorithms $\\varepsilon$-Accurate Predictions.  Advances in Neural Information Processing Systems 2022.\n\n- For the experiments on $B$-clairvoyant scheduling, it seems it would be natural to consider exponentially distributed job sizes, since those witness the lower bound for Theorem 4.1.\n\n- For the ski-rental and secretary problem results, is it possible to give any general lower bounds for the competitive ratio of any algorithm?  For the ski-rental result this could help to alleviate the concerns the authors raise with using the simpler strategy over the optimal strategy which is difficult to analyze.\n\n- Please use proper capitalization for the title and section titles.\n\nLIMITATIONS:\nThis paper is mostly theoretical in nature, so any possible limitations are inherent in the assumptions and theorem statements which have been stated clearly (and thus addressed by the authors).", "TITLE": "Official Review", "RECOMMENDATION": 5, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 2, "DATE": "2023-07-04"}

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThe paper studies learning-augmented algorithms in a setting where predictions are a scarce resource and algorithms need to decide when to request them. The framework is instantiated over (i) ski-rental with a single prediction, (ii) the secretary problem with B predictions, (iii) preemptive non-clairvoyant scheduling with B perfectly accurate predictions. The article mainly presents upper bounds for these problems.\n\nSTRENGTHS:\n- The paper is really well-written\n- The framework is well-motivated and likely to inspire further work\n- The results are nice and non-trivial\n- Proofs (as far as I checked) in the supplementary material seem to be correct\n- Experimental figures help understanding the parameters in the results (e.g., roles of $b$ or $p$)\n\nWEAKNESSES:\nNo major weaknesses, so I'll point some relatively minor ones.\n\n1) It's unclear how novel the setting is and I think the paper could be more straightforward about this; the authors provide a section on related work, but while they mention the setting is relatively unexplored, there are examples of the setting that they provide as well as others they don't seem to cite like \"Parsimonious Learning-Augmented Caching\" by Im et al. The abstract of the paper, as well the introduction page, give me the feeling that the authors are presenting the setting itself as a contribution, whereas it seems that setting is not itself novel and the contribution is about the specific results for specific problems presented (which is not minor).\n\n2) On Algorithm 2 I think it would be nicer to write \"buy on the start of day $d \\in ...$ with probability proportional to $(1-1/b)^{\\lfloor \\lambda b \\rfloor - d}$.\n\n3) The results (i.e., theorem statements) could be phrased in terms of consistency/robustness more explicitly.\n\n4) As usual I printed the paper on black-and-white, and the figures are not great in this respect -- consider for example Figure 1, where the lines only differ by color. I suggest using either some pattern (dashed, dotted, etc, (Figure 2 does a bit of this, but it can still be improved)). Granted this is not an issue on a computer screen, but it's worth considering too for accessibility reasons (colorblind readers, etc.)\n\n5) The scheduling problem setting is a bit weird as the predictions are assumed to be perfect, and thus said problem doesn't really fit the learning-augmented framework, only the budget-constrained aspect. It would be more solid if the paper considered predictions with a parametric quality.\n\n6) It seems that the predictions considered are always in terms of their probability of being correct rather than on a notion of error (as in Lykouris and Vassilvitskii), which fits the framework of (https://openreview.net/forum?id=HFkxZ_V0sBQ), and seems appropriate to cite.\n\nQUESTIONS:\nFor the ski-rental problem, did you consider what happens if one has B predictions that are independent? An interesting thing that might happen is that two general strategies appear to be in conflict: (1) Spend the B predictions at the beginning to have as good as possible an initial prediction, due to the independence assumption. (2) Wait until predictions unfold (i.e., are confirmed or refuted by reality) and when the season continues spend more predictions to sort of recursively reset the state imagining the season just started.\n\nLIMITATIONS:\nThey're not really addressed, although I don't see an issue in the particular case of this paper as there doesn't seem to be much to address anyway.", "TITLE": "Official Review", "RECOMMENDATION": 8, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 4, "DATE": "2023-07-05"}

comments: SUMMARY:
Authors consider ML-augmented algorithms with a limited number of predictions.
They consider three problems: ski rental, secretary, and non-clairvoyant
scheduling. Their result on non-clairvoyant scheduling assumes perfect
predictions, while for ski rental and secretary problems they assume
knowledge of the predictors success probability in advance.
This implicitly assumes that the input has a particular structure or comes from
a distribution where the predictors achieve the declared success probability.
In case of the secretary problem, they also discuss the case when an incorrect
value of p is provided to the algorithm. I have not noticed such a discussion
in the case of ski rental.
It is not clear whether the performance bounds achieved by their algorithms
are tight.

STRENGTHS:
technically sound results

WEAKNESSES:
* absence of lower bounds for ski rental and secretary
* only perfect predictions for scheduling
* not clear how should we know the success probability of the predictor

QUESTIONS:
* there is a paper by Antoniadis et al. Learning-Augmented  Dynamic Power Management with Multiple States via New Ski Rental Bounds (NeurIPS 2021) which, as a special case, solves a sequence of ski rental instances, learning the precision of the predictor online. Can you relate somehow to their results?
* I appreciate Figure 2 showing your competitive ratio in a natural setting. However, it looks like your ratio is never better than e/(e-1). What precision do you need to achieve meaningful improvement?
* There is a paper by Im et al. Parsimonious Learning-Augmented Caching (ICML 2022) -- might be also worth mentioning in your related work.

LIMITATIONS:
theorems state their assumptions clearly
TITLE: Official Review
SOUNDNESS_CORRECTNESS: 3
DATE: 2023-07-06

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nIn this paper the authors re-consider classic online optimization problems in the area of learning-augmented algorithms, under the setting where the algorithms that have access to a limited number of predictions. Additionally, the setting that is considered assumes that as the algorithm progresses the predictions become more accurate. Three problems are studied under this model: 1) the ski-rental problem, 2) secretary problem, and 3) job scheduling problem. Each of these problems considers problem-specific advice, and the authors show that given correct advice they can significantly outperform the worst-case bounds from the non-learning-augmented model.\n\nThe main motivation for this work is that the advice can be very costly, and one cannot always assume access to unlimited calls to the learned advice. Hence, it becomes relevant to ask what are the best-possible bounds that one can obtain under this limited budget setting. \n\nWhile the paper is mainly interesting for its theoretical contributions, the authors additionally ran simulations showing that the algorithms behave according to the theoretical results. Also for the secretary problem the authors show a heuristic variation of the suggested algorithm that performs better than the theoretical lower bound.\n\nSTRENGTHS:\n+ Considers an interesting setting where the algorithm has a limited access to an oracle, and in one where the probability of correct advice increases over time. Although, it is not clear how to motivate the very restricted access (why would it be restricted if it comes from a model). \n\n+ A nice set of results for each of the three problems considered.\n\nWEAKNESSES:\n- Some advice and assumptions seem a bit unrealistic. Specifically, the advice on the size of the jobs in the job scheduling problem assumes that the advice is always correct but it is not clearly justified. Additionally, to tune the algorithms for the ski-rental problem, one needs to have knowledge of the probability of a correct prediction over time.\n\nQUESTIONS:\n- For the Secretary problem, it is not clear what it means that \"assuming that the predictions are error-free, the problem is equivalent to the multiple-choice secretary problem\". In the setting of the paper, the algorithm has to additionally choose whether to select the secretary or keep searching.\n\n- The algorithm for the ski-rental problem assumes the knowledge of the success probability. Is this something realistic?\n\n- L226: \"The previous theorem shows that, with well-chosen thresholds for querying the predictions, strong theoretical guarantees on ADATHRESH can be obtained\". This is not obvious and should be explained.\n\n- Explain how the memorization variant of the algorithm for the secretary problem works.\n\n- No discussion on the experiment for the ski-rental problem. \n\n- Don't know how to read figure 4. Please explain.\n\n- Report standard deviation for the plot with the scheduling problem.\n\nLIMITATIONS:\nN/A", "TITLE": "Official Review", "RECOMMENDATION": 7, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 4, "DATE": "2023-07-06"}