Repository navigation
docs(pm-dispatch): card-thread backend (mode:thread), coordinator scheduling and per-card dispatch effort - #25214
Conversation
…patch effort A seat whose session is a project thread dispatches each card as its own thread; the dispatch effort is chosen per card by difficulty, beside the model tier, in the claim's Container & model line and the dispatch order. Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
… the coordinator Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
…r-seat claim Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
…nd security go to a thread Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
…review-tier ruling thread Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
…eady stated elsewhere dispatch-runbook.md: 16 lines whose rule lives in SKILL.md, os-dev.md, state-machine.md, seat-lifecycle.md, seat-post-protocol.md or execution-duties.md, plus two frame-paste lines merged into one. execution-duties.md: two lines already stated by os-dev.md rule 6 and the runbook's cloud section. Both files land at their ceilings. Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
Contract reviewServed-tier: Inputs: card #25185 body and all three comments (claim 6335635315, the skills seat's waiting note 6339578152, the dev's ① Derived judgmentsCard acceptance criteria. Item 1 (recognise the project environment; Rule-by-rule, right unless marked:
The 18 deletions, each verified against the head tree — every rule keeps a surviving home; none is a FAIL: Ratchet. PR body, non-blocking notes for the seat's 终稿: it says 「21 insertions and 25 deletions」; GitHub counts 29 / 26 (edited lines count on both sides). Two maintainer quotations in the body contain a model name; ② Semver level
③ Boundary flags
FAIL items, each one line:
Implemented-by: VERDICT: FAIL Generated by Claude Code |
…seat; branch convention stays, thread branch is the measured exception Contract review FAIL items 1-3 on the card thread section: the thread's first act is to report its designated push branch and wait; the seat writes the assignee and posts the claim in AGENTS.md's order before the thread starts; claude/issue-<n>-<slug> remains the convention and the thread's designated branch is recorded as the measured platform exception; the ruling-thread lines leave this PR. Claude-Session: https://claude.ai/code/session_01NVBPkGXNnJayvXnCjcXpFb Co-authored-by: Claude <noreply@anthropic.com>
Contract reviewServed-tier: Round 2 on the head above, following record 6341183860 (FAIL on b301b37). Inputs: card #25185 body and all four comments (the dev's round-2 ① Derived judgmentsFAIL 1 (thread wrote the assignee and posted the claim) — cured. Runbook section lines 13–14: 「线程开起后第一动作:向席位报告指定推送分支并等待;⛔ 线程不贴认领、不写 assignee」 and 「席位按 AGENTS.md 的顺序写 assignee+ FAIL 2 (designated thread branch vs FAIL 3 (ruling thread) — cured. Both lines are gone from the diff; card #25216 carries the maintainer's word verbatim and lists the three texts the rule must reconcile (SKILL.md line 255, the 红线 confidence gate, Nothing else regressed. Section 〈卡线程〉 is 16 rule lines; the twelve lines that were right in round 1 are unchanged; line 16 (「worktree 照建;仓 PR body, non-blocking: it now says 「29 insertions and 26 deletions by GitHub's count」; after round 2 GitHub counts 28 / 26. One maintainer quotation in the body still contains a model name; the trailer gate judges only the pair and AGENTS.md exempts a verbatim maintainer ruling, so no gate reds — keep it as a quotation block in the seat's record of review. ② Semver level
③ Boundary flags
Implemented-by: VERDICT: PASS Generated by Claude Code |
维护者速读改了什么: pm-dispatch 技能加了第三种派发方式 为什么改: 10-22 你在项目里定的几条规则(「此时就每张卡开新线程」「根据任务的难度来选择 effort」「还是需要你来总体调度,因为要优先派 p1」「规则类的应该进仓库」)。 风险与代价(含回滚): 纯规则文本,不碰代码和门禁;回滚就是 revert 本 PR。卡线程的分支名 席位意见: 建议落地。契约评审第一轮 FAIL 三项,第二轮在本 head 上全部消除,CI 全绿。另外两件事已经另立卡,不随本 PR:你 08:35 定的「裁定线程有把握就自己定」规则是 #25216;harness 在 PR 正文首行写 HTML 注释署名、与 os-dev.md 禁令冲突的问题是 #25220。 你要做的: 一件,不急:AGENTS.md §2 要不要写明项目线程只能推指定分支这个例外,或者给卡线程一个推 席位核对ACCEPT ·
Generated by Claude Code |
Requested by Bill · project thread
Fixes #25185
Clause-②: no
Metadata-protocol: none
What changed
Four
.claude/**files, 29 insertions and 26 deletions by GitHub's count, no code.mode:thread—SKILL.mdargs table (mode:row and thebatch:row, which now counts card threads), the claim template'sContainer & model:line,os-dev.md's "GitHub is the report's source of truth under every mode" line, and a new section 〈卡线程(mode:thread)〉 inreferences/dispatch-runbook.mdbeside themode:cloudsection. The rules it carries, each from the maintainer's words quoted on the card:priority:p1andsecuritycards as one thread per card; S-class mechanical cards stay an in-seat subagent (a thread re-clones and re-reads the skill first); a card under the disclosure ruling (record 5323310017) stays in-seat too; a card thread counts againstbatch.batchterms; seats hand it candidates at any time with priority, order file and suggested effort, and tell it when a thread hands back or its PR merges./mnt/project-files/, onedispatch-N.mdper card under the seat's folder). Claim mechanics changed after the first contract review (record 6341183860): the thread's first act is to report its designated push branch to the seat and wait; the seat writes the assignee andpm:dispatched, then posts the Claim carrying thatBranch:, in AGENTS.md's order; the thread starts only after that, posts no claim and never writes the assignee.claude/issue-N-slugremains the branch convention; a project-thread session can push only its own designated branch (measured: the session's harness names that branch and forbids any other), so the claim records that branch as the platform exception. The coordinator sets a thread's model and effort only on the maintainer's explicit word, so the seat attaches that message..claude/agentstypes did not load in a project thread (measured), so the thread readsos-dev.md; container restarts kill local background loops, so the seat waits on server-side signals.references/execution-duties.md〈派发〉 and theeffort:field in the claim template: effort is chosen per card beside the model tier, written into the claim and the order and passed explicitly, never left unset. Grading as the card proposed, unchanged by measurement: S mechanicalmedium; Mhigh(the default); L/XL,security, p1, the contract review and four-axis analysisxhigh;maxonly when the maintainer names it. The card'sContainer & model:reader (readContainerModelLine) still reads themodel:slot with the new field present; this PR's own claim (comment 6335635315) carries the new shape and passedpost-stamped.The maintainer's words, verbatim and untranslated, as the card quotes them: 「你能识别到在项目的环境下工作吗?此时就每张卡开新线程。」 · 「立一张卡,修改 skills,包括派任务时要求根据任务的难度来选择 effort」 · 「还是需要你来总体调度,因为要优先派 p1」 · 「规则类的应该进仓库」 · on the S/M boundary 「同意」. The ruling-thread rule left this PR after the first contract review; it is card #25216.
How the line ratchet was paid
check:pm-skill-ratchetholds every file here at a shrink-only ceiling. The new text needed +17 lines indispatch-runbook.mdand +2 inexecution-duties.md. The maintainer left the choice (「你自己决定 :抬上限 / 删旧内容 / 压缩」) and the spec seat preferred deletion, so no ceiling moved: both files land exactly at their ceilings (241 and 188) by deleting lines whose rule is already stated in another file of the same corpus. Reviewers, each deletion with the surviving home of its rule:dispatch-runbook.md(16 deleted, 2 merged into 1):ensure-pm-labels.sh」 → SKILL.md 〈机械守卫索引〉 names that script as the authority.check-half-states.mjsrow.state-machine.md(the hold-comment line).seat-post-protocol.md(subtree reclaim) and SKILL.md 状态模型 「在飞卡跟到 MERGED」.seat-lifecycle.md读数三.os-dev-report标记」 →os-dev.mdlines 17–18.os-dev.md〈干净收尾〉 item 1; the identity triple that follows it is kept.execution-duties.md〈收集〉 「先探活后翻 ready」.os-dev.mdDefinition of done; 「派发令只带增量」 →execution-duties.md〈派发〉.execution-duties.md「标准非协商条款 ⛔ 不抄进派发词」..claude/agents/*frontmatter 的model:」 → AGENTS.md (commit-message paragraph of Multi-agent discipline),os-dev.md285–286 and its frontmatter comment,execution-duties.md「解析顺序…以 os-dev 定义 frontmatter 注释为权威」.check:skill-frame-sync全树扫;os-dev 定义没带就停下索取」 →os-dev.md356–357 and SKILL.md 〈机械守卫索引〉check:skill-frame-syncrow.execution-duties.md(2 deleted):os-dev.mdrule 6 (the dev verifies every premise regardless), and the same section's 「标准非协商条款 ⛔ 不抄进派发词」 says not to restate it in the order.SendMessagenot-reachable 是设计非故障,⛔ 不复测」 →dispatch-runbook.md〈云卡四课〉 「roster 不可达与SendMessage同裁,ListAgents同列不到,⛔ 不复测」, kept.Every line added or edited is at most 120 bytes (the ratchet's max-line rule); the four-axis frame was not touched (
check:skill-frame-syncandcheck:skill-frame-freshnessgreen).Landing and the claim's model line
.claude/**is Tier S under AGENTS.md Prime Directive 14, not a human merge as the card's first sentence says: the owning seat lands this PR after a## Contract reviewrecord for its head withServed-tier: CONTRACT_REVIEW_TIERand a PASS verdict, plus all-green checks. The PR stays a draft until then.Container & model:line saysmodel: default;dispatch-gates --tierprints MANDATORYCONTRACT_REVIEW_TIERforSKILL.mdandos-dev.md. The seat corrected this mid-card: the maintainer switched this thread to that tier (「切换到 fable」, 08:08Z) and the whole diff was re-read at it before this PR opened; that re-read found and fixed one contradiction in themode:row (S+M ⇒ subagent against M+ ⇒ thread; now 「席位是项目线程时 M 及以上、p1、security一律thread」).Open questions for the contract review (settled in round 2)
Claim:」: settled. The seat posts the claim and writes the assignee; the thread posts neither. This card's own round-1 claim and assignee were written by the thread under the round-1 order, before this rule existed; they stand as the record.pm:queuelabel and priority. The coordinator's queue is a view derived from those labels and rebuildable from GitHub at any time; the order files are inputs, not state. Once a thread opens, the card carries assignee,pm:dispatchedand the Claim like any other dispatch.needs_decisionfork goes to a separate ruling thread at the contract-review tier, which rules when confident and sends the maintainer a decision card otherwise (maintainer's word 2026-10-22) #25216 carries the maintainer's word and has to be reconciled with 「总监席是唯一裁决者」 there.claude/issue-N-slugstays the convention; the designated thread branch is recorded as the measured platform exception. The Duplicate Fix Guard is advisory. Whether AGENTS.md §2 itself should name the exception is a Tier H question the seat has taken to the maintainer; this PR touches no Tier H file.Gates
Round 2, head e704856:
dispatch-gates --commands --repo objectstack-ai/objectstackderived the same 22 families, each run with its exit code captured before any pipe, all 22 exit 0;--ran22/22, 0 NOT-MEASURED.check:skill-frame-freshnessandcheck:pm-skill-ratchetexit 0 (dispatch-runbook.md240/241,execution-duties.md188/188,SKILL.md319/319,os-dev.md404/404). Round 1 at b301b37: the same 22, all 0;check:doc-formula-expressionsfirst exited 3 (unbuilt@objectstack/lint), rebuilt under the verify lock and re-run to 0. CI's remaining families are the PR's check-runs. No published package moved (.claude/**is a fast-track non-published path), soskip-changesetrides this PR's create.维护者速读(草稿)
改了什么: pm-dispatch 技能加了第三种派发后端
mode:thread:席位在项目线程里跑时,M 及以上、p1、security 的卡每张开一个线程,由 coordinator 跨席位按 p1 优先统一调度,总并发 = 各席 batch 之和;S 级机械小改仍用席内子 agent。派单按难度选 effort(S medium、M high、L/XL/p1/security/契约复核/四轴 xhigh、max 只凭你点名)。认领与 assignee 仍由席位写,线程先报分支再开工。行数上限没动,用删掉 18 条已在别处写明的旧规则抵账。为什么改: 你 10-22 在项目里定的这几条规则(「规则类的应该进仓库」)。
风险与代价(含回滚): 纯规则文本,不碰代码与门禁;回滚即 revert 本 PR。AGENTS.md §2 的分支约定是否要写明项目线程的例外,属 H 档,席位已另报给你。
席位意见:
你要做的: 无;
.claude/**是 Tier S,席位做完契约复核后自行落地。Acceptance notes
Thread-read: none (no comments yet);post-stampedrefuses that spelling (H50 compares it for equality against one id ornone). The seat has already corrected its template; noted here, not filed.os-dev-report.os-dev.md〈干净收尾〉 forbids HTML comments in GitHub text. Measured on an earlier card thread's PR, the relay read-back keeps it byte for byte. Reported as a deviation, not hidden.Generated by Claude Code