proofs: commence AffineScript alignment (Phase 1 — proof foundation)#53
Merged
Merged
Conversation
🔍 Hypatia Security ScanFindings: 135 issues detected
View findings[
{
"reason": "Merge artifact in root",
"type": "stale",
"file": "SPEC.core.scm.orig",
"action": "delete",
"rule_module": "root_hygiene",
"severity": "medium"
},
{
"reason": "Action perpolymath/standards/.github/workflows/governance-reusable.yml@main\n needs attention",
"type": "unpinned_action",
"file": "governance.yml",
"action": "pin_sha",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cargo-audit.yml",
"type": "missing_timeout_minutes",
"file": "cargo-audit.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cargo-audit.yml",
"type": "missing_timeout_minutes",
"file": "cargo-audit.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in casket-pages.yml",
"type": "missing_timeout_minutes",
"file": "casket-pages.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in casket-pages.yml",
"type": "missing_timeout_minutes",
"file": "casket-pages.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cflite_batch.yml",
"type": "missing_timeout_minutes",
"file": "cflite_batch.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cflite_pr.yml",
"type": "missing_timeout_minutes",
"file": "cflite_pr.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in codeql.yml",
"type": "missing_timeout_minutes",
"file": "codeql.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in comprehensive-quality.yml",
"type": "missing_timeout_minutes",
"file": "comprehensive-quality.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
}
]Powered by Hypatia Neurosymbolic CI/CD Intelligence |
🔍 Hypatia Security ScanFindings: 133 issues detected
View findings[
{
"reason": "Merge artifact in root",
"type": "stale",
"file": "SPEC.core.scm.orig",
"action": "delete",
"rule_module": "root_hygiene",
"severity": "medium"
},
{
"reason": "Action perpolymath/standards/.github/workflows/governance-reusable.yml@main\n needs attention",
"type": "unpinned_action",
"file": "governance.yml",
"action": "pin_sha",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cargo-audit.yml",
"type": "missing_timeout_minutes",
"file": "cargo-audit.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cargo-audit.yml",
"type": "missing_timeout_minutes",
"file": "cargo-audit.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in casket-pages.yml",
"type": "missing_timeout_minutes",
"file": "casket-pages.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in casket-pages.yml",
"type": "missing_timeout_minutes",
"file": "casket-pages.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cflite_batch.yml",
"type": "missing_timeout_minutes",
"file": "cflite_batch.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in cflite_pr.yml",
"type": "missing_timeout_minutes",
"file": "cflite_pr.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in codeql.yml",
"type": "missing_timeout_minutes",
"file": "codeql.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in comprehensive-quality.yml",
"type": "missing_timeout_minutes",
"file": "comprehensive-quality.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
}
]Powered by Hypatia Neurosymbolic CI/CD Intelligence |
hyperpolymath
marked this pull request as ready for review
June 2, 2026 13:00
hyperpolymath
enabled auto-merge (squash)
June 2, 2026 13:00
Bring BetLang's verification posture toward the AffineScript estate's RSR standard, starting with proofs. BetLang already has strong proof *content* (Lean 4 Progress + Preservation + monad laws, 0 sorry, 1 classified axiom) but lacked the *infrastructure* to machine-check and govern it. This change adds, without touching proofs/BetLang.lean: - lakefile.lean + lean-toolchain: the existing Lean 4 formalisation is now a buildable Lake package (pure-core, no Mathlib). - .github/workflows/proofs.yml: CI machine-checks the proofs (lake build) and runs a banned-pattern gate on every push/PR. - tools/proof-scan.sh: comment-aware scanner for banned soundness escape hatches (sorry/admit/Admitted/postulate/believe_me/assert_total/ unsafeCoerce); shared by CI and `just`. - Justfile: proof-check-lean4, proof-scan, proof-check-all recipes. - PROOF-STATUS.md (new) + PROOF-NEEDS.md (restructured): proof obligation register and live completion table, aligned to the AffineScript format. - verification/: add the four RSR pillars BetLang lacked (simulations, coverage, traceability, safety_case) with AI manifests + READMEs, plus the pillar manifest and an updated index. - docs/AFFINESCRIPT-ALIGNMENT.adoc (new): gap analysis and the phased plan (Phase 1 here; Phases 2-5 cover axiom discharge, continuous semantics, multi-prover ABI/FFI proofs, and the remaining pillars). https://claude.ai/code/session_01NGKc4681nuptfQADqreAfc
hyperpolymath
force-pushed
the
claude/affinescript-betlang-alignment-Lwvm3
branch
from
June 2, 2026 17:50
762b72e to
67f8725
Compare
🔍 Hypatia Security ScanFindings: 63 issues detected
View findings[
{
"reason": "Action perpolymath/standards/.github/workflows/governance-reusable.yml@main\n needs attention",
"type": "unpinned_action",
"file": "governance.yml",
"action": "pin_sha",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in governance.yml",
"type": "missing_timeout_minutes",
"file": "governance.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in hypatia-scan.yml",
"type": "missing_timeout_minutes",
"file": "hypatia-scan.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in mirror.yml",
"type": "missing_timeout_minutes",
"file": "mirror.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in scorecard.yml",
"type": "missing_timeout_minutes",
"file": "scorecard.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in secret-scanner.yml",
"type": "missing_timeout_minutes",
"file": "secret-scanner.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in spark-theatre-gate.yml",
"type": "missing_timeout_minutes",
"file": "spark-theatre-gate.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "Issue in scorecard-enforcer.yml",
"type": "scorecard_publish_with_run_step",
"file": "scorecard-enforcer.yml",
"action": "split_scorecard_publish_job",
"rule_module": "workflow_audit",
"severity": "high"
},
{
"reason": "Issue in codeql.yml",
"type": "codeql_missing_actions_language",
"file": "codeql.yml",
"action": "flag",
"rule_module": "workflow_audit",
"severity": "medium"
},
{
"reason": "TypeScript file detected -- banned language",
"type": "banned_language_file",
"file": "/home/runner/work/betlang/betlang/playground/src/ternary.ts",
"action": "flag",
"rule_module": "cicd_rules",
"severity": "critical"
}
]Powered by Hypatia Neurosymbolic CI/CD Intelligence |
hyperpolymath
pushed a commit
that referenced
this pull request
Jun 5, 2026
…rack, SPDX, license badge Reconcile docs to the axiom-free reality. substTop_preserves_typing is a proved theorem (proofs/BetLang.lean:918), verified by `lake build`; zero `axiom` declarations remain. Six artefacts still called it a live axiom: - docs/proof-debt.adoc: move substTop from §(c) NECESSARY AXIOM to §(a) DISCHARGED; marker count 1 -> 0. - PROOF-STATUS.md: TP-4 -> Done; axiom-free note; banned-patterns wording. - PROOF-NEEDS.md: TP-4 status -> done. - .machine_readable/6a2/STATE.a2ml: M4 done; axioms=[]; remaining 10->9; drop already-merged-PR (#53/#54/#55) next-actions. - README.md / README.adoc / EXPLAINME.adoc: "one permitted axiom" -> axiom-free. Untrack build rot + tidy: - remove 8 stale *.bak.20250719-182140 backups. - untrack 321 Gleam build artefacts under lsp/bet-lsp/build/ (already gitignored). - remove broken root symlink SPEC.core.scm (target migrated .scm -> .a2ml). - gitignore lake-manifest.json (zero-dep project; regenerated on every build). Conformance: - add SPDX headers to core/betlang.rkt, lib/ternary.rkt, repl/shell.rkt, tests/basics.rkt (Mustfile requires SPDX on .rkt). - drop redundant/incorrect PMPL-1.0 license badge (LICENSE + SPDX = MPL-2.0). Verified: `lake build` green (Lean v4.15.0), tools/proof-scan.sh clean, working tree clean. No Lean sources changed. https://claude.ai/code/session_01VwbFNQJw23tW8tqM7utWku
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal
Bring BetLang from where it is today to the same engineering position the AffineScript estate occupies — starting with proofs, as requested. This PR establishes the standing plan and commences Phase 1.
Where AffineScript is vs. where BetLang was
I examined
hyperpolymath/affinescript(+affinescript-vite,affinescriptiser). Finding: BetLang is ahead on proof content and behind on proof infrastructure.solo-coreIdris2 is statements-only (progress/preservation with?todoholes, derivations scheduled weeks 3–12).proofs/BetLang.leanalready proves Progress + Preservation + the distribution monad laws, with 0sorryand exactly 1 classified necessary axiom (substTop_preserves_typing, already triaged indocs/proof-debt.adoc).What BetLang lacked was the AffineScript-standard scaffold and enforcement around that content: a buildable/CI-checked proof project, the multi-prover
verification/proofslayout, aPROOF-STATUS.md, a banned-pattern gate, andjust proof-check-*recipes.What this PR does (Phase 1 — proof foundation)
Without touching
proofs/BetLang.lean:lakefile.lean+lean-toolchain— the existing Lean 4 formalisation becomes a buildable Lake package (pure-core, no Mathlib)..github/workflows/proofs.yml— CI machine-checks the proofs (lake build) and runs a banned-pattern gate on every push/PR. A green build is the machine-checked proof.tools/proof-scan.sh— comment-aware scanner for banned soundness escape hatches (sorry/admit/Admitted/postulate/believe_me/assert_total/unsafeCoerce). Interim portable stand-in forpanic-attack assail --proofs-only. The single classifiedaxiomis permitted per standards#203.Justfile—proof-check-lean4,proof-scan,proof-check-all.PROOF-STATUS.md(new) +PROOF-NEEDS.md(restructured) — obligation register + live completion table, aligned to the AffineScript format. Current: 3/13 proven (23%).verification/— add the four RSR pillars BetLang lacked (simulations,coverage,traceability,safety_case) with AI manifests + READMEs, plus the pillar manifest and an updated index. (Theproofs/tests/conformance/benchmarks/fuzzingsymlinks already existed.)docs/AFFINESCRIPT-ALIGNMENT.adoc(new) — gap analysis + the phased plan.The plan (in place)
substTop_preserves_typing→ axiom-free core; continuous measure semantics; mechanise max-entropy & SLLN statementspanic-attack --proofs-only; cross-link into.machine_readable/STATE.scm; paperVerification note
lake buildwas not run locally — the newproofs.ymljob is what will machine-check it. I pinnedleanprover/lean4:v4.15.0; if the proof file needs a different version, CI will surface it and it's a one-line change. The banned-pattern scanner was run locally (11 proof files, clean — no false positives on the "no sorry" comments).https://claude.ai/code/session_01NGKc4681nuptfQADqreAfc
Generated by Claude Code