Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Lemma 6.5 — reduction from limited to full information

Proved
OnlineConvexOpt.BanditConvex.bandit_to_full_information_regret

by mikedeng1 · Sep 19, 2026 · Mathlib 0df444a (Lean v4.33.1)

bandit-convex-optimizationgradient-estimationonline-convex-optimizationregret

Statement (Lemma 6.5, p. 108, PDF p. 130). Let u∈Ku \in Ku∈K be fixed and f1,…,fT:K→Rf_1,\dots,f_T : K \to \mathbb Rf1​,…,fT​:K→R be differentiable. Let AAA be a first order online algorithm (Definition 6.4) that ensures, in the full information setting, a regret bound RegretT(A)≤BA(∇f1(x1),…,∇fT(xT))\mathrm{Regret}_T(A) \le B_A(\nabla f_1(x_1),\dots,\nabla f_T(x_T))RegretT​(A)≤BA​(∇f1​(x1​),…,∇fT​(xT​)). Define the points {xt}\{x_t\}{xt​} by x1←A(∅)x_1 \leftarrow A(\emptyset)x1​←A(∅), xt←A(g1,…,gt−1)x_t \leftarrow A(g_1,\dots,g_{t-1})xt​←A(g1​,…,gt−1​), where each gtg_tgt​ is a random variable with E[gt∣x1,f1,…,xt,ft]=∇ft(xt)\mathbb E[g_t \mid x_1,f_1,\dots,x_t,f_t] = \nabla f_t(x_t)E[gt​∣x1​,f1​,…,xt​,ft​]=∇ft​(xt​). Then E[∑t=1Tft(xt)]−∑t=1Tft(u)≤E[BA(g1,…,gT)]\mathbb E[\sum_{t=1}^T f_t(x_t)] - \sum_{t=1}^T f_t(u) \le \mathbb E[B_A(g_1,\dots,g_T)]E[∑t=1T​ft​(xt​)]−∑t=1T​ft​(u)≤E[BA​(g1​,…,gT​)].

This is Algorithm 22's reduction: substituting an unbiased gradient estimator gtg_tgt​ for the true gradient inside any first-order full-information algorithm preserves its regret bound in expectation, up to the magnitude of the estimator. Lemma 6.5 is the abstract template Theorem 6.9 instantiates.

