Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

Bandit Algorithms

51 missions · 33 completed

Missions

Open18Completed33All51
🏆Completed
Machine LearningOperations Research·Captain: Shuze Chen

Bandit Algorithms I: Concentration of MeasureTextbook

How quickly does the empirical mean of independent random variables concentrate around the true mean? This question is the analytic engine of the entire theory of stochastic bandits: every optimistic algorithm (Explore-Then-Commit, UCB and its relatives) is calibrated by a tail bound on the sample mean. This mission formalizes the subgaussian framework of Chapter 5 of Lattimore–Szepesvári's Bandit Algorithms: a random variable XXX is σ\sigmaσ-subgaussian when E[eλX]≤eλ2σ2/2\mathbb{E}[e^{\lambda X}] \le e^{\lambda^2\sigma^2/2}E[eλX]≤eλ2σ2/2 for all λ\lambdaλ, and the Cramér–Chernoff method converts this moment-generating-function control into the exponential tail P(X≥ε)≤e−ε2/(2σ2)\mathbb{P}(X \ge \varepsilon) \le e^{-\varepsilon^2/(2\sigma^2)}P(X≥ε)≤e−ε2/(2σ2). The goal theorem is the Hoeffding-type bound: the sample mean of nnn independent σ\sigmaσ-subgaussian deviations exceeds the true mean by ε\varepsilonε with probability at most exp⁡(−nε2/(2σ2))\exp(-n\varepsilon^2/(2\sigma^2))exp(−nε2/(2σ2)), together with its confidence form P(μ^+2σ2log⁡(1/δ)/n≤μ)≤δ\mathbb{P}\big(\hat\mu + \sqrt{2\sigma^2\log(1/\delta)/n} \le \mu\big) \le \deltaP(μ^​+2σ2log(1/δ)/n​≤μ)≤δ — the exact bound every UCB index is built from. These few lines of analysis are cited by every regret bound in the series.

2 thms3 active usersReviewed
🏆Completed
Machine LearningOperations ResearchStatistics·Captain: mikedeng1

Optimal Best Arm Identification with Fixed Confidence II: Characterization of the Optimal Proportions of Arm DrawsResearch Paper

Motivation

In best arm identification with fixed confidence, a learner samples KKK unknown distributions ("arms") sequentially and must name the arm with the largest mean, with error probability at most a prescribed δ\deltaδ, using as few samples as possible. Garivier and Kaufmann (arXiv:1602.04589, COLT 2016) showed that every δ\deltaδ-PAC strategy needs, in expectation, at least T∗(μ) kl(δ,1−δ)T^*(\boldsymbol\mu)\,\mathrm{kl}(\delta,1-\delta)T∗(μ)kl(δ,1−δ) samples, where the characteristic time T∗(μ)T^*(\boldsymbol\mu)T∗(μ) is the value of a max–min optimization problem over the proportions of draws allocated to the arms. The maximizer of that problem, w∗(μ)w^*(\boldsymbol\mu)w∗(μ), is the allocation any asymptotically optimal strategy must follow; the Track-and-Stop algorithm of the same paper computes w∗(μ^)w^*(\hat{\boldsymbol\mu})w∗(μ^​) at plug-in estimates and tracks it.

A strategy can only track w∗w^*w∗ if w∗w^*w∗ can be computed. This mission formalizes the part of the paper (Section 2.2 and Appendix A) that turns the abstract max–min problem into an explicit recipe: a closed form for the inner infimum, and a characterization of w∗w^*w∗ through the root of one increasing scalar function. The problem had been solved in closed form before only for special cases, such as Poisson rewards with all suboptimal arms equal (Vaidhyan and Sundaresan, 2015); the paper's result covers every one-parameter exponential family.

Setting

A canonical one-parameter exponential family is a family of laws νθ\nu_\thetaνθ​, θ∈Θ\theta\in\Thetaθ∈Θ, on R\mathbb RR with density exp⁡(θx−b(θ))\exp(\theta x-b(\theta))exp(θx−b(θ)) with respect to a reference measure ξ\xiξ. The law νθ\nu_\thetaνθ​ has mean b˙(θ)\dot b(\theta)b˙(θ); the set of attainable means is the mean space b˙(Θ)\dot b(\Theta)b˙(Θ). For means μ=b˙(θ)\mu=\dot b(\theta)μ=b˙(θ) and μ′=b˙(θ′)\mu'=\dot b(\theta')μ′=b˙(θ′) the Kullback–Leibler divergence is

d(μ,μ′)=KL(νθ,νθ′)=b(θ′)−b(θ)−b˙(θ)(θ′−θ).d(\mu,\mu')=\mathrm{KL}(\nu_\theta,\nu_{\theta'})=b(\theta')-b(\theta)-\dot b(\theta)(\theta'-\theta).d(μ,μ′)=KL(νθ​,νθ′​)=b(θ′)−b(θ)−b˙(θ)(θ′−θ).

Bernoulli laws and Gaussian laws with known variance are the standard examples.

A bandit model is identified with its vector of means μ=(μ1,…,μK)∈b˙(Θ)K\boldsymbol\mu=(\mu_1,\dots,\mu_K)\in\dot b(\Theta)^Kμ=(μ1​,…,μK​)∈b˙(Θ)K. S\mathcal SS is the set of models with a unique optimal arm a∗(μ)a^*(\boldsymbol\mu)a∗(μ), and Alt(μ)={λ∈S:a∗(λ)≠a∗(μ)}\mathrm{Alt}(\boldsymbol\mu)=\{\boldsymbol\lambda\in\mathcal S:a^*(\boldsymbol\lambda)\ne a^*(\boldsymbol\mu)\}Alt(μ)={λ∈S:a∗(λ)=a∗(μ)} is the set of alternatives. ΣK\Sigma_KΣK​ is the probability simplex. The transportation cost of proportions w∈ΣKw\in\Sigma_Kw∈ΣK​ and the objects of the paper are

cμ(w)=inf⁡λ∈Alt(μ)∑a=1Kwa d(μa,λa),T∗(μ)−1=sup⁡w∈ΣKcμ(w),w∗(μ)=argmax⁡w∈ΣKcμ(w).c_{\boldsymbol\mu}(w)=\inf_{\boldsymbol\lambda\in\mathrm{Alt}(\boldsymbol\mu)}\sum_{a=1}^Kw_a\,d(\mu_a,\lambda_a),\qquad T^*(\boldsymbol\mu)^{-1}=\sup_{w\in\Sigma_K}c_{\boldsymbol\mu}(w),\qquad w^*(\boldsymbol\mu)=\operatorname*{argmax}_{w\in\Sigma_K}c_{\boldsymbol\mu}(w).cμ​(w)=λ∈Alt(μ)inf​a=1∑K​wa​d(μa​,λa​),T∗(μ)−1=w∈ΣK​sup​cμ​(w),w∗(μ)=w∈ΣK​argmax​cμ​(w).

The arms are sorted so that μ1>μ2≥⋯≥μK\mu_1>\mu_2\ge\dots\ge\mu_Kμ1​>μ2​≥⋯≥μK​. The parameterized Jensen–Shannon divergence is, for α∈[0,1]\alpha\in[0,1]α∈[0,1],

Iα(μ1,μ2)=α d(μ1,αμ1+(1−α)μ2)+(1−α) d(μ2,αμ1+(1−α)μ2).I_\alpha(\mu_1,\mu_2)=\alpha\,d\big(\mu_1,\alpha\mu_1+(1-\alpha)\mu_2\big)+(1-\alpha)\,d\big(\mu_2,\alpha\mu_1+(1-\alpha)\mu_2\big).Iα​(μ1​,μ2​)=αd(μ1​,αμ1​+(1−α)μ2​)+(1−α)d(μ2​,αμ1​+(1−α)μ2​).

For a∈{2,…,K}a\in\{2,\dots,K\}a∈{2,…,K} let ga(x)=(1+x)I1/(1+x)(μ1,μa)g_a(x)=(1+x)I_{1/(1+x)}(\mu_1,\mu_a)ga​(x)=(1+x)I1/(1+x)​(μ1​,μa​) for x≥0x\ge0x≥0, let xa=ga−1x_a=g_a^{-1}xa​=ga−1​, and let x1≡1x_1\equiv1x1​≡1. Finally

Fμ(y)=∑a=2Kd(μ1,ma(y))d(μa,ma(y)),ma(y)=μ1+xa(y)μa1+xa(y).F_{\boldsymbol\mu}(y)=\sum_{a=2}^K\frac{d\big(\mu_1,m_a(y)\big)}{d\big(\mu_a,m_a(y)\big)},\qquad m_a(y)=\frac{\mu_1+x_a(y)\mu_a}{1+x_a(y)}.Fμ​(y)=a=2∑K​d(μa​,ma​(y))d(μ1​,ma​(y))​,ma​(y)=1+xa​(y)μ1​+xa​(y)μa​​.

Formalization targets

Goal: Theorem 5 (p. 5)

