GOVERNED ACTION

Four Lean 4 theorem files on the legitimacy of authority, the residues of attestation, the achievability of containment, and the information-theoretic floor of trust — kernel-checkable, no mathlib, no sorry.

David Lee Wise · TriPod LLC · CC-BY-ND-4.0

What this page is, and is not

Below is the actual Lean 4 source of four theorem files, unedited. No Lean toolchain was available in the environment that built this page, so nothing here was re-run against the Lean kernel to produce this page — there is no "compiles ✓" badge, because that would not be true. What can honestly be said: every line was read, no file contains sorry or an admitted gap, and the syntax uses only Lean 4 core (no mathlib import). Verify it yourself: lean governance.lean, and so on for the other three. Each file ends with its own "Honest scope" note, kept intact below — read those before the theorem, not after.

I · Governance — no complete, legitimate authority

A locus is legitimate only if it has a distinct legitimate governor. From that one recurrence, three things follow: an ungoverned "top" is never legitimate (the dogmatic horn — authority that answers to nothing is self-asserted, not earned); a locus that only governs itself can't be legitimate either (the cycle horn — reflexive authority fails the distinctness requirement); and if legitimacy is defined as the smallest predicate closed under that recurrence with no base case, it's empty — nothing satisfies it (the regress horn). No structure is both complete and fully legitimate. A companion lemma: an agent that sets its own boundary always weakly prefers to widen it — self-set boundaries are ratchets, not walls.

theorem top_not_legit
    {G : Locus → Locus → Prop} {L : Locus → Prop}
    (hL : IsLegitimacyPred G L) {T : Locus} (hT : IsTop G T) : ¬ L T := by
  intro hLT
  obtain ⟨x, _, hGxT, _⟩ := hL T hLT
  exact hT x hGxT

theorem no_self_ground
    {G : Locus → Locus → Prop} {L : Locus → Prop}
    (hL : IsLegitimacyPred G L) {y : Locus}
    (hLy : L y) (onlySelf : ∀ x, G x y → x = y) : False := by
  obtain ⟨x, hne, hGxy, _⟩ := hL y hLy
  exact hne (onlySelf x hGxy)

theorem regress_empty {G : Locus → Locus → Prop} (y : Locus) :
    ¬ LegitLFP G y := by
  intro h; induction h with
  | step _ _ _ ih => exact ih

