MindFormal v1.0.0One Mind

MindFormal.Chapters.Ch07Concepts.CriterionConsequences

Finite criterion scoring retains the prefix. A streak s needs 32-s new correct responses. Nothing here asserts an uncensored error mean.

def MindFormal.Concepts.criterion32 (correct : ℕ → Prop) (k : ℕ) :

The lab's consecutive-correct criterion, as a predicate on correctness.

Equations
Instances For
    noncomputable def MindFormal.Concepts.errorsUntil (correct : ℕ → Prop) (k : ℕ) :

    Ordinary charged error count, without discarding the acquisition prefix.

    Equations
    Instances For
      theorem MindFormal.Concepts.criterion_not_before_needed {r s : ℕ} (hs : s < 32) (hsr : s ≤ r) (correct : ℕ → Prop) (unfinished : ∀ k ≤ r, ¬criterion32 correct k) (previous : s < r → ¬correct (r - s - 1)) (k : ℕ) :
      k < r + (32 - s) → ¬criterion32 correct k

      Regardless of the continuation, a current streak s cannot complete the criterion in fewer than 32-s more trials. The actual earlier prefix must itself be unfinished.

      theorem MindFormal.Concepts.criterion_at_needed {r s : ℕ} (hs : s < 32) (hsr : s ≤ r) (correct : ℕ → Prop) (streak : ∀ (k : ℕ), r - s ≤ k → k < r → correct k) (continuation : ∀ (k : ℕ), r ≤ k → k < r + (32 - s) → correct k) :
      criterion32 correct (r + (32 - s))

      The last s correct prefix responses followed by precisely 32-s correct responses complete the criterion at the advertised total count.

      theorem MindFormal.Concepts.errorsUntil_preserve_prefix {r K : ℕ} (hrK : r ≤ K) (correct : ℕ → Prop) (continuation : ∀ (k : ℕ), r ≤ k → k < K → correct k) :
      errorsUntil correct K = errorsUntil correct r
      theorem MindFormal.Concepts.global_prefix_probability {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_2} {Λ : Type u_3} {J : Type u_4} [Fintype T] [Fintype Λ] [Fintype J] (C : StateLearning Ω N n T Λ J) (contained : C.Contained) (input : C.control.εu = 0) {K : ℕ} (label : Ω → Fin K → Fin N) (lo hi : Ω → Fin K → ℝ) (w : (z : Ω) → z ∈ C.run.good → (q : Fin K) → LearningWindowMargins C.run z (label z q) (lo z q) (hi z q)) (initial : ∀ (z : Ω) (hz : z ∈ C.run.good) (h : 0 < K), (w z hz ⟨0, h⟩).phase ≤ 0) (next : ∀ (z : Ω) (hz : z ∈ C.run.good) (q : Fin K) (h : ↑q + 1 < K), (w z hz ⟨↑q + 1, h⟩).phase ≤ lo z q + C.run.data.pause false ∧ hi z q + C.run.data.pause false ≤ hi z ⟨↑q + 1, h⟩) (event : Ω → (Fin K → Fin N ⊕ Unit) → Prop) :
      |C.run.data.μ.real {z : Ω | event z fun (q : Fin K) => ((C.experiment.supportHistory z).event false ↑q).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2} - C.run.data.μ.real {z : Ω | event z fun (q : Fin K) => Sum.inl (label z q)}| ≤ C.control.failure

      The uncensored original history has the same finite event transfer as the learning record. Agreement is derived almost surely from own-noise identification and every propagated native release.

      theorem MindFormal.Concepts.native_criterion_completion {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_2} {Λ : Type u_3} {J : Type u_4} [Fintype T] [Fintype Λ] [Fintype J] (C : StateLearning Ω N n T Λ J) (contained : C.Contained) (input : C.control.εu = 0) {r s : ℕ} (hs : s < 32) (hsr : s ≤ r) (answer : Ω → ℕ → Fin N) (label : Ω → Fin (r + (32 - s)) → Fin N) (lo hi : Ω → Fin (r + (32 - s)) → ℝ) (w : (z : Ω) → z ∈ C.run.good → (q : Fin (r + (32 - s))) → LearningWindowMargins C.run z (label z q) (lo z q) (hi z q)) (initial : ∀ (z : Ω) (hz : z ∈ C.run.good) (h : 0 < r + (32 - s)), (w z hz ⟨0, h⟩).phase ≤ 0) (next : ∀ (z : Ω) (hz : z ∈ C.run.good) (q : Fin (r + (32 - s))) (h : ↑q + 1 < r + (32 - s)), (w z hz ⟨↑q + 1, h⟩).phase ≤ lo z q + C.run.data.pause false ∧ hi z q + C.run.data.pause false ≤ hi z ⟨↑q + 1, h⟩) (unfinished : ∀ (z : Ω), ∀ k ≤ r, ¬criterion32 (fun (j : ℕ) => ∃ (hj : j < r + (32 - s)), label z ⟨j, hj⟩ = answer z j) k) (previous : ∀ (z : Ω), s < r → label z ⟨r - s - 1, ⋯⟩ ≠ answer z (r - s - 1)) (streak : ∀ (z : Ω) (k : ℕ), r - s ≤ k → ∀ (hk : k < r), label z ⟨k, ⋯⟩ = answer z k) (continuation : ∀ (z : Ω) (q : Fin (r + (32 - s))), r ≤ ↑q → label z q = answer z ↑q) :
      have correct := fun (z : Ω) (k : ℕ) => ∃ (_ : k < r + (32 - s)), (((C.experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (answer z k); 1 - C.control.failure ≤ C.run.data.μ.real {z : Ω | (∀ (q : Fin (r + (32 - s))), ↑q < r → (((C.experiment.supportHistory z).event false ↑q).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (label z q)) ∧ criterion32 (correct z) (r + (32 - s)) ∧ (∀ k < r + (32 - s), ¬criterion32 (correct z) k) ∧ errorsUntil (correct z) (r + (32 - s)) = errorsUntil (correct z) r}

      A full carried certificate proves completion after 32-s additional responses, zero added errors and exact retention of the prefix score. The event reads the original global history, including prefix slots.

      theorem MindFormal.Concepts.native_criterion_error {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_2} {Λ : Type u_3} {J : Type u_4} [Fintype T] [Fintype Λ] [Fintype J] (C : StateLearning Ω N n T Λ J) (contained : C.Contained) (input : C.control.εu = 0) {r s : ℕ} (hs : s < 32) (hsr : s ≤ r) (answer : Ω → ℕ → Fin N) (label : Ω → Fin (r + (32 - s)) → Fin N) (lo hi : Ω → Fin (r + (32 - s)) → ℝ) (w : (z : Ω) → z ∈ C.run.good → (q : Fin (r + (32 - s))) → LearningWindowMargins C.run z (label z q) (lo z q) (hi z q)) (initial : ∀ (z : Ω) (hz : z ∈ C.run.good) (h : 0 < r + (32 - s)), (w z hz ⟨0, h⟩).phase ≤ 0) (next : ∀ (z : Ω) (hz : z ∈ C.run.good) (q : Fin (r + (32 - s))) (h : ↑q + 1 < r + (32 - s)), (w z hz ⟨↑q + 1, h⟩).phase ≤ lo z q + C.run.data.pause false ∧ hi z q + C.run.data.pause false ≤ hi z ⟨↑q + 1, h⟩) (unfinished : ∀ (z : Ω), ∀ k ≤ r, ¬criterion32 (fun (j : ℕ) => ∃ (hj : j < r + (32 - s)), label z ⟨j, hj⟩ = answer z j) k) (previous : ∀ (z : Ω), s < r → label z ⟨r - s - 1, ⋯⟩ ≠ answer z (r - s - 1)) (display : Fin (32 - s) → Ω → Bool) (meas : ∀ (j : Fin (32 - s)), Measurable (display j)) (independent : ProbabilityTheory.iIndepFun display C.run.data.μ) (balanced : ∀ (j : Fin (32 - s)), C.run.data.μ {z : Ω | display j z = true} = ENNReal.ofReal (1 / 2)) (pattern : ∀ (z : Ω) (q : Fin (r + (32 - s))), r ≤ ↑q → (label z q = answer z ↑q ↔ display ⟨↑q - r, ⋯⟩ z = true)) :
      have correct := fun (z : Ω) (k : ℕ) => ∃ (_ : k < r + (32 - s)), (((C.experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (answer z k); 1 - (1 / 2) ^ (32 - s) - C.control.failure ≤ C.run.data.μ.real {z : Ω | ∃ (q : Fin (r + (32 - s))), r ≤ ↑q ∧ (∃ (t : ℝ) (o : Fin N), (C.experiment.supportHistory z).event false ↑q = some (t, o) ∧ o ≠ answer z ↑q) ∧ ∀ k ≤ ↑q, ¬criterion32 (correct z) k}

      An unloaded VI error occurs before criterion with the charged streak s. Only the received displays are independent; the native responses are obtained from the same carried full-state windows.

      theorem MindFormal.Concepts.native_sorting_criterion {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_2} {Λ : Type u_3} {J : Type u_4} [Fintype T] [Fintype Λ] [Fintype J] (C : Bool → Fin 2 → StateLearning Ω N n T Λ J) (contained : ∀ (d : Bool) (i : Fin 2), (C d i).Contained) (input : ∀ (d : Bool) (i : Fin 2), (C d i).control.εu = 0) (r s : Fin 2 → ℕ) (hs : ∀ (i : Fin 2), s i < 32) (hsr : ∀ (i : Fin 2), s i ≤ r i) (answer : Fin 2 → Ω → ℕ → Fin N) (label : Bool → (i : Fin 2) → Ω → Fin (r i + (32 - s i)) → Fin N) (lo hi : Bool → (i : Fin 2) → Ω → Fin (r i + (32 - s i)) → ℝ) (w : (d : Bool) → (i : Fin 2) → (z : Ω) → z ∈ (C d i).run.good → (q : Fin (r i + (32 - s i))) → LearningWindowMargins (C d i).run z (label d i z q) (lo d i z q) (hi d i z q)) (initial : ∀ (d : Bool) (i : Fin 2) (z : Ω) (hz : z ∈ (C d i).run.good) (h : 0 < r i + (32 - s i)), (w d i z hz ⟨0, h⟩).phase ≤ 0) (next : ∀ (d : Bool) (i : Fin 2) (z : Ω) (hz : z ∈ (C d i).run.good) (q : Fin (r i + (32 - s i))) (h : ↑q + 1 < r i + (32 - s i)), (w d i z hz ⟨↑q + 1, h⟩).phase ≤ lo d i z q + (C d i).run.data.pause false ∧ hi d i z q + (C d i).run.data.pause false ≤ hi d i z ⟨↑q + 1, h⟩) (unfinished : ∀ (d : Bool) (i : Fin 2) (z : Ω), ∀ k ≤ r i, ¬criterion32 (fun (j : ℕ) => ∃ (hj : j < r i + (32 - s i)), label d i z ⟨j, hj⟩ = answer i z j) k) (previous : ∀ (d : Bool) (i : Fin 2) (z : Ω) (h : s i < r i), label d i z ⟨r i - s i - 1, ⋯⟩ ≠ answer i z (r i - s i - 1)) (streak : ∀ (d : Bool) (i : Fin 2) (z : Ω) (k : ℕ), r i - s i ≤ k → ∀ (hk : k < r i), label d i z ⟨k, ⋯⟩ = answer i z k) (samePrefix : ∀ (i : Fin 2) (z : Ω) (q : Fin (r i + (32 - s i))), ↑q < r i → label false i z q = label true i z q) (correct : ∀ (d : Bool) (i : Fin 2), d = true ∨ i = 0 → ∀ (z : Ω) (q : Fin (r i + (32 - s i))), r i ≤ ↑q → label d i z q = answer i z ↑q) (display : Fin (32 - s 1) → Ω → Bool) (meas : ∀ (j : Fin (32 - s 1)), Measurable (display j)) (μ : MeasureTheory.Measure Ω) [MeasureTheory.IsProbabilityMeasure μ] (sameMeasure : ∀ (d : Bool) (i : Fin 2), (C d i).run.data.μ = μ) (independent : ProbabilityTheory.iIndepFun display μ) (balanced : ∀ (j : Fin (32 - s 1)), μ {z : Ω | display j z = true} = ENNReal.ofReal (1 / 2)) (pattern : ∀ (z : Ω) (q : Fin (r 1 + (32 - s 1))) (hqr : r 1 ≤ ↑q), label false 1 z q = answer 1 z ↑q ↔ display ⟨↑q - r 1, ⋯⟩ z = true) :
      have ok := fun (d : Bool) (i : Fin 2) (z : Ω) (k : ℕ) => ∃ (_ : k < r i + (32 - s i)), ((((C d i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (answer i z k); have complete := fun (d : Bool) (i : Fin 2) (z : Ω) => (∀ (q : Fin (r i + (32 - s i))), ↑q < r i → ((((C d i).experiment.supportHistory z).event false ↑q).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (label d i z q)) ∧ criterion32 (ok d i z) (r i + (32 - s i)) ∧ (∀ k < r i + (32 - s i), ¬criterion32 (ok d i z) k) ∧ errorsUntil (ok d i z) (r i + (32 - s i)) = errorsUntil (ok d i z) (r i); (∀ (d : Bool) (i : Fin 2), d = true ∨ i = 0 → 1 - (C d i).control.failure ≤ μ.real {z : Ω | complete d i z}) ∧ 1 - (1 / 2) ^ (32 - s 1) - (C false 1).control.failure ≤ μ.real {z : Ω | ∃ (q : Fin (r 1 + (32 - s 1))), r 1 ≤ ↑q ∧ (∃ (t : ℝ) (o : Fin N), ((C false 1).experiment.supportHistory z).event false ↑q = some (t, o) ∧ o ≠ answer 1 z ↑q) ∧ ∀ k ≤ ↑q, ¬criterion32 (ok false 1 z) k} ∧ 1 - (C true 0).control.failure - (C true 1).control.failure ≤ μ.real {z : Ω | complete true 0 z ∧ complete true 1 z} ∧ 1 - (1 / 2) ^ (32 - s 1) - (C false 0).control.failure - (C false 1).control.failure ≤ μ.real {z : Ω | complete false 0 z ∧ ∃ (q : Fin (r 1 + (32 - s 1))), r 1 ≤ ↑q ∧ (∃ (t : ℝ) (o : Fin N), ((C false 1).experiment.supportHistory z).event false ↑q = some (t, o) ∧ o ≠ answer 1 z ↑q) ∧ ∀ k ≤ ↑q, ¬criterion32 (ok false 1 z) k} ∧ (∀ (z : Ω), complete true 0 z → complete true 1 z → ↑(errorsUntil (ok true 1 z) (r 1 + (32 - s 1))) - ↑(errorsUntil (ok true 0 z) (r 0 + (32 - s 0))) = ↑(errorsUntil (ok true 1 z) (r 1)) - ↑(errorsUntil (ok true 0 z) (r 0)) ∧ (errorsUntil (ok true 1 z) (r 1 + (32 - s 1)) = errorsUntil (ok true 0 z) (r 0 + (32 - s 0)) ↔ errorsUntil (ok true 1 z) (r 1) = errorsUntil (ok true 0 z) (r 0))) ∧ ∀ᵐ (z : Ω) ∂μ, (∀ (d : Bool) (i : Fin 2), z ∈ (C d i).run.good) → ∀ (i : Fin 2), ∀ k < r i, ((((C false i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = (((C true i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2

      The actual two-task criterion comparison. Both load arms carry their entire original prefixes, with the same source prefix in each assignment. The joint probability bills are the two relevant failures, not four. The loaded total scores retain exactly their charged prefix difference.

      theorem MindFormal.Concepts.native_sorting_criterion_robust {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_2} {Λ : Type u_3} {J : Type u_4} [Fintype T] [Fintype Λ] [Fintype J] (C : Bool → Fin 2 → StateLearning Ω N n T Λ J) (contained : ∀ (d : Bool) (i : Fin 2), (C d i).Contained) (input : ∀ (d : Bool) (i : Fin 2), (C d i).control.εu = 0) (r s : Fin 2 → ℕ) (hs : ∀ (i : Fin 2), s i < 32) (hsr : ∀ (i : Fin 2), s i ≤ r i) (answer : Fin 2 → Ω → ℕ → Fin N) (label : Bool → (i : Fin 2) → Ω → Fin (r i + (32 - s i)) → Fin N) (lo hi : Bool → (i : Fin 2) → Ω → Fin (r i + (32 - s i)) → ℝ) (w : (d : Bool) → (i : Fin 2) → (z : Ω) → z ∈ (C d i).run.good → (q : Fin (r i + (32 - s i))) → LearningWindowMargins (C d i).run z (label d i z q) (lo d i z q) (hi d i z q)) (initial : ∀ (d : Bool) (i : Fin 2) (z : Ω) (hz : z ∈ (C d i).run.good) (h : 0 < r i + (32 - s i)), (w d i z hz ⟨0, h⟩).phase ≤ 0) (next : ∀ (d : Bool) (i : Fin 2) (z : Ω) (hz : z ∈ (C d i).run.good) (q : Fin (r i + (32 - s i))) (h : ↑q + 1 < r i + (32 - s i)), (w d i z hz ⟨↑q + 1, h⟩).phase ≤ lo d i z q + (C d i).run.data.pause false ∧ hi d i z q + (C d i).run.data.pause false ≤ hi d i z ⟨↑q + 1, h⟩) (unfinished : ∀ (d : Bool) (i : Fin 2) (z : Ω), ∀ k ≤ r i, ¬criterion32 (fun (j : ℕ) => ∃ (hj : j < r i + (32 - s i)), label d i z ⟨j, hj⟩ = answer i z j) k) (previous : ∀ (d : Bool) (i : Fin 2) (z : Ω) (h : s i < r i), label d i z ⟨r i - s i - 1, ⋯⟩ ≠ answer i z (r i - s i - 1)) (streak : ∀ (d : Bool) (i : Fin 2) (z : Ω) (k : ℕ), r i - s i ≤ k → ∀ (hk : k < r i), label d i z ⟨k, ⋯⟩ = answer i z k) (samePrefix : ∀ (i : Fin 2) (z : Ω) (q : Fin (r i + (32 - s i))), ↑q < r i → label false i z q = label true i z q) (correct : ∀ (d : Bool) (i : Fin 2), d = true ∨ i = 0 → ∀ (z : Ω) (q : Fin (r i + (32 - s i))), r i ≤ ↑q → label d i z q = answer i z ↑q) (display : Fin (32 - s 1) → Ω → Bool) (meas : ∀ (j : Fin (32 - s 1)), Measurable (display j)) (μ : MeasureTheory.Measure Ω) [MeasureTheory.IsProbabilityMeasure μ] (sameMeasure : ∀ (d : Bool) (i : Fin 2), (C d i).run.data.μ = μ) (independent : ProbabilityTheory.iIndepFun display μ) (balanced : ∀ (j : Fin (32 - s 1)), μ {z : Ω | display j z = true} = ENNReal.ofReal (1 / 2)) (pattern : ∀ (z : Ω) (q : Fin (r 1 + (32 - s 1))) (hqr : r 1 ≤ ↑q), label false 1 z q = answer 1 z ↑q ↔ display ⟨↑q - r 1, ⋯⟩ z = true) (loadedMargin : (C true 0).control.failure + (C true 1).control.failure < 1) (unloadedMargin : (C false 0).control.failure + (C false 1).control.failure < 1 - (1 / 2) ^ (32 - s 1)) :
      have ok := fun (d : Bool) (i : Fin 2) (z : Ω) (k : ℕ) => ∃ (_ : k < r i + (32 - s i)), ((((C d i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (answer i z k); have complete := fun (d : Bool) (i : Fin 2) (z : Ω) => (∀ (q : Fin (r i + (32 - s i))), ↑q < r i → ((((C d i).experiment.supportHistory z).event false ↑q).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = Sum.inl (label d i z q)) ∧ criterion32 (ok d i z) (r i + (32 - s i)) ∧ (∀ k < r i + (32 - s i), ¬criterion32 (ok d i z) k) ∧ errorsUntil (ok d i z) (r i + (32 - s i)) = errorsUntil (ok d i z) (r i); (∀ (d : Bool) (i : Fin 2), d = true ∨ i = 0 → 1 - (C d i).control.failure ≤ μ.real {z : Ω | complete d i z}) ∧ 1 - (1 / 2) ^ (32 - s 1) - (C false 1).control.failure ≤ μ.real {z : Ω | ∃ (q : Fin (r 1 + (32 - s 1))), r 1 ≤ ↑q ∧ (∃ (t : ℝ) (o : Fin N), ((C false 1).experiment.supportHistory z).event false ↑q = some (t, o) ∧ o ≠ answer 1 z ↑q) ∧ ∀ k ≤ ↑q, ¬criterion32 (ok false 1 z) k} ∧ 0 < μ.real {z : Ω | complete true 0 z ∧ complete true 1 z} ∧ 0 < μ.real {z : Ω | complete false 0 z ∧ ∃ (q : Fin (r 1 + (32 - s 1))), r 1 ≤ ↑q ∧ (∃ (t : ℝ) (o : Fin N), ((C false 1).experiment.supportHistory z).event false ↑q = some (t, o) ∧ o ≠ answer 1 z ↑q) ∧ ∀ k ≤ ↑q, ¬criterion32 (ok false 1 z) k} ∧ (∀ (z : Ω), complete true 0 z → complete true 1 z → ↑(errorsUntil (ok true 1 z) (r 1 + (32 - s 1))) - ↑(errorsUntil (ok true 0 z) (r 0 + (32 - s 0))) = ↑(errorsUntil (ok true 1 z) (r 1)) - ↑(errorsUntil (ok true 0 z) (r 0)) ∧ (errorsUntil (ok true 1 z) (r 1 + (32 - s 1)) = errorsUntil (ok true 0 z) (r 0 + (32 - s 0)) ↔ errorsUntil (ok true 1 z) (r 1) = errorsUntil (ok true 0 z) (r 0))) ∧ ∀ᵐ (z : Ω) ∂μ, (∀ (d : Bool) (i : Fin 2), z ∈ (C d i).run.good) → ∀ (i : Fin 2), ∀ k < r i, ((((C false i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2) = (((C true i).experiment.supportHistory z).event false k).elim (Sum.inr ()) fun (p : ℝ × Fin N) => Sum.inl p.2

      Positive source margins make both paired native comparisons nontrivial.