With D=d(μ1,μ2)D=d(\mu_1,\mu_2)D=d(μ1​,μ2​): FμF_{\boldsymbol\mu}Fμ​ is continuous and strictly increasing on [0,D[[0,D[[0,D[, Fμ(0)=0F_{\boldsymbol\mu}(0)=0Fμ​(0)=0, Fμ(y)→∞F_{\boldsymbol\mu}(y)\to\inftyFμ​(y)→∞ as y→Dy\to Dy→D, the equation Fμ(y)=1F_{\boldsymbol\mu}(y)=1Fμ​(y)=1 has a unique solution y∗∈[0,D[y^*\in[0,D[y∗∈[0,D[, and

w∈w∗(μ)  ⟺  wa=xa(y∗)∑i=1Kxi(y∗)for every arm a.w\in w^*(\boldsymbol\mu)\iff w_a=\frac{x_a(y^*)}{\sum_{i=1}^Kx_i(y^*)}\quad\text{for every arm }a.w∈w∗(μ)⟺wa​=∑i=1K​xi​(y∗)xa​(y∗)​for every arm a.

The equivalence says at once that the argmax exists, that it is a single point, and that it is given by eq. (5).

Milestones

  1. Lemma 3 (p. 5): for every w∈ΣKw\in\Sigma_Kw∈ΣK​,
cμ(w)=min⁡a≠1(w1+wa) Iw1w1+wa(μ1,μa).c_{\boldsymbol\mu}(w)=\min_{a\ne1}(w_1+w_a)\,I_{\frac{w_1}{w_1+w_a}}(\mu_1,\mu_a).cμ​(w)=a=1min​(w1​+wa​)Iw1​+wa​w1​​​(μ1​,μa​).
  1. Claim after eq. (4) (p. 5): gag_aga​ is a strictly increasing one-to-one mapping from [0,+∞[[0,+\infty[[0,+∞[ onto [0,d(μ1,μa)[[0,d(\mu_1,\mu_a)[[0,d(μ1​,μa​)[.
  2. Lemma 4 (p. 5): for every maximizer w∗w^*w∗ and all a,b∈{2,…,K}a,b\in\{2,\dots,K\}a,b∈{2,…,K},
(w1∗+wa∗)Iw1∗w1∗+wa∗(μ1,μa)=(w1∗+wb∗)Iw1∗w1∗+wb∗(μ1,μb).(w^*_1+w^*_a)I_{\frac{w^*_1}{w^*_1+w^*_a}}(\mu_1,\mu_a)=(w^*_1+w^*_b)I_{\frac{w^*_1}{w^*_1+w^*_b}}(\mu_1,\mu_b).(w1∗​+wa∗​)Iw1∗​+wa∗​w1∗​​​(μ1​,μa​)=(w1∗​+wb∗​)Iw1∗​+wb∗​w1∗​​​(μ1​,μb​).

Significance

The result. Theorem 5 reduces a (K−1)(K-1)(K−1)-dimensional non-smooth max–min problem to finding the root of one continuous increasing function on a bounded interval, each evaluation of which requires K−1K-1K−1 scalar inversions. It gives existence and uniqueness of w∗(μ)w^*(\boldsymbol\mu)w∗(μ), which the paper's lower bound only presupposes, and it is the computational core of Track-and-Stop: without an explicit, well-posed w∗w^*w∗ the tracking strategy is not defined. Lemma 3 alone gives the closed form of the inner infimum used again in the analysis of the stopping rule.

Formalizing it. The results are proved in the paper; nothing here is open. To the best of our knowledge none of them has a machine-checked proof: the platform's existing best-arm-identification rows concern Gaussian arms and state the characteristic time at the level of measures, without this characterization. The mission produces a checked reduction for general one-parameter exponential families, including the edge cases the text passes over (ties among suboptimal arms, zero weights, the behaviour of xax_axa​ near the end of its domain).

Difficulty

The infimum in Lemma 3 ranges over Alt(μ)\mathrm{Alt}(\boldsymbol\mu)Alt(μ), a set of models with a unique best arm, so it is an open condition: the minimizing configuration, in which λ1\lambda_1λ1​ and λa\lambda_aλa​ coincide, lies outside Alt(μ)\mathrm{Alt}(\boldsymbol\mu)Alt(μ) and is only approached. Other arms may also compete for the best position. A statement in which the infimum is taken over the closed relaxation {λa≥λ1}\{\lambda_a\ge\lambda_1\}{λa​≥λ1​} is a lemma of the proof, not Lemma 3.

For Theorem 5, the equalization in Lemma 4 needs an argument that holds for every maximizer, not only for one found by a first-order condition, because the objective is a minimum of functions and is not differentiable. The monotonicity of FμF_{\boldsymbol\mu}Fμ​ needs the monotonicity of each xax_axa​ and of each ratio in the moving point mam_ama​, and the limit at DDD rests on the second-best arm(s) only, which is where the ordering μ1>μ2≥…\mu_1>\mu_2\ge\dotsμ1​>μ2​≥… enters. Finally the analytic facts about ddd (continuity, positivity off the diagonal, monotonicity in each argument) must be derived from the exponential family itself.

Formalization scope

Lean represents a model by μ : Fin K → ℝ with 2 ≤ K and every μ a in the mean space deriv F.b '' F.Θ. The paper's arm 111 is index 0, arm 222 is index 1. The exponential family is a structure ExpFamily whose parameter set is a nonempty open interval and whose b is twice continuously differentiable with b¨>0\ddot b>0b¨>0 on Θ\ThetaΘ. These two conditions are added to the paper's "convex, twice differentiable" and are disclosed: strict convexity is what makes the mean parameterization unique, and openness is what lets alternatives approach the boundary of Alt(μ)\mathrm{Alt}(\boldsymbol\mu)Alt(μ). The reference measure and normalization are part of the structure but unused here.

The transportation cost is an infimum in EReal, so it is the true infimum of the set of values rather than a default 0. w∗(μ)w^*(\boldsymbol\mu)w∗(μ) is never defined by choice: "www is optimal" is a predicate, and Theorem 5 characterizes the set of such www. The functions xax_axa​ are the inverse of gag_aga​ on [0,+∞[[0,+\infty[[0,+∞[ and are evaluated only on [0,d(μ1,μ2)[[0,d(\mu_1,\mu_2)[[0,d(μ1​,μ2​)[. "Increasing" in Theorem 5 is stated as strictly increasing, as proved in Appendix A.2. Lemmas 3 and 4 and the claim on gag_aga​ assume only that arm 111 is the unique best arm, which is weaker than the paper's standing ordering.

A formalization that replaces Alt(μ)\mathrm{Alt}(\boldsymbol\mu)Alt(μ) by {λa≥λ1}\{\lambda_a\ge\lambda_1\}{λa​≥λ1​}, assumes the maximizer exists and is unique, or asserts only existence of some y∗y^*y∗ without the formula for w∗w^*w∗, does not state these results and is ruled out.

A complete development needs: basic calculus of exponential families (the Bregman form of ddd, its continuity and strict positivity off the diagonal, its monotonicity in the second argument), the inverse function of a continuous strictly monotone map on an interval, and compactness of the simplex. The divergence facts are reusable in every bandit mission built on exponential families. Proofs of the milestones, of auxiliary facts about ddd and IαI_\alphaIα​, and a sorry-free instance of ExpFamily (Bernoulli or unit-variance Gaussian) are welcome.

Selected references

  • A. Garivier, E. Kaufmann, Optimal Best Arm Identification with Fixed Confidence, COLT 2016 (JMLR W&CP 49), arXiv:1602.04589v2. https://arxiv.org/abs/1602.04589
  • E. Kaufmann, O. Cappé, A. Garivier, On the Complexity of Best-Arm Identification in Multi-Armed Bandit Models, JMLR 17, 2016. https://arxiv.org/abs/1407.4443
  • N. K. Vaidhyan, R. Sundaresan, Learning to detect an oddball target, arXiv:1508.05572, 2015. https://arxiv.org/abs/1508.05572
  • O. Cappé, A. Garivier, O.-A. Maillard, R. Munos, G. Stoltz, Kullback–Leibler upper confidence bounds for optimal sequential allocation, Annals of Statistics 41(3), 2013. https://arxiv.org/abs/1210.1136
6 thms2 active usersReviewed
🏆Completed
Machine LearningOptimization·Captain: mikedeng1

Taming the Monster: A Fast and Simple Algorithm for Contextual Bandits II: The Iteration Bound of Coordinate DescentResearch Paper

Motivation

In the contextual bandit problem a learner repeatedly observes a context, picks one of KKK actions, and sees the reward of that action only. Against a finite class Π\PiΠ of policies, statistically optimal regret of order KTln⁡∣Π∣\sqrt{KT\ln|\Pi|}KTln∣Π∣​ has been known since EXP4 (Auer et al., 2002), but EXP4 maintains a weight per policy and costs Ω(∣Π∣)\Omega(|\Pi|)Ω(∣Π∣) time per round. For the large policy classes used in practice (linear classifiers, trees), that is prohibitive.

The oracle-efficient line of work accesses Π\PiΠ only through a cost-sensitive classification oracle (an arg max oracle, AMO). The RandomizedUCB algorithm of Dudík et al. (2011) obtains optimal regret with polynomially many oracle calls by solving a convex program in each round, but the number of calls is large. Agarwal, Hsu, Kale, Langford, Li and Schapire (2014) replace that solver by a coordinate descent method whose number of iterations, and hence of oracle calls, is bounded independently of ∣Π∣|\Pi|∣Π∣. Their algorithm, ILOVETOCONBANDITS, and its practical variant are now standard references for oracle-based exploration.

This mission formalizes the optimization half of that paper: Algorithm 2 solves the per-epoch problem (OP) after at most 4ln⁡(1/(Kμ))/μ4\ln(1/(K\mu))/\mu4ln(1/(Kμ))/μ coordinate steps.

Setting

Let A={0,…,K−1}A=\{0,\dots,K-1\}A={0,…,K−1} be the actions, XXX any set of contexts, and Π⊆AX\Pi\subseteq A^XΠ⊆AX a finite nonempty set of policies. A history HtH_tHt​ is a sequence of t≥1t\ge1t≥1 records (xi,ai,ri(ai),pi(ai))(x_i,a_i,r_i(a_i),p_i(a_i))(xi​,ai​,ri​(ai​),pi​(ai​)) with ri(ai)∈[0,1]r_i(a_i)\in[0,1]ri​(ai​)∈[0,1] the observed reward and pi(ai)∈(0,1]p_i(a_i)\in(0,1]pi​(ai​)∈(0,1] the probability with which aia_iai​ was chosen. Write E^x∼Ht[f(x)]=1t∑if(xi)\widehat{\mathbb E}_{x\sim H_t}[f(x)]=\frac1t\sum_i f(x_i)Ex∼Ht​​[f(x)]=t1​∑i​f(xi​).

The inverse propensity scoring estimate (Eq. (1)) is

R^t(π)=1t∑i=1tri(ai) 1{π(xi)=ai}pi(ai),\widehat{\mathcal R}_t(\pi)=\frac1t\sum_{i=1}^t\frac{r_i(a_i)\,\mathbb 1\{\pi(x_i)=a_i\}}{p_i(a_i)},Rt​(π)=t1​i=1∑t​pi​(ai​)ri​(ai​)1{π(xi​)=ai​}​,

the estimated regret is Reg^t(π)=max⁡π′∈ΠR^t(π′)−R^t(π)\widehat{\mathrm{Reg}}_t(\pi)=\max_{\pi'\in\Pi}\widehat{\mathcal R}_t(\pi')-\widehat{\mathcal R}_t(\pi)Reg​t​(π)=maxπ′∈Π​Rt​(π′)−Rt​(π), and for a minimum probability μ\muμ one sets bπ=Reg^t(π)/(ψμ)b_\pi=\widehat{\mathrm{Reg}}_t(\pi)/(\psi\mu)bπ​=Reg​t​(π)/(ψμ) with ψ=100\psi=100ψ=100.

Weights are vectors Q∈RΠQ\in\mathbb R^\PiQ∈RΠ; ΔΠ\Delta^\PiΔΠ is the set of nonnegative QQQ with ∑πQ(π)≤1\sum_\pi Q(\pi)\le1∑π​Q(π)≤1. The smoothed projection of QQQ is

Qμ(a∣x)=(1−Kμ)∑π: π(x)=aQ(π)+μ.Q^\mu(a\mid x)=(1-K\mu)\sum_{\pi:\ \pi(x)=a}Q(\pi)+\mu .Qμ(a∣x)=(1−Kμ)π: π(x)=a∑​Q(π)+μ.

The optimization problem (OP) asks for Q∈ΔΠQ\in\Delta^\PiQ∈ΔΠ with

∑π∈ΠQ(π)bπ≤2K(2),E^x∼Ht[1Qμ(π(x)∣x)]≤2K+bπ  ∀π∈Π(3).\sum_{\pi\in\Pi}Q(\pi)b_\pi\le2K\quad(2),\qquad \widehat{\mathbb E}_{x\sim H_t}\Bigl[\frac1{Q^\mu(\pi(x)\mid x)}\Bigr]\le2K+b_\pi\ \ \forall\pi\in\Pi\quad(3).π∈Π∑​Q(π)bπ​≤2K(2),Ex∼Ht​​[Qμ(π(x)∣x)1​]≤2K+bπ​  ∀π∈Π(3).

Algorithm 2 starts from QinitQ_{\mathrm{init}}Qinit​ and loops. With Vπ(Q)=E^[1/Qμ(π(x)∣x)]V_\pi(Q)=\widehat{\mathbb E}[1/Q^\mu(\pi(x)\mid x)]Vπ​(Q)=E[1/Qμ(π(x)∣x)], Sπ(Q)=E^[1/Qμ(π(x)∣x)2]S_\pi(Q)=\widehat{\mathbb E}[1/Q^\mu(\pi(x)\mid x)^2]Sπ​(Q)=E[1/Qμ(π(x)∣x)2] and Dπ(Q)=Vπ(Q)−(2K+bπ)D_\pi(Q)=V_\pi(Q)-(2K+b_\pi)Dπ​(Q)=Vπ​(Q)−(2K+bπ​): if ∑πQ(π)(2K+bπ)>2K\sum_\pi Q(\pi)(2K+b_\pi)>2K∑π​Q(π)(2K+bπ​)>2K it rescales QQQ by c=2K/∑πQ(π)(2K+bπ)c=2K/\sum_\pi Q(\pi)(2K+b_\pi)c=2K/∑π​Q(π)(2K+bπ​) (Eq. (4)); then, if some π\piπ has Dπ(Q)>0D_\pi(Q)>0Dπ​(Q)>0, it adds

απ(Q)=Vπ(Q)+Dπ(Q)2(1−Kμ)Sπ(Q)\alpha_\pi(Q)=\frac{V_\pi(Q)+D_\pi(Q)}{2(1-K\mu)S_\pi(Q)}απ​(Q)=2(1−Kμ)Sπ​(Q)Vπ​(Q)+Dπ​(Q)​

to Q(π)Q(\pi)Q(π) (Step 8) and repeats; otherwise it halts and outputs QQQ.

The analysis uses the potential (Eq. (6)), with τ=t\tau=tτ=t and UA\mathcal U_AUA​ uniform on AAA,

Φm(Q)=τμ(E^x[RE(UA ∥ Qμ(⋅∣x))]1−Kμ+∑πQ(π)bπ2K),RE(p∥q)=∑a(paln⁡paqa+qa−pa).\Phi_m(Q)=\tau\mu\left(\frac{\widehat{\mathbb E}_x[\mathrm{RE}(\mathcal U_A\,\|\,Q^\mu(\cdot\mid x))]}{1-K\mu}+\frac{\sum_\pi Q(\pi)b_\pi}{2K}\right),\qquad \mathrm{RE}(p\|q)=\sum_a\bigl(p_a\ln\tfrac{p_a}{q_a}+q_a-p_a\bigr).Φm​(Q)=τμ(1−KμEx​[RE(UA​∥Qμ(⋅∣x))]​+2K∑π​Q(π)bπ​​),RE(p∥q)=a∑​(pa​lnqa​pa​​+qa​−pa​).

Formalization targets

Goal: Theorem 3 (p. 6)

For 0<μ≤1/(2K)0<\mu\le1/(2K)0<μ≤1/(2K), Algorithm 2 with Qinit=0Q_{\mathrm{init}}=\mathbf 0Qinit​=0 satisfies: every run executes Step 8 at most

4ln⁡(1/(Kμ))μ\frac{4\ln(1/(K\mu))}{\mu}μ4ln(1/(Kμ))​

times, whatever policy each Step 8 chooses among those with Dπ>0D_\pi>0Dπ​>0; and when it halts, its output solves (OP). The bound depends on KμK\muKμ only, not on ∣Π∣|\Pi|∣Π∣ or ttt.

Milestones

  1. Lemma 5 (p. 10). If Algorithm 2 halts and outputs QQQ, then QQQ satisfies (2), (3) and ∑πQ(π)≤1\sum_\pi Q(\pi)\le1∑π​Q(π)≤1.
  2. Lemma 6 (p. 10). If ∑πQ(π)(2K+bπ)>2K\sum_\pi Q(\pi)(2K+b_\pi)>2K∑π​Q(π)(2K+bπ​)>2K and ccc is as in Eq. (4), then Φm(cQ)≤Φm(Q)\Phi_m(cQ)\le\Phi_m(Q)Φm​(cQ)≤Φm​(Q).
  3. Lemma 7 (p. 10). If Dπ(Q)>0D_\pi(Q)>0Dπ​(Q)>0 and Q′Q'Q′ adds απ(Q)\alpha_\pi(Q)απ​(Q) to Q(π)Q(\pi)Q(π), then
Φm(Q)−Φm(Q′)≥τμ24(1−Kμ).\Phi_m(Q)-\Phi_m(Q')\ge\frac{\tau\mu^2}{4(1-K\mu)}.Φm​(Q)−Φm​(Q′)≥4(1−Kμ)τμ2​.

Significance

The result. Theorem 3 is what makes ILOVETOCONBANDITS computationally efficient: each call of Algorithm 2 is implemented with one AMO call per iteration (Lemma 1 of the paper), so the oracle complexity of an epoch is O(ln⁡(1/(Kμ))/μ)O(\ln(1/(K\mu))/\mu)O(ln(1/(Kμ))/μ). Combined with the epoch schedule and warm start, this gives the paper's total of O~(KT/ln⁡(∣Π∣/δ))\tilde O(\sqrt{KT/\ln(|\Pi|/\delta)})O~(KT/ln(∣Π∣/δ)​) oracle calls over TTT rounds. Theorem 3 also gives a constructive proof that (OP) is feasible for every history, which the regret analysis (a separate mission in this series) assumes.

Formalizing it. The result is proved in the paper, with complete proofs of Lemmas 5–7 in Appendix D. No machine-checked version is known. The formalization would give a checked termination bound for a coordinate descent method on a non-smooth feasibility problem, with a fully explicit constant, and a verified definition of the unnormalized relative entropy potential that is reusable for other smoothed-projection analyses (e.g. RandomizedUCB-type convex programs).

Difficulty

Termination cannot be read off the constraints. Step 8 raises one weight and can push the total weight above 1, after which Step 5 shrinks every coordinate, so no constraint and no single weight moves monotonically along a run. The number of policies that violate (3) can also go up after a step. Bounding the number of iterations therefore needs a global quantity that tracks progress through both kinds of step. The rescaling step is the harder of the two: it lowers every Qμ(a∣x)Q^\mu(a\mid x)Qμ(a∣x) at once, which pushes the relative-entropy term the wrong way, and it must be offset by the drop in the regret term. Knowing that (OP) is feasible, or that some convex function has a minimizer, bounds nothing about how many steps a particular method takes; that is the obvious approach, and it gives no count.

Formalization scope

  • Actions are Fin K with K≥1K\ge1K≥1; contexts form an arbitrary type (no measure is needed: Theorem 3 is deterministic). Π\PiΠ is a nonempty Finset (X → Fin K); weights are real functions on its subtype.
  • Histories are indexed by Fin t with t≥1t\ge1t≥1 (0-based indices). The paper allows pi(ai)∈[0,1]p_i(a_i)\in[0,1]pi​(ai​)∈[0,1]; the formalization requires pi(ai)∈(0,1]p_i(a_i)\in(0,1]pi​(ai​)∈(0,1], since Eq. (1) divides by it.
  • Reg^t(π)\widehat{\mathrm{Reg}}_t(\pi)Reg​t​(π) is written as max⁡π′R^t(π′)−R^t(π)\max_{\pi'}\widehat{\mathcal R}_t(\pi')-\widehat{\mathcal R}_t(\pi)maxπ′​Rt​(π′)−Rt​(π), which equals R^t(πt)−R^t(π)\widehat{\mathcal R}_t(\pi_t)-\widehat{\mathcal R}_t(\pi)Rt​(πt​)−Rt​(π) for any maximizer πt\pi_tπt​; ψ=100\psi=100ψ=100 is hard-wired in bπb_\pibπ​.
  • QμQ^\muQμ, VπV_\piVπ​, SπS_\piSπ​, (OP) and Φm\Phi_mΦm​ all use the smoothed projection of the unnormalized weights; there is no default policy in this mission.
  • μ\muμ ranges over (0,1/(2K)](0,1/(2K)](0,1/(2K)], the range of μm\mu_mμm​ in Algorithm 1 that the printed theorem refers to. τ\tauτ in Φm\Phi_mΦm​ is the history length ttt.
  • Algorithm 2 is encoded relationally. A run of length nnn from QinitQ_{\mathrm{init}}Qinit​ is a sequence Q(0)=Qinit,…,Q(n)Q^{(0)}=Q_{\mathrm{init}},\dots,Q^{(n)}Q(0)=Qinit​,…,Q(n) in which each Q(k+1)Q^{(k+1)}Q(k+1) is Step 8, for some policy with Dπ>0D_\pi>0Dπ​>0, applied to the rescaled Q(k)Q^{(k)}Q(k). It halts at Q(n)Q^{(n)}Q(n) when no policy has Dπ>0D_\pi>0Dπ​>0 after rescaling, and it then outputs the rescaled Q(n)Q^{(n)}Q(n). "Iterations" means executions of Step 8. The last pass, which halts at Step 10, is not counted: the paper's proof bounds "the number of times Step 8 is executed". The bound is compared in R\mathbb RR, without rounding.
  • Lemmas 5–7 are stated for nonnegative weight vectors without a bound on their sum, because Algorithm 2 rescales vectors whose sum may exceed 1. Lemma 7's "α=απ(Q)>0\alpha=\alpha_\pi(Q)>0α=απ​(Q)>0" is part of its conclusion.
  • A trivializing formalization is ruled out: the goal quantifies over every run from 0\mathbf 00 and every choice in Step 8, not over some run, and the potential, bπb_\pibπ​ and DπD_\piDπ​ are computed from the history rather than taken as free parameters.
  • The auxiliary facts Φm≥0\Phi_m\ge0Φm​≥0 and Φm(0)≤τμln⁡(1/(Kμ))/(1−Kμ)\Phi_m(\mathbf 0)\le\tau\mu\ln(1/(K\mu))/(1-K\mu)Φm​(0)≤τμln(1/(Kμ))/(1−Kμ) are inline claims in the paper and are not stated separately; contributions stating and proving them are welcome, as are general lemmas on the unnormalized relative entropy.
  • Out of scope: the regret bound (Theorem 2) and the probabilistic model (mission I of this series), the AMO implementation (Lemma 1), warm start and epoch-level oracle counts (Lemmas 2, 3, 8), and the support lower bound (Theorem 4).

Selected references

  • A. Agarwal, D. Hsu, S. Kale, J. Langford, L. Li, R. E. Schapire, Taming the Monster: A Fast and Simple Algorithm for Contextual Bandits, ICML 2014; arXiv:1402.0555v2. https://arxiv.org/abs/1402.0555
  • M. Dudík, D. Hsu, S. Kale, N. Karampatziakis, J. Langford, L. Reyzin, T. Zhang, Efficient Optimal Learning for Contextual Bandits, UAI 2011. https://arxiv.org/abs/1106.2369
  • P. Auer, N. Cesa-Bianchi, Y. Freund, R. E. Schapire, The Nonstochastic Multiarmed Bandit Problem, SIAM J. Comput. 32(1), 2002. https://doi.org/10.1137/S0097539701398375
7 thms2 active usersReviewed
🏆Completed
Machine LearningOperations ResearchProbability·Captain: mikedeng1

Stochastic Linear Optimization under Bandit Feedback 2: A Regret Lower Bound on the CircleResearch Paper

Motivation

In stochastic linear optimization under bandit feedback a learner repeatedly chooses a point xtx_txt​ from a compact decision set D⊂RnD\subset\mathbb R^nD⊂Rn and observes only the random cost ℓt\ell_tℓt​ of that point, whose mean is μ⋅xt\mu\cdot x_tμ⋅xt​ for an unknown vector μ\muμ. The problem models online routing, ad placement and other sequential decisions with linearly structured costs. The quality of a learner is measured by its regret against the best fixed decision.

For the KKK-armed bandit the achievable regret for a fixed instance is logarithmic in the horizon TTT (Lai and Robbins 1985; Auer, Cesa-Bianchi and Fischer 2002). Dani, Hayes and Kakade (COLT 2008) showed that for linear costs the picture depends on the geometry of DDD. Their Theorem 1 gives polylogarithmic regret when the decision set has a positive gap between the best and second-best extreme point (a polytope, for instance), and their Theorem 2 gives O∗(nT)O^*(n\sqrt T)O∗(nT​) regret for every decision set. Their Theorem 3 shows that the second rate cannot be improved in general: on a decision set with zero gap, every algorithm pays Ω(T)\Omega(\sqrt T)Ω(T​) in expectation.

Timeline:

  • 2002: Auer, Using confidence bounds for exploitation–exploration trade-offs (JMLR 3), introduces confidence-bound algorithms for linear bandits on finite decision sets.
  • 2008: Dani, Hayes and Kakade prove the O∗(nT)O^*(n\sqrt T)O∗(nT​) upper bound for ConfidenceBall₂ and the Ω(T)\Omega(\sqrt T)Ω(T​) lower bound on a product of circles, the subject of this mission. A hypercube lower bound for the adversarial setting appears in their NIPS 2007 paper.
  • 2010: Rusmevichientong and Tsitsiklis, Linearly parameterized bandits (Math. OR 35), give Ω(nT)\Omega(n\sqrt T)Ω(nT​) lower bounds on the unit sphere.
  • 2020: Lattimore and Szepesvári, Bandit Algorithms, Theorems 24.1 and 24.2, give minimax lower bounds on the hypercube and the unit ball with Gaussian noise.

Setting

The decision set is the unit circle D2=S1={x∈R2:x12+x22=1}D_2=S^1=\{x\in\mathbb R^2: x_1^2+x_2^2=1\}D2​=S1={x∈R2:x12​+x22​=1}. An unknown mean vector μ∈R2\mu\in\mathbb R^2μ∈R2 is drawn once, uniformly from the circle D2/2D_2/2D2​/2 of radius 1/21/21/2; concretely μ=μ(θ)=12(cos⁡θ,sin⁡θ)\mu=\mu(\theta)=\tfrac12(\cos\theta,\sin\theta)μ=μ(θ)=21​(cosθ,sinθ) with θ\thetaθ uniform on [0,2π)[0,2\pi)[0,2π).

On each round t=1,…,Tt=1,\dots,Tt=1,…,T the algorithm plays xt∈D2x_t\in D_2xt​∈D2​ and observes a cost ℓt∈{−1,+1}\ell_t\in\{-1,+1\}ℓt​∈{−1,+1} with Pr⁡(ℓt=+1)=(1+μ⋅xt)/2\Pr(\ell_t=+1)=(1+\mu\cdot x_t)/2Pr(ℓt​=+1)=(1+μ⋅xt​)/2, so that E[ℓt]=μ⋅xt\mathbb E[\ell_t]=\mu\cdot x_tE[ℓt​]=μ⋅xt​. Given the decision, the cost is independent of the past.

An algorithm may be randomised. It draws a seed sss once from a probability measure ρ\rhoρ on a measurable space SSS, and chooses xtx_txt​ as a function of sss and the costs ℓ1,…,ℓt−1\ell_1,\dots,\ell_{t-1}ℓ1​,…,ℓt−1​ observed so far, measurably in sss.

The regret over TTT rounds is

R=∑t=1T(μ⋅xt−μ⋅x∗),μ⋅x∗=min⁡x∈D2μ⋅x,R=\sum_{t=1}^T(\mu\cdot x_t-\mu\cdot x^*),\qquad \mu\cdot x^*=\min_{x\in D_2}\mu\cdot x,R=t=1∑T​(μ⋅xt​−μ⋅x∗),μ⋅x∗=x∈D2​min​μ⋅x,

so each round costs rt=μ⋅xt+12≥0r_t=\mu\cdot x_t+\tfrac12\ge0rt​=μ⋅xt​+21​≥0 when ∥μ∥=1/2\|\mu\|=1/2∥μ∥=1/2. The expected regret ER=Eμ E(R∣μ)\mathbb E R=\mathbb E_\mu\,\mathbb E(R\mid\mu)ER=Eμ​E(R∣μ) averages over the seed, the prior and the costs.

In the Lean development these objects are unitCircle, meanVec, optCost, RandomizedPolicy and expectedRegret in the namespace StochLinOpt.LowerBound.

Formalization targets

Goal: Theorem 3 for n=2n=2n=2

There is a universal constant c>0c>0c>0 such that for every randomised algorithm and every T≥1T\ge1T≥1,

ER ≥ cT.\mathbb E R\ \ge\ c\sqrt T.ER ≥ cT​.

The constant is left existential, which is the form that survives any later improvement of the constant; it is chosen before the algorithm and before TTT.

Milestones

  1. Section 6.1, Eq. (3). For ∥μ1∥=∥μ2∥=1/2\|\mu_1\|=\|\mu_2\|=1/2∥μ1​∥=∥μ2​∥=1/2, x∈S1x\in S^1x∈S1, a posterior probability p∈[0,1]p\in[0,1]p∈[0,1] of μ=μ1\mu=\mu_1μ=μ1​ and a cost ℓ∈{±1}\ell\in\{\pm1\}ℓ∈{±1}, the Bayes-updated bias bt+1b_{t+1}bt+1​ satisfies ∣bt+1−bt∣≤∣(μ1−μ2)⋅x∣|b_{t+1}-b_t|\le|(\mu_1-\mu_2)\cdot x|∣bt+1​−bt​∣≤∣(μ1​−μ2​)⋅x∣, where bt=2p−1b_t=2p-1bt​=2p−1.
  2. Lemma 15. With ε=∥μ1−μ2∥>0\varepsilon=\|\mu_1-\mu_2\|>0ε=∥μ1​−μ2​∥>0 and the same data,
Eμ(rt∣Ht)≥116(ε2+∣bt+1−bt∣2ε2)1{∣bt∣≤1/2}.\mathbb E_\mu(r_t\mid\mathcal H_t)\ge\frac1{16}\Big(\varepsilon^2+\frac{|b_{t+1}-b_t|^2}{\varepsilon^2}\Big)\mathbf 1\{|b_t|\le1/2\}.Eμ​(rt​∣Ht​)≥161​(ε2+ε2∣bt+1​−bt​∣2​)1{∣bt​∣≤1/2}.
  1. Theorem 4 (Freedman). For a martingale difference sequence X1,…,XTX_1,\dots,X_TX1​,…,XT​ bounded above by bbb, with conditional variance sum VVV, and all a,v>0a,v>0a,v>0,
Pr⁡(∑iXi≥a, V≤v)≤exp⁡(−a22v+2ab/3).\Pr\Big(\sum_i X_i\ge a,\ V\le v\Big)\le\exp\Big(\frac{-a^2}{2v+2ab/3}\Big).Pr(i∑​Xi​≥a, V≤v)≤exp(2v+2ab/3−a2​).

Significance

The lower bound shows that the T\sqrt TT​ dependence of the problem-independent upper bound (Theorem 2 of the same paper) is necessary. It also shows that the gap-dependent polylogarithmic rate of Theorem 1 cannot extend to decision sets without a gap, such as the sphere. Together with the upper bound it characterises the minimax regret of stochastic linear bandits in TTT up to logarithmic factors, and in the paper's general-nnn form it also underlies the claim that the price of bandit information is Θ∗(n)\Theta^*(\sqrt n)Θ∗(n​).

The result is proved in the paper for n=2n=2n=2 and has not been machine-checked. The mission produces a checked Bayesian lower bound over all randomised algorithms, with an explicit probability model for the protocol. Two related platform results are different theorems: BanditAlgorithm.linear_bandit_unit_ball_minimax_lower_bound (Lattimore–Szepesvári Theorem 24.2: unit ball, Gaussian noise, a worst-case μ\muμ) and BanditAlgorithm.linear_bandit_hypercube_minimax_lower_bound (Theorem 24.1: hypercube). The {−1,+1}\{-1,+1\}{−1,+1} costs, the circle and the uniform prior used here are not covered by either.

Difficulty

The obvious attempt is a two-point change-of-measure argument with a fixed pair of means at distance ε\varepsilonε. It fails as stated because the decision set has no gap: an algorithm that plays close to the optimum of both candidates learns slowly but also pays little. The per-round trade-off between regret and information (Lemma 15) is exact only while the posterior is undecided, ∣bt∣≤1/2|b_t|\le1/2∣bt​∣≤1/2. Turning it into a bound on the whole horizon requires controlling how long the posterior stays undecided, which is a statement about a martingale whose step sizes are chosen by the algorithm; a concentration bound that ignores the accumulated conditional variance (Azuma–Hoeffding with worst-case steps) is too weak for this. The averaging step from a two-point prior to the uniform prior on the circle is also part of the formal work.

Formalization scope

Vectors are Fin 2 → ℝ with the dot product ⬝ᵥ; Euclidean norms are written through dot products, never with Lean's sup norm. Rounds are 0-indexed internally: the Lean index ttt is the paper's round t+1t+1t+1. The expected regret is the exact finite expectation

ER=∫S12π∫02π∑ℓ∈{±1}T∏t=1T1+ℓt μ(θ)⋅xt2  R  dθ dρ(s),\mathbb E R=\int_S\frac1{2\pi}\int_0^{2\pi}\sum_{\ell\in\{\pm1\}^T}\prod_{t=1}^T\frac{1+\ell_t\,\mu(\theta)\cdot x_t}{2}\;R\;d\theta\,d\rho(s),ER=∫S​2π1​∫02π​ℓ∈{±1}T∑​t=1∏T​21+ℓt​μ(θ)⋅xt​​Rdθdρ(s),

so no infinite product of measures is needed. A randomised algorithm is a seeded policy, which covers every randomised algorithm. The optimal cost is the infimum of μ⋅x\mu\cdot xμ⋅x over the compact circle and is attained. Every junk value in the model (a non-integrable integrand) could only make the lower bound harder to prove, never easier.

A statement over deterministic algorithms only, over a worst-case μ\muμ instead of the uniform prior, or with the constant allowed to depend on the algorithm or on TTT would be a weaker theorem. The goal quantifies ∃c>0\exists c>0∃c>0 before the algorithm and TTT, and fixes the prior.

Corrections relative to the printed paper:

  • General nnn is not stated. Theorem 3 as printed claims ER≥110nT\mathbb E R\ge\frac1{10}n\sqrt TER≥101​nT​ for every even nnn. It is false for n>10n>10n>10: on DnD_nDn​ with μ∈Dn/n\mu\in D_n/nμ∈Dn​/n each round has regret at most 111, so at T=1T=1T=1 the claim would need ER≥n/10>1\mathbb E R\ge n/10>1ER≥n/10>1. The general case rests on Lemma 16, which has no proof. The goal is the n=2n=2n=2 case, which Section 6.1 proves.
  • The constant. For n=2n=2n=2 the paper prints 15T\frac15\sqrt T51​T​; its proof gives c=116min⁡(12−1e,164)=11024c=\frac1{16}\min(\frac12-\frac1e,\frac1{64})=\frac1{1024}c=161​min(21​−e1​,641​)=10241​. The proof's Freedman step prints 2exp⁡(−1/41/8+ε/3)≤2/e22\exp(-\frac{1/4}{1/8+\varepsilon/3})\le 2/e^22exp(−1/8+ε/31/4​)≤2/e2; with v=1/32v=1/32v=1/32 the denominator is 1/16+ε/31/16+\varepsilon/31/16+ε/3, and the bound 2/e22/e^22/e2 then needs ε=T−1/4≤3/16\varepsilon=T^{-1/4}\le3/16ε=T−1/4≤3/16. Small TTT is covered by the first round, whose expected regret is 1/21/21/2. The goal leaves ccc existential.
  • Theorem 4. The printed variance sum runs to nnn; it runs to TTT. The conditioning is on a general filtration, and square-integrability of the steps is assumed so that the conditional variance is defined.
  • Lemma 15. Its right side depends on the round-ttt cost ℓt\ell_tℓt​, which is not part of Ht\mathcal H_tHt​; the Lean statement holds for either value of ℓt\ell_tℓt​.

Welcome contributions: a Lean proof of Freedman's inequality (reusable across the bandit and concentration missions on the platform); the averaging argument from two-point priors to the uniform prior; and the stopped-martingale bookkeeping for the bias sequence.

Selected references

  • Varsha Dani, Thomas P. Hayes, Sham M. Kakade, Stochastic Linear Optimization under Bandit Feedback, Proceedings of the 21st Annual Conference on Learning Theory (COLT), 2008.
  • David A. Freedman, On tail probabilities for martingales, The Annals of Probability 3(1):100–118, 1975. https://doi.org/10.1214/aop/1176996452
  • Colin McDiarmid, Concentration, in Probabilistic Methods for Algorithmic Discrete Mathematics, Springer, 1998. https://doi.org/10.1007/978-3-662-12788-9_6
  • Peter Auer, Using confidence bounds for exploitation–exploration trade-offs, JMLR 3:397–422, 2002. https://www.jmlr.org/papers/v3/auer02a.html
  • Paat Rusmevichientong, John N. Tsitsiklis, Linearly parameterized bandits, Mathematics of Operations Research 35(2):395–411, 2010. https://doi.org/10.1287/moor.1100.0446
  • Tor Lattimore, Csaba Szepesvári, Bandit Algorithms, Cambridge University Press, 2020, Chapter 24. https://doi.org/10.1017/9781108571401
5 thms2 active usersReviewed
🏆Completed
Machine LearningReinforcement LearningStatistics·Captain: mikedeng1

Foundations of Reinforcement Learning II: Contextual Bandits and Inverse Gap WeightingTextbook

Motivation

Decision-making problems rarely present the same fixed choice twice. A doctor prescribing a treatment sees each patient's medical history and symptoms before deciding; a website choosing which article to show sees the visitor's profile first. The multi-armed bandit model — where the learner repeatedly picks from a fixed set of arms with no side information — cannot express this: it is blind to the covariates that any real decision-maker actually observes. The contextual bandit model closes this gap by letting the learner see a context before acting, and asks for a decision rule that generalizes across contexts rather than memorizing a policy per context. Foster and Rakhlin's Foundations of Reinforcement Learning and Interactive Decision Making (arXiv:2312.16730v1, Section 3, pp. 38–53) develops this model and its algorithms as the bridge between supervised learning and sequential decision making, en route to general reinforcement learning. Contextual bandits with a learned reward-function class underlie production systems for content recommendation, online advertising, and adaptive clinical trial design (Li et al., A Contextual-Bandit Approach to Personalized News Article Recommendation, 2010, https://arxiv.org/abs/1003.0146; Agarwal et al., Making Contextual Decisions with Low Technical Debt, 2016, https://arxiv.org/abs/1606.03966).

The algorithmic history in this chapter runs through two distinct principles. The optimism principle (LinUCB, Section 3.2) generalizes the UCB algorithm to contexts under a linear reward model, but the chapter's own Example 3.1 (Section 3.3) shows optimism fails outside such structured classes, incurring regret linear in the size of the context space or the class. Foster and Rakhlin then present two "black-box" alternatives that use any function class FFF through an abstract regression subroutine: the naive ε\varepsilonε-Greedy method (Section 3.4), and the Inverse Gap Weighting (IGW) strategy underlying the SquareCB algorithm (Bietti, Agarwal & Langford, A Contextual Bandit Bake-off, 2018, https://arxiv.org/abs/1802.04064; Foster & Rakhlin, Beyond UCB: Optimal and Efficient Contextual Bandits with Regression Oracles, 2020, https://arxiv.org/abs/2002.04926). SquareCB attains a regret rate that both generalizes across contexts (no dependence on the size of the context space) and matches the optimal T\sqrt{T}T​ rate — improving on ε\varepsilonε-Greedy's T2/3T^{2/3}T2/3 rate — while remaining agnostic to the internal structure of FFF.

Setting

Over TTT rounds, a decision-maker faces the contextual bandit protocol: at each round ttt, it observes a context xt∈Xx_t \in Xxt​∈X, selects a decision πt\pi_tπt​ from a finite action set Π={1,…,A}\Pi = \{1,\dots,A\}Π={1,…,A}, and observes a reward rt∈Rr_t \in \mathbb{R}rt​∈R. Rewards are generated independently as rt∼M⋆(⋅∣xt,πt)r_t \sim M^\star(\cdot \mid x_t, \pi_t)rt​∼M⋆(⋅∣xt​,πt​) for a fixed, unknown conditional model M⋆M^\starM⋆; write f⋆(x,π):=E[r∣x,π]f^\star(x,\pi) := \mathbb{E}[r \mid x, \pi]f⋆(x,π):=E[r∣x,π] for the mean reward function and π⋆(x):=arg⁡max⁡πf⋆(x,π)\pi^\star(x) := \arg\max_\pi f^\star(x,\pi)π⋆(x):=argmaxπ​f⋆(x,π) for the optimal, context-dependent policy. The context sequence x1,…,xTx_1,\dots,x_Tx1​,…,xT​ is arbitrary — fixed in advance or adversarially chosen — while rewards remain stochastic. Performance is measured by regret against π⋆\pi^\starπ⋆:

Reg:=∑t=1Tf⋆(xt,π⋆(xt))−∑t=1TEπt∼pt[f⋆(xt,πt)],\mathrm{Reg} := \sum_{t=1}^T f^\star(x_t,\pi^\star(x_t)) - \sum_{t=1}^T \mathbb{E}_{\pi_t\sim p_t}[f^\star(x_t,\pi_t)],Reg:=t=1∑T​f⋆(xt​,π⋆(xt​))−t=1∑T​Eπt​∼pt​​[f⋆(xt​,πt​)],

where ptp_tpt​ is the learner's (possibly randomized) action distribution at round ttt.

To generalize across contexts, the learner is given a class F⊆{f:X×Π→R}F \subseteq \{f : X\times\Pi \to \mathbb{R}\}F⊆{f:X×Π→R} with f⋆∈Ff^\star \in Ff⋆∈F, and aims for regret scaling with the statistical complexity log⁡∣F∣\log|F|log∣F∣ rather than with ∣X∣|X|∣X∣. Both algorithms in this mission access FFF only through an online regression oracle (Definition 3, p. 47): given the history (x1,π1,r1),…,(xt−1,πt−1,rt−1)(x_1,\pi_1,r_1),\dots,(x_{t-1},\pi_{t-1},r_{t-1})(x1​,π1​,r1​),…,(xt−1​,πt−1​,rt−1​), it returns an estimate f^t:X×Π→R\hat f_t : X\times\Pi\to\mathbb{R}f^​t​:X×Π→R satisfying, with probability at least 1−δ1-\delta1−δ, ∑t=1TEπt∼pt[(f^t(xt,πt)−f⋆(xt,πt))2]≤EstSq(F,T,δ)\sum_{t=1}^T \mathbb{E}_{\pi_t\sim p_t}[(\hat f_t(x_t,\pi_t)-f^\star(x_t,\pi_t))^2] \le \mathrm{EstSq}(F,T,\delta)∑t=1T​Eπt​∼pt​​[(f^​t​(xt​,πt​)−f⋆(xt​,πt​))2]≤EstSq(F,T,δ) — for instance, exponential weights on a finite class FFF achieves EstSq(F,T,δ)=log⁡(∣F∣/δ)\mathrm{EstSq}(F,T,\delta) = \log(|F|/\delta)EstSq(F,T,δ)=log(∣F∣/δ). SquareCB (p. 50–51) then samples its action from the Inverse Gap Weighting distribution (Definition 4, p. 50): given a vector of estimated values f^∈RA\hat f \in \mathbb{R}^Af^​∈RA with greedy action πˉ=arg⁡max⁡πf^(π)\bar\pi = \arg\max_\pi \hat f(\pi)πˉ=argmaxπ​f^​(π), and an exploration parameter γ≥0\gamma \ge 0γ≥0, p=IGWγ(f^)p = \mathrm{IGW}_\gamma(\hat f)p=IGWγ​(f^​) is p(π)=1/(λ+2γ(f^(πˉ)−f^(π)))p(\pi) = 1/(\lambda + 2\gamma(\hat f(\bar\pi)-\hat f(\pi)))p(π)=1/(λ+2γ(f^​(πˉ)−f^​(π))) for the unique λ∈[1,A]\lambda \in [1,A]λ∈[1,A] making ppp a probability distribution.

Formalization targets

Milestone — Proposition 9 (IGW estimation-to-regret inequality)

Eπ∼p[f⋆(π⋆)−f⋆(π)]≤Aγ+γ⋅Eπ∼p[(f^(π)−f⋆(π))2],p=IGWγ(f^).\mathbb{E}_{\pi\sim p}[f^\star(\pi^\star)-f^\star(\pi)] \le \frac{A}{\gamma} + \gamma\cdot\mathbb{E}_{\pi\sim p}[(\hat f(\pi)-f^\star(\pi))^2], \qquad p = \mathrm{IGW}_\gamma(\hat f).Eπ∼p​[f⋆(π⋆)−f⋆(π)]≤γA​+γ⋅Eπ∼p​[(f^​(π)−f⋆(π))2],p=IGWγ​(f^​).

This holds for any f^,f⋆∈RA\hat f, f^\star \in \mathbb{R}^Af^​,f⋆∈RA and any γ>0\gamma>0γ>0, with no reference to FFF or to how f^\hat ff^​ was produced — it is the purely algebraic core the goal theorem invokes at every round.

Goal — Proposition 10 (SquareCB regret bound)

Reg≤2A T EstSq(F,T,δ)\mathrm{Reg} \le 2\sqrt{A\,T\,\mathrm{EstSq}(F,T,\delta)}Reg≤2ATEstSq(F,T,δ)​

with probability at least 1−δ1-\delta1−δ, for SquareCB run with γ=TA/EstSq(F,T,δ)\gamma = \sqrt{TA/\mathrm{EstSq}(F,T,\delta)}γ=TA/EstSq(F,T,δ)​, for any context sequence x1,…,xTx_1,\dots,x_Tx1​,…,xT​. This is the weakest stable target level in the chapter's oracle-based development: it is stated for an arbitrary class FFF and oracle, so it survives any future improvement to the oracle's own EstSq\mathrm{EstSq}EstSq bound, unlike a version hard-coded to a specific class or oracle.

Significance

Proposition 10 shows that Inverse Gap Weighting converts any estimation-error guarantee into a regret guarantee with the same statistical rate, with no algorithm-side dependence on the structure of FFF or the size of XXX: the same SquareCB template, driven by a plug-in regression oracle, is minimax optimal whenever the oracle itself is. When FFF is finite, this yields Reg≲ATlog⁡(∣F∣/δ)\mathrm{Reg} \lesssim \sqrt{AT\log(|F|/\delta)}Reg≲ATlog(∣F∣/δ)​, matching the optimal rate for stochastic multi-armed bandits (Section 2) while generalizing across contexts — a guarantee that optimism (Proposition 7) provably cannot deliver outside linear classes (Example 3.1), and that the simpler ε\varepsilonε-Greedy baseline (Proposition 8) only delivers at a slower T2/3T^{2/3}T2/3 rate. Foster and Rakhlin describe Proposition 9 itself as being "at the core of the development for the rest of the course": the same IGW mechanism reappears, generalized, in the book's treatment of general decision-making and the Decision-Estimation Coefficient.

Both propositions are proved results, not open questions; this mission's contribution is a machine-checked formalization of their exact statements and hypotheses — the precise OracleGuarantee hypothesis Proposition 10 requires, the exact constant (222, not a bare ≲\lesssim≲) its proof yields at the stated optimal γ\gammaγ, and the universally-quantified form of the IGW inequality (Proposition 9) that makes it reusable independently of any particular oracle or class.

Difficulty

The obvious first idea for exploiting an estimator f^t\hat f_tf^​t​ is a UCB-style optimism approach: build a confidence set around f^t\hat f_tf^​t​ and act greedily on its upper envelope, as in LinUCB (Proposition 7). Example 3.1 shows this fails in general: a class FFF can force the confidence set to remain wide on a fresh action at every new context, driving regret linear in min⁡{∣F∣,∣X∣}\min\{|F|,|X|\}min{∣F∣,∣X∣} — the confidence width in the regret bound does not shrink merely because the oracle's cumulative estimation error is small, since that error is not localized to the specific action the confidence-set approach tries next. Uniform exploration (ε\varepsilonε-Greedy) sidesteps this but wastes exploration budget on actions already known to be far from optimal, which is what caps its rate at T2/3T^{2/3}T2/3 (Proposition 8). Inverse Gap Weighting instead ties the sampling probability itself to the estimated gap from the greedy action, so cheap-to-rule-out actions are down-weighted continuously rather than either fully explored (ε-Greedy) or trusted outright (optimism); the technical content of Proposition 9 is showing this specific reciprocal-gap form gives a bound with no hidden dependence on FFF or XXX, for every pair (f^,f⋆)(\hat f, f^\star)(f^​,f⋆) simultaneously — a guarantee optimism cannot match because its confidence sets are class-dependent by construction.

Formalization scope

Contexts form an arbitrary type X; actions are Fin A for A : ℕ. A finite probability distribution over Fin A is represented directly as p : Fin A → ℝ with ∀ π, 0 ≤ p π and ∑ π, p π = 1, and Eπ∼p[g]\mathbb{E}_{\pi\sim p}[g]Eπ∼p​[g] as the finite sum ∑ π, p π * g π, rather than via Mathlib's PMF (which is ℝ≥0∞-valued) — an equivalent and lighter-weight representation of a distribution on a finite type. The normalizing constant λ\lambdaλ of Definition 4 and the optimal actions π⋆\pi^\starπ⋆, πˉ\bar\piπˉ are each specified by their defining property (existence of λ∈[1,A]\lambda \in [1,A]λ∈[1,A] realizing the IGW formula; ∀π,f(π)≤f(argmax)\forall\pi, f(\pi)\le f(\text{argmax})∀π,f(π)≤f(argmax)) rather than constructed explicitly via an intermediate-value or Finset.argmax argument, avoiding committing to one choice function for a value the book itself leaves implicit. The class FFF enters neither proposition's statement directly: it appears in the source only through the abstract bound EstSq(F,T,δ)\mathrm{EstSq}(F,T,\delta)EstSq(F,T,δ), which is carried as an explicit real-valued parameter and hypothesis (OracleGuarantee) rather than as a literal subset of a function space, since no property of FFF beyond producing this bound is ever used. The probability-(1−δ)(1-\delta)(1−δ) qualifier attached to the online regression oracle's guarantee is likewise the explicit hypothesis OracleGuarantee ... EstSq on a fixed realized run, rather than a statement quantified over an underlying probability space of histories — every subsequent step in both propositions' proofs is deterministic given that this event holds, so this does not weaken either conclusion. A trivializing formalization would fix A=1A=1A=1 (a single ever-optimal action, making both Reg and the IGW inequality vacuous) or take EstSq as an unconstrained free variable with no positivity hypothesis (making γ\gammaγ in Proposition 10 undefined); this mission's statements require 0 < EstSq and leave AAA, TTT, XXX, FFF-via-EstSq fully general.

This mission omits Proposition 7 (LinUCB): its proof rests on an entirely disjoint apparatus (finite linear parameter sets, least-squares confidence sets, the elliptic potential lemma) that neither Proposition 9 nor 10 requires, and Example 3.1 (the failure of optimism) is a worked example rather than a numbered, formalizable claim. It also omits Proposition 8 (ε\varepsilonε-Greedy): the source leaves the optimal ε\varepsilonε unspecified ("choosing ε\varepsilonε appropriately"), and deriving its own optimal value and matching constant independently — rather than reusing the book's own explicit constant, as Rule 7 of this formalization effort requires — was judged too likely to introduce an unfaithful, invented constant within this mission's time budget; both are natural extensions for a follow-up mission or contribution. Reusable infrastructure: the Fin A-indexed finite-distribution convention and the OracleGuarantee/optimal-action-by-property pattern extend directly to any later chapter built on the same online-regression-oracle abstraction.

Selected references

  • Foster, D. J. and Rakhlin, A. Foundations of Reinforcement Learning and Interactive Decision Making. 2023. https://arxiv.org/abs/2312.16730
  • Foster, D. J. and Rakhlin, A. Beyond UCB: Optimal and Efficient Contextual Bandits with Regression Oracles. ICML 2020. https://arxiv.org/abs/2002.04926
  • Bietti, A., Agarwal, A., and Langford, J. A Contextual Bandit Bake-off. JMLR 2021 (arXiv 2018). https://arxiv.org/abs/1802.04064
  • Li, L., Chu, W., Langford, J., and Schapire, R. E. A Contextual-Bandit Approach to Personalized News Article Recommendation. WWW 2010. https://arxiv.org/abs/1003.0146
  • Agarwal, A. et al. Making Contextual Decisions with Low Technical Debt. 2016. https://arxiv.org/abs/1606.03966
5 thms2 active usersReviewed
🏆Completed
Machine LearningReinforcement Learning·Captain: mikedeng1

Foundations of Reinforcement Learning I: Multi-Armed Bandits and the UCB AlgorithmTextbook

Motivation

The multi-armed bandit is the simplest model of sequential decision-making under partial feedback: a learner repeatedly picks one of finitely many options and observes a reward only for the option chosen, never for the alternatives. It formalizes problems ranging from clinical trial design (which treatment to offer a patient) to online advertising (which ad to show) and A/B testing more generally. The framework dates to Robbins' 1952 paper on sequential design, and the algorithm this mission's goal theorem concerns — the Upper Confidence Bound (UCB) algorithm of Lai and Robbins [1985] and Auer, Cesa-Bianchi and Fischer [2002] — is the canonical answer to how to explore efficiently: instead of exploring uniformly at random, act optimistically with respect to the current uncertainty about each option's value. This mission draws its formalization from Chapter 2 of Foster and Rakhlin's 2023 lecture notes, Foundations of Reinforcement Learning and Interactive Decision Making, which develops the bandit problem as the first rung of a ladder of increasingly general interactive decision-making settings (contextual bandits, structured bandits, reinforcement learning) that the book's later chapters build.

Setting

Fix a finite decision (action) space Π={1,…,A}\Pi = \{1,\dots,A\}Π={1,…,A}. In the multi-armed bandit protocol, for each round t=1,…,Tt = 1,\dots,Tt=1,…,T the learner selects a decision πt∈Π\pi_t \in \Piπt​∈Π, possibly at random according to a distribution ptp_tpt​ depending on the history Ht−1=((π1,r1),…,(πt−1,rt−1))H_{t-1} = ((\pi_1,r_1),\dots,(\pi_{t-1},r_{t-1}))Ht−1​=((π1​,r1​),…,(πt−1​,rt−1​)) observed so far, and then observes a reward rt∈Rr_t \in \mathbb{R}rt​∈R drawn independently from a fixed conditional distribution M⋆(⋅∣πt)M^\star(\cdot \mid \pi_t)M⋆(⋅∣πt​) (the stochastic rewards assumption). Writing f⋆(π):=E[r∣π]f^\star(\pi) := \mathbb{E}[r \mid \pi]f⋆(π):=E[r∣π] for the mean reward function and π⋆:=arg⁡max⁡πf⋆(π)\pi^\star := \arg\max_\pi f^\star(\pi)π⋆:=argmaxπ​f⋆(π) for an optimal decision, the learner's performance is measured by the regret

Reg:=∑t=1Tf⋆(π⋆)−∑t=1TEπt∼pt[f⋆(πt)].\mathrm{Reg} := \sum_{t=1}^T f^\star(\pi^\star) - \sum_{t=1}^T \mathbb{E}_{\pi_t \sim p_t}[f^\star(\pi_t)].Reg:=t=1∑T​f⋆(π⋆)−t=1∑T​Eπt​∼pt​​[f⋆(πt​)].

Because the learner observes a reward only for the action played (bandit feedback), a purely greedy strategy that always plays the current empirical maximizer can commit to a suboptimal action forever, incurring linear regret; some form of deliberate exploration is necessary. The chapter's central construction is the confidence interval: a pair of functions f‾t,fˉt:Π→R\underline{f}_t, \bar f_t : \Pi \to \mathbb{R}f​t​,fˉ​t​:Π→R such that, with probability at least 1−δ1-\delta1−δ, f⋆(π)∈[f‾t(π),fˉt(π)]f^\star(\pi) \in [\underline{f}_t(\pi), \bar f_t(\pi)]f⋆(π)∈[f​t​(π),fˉ​t​(π)] for every round ttt and decision π\piπ simultaneously. The UCB algorithm plays the optimistic action πt=arg⁡max⁡πfˉt(π)\pi_t = \arg\max_\pi \bar f_t(\pi)πt​=argmaxπ​fˉ​t​(π) at every round, using the confidence interval built from Hoeffding's inequality around the empirical mean f^t(π)\hat f_t(\pi)f^​t​(π).

Formalization targets

Goal — Proposition 5 (UCB regret)

Reg  ≲  ATlog⁡(AT/δ)\mathrm{Reg} \;\lesssim\; \sqrt{AT\log(AT/\delta)}Reg≲ATlog(AT/δ)​

holding with probability at least 1−δ1-\delta1−δ, for the UCB algorithm using the confidence radius 2log⁡(2T2A/δ)/nt(π)\sqrt{2\log(2T^2A/\delta)/n_t(\pi)}2log(2T2A/δ)/nt​(π)​ of Eq. (2.19). This is the weakest stable statement the chapter proves: it is optimal up to the log factor, and strengthening it (e.g. to the sharper instance-dependent bound of Remark 10) is explicitly left to later work by the book itself.

Milestones

  • Proposition 4 (ε-Greedy regret): Reg≲A1/3T2/3log⁡1/3(AT/δ)\mathrm{Reg} \lesssim A^{1/3}T^{2/3}\log^{1/3}(AT/\delta)Reg≲A1/3T2/3log1/3(AT/δ) — the book's preceding, weaker result, establishing that naive forced exploration already gives sublinear regret, and motivating why an adaptive strategy (UCB) does better.
  • Lemma 7 (Optimism): the per-round regret of the optimistic action is bounded by the confidence width at that action.
  • Lemma 8 (Confidence width potential lemma): ∑t=1T(1/nt(πt)∧1)≲AT\sum_{t=1}^T (1/\sqrt{n_t(\pi_t)} \wedge 1) \lesssim \sqrt{AT}∑t=1T​(1/nt​(πt​)​∧1)≲AT​, a pigeonhole bound on how often any one action's confidence interval can still be wide.

Significance

UCB is the prototype of the "optimism in the face of uncertainty" principle that recurs, in increasingly abstract form, throughout the rest of the book: the same two-step argument (Lemma 7 + Lemma 8) reappears for linear bandits, structured bandits via the Decision-Estimation Coefficient, and UCB-VI for tabular reinforcement learning. Formalizing Chapter 2 in full therefore front-loads the proof pattern every later chapter in this series specializes. The result itself is also of standalone interest: the AT\sqrt{AT}AT​ minimax rate is the benchmark every subsequent bandit algorithm in the literature is compared against, and the A1/3T2/3A^{1/3}T^{2/3}A1/3T2/3-vs-AT\sqrt{AT}AT​ contrast between ε-Greedy and UCB is the standard illustration, in any course on the subject, of why adaptive exploration matters.

No formalization of this exact statement — realizability with respect to a function class f⋆∈F=RΠf^\star \in \mathcal{F} = \mathbb{R}^\Pif⋆∈F=RΠ and a generic confidence interval, rather than a per-arm sub-Gaussian empirical mean — currently exists on the platform (see Formalization scope below); the mission both proves this specific regret bound and seeds the generic optimism/potential lemma pair (Lemma 7, Lemma 8) that the book's later, more structured settings specialize.

Difficulty

The natural first attempt — bound the regret of the empirical-mean-greedy algorithm directly — fails outright: on a two-armed instance where one arm is deterministic and the other only slightly better in expectation, the greedy algorithm can commit to the worse arm forever with constant probability, giving linear, not sublinear, regret (§2.1). The obvious fix, ε-Greedy, forces exploration uniformly across all actions regardless of how much is already known about each, so the exploration cost scales with εT\varepsilon TεT even for actions whose value is already well determined — this is exactly what caps ε-Greedy at the T2/3T^{2/3}T2/3 rate. UCB's optimism principle resolves this by exploring an action only in proportion to how uncertain it still is; the technical core, isolated in Lemma 7 and Lemma 8, is disentangling "the algorithm made a mistake" from "the algorithm is still uncertain," which are conflated in the naive per-round regret decomposition used for ε-Greedy.

Formalization scope

Both the goal and the milestones fix a finite decision space Fin A, a mean reward function fStar : Fin A → ℝ with fStar π ∈ [0,1], and an optimal decision piStar. Regret is defined generically (Eq. (2.3)) via per-round decision weights p : ℕ → Fin A → ℝ, so it applies uniformly to a randomized algorithm (ε-Greedy) and a deterministic one (UCB, via the point mass at the played action). The book's "with probability at least 1−δ1-\delta1−δ" qualifier on both Proposition 4 and Proposition 5 is formalized as the deterministic consequence of the underlying concentration event (Eq. (2.9) and Eq. (2.18) respectively) holding — exactly the move the book's own proofs make ("Let us condition on the event in (2.18) ... "). The concentration events themselves rest on Hoeffding's inequality for adaptive stopping times (Lemma 33) and Bernstein's inequality (Lemma 5), both stated in the book's technical appendix outside this chapter, and are not drafted here; a solver may either take them as a hypothesis (as this mission's statements do) or import/prove them separately. A trivializing formalization is ruled out explicitly: taking δ outside (0,1)(0,1)(0,1), or dropping the fStar π ∈ [0,1] hypothesis, would make the stated constants vacuous or false, so both are retained as explicit hypotheses in every theorem. In every ≲ statement (Prop. 4, Lemma 8, Prop. 5) the witnessed constant C is quantified before the instance parameters (A, T, δ, and the realized sequences): ∃ C, 0 < C ∧ ∀ A T δ ..., Reg ≤ C * (rate), not the other order. This is deliberate, not stylistic: quantifying C after the instance lets it depend on A, T, δ, making the bound satisfiable by an arbitrarily large C chosen per instance and hence content-free, which is not what the book's ≲ means (a single constant working uniformly over all instances). Proposition 5's UCB decision rule is stated in the book's own two clauses, not collapsed into a single "maximize the upper confidence bound" rule: the confidence radius of Eq. (2.19) is +∞+\infty+∞ at nt(π)=0n_t(\pi)=0nt​(π)=0 (an action never yet sampled), so the book's UCB always plays an unsampled action before ever comparing indices, and only compares finite upper confidence bounds once every action has been sampled at least once; the confidence event of Eq. (2.18) is correspondingly assumed only at sampled actions, since the book's own bound is vacuous otherwise. An earlier draft instead capped the radius at 111 when nt(π)=0n_t(\pi)=0nt​(π)=0, which is a true statement about a different algorithm (a sampled action can have index above the capped unsampled index), and was corrected to the book's own rule after moderation. Reuse from the platform's existing bandit library (BanditAlgorithm, Lattimore & Szepesvári) is deliberately avoided: that library's UCB (bandit_ucb_regret_bound, bandit_ucb_minimax_regret_bound) is stated for per-arm 1-sub-Gaussian rewards with δ=1/n2\delta = 1/n^2δ=1/n2 fixed by the horizon, whereas this chapter's UCB is stated for a free failure probability δ\deltaδ and a generic confidence-interval abstraction (the multi-armed case being F=RΠ\mathcal{F} = \mathbb{R}^\PiF=RΠ of the book's general realizability framework) — the two are related but not the same statement. Contributions extending the mission with the generic confidence-interval form of Lemma 7/8 applied to other chapters in this series (contextual and structured bandits) are welcome.

Selected references

  • T. Lai and H. Robbins, Asymptotically Efficient Adaptive Allocation Rules, Advances in Applied Mathematics, 1985.
  • P. Auer, N. Cesa-Bianchi, and P. Fischer, Finite-time Analysis of the Multiarmed Bandit Problem, Machine Learning, 2002.
  • D. Foster and A. Rakhlin, Foundations of Reinforcement Learning and Interactive Decision Making, arXiv:2312.16730, 2023. https://arxiv.org/abs/2312.16730
  • T. Lattimore and C. Szepesvári, Bandit Algorithms, Cambridge University Press, 2020.
7 thms2 active usersReviewed
🏆Completed
Machine LearningOperations Research·Captain: Shuze Chen

Bandit Algorithms XII: Follow-the-Regularised-Leader and Mirror DescentTextbook

Beneath Exp3, Exp4 and their relatives lies one algorithm: minimize past losses plus a convex regularizer. Chapters 26–28 of Lattimore–Szepesvári develop this unifying view. For a Legendre potential FFF with Bregman divergence DFD_FDF​, both mirror descent and follow-the-regularised-leader satisfy the master bound Rn(a)≤F(a)−F(a1)η+1η∑tDF(at,a~t+1)R_n(a) \le \frac{F(a) - F(a_1)}{\eta} + \frac{1}{\eta}\sum_t D_F(a_t, \tilde a_{t+1})Rn​(a)≤ηF(a)−F(a1​)​+η1​∑t​DF​(at​,a~t+1​); the negentropy potential on the simplex recovers Exp3 exactly. The goal theorem is the payoff for adversarial linear bandits: FTRL on the unit ball with the self-concordant-flavoured potential F(a)=−log⁡(1−∥a∥)−∥a∥F(a) = -\log(1-\|a\|) - \|a\|F(a)=−log(1−∥a∥)−∥a∥ achieves Rn≤23ndlog⁡nR_n \le 2\sqrt{3nd\log n}Rn​≤23ndlogn​ — improving the d\sqrt{d}d​ factor over the Exp3-style approach of Chapter 27 and matching the Ω(dn)\Omega(d\sqrt{n})Ω(dn​) lower bound of Mission XI up to logarithms.

5 thms2 active users
🏆Completed
Machine LearningOperations Research·Captain: Shuze Chen

Bandit Algorithms VIII: Contextual Bandits and Exp4Textbook

Real decisions come with context: a news site chooses an article for a particular user. Competing with the single best arm is then meaningless; the right benchmark is the best mapping from contexts to arms, or more generally the best of MMM expert policies. Chapter 18 of Lattimore–Szepesvári formalizes this via Exp4 — exponential weighting over experts, fed by the importance-weighted estimator of Mission V. The goal theorem: with learning rate η=2log⁡(M)/(nk)\eta = \sqrt{2\log(M)/(nk)}η=2log(M)/(nk)​, Exp4 satisfies Rn≤2nklog⁡MR_n \le \sqrt{2nk\log M}Rn​≤2nklogM​ against the best of MMM experts. Since MMM enters only logarithmically, the learner can compete with exponentially large policy classes — the conceptual gateway from bandits to reinforcement learning with function approximation.

9 thms2 active usersReviewed
PreviousPage 2 of 2Next

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me