Lemma 1: optimal predictor and predictable energy
ProvedControlledWorldModels.optimal_predictor_predictable_energyAssume Assumptions 1–2. Let be an admissible encoder, i.e. . Then:
- the optimal predictor for squared loss is the conditional mean . That is, there is a measurable realising this conditional expectation almost surely, and for every measurable predictor ;
- ;
- with ,
the infimum being over measurable predictors.
Minimizing the prediction loss over is therefore equivalent to maximizing the predictable energy .
Formalization Note The inequality is stated so that the subtraction in is the ordinary one. The paper's identity appears as items 2 and 3 together.
import Mathlib import Definitions.Def_ControlledWorldModels_Basic open MeasureTheory ProbabilityTheory
namespace ControlledWorldModels
theorem optimal_predictor_predictable_energy {d m : ℕ} (A : Matrix (Fin d) (Fin d) ℝ) (B : Matrix (Fin d) (Fin m) ℝ)
(μ : Measure ((Fin d → ℝ) × (Fin m → ℝ))) (ν : Measure (Fin d → ℝ))
(hpol : IsJointGaussianPolicy μ) (htr : IsStationaryTransition A B μ ν)
(e : (Fin d → ℝ) → Fin d → ℝ) (he : IsAdmissible e) :
(∃ Fstar : (Fin d → ℝ) → (Fin m → ℝ) → Fin d → ℝ, Measurable (Function.uncurry Fstar) ∧
(fun ω : Sample d m => Fstar (e ω.1.1) ω.1.2) =ᵐ[μ.prod ν] condPred A B μ ν e ∧
∀ F : (Fin d → ℝ) → (Fin m → ℝ) → Fin d → ℝ, Measurable (Function.uncurry F) →
loss A B μ ν e Fstar ≤ loss A B μ ν e F) ∧
∫⁻ ω, ENNReal.ofReal (sqNorm (e (nextState A B ω))) ∂(μ.prod ν) = ENNReal.ofReal d ∧
predEnergy A B μ ν e ≤ ENNReal.ofReal d ∧
(⨅ (F : (Fin d → ℝ) → (Fin m → ℝ) → Fin d → ℝ) (_ : Measurable (Function.uncurry F)),
loss A B μ ν e F) = ENNReal.ofReal d - predEnergy A B μ ν e := by sorry
end ControlledWorldModelsRead-back
What the Lean code literally says, in plain math · claude-opus-5-5
Fix natural numbers (latent dimension) and (action dimension). Either may be ; for the space is a single point and every squared norm below is . Let and be arbitrary real matrices. Let be a measure on , the law of a state–action pair , and let be a measure on , the law of a noise vector . Write for the product of independent standard normals on , and .
Hypotheses.
- Policy hypothesis on .
- is a Gaussian measure on . In particular it is a probability measure, and every continuous linear functional has a real Gaussian law.
- has mean .
- Its first marginal (the law of ) is exactly .
- Nothing else is assumed about the action marginal or the dependence between and .
- Transition hypothesis on , , , .
- is a Gaussian (probability) measure on with mean .
- Draw , so that is independent of . Then the next state
has law exactly $N(0, I_d)$.
- Admissible encoder. is Borel measurable, and it pushes forward to . That is, whenever . No invertibility, linearity or continuity of is assumed.
Quantities. All expectations below are taken under on samples , with .
- Prediction loss. For a predictor ,
- Conditional predictor. is the measure-theoretic conditional expectation . Here is the -algebra on sample space generated by the pair . This is a random vector on sample space, defined up to -null sets.
- Predictable energy.
Conclusion. The theorem asserts the conjunction of four statements.
- An optimal predictor exists among measurable predictors. There is a jointly Borel-measurable such that both of the following hold:
- for -almost every ;
- for every jointly Borel-measurable .
- Second moment of the encoded next state.
- Energy bound.
- Optimal loss. The infimum of the loss over all jointly Borel-measurable predictors (not over any restricted predictor class) satisfies
Here the subtraction is in and truncated at . Given item 3, it coincides with ordinary subtraction .
Remarks on the statement.
- The matrices and enter the conclusion only through . None of , , or appears explicitly in the numerical values and , except via .
- The hypotheses are jointly satisfiable. For example, take , , , and the identity.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.