Skip to content

feat(efficacy): score changed trees in full, one radar a task, the registered readings - #186

Merged
braboj merged 25 commits into
mainfrom
feat/changed-tree-scoring
Nov 19, 2026
Merged

braboj merged 25 commits into
mainfrom
feat/changed-tree-scoring

Conversation

@braboj

@braboj braboj commented Nov 15, 2026

Copy link
Copy Markdown
Contributor

Round 6 (C1) now scores each changed tree like a build, adds two change-task targets, and prints one radar and verdict per task with the registered readings.

fixture (5e none-b) --seed v1 db--> copy --opened by--> each arm's changed tree (v2)
                                                         |-- full scoring: probes, security, quality, judge
                                                         |-- interfaces: 4 suite modules the fixture passed
                                                         '-- data upgrade: old values, exports, prices survive
Change Where on the radar
score.py --task change runs everything a build gets; security, quality and judge take --task change every axis of the change radar
Interfaces: api_contract, http_routes, export_json, export_csv still pass where the fixture passed; inherited failures count neither way Compatibility, interoperability
Data upgrade: the changed tree opens the fixture-seeded database; values, exports and old prices hold; new rows can be added Flexibility, adaptability
One ISO radar, verdict and mean billed cost per task build radar and change radar
Registered readings: check loop kept (lazyref vs lazyrefold), lazysections vs lazyref and reference, H7 per lazy arm "The registered readings"

The registered readings, in the report's own words:

  • Check loop kept only on a point cost drop of 10 % or more on each task, and no axis worse on either.
  • Worse only where the whole interval lies past the margin; otherwise "no degradation detected under the registered rule".
  • Non-inferior only where every measured axis's lower bound clears minus its margin; otherwise "inconclusive on ".
  • H7, on demand: "yes" only for fewer templates read than reference and non-inferior on every axis; otherwise "not shown".

Reference runs:

  • interfaces read 1 on reference and reference-change; a planted wrong CSV content type reads 0

  • data upgrade passes; reference-change without its migration fails

  • every self-test, trace.py PASS (134 rules), pyflakes clean; every new rule mutation-tested

  • New IDs: FR-16-01 to FR-16-10, QT-03-02, QT-08-03

Base: stack/c1-base, the merge of #185 (on #182) and #184 (on #181, #180). Review only this PR's own commits.

Closes #178. Refs #158, #169, #168.

🤖 Generated with Claude Code

https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3

braboj and others added 6 commits November 15, 2026 21:00
…ged-tree-scoring

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
…nd data upgrade

- score.py scores a changed tree on every reading a build has, both suites,
  churn before the battery, and files its security reading beside it
- the interfaces reading: the API, route and export modules the fixture
  passed whole must still pass; inherited failures counted neither way
- the harness refuses a fixture whose baseline does not name the four
  interface modules, and copies the baseline into each change record
- quality.py --task change adds the data upgrade: seed through the
  fixture's own forms at the starting commit, open a copy with the changed
  tree, check values, old invoices and new rows; provenance recorded
- security.py, quality.py and judge.py take --task change, each into
  folders of its own
- round 6's ISO table: interfaces on Interoperability, data upgrade on
  Adaptability, each once, read whatever the build did; pilots unchanged
- archive.py and reuse.py carry the change readings and judgings; reuse
  brings change tasks in a change run naming the round's fixtures
- FR-16-01 to FR-16-07, QT-03-02, QT-08-03, ch. 8 and ADR-023 history

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- the upgrade posted a new percentage rule and then re-saved the first
  old invoice, so its own rule repriced it: reference-change read failed
- the old invoice is now saved again first, then the new records
- the stand-in prices percentage rules, so the old order fails its sound
  upgrade check

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- a named round draws the ISO radar and gives each arm's verdict for the
  build task and for the change task, each against none on the same task
- the change radar reads each change task's tree: its score, its build
  suite as the hidden suite, its own security, quality and judgings
