Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Proposition A.2 (as proved, corrected powers of δ\deltaδ and ε2\varepsilon_2ε2​): the χ2\chi^2χ2-based discrepancy bound satisfies (R1) and (R2)

Proved
MBRLGuarantees.dChi_discrepancy_bound

by Xeroth · Nov 24, 2026 · Mathlib 0df444a (Lean v4.33.1)

chi-square-divergencediscrepancy-boundsmarkov-decision-processesmodel-based-rlreinforcement-learning

Let γ∈[0,1)\gamma\in[0,1)γ∈[0,1), let RRR be bounded and measurable, let S0∼μ0S_0\sim\mu_0S0​∼μ0​, let M⋆M^\starM⋆ be the true model and δ≥0\delta\ge0δ≥0. Take d=dχ2d=d^{\chi^2}d=dχ2 and

Dπref(M^,π)=(1−γ)−1ε1+(1−γ)−2 δ1/2ε21/2+(1−γ)−5/2 δ3/4εmax⁡,D_{\pi_{\mathrm{ref}}}(\widehat M,\pi)=(1-\gamma)^{-1}\varepsilon_1+(1-\gamma)^{-2}\,\delta^{1/2}\varepsilon_2^{1/2}+(1-\gamma)^{-5/2}\,\delta^{3/4}\varepsilon_{\max},Dπref​​(M,π)=(1−γ)−1ε1​+(1−γ)−2δ1/2ε21/2​+(1−γ)−5/2δ3/4εmax​,

where ε1=ES∼ρπref∣Gπ,M^(S)∣\varepsilon_1=\mathbb E_{S\sim\rho^{\pi_{\mathrm{ref}}}}|G^{\pi,\widehat M}(S)|ε1​=ES∼ρπref​​∣Gπ,M(S)∣, ε2=ES∼βπrefGπ,M^(S)2\varepsilon_2=\mathbb E_{S\sim\beta^{\pi_{\mathrm{ref}}}}G^{\pi,\widehat M}(S)^2ε2​=ES∼βπref​​Gπ,M(S)2, εmax⁡=sup⁡S∣Gπ,M^(S)∣\varepsilon_{\max}=\sup_S|G^{\pi,\widehat M}(S)|εmax​=supS​∣Gπ,M(S)∣, all computed on M⋆M^\starM⋆. Then

  1. (R1) for all policies π,πref\pi,\pi_{\mathrm{ref}}π,πref​ and every model M^\widehat MM with dχ2(π,πref)≤δd^{\chi^2}(\pi,\pi_{\mathrm{ref}})\le\deltadχ2(π,πref​)≤δ (and s↦χ2(π(⋅∣s),πref(⋅∣s))s\mapsto\chi^2(\pi(\cdot\mid s),\pi_{\mathrm{ref}}(\cdot\mid s))s↦χ2(π(⋅∣s),πref​(⋅∣s)) measurable), Vπ,M⋆≥Vπ,M^−Dπref(M^,π)V^{\pi,M^\star}\ge V^{\pi,\widehat M}-D_{\pi_{\mathrm{ref}}}(\widehat M,\pi)Vπ,M⋆≥Vπ,M−Dπref​​(M,π);
  2. (R2) Dπref(M⋆,π)=0D_{\pi_{\mathrm{ref}}}(M^\star,\pi)=0Dπref​​(M⋆,π)=0 for all π,πref\pi,\pi_{\mathrm{ref}}π,πref​.

Formalization Note The paper prints Dχ2=(1−γ)−1ε1+(1−γ)−2δε2+(1−γ)−5/2δ3/2εmax⁡D^{\chi^2}=(1-\gamma)^{-1}\varepsilon_1+(1-\gamma)^{-2}\delta\varepsilon_2+(1-\gamma)^{-5/2}\delta^{3/2}\varepsilon_{\max}Dχ2=(1−γ)−1ε1​+(1−γ)−2δε2​+(1−γ)−5/2δ3/2εmax​. Its proof in Appendix C.2 uses δ1≤(1−γ)−1δ\delta_1\le(1-\gamma)^{-1}\deltaδ1​≤(1−γ)−1δ, but dχ2≤δd^{\chi^2}\le\deltadχ2≤δ only gives δ1≤(1−γ)−1δ1/2\delta_1\le(1-\gamma)^{-1}\delta^{1/2}δ1​≤(1−γ)−1δ1/2. It also writes δ1ε2\delta_1\varepsilon_2δ1​ε2​ for δ1⟨βπref,f2⟩1/2=δ1ε21/2\delta_1\langle\beta^{\pi_{\mathrm{ref}}},f^2\rangle^{1/2}=\delta_1\varepsilon_2^{1/2}δ1​⟨βπref​,f2⟩1/2=δ1​ε21/2​. Correcting both steps gives the bound above. The printed bound is false: a two-state example violates it (see the mission report). The paper's ε2\varepsilon_2ε2​ uses G(S,A)2G(S,A)^2G(S,A)2 with AAA unspecified; the statement uses G(S)2G(S)^2G(S)2, as the proof does.

