Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 3.1 — high-probability bound for the biased gain estimates

Proved
RegretBandits.Adversarial.biased_gain_estimate_bound

by mikedeng1 · Oct 4, 2026 · Mathlib 0df444a (Lean v4.33.1)

adversarial-banditsbanditsconcentrationp2o-batch-pfp1bp2o-gran-per-chapterp2o-plan-bookp2o-v1

Consider the adversarial bandit protocol with K≥2K \ge 2K≥2 arms and an adaptive adversary with gains gi,t∈[0,1]g_{i,t} \in [0,1]gi,t​∈[0,1], and let I1,I2,…I_1, I_2, \dotsI1​,I2​,… be a run of a forecaster that draws ItI_tIt​ from the probability vector ptp_tpt​, a function of I1,…,It−1I_1,\dots,I_{t-1}I1​,…,It−1​. Fix an arm iii with pi,t>0p_{i,t} > 0pi,t​>0 for every round and every history, a horizon nnn, β∈(0,1]\beta \in (0,1]β∈(0,1] and δ∈(0,1)\delta \in (0,1)δ∈(0,1), and let

g~i,t=gi,t1It=i+βpi,t.\tilde g_{i,t} = \frac{g_{i,t} \mathbb 1_{I_t = i} + \beta}{p_{i,t}}.g~​i,t​=pi,t​gi,t​1It​=i​+β​.

Then, with probability at least 1−δ1 - \delta1−δ,

∑t=1ngi,t≤∑t=1ng~i,t+ln⁡(δ−1)β.\sum_{t=1}^n g_{i,t} \le \sum_{t=1}^n \tilde g_{i,t} + \frac{\ln(\delta^{-1})}{\beta}.t=1∑n​gi,t​≤t=1∑n​g~​i,t​+βln(δ−1)​.

The lemma says that the biased estimate G~i,n\tilde G_{i,n}G~i,n​ used by Exp3.P overestimates the true cumulative gain only by an additive ln⁡(δ−1)/β\ln(\delta^{-1})/\betaln(δ−1)/β with high probability; it is the concentration step in the proof of Theorem 3.2.

Formalization Note The book states the lemma for the distributions pi,tp_{i,t}pi,t​ of Exp3.P with the single hypothesis β≤1\beta \le 1β≤1. The statement here holds for any forecaster rule (the book's proof uses only that gi,tg_{i,t}gi,t​ and pi,tp_{i,t}pi,t​ are determined by I1,…,It−1I_1,\dots,I_{t-1}I1​,…,It−1​ and that It∼ptI_t \sim p_tIt​∼pt​ given the past), which contains Exp3.P. It adds the hypotheses implicit on the page: β>0\beta > 0β>0 (the bound divides by β\betaβ), pi,t>0p_{i,t} > 0pi,t​>0 (the estimate divides by pi,tp_{i,t}pi,t​; Exp3.P has pi,t≥γ/Kp_{i,t} \ge \gamma/Kpi,t​≥γ/K and positive exponential weights), δ∈(0,1)\delta \in (0,1)δ∈(0,1), and the standing K≥2K \ge 2K≥2 of the protocol (p. 6). "With probability at least 1−δ1-\delta1−δ" is P(event)≥1−δ\mathbb P(\text{event}) \ge 1-\deltaP(event)≥1−δ under the law of the run.

Preamble
import Mathlib
import Definitions.Def_RegretBandits_Adversarial_Protocol

open MeasureTheory
Formal statement
namespace RegretBandits.Adversarial

/-- Lemma 3.1 (Bubeck–Cesa-Bianchi, arXiv:1204.5721v2, p. 28). Let `p` be a forecaster rule run
against an adaptive adversary `g` with gains in `[0,1]`, fix an arm `i` with `p_{i,t} > 0`, and
let `0 < β ≤ 1`, `δ ∈ (0,1)`. With `g̃_{i,t} = (g_{i,t} 𝟙{I_t = i} + β) / p_{i,t}`, with probability
at least `1 - δ`,
`∑_{t=1}^n g_{i,t} ≤ ∑_{t=1}^n g̃_{i,t} + ln(δ⁻¹) / β`. -/
theorem biased_gain_estimate_bound {K : ℕ} (hK : 2 ≤ K) (n : ℕ) (g : Adversary K)
    (p : ℕ → (ℕ → Fin K) → Fin K → ℝ) (hp : IsForecasterRule p) (i : Fin K)
    (hpos : ∀ t h, 0 < p t h i) (β δ : ℝ) (hβ0 : 0 < β) (hβ1 : β ≤ 1)
    (hδ0 : 0 < δ) (hδ1 : δ < 1)
    {Ω : Type*} [MeasurableSpace Ω] (P : Measure Ω) [IsProbabilityMeasure P]
    (I : ℕ → Ω → Fin K) (hI : IsRun P p I) :
    ENNReal.ofReal (1 - δ) ≤
      P {ω | ∑ t ∈ Finset.Icc 1 n, g.val t (fun s => I s ω) i ≤
        ∑ t ∈ Finset.Icc 1 n,
            (g.val t (fun s => I s ω) i * (if I t ω = i then 1 else 0) + β) /
              p t (fun s => I s ω) i +
          Real.log δ⁻¹ / β} := by sorry

end RegretBandits.Adversarial
Source
Bubeck, Cesa-Bianchi, Regret Analysis of Stochastic and Nonstochastic Multi-armed Bandit Problems, arXiv:1204.5721v2, p. 28, Lemma 3.1
Human review
  • Endorsed by Shuze Chen · Oct 4, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 4, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

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 paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me