Skip to content

Per-language evidence sheets: six independent stats, no overall score - #9142

Merged
squid-protocol merged 1 commit into
mainfrom
language-stat-sheets
Nov 23, 2026
Merged

squid-protocol merged 1 commit into
mainfrom
language-stat-sheets

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

What this does

Gives every code language an evidence sheet of six independent stats instead of one ranking or tier. The README's five validation charts are too long and mix very different evidence; this is the place they move to.

For each of the 73 code languages, tests/tools/language_sheets.py reads the committed baselines and writes docs/language_sheets/<lang>.md, an index, and a colour matrix (matrix.svg):

stat read from measured against
Detection tests/detection_accuracy_baseline.json labelled language-crucible files
Functions tree_sitter_accuracy_baseline_<lang>.json (python: ast) tree-sitter functions
Call links call_graph_resolution_<lang>_baseline.json, else the callee-name baseline a compiler or analyser (libclang, tsc, scip, ...), else tree-sitter call nodes
Imports import_graph_accuracy_baseline.json import statements in pinned repos
Keywords family_validity_baseline.json families by score (>90, 90-75, 75-50, <50), only bins that have families
Rosetta rosetta_snapshot.json comparable cells passed vs open defects

Every stat carries value, sample size, method (fixed vocabulary), reference and source. Numbers are raw, as the baselines hold them. graph_coverage_chart.py still shows the ledger-validated graph numbers.

A hand-written notes/<lang>.toml records what was possible for the language (parsers found, corpus, best method), so a thin number reads as a limit of the tooling, not a rank. The generator rejects a method outside the vocabulary and an ensemble or llm-read stat without a note. Colours are the keyword-quality chart's own bins.

Read this before merging

  • Notes are drafts. Written for c, typescript, cobol, easytrieve and hcl. c and typescript state facts from this repo's own tooling. The cobol, easytrieve and hcl claims (no parser found, corpus size, best method) are marked unconfirmed and have no dated search log yet.
  • Every other language shows as unclassified. The context group (modern-tooled, legacy/mainframe, DSL) is a hand decision per language.
  • Rosetta is a snapshot. rosetta_snapshot.json is built from keyword-rosetta's docs/bias_data.json at engine a48ee0ad95 via --refresh-rosetta PATH, so CI needs no sibling checkout. A cell counts as failed when its cause is unexplained, extraction or correlation (keyword-rosetta's OPEN_DEFECT_CATEGORIES); validated variations count as passed. Nothing refreshes it automatically yet.
  • No scheduled regeneration yet. --check fails when the committed output is stale, but no workflow runs it. That is a follow-up, with the README slimming.
  • No stat has an as-of date: the baselines carry none. Each row names its source file.

Not in this PR

Moving the five README charts to these pages and shortening "How we validated it". I want the output reviewed first.

Checked

  • pytest tests/tools/test_language_sheets.py: 8 passed
  • ruff check and ruff format on the two new files; ruff_audit.py --ci, doc_refs_audit.py --ci, dead_key_audit.py --ci: no new findings
  • language_sheets.py --check: current
  • Rendered the matrix in headless Chrome and read the top of it

🤖 Generated with Claude Code

One generated sheet per code language (73) plus an index and a colour matrix,
read from the committed baselines. Detection, functions, call links, imports,
keywords and Rosetta each carry a value, a sample size, a method from a fixed
vocabulary, the reference it was measured against and the source file. A
hand-written notes file per language records what was possible (parsers found,
corpus, best method), so a thin number is not read as a ranking. Notes are
drafted for c, typescript, cobol, easytrieve and hcl; the easytrieve, cobol and
hcl claims are marked unconfirmed.

Keywords show families by score (>90, 90-75, 75-50, <50) with only the bins that
have families; Rosetta shows comparable cells passed against open defects, from
a committed snapshot of keyword-rosetta's bias_data.json so CI needs no sibling
checkout. Colours are the keyword-quality chart's own bins.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@squid-protocol
squid-protocol marked this pull request as ready for review November 23, 2026 19:42
@squid-protocol
squid-protocol merged commit ca26e93 into main Nov 23, 2026
62 checks passed
@squid-protocol
squid-protocol deleted the language-stat-sheets branch November 23, 2026 19:59
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.

1 participant