Skip to content

docs(pm): new code in a large source file goes in a new module; the os-dev report records classifier refusals - #38683

Merged
objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-38664-os-dev-rule-fold
Nov 30, 2026
Merged

objectstack-fleet[bot] merged 2 commits into
mainfrom
claude/issue-38664-os-dev-rule-fold

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Steve · project thread

Fixes #38664
Fixes #38669

Clause-②: no
Metadata-protocol: none
Rule-change: ruled
Ruling-ref: 「同意,立卡」「按照 fable的方案」 — the maintainer (os-warren), os-warren's fleet project thread, 2026-11-30T01:18Z, quoted in the body of the first card above

维护者速读

  • 用户能看到什么变化:用户无感;开发 agent 往已经很大的源文件里加新功能时改为写进旁边的新文件,审核和派卡各多一条对应的检查,开发 agent 的收尾报告多一栏、如实记下被权限分类器拒掉的命令。
  • 为什么做:属于「大文件治理」计划的规则部分(维护者已同意),同时替「为什么有些会话的写操作被拒」这项调查补上能直接统计的数据。
  • 出错会怎样:只影响 agent 的工作规则、不影响产品,规则不合适时开发 agent 可能把本该留在原处的改动拆成新文件,撤回这次合并即恢复原规则。
  • 要你做什么:无。

What changes

Rule text only, four files under .claude/. No script, no gate, no ceiling row, no AGENTS.md sentence.

First card: new code in a large file goes in a new module (commit ab3b298f). The four sentences of the card's Ask, in Chinese like the files they land in, tightened to pay for bytes. Thresholds as measured: 1,000 lines, 2,000 lines, 300 net lines.

File Sentence added (in substance)
.claude/agents/os-dev.md, last bullet of the scope rule A new concern (a new operation, a new rule family, a new sub-flow) added to a source file over 1,000 lines is written in a new sibling module; the existing file gains only the call. A fix inside an existing function stays where it is. Existing code is never moved to make room: that is a split card.
references/l1-review-checklist.md, scope section More than 300 net lines added to a non-test source file already over 2,000 lines: the ACCEPT names why the code could not live in a new module; no reason is REWORK.
references/area-lease.md, zone rules, after the hot-file line Two cards queued on one source file over 2,000 lines: the seat opens a move-only split card for that file, Blocked-by: the open PRs on it, and the queued cards follow it. The split PR registers the file in facade-delegation-registry.json with its ceiling.
references/dispatch-runbook.md, dispatch-order section A card whose file surface touches a source file over 2,000 lines: the dispatch order names the module the new code lands in.

Second card: a classifier_refusals field in the os-dev report (commit d9725a76). The report template in .claude/agents/os-dev.md gains one list field after api_writes, and one bullet under the template:

  • a row per command the permission classifier refused, with five keys: command (verbatim), reason (as the classifier quoted it), mode (subagent | cloud | thread), human_turn_before (yes | no | unknown: a human-typed turn earlier in the session), resend (none | passed | refused, plus what changed);
  • [] when none; it records what happened: no refusal is staged and no command is re-sent to fill it.

The field allows nothing and adds no allow rule. The existing rule on a classifier refusal (stop, record the command and reason in deviations, the seat forwards to the maintainer, never re-send by another route) is untouched.

Rule-change reading, hunk by hunk

  • The four sentences of the first card change what a dev, an L1 reviewer and a seat do: each copies, in substance, a sentence of the card's Ask, which the maintainer approved with the words on the Ruling-ref: line. That is the ruled part.
  • The report field is a record: it changes no permission, no order of work and nothing that goes to the maintainer. Read on its own it is none.
  • Every deletion is a rationale sentence or, in area-lease.md, the one-line overview; none states a rule (list below). Slimming, not a rule change.

No hunk reads as yes to me. If the reviewer reads one that way, the PR is Tier H and waits for the maintainer.

Byte arithmetic (base 302a4c32, head d9725a76; wc -c)

File Base Head Ceiling Added Deleted
.claude/agents/os-dev.md 33491 33475 33491 691 707
references/l1-review-checklist.md 6875 6871 6875 511 515
references/area-lease.md 7220 7220 7220 355 355
references/dispatch-runbook.md 20480 20455 20483 169 194

Added and deleted are whole changed lines, so an edited line counts on both sides. scripts/pm/check-skill-line-ratchet.mjs is not in the diff: no ceiling row moves, up or down.

What was deleted to pay, line by line

