BanditAlgorithm.bandit_divergence_decomposition
Proved(Divergence decomposition) Let and be reward distributions of two -armed bandits, a fixed policy, and the measures induced on the canonical bandit model by the -round interconnection. Then
import Mathlib.InformationTheory.KullbackLeibler.Basic import Definitions.Def_BanditPolicy open MeasureTheory ProbabilityTheory InformationTheory
theorem BanditAlgorithm.bandit_divergence_decomposition {k : ℕ} (ν ν' : StochasticBandit k)
(hKL : ∀ i, klDiv (ν.P i) (ν'.P i) ≠ ⊤)
(π : BanditPolicy k) (n : ℕ) :
klDiv (banditMeasure ν π n) (banditMeasure ν' π n) =
∑ i, ENNReal.ofReal (∫ h, (armPullCount i h : ℝ) ∂banditMeasure ν π n) *
klDiv (ν.P i) (ν'.P i) := by
sorry
Read-back
What the Lean code literally says, in plain math · claude-fable-5
Setup and notation. Let and be two -armed bandits (families of probability measures on ) and a policy (a family of Markov kernels from length- histories to arm distributions). denotes the canonical probability measure on length- histories: the point mass at the empty history for , and at each further step an arm drawn from the policy kernel given the current history, a reward drawn from that arm's distribution, and the pair appended. is the number of rounds of the history that play arm . denotes the Kullback–Leibler divergence with values in (the library's: it is whenever is not absolutely continuous with respect to or the log-likelihood ratio is not -integrable; for probability measures with integrable log-likelihood ratio it is the truncation to of ). Write viewed in .
Assertion (an equality in ).
Hypotheses.
- For every arm , .
- is an arbitrary policy; is arbitrary (including ); are arbitrary -armed bandits. Both history measures use the same policy .
Edge cases.
- The expected pull count is a Bochner integral of the real-valued count function (which is bounded by ) under the history measure of (the first bandit), and it is then truncated at before entering the extended-real product.
- Since each per-arm divergence is finite by hypothesis, no product arises on the right; multiplication follows the conventions.
- The claim is a two-sided equality, not merely an inequality.
- Instances include (both history measures are the point mass at the empty history, all pull counts ) and (empty sum).
Confirmed by the mission captain (proposal self-audit).