This repository was archived by the owner on Nov 4, 2026. It is now read-only.
Repository navigation
feat(scripts): make the marked skill-example population shrink-only, per category - #7553
Merged
Merged
Conversation
…per category `check-skill-examples.mjs` landed with no ratchet and said so in its own header: whether the marked population becomes shrink-only — the way `check-doc-fence-languages.mjs` treats its declared-file population — was left as a separate decision. That decision is taken here, as a per-category FLOOR rather than an exact pin or a `file:line` register. - `MARKED_FLOOR` carries one number per marked-fence category, seeded at the population measured at this branch point: 17 `ts`, 39 `json` — the same numbers the gate printed at its own landing, so nothing had moved between. That is the MARKED population, not the passing one; `--measure` on the same tree prints `ts: 20/121 pass`, and a floor seeded off that line would have been red on the day it landed. - Below the floor exits 1, naming the category, the count, the floor and the two legal moves (raise it in the pull request that adds markers; lower it in the one that removes a marker, with the reason written beside the row). Above the floor stays green: opting one more fence in is the direction this gate exists to travel, and a ratchet that reds on the good move is one people route around — here, by unmarking. - The report line prints each count beside its floor on every run, so the number stays re-derivable rather than a claim in a merged pull request body. - An EMPTY population stays a PRECONDITION (exit 2). The floor is read only after every precondition has returned and never under `--measure`, so this ratchet cannot re-label "could not run" as "ran and found errors". Pins in `scripts/__tests__/check-skill-examples.test.ts` cover both directions on fixtures, the category coupling (a third fence kind cannot land without a floor decision), the report line, the real corpus, and — as a source-level fact, because a floor computed and never consulted passes everything else — that `main()` reads it, after the preconditions and not under `--measure`. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019RfFHiRCSs3JXLK4cwcfox
os-steve
marked this pull request as ready for review
September 3, 2026 21:11
os-steve
pushed a commit
that referenced
this pull request
Sep 3, 2026
objectui#7550's per-category `MARKED_FLOOR` ratchet (PR #7553) landed on the same two files. Both behaviours are kept whole: - `scripts/check-skill-examples.mjs` auto-merged. The summary now carries the floors on its `Marked:` line and the root bound's refused count on its own `Root bound:` line, and the exit path reads both — the floor breach check and the undeclared/stale root-bound rows. - The one conflict was this suite's import list, resolved by keeping both sides' symbols. - The two docblocks now name each other, which is the interaction neither PR could state alone: the floor counts MARKS, so a fence the root bound refuses stays inside it while being type-checked by nothing, and unmarking one to silence a refusal would breach the floor. Two ratchets, counting different things, neither substituting for the other. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019RfFHiRCSs3JXLK4cwcfox
akarma-synetal
pushed a commit
to akarma-synetal/objectui
that referenced
this pull request
Sep 9, 2026
…bjectstack-ai#7563) The Skill Example Check section documented every other assertion the gate makes but said nothing about the second shrink-only ratchet PR objectstack-ai#7553 added: MARKED_FLOOR, one floor per marked-fence category (ts: 17, json: 39 as measured on this tree), raised only by a PR that adds marks and lowered only by the PR that removes one, with the reason written beside the constant. Adds one paragraph beside the existing KNOWN_BARE_ANY_EXAMPLES one, in the same voice, and rewrites the "If it fails" advice so that removing a marker is named as the floor-lowering move (with its reason) rather than a silent unmark. Claude-Session: https://claude.ai/code/session_019RfFHiRCSs3JXLK4cwcfox Co-authored-by: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #7550
Part of #7359
Executes the maintainer's ruling on objectstack #14909 item 2 (option A): the marked-fence population that
scripts/check-skill-examples.mjstype-checks becomes shrink-only, per category, as a floor rather than an exact pin and ⛔ not as afile:lineregister (option B, refused).The gate landed saying so in its own header — "There is deliberately NO ratchet and NO count pin ... a separate decision, recorded as a follow-up rather than taken here". That paragraph is replaced by the decision.
The seeded floors, and the run that measured them
MARKED_FLOORcarries one number per marked-fence category. Seeded from a measurement at the branch point3e01cb5, not from a claim in a merged pull request body —pnpm check:skill-exampleson the unmodified tree printed:so
ts: 17,json: 39— the same numbers objectui#7359 reported at the gate's landing, meaning no marker had moved in between.--measureprinted:Three more
tsfences hold up than are opted in, so a floor seeded off theStarting populationline would have been red on the day it landed. The docblock records the distinction beside the constant.What the gate now does
Marked: 17 ts fence(s) (floor 17), 39 json fence(s) (floor 39) — the floor is ⛔ SHRINK-ONLY. Unmarked fences are ignored by design (opt-in).--measure, so this ratchet cannot re-label "could not run" as "ran and found errors". The ordering is pinned, not just written.The self-description is in
check-doc-fence-languages.mjs's idiom for itsKNOWN_UNHIGHLIGHTED_TS_FENCESbaseline: a per-key count, ⛔ SHRINK-ONLY, with the remedy spelled out as aREMEDY_FLOORblock the way that gate spellsREMEDY_SYNONYM.One reading declared, so the seat can redirect cheaply
The card says "two floor constants:
MARKED_FLOORfortsand forjson". Landed as one exportedMapnamedMARKED_FLOORcarrying exactly those two rows — two floors, one per category, each with room for its reason beside it. That reading keeps the identifier the card names verbatim, matches the sibling idiom it told me to copy (aMapkeyed per category, injectable so the self-test can drive it), and lets the check be a loop that names the category. If the seat meant two separate identifiers, it is a rename.Pins (
scripts/__tests__/check-skill-examples.test.ts)All of it runs on an unbuilt tree — the floor is a count over the scanner's output — so it belongs in the vitest suite rather than in
--self-test, per that file's stated boundary.MARKED_FLOOR's keys are derived from whatscanSkillFencescan actually produce, so a third fence kind cannot land without a floor decision for it;main()reads it, that a breach exitsexamplesFailed, and that it is read after the preconditions and not under--measure.The existing
leaves the majority unmarkedpin stays a ratio; its comment, which said objectui#7359 had not decided this, is updated rather than the assertion.Ablation
Two legs, each mutated on disk with the mutation proved by grepping both the removed and the injected text, each restored with
git checkout HEAD -- ...and the restore proved by state (disk blobb83b589equals the HEAD blob,git diff HEADempty), under atrap ... EXIT INT TERMwith absolute paths. No build leg is involved: the pins are pure functions plus a source read, and the gate runs from source.Leg A — the floor check deleted from
main()(reconcileFloors(population)occurrences on disk: 1 → 0). The wiring pin reds and names itself:Leg B — the
tsfloor raised one above the measured count (['ts', 17]→['ts', 18]; injected 1, replaced 0). The gate itself exits 1 and names everything the ruling asked for:followed by the two legal moves. The corpus pin reds in the same leg and names itself (
Tests 1 failed | 72 passed).Gates — verdict lines, run on head
e9508b4after the final commit, clean treepnpm check:skill-examplesEvery marked skill example holds up against the built types.node scripts/check-skill-examples.mjs --self-test✓ check-skill-examples self-test: 42 cases pass (...)pnpm check:doc-snippetsEvery covered documentation snippet compiles against the built types.pnpm check:doc-fences✅ check:doc-fences — every TypeScript block in 227 document(s) is fenced ts/tsx/typescript, except 80 declared file(s) carrying 90 block(s) ... (⛔ SHRINK-ONLY).pnpm check:control-bytes✅ check-control-bytes: OK (scanned 6224 tracked text file(s); skipped 85 binary).pnpm vitest run scripts/__tests__/check-skill-examples.test.tsTest Files 1 passed (1) · Tests 73 passed (73)pnpm vitest run scripts/__tests__/check-skill-eval-tokens.test.ts scripts/__tests__/scripts-type-check.test.tsTest Files 2 passed (2) · Tests 51 passed (51)pnpm type-check:scriptstsc -p tsconfig.scripts.json, no diagnosticspnpm lintTasks: 47 successful, 47 totalEvery exit code was captured before any pipe (
cmd redirected to a file; EXIT=$?; tail), never read through one.Both edited files are proved to be in the
type-check:scriptsprogram bytsc --listFiles(2 hits), so "typecheck clean" is a statement about them and not a vacuous pass. The two heavier gates needed a build first:check:skill-examplesbuilds the closure its own--build-filternames, andcheck:doc-snippetsexited 2PRECONDITION NOT METon the wider closure until that was built too — an exit 2 that is "could not run", not a red, and it is 0 above.Changeset
None owed, and none added.
node scripts/check-changeset-presence.mjson this range:2 file(s) changed, 0 of them published source of a package the release covers ... ✅ No source or published contract of a released package changed in this range, so no changeset is owed.skip-changesetlabel. It is not applied, and deliberately: in this repository that label is the phantomscripts/__tests__/ci-cd-pipeline-doc.test.tsdocuments at length — auto-minted by an API call, read by no workflow and no script, and one whose application was refused and the refusal upheld on PR #6260. The repo's exemption is an empty-frontmatter changeset, and here not even that is owed. Raised for the seat rather than acted on silently.Out of scope, filed
content/docs/guide/ci-cd-pipeline.mddocuments every other assertion of this gate including theKNOWN_BARE_ANY_EXAMPLESratchet, and now says nothing about this second one; its "If it fails" paragraph advises removing a marker, which is now a move that reds until the floor is lowered. Not fixed here: this card's ruling pins the file surface to the two files in this diff.Session, as prose so it survives a later body edit:
https://claude.ai/code/session_019RfFHiRCSs3JXLK4cwcfoxGenerated by Claude Code