theorem value_monotone
    {A : Type} {u : A → Nat} {B B' : A → Prop}
    (hsub : ∀ a, B a → B' a)
    {aStar : A} (hB : B aStar) (hmax : ∀ a, B a → u a ≤ u aStar) :
    ∃ b, B' b ∧ ∀ a, B a → u a ≤ u b :=
  ⟨aStar, hsub aStar hB, hmax⟩
Honest scope (from governance.lean): Lemma 1 (pre-action/set-level timing) is a timing argument over an execution model, not formalized as a finite proposition. T1's "infinite ⇒ inert" step encodes a semantics of "authority is exercised" that is a modeling choice. What IS checked: a top is not legitimate, self-grounding fails, least-fixed-point legitimacy is empty. These are proofs relative to the definitions — they assert nothing about any real system.

finite illustration — try to name a legitimate top

Four loci, each governed by the next. Click one to mark it "the top" (ungoverned). The proof says: whatever you pick, it can't be legitimate.

pick a node above

II · Attestation — the three ways exteriority relocates

A sound attestation discharges containment with no requirement that the checker be exterior to the selector — so where does "exterior" actually have to live? Three places, and removing any one collapses the certificate: (i) the spec — if the agent can weaken its own spec, it ratchets to the vacuous predicate True, which every trace satisfies, including violating ones; (ii) the trust root — if the verifier's own soundness is only self-attested, the evaluator's own rule (reject self-attested evidence) blocks acceptance outright; (iii) timing — a verdict computed after an irreversible action never enters the containment predicate, so it can't retroactively make a violating trace contained. Given all three exterior conditions, containment is sufficient — necessity is carried by these three residues.

theorem vacuous_certifies_nothing
    {A : Type} (admStrict : A → Prop) (tr : Trace A)
    (someViolation : ∃ t, ¬ admStrict (tr t)) :
    Contained (fun _ => True) tr ∧ ¬ Contained admStrict tr := by
  refine ⟨fun _ => trivial, ?_⟩
  obtain ⟨t₀, hv⟩ := someViolation
  intro h; exact hv (h t₀)

theorem root_selfattested_fails
    {Ev : Type} {AccE selfAttested : Ev → Prop}
    (C4 : ∀ e, selfAttested e → ¬ AccE e)
    {soundnessClaim : Ev} (hself : selfAttested soundnessClaim) :
    ¬ AccE soundnessClaim :=
  C4 soundnessClaim hself

theorem postaction_insufficient
    {A : Type} (adm : A → Prop) (tr : Trace A)
    {t₀ : Nat} (violation : ¬ adm (tr t₀)) :
    ¬ Contained adm tr := by
  intro h; exact violation (h t₀)
Honest scope (from attestation.lean): discharge and root_selfattested_fails are near-definitional (modus ponens/tollens on the stated hypotheses). vacuous_certifies_nothing fixes that a self-chosen spec certifies nothing informative — it does not fix the magnitude of the resulting gap. The full timing/latency execution model is not formalized. relocation proves sufficiency of the three exterior conditions; necessity is carried by the residue lemmas, not bundled into one iff.

III · Achievability — pre-action gating into an adequate boundary

Given a fixed, exterior-supplied verifier that is sound and complete for a boundary B, and B is adequate (a subset of the target set A*): gating every action through the verifier before it executes puts every executed action in A* — containment, with no exterior information entering per-action. Two side conditions make the gate honest rather than trivial: completeness means it never blocks an admissible action (liveness — no false rejections), and soundness means it genuinely rejects anything outside B (non-vacuity — the gate actually bites).

theorem achiev_correct
    {A : Type} (V : A → Bool) (B Astar : A → Prop)
    (Vsound : ∀ a, V a = true → B a)
    (Badeq : ∀ a, B a → Astar a)
    (tr : Trace A) (gated : ∀ t, V (tr t) = true) :
    ∀ t, Astar (tr t) := by
  intro t; exact Badeq _ (Vsound _ (gated t))

theorem achiev_live
    {A : Type} (V : A → Bool) (B : A → Prop)
    (Vcomplete : ∀ a, B a → V a = true)
    {a : A} (hB : B a) : V a = true := Vcomplete a hB

theorem rejects_excluded
    {A : Type} (V : A → Bool) (B : A → Prop)
    (Vsound : ∀ a, V a = true → B a)
    {a : A} (hnotB : ¬ B a) : V a = false := by
  cases hva : V a with
  | false => rfl
  | true => exact absurd (Vsound a hva) hnotB
Honest scope (from achievability.lean): this is the ZERO-ERROR idealization — Vsound/Vcomplete are exact. A real proof system has soundness error 2⁻λ per proof; over T actions the union bound gives total error ≤ T·2⁻λ. Cost (that exterior information = log₂N + λ + 0) is an accounting argument, not a theorem, made in the companion note. Achievability is relative to the existence of such a proof system — it is not constructed from scratch here.

IV · The trust floor — soundness forces a minimum entropy

If the best key-guessing forgery succeeds on at least one key out of the secret's support, and soundness bounds any forgery to at most a 2⁻λ fraction of that support, then the support must have size at least 2^λ — the secret's min-entropy is at least λ bits. A claimed soundness of 2⁻λ is not free: it costs a trust anchor with at least λ bits of uncertainty behind it, or it's impossible.

theorem trust_floor (NK lam fcount : Nat)
    (hguess : 1 ≤ fcount)
    (hsound : fcount * 2 ^ lam ≤ NK) :
    2 ^ lam ≤ NK := by
  obtain ⟨f', hf'⟩ : ∃ f', fcount = f' + 1 := ⟨fcount - 1, by omega⟩
  have hexp : fcount * 2 ^ lam = f' * 2 ^ lam + 2 ^ lam := by
    rw [hf', Nat.add_mul, Nat.one_mul]
  omega

theorem short_key_breaks_soundness (NK lam fcount : Nat)
    (hguess : 1 ≤ fcount) (hshort : NK < 2 ^ lam) :
    ¬ (fcount * 2 ^ lam ≤ NK) := by
  intro hsound
  have := trust_floor NK lam fcount hguess hsound
  omega
Honest scope (from trust_floor.lean): the load-bearing assumption is "an adversary who knows the secret K can forge" — real for MACs / designated-verifier / secret-coin proofs / TEE keys, NOT for computationally-sound public-coin systems like SNARKs, where a key-knowing adversary still can't forge without breaking a hardness assumption. That regime's trust floor is the hardness assumption, not bits of entropy. The general statement (optimal guessing probability = 2⁻H∞ for arbitrary distributions) is standard analysis, stated but not formalized here — only the uniform counting core is.

check the bound yourself