Skip to content

Commit 83a3069

Browse files
committed
docs(machine-readable): surface PRs #79-#82 proof work to bot-coordination state
The Lean+Coq proof repair/extension (PRs #79-#82, merged) was invisible to the estate's bot-coordination layer. Surface it through the append-designed, session-end channels — no curated content overwritten: - debt.a2ml: carry-forward follow-ups as next-session Phase-0 input (Coq binop parity, Lean array typing, cap_subsumes_trans; Coq preservation rewrite, Lean float binops, echo-types L3 integration blueprint). - coverage.a2ml: record docs/proofs/verification/ as a visited component. - methodology.a2ml: populate divergent-invariants (provers are Lean 4 + Coq, not Idris2; admit/sorry stay zero; the Coq.Reals axioms are permitted, not escape hatches) and known-constraints (CI-gated + toolchain-pinned; complementary Lean/Coq subsets; PROOF-NEEDS #2 ill-posed pending a maintainer decision). - STATE.a2ml: add type-safety-proofs to [frontier]; add proof-gates and last-proof-shepherd to [ci]. Existing lines preserved. https://claude.ai/code/session_013wg3Mtq2QFhYi4XVw1Z6z7
1 parent 8e66f14 commit 83a3069

4 files changed

Lines changed: 69 additions & 11 deletions

File tree

.machine_readable/6a2/STATE.a2ml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
[metadata]
66
project = "wokelang"
77
version = "0.1.0"
8-
last-updated = "2026-06-12"
8+
last-updated = "2026-06-15"
99
status = "active"
1010

1111
[project-context]
@@ -27,11 +27,14 @@ proof-assistant = "Isabelle (preferred)"
2727
echo-types-source = "hyperpolymath/echo-types (constructive Agda formalization of fiber-based structured loss)"
2828
goal = "the language sorts the hard consent/affine-safety reasoning so users never have to"
2929
typechecker-note = "TypeChecker::new seeds a ~64-binding builtin prelude (incl. Result/echo constructors)"
30+
type-safety-proofs = "docs/proofs/verification/ — WokeLang.lean (Lean 4.30.0) + WokeLang.v (Coq 8.18.0): both compile sorry/admit/axiom-free (Coq only the unavoidable Coq.Reals classical+funext axioms from modelling float as the reals) and are CI-gated (lean-proofs.yml, coq-proofs.yml). Proven for the expression core: canonical_forms, progress, preservation, type_safety (multi-step), consent_{monotonicity,preservation}. Strict subset of the surface language; Lean/Coq cover complementary fragments. Repaired from bit-rot + extended 2026-06-14/15 (PRs #79-#82, merged). Full audit: docs/proofs/verification/AUDIT.md"
3031

3132
[ci]
3233
workflows = "20 GitHub Actions; thin-wrapper reusables from hyperpolymath/standards"
3334
gates = "rust-ci, dogfood-gate, e2e (Rust+OCaml), governance, security, codeql, scorecard, secret-scanner, hypatia-scan, clusterfuzzlite, mirror, instant-sync"
35+
proof-gates = "lean-proofs.yml + coq-proofs.yml (added 2026-06-14): machine-check the Lean/Coq developments on every push. Before this NO CI ran a prover, so the 'verified/sorry-free' claim had silently rotted."
3436
last-shepherd = "2026-06-12 PR #77: fixed 3 Rust tests, empty wokelang.opam, removed banned ReScript VSCode client (governance); issue #78 tracks AffineScript reimpl"
37+
last-proof-shepherd = "2026-06-14/15 PRs #79-#82 (merged): repaired bit-rotted WokeLang.lean + WokeLang.v; extended the Lean type-safety core; fixed Coq cap_subsumes reflexivity; added the two prover CI gates; wrote docs/proofs/verification/AUDIT.md"
3538

3639
[spec]
3740
location = "spec/ — grammar.ebnf, axiomatic-semantics.md, system-specs.md, SPEC.core.scm"

.machine_readable/bot_directives/coverage.a2ml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
[metadata]
1111
version = "1.0.0"
12-
last-updated = "2026-03-24"
12+
last-updated = "2026-06-15"
1313

1414
# ============================================================================
1515
# COVERAGE STATE
@@ -35,6 +35,12 @@ coverage-percent = 0
3535
# fixes = 3
3636
# notes = "boot-guardian built, shutdown-marshal built"
3737

38+
[coverage.visited.proofs-verification]
39+
date = "2026-06-15"
40+
ring = 1
41+
fixes = 4
42+
notes = "docs/proofs/verification/. Repaired bit-rotted WokeLang.lean (Lean 4.30.0) + WokeLang.v (Coq 8.18.0) to compile sorry/admit/axiom-free; extended the Lean type-safety core (or, sub/mul/div/mod with zero-divisor panic, lt/gt/le/ge, capability preorder); fixed Coq cap_subsumes reflexivity (proved cap_subsumes_refl); added lean-proofs + coq-proofs CI gates (no prover had ever run in CI); wrote AUDIT.md. PRs #79-#82, all merged. Carry-forward recorded in debt.a2ml."
43+
3844
# ============================================================================
3945
# SKIPPED COMPONENTS WITH MUSTS
4046
# ============================================================================

.machine_readable/bot_directives/debt.a2ml

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
[metadata]
1111
version = "1.0.0"
12-
last-updated = "2026-03-24"
12+
last-updated = "2026-06-15"
1313

1414
# ============================================================================
1515
# DEBT ITEMS
@@ -34,6 +34,30 @@ last-updated = "2026-03-24"
3434
# impact = "medium"
3535
# discovered = "2026-03-23"
3636

37+
# --- Formal-proof carry-forward from PRs #79-#82 (2026-06-14/15). See
38+
# --- docs/proofs/verification/AUDIT.md §"Recommended next proof steps". ---
39+
40+
[[debt.should]]
41+
component = "docs/proofs/verification/WokeLang.v (Coq)"
42+
issue = "Binops behind the Lean file: only add/eq/and have rules. Bring Coq up to parity with the extended Lean set — sub/mul/div/mod (div/mod panic to error on zero divisor), comparisons lt/gt/le/ge, and or."
43+
effort = "medium"
44+
impact = "medium"
45+
discovered = "2026-06-14"
46+
47+
[[debt.should]]
48+
component = "docs/proofs/verification/WokeLang.lean (Lean)"
49+
issue = "Array typing/evaluation not modelled (tArray + an array congruence/value rule). The Coq file already has this (T_Array/T_Lit_Array + S_Array_step/S_Array_val + well-founded expr_size induction) and is a ready template."
50+
effort = "medium"
51+
impact = "medium"
52+
discovered = "2026-06-14"
53+
54+
[[debt.should]]
55+
component = "docs/proofs/verification/WokeLang.v (Coq)"
56+
issue = "cap_subsumes_trans not yet proven (cap_subsumes_refl is). The relation IS transitive; a robust proof needs explicit per-kind case analysis, not the brittle 6x6x6 automation."
57+
effort = "medium"
58+
impact = "low"
59+
discovered = "2026-06-14"
60+
3761
# ============================================================================
3862
# COULD — would fix eventually
3963
# ============================================================================
@@ -47,3 +71,24 @@ last-updated = "2026-03-24"
4771
# effort = "easy"
4872
# impact = "low"
4973
# discovered = "2026-03-23"
74+
75+
[[debt.could]]
76+
component = "docs/proofs/verification/WokeLang.v (Coq)"
77+
issue = "preservation is a large brute-force `try solve [...]` pile ending in a literal 'Nuclear option' — it compiles and is axiom-honest but is fragile/unreviewable. Rewrite per-case in the style of the Lean preservation."
78+
effort = "hard"
79+
impact = "low"
80+
discovered = "2026-06-14"
81+
82+
[[debt.could]]
83+
component = "docs/proofs/verification/WokeLang.lean (Lean)"
84+
issue = "Float arithmetic variants (sub/mul/div on float, mirroring add on float) not modelled."
85+
effort = "easy"
86+
impact = "low"
87+
discovered = "2026-06-14"
88+
89+
[[debt.could]]
90+
component = "docs/proofs/verification/ (echo-types integration)"
91+
issue = "Echo-types L3 integration blueprint not started: a Lean port of EchoLinear + EchoResidue as WokeLang/Echo.lean (a Mode-indexed decoration on top of the base type system, leaving progress/preservation intact), modelled on Ephapax's formal/Echo.v Coq port. Connects to the STATE [frontier] echo-types goal."
92+
effort = "hard"
93+
impact = "medium"
94+
discovered = "2026-06-14"

.machine_readable/bot_directives/methodology.a2ml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
[metadata]
1111
version = "1.0.0"
12-
last-updated = "2026-03-24"
12+
last-updated = "2026-06-15"
1313
spec = "https://github.com/hyperpolymath/standards/blob/main/agentic-a2ml/docs/ADR-002-methodology-layer.adoc"
1414

1515
# ============================================================================
@@ -70,11 +70,13 @@ deepen-not-broaden = true
7070
# If parallel → stop. Note as cross-project insight.
7171

7272
[methodology.divergent-invariants]
73+
# Real invariants for wokelang's formal-verification strength (populated
74+
# 2026-06-15 from PRs #79-#82). The generic template examples below are
75+
# DELIBERATELY NOT used — wokelang's provers are Lean 4 + Coq, not Idris2.
7376
rules = [
74-
# Customise per project. Examples:
75-
# "Idris2 only for formal verification — no Lean4, Coq, Agda",
76-
# "believe_me count must remain zero",
77-
# "FFI architecture: Idris2 → RefC → Zig → C ABI (no shortcuts)",
77+
"Verification provers for docs/proofs/verification/ are Lean 4 and Coq — deepen these two; do NOT switch to Idris2/Isabelle or add a third prover for the type-safety track (the STATE [frontier] echo-types narrative is a separate, additive layer, not a prover swap)",
78+
"sorry / admit / Admitted count in WokeLang.lean and WokeLang.v must remain zero; the ONLY permitted axioms are Coq.Reals' ClassicalDedekindReals.sig_forall_dec + functional_extensionality (unavoidable from modelling float as the reals R) — these are NOT escape hatches, and an Axiom-scanner must not flag them",
79+
"The proofs are a deliberate strict SUBSET of the surface language (the expression core) — broaden along the existing Step/HasType + progress/preservation pattern; do not claim full-language verification",
7880
]
7981

8082
# Optional: language invariant for the core strength
@@ -88,10 +90,12 @@ rules = [
8890
# Updated at session end with newly discovered constraints.
8991

9092
[methodology.known-constraints]
93+
# Discovered 2026-06-14/15 (PRs #79-#82). See docs/proofs/verification/AUDIT.md.
9194
constraints = [
92-
# Customise per project. Examples:
93-
# "End-to-end build has never been verified",
94-
# "libproject.so does not exist yet — all bindings call stubs",
95+
"Formal proofs live in docs/proofs/verification/: WokeLang.lean (Lean 4, pinned v4.30.0 via lean-toolchain) + WokeLang.v (Coq 8.18.0, ubuntu-24.04), both now CI-gated (lean-proofs.yml, coq-proofs.yml)",
96+
"Both proof files had silently bit-rotted because no CI ever ran a prover; the toolchain pins are load-bearing and WokeLang.v is version-sensitive — do not bump Coq blindly",
97+
"Lean and Coq cover COMPLEMENTARY subsets: Coq is ahead on arrays (T_Array + well-founded expr_size induction); Lean is ahead on binops (sub/mul/div/mod, lt/gt/le/ge, or). Neither is full-language",
98+
"PROOF-NEEDS #2 (eval matches the Lean spec) is NOT a well-posed single theorem: core/eval.ml models a different language (units-of-measure, to_bool coercions, no Result) than the Lean/Coq Step relation. Needs a maintainer decision — (a) treat WokeLang.lean as normative and converge implementations, or (b) build a second model faithful to core/eval.ml — before attempting it",
9599
]
96100

97101
# ============================================================================

0 commit comments

Comments
 (0)