- the build radar leaves the change targets to the change task's radar
- each task's mean billed cost per trial is shown beside its radar, not
  scored; the summary, its tables, the plain report and the appendix
  name the task; aggregate.json keeps each task's reading
- pilot rounds draw one radar over their trials as before
- FR-16-08, ch. 8 and ADR-024 history

Refs #169, #178.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- the check loop: lazyref against lazyrefold, paired by block; kept only
  where the mean billed cost per trial drops by 10 % or more on each task,
  its interval beside it, and no ISO axis reads worse on either
- an axis is worse only with its whole interval past the margin downward;
  none flagged reads "no degradation detected under the registered rule"
- non-inferior only where every measured axis's lower bound clears minus
  its margin, an interval crossing it inconclusive; read apart from kept
- the section files against lazyref and reference: the same words and
  the cost, no gate
- H7: an on-demand arm delivers on demand only reading fewer templates per
  trial than reference and non-inferior to it on every measured axis
- templates read are counted per task from that task's transcripts,
  section files included; contrasts take any pair
- FR-16-09, FR-16-10 and ch. 8

Refs #169, #178.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- contrasts keep the pairs asked for apart from each contrast's
  differences, so a second metric no longer reads numbers as arm names
- the check loop is kept only with both tasks read; a build alone leaves
  it not decided
- a changed tree's bundle carries the pinned change prompt, and its judge
  is told the change extends the spec; the build's prompt is unchanged
- a section file is read only by a read or a reading command, a wildcard
  standing for each file it matches; a listing reads none
- a named round with no build reads its finding table from the change
  task's own trials, cost and contrasts

Refs #178, #169.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 1 (gpt-6-astra, high): 5 findings, all fixed in edc00ae.

Sev Finding Outcome
P2 Named contrasts crashed on a second metric Fixed: selected pairs kept apart from differences
P2 Check loop read Kept on build readings alone Fixed: needs both tasks, else Not decided
P2 Change-task judge lacked the change requirements Fixed: bundle carries CHANGE.md, prompt says it extends the spec
P2 Section-file reads matched ls, missed wildcards Fixed: same command-aware reads as vendored templates
P2 Finding table mixed build and change readings Fixed: reads the selected task's own trials, table and cost

trace 134 rules, 0 problems. Round 2 running.

🤖 Generated with Claude Code

- the data upgrade keeps each seeded record's row as the fixture's list
  page shows it, prices and rates included, and fails a field the
  upgraded tree no longer shows; a column the change adds is no loss
- each task's template use is read over that task's own trials, so a
  reading the report leaves out counts on neither task
- the check loop's 10 % gate reads the unrounded paired differences; the
  rounded mean is for display only

Refs #178, #158, #169.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 2 (gpt-6-astra, high): 3 findings, all fixed in 1a26e84.

Sev Finding Outcome
P2 Upgrade check compared names, not field values Fixed: each seeded row's cells must survive; stand-in fault rerating
P2 Dropped trials still counted in template-use averages Fixed: task_uses reads each task's filtered view
P2 10 % cost gate read a rounded mean Fixed: gate reads unrounded differences

trace 134 rules, 0 problems. Round 3 running.

🤖 Generated with Claude Code

braboj and others added 3 commits November 16, 2026 08:36
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- one reading of the section files, the base's: by their path in the
  workspace, through the shared shell-read detection
- a named round's use-of-the-map table is printed once a task, each over
  that task's own trials, the build's the one the aggregate keeps

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- the data upgrade compares each listed field as a whole cell, so a value
  kept only inside a longer one fails; extra columns stay allowed
- a skill's SKILL.md read or shell-read counts as that skill used, once
  with its loading
- C1's non-inferiority needs the lower bound strictly above minus the
  margin; the pilot rounds keep their own rule
- the 10 % cost gate meets within 1e-9, the table's column and the
  decision reading the same test

Refs #178, #169.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Base refreshed: stack/c1-base now merges #185 at 7e83dba (7d5c340), merged into this branch (03fc133). This brings #182's fix for a checkout with no local main, which made CI fail.

