Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Bayesian regret decomposes into one-round expectations

Proved
BanditAlgorithm.bayesianAdversarialRegret_eq_sum_round_integral

by Harry_Xu · Aug 1, 2026 · Mathlib c5ea003 (Lean v4.30.0)

banditsbayesian-regretthompson-sampling

Let A∗A^*A∗ be the action with largest total reward and let (At)t=1n(A_t)_{t=1}^n(At​)t=1n​ be the actions in the Bayesian adversarial-bandit trajectory. For a prior supported on reward matrices in [0,1]n×k[0,1]^{n\times k}[0,1]n×k, Bayesian regret decomposes round by round:

BR⁡n=∑t=1nE ⁣[Xt,A∗−Xt,At].\operatorname{BR}_n =\sum_{t=1}^n \mathbb E\!\left[X_{t,A^*}-X_{t,A_t}\right].BRn​=t=1∑n​E[Xt,A∗​−Xt,At​​].

The expectation is taken under the terminal joint law of the reward matrix and observed trajectory.

Preamble
import Definitions.Def_ThompsonSampling

open MeasureTheory ProbabilityTheory
open scoped BigOperators
Formal statement
theorem BanditAlgorithm.bayesianAdversarialRegret_eq_sum_round_integral {k n : ℕ} [NeZero k]
    (Q : Measure (Fin n → Fin k → ℝ)) [IsProbabilityMeasure Q]
    (hQ : ∀ᵐ X ∂Q, ∀ (t : Fin n) (a : Fin k), X t a ∈ Set.Icc (0 : ℝ) 1)
    (pi : BanditPolicy k) :
    bayesianAdversarialRegret Q pi =
      ∑ t, ∫ p, (p.1 t (bayesianOptimalAction p.1) - p.1 t ((p.2 t).1))
        ∂bayesianAdversarialMeasure Q pi n le_rfl := by
  sorry
Source
Lattimore and Szepesvári, Bandit Algorithms (Cambridge UP, 2020), https://tor-lattimore.com/downloads/book/book.pdf, printed p. 469 (PDF p. 478), definition of BR_n immediately before Theorem 36.5, followed by linearity of expectation.

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