Formalization Note. 𝓕 models the history "x1,f1,…,xt,ftx_1,f_1,\dots,x_t,f_tx1​,f1​,…,xt​,ft​" available just before gtg_tgt​ is drawn (xtx_txt​ is Ft\mathcal F_tFt​-measurable, gtg_tgt​ is Ft+1\mathcal F_{t+1}Ft+1​-measurable; the fτf_\taufτ​ are deterministic and add no randomness to condition on). Rounds are 0-indexed (Finset.range T). The empty history A(∅)A(\emptyset)A(∅) is modeled by applying AAA to the identically-zero cost sequence, since a non-anticipating AAA's round-0 decision cannot depend on any cost function's values (matching how OnlineConvexOpt.FirstOrder.Algorithm's IsOnlineAlgorithm treats round 0). Integrability of ft(xt)f_t(x_t)ft​(xt​) and of BA(g1,…,gT)B_A(g_1,\dots,g_T)BA​(g1​,…,gT​) is required explicitly as a hypothesis, per the book's implicit assumption that these expectations exist.


Retired. Retired because its Lean statement was unfaithful to Hazan (see the replacement's Formalization Note); replaced by OnlineConvexOpt.BanditConvex.bandit_to_full_information_regret_v2.

Preamble
import Mathlib
import Definitions.Def_OnlineConvexOpt_BanditConvex_FirstOrderAlgorithm
import Definitions.Def_OnlineConvexOpt_FirstOrder_Protocol

open MeasureTheory
Formal statement
namespace OnlineConvexOpt.BanditConvex

variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E]
  [MeasurableSpace E] [BorelSpace E]

/-- Lemma 6.5 (Hazan, *Introduction to Online Convex Optimization*, 2nd ed., arXiv:1909.05207v3,
p. 108, PDF p. 130). Let `u ∈ K` be fixed and `f_1, ..., f_T : K → ℝ` differentiable (with
gradient map `gradf`). Let `A` be a first order online algorithm (Definition 6.4) that ensures,
in the full information setting, a regret bound `Regret_T(A) ≤ B(∇f_1(x_1), ..., ∇f_T(x_T))` for
every differentiable cost sequence, where `x_t = A(f_1, ..., f_{t-1})` is `A`'s own full
information play. Define the points `{x_t}` (Algorithm 22) by `x_1 ← A(∅)`,
`x_t ← A(g_1, ..., g_{t-1})` (`g_τ` substituted for `A` as the linear functional `y ↦ ⟪g_τ, y⟫`),
where each `g_t` is a vector valued random variable adapted to a filtration `𝓕` with
`E[g_t | x_1, f_1, ..., x_t, f_t] = ∇f_t(x_t)`. Then `E[Σ_{t=1}^T f_t(x_t)] - Σ_{t=1}^T f_t(u) ≤
E[B(g_1, ..., g_T)]`.

`𝓕` models the history "`x_1, f_1, ..., x_t, f_t`" available just before `g_t` is drawn: `x_t` is
`𝓕 t`-measurable and `g_t` is `𝓕 (t + 1)`-measurable (the `f_τ` are deterministic, so they add no
randomness to condition on). The empty history `A(∅)` is modeled by applying `A` to the
identically-zero cost sequence, since a non-anticipating `A`'s round-0 decision cannot depend on
any cost function's values. -/
theorem bandit_to_full_information_regret
    {Ω : Type*} [m0 : MeasurableSpace Ω] {Prob : Measure Ω} [IsProbabilityMeasure Prob]
    (K : Set E) (T : ℕ) (u : E) (hu : u ∈ K)
    (f : ℕ → E → ℝ) (gradf : ℕ → E → E) (hf : ∀ t y, HasGradientAt (f t) (gradf t y) y)
    (A : (ℕ → E → ℝ) → ℕ → E) (hA : IsFirstOrderOnlineAlgorithm A)
    (B : (ℕ → E) → ℝ)
    (hB : ∀ (h : ℕ → E → ℝ) (grad' : ℕ → E),
      (∀ t, HasGradientAt (h t) (grad' t) (A h t)) →
      OnlineConvexOpt.FirstOrder.RegretT K h (fun t => A h t) T ≤ B grad')
    (𝓕 : ℕ → MeasurableSpace Ω) (hFmono : Monotone 𝓕) (hFle : ∀ t, 𝓕 t ≤ m0)
    (x g : ℕ → Ω → E)
    (hx0 : x 0 = fun _ => A (fun _ _ => (0 : ℝ)) 0)
    (hxstep : ∀ t : ℕ, x (t + 1) =
      fun ω => A (fun τ y => if τ ≤ t then inner ℝ (g τ ω) y else 0) (t + 1))
    (hxmeas : ∀ t, Measurable[𝓕 t] (x t))
    (hgmeas : ∀ t, Measurable[𝓕 (t + 1)] (g t))
    (hunbiased : ∀ t, condExp (𝓕 t) Prob (g t) =ᵐ[Prob] fun ω => gradf t (x t ω))
    (hfintegrable : ∀ t, Integrable (fun ω => f t (x t ω)) Prob)
    (hBintegrable : Integrable (fun ω => B (fun t => g t ω)) Prob) :
    (∫ ω, ∑ t ∈ Finset.range T, f t (x t ω) ∂Prob) - ∑ t ∈ Finset.range T, f t u ≤
      ∫ ω, B (fun t => g t ω) ∂Prob := by sorry

end OnlineConvexOpt.BanditConvex
Source
Hazan, Introduction to Online Convex Optimization, 2nd ed., arXiv:1909.05207v3, p. 108, Lemma 6.5 (PDF p. 130)
Human review
  • Endorsed by Shuze Chen · Sep 28, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 28, 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