Preamble
import Mathlib
import Definitions.Def_MBRLGuarantees_Basic

open MeasureTheory ProbabilityTheory InformationTheory
open scoped ENNReal
Formal statement
namespace MBRLGuarantees

theorem dChi_discrepancy_bound {S A : Type*} [MeasurableSpace S] [MeasurableSpace A]
    (γ : ℝ) (hγ0 : 0 ≤ γ) (hγ1 : γ < 1)
    (R : S × A → ℝ) (hRm : Measurable R) (hRb : ∃ C, ∀ x, |R x| ≤ C)
    (μ₀ : Measure S) [IsProbabilityMeasure μ₀] (Mstar : Kernel (S × A) S) [IsMarkovKernel Mstar]
    (δ : ℝ) (hδ : 0 ≤ δ) :
    (∀ (piref pi : Kernel S A) (Mhat : Kernel (S × A) S), IsMarkovKernel piref →
      IsMarkovKernel pi → IsMarkovKernel Mhat → Measurable (fun s => chiSq (pi s) (piref s)) →
      dChi γ μ₀ Mstar pi piref ≤ ENNReal.ofReal δ →
      value γ R μ₀ pi Mhat -
          ((1 - γ)⁻¹ * epsOne γ R μ₀ Mstar piref pi Mhat +
            ((1 - γ) ^ 2)⁻¹ * Real.sqrt δ * Real.sqrt (epsTwo γ R μ₀ Mstar piref pi Mhat) +
            ((1 - γ) ^ (5 / 2 : ℝ))⁻¹ * δ ^ (3 / 4 : ℝ) * epsMax γ R Mstar pi Mhat) ≤
        value γ R μ₀ pi Mstar) ∧
    (∀ piref pi : Kernel S A, IsMarkovKernel piref → IsMarkovKernel pi →
      (1 - γ)⁻¹ * epsOne γ R μ₀ Mstar piref pi Mstar +
          ((1 - γ) ^ 2)⁻¹ * Real.sqrt δ * Real.sqrt (epsTwo γ R μ₀ Mstar piref pi Mstar) +
          ((1 - γ) ^ (5 / 2 : ℝ))⁻¹ * δ ^ (3 / 4 : ℝ) * epsMax γ R Mstar pi Mstar = 0) := by sorry

end MBRLGuarantees
Source
Luo, Xu, Li, Tian, Darrell and Ma, Algorithmic Framework for Model-based Deep Reinforcement Learning with Theoretical Guarantees, arXiv:1807.03858v5 (ICLR 2019), Appendix A, Definition A.1, eqs. (A.1)-(A.2), Proposition A.2, p. 16; proof in Appendix C.2, p. 18
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

Setting. Let SSS and AAA be arbitrary measurable spaces of states and actions. The following data are fixed throughout:

  • a discount factor γ\gammaγ with 0≤γ<10 \le \gamma < 10≤γ<1;
  • a reward R:S×A→RR : S \times A \to \mathbb{R}R:S×A→R that is measurable and bounded, meaning there is a constant CCC with ∣R(x)∣≤C|R(x)| \le C∣R(x)∣≤C for all xxx;
  • a probability measure μ0\mu_0μ0​ on SSS, the initial-state distribution;
  • a Markov kernel M⋆(⋅∣s,a)M^\star(\cdot \mid s,a)M⋆(⋅∣s,a) from S×AS \times AS×A to SSS, the "true" model;
  • a real number δ≥0\delta \ge 0δ≥0.

The theorem asserts the conjunction of two statements, (I) and (II), defined after the notation below.

Notation (unfolded definitions). For a kernel π(⋅∣s)\pi(\cdot\mid s)π(⋅∣s) from SSS to AAA and a kernel MMM from S×AS\times AS×A to SSS:

  • The induced state transition kernel is
Pπ,M(B∣s)=∫AM(B∣s,a) π(da∣s).P_{\pi,M}(B \mid s) = \int_A M(B \mid s,a)\,\pi(da \mid s).Pπ,M​(B∣s)=∫A​M(B∣s,a)π(da∣s).
  • Pπ,MtP_{\pi,M}^tPπ,Mt​ is its ttt-fold composition, with P0P^0P0 the identity.
  • The one-step expected reward is rπ(s)=∫AR(s,a) π(da∣s)r_\pi(s) = \int_A R(s,a)\,\pi(da\mid s)rπ​(s)=∫A​R(s,a)π(da∣s).

