Skip to content

claw: specs/claw/evidence.t27 -- the Evidence law every TRI CLAW and t27 MCP fact obeys (Closes #10412) - #10419

Merged
gHashTag merged 1 commit into
masterfrom
claw/evidence-10412
Oct 18, 2026
Merged

gHashTag merged 1 commit into
masterfrom
claw/evidence-10412

Conversation

@gHashTag

Copy link
Copy Markdown
Owner

Closes #10412

What

specs/claw/evidence.t27 is the law every fact TRI CLAW and the t27 MCP server publish must obey. A fact can be a check-run line, a SARIF result, a review suggestion, or a row of an MCP tool answer. Each one is an Evidence record with these fields:

  • claim text and strength (CL_PARSES < CL_TYPECHECKS < CL_HOLDS);
  • the instrument that measured it (parser, typechecker or test-report), with the counts of runtime asserts and failures;
  • the source span (path plus line range);
  • the full seal digest (sha256: plus 64 hex digits);
  • coverage (complete, partial or unknown);
  • a label (exact, derived, suggested or unknown): the four T27F labels.

The idea comes from REA's Evidence model (morluto/rea, rea-agents 6.7.0, MIT). No REA code is used.

Rule Function Test
R1 coverage is required and read only from its exact word. A missing or prose value is refused, never defaulted to complete. coverage_of, check_record r1_missing_coverage_is_refused_not_defaulted, r1_every_coverage_and_label_word_round_trips
R2 unknown stays unknown. Anything composed from an unknown is at best partial. Labels compose to the weakest. compose_coverage, compose_label r2_unknown_never_composes_into_complete, r2_labels_compose_to_the_weakest, r2_an_unknown_label_cannot_claim_complete_coverage
R3 parses or typechecks never becomes holds: the typecheck stays ok for assert 1 > 2. Holds needs a green test-report with at least one runtime assert. strongest_claim, claim_supported r3_typecheck_ok_never_becomes_holds, r3_a_suggested_row_never_says_holds
R4 ready and covered are declared only over comparable rows: all well formed and on one full seal digest. A 12-digit display prefix is refused. cite, comparable, may_declare_ready, may_declare_covered r4_ready_and_covered_need_one_seal, r4_a_display_prefix_is_not_a_digest, r4_covered_needs_complete_coverage_on_every_row
R5 a publish is verified only by a digest read back after the final write. recheck r5_recheck_reads_the_digest_after_the_final_write

specs/claw/evidence_pins.t27 is a test-only companion module, following the gates_pins.t27 pattern. It pins every explicit length to .len, and it pins the four labels (values and names) to specs/t27f/spec_graph.t27.

Verified on the Railway lab (t27c at /root/t27/target/release/t27c, PATH=/opt/zig)

  • t27c spec-status specs/claw/evidence.t27: IMPLEMENTED. The pins module reports NOFN, as gates_pins.t27 does: it has tests and no functions.
  • t27c test-report: evidence 12/12, 0 FAIL, 0 vacuous; pins 4/4, 0 FAIL, 0 vacuous.
  • Negative controls: 6 of 6 mutants were each killed by the test of their rule:
    • coverage_of defaults to complete;
    • the typechecker supports holds;
    • an unknown upgrades to complete;
    • a mixed seal is ignored;
    • a read-back before the final write counts;
    • a fixture length is miscounted.
  • t27c gen-c specs/claw/evidence.t27 lowers (569 lines), and cc -c compiles the output. The feeds can therefore use it. It is not added to the gen-c drift list yet.
  • No seal is committed for the new modules. The claw siblings got their seals in the bulk seal PR (seals: verdict-blocked specs compile and seal; 11 refused specs fixed, 30 blocked ones listed (Refs #8314) #10370), not in their own PRs.

Adopt next (each in its own PR)

  1. specs/claw/sarif_feed.t27 / sarif.t27: one Evidence per SARIF result. The span is already there. Add properties.coverage, label and seal. A parse-error or unwritten result has strength CL_PARSES or none, never holds.
  2. specs/claw/t27f_gate.t27: its check-run table shows a 12-digit digest. Cite the full seal (R4) before writing sealed, and recheck the posted summary (R5).
  3. specs/claw/suggest_feed.t27 / suggest.t27: every suggestion is LABEL_SUGGESTED and can never claim holds (R3).
  4. specs/claw/gates.t27: the gate-audit check-run line declares coverage only through may_declare_covered.
  5. specs/claw/preview.t27: the preview environment's ready state goes through may_declare_ready over the spec seals it renders.
  6. specs/t27mcp/seal_verdict.t27 (t27_spec receipt) and spec_brief.t27 must emit coverage and label per row, and must never turn a typecheck into "works".
  7. specs/t27mcp/find.t27, examples.t27, check_hints.t27 and dashboard.t27 must label every answer row: a match is derived at best, and a hint is suggested.
  8. specs/claw/github_surface.t27: add the Evidence fields as a requirement of each publishing surface row.

🤖 Generated with Claude Code

…t27 MCP fact obeys (Closes #10412)

Every published fact (check-run line, SARIF result, review suggestion,
MCP tool answer row) is an Evidence record: claim text and strength,
the instrument that measured it, source span, full seal digest,
coverage (complete/partial/unknown) and one of the four T27F labels.
Five rules, each a test block: coverage is read only from its exact
word and a missing one is refused, never defaulted; unknown stays
unknown and caps a composition at partial; parses/typechecks never
becomes holds; ready/covered only over rows on one full seal digest;
a publish is verified only by a read-back after the final write.

evidence_pins.t27 pins every explicit length to .len and the labels to
specs/t27f/spec_graph.t27. Idea from REA's Evidence model; no REA code.

Lab: spec-status IMPLEMENTED; test-report 12/12 and 4/4, 0 vacuous;
6 of 6 mutants killed by the test of their rule; gen-c lowers and cc
compiles the result.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-18 11:35:25 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 49
PRs with All Checks Green 1
READY 0
FAILING 49
PENDING 0
NO CHECKS YET 0

These columns do not partition: 0 + 49 + 0 + 0 = 49, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=fad12492937a != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@gHashTag
gHashTag enabled auto-merge (squash) October 18, 2026 11:37
@gHashTag
gHashTag merged commit 569b98a into master Oct 18, 2026
26 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

claw: specs/claw/evidence.t27 -- the Evidence law every TRI CLAW and t27 MCP fact obeys (coverage, label, seal, span)

1 participant