Skip to content

Keyword families: cross-language consistency report on keyword-rosetta (Part of #8863) - #9202

Merged
squid-shepherd[bot] merged 2 commits into
mainfrom
churn/8863-20261124T1429Z
Nov 24, 2026
Merged

squid-shepherd[bot] merged 2 commits into
mainfrom
churn/8863-20261124T1429Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #8863 (step 2 of "The test": cross-language consistency on keyword-rosetta). Checklist: partial [c:cross-language-consistency-report]

What

tests/tools/family_rosetta_consistency.py: reads keyword-rosetta's data/*/expected_signals.json (the blessed engine counts of the same 12-probe program in every language, summed over the folder's files) and, per contracted family, says which languages that HAVE a rule for it disagree with the rest. A family that fires in most of its defining languages and reads 0 in one is a gap with no parser oracle. No engine or keyword change; nothing scans.

Verdicts per (family, language): agrees, silent (rule defined, most languages fire, this one reads 0), over, under, ledgered (a deviation that keyword-rosetta's deviation_ledger.json already explains). A language with no rule is N/A, not a gap. A family that fires in under half its defining languages has "no consensus" and is listed, not judged. Contracted families the corpus does not plant are listed as "not testable here". With no corpus, no manifests or no mapped language it exits 2 saying nothing was checked (the #2682 rule); --check-floor exits 1 on any silent cell; --json writes the table.

First result (corpus 2e67433, 50 code languages, 30 contracted planted families)

  • Silent: dead_code in Python (fires in 4 of 5 defining languages).
  • Over the target: api in 8 languages (abap, ada, bms, dart, hlasm, objective-c, perl, pli), func_start in css and makefile, panics_and_aborts in hlasm. No under-counts.
  • 42 contracted families are not planted at all (so untestable here), e.g. regex_execution, time_date_logic, serialization_parsing, bitwise_ops.

These are the report's readings, not verdicts on the engine: the contract decides whether any is a bug (#8862 for draft contracts).

Class / Sibling gaps

Class: cross-language consistency of the planted, contracted keyword families on keyword-rosetta (every family in the intersection of signal_contracts.CONTRACTS and the manifest keys, handled by one table; each verdict has a test in test_family_rosetta_consistency.py: clean, silent, over, under, N/A, ledgered, unplanted, non-code folder, threshold boundary, ordering, missing corpus, malformed manifest, CLI and --check-floor).

Sibling gaps (not done here, different mechanism):

  • Live-scan variant (manifests are blessed output; a stale one would mislead): rule_probe.probe over the corpus. Source: this tool's design.
  • README / chart integration and a CI gate on the floor: a separate decision; --check-floor exists but is wired nowhere.
  • The 42 unplanted contracted families need rosetta SPEC plants (keyword-rosetta PRs) before this report can see them.
  • Missing-keyword mining (Epic: keyword-family validity -- do the per-function signals measure what their names say? #8863 step 3) and the other open children.
  • The one silent cell (dead_code, Python) and the api / func_start over-counts are for the contract audit of those signals, not this PR.

Gates

pr_gates.py --fast: 8 of 9 pass; derived (docs_read_by_tests.txt stale) fixed by change_classifier.py --write (3 generated lines, two come from main's docs). Tree-wide guards 207 passed, time ratchet 0 over. --ratchets: 9 pass, 0 fail, 0 skipped. New test 20 cases, 0.6 s. No golden, ledger or baseline moved.

Cross-repo

None: reads keyword-rosetta, changes nothing there.

Lessons for agents

  • Rosetta manifests spread the plants over main, a, b and c: counting only main.* makes cleanup, globals, test and telemetry look dead.

🤖 Generated with Claude Code

@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 24, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 24, 2026 14:44
@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 24, 2026 14:45
@squid-shepherd
squid-shepherd Bot merged commit 57db345 into main Nov 24, 2026
61 checks passed
@squid-shepherd
squid-shepherd Bot deleted the churn/8863-20261124T1429Z branch November 24, 2026 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant