Lemma 6: the optimal success probability of is binomial
ProvedGeneralAgentsWorldModels.lemma6_optimal_success_binomialLet the environment satisfy Assumption 1, let be states, actions, and . Let be the disjunction of all sequential goals
in which exactly of the equal and the other equal : the agent takes , then times goes to and takes , and the transition happens in exactly of these attempts. Then for every initial state ,
import Mathlib import Definitions.Def_GeneralAgentsWorldModels_Basic open Finset
namespace GeneralAgentsWorldModels
theorem lemma6_optimal_success_binomial {S A : Type*} [Fintype S] [DecidableEq S] [Fintype A]
(M : CMP S A) (hM : SatisfiesAssumption1 M) (s s' : S) (a b : A) (hss : s ≠ s')
(n r : ℕ) (hr : r ≤ n) (s₀ : S) :
optProb M (binGoal b s a s' n (· = r)) s₀ =
(n.choose r : ℝ) * M.P s a s' ^ r * (1 - M.P s a s') ^ (n - r) := by sorry
end GeneralAgentsWorldModelsRead-back
What the Lean code literally says, in plain math · claude-opus-5-5
Setting. Let be a finite set of states (with decidable equality) and a finite set of actions. Let be a controlled Markov process on and . It is given by transition numbers with and for every and . These numbers do not depend on time.
Hypothesis (Assumption 1). satisfies both of the following:
- Communicating. For any two distinct states there is a finite chain with . Each step must have for some action .
- At least two actions. .
Other variables.
- are two states with .
- are two actions. They may be equal.
- are natural numbers with .
- is an arbitrary initial state. It may equal , , or anything else.
Write . Nothing is assumed about ; it may be or .
The goal. For each outcome pattern , define the sequential goal
Here if is true, and if is false.
The composite goal is the disjunction of over all patterns with exactly true entries. There are such disjuncts.
Trajectories and satisfaction. A trajectory is an infinite sequence . It satisfies if some disjunct is satisfied when evaluated from time . A sequential goal is evaluated from a time as follows; the empty sequence is always satisfied.
- requires . The remaining sub-goals are then evaluated from .
- requires . The rest is evaluated from . For only the state matters.
- takes to be the first time with , and requires that such a exists. The rest is evaluated from .
Two consequences of these rules:
- "Eventually" includes the current time. So can be met at the very time where the previous sub-goal ended. This includes time when and .
- In plain terms, says: take action at time . Then, times in succession, wait for the first subsequent occasion of being in state while taking action . On each such occasion, the next state must be or not , according to .
Policies and success probability.
A policy is deterministic and history-dependent. It maps the list of past pairs and the current state to an action .
For , define as a sum over all sequences of next states . Each term is the product , counted only when the finite prefix generated by decides . A prefix decides the goal if every infinite trajectory beginning with that prefix satisfies it.
The success probability of from is
The optimal value is the supremum of this quantity over all deterministic history-dependent policies . Both suprema are taken in , where an unbounded or empty family would by convention have supremum .
Statement. Under the hypotheses above, for every initial state :
Here , and is ordinary subtraction because .
Degenerate cases.
- If , then . The goal is the single sequence and the right-hand side equals .
- If or , the right-hand side is when or respectively, and otherwise.
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.