vcl-ut Phase 3: L1/L6–L10 soundness + dependent SafetyCertificate + sound ABI.Layout (stacked on #22) — Refs standards#124#23
Merged
Conversation
checkLevel6Sound..checkLevel10Sound: acceptance => the LN_* witness, same with..proof p shape as checkLevel4Sound, no proof-escape. The L6-L10 predicates assert exactly 'the relevant clause/annotation is present' (real, non-vacuous, but shallower than what checkLevelN also enforces e.g. L9!=LinUnlimited / L10 declared+acyclic) — soundness is genuine for the predicates as stated; the shallowness gap is a disclosed Phase 3 residual, not masked. Clean build EXIT=0 (8/8), zero escapes, SafetyL4Model checks. Refs hyperpolymath/standards#124. Does not close. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Decide: fieldRefResolves/allFieldRefsResolve + allFieldsBoundFromResolve, which BUILDS the genuine inductive AllFieldsBound (each FieldBound carries the real resolveFieldRef ref schema = Just fd). checkLevel1 decided through allFieldRefsResolve over BOTH statementFieldRefs (thorough, subquery-descending — behaviour preserved) AND Levels.extractFieldRefs (the L1 predicate's extractor — drift-free soundness hook, verdict- neutral since statementFieldRefs strictly dominates). checkLevel1Sound connects checker -> the existing non-vacuous L1_SchemaBound WITHOUT touching the genuine Composition.l1Compose proof. Phase 3a DONE: checkLevel1Sound..checkLevel10Sound all genuine, no proof-escape. Clean build EXIT=0 (8/8), SafetyL4Model checks. Refs hyperpolymath/standards#124. Does not close. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
tryL1..tryL10 run each decision procedure and, on acceptance, return the genuine LN_* witness via the machine-checked checkLevelNSound lemmas (with..proof p, no escape, no re-assertion). certifyAt assembles them into the cumulative dependent SafetyCertificate; certifyRequested certifies at the statement's own requestedLevel — a Just IS a machine-checked proof the query meets its declared level. checkQuery (Bool/CheckResult) retained unchanged for the C ABI. This closes the certificate<->checker disconnect (previously the dependent SafetyCertificate type was decorative w.r.t. the decision procedure). Clean build EXIT=0 (8/8), zero escapes, SafetyL4Model checks. Refs hyperpolymath/standards#124. Does not close. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Honest, not faked. The ONLY false proofs in the codebase were two items in ABI.Layout; DELETED rather than forced: - alignUpCorrect: (align > 0) is a Bool used as a Type + bogus Refl asserting the divisibility goal — removed (genuine div/mod proof OWED). - offsetInBounds: an open ?metavariable (never a proof, false in general) — removed (membership-quantified version OWED). - queryPlanHeaderNoPadding: over-claimed 'no padding', and even the trivial totalSize=24 restatement won't reduce under Refl (Vect-n implicit blocks the projection) — removed (real no-padding proof OWED). GENUINELY FIXED: paddingFor used (-) on Nat (no Neg Nat) -> minus. Sound content kept (roundtrip Refl proofs, layout data, alignUp/ paddingFor/Divides) and is now machine-checked: VclTotal.ABI.Layout added to vclut-core.ipkg (9 modules) + CI escape-grep. ABI.Foreign stays excluded but is NOT unsound — it has no proofs (FFI plumbing); its non-compile + stub-transport is architectural Phase 3+ OWED, precisely disclosed. VERIFICATION-STANCE.adoc rewritten: ABI.Layout OWED RESOLVED; certificate-disconnect RESOLVED (Phase 3a/3b); residuals re-scoped to the FFI boundary + genuine alignment theorems + L6-L10 predicate shallowness. Clean build EXIT=0 (9/9), zero proof-escapes, SafetyL4Model checks. Refs hyperpolymath/standards#124. Does not close. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…ed mint The FFI fabricated a verification result: ffi/zig/src/lib.zig returned 2 (Verified L2) for ANY query containing the substring "SELECT", with a Zig test enshrining it. A fake green is worse than a red. - ffi/zig/src/lib.zig: fabrication DELETED; vclut_verify_query is now fail-closed (returns -1 Rejected, explicit 'no verifier backend linked' message; never returns a level it didn't establish). The lie-test rewritten to assert the fail-closed contract. zig build test green. - Checker.certifiedLevel : Statement -> OctadSchema -> Int — genuine proof-gated attestation mint: a non-negative level is returned ONLY on the Just-certificate branch of certifyRequested (structural, no escape). The real verification authority, in the CI-gated corpus. - src/abi/Foreign.idr + src/interface/abi/Foreign.idr: trust model documented honestly (C int = trusted-certifier attestation, NOT a transported dependent proof — inherent to any FFI). - VERIFICATION-STANCE.adoc: FFI item rewritten — lie removed, boundary precisely scoped. NAMED OWED: no string->Statement parser exists anywhere in the repo (the verify(query_string) shape presupposes an unwritten component); C-ABI Statement marshalling; Idris->C build; real backend link. A C ABI carrying a re-checkable dependent proof is impossible by construction — honest target is attestation. Clean build EXIT=0 (9/9), L4 model EXIT=0, zig build test EXIT=0, zero proof-escapes. Refs hyperpolymath/standards#124. Does not close. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Owner
Author
|
Update — Phase 3d added to this PR (commit `28cbe71`): FFI honesty. The FFI fabricated a result — `ffi/zig/src/lib.zig` returned `2` (`Verified L2`) for any query containing the substring `SELECT`, with a Zig test enshrining it. A fake green is worse than a red, so:
Authoritative verification: corpus `idris2 0.8.0 --build` EXIT=0 (9/9), `SafetyL4Model` EXIT=0, `zig build test` EXIT=0, zero proof-escapes. Refs hyperpolymath/standards#124; does not close. |
hyperpolymath
added a commit
that referenced
this pull request
May 19, 2026
Brings the human-facing docs in line with the now-verified state (Phases 1–3 on main via #21/#22/#23; Phase 4 = PR #24). No source or proof changes; corpus remains green (10 modules, exit 0, zero escapes). - PROOF-NEEDS.md: the false "corpus does not compile / never machine-checked / L2/L3/L5 vacuous" block replaced with the actual CI-gated 10-module state; per-level status corrected (L1–L10 resolved, residual gaps precisely scoped). - verification/proofs/README.adoc: added `vclut-core.ipkg` to Contents + the corpus build to "Verifying"; corrected the STANCE summary. - verification/proofs/VERIFICATION-STANCE.adoc: headline updated "Phase 1 + 2 + 3" -> "Phase 1–4". - CHANGELOG.md: new "### Verified" entry under [Unreleased] recording the Phase 0→4 proof-corpus remediation. The a2ml machine manifests carry no verification state (generic scaffolding) and were correctly left untouched. VERIFICATION-STANCE.adoc remains the authoritative catalogue and takes precedence over README/PROOF-NEEDS prose. Refs hyperpolymath/standards#124. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
Stacked on #22 (Phase 2), which is stacked on #21 (Phase 1). Refs hyperpolymath/standards#124. Does not close the issue. Retarget down the stack as #21/#22 merge.
What this does (Phase 3 of the standards#124 vcl-ut HOLE remediation)
3a — soundness for all remaining levels
checkLevel1Sound…checkLevel10Sound, same machine-checkedwith … proof pshape ascheckLevel4Sound, no proof-escape. L1'sDecide.allFieldsBoundFromResolvebuilds the genuine inductiveAllFieldsBound(eachFieldBoundcarries the realresolveFieldRef ref schema = Just fd), connected to the checker without disturbing the genuineComposition.l1Compose. With Phase 2, all of L1–L10 now have genuine checker→predicate soundness.3b —
checkQueryemits a real dependentSafetyCertificatetryL1..tryL10run each decision procedure and, on acceptance, return the genuineLN_*witness via the Sound lemmas;certifyAt/certifyRequestedassemble them into the cumulative dependentSafetyCertificate. AJustfromcertifyRequested stmt schemais a machine-checked proof the query meets its declaredrequestedLevel. The previously-decorative dependent certificate is now produced by the decision procedure.checkQuery(C-ABIBoolpath) retained unchanged.3c —
ABI.Layoutmade sound + CI-gated (honest, not faked)The only false proofs in the entire codebase were two items in
ABI.Layout; deleted rather than forced:alignUpCorrect((align > 0)Bool-as-Type + bogusRefl),offsetInBounds(open?metavariable),queryPlanHeaderNoPadding(over-claimed + non-reducing).paddingFor's genuine non-compile ((-)needsNeg Nat) fixed tominus. The sound content (roundtripReflproofs, layout data) is kept;VclTotal.ABI.Layoutis now the 9th ipkg module, CI-gated.ABI.Foreignstays excluded but is not unsound (FFI plumbing, no proofs) — stub-transport is precisely-disclosed Phase 3+ architecture.Verification
idris2 0.8.0 --build verification/proofs/vclut-core.ipkg→ EXIT=0, 9/9 modules,%default total.Layout.idr);SafetyL4Model.idrstill--checkEXIT=0.ABI.Layoutalignment/no-padding theorems, L6–L10 predicate shallowness, L3 subquery/heuristic scoping) is scoped OWED inVERIFICATION-STANCE.adoc, not masked. Headline residuals (non-compiling corpus, vacuous L2/L3/L5, decorative certificate, unsoundABI.Layout) are all resolved.🤖 Generated with Claude Code