Codex round 3 (gpt-6-astra, high): 4 findings, all fixed in 2c953b5.

Sev Finding Outcome
P2 Upgrade kept a value found inside a longer one (0.05 in 0.051) Fixed: whole-cell compare; stand-in fault extending
P2 Skill files read directly were not counted Fixed: Read or shell read of SKILL.md counts, once with its loading
P2 C1 non-inferiority accepted a bound equal to minus the margin Fixed: strictly above, C1 only
P2 $0.90 vs $1.00 read under 10 % by float error Fixed: 1e-9 tolerance, decision and table agree

trace 134 rules, 0 problems, also on a clone with no local main. Round 4 running.

🤖 Generated with Claude Code

- a changed tree's scope reads its index as the change task left it,
  captured before the install, the suites or churn's intent-to-add, so
  the scorer's own build output is no unasked artifact
- a changed tree's public surface is read against the build's names and
  each the pinned change prompt calls on the package, ThresholdRule
  among them; the build is read as before

Refs #178.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 4 (gpt-6-astra, high): 2 findings, both fixed in a9eafa2.

Sev Finding Outcome
P2 Files the scorer's install wrote counted as unasked artifacts Fixed: scope read from the tracked files right after unpacking
P2 Structure probe read the changed tree against build-only names Fixed: change task passes build names plus the change's (ThresholdRule)

trace 134 rules, 0 problems. Round 5 running.

🤖 Generated with Claude Code

@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 5 (gpt-6-astra, high): 2 findings, both in the upgrade probe; fixing.

Sev Finding Outcome
P2 Post-upgrade writes never use the change's new fields (caps, threshold) Fixing: write and read back capped and threshold records on the upgraded copy
P2 <li>/<p> rows compared as one cell, so an added field fails a sound upgrade Fixing: whole-token compare for every row kind, extra tokens allowed

🤖 Generated with Claude Code

braboj and others added 2 commits November 16, 2026 09:58
- after the upgrade the probe also posts a capped jurisdiction and a
  threshold rule through the changed app's forms and reads them back, so
  a schema changed for new files alone fails on an old one
- each seeded row is read as whole values, split on white space and
  `,;|`, the same for table rows, list items and paragraphs; every old
  value must still show whole, and a value the change adds is allowed

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- a seeded record whose row no key finds, on the old page or on a new
  page that still shows it, leaves the data upgrade missing, never
  passed: "row for <key> not found"
- the boot check keeps its database, and whatever the app writes beside
  it, in a folder of its own outside the tree, removed after
- a changed tree's churn is read before the install, the boot or the
  suites write into it, beside its scope

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 6 (gpt-6-astra, high): 2 findings, both fixed in 520c301.

Sev Finding Outcome
P2 Rows the upgrade could not find were skipped, so data loss passed Fixed: reads missing, "row for not found"; stand-in +divs
P2 Boot check wrote a secret into the tree, adding churn Fixed: boot DB in a temp dir; churn read right after unpacking

trace 134 rules, 0 problems. Round 7 running.

🤖 Generated with Claude Code

- a page's rows are read by the outermost kind it holds, table rows,
  then list items, then paragraphs, each with everything inside it, so a
  paragraph in a table cell no longer cuts its row in two

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex round 7 (gpt-6-astra, high): 1 finding, fixed in 62d74c4.

Sev Finding Outcome
P2 A <p> inside a table cell cut the row, so field values escaped comparison Fixed: one row kind per page (outermost of tr, li, p), read whole with a depth-counting parser; stand-in +pcells

trace 134 rules, 0 problems. Round 8 running.

🤖 Generated with Claude Code

braboj and others added 4 commits November 16, 2026 14:53
- the base's quality changes kept, with the change task's folders and the
  data upgrade beside them; the absent-tree guard covers the upgrade too
- the total reader the base's capacity probe no longer uses is kept for
  the data upgrade, which reads an old invoice's price back by it
