chore(ratchet): raise the two src/sales token ceilings to their anchor() (59,000 / 107,000) - #1953
Merged
objectstack-fleet[bot] merged 2 commits intoOct 3, 2026
Conversation
`business semantics` 55,000 -> 59,000 and `authored total` 100,000 -> 107,000 in `scripts/check-source-token-ratchet.mjs`. Both are `anchor()` — the ruled `ceil(reading x 1.05 / 1000) x 1000` — of the readings PR #1950's tree prints (55,986 and 101,395), so the kind stays ANCHORED and the 5% working buffer is the whole of the raise. The maintainer ruling authorising it is quoted in the gate's own header and in the PR body, which is the condition the gate states for raising an anchored ceiling. The reading those two rows anchor from is not one `origin/main` prints, so the recorded anchoring run names the tree it was taken on (`refs/pull/1950/head` at 85e5dbd) — the format this header already uses for a run that cannot be taken on `main`. Nine of the twelve worked rows re-anchor onto that run; the three whose `anchor()` now lands above the ceiling they carry keep their 2026-09-16 row and are recorded as declined re-anchorings, which is what keeps the header's ledger self-consistent and `test/source-token-ratchet.test.ts` green. No other ceiling moves, and nothing under `src/` is touched. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T3YsvpK1PvYf9n1YUhYP6W
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
This was referenced Sep 25, 2026
This was referenced Oct 2, 2026
Closed
Refresh of PR #1953 onto main 25cd8d7 (26 commits). The merge is clean: main touched none of the PR's four files. Its one README edit (31 -> 30 flows, #1988) is not a figure test/docs-readme-token-figures.test.ts pins, and that test stays green on the merged tree. Claude-Session: https://claude.ai/code/session_01ER8ntXZhYebyQ66aXWdjfT Co-authored-by: Claude <noreply@anthropic.com>
This was referenced Oct 3, 2026
hotlong
pushed a commit
that referenced
this pull request
Oct 3, 2026
… raise, #1994, #1963 No conflicts. #1953 raises the src/sales ceilings to 59,000 / 107,000, the ruled answer to this branch's measurement. #1994 (tenant_admin profile) and #1963 (tsx bump, pnpm-lock.yaml) do not touch this branch's file surface. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ER8ntXZhYebyQ66aXWdjfT
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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 #1951
Raises exactly two
src/salesratchet ceilings inscripts/check-source-token-ratchet.mjs.Nothing under
src/is touched, so the measured surface does not move.src/salesrowanchor()of⛔ No other package's ceiling changes. ⛔ No
kindchanges.The maintainer ruling this raise stands on
The gate's own header states the condition: raising an anchored ceiling "requires a
maintainer ruling quoted in the raising PR's body". Quoting it, verbatim and
untranslated — maintainer reply of 2026-09-16T11:04Z, recorded in
#1951's ruling comment:
That is the maintainer's whole text, so here is the letter it answers, from the same comment:
The arithmetic, re-derived here with the gate's own exported
anchor()rather than copiedfrom the ruling:
and the PM seat stopped and checked the channel before executing rather than assuming it.
The answer was that it counts, with one standing constraint — this PR stays a draft and the
merge decision is the maintainer's. The trail is
PM comment 5696983500
(the question) and
PM comment 5723611009
(the answer, and the dispatch).
That constraint was lifted on 2026-10-03. The
repo:hotcrmseat (session_01ER8ntXZhYebyQ66aXWdjfT) took this PR over, as recorded intakeover claim 5965002201.
In the seat's chat, the maintainer ordered 「hotcrm一大堆pr你全部接手处理」. Asked who lands this PR once it is refreshed and green, the maintainer answered, verbatim, 「席位落地(推荐)」. So the seat lands it through the merge queue once review passes and CI is green on the refreshed head.
The kind stays
ANCHORED, and that was decided rather than defaultedThere is real tension in it: the header defines an ANCHORED ceiling as
anchor()of "a readingthis gate actually printed", and
origin/mainat087b7c5prints 54,179 / 99,340. It has neverprinted 55,986 / 101,395 — those are true on the tree of the REQ-0006 branch (PR #1950, head
85e5dbd).The resolution is to keep
ANCHOREDand make the rows name the tree their reading camefrom, which is the format this header already carries (the existing anchoring run names
origin/mainat4d7ae9f, and #1905's re-scoping run could not have been taken onmainatall). Switching the kind to
RULEDwas refused on a property the gate itself states: a RULEDceiling is symmetric, so lowering these two would then need a maintainer ruling too,
forever. The maintainer agreed to a number derived by
anchor(), not to pinning these tworows against future tightening, and a long-term property of the gate is not a fair price for an
easier PR.
The header's ledger had to be reconciled, and this is why
test/source-token-ratchet.test.tsholds the header table to four invariants at once: one rowper committed ceiling in the committed order,
anchor(row reading) == the committed constant,every row dated to a recorded run that actually produced its reading, and — the one that bites
— every ceiling the latest recorded run left alone owes a "declined re-anchoring" row proving
it would have been a raise.
So a new run block cannot record two rows and ignore ten. This PR records one real run, on one
tree, and reconciles all twelve rows against it:
rows
anchor(reading)is the constant they already carry, so re-anchoring them moves a dateand a reading, never a ceiling.
anchor()of the new reading lands abovethe ceiling they carry, and raising one of those is a ruling of its own that nobody gave.
They are recorded as declined re-anchorings:
85e5dbdand onorigin/mainat087b7c5— theREQ-0006 branch touches
src/sales/alone — so the module readings recorded above areorigin/main's own, re-measured on that run rather than carried across. Verified by runningthe gate on both trees: the module blocks are identical line for line.
Refresh onto
main25cd8d78(2026-10-03)Merge commit
e7287a65(parentsdeb4563c+25cd8d78, 26 commits frommain, clean, no hand resolution). The PR's four files are byte-identical todeb4563c, so the ruled numbers, everykindand the changeset are untouched. The readings below are on the refreshed head. The original 2026-09-18 readings stay further down as history.pnpm verify, exit 0 one7287a65:Test Files 174 passed (174)·Tests 3701 passed | 1 skipped (3702). CI one7287a65: 9/9 success.main's ownsrc/salesreading moved down since087b7c5, so these differ from the 2026-09-18 block:mainwithout feat(opportunity): REQ-0006 qualification, the customer calendar, narrative and approval on status change #1950:⛔ Do not act on it in this PR. It is a
console.log(exit 0). The ceilings are anchored to the REQ-0006 tree by the ruling, and that tree lands next as PR #1950. Measured on agit merge-treeof #1950's head85e5dbdontoe7287a65, the gate reads 55,240 / 98,614, and neither row prints the advisory:anchor(reading)main+ this PRmain+ this PRmainmoved its reading to 53,433, which is still inside the ~54k banner's 51,300–56,700 band.test/docs-readme-token-figures.test.tspasses with no edit.main's only README change since087b7c5is fix(flows): retire demo_bootstrap, the platform claims seeded rows once at seed settle #1988's 31 → 30 flows, which that test does not pin.Measurements (original, 2026-09-18, on
deb4563c; kept as history)pnpm verify— the full chainpackage.jsondefines, exit 0.pnpm validate && pnpm typecheck && pnpm lint && pnpm lint:i18n-gate && pnpm hygiene && pnpm hygiene:tokens && pnpm build && pnpm test.Exit code captured to a file before any pipe.
The gate itself, on this branch —
node scripts/check-source-token-ratchet.mjs, exit 0:The opportunistic-tightening advisory did NOT fire on
deb4563c. That was true on the 2026-09-18 base; on the refreshed head it prints (see the refresh section above). Measured on this branch, not assumed.The gate prints no
over twice the 5% bufferline anywhere in that run (grep -con thecaptured output:
0). Substituting into the gate's own expressionrow.ceiling - row.tokens > row.tokens * 2 * BUFFER && anchor(row.tokens) < row.ceiling:anchor(reading)Both sit inside the relative trigger, so the second half never gets asked. And the advisory is
a
console.logthat never setsfailed, so it could not have moved the exit code either way.Both importing suites are green, and one of them moved:
test/docs-readme-token-figures.test.tsimports
CEILINGSand pins its own docstring band row against it, so the row's ceiling columnfollows 55,000 to 59,000. The README banner does not move — it is pinned to the measured
reading, not to a ceiling (「解耦:banner 钉实测,ceiling 独立」),
origin/main's reading did notchange as of 2026-09-18 (it has since moved to 53,433, see the refresh section), and ~54k stays inside its 51,300–56,700 band at 53,433, 54,179 and 55,986 alike.
Changeset: an empty-frontmatter declaration, not the label
The ruling's parenthetical suggested
skip-changeset; checked against what comparable PRs inthis repo actually did rather than taken as fact.
.github/workflows/changeset-check.ymlcountschangesets added by the PR and treats an empty-frontmatter file as the sanctioned "this PR
releases nothing" declaration, on par with the label — and the script-only precedents all chose
the file, including #1928, which raised two of these same ceilings
(
.changeset/per-module-token-ratchet.md), plusderive-the-src-roster-package-list.mdandconfig-globs-must-match-something.md. The file is the better of the two because it leaves thereasoning in the repository instead of in a label.
package.jsonisprivate: trueand thisdiff opens no file
objectstack buildreads, so the artifact and the docs site arebyte-identical to
main.What this PR deliberately does not do
label:strings. Ruling item 2 keeps that separateand it is getting its own card; this PR is not the place to answer it.
state. That sequencing is the PM seat's: this PR lands first, then feat(opportunity): REQ-0006 qualification, the customer calendar, narrative and approval on status change #1950 merges
mainagain.src/sales's interaction ceiling, any module ceiling, anykind, themeasurement basis, or one line under
src/.Acceptance notes
src/service authored totalandsrc/revenue authored totalhave bothdrifted past their own 5% anchor since [decision] Track A has ~621 tokens of business-semantics headroom left and two rings to go — raising the ceiling needs a maintainer ruling quoted in the raising PR #1928 —
anchor()of today's reading is 23,000 and20,000 against committed 22,000 and 19,000. Neither is over its ceiling and neither is a
defect; they are now recorded as declined re-anchorings in the gate header, which is the
first written record that these two are the next rows likely to need a conversation.
Successor: whoever next raises or re-anchors a module ceiling reads those rows.
re-date every row it can and write a declined row for every row it cannot. That is the
suite working as designed, not a defect, but it is why a two-constant raise touches ten rows.
Successor: the next raising PR, which will meet the same invariant.
Generated by Claude Code