.claude/agents/os-dev.md (new sentences: 214 bytes for the new-module bullet, 414 for the field and its bullet; 644 bytes paid):

  • rule 1: the sentence saying why the scratchpad is split per issue (agents of one batch share the directory and overwrite each other's files), 99 bytes. The rule (make issue-N/ and write there) stays on the line above.
  • local verification: the sentence saying why a hand-made git diff list is wrong (sibling files landed later are counted as yours), 119 bytes. The prohibition stays on the line above.
  • local verification, item 5: "the derivation answers which gates read your file, not which tests test the script", 79 bytes. The duty (run the script's own tests) stays.
  • local verification: what feeding a sibling repo's paths to this checkout returns (this repo's families, exit 0, all wrong), 120 bytes. The three rules around it stay (check the first line, derive the sibling's list by hand, pass --repo).
  • local verification: "a late commit moves exactly the ratchet readings", 48 bytes. The rule after the semicolon stays (re-run the union on the new head after any push).
  • standard clauses: what a false red and a false green from a stale build look like, 119 bytes. The rule (build before judging) stays.
  • standard clauses: "this proves you read the rebuilt declarations, not the cache", 60 bytes. The reverse-verification rule stays.

references/l1-review-checklist.md (new sentence 117 bytes; 121 paid): five clause endings that give a reason, not a criterion: "read against it" in the intro (13), "an empty changeset holds a release back here" (39; the prohibition stays on the line above), "doing it for the dev launders the permission" (19), "this reconciles the two dispatch-side sentences" (31), "the green may be false" (19).

references/area-lease.md (new sentence 181 bytes; 181 paid): the one-line overview under the title, with its blank line (119). Each thing it summarised is still stated as a rule further down: zones on demand, the L1 thread, zones landing their own PRs after ACCEPT, the seat keeping W0, routing and governed PRs. Also "so two zones rarely change the same function" (31) and "a lease over a hot file blocks the other seats" (31), both reasons after a rule that stays.

references/dispatch-runbook.md (new sentence 86 bytes; 111 paid): the reason after "never retell an estimate dressed as a ruling" (74) and the reason after "never write: stop when you find a consumer" (37). Both prohibitions stay.

Tests

No test file is added, changed or deleted, and no script changes. Nothing pins the deleted text: the phrases scripts/pm/l1-face.mjs holds from the checklist and from os-dev.md are all still present (its self-test, 51 cases, exit 0 on the head).

Derived gates, all on head d9725a76, each run with stdin closed and the exit code captured before any pipe:

27 of 27 derived commands, exit 0; reconciliation 0 NOT-MEASURED, 0 UNRUN
node scripts/check-closing-keyword-parity.mjs :: exit 0
node scripts/check-closing-keyword-parity.mjs --self-test :: exit 0
node scripts/check-comment-mask-corpus.mjs :: exit 0
node scripts/pm/check-governed-queue-guard.mjs --self-test :: exit 0
node scripts/pm/check-harness-current.mjs --self-test :: exit 0
pnpm --filter @objectstack/lint run check:doc-formula-expressions :: exit 0
pnpm check:adr-anchors :: exit 0
pnpm check:agent-model-declared :: exit 0
pnpm check:agent-test-spelling :: exit 0
pnpm check:commit-card-trailers :: exit 0
pnpm check:cross-package-test-inputs :: exit 0
pnpm check:doc-authoring :: exit 0
pnpm check:driver-memory-census :: exit 0
pnpm check:gitlink-declared :: exit 0
pnpm check:nul-bytes :: exit 0
pnpm check:pm-expected-skips :: exit 0
pnpm check:pm-governed-merges :: exit 0
pnpm check:pm-label-write :: exit 0
pnpm check:pm-prior-rulings :: exit 0
pnpm check:pm-record-recognisers :: exit 0
pnpm check:pm-settings-deny-roster :: exit 0
pnpm check:pm-skill-id-lint :: exit 0
pnpm check:pm-skill-ratchet :: exit 0
pnpm check:refd-timer-probe :: exit 0
pnpm check:required-contexts :: exit 0
pnpm check:skill-frame-sync :: exit 0
pnpm check:watch-hint-literal :: exit 0

node scripts/pm/dispatch-gates.mjs --ran on that record: "27 derived famil(ies) accounted for — 27 run, 0 NOT-MEASURED (a DERIVED zero — all 27 recorded an exit code and none of them is 3)".

The ratchet's four lines on the head: os-dev.md is 33475 bytes (ceiling 33491; headroom 16), l1-review-checklist.md is 6871 bytes (ceiling 6875; headroom 4), area-lease.md is 7220 bytes (ceiling 7220; headroom 0), dispatch-runbook.md is 20455 bytes (ceiling 20483; headroom 28).

A first pass recorded exit 3 (PREREQUISITE NOT MET) for the doc-formula gate: @objectstack/formula and @objectstack/lint were not built in the new worktree. Both were built under the verify lock (VERDICT command-exit 0), and all 27 commands were then run again into a fresh record; the lines above are that second record.

Outside the derived list, also exit 0 on the head: node scripts/pm/l1-face.mjs --self-test, pnpm check:pm-governed-prose, node scripts/pm/check-skill-line-ratchet.mjs --self-test.

Acceptance notes

  • No reader validates the report's field set. Searched scripts/ for the template's field names: scripts/pm/label-write.mjs reads dogfood_battery alone, and nothing checks the set of keys. So the new field owes no reader row and no self-test case, and no script is in the diff.
  • deviations still carries a refused command. The existing rule, the L1 checklist line that asks for the refused command in deviations, and the reminder scripts/pm/l1-face.mjs prints all still say deviations. The new field is added beside it, so a refusal is written in both places. Making classifier_refusals the only home needs three edits, one of them in l1-face.mjs, which is outside this claim's file surface; left as an open question in the report.
  • human_turn_before has a third value, unknown. A subagent does not see its parent session's turns, so a forced yes or no would be a guess in the one column the census wants to test.
  • area-lease.md loses its one-line overview. It was the only way to pay 181 bytes in that file without deleting a rule; the reviewer may prefer a different payment.
  • Headroom is left where it fell (16, 4, 0 and 28 bytes). Lowering the rows is legitimate but edits check-skill-line-ratchet.mjs, outside the file surface.
  • The branch is two commits behind origin/main (0124851b); neither touches these four files, and overlap-check.mjs reads a clean merge with the base and no open PR sharing a file. Not merged, to keep one commit per card.
  • The card's open point for the seat (the CODEOWNERS line on .claude/**, Tier S or Tier H) is the seat's to confirm before landing.

Verification

Read first, by risk:

  1. .claude/skills/pm-dispatch/references/area-lease.md: the deleted overview line (top of the file) and the new split-card line.
  2. .claude/agents/os-dev.md: the seven deleted rationale sentences, the new bullet at the end of rule 3, and the template field.
  3. .claude/skills/pm-dispatch/references/l1-review-checklist.md: the five trimmed clause endings and the new line.

Two-minute check: node scripts/pm/check-skill-line-ratchet.mjs prints the four lines quoted above and exits 0, and git diff origin/main...HEAD --stat lists four files, all under .claude/.


Generated by Claude Code

…rule, L1 line, split-card line, dispatch-order line

Four sentences, one per file, each paid by a deletion in the same file; no
ceiling in check-skill-line-ratchet.mjs moves.

- os-dev.md, scope rule: a new concern added to a source file over 1,000
  lines is written in a new sibling module and called from the existing
  file; a fix inside an existing function stays; existing code is never
  moved to make room (that is a split card).
- l1-review-checklist.md: more than 300 net lines added to a non-test
  source file already over 2,000 lines needs the reason in the ACCEPT, or
  REWORK.
- area-lease.md: two cards queued on one source file over 2,000 lines make
  the seat file a move-only split card, blocked by the open PRs on the
  file; the split PR registers the file with its ceiling.
- dispatch-runbook.md: a dispatch order whose file surface touches such a
  file names the module the new code lands in.

Paid by rationale sentences and one overview line; no rule is deleted.

Claude-Session: https://claude.ai/code/session_01ADHkmRJUY9Ncce14hVHd25
Co-authored-by: Claude <noreply@anthropic.com>
One row per command the permission classifier refused: the command
verbatim, the reason as the classifier quoted it, the dispatch mode,
whether a human-typed turn came earlier in the session, and whether a
re-send passed and with what change. Empty list when none. It records
what happened: no refusal is staged and no command is re-sent to fill
it. The field allows nothing and adds no allow rule; the existing rule
(stop, record in deviations, the seat forwards to the maintainer, never
re-send by another route) is unchanged.

No script validates the report's field set (label-write.mjs reads
dogfood_battery only), so no reader row is owed.

Paid in the same file by five rationale sentences; the ceiling row does
not move.

Claude-Session: https://claude.ai/code/session_01ADHkmRJUY9Ncce14hVHd25
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmSAjFEZHRpRq3WCj6z

Contract-review-claim: session_01ADHkmSAjFEZHRpRq3WCj6z · head d9725a7 · 2026-11-30T04:00Z

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmRJUY9Ncce14hVHd25

Final green head for review: d9725a76d0e99d5185c5e35e75b3cdf23406493a (read 2026-11-30T04:05Z: 24 check-runs success, 28 skipped, 0 failed or pending; mergeable clean). Fold of #38664 + #38669 (claims 7267855082 / 7267868303; one commit per card), dev report on #38664. 36 changed lines, rule text only, Rule-change: ruled declared with a Ruling-ref: line. check-governed-merges --pr 38683 reads Tier H until a contract-review record names this head with Rule-change-verified: ruled. Owed: L1 (L1-a) and that record; the PR stays draft and lands through the owner seat.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmSAjFEZHRpRq3WCj6z

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: d9725a76d0e99d5185c5e35e75b3cdf23406493a
Local-runs: none
Scope: .claude/agents/os-dev.md, .claude/skills/pm-dispatch/references/area-lease.md, .claude/skills/pm-dispatch/references/dispatch-runbook.md, .claude/skills/pm-dispatch/references/l1-review-checklist.md + none
Rule-change-verified: ruled

Read for this record: cards #38664 and #38669 (bodies and every comment: triage 7266689375 and 7266763067, claims 7267855082 and 7267868303, the os-dev-report 7268340766), comment 7266139336 on #36936 (the census #38669 came from), the PR body, the PR file list (four files, all under .claude/), the net diff 302a4c32..d9725a76 (18 lines added, 18 deleted), and the check-runs on the head. The four hits are what record-recognisers.mjs --template --paths prints for the PR's own file list; no script, gate or test is in the diff, so no implementing file is named.

Check-runs on d9725a76, read 2026-11-30T04:04Z: 52 runs, all concluded, 24 success and 28 skipped, none failed, cancelled or pending. Lint · PM dispatch-gates (the job that runs the byte ratchet) and Lint · CI, release & engine gates were still in progress on the first read at about 04:02Z and concluded success by the second.

① Derived judgments

  • Accept sets and public surface: none changes. The diff is rule text in four .claude/ files; no schema, no export, no script, no gate, no ceiling row. Right.
  • Byte budget, measured with git show SHA:PATH | wc -c at base, head and origin/main (0124851), ceilings read from scripts/pm/check-skill-line-ratchet.mjs at the head and on main (identical; the file is not in the diff):
    • .claude/agents/os-dev.md: 33491 → 33475, ceiling 33491. Right.
    • references/l1-review-checklist.md: 6875 → 6871, ceiling 6875. Right.
    • references/area-lease.md: 7220 → 7220, ceiling 7220, headroom 0. Right.
    • references/dispatch-runbook.md: 20480 → 20455, ceiling 20483. Right.
      Every file's growth is paid inside the same file and no ceiling rises, as the card's Ask requires. The PR body's table matches these readings. origin/main has not moved on any of the four files or on the ratchet since the merge-base, so the merged bytes equal the head bytes.
  • Pins on deleted text: each of the 17 deleted phrases was searched in the head tree; none is held by a script or test. The one phrase scripts/pm/l1-face.mjs pins on an edited line (the classifier-refusal line of the checklist, l1-face.mjs:114) is the kept half of that line. Right.
  • Fixes #38664 and Fixes #38669: both cards' acceptance is met by the tree (item ④). Right.

② Semver level

skip-changeset label, no changeset: right. Nothing under a published package changes; Check Changeset concluded success. Clause-②: no on the PR body and both claims: right, no declared capability is narrowed or widened. Metadata-protocol: none: right.

③ Boundary flags

SQL push-down: not applicable, no code in the diff.

The dev's four open questions:

  1. A refusal recorded in both classifier_refusals and deviations: accept A as landed. os-dev.md:255 (stop, record command and reason in deviations, the seat forwards to the maintainer, never re-send by another route), the checklist line that asks for the refused command in deviations, and the l1-face.mjs reminder all stand unedited, so what the L1 reviewer reads stays true. Making the new field the one home edits scripts/pm/l1-face.mjs, outside the claim's file surface: a card of its own if the census wants it, not this PR.
  2. The area-lease.md overview cut: accept A. The deleted line was a definition of the mode, not a rule; each element is still stated as a rule below it (zones on demand: section one; L1 threads: "L1 线程每 3 活跃区一条"; zones land their own PRs after ACCEPT: the "落地" lines; the seat keeps W0, routing and governed PRs: 开席 item 4, "席只裁路由", "受管面与过线卡的 PR 区 ⛔ 不落,交席位"). One residue is noted as a nit in ④.
  3. A third value unknown on human_turn_before: accept A. The card asks "whether a human-typed turn preceded it in that session"; a subagent cannot see its parent's turns and a forced yes or no would put guesses in the column fleet: three of seven cloud dev sessions had identical relay writes refused by their permission classifier ("Undermining Oversight") while sibling sessions passed #36936 wants to test. The mode:cloud session, the one the controlled reading is planned on, sees its own turns and can answer yes or no.
  4. The tier: ruled is confirmed for the whole diff, basis below. No hunk reads as yes.

Escalated to the adopting seat, not answered by this record: card #38664's speed-read tells the maintainer "需 os-zhuang 批准" and "要你做什么:合并时批准", triage 7266689375 sizes it "Tier H, rule text", and the card leaves "confirm Tier S vs Tier H before landing" as an open point for the claiming seat; the PR's own speed-read says "要你做什么:无". By AGENTS.md (.claude/** is S on ruled with a Ruling-ref: line quoting the maintainer, repeated on this record) the PR reads Tier S, but the maintainer was told on the card that he would approve at merge. No comment on either card answers the open point. The seat answers it on the card before queueing.

Rule-change, hunk by hunk. The Ruling-ref: line quotes 「同意,立卡」「按照 fable的方案」 (the maintainer, 2026-11-30T01:18Z). Those words approve a plan; the plan's rule text reaches GitHub only as the four quoted sentences of card #38664's Ask, filed on the maintainer's word and confirmed maintainer-directed by triage 7266689375. The project thread itself is not readable from here, so the copy was checked against the card's Ask.

  • os-dev.md, new last bullet of rule 3 (scope): over 1,000 lines, a new concern (new operation, new rule family, new sub-flow) goes in a new sibling module and the existing file gains only the call; a fix inside an existing function stays; never move existing code to make room, that is a split card. Copies Ask 1 clause for clause, placed beside the scope rule as asked. ruled.
  • l1-review-checklist.md, new line in the scope section: a non-test source file already over 2,000 lines gaining more than 300 net lines, the ACCEPT names why it could not go in a new module, no reason is REWORK. Copies Ask 2. ruled.
  • area-lease.md, new line after the hot-file line: two cards queued on one source file over 2,000 lines, the seat files its move-only split card, Blocked-by: the open PRs on it, queued cards follow, the split PR registers the file with its ceiling in the facade registry. Copies Ask 3. ruled.
  • dispatch-runbook.md, new line in the dispatch-order file-surface block: a card whose file surface touches a source file over 2,000 lines, the order names the module the new code lands in. Copies Ask 4. ruled.
  • Thresholds 1,000 / 2,000 / 300 as the card measured; no hunk adds a gate, a ceiling, an AGENTS.md sentence or a report, the four things the card rules out. Nothing goes beyond the Ask.
  • os-dev.md, the classifier_refusals template field and its bullet (os-dev report: a closed classifier_refusals field, so permission-classifier refusals of relay writes can be counted instead of rebuilt by regex #38669): a record field. It permits nothing, adds no allow rule, changes no order of work and nothing that goes to the maintainer; os-dev.md:255 is untouched. The bullet's two prohibitions (no staged refusal, no re-send to fill the field) restate the card's "No refusal is staged to fill it; it records what happened". none.
  • The 17 deletions (7 in os-dev.md, 5 clause endings in the checklist, 3 in area-lease.md, 2 in the runbook): each is a reason or a consequence attached to a rule that stays on the same or the neighbouring line, or the overview line of area-lease.md. Read one by one against the head tree; none removes a duty, a prohibition or a criterion. Slimming, none.

The strongest value any hunk earns is ruled, equal to the PR body's Rule-change: ruled.

④ Design judgment

No must-fix, no should-fix.

.claude/agents/os-dev.md. The new bullet sits at the end of rule 3 ("范围 = 这张 issue"), which is the scope rule the card names. It holds against the neighbouring rules: it forbids moving existing code, so it cannot be read as licence for an unasked refactor, and "既有函数内的修复留原处" keeps defect fixes where rule 3 already puts them. The template field is valid inside the template's JSON, sits after api_writes as the PR says, and carries the five keys the card lists (command, reason, mode, human turn, re-send and what changed). mode uses the three dispatch modes the census counted. No reader validates the report's key set (label-write.mjs reads dogfood_battery alone; a tree search for classifier_refusals finds only this file), so no reader row is owed. The seven deleted sentences are all "why" lines; the duty each explained is still on the line above or below (scratchpad per issue, no hand-made diff list, the script's own tests, the sibling-repo derivation, re-run the union after a push, build first, the reverse verification).

.claude/skills/pm-dispatch/references/l1-review-checklist.md. The new line sits directly under the existing move/split net-growth line, the right neighbour. The five trimmed endings leave each criterion whole: skip-changeset not an empty changeset, the seat forwards a refused label to the maintainer and never applies it itself, the rejection assertions stay verbatim, the stale-dist question is still asked.

.claude/skills/pm-dispatch/references/area-lease.md. The new line sits after the hot-file line in 区内规则 and agrees with it: the hot-file line keeps lease paths still, the new line gives the seat the split route when two cards queue. scripts/facade-delegation-registry.json exists at the head. "席立…卡" is a seat-filed card, which is what the Ask says. The two trimmed reasons ("让两区极少改同一函数", "租约罩热文件即挡他席") leave both rules standing.

.claude/skills/pm-dispatch/references/dispatch-runbook.md. The new line sits among the file-surface lines of 派发词构造细则, the block the order's file surface is built from. The two trimmed reasons leave both prohibitions.

Nits, none affecting correctness or the contract:

  • nit: area-lease.md names the registry as facade-delegation-registry.json; the card and the tree say scripts/facade-delegation-registry.json. The basename is unique in the tree, so it resolves.
  • nit: the deleted area-lease.md overview also said the seat keeps the "台账" (ledger). The PR body's list of successors does not mention it, and no line below says it in one phrase; the ledger duties are stated item by item (the lease table on the seat post as the only record, the usage line, the handover on the seat post). No rule is lost; the PR body's account is one item short.
  • nit: the template's resend key lists passed | refused beside os-dev.md:255, which tells a dev to stop on a refused external write and never re-send by another route. The field records and line 255 still governs, and the new bullet forbids re-sending to fill the field, but neither line points at the other. A pointer belongs to the one-home follow-up of open question 1.
  • nit: for a source file between 1,000 and 2,000 lines the dev rule already requires a new sibling module, while the order's duty to name that module starts at 2,000. In that band the dev creates a file the claim's File surface: did not name and amends the claim by the existing route. These are the ruled thresholds, copied as ruled; noted for the large-file plan's owner, not re-ruled here.

Implemented-by: claude/issue-38664-os-dev-rule-fold
Reviewed-by: session_01ADHkmSAjFEZHRpRq3WCj6z

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmQm8PTU4AkVU5kdwEv
L1-a, the seat's L1 thread · 2026-11-30T04:07Z · first review

席位核对

ACCEPT @ d9725a76d0e99d5185c5e35e75b3cdf23406493a (cards #38664 + #38669 folded, one commit each, zone o3-F). The PR is rule text only, on the governed face (.claude/**), declared Rule-change: ruled with a Ruling-ref:. Whether that holds, and so the tier, is the seat's L2 call (claimed 7268395863).

Read at head:

  • 开发规范:新功能放新模块,大文件净增需说明理由 #38664 (ab3b298f): the four sentences against the card's Ask, one by one. Each matches in substance.
    1. os-dev.md, scope rule: "源文件超 1,000 行 ⇒ 新关注点(新操作、新规则族、新子流程)写进同级新模块,原文件只加调用;既有函数内的修复留原处;⛔ 不为腾位搬既有代码:那是拆分卡". This is Ask 1 clause by clause.
    2. l1-review-checklist.md, scope section: ">2,000 行 … 净增 >300 行:ACCEPT 点名为何进不了新模块,无理由 ⇒ REWORK". This is Ask 2.
    3. area-lease.md: two cards on one >2,000-line file ⇒ a move-only split card Blocked-by: the open PRs on it, and the split PR registers the file with its ceiling. This is Ask 3. scripts/facade-delegation-registry.json exists at this head.
    4. dispatch-runbook.md, file-surface section: the dispatch order names the module. This is Ask 4.
      No sentence carries a card number, date or current value.
  • os-dev report: a closed classifier_refusals field, so permission-classifier refusals of relay writes can be counted instead of rebuilt by regex #38669 (d9725a76): classifier_refusals.
    • The template field carries the five keys the card's "Wanted" names: command verbatim, reason as quoted, mode, human_turn_before, and resend with what changed.
    • The bullet says it is a closed field, [] when empty, and "⛔ 不造拒、不为填它重发".
    • The existing refusal rule (stop, record in deviations, never re-send by another route) is untouched.
  • The deletions are rationale, not rules. I read each of the 15 deleted lines against what stays.
    • os-dev.md: seven "why" sentences go, and each line above still states its rule.
    • l1-review-checklist.md: five reason clauses go, and each criterion stays.
    • dispatch-runbook.md: two reason clauses go after a ⛔ that stays.
    • area-lease.md: the opening one-line overview goes. Its parts are each stated later in the file: W0 at :24, zone self-landing at :47-51, seat routing at :54, the governed face at :51. Two other clauses go as well: "让两区极少改同一函数" (the boundary rule "按卡触及的文件与包聚类" stays) and the hot-file rationale.
  • Bytes. check-skill-line-ratchet.mjs exits 0 at this head. wc -c gives 33475, 6871, 7220 and 20455, the body's table, each at or under its ceiling. No ceiling row moves.
  • skip-changeset. It touches .claude/** only, in no package.
  • Checks. 24 success, 28 expected skip, 0 failed, 0 pending. mergeable_state is clean.

For the seat (L2), not blocking: the one deletion that comes closest to a rule is area-lease's "让两区极少改同一函数", the goal a boundary is drawn to. I read it as rationale for the clustering rule that stays, but it is the sentence to weigh if you read any hunk as yes.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmRJUY9Ncce14hVHd25

Landing not performed (2026-11-30T04:10Z): the zone session's permission classifier refused the landing stroke before it ran, reason quoted [Destructive or Unwanted Actions]. Command, verbatim: node scripts/pm/label-write.mjs --issue 38683 --comment-file FILE --land (its --dry-run passed: comment → pr_ready → automerge_enable). Nothing was written; the PR stays draft. Not retried by any other spelling or route. With the maintainer for a word in the zone thread. Data point for #38669 / #36936 (mode: project thread session, no human-typed turn in this thread since 01:00Z).

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#3 · os-steve · session_01ADHkmRJUY9Ncce14hVHd25

Landing, read 2026-11-30T04:15Z at head d9725a76d0e99d5185c5e35e75b3cdf23406493a:

probe reading
check-governed-merges --pr 38683 Tier S — .claude/** only, Rule-change: ruled, record on this head reads Rule-change-verified: ruled; 36 changed lines ≤ 3000
reviews on this head L1 ACCEPT 7268501674 · contract review PASS 7268474055
check-runs 24 success, 28 skipped, 0 failed or pending; mergeable clean

State: ready + auto-merge now, by the zone (Tier S lands in the lane; the owner seat's --handoff was refused as Tier S). The first landing stroke was refused by this session's permission classifier (7268541983); the maintainer then chose, on the zone thread's decision card, verbatim 「落地 PR #38683」 (2026-11-30T04:14Z). On merge: #38664 and #38669 close and leave pm:dispatched.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 30, 2026 04:15
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 30, 2026
Merged via the queue into main with commit 5ac1ee0 Nov 30, 2026
53 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-38664-os-dev-rule-fold branch November 30, 2026 04:30
Nenzyz pushed a commit to Nenzyz/objectstack that referenced this pull request Dec 1, 2026
…D, not sent to the background (objectstack-ai#38684)

<!-- claude-projects-attribution: {"github_login":"os-steve"} -->
_Requested by **Steve** · [project
thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi98ZAtPQK4A8ABvN79TALFDE)_

Fixes objectstack-ai#38668

Clause-②: no
Metadata-protocol: none
Rule-change: yes

## 维护者速读

- 用户能看到什么变化:用户无感;派出去的开发 agent 遇到十分钟内跑不完的本地检查,不再把它转到后台去跑,而是如实记成「本地没测」并交给
CI。
- 为什么做:属于车队规则维护;原规则教的后台跑法正是权限审查会拒绝的做法,照做的 agent 白丢一次检查,还要事后解释。
- 出错会怎样:带破坏性改动的 PR 原本在本地跑的全量实景回归,今后多半只能等合并队列第一次报红;撤回本 PR 即恢复原文。
- 要你做什么:这是一次规则变更,请审阅后亲手合并。

## What changes

Two sentences of `.claude/agents/os-dev.md` and one reading line of
`.claude/skills/pm-dispatch/references/readings-ci.md`. No script, no
test, no ceiling row.

1. `os-dev.md`, 资源纪律 item 1, the background-run bullet. It prescribed
`nohup … &` plus `tail --pid` for anything past the foreground limit,
the form the dev sessions' permission classifier refused. It now reads:
a run that cannot finish inside the foreground limit is never moved to
the background, in any spelling; it is declared in the `--ran` record as
`NOT-MEASURED COMMAND :: REASON` (the file spells the two placeholders
in its own notation) and CI carries it.
2. `os-dev.md`, 干净收尾 item 4. The line told a dev to read a still-running
gate's log (the redirect target) at report time, which only makes sense
beside a detached run. It now reads: a report holds no gate that is
still running; one that did not finish in the foreground is recorded NOT
MEASURED with the measured reason, and CI carries it.
3. `readings-ci.md`, the `check:pm-dispatch-gates` reading. It carried
the same prescription (detach plus `tail --pid`) beside a reading of
1216 to 1246 s. It now carries the reading taken for this PR, 404 s in
the foreground for the fast tier, and says to run it in the foreground.

Nothing here looks for another way to get a background run past the
permission check. The change removes the request to run in the
background.

### Byte arithmetic (`wc -c`, ceilings from
`scripts/pm/check-skill-line-ratchet.mjs`, not edited)

| File | Before | Out | In | After | Ceiling | Net |
|:---|---:|---:|---:|---:|---:|---:|
| `.claude/agents/os-dev.md` | 33491 | 113 + 119 | 129 + 103 | 33491 |
33491 | 0 |
| `.claude/skills/pm-dispatch/references/readings-ci.md` | 4896 | 119 |
114 | 4891 | 4900 | -5 |

No ceiling moves. `pnpm check:pm-skill-ratchet` exits 0 at `b469dcec`.

### Read first

1. `.claude/agents/os-dev.md` line 90: the rule itself. The risk is the
phrase 「任何拼法」: it is meant to rule out a renamed background run, not a
dev server.
2. `.claude/agents/os-dev.md` line 293: the report-side half of the same
rule.
3. `.claude/skills/pm-dispatch/references/readings-ci.md` line 48: a
reading replaced by a newer one. See the first acceptance note for why
this file is in the diff.

## Tests

No test changed and none is owed: the diff is rule text and one reading.
`git grep` over the tree at `b469dcec` finds the two replaced sentences
nowhere else, so no test or gate pins them. No ablation: no tested
behaviour changed.

Measurements taken for the rule (the card asked which gates actually
pass the foreground limit today):

<details><summary>check:pm-dispatch-gates in the foreground: 404 s, exit
0 (limit 600 s)</summary>

Tree `0124851b` (the branch point; the diff does not touch the
instrument), 4 cores, load average 0.42 at the start and 1.03 at the
end, no lock, stdin from `/dev/null`, exit captured before any pipe.

```
exit 0 wall 404s head 0124851
dispatch-gates self-test tiers: fast 2686 case(s) in 402.9s · slow tier deferred (9 section(s)) — run without --fast for both.
✓ dispatch-gates self-test (fast tier): 2686 cases pass; 9 slow section(s) deferred.
check:pm-dispatch-gates: the battery (the fast tier) took 403.1s on this box.
```

It fits with about 196 s to spare on a quiet box. On a busy box it may
not; the rule then applies as written (killed at the limit, declared NOT
MEASURED, CI runs it in `lint-pm-dispatch-gates`).

</details>

<details><summary>Full dogfood: NOT MEASURED locally; the CI reading
says it cannot fit</summary>

Not run locally: a run known to pass the limit would hold the shared
lock for ten minutes and reach no verdict. Read instead from CI on main
`39064f62`, the step `Boot example apps and exercise real user flows` of
the three `Dogfood Regression Gate (k/3)` jobs: 1063 s (1/3), 778 s
(2/3), 698 s (3/3). Each third alone is past 600 s, so the unsharded
command the agent file prescribes cannot finish in one foreground call.

</details>

<details><summary>The record spelling the new bullet names, probed
against the instrument</summary>

On copies of this PR's own run record at `b469dcec` (the real record is
untouched):

```
# one family replaced by a NOT-MEASURED line with a reason
Run reconciliation — 26 derived, 25 run, 1 NOT-MEASURED, 0 UNRUN.
✓ dispatch-gates --ran: 26 derived famil(ies) accounted for — 25 run, 1 NOT-MEASURED (0 DERIVED from a recorded exit 3, 1 claimed).        exit 0

# the same family recorded with a bare kill code and no declaration
Run reconciliation — 26 derived, 25 run, 0 NOT-MEASURED, 1 UNRUN.
✗ dispatch-gates --ran: 1 of 26 derived famil(ies) UNRUN.        exit 1
```

So the declared path already exists in `scripts/pm/dispatch-gates.mjs`
(`parseRunRecord`, `runReconciliation`): a kill code alone is UNRUN, and
the declaration with a reason is what makes it NOT-MEASURED. The
instrument prints the spelling itself when it meets a bare kill code.

</details>

## Acceptance notes

- **`readings-ci.md` is in the diff — seat ruled A (keep it); claim
amendment 7268968229 names it.** The claim allows "the pm-dispatch
reference that states the declared-narrowing path for `--ran` records if
its text must name the new case". No pm-dispatch reference mentions
`--ran` at all; the only pm-dispatch text on a gate past the limit is
this one line, and it prescribed the refused form. I took it to be the
reference meant. It is its own commit (`b469dcec`), so dropping it is
one revert if the seat reads the fence differently.
- **The instruments still prescribe the detached form, and this PR does
not touch them — follow-up objectstack-ai#38689 (Blocked-by this PR)** (outside the
claim; `dispatch-gates.mjs` is a Tier H instrument).
`scripts/pm/check-dispatch-gates.mjs` has a header section telling an
agent container to run detached, and its kill branch prints `nohup pnpm
check:pm-dispatch-gates > pm-dispatch-gates.log 2>&1 &` as the remedy to
a dev whose foreground run was just killed;
`scripts/pm/dispatch-gates.mjs` carries the same header section. After
this PR the agent file and the instrument's printed remedy disagree.
- **Full dogfood has no local route left — follow-up objectstack-ai#38688 (maintainer
decision; not this PR).** The definition-of-done lines of `os-dev.md`
still order one full dogfood run under the lock on a PR whose title
carries `!` or whose clause line carries the narrowing arm, with no
shard and never skipped. By the CI reading above that run cannot finish
in the foreground, and PR runs do not carry the dogfood shards (queue
runs do). Those lines are outside this claim; the question is in the
report.
- `.claude/skills/scenario-eval/SKILL.md` and
`packages/qa/scenarios/README.md` prescribe `nohup` plus `tail --pid`
for scenario and gallery runs. Those are another seat's runs and no
refusal is recorded for them; noted, not edited.
- `readings-shell.md` holds a reading that a refused compound command is
retried as bare actions before reporting blocked. It is a general
reading about command shape, not about background runs, and is
untouched; a reader may still put it beside the new bullet.

## Verification

Two minutes: `git diff origin/main...HEAD --stat` shows 2 files, 3
insertions, 3 deletions; then `git grep -n -E 'nohup|tail --pid' --
.claude/agents .claude/skills/pm-dispatch` at the head shows one hit,
the `readings-shell.md` line that warns against `nohup` inside a
background tool call, and none that prescribes it.

<details><summary>Local gate union at b469dce: 26 derived, 26 run, exit
0</summary>

`node scripts/pm/dispatch-gates.mjs --commands --repo
objectstack-ai/objectstack` (no paths) derived 26 commands from 2
changed paths against merge base `0124851b`. Each ran in the foreground
with stdin from `/dev/null`, the exit captured before any pipe, and was
recorded as `COMMAND :: exit N`; the whole loop took 325 s in one
foreground call.

```
Run reconciliation — 26 derived, 26 run, 0 NOT-MEASURED, 0 UNRUN.
✓ dispatch-gates --ran: 26 derived famil(ies) accounted for — 26 run, 0 NOT-MEASURED (a DERIVED zero — all 26 recorded an exit code and none of them is 3).
```

The first pass recorded `pnpm --filter @objectstack/lint run
check:doc-formula-expressions :: exit 3` (PREREQUISITE NOT MET:
`@objectstack/formula` and `@objectstack/lint` were not built). I built
the two under the shared lock (`VERDICT command-exit 0`, held 80 s) and
ran the whole list again; the record above is that second pass, with no
line edited.

Longest single gate: `node scripts/check-comment-mask-corpus.mjs`, 188
s. Local-only family also run: `pnpm check:skill-frame-freshness`, exit
0.

</details>

`node scripts/pm/overlap-check.mjs --branch=HEAD` at `b469dcec`:
`VERDICT clean exit 0` against `origin/main` and against the one open PR
that shares `os-dev.md` (objectstack-ai#38683, other sections).

---
_Generated by [Claude
Code](https://claude.ai/code/session_01ADHkmRJUY9Ncce14hVHd25)_


<!-- signed: repo:objectstack#3 · os-steve ·
session_01ADHkmRJUY9Ncce14hVHd25 -->

---------

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/s skip-changeset PR has no user-facing published change; bypasses the changeset gate

Projects

None yet

2 participants