- archive: the base's reading list and its combined readings check, with
  the change task's folders and environments

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
- the data upgrade reads back the values its new-field records were posted
  with, the cap and the minimum, whole in their rows; an app that drops a
  field it has no column for fails
- an archive's verify compares each task's ISO reading and cost and the
  registered C1 results too, so a change task's reading that changes, its
  data upgrade among them, refuses the verify
- C1's new arms, from the base's declared contrasts, get a verdict and a
  cost on each task

Refs #178, #158, #169.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Base refreshed: stack/c1-base now merges the final #185 (f138ba7) and #184 (5bb7c86), at a643c29, and is merged here (3601136).

Codex round 8 (gpt-6-astra, high): 3 findings, all fixed.

Sev Finding Outcome
P2 New-field writes passed when the app silently dropped caps/minimum Fixed in 0031c81: values read back by whole token
P2 Task radars omitted lazysections and lazyrefold Fixed by the base refresh (#185's C1 contrasts); per-task check added
P2 Archive verify ignored change-task readings Fixed in 0031c81: figures() holds per-task ISO, contrasts, cost and registered results

trace 134 rules, 0 problems, also on a clone with no local main. Round 9 running.

🤖 Generated with Claude Code

- one rule reads a row's values, kept ones and those read back alike:
  equal as text, or the same amount once a leading currency is set
  aside, a key=value with the same key and such a value; 0.05 still
  fails against 0.051
- every export the upgrade reads must answer a success before its body
  counts, the JSON exports and the customer's alike, at the seed too;
  one that does not fails the upgrade, naming its status

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex review, round 9: two findings, both fixed in e76ca30.

Severity Finding Outcome
P2 Money values had to match as literal text, so 200, 200.00 and €200.00 read as different Fixed: tokens match as text or as equal numbers after a currency prefix (same_token, has_token); test mode terse
P2 Export status codes were ignored, so an export answering with an error still passed the upgrade Fixed: every export must answer 2xx; test mode erring

Round 10 is reviewing e76ca30.

🤖 Generated with Claude Code

- the data upgrade reads back every value its new records were posted
  with, by the rule kept values are read by, not only the cap and the
  minimum; a stand-in storing other values fails
- a build suite that ran out of time fails every interface, report or
  none, as the radar reads such a suite, not leaving them unmeasured
- a shell read of a skill's folder through a wildcard reads its skill,
  resolved against the skills' own files, once with its loading

Refs #178, #158, #169.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex review, round 10: three findings, all fixed in 38976b0.

Severity Finding Outcome
P2 New records written after the upgrade were checked only by key and cap or minimum, so wrong names or rates passed Fixed: every posted value must read back in its row; test mode garbling
P2 A build suite that timed out before writing its report left interfaces unmeasured, dropping Compatibility Fixed: a timed-out suite fails every interface, report or not
P2 A wildcard read such as cat .claude/skills/base-quality/*.md counted no skill Fixed: shell reads under .claude/skills resolve wildcards against each skill's SKILL.md, counted once per skill

Round 11 is reviewing 38976b0.

🤖 Generated with Claude Code

braboj and others added 2 commits November 16, 2026 18:02
- reused change tasks join a target only where its change runs took the
  same fixture manifest and block mapping, refused before anything is
  copied
- the invoice saved after the upgrade is read as the old ones are: its
  page and both exports must answer a success

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
… behaviour

- values are read from the exports the spec fixes: each old invoice's
  JSON, every old key and value, lists in order, and its CSV by column,
  row by row; the customer's export; extra keys and columns allowed
- every old invoice's body is saved again and must export as the
  fixture's did, its new id aside, in place of the total alone
- the change's own fields are read by their effect: a capped jurisdiction
  and a threshold rule posted on the copy, invoices saved through the app
  opened afresh below, at and above the threshold and the cap, against
  the change's semantics; the seed's invoice percentage deleted first
- list pages count for presence alone: a seeded code or rule id named
  whole, whatever the markup
- removed: the row reading, same_token/has_token and currency handling,
  the preview total search, and missing for a row not found
- the stand-in prices the spec's way; HTML-layout modes dropped, new
  modes for a customer rewritten and a rule that will not delete
- FR-16-04, its coverage and ch. 8 state the narrowed claim

Refs #178, #158.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex review, round 11: three findings. Two fixed in 6296338; one settled by a design change in e745f6c.

Severity Finding Outcome
P2 A renamed value (Upgradia → Upgradia Corrupted) passed the HTML token check By design: the upgrade probe no longer reads HTML values (see below); jurisdiction names are outside its narrowed claim
P2 Reuse combined change tasks from runs with different fixture manifests Fixed: reuse refuses a manifest or block mismatch before copying anything
P2 The invoice saved after the upgrade had only its JSON total checked Fixed: its page and both exports must answer 2xx

Design change (e745f6c). Rounds 3–11 kept finding layout edge cases in the HTML reader. Codex, as the owner's stand-in, chose to narrow the claim:

Before After
Old values read from list-page rows (tr/li/p) Read from the invoice JSON/CSV and customer exports; extra keys and columns allowed
Fresh invoice: total only Every old invoice saved again; full exports must match, except invoice_id
New fields read back from list pages Checked by effect: threshold and cap below, at and above 200.00 / 50.00
List pages compared field by field Presence only: seeded code and rule ids as whole identifiers

Removed: the Rows parser, same_token/has_token, currency-prefix handling, "missing because no row was found".
Checked against the reference apps: reference → reference-change passes; no change fails; a removed migration reads lost.

Round 12 is reviewing e745f6c.

🤖 Generated with Claude Code

@braboj

braboj commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

Codex review, round 12 (e745f6c): no findings.

The review loop is clean. Ready for the owner's approval, after #184 and #185 merge into stack/c1-base's parents.

🤖 Generated with Claude Code

@braboj
braboj changed the base branch from stack/c1-base to main November 17, 2026 14:21
braboj and others added 2 commits November 17, 2026 16:29
…ring

- harness: the change record carries the fixture's baseline beside main's
  fence, `protected` and `protected_names`
- report: the change task's readings still load beside main's load, and
  main's planted registration repository sits beside the C1 checks

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
…ts radar

- read as the change task's own tree, a tree that does not install or
  boot is the change's: it fails Reliability's first target and is left
  out of every other axis, as a broken build is
- a named round's change read beside its build keeps reading its targets
  whatever the build did

Refs #178.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 17, 2026

Copy link
Copy Markdown
Contributor Author

Merged main (#180, #181, #182, #184, #185) as 28d078a; both sides kept, the data-upgrade redesign unchanged.

Codex full review after the merge (gpt-6-astra, high): one finding, fixed in 6389381.

Severity Finding Outcome
P2 A changed tree that failed to install scored zero on Compatibility, Maintainability and Flexibility as well as Reliability on its own radar Fixed: on the change task's own view a failed tree follows the failed-tree rule; the exemption stays for an independent change read beside a build

report 307/307, pyflakes clean. A delta review of 6389381 is running.

🤖 Generated with Claude Code

- the verify's C1 root planted a change score with no install or boot
  reading, which its task's radar now reads as a broken tree, left out of
  every axis but Reliability; the flipped data upgrade then moved nothing
- the planted change score installs and boots, as the check means it to

Refs #178.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DpT5xQh3AgRFs2tJwMT4g3
@braboj

braboj commented Nov 19, 2026

Copy link
Copy Markdown
Contributor Author

Codex delta reviews of 6389381 and c37c545 (gpt-6-astra, high): no findings. CI passes. Merging (owner approved).

🤖 Generated with Claude Code

@braboj
braboj merged commit 84390e6 into main Nov 19, 2026
2 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.

Round 6: score changed trees in full, with upgrade and interface checks

1 participant