MathLedger — Version v0.2.7
Status: LOCKED(see /versions/ for current status)
Tag: v0.2.7-verifier-parity | Commit: 5d01b4b1446e | Locked: 2026-01-04
Tier A (enforced): 10 Tier B (logged): 1 Tier C (aspirational): 3
What this version cannot enforce:
  • No Lean/Z3 verifier: FV claims always return ABSTAINED
  • Single template partitioner: no multi-model consensus
  • No learning loop: RFL not active
  • MV edge cases: overflow, float precision not fully covered

Invariants Status ARCHIVE

Invariants Status: FM vs. v0 Implementation

This document provides a brutally honest classification of governance invariants.

Tier Classification:

Invariants Table

InvariantFM SectionTierHow It Can Be Violated TodayCurrent DetectionPlanned Enforcement
Canonicalization Determinism§1.5AImpossible without golden test failuretest_golden_evidence_pack.pyDone
H_t = SHA256(R_t \\U_t)§1.5AImpossible - structural code constraintcompute_composite_root()Done
ADV Excluded from R_t§1.5AImpossible - build_reasoning_artifact_payload raises ValueErrorStructural rejectionDone
Content-Derived IDs§1.5AImpossible - derive_committed_id() uses SHA256Code structureDone
Replay Uses Same Code PathsAImpossible - same imports in replay_verifyStructuralDone
Double-Commit Returns 409AImpossible - _committed_proposal_ids set checkAPI enforcementDone
No Silent Authority§4AImpossible - require_epoch_root() gate mandatory for evidence packauthority_gate.require_epoch_root()Done (v0.1)
Trust-Class Monotonicity§6AImpossible - require_trust_class_monotonicity() gate mandatory at committrust_monotonicity.require_trust_class_monotonicity()Done (v0.1)
Abstention Preservation§4.1AImpossible - require_abstention_preservation() gate mandatoryabstention_preservation.require_abstention_preservation()Done (v0.1)
Audit Surface Version FieldAImpossible - manifest.json includes source referenceBuild assertion verifiesDone (v0.2.0)
MV Validator CorrectnessBEdge cases in arithmetic parsing; non-arithmetic claimsLogged validation_outcomeAdditional validators
FV Mechanical Verification§1.5CNo Lean/Z3 verifier existsPhase II
Multi-Model Consensus§10CSingle template partitionerPhase II
RFL Integration§7-8CNo learning loop in v0Phase II
USLA§10CNo constitutional constraint layerPhase III
TDA Mind Scanner§10.3CNo topological coherence monitoringPhase III

Tier A: Enforced (10 invariants)

These cannot be violated without cryptographic or structural failure detection.

1. Canonicalization Determinism

2. H_t Computation

3. ADV Excluded from R_t

4. Content-Derived IDs

5. Replay Uses Same Code Paths

6. No Silent Authority (PROMOTED v0.1)

7. Double-Commit Returns 409

8. Trust-Class Monotonicity (PROMOTED v0.1)

9. Abstention Preservation (PROMOTED v0.1)

10. Audit Surface Version Field (PROMOTED v0.2.0)

What Is Enforced:
  1. Every release has a canonical entry in releases/releases.json with:
- version: Semantic version string (e.g., "v0.2.3") - tag: Git tag name (e.g., "v0.2.3-audit-path-freshness") - commit: Short commit hash for verification - status: Release lifecycle state ("active", "closed")
  1. Evidence pack artifacts include version reference:
- releases/evidence_pack_examples.{version}.jsonpack_version field matches version - releases/evidence_pack_verifier_vectors.{version}.jsonmetadata.version matches version
  1. Hosted demo health endpoint (/health) returns:
- build_commit, build_tag matching releases.json current_version entry - release_pin.is_stale flag for drift detection How Auditors Verify:
# 1. Check releases.json current_version
cat releases/releases.json | jq '.current_version'

2. Verify deployed demo matches

curl -s https://mathledger.ai/demo/health | jq '.build_tag, .build_commit'

3. Run predeploy gate (should pass for correctly deployed system)

uv run python tools/predeploy_gate.py --check-health
Promotion Date: 2026-01-02 (v0.2.0)

Tier B: Logged but Not Hard-Gated (1 invariant)

These are detectable via replay or logs but not prevented at runtime.

1. MV Validator Correctness


Tier C: Aspirational (3 invariants in current release, 5 total documented)

These are documented but not implemented in v0. Only FV, Multi-Model, and RFL are tracked in releases.json.

1. FV Mechanical Verification

2. Multi-Model Consensus

3. RFL Integration

4. USLA (Unified System Law Architecture)

5. TDA Mind Scanner


Promotion Complete: No Silent Authority → Tier A (v0.1)

