Documentation

LeanMachineLearning.SequentialLearning.BayesStationaryEnv

Bayesian stationary environments #

A Bayesian stationary environment is an environment that draws a parameter e : ๐“” from a prior Q before the first round and then behaves like the stationary environment stationaryEnv (ฮบ.sectR e). Concretely, bayesStationaryEnv Q ฮบ : Environment ๐“” ๐“ ๐“จ announces an observation e at every round and runs against alg.comapObs (fun _ โ†ฆ ()), for an alg : Algorithm Unit ๐“ ๐“จ, an algorithm that does not use the observation.

Main definitions #

Main results #

noncomputable def Learning.bayesStationaryEnv {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] :
Environment ๐“” ๐“ ๐“จ

The environment that draws a parameter e : ๐“” from Q before the first round, announces it as the observation of every round, and returns a feedback drawn from ฮบ (e, a) when the action is a. The algorithm is meant to ignore the announced parameter, that is, to run through Algorithm.comapObs (fun _ โ†ฆ ()).

Equations
  • One or more equations did not get rendered due to their size.
Instances For
    @[simp]
    theorem Learning.obs_bayesStationaryEnv_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] :
    (bayesStationaryEnv Q ฮบ).obs 0 = ProbabilityTheory.Kernel.const (Hist ๐“” ๐“ ๐“จ 0) Q
    @[simp]
    theorem Learning.obs_bayesStationaryEnv_succ {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] (n : โ„•) :
    (bayesStationaryEnv Q ฮบ).obs (n + 1) = ProbabilityTheory.Kernel.deterministic (fun (h : Hist ๐“” ๐“ ๐“จ (n + 1)) => (h 0).obs) โ‹ฏ
    @[simp]
    theorem Learning.feedback_bayesStationaryEnv {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] (n : โ„•) :
    (bayesStationaryEnv Q ฮบ).feedback n = ฮบ.comap (fun (p : (Hist ๐“” ๐“ ๐“จ n ร— ๐“”) ร— ๐“) => (p.1.2, p.2)) โ‹ฏ
    @[simp]
    theorem Learning.obs0_bayesStationaryEnv {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] :
    @[simp]
    theorem Learning.ฮฝ0_bayesStationaryEnv {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] :
    (bayesStationaryEnv Q ฮบ).ฮฝ0 = ฮบ
    def Learning.announceHist {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} (e : ๐“”) {n : โ„•} (h : Hist Unit ๐“ ๐“จ n) :
    Hist ๐“” ๐“ ๐“จ n

    Insert an announced parameter e as the observation of every round of an observable history.

    Equations
    Instances For
      theorem Learning.measurable_announceHist {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] (n : โ„•) :
      Measurable fun (p : ๐“” ร— Hist Unit ๐“ ๐“จ n) => announceHist p.1 p.2
      def Learning.IsBayesAlgEnvSeq {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) (E : ฮฉ โ†’ ๐“”) (A : โ„• โ†’ ฮฉ โ†’ ๐“) (Y : โ„• โ†’ ฮฉ โ†’ ๐“จ) (P : MeasureTheory.Measure ฮฉ) [MeasureTheory.IsProbabilityMeasure P] :

      IsBayesAlgEnvSeq Q ฮบ alg E A Y P states that there is a measure P : Measure ฮฉ such that the parameter E : ฮฉ โ†’ ๐“” has law Q and that the sequences of actions A : โ„• โ†’ ฮฉ โ†’ ๐“ and feedbacks Y : โ„• โ†’ ฮฉ โ†’ ๐“จ are generated by the algorithm alg : Algorithm Unit ๐“ ๐“จ interacting with an underlying environment that depends on E and ฮบ (stationaryEnv (ฮบ.sectR (E ฯ‰))).

      This is IsAlgEnvSeq for the announcing environment bayesStationaryEnv Q ฮบ and the algorithm alg.comapObs (fun _ โ†ฆ ()) that ignores the announced parameter: the observation at every round is E ฯ‰.

      Equations
      Instances For
        theorem Learning.IsBayesAlgEnvSeq.isAlgEnvSeq {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :
        IsAlgEnvSeq (fun (x : โ„•) => E) A Y (alg.comapObs (fun (x : ๐“”) => ()) โ‹ฏ) (bayesStationaryEnv Q ฮบ) P

        A Bayesian algorithm-environment sequence is an algorithm-environment sequence for the announcing environment bayesStationaryEnv Q ฮบ.

        theorem Learning.IsBayesAlgEnvSeq.measurable_param {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :
        theorem Learning.IsBayesAlgEnvSeq.measurable_action {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        theorem Learning.IsBayesAlgEnvSeq.measurable_feedback {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        theorem Learning.IsBayesAlgEnvSeq.hasLaw_env {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :

        The parameter has law Q.

        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_action {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        ProbabilityTheory.HasCondDistrib (A n) (fun (ฯ‰ : ฮฉ) => (E ฯ‰, history (noObs ฮฉ) A Y n ฯ‰, noObs ฮฉ n ฯ‰)) (ProbabilityTheory.Kernel.prodMkLeft ๐“” (alg.policy n)) P

        The action at time n has the correct conditional distribution given the parameter and the history: it depends only on the history.

        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_feedback {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        ProbabilityTheory.HasCondDistrib (Y n) (fun (ฯ‰ : ฮฉ) => ((history (noObs ฮฉ) A Y n ฯ‰, noObs ฮฉ n ฯ‰), E ฯ‰, A n ฯ‰)) (ProbabilityTheory.Kernel.prodMkLeft (Hist Unit ๐“ ๐“จ n ร— Unit) ฮบ) P

        The feedback at time n has the correct conditional distribution given the history, the parameter and the action at time n: it depends only on the parameter and the action.

        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_action' {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        ProbabilityTheory.HasCondDistrib (A n) (fun (ฯ‰ : ฮฉ) => (history (noObs ฮฉ) A Y n ฯ‰, noObs ฮฉ n ฯ‰)) (alg.policy n) P
        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_feedback' {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        ProbabilityTheory.HasCondDistrib (Y n) (fun (ฯ‰ : ฮฉ) => (E ฯ‰, A n ฯ‰)) ฮบ P
        theorem Learning.IsBayesAlgEnvSeq.hasLaw_action_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :
        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_action_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :

        The first action is independent of the parameter E, and has law alg.p0 ().

        theorem Learning.IsBayesAlgEnvSeq.condDistrib_param_history_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“”] [Nonempty ๐“”] (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :
        ๐“›[E | history (noObs ฮฉ) A Y 0; P] = ProbabilityTheory.Kernel.const (Hist Unit ๐“ ๐“จ 0) Q

        The posterior over the parameter given the empty history is the prior.

        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_IT_obs {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“] [Nonempty ๐“] [StandardBorelSpace ๐“จ] [Nonempty ๐“จ] (_h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_IT_action {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“] [Nonempty ๐“] [StandardBorelSpace ๐“จ] [Nonempty ๐“จ] (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        โˆ€แต (e : ๐“”) โˆ‚Q, ProbabilityTheory.HasCondDistrib (IT.action n) (fun (ฯ„ : โ„• โ†’ Round Unit ๐“ ๐“จ) => (IT.hist n ฯ„, IT.obs n ฯ„)) (alg.policy n) (๐“›[trajectory (noObs ฮฉ) A Y | E; P] e)
        theorem Learning.IsBayesAlgEnvSeq.hasCondDistrib_IT_feedback {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“] [Nonempty ๐“] [StandardBorelSpace ๐“จ] [Nonempty ๐“จ] (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        โˆ€แต (e : ๐“”) โˆ‚Q, ProbabilityTheory.HasCondDistrib (IT.feedback n) (fun (ฯ„ : โ„• โ†’ Round Unit ๐“ ๐“จ) => ((IT.hist n ฯ„, IT.obs n ฯ„), IT.action n ฯ„)) (ProbabilityTheory.Kernel.prodMkLeft (Hist Unit ๐“ ๐“จ n ร— Unit) (ฮบ.sectR e)) (๐“›[trajectory (noObs ฮฉ) A Y | E; P] e)
        theorem Learning.IsBayesAlgEnvSeq.hasLaw_IT_hist {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“] [Nonempty ๐“] [StandardBorelSpace ๐“จ] [Nonempty ๐“จ] (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) (n : โ„•) :
        โˆ€แต (e : ๐“”) โˆ‚Q, ProbabilityTheory.HasLaw (IT.hist n) (๐“›[history (noObs ฮฉ) A Y n | E; P] e) (๐“›[trajectory (noObs ฮฉ) A Y | E; P] e)
        theorem Learning.IsBayesAlgEnvSeq.ae_IsAlgEnvSeq {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] {E : ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} [StandardBorelSpace ๐“] [Nonempty ๐“] [StandardBorelSpace ๐“จ] [Nonempty ๐“จ] (h : IsBayesAlgEnvSeq Q ฮบ alg E A Y P) :
        theorem Learning.IsAlgEnvSeq.ae_obs_eq_obs_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {O : โ„• โ†’ ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] [StandardBorelSpace ๐“”] (h : IsAlgEnvSeq O A Y (alg.comapObs (fun (x : ๐“”) => ()) โ‹ฏ) (bayesStationaryEnv Q ฮบ) P) (n : โ„•) :
        O 0 =แต[P] O n

        Under bayesStationaryEnv Q ฮบ, the announced parameter is almost surely the same at every round.

        theorem Learning.IsAlgEnvSeq.isBayesAlgEnvSeq {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} {ฮฉ : Type u_4} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [MeasurableSpace ฮฉ] {Q : MeasureTheory.Measure ๐“”} [MeasureTheory.IsProbabilityMeasure Q] {ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ} [ProbabilityTheory.IsMarkovKernel ฮบ] {alg : Algorithm Unit ๐“ ๐“จ} {O : โ„• โ†’ ฮฉ โ†’ ๐“”} {A : โ„• โ†’ ฮฉ โ†’ ๐“} {Y : โ„• โ†’ ฮฉ โ†’ ๐“จ} {P : MeasureTheory.Measure ฮฉ} [MeasureTheory.IsProbabilityMeasure P] [StandardBorelSpace ๐“”] (h : IsAlgEnvSeq O A Y (alg.comapObs (fun (x : ๐“”) => ()) โ‹ฏ) (bayesStationaryEnv Q ฮบ) P) :
        IsBayesAlgEnvSeq Q ฮบ alg (O 0) A Y P

        A run of alg.comapObs (fun _ โ†ฆ ()) against the announcing environment bayesStationaryEnv Q ฮบ is a Bayesian algorithm-environment sequence for the announced parameter.

        noncomputable def Learning.IT.bayesTrajMeasure {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) :
        MeasureTheory.Measure (โ„• โ†’ Round ๐“” ๐“ ๐“จ)

        A measure P on a measurable space that carries random variables E, A, and Y such that IsBayesAlgEnvSeq Q ฮบ alg E A Y P. The parameter is the observation of the first round, IT.obs 0.

        Equations
        Instances For
          instance Learning.IT.instIsProbabilityMeasureForallNatRoundBayesTrajMeasure {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) :
          theorem Learning.IT.isBayesAlgEnvSeq_bayesTrajMeasure {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [StandardBorelSpace ๐“”] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) :
          IsBayesAlgEnvSeq Q ฮบ alg (obs 0) action feedback (bayesTrajMeasure Q ฮบ alg)
          noncomputable def Learning.IT.bayesTrajMeasurePosterior {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [StandardBorelSpace ๐“”] [Nonempty ๐“”] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) (n : โ„•) :
          ProbabilityTheory.Kernel (Hist Unit ๐“ ๐“จ n) ๐“”

          A kernel that represents the posterior over E given the history before time n.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            instance Learning.IT.instIsMarkovKernelHistUnitBayesTrajMeasurePosterior {๐“” : Type u_3} {๐“ : Type u_1} {๐“จ : Type u_2} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [StandardBorelSpace ๐“”] [Nonempty ๐“”] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) (n : โ„•) :
            theorem Learning.IT.bayesTrajMeasurePosterior_zero {๐“” : Type u_1} {๐“ : Type u_2} {๐“จ : Type u_3} [MeasurableSpace ๐“”] [MeasurableSpace ๐“] [MeasurableSpace ๐“จ] [StandardBorelSpace ๐“”] [Nonempty ๐“”] (Q : MeasureTheory.Measure ๐“”) [MeasureTheory.IsProbabilityMeasure Q] (ฮบ : ProbabilityTheory.Kernel (๐“” ร— ๐“) ๐“จ) [ProbabilityTheory.IsMarkovKernel ฮบ] (alg : Algorithm Unit ๐“ ๐“จ) :
            bayesTrajMeasurePosterior Q ฮบ alg 0 = ProbabilityTheory.Kernel.const (Hist Unit ๐“ ๐“จ 0) Q

            The posterior given the empty history is the prior.