The state value function and the value are

Vπ,M(s)=∑t≥0γt∫Srπ(s′) Pπ,Mt(ds′∣s),Vπ,M=∫SVπ,M(s) μ0(ds).V^{\pi,M}(s) = \sum_{t\ge 0} \gamma^t \int_S r_\pi(s')\,P^t_{\pi,M}(ds' \mid s), \qquad V^{\pi,M} = \int_S V^{\pi,M}(s)\,\mu_0(ds).Vπ,M(s)=t≥0∑​γt∫S​rπ​(s′)Pπ,Mt​(ds′∣s),Vπ,M=∫S​Vπ,M(s)μ0​(ds).

Lean's conventions apply: a non-summable series is assigned the value 000, and a non-integrable integrand has integral 000.

On the model M⋆M^\starM⋆, the discounted state distribution and the re-weighted distribution of a policy πref\pi_{\mathrm{ref}}πref​ are

ρπref=(1−γ)∑t≥0γt μ0Pπref,M⋆t,βπref=(1−γ)2∑t≥0(t+1)γt μ0Pπref,M⋆t+1.\rho^{\pi_{\mathrm{ref}}} = (1-\gamma)\sum_{t\ge0}\gamma^t\,\mu_0 P^t_{\pi_{\mathrm{ref}},M^\star}, \qquad \beta^{\pi_{\mathrm{ref}}} = (1-\gamma)^2\sum_{t\ge0}(t+1)\gamma^t\,\mu_0 P^{t+1}_{\pi_{\mathrm{ref}},M^\star}.ρπref​=(1−γ)t≥0∑​γtμ0​Pπref​,M⋆t​,βπref​=(1−γ)2t≥0∑​(t+1)γtμ0​Pπref​,M⋆t+1​.

Here μ0Pt\mu_0 P^tμ0​Pt denotes the law of the state after ttt steps when starting from μ0\mu_0μ0​.

For a model M^\hat MM^, the model discrepancy is defined against M⋆M^\starM⋆:

Gπ,M^(s,a)=∫SVπ,M^(s′) M^(ds′∣s,a)−∫SVπ,M^(s′) M⋆(ds′∣s,a),G^{\pi,\hat M}(s,a) = \int_S V^{\pi,\hat M}(s')\,\hat M(ds'\mid s,a) - \int_S V^{\pi,\hat M}(s')\,M^\star(ds'\mid s,a),Gπ,M^(s,a)=∫S​Vπ,M^(s′)M^(ds′∣s,a)−∫S​Vπ,M^(s′)M⋆(ds′∣s,a), Gπ,M^(s)=∫AGπ,M^(s,a) π(da∣s).G^{\pi,\hat M}(s) = \int_A G^{\pi,\hat M}(s,a)\,\pi(da\mid s).Gπ,M^(s)=∫A​Gπ,M^(s,a)π(da∣s).

From GGG one forms three quantities:

ε1=∫S∣Gπ,M^(s)∣ ρπref(ds),ε2=∫SGπ,M^(s)2 βπref(ds),εmax⁡=sup⁡s∈S∣Gπ,M^(s)∣.\varepsilon_1 = \int_S |G^{\pi,\hat M}(s)|\,\rho^{\pi_{\mathrm{ref}}}(ds), \qquad \varepsilon_2 = \int_S G^{\pi,\hat M}(s)^2\,\beta^{\pi_{\mathrm{ref}}}(ds), \qquad \varepsilon_{\max} = \sup_{s\in S}|G^{\pi,\hat M}(s)|.ε1​=∫S​∣Gπ,M^(s)∣ρπref​(ds),ε2​=∫S​Gπ,M^(s)2βπref​(ds),εmax​=s∈Ssup​∣Gπ,M^(s)∣.

Some points about these quantities:

  • In all three, GGG is built from π\piπ and M^\hat MM^, while the weighting measures come from πref\pi_{\mathrm{ref}}πref​ on M⋆M^\starM⋆.
  • The supremum is a real supremum. If the set is unbounded above, or if SSS is empty, it takes the junk value 000.
  • The non-integrability convention above also applies to ε1\varepsilon_1ε1​ and ε2\varepsilon_2ε2​.

For measures p,qp,qp,q, the χ2\chi^2χ2 distance takes values in [0,∞][0,\infty][0,∞]:

χ2(p,q)={∫(dpdq−1)2 dqif p≪q,+∞otherwise.\chi^2(p,q) = \begin{cases}\int \big(\tfrac{dp}{dq}-1\big)^2\,dq & \text{if } p \ll q,\\ +\infty & \text{otherwise.}\end{cases}χ2(p,q)={∫(dqdp​−1)2dq+∞​if p≪q,otherwise.​

Here dpdq\tfrac{dp}{dq}dqdp​ is the Radon–Nikodym derivative, converted to a real number. The policy distance is

dχ2(π,πref)=max⁡{∫Sχ2(π(⋅∣s),πref(⋅∣s)) ρπref(ds), ∫Sχ2(π(⋅∣s),πref(⋅∣s)) βπref(ds)},d^{\chi^2}(\pi,\pi_{\mathrm{ref}}) = \max\Big\{\int_S \chi^2\big(\pi(\cdot\mid s),\pi_{\mathrm{ref}}(\cdot\mid s)\big)\,\rho^{\pi_{\mathrm{ref}}}(ds),\ \int_S \chi^2\big(\pi(\cdot\mid s),\pi_{\mathrm{ref}}(\cdot\mid s)\big)\,\beta^{\pi_{\mathrm{ref}}}(ds)\Big\},dχ2(π,πref​)=max{∫S​χ2(π(⋅∣s),πref​(⋅∣s))ρπref​(ds), ∫S​χ2(π(⋅∣s),πref​(⋅∣s))βπref​(ds)},

where both integrals are taken in [0,∞][0,\infty][0,∞].

Write

Φ(πref,π,M^)=ε11−γ+δ ε2(1−γ)2+δ3/4 εmax⁡(1−γ)5/2,\Phi(\pi_{\mathrm{ref}},\pi,\hat M) = \frac{\varepsilon_1}{1-\gamma} + \frac{\sqrt{\delta}\,\sqrt{\varepsilon_2}}{(1-\gamma)^2} + \frac{\delta^{3/4}\,\varepsilon_{\max}}{(1-\gamma)^{5/2}},Φ(πref​,π,M^)=1−γε1​​+(1−γ)2δ​ε2​​​+(1−γ)5/2δ3/4εmax​​,

where ε1,ε2,εmax⁡\varepsilon_1,\varepsilon_2,\varepsilon_{\max}ε1​,ε2​,εmax​ are computed for (πref,π,M^)(\pi_{\mathrm{ref}},\pi,\hat M)(πref​,π,M^).

(I) The bound. Take any Markov kernels πref\pi_{\mathrm{ref}}πref​ and π\piπ from SSS to AAA, and any Markov kernel M^\hat MM^ from S×AS\times AS×A to SSS. Assume:

  • the map s↦χ2(π(⋅∣s),πref(⋅∣s))s \mapsto \chi^2(\pi(\cdot\mid s),\pi_{\mathrm{ref}}(\cdot\mid s))s↦χ2(π(⋅∣s),πref​(⋅∣s)) is measurable;
  • dχ2(π,πref)≤δd^{\chi^2}(\pi,\pi_{\mathrm{ref}}) \le \deltadχ2(π,πref​)≤δ.

Then

Vπ,M^−Φ(πref,π,M^)≤Vπ,M⋆.V^{\pi,\hat M} - \Phi(\pi_{\mathrm{ref}},\pi,\hat M) \le V^{\pi,M^\star}.Vπ,M^−Φ(πref​,π,M^)≤Vπ,M⋆.

The same δ\deltaδ serves both as the bound in the hypothesis and as the coefficient inside Φ\PhiΦ. No other relation between π\piπ, πref\pi_{\mathrm{ref}}πref​ and M^\hat MM^ is assumed.

(II) The case M^=M⋆\hat M = M^\starM^=M⋆. For any Markov kernels πref\pi_{\mathrm{ref}}πref​ and π\piπ from SSS to AAA, with no further hypotheses (no condition on dχ2d^{\chi^2}dχ2 and no condition on δ\deltaδ):

Φ(πref,π,M⋆)=0.\Phi(\pi_{\mathrm{ref}},\pi,M^\star) = 0.Φ(πref​,π,M⋆)=0.

Unfolding the definitions, when M^=M⋆\hat M = M^\starM^=M⋆ the two integrals in Gπ,M⋆(s,a)G^{\pi,M^\star}(s,a)Gπ,M⋆(s,a) are literally the same expression. Hence G≡0G \equiv 0G≡0, which makes ε1=ε2=εmax⁡=0\varepsilon_1 = \varepsilon_2 = \varepsilon_{\max} = 0ε1​=ε2​=εmax​=0, and this conjunct follows directly from the definitions.

Human review
  • Endorsed by Shuze Chen · Nov 24, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Xeroth · Nov 24, 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