Invariant: No Silent Authority (FM §4) Previous State: Tier B (logged, not hard-gated) Current State: Tier A (structurally enforced) Implementation (v0.1):
# governance/authority_gate.py

def require_epoch_root(request: AuthorityUpdateRequest) -> str: """ Verify epoch root before allowing authority-bearing output.

FAIL-CLOSED: Any validation failure raises SilentAuthorityViolation. """ if request.uvil_events is None: raise SilentAuthorityViolation("uvil_events is None") if request.reasoning_artifacts is None: raise SilentAuthorityViolation("reasoning_artifacts is None")

computed_u_t = compute_ui_root(request.uvil_events) computed_r_t = compute_reasoning_root(request.reasoning_artifacts) computed_h_t = compute_composite_root(computed_r_t, computed_u_t)

if request.claimed_h_t and computed_h_t != request.claimed_h_t: raise SilentAuthorityViolation("H_t mismatch - tampering detected")

return computed_h_t

Enforcement Location: What Is Gated (v0.1 "Durable Influence"):
  1. Producing evidence packs (canonical attestation output)
  2. Any data marked authority_gate_passed: True
Tests: Promotion Date: 2026-01-02

Promotion Complete: Trust-Class Monotonicity → Tier A (v0.1)

Invariant: Trust-Class Monotonicity (FM §6) Previous State: Tier B (logged, humans could over-assign) Current State: Tier A (structurally enforced) Implementation (v0.1):
# governance/trust_monotonicity.py

def require_trust_class_monotonicity( claims: List[Dict[str, Any]], committed_partition_id: str, record_violation: bool = True, ) -> None: """ Verify trust-class monotonicity for a batch of claims.

FAIL-CLOSED: First violation raises TrustClassMonotonicityViolation. """ for claim in claims: verify_trust_class_immutable( claim_id=claim["claim_id"], claim_text=claim["claim_text"], trust_class=claim["trust_class"], rationale=claim.get("rationale", ""), committed_partition_id=committed_partition_id, record_violation=record_violation, )

Enforcement Location: What Is Gated (v0.1):
  1. Any attempt to commit a claim_id with a different trust class than originally committed
  2. Any content tampering (claim_text mismatch for same claim_id)
Error Response (HTTP 422):
{
  "error_code": "TRUST_CLASS_MONOTONICITY_VIOLATION",
  "message": "Trust-class monotonicity FAILED: Cannot change trust class...",
  "committed_partition_id": "...",
  "claim_id": "sha256:...",
  "attempted_change": {"from": "MV", "to": "FV"}
}
Tests: Promotion Date: 2026-01-02

Promotion Complete: Abstention Preservation → Tier A (v0.1)

Invariant: Abstention Preservation (FM §4.1) Previous State: Tier B (logged, downstream could ignore) Current State: Tier A (structurally enforced) Implementation (v0.1):
# governance/abstention_preservation.py

def require_abstention_preservation( reasoning_artifacts: List[Dict[str, Any]], record_violation: bool = True, ) -> None: """ Verify abstention preservation for a batch of reasoning artifacts.

FAIL-CLOSED: First violation raises AbstentionPreservationViolation. """ for idx, artifact in enumerate(reasoning_artifacts): verify_outcome_present(artifact, artifact_index=idx, record_violation=record_violation)

Enforcement Location: What Is Gated (v0.1):
  1. Missing validation_outcome field → violation
  2. Null/None validation_outcome → violation
  3. Invalid outcome value (not VERIFIED/REFUTED/ABSTAINED) → violation
  4. Aggregation without explicit ABSTAINED handling → violation
Error Response (HTTP 422):
{
  "error_code": "ABSTENTION_PRESERVATION_VIOLATION",
  "message": "Abstention preservation FAILED: validation_outcome is null...",
  "artifact_index": 2,
  "claim_id": "sha256:...",
  "violation_type": "NULL_VALUE",
  "details": {"received_value": null}
}
Tests: Promotion Date: 2026-01-02

Tracked Issues: FM vs. Repo Discrepancies

IssueFM ClaimRepo StateResolution
H_t formulaHash("EPOCH:"R_tU_t)SHA256(R_tU_t)Domain prefix differs; documented as v0 simplification
Trust classes4 defined (FV, MV, PA, ADV)4 implemented✓ Aligned
Dual attestationU_t + R_t + H_tImplemented✓ Aligned
Abstention outcomeFirst-class artifactImplemented✓ Aligned
For a comprehensive 20-point pressure analysis, see: docs/SPEC_PRESSURE_AUDIT_V0.2.x.md (in repository)

Governance Note

This document increases credibility by being honest about what is enforced vs. aspirational.

Date: 2026-01-02 Author: Claude A (v0 Evidence Pack Closure Pass)