Skip to content

feat(agents): pm-dispatch 首轮实跑经验回写 — 认领协议、跨仓查重、决策落原 issue、开发模型策略 - #4554

Merged
os-zhuang merged 2 commits into
mainfrom
claude/pm-agent-task-dispatch-r4cepu
Aug 2, 2026
Merged

feat(agents): pm-dispatch 首轮实跑经验回写 — 认领协议、跨仓查重、决策落原 issue、开发模型策略#4554
os-zhuang merged 2 commits into
mainfrom
claude/pm-agent-task-dispatch-r4cepu

Conversation

@os-zhuang

Copy link
Copy Markdown
Contributor

目的

/pm-dispatch 第一轮真实派发(#4551#4518 已派发;#4515#4525 已转决策)暴露的四处机制空白,连同维护者的三条反馈,回写进 skill。

内容(均为 .claude/skills/pm-dispatch/SKILL.md)

1. 认领协议(step 4 重写)。 所有 agent 共用一个 GitHub 账号,assignee 只能表达「有人认领」而非「谁认领」:

  • 固定格式认领评论(轮次 + 分支名)补上身份,分支名是后续一切产物的锚点;
  • assign 幂等导致的竞态用「回读评论区、先评论者胜」解决;
  • 要求开发 agent 尽早推分支,收窄「已认领但不可见」的盲区;
  • 僵尸认领回收:超 24h 且承诺的分支不存在、无 PR → 先问后放回队列;有活分支的绝不回收。

2. 分诊时跨仓查重(step 2 新增)。 派发前顺着 issue 的跨仓引用 + 关键词搜索另两个仓库找「影子」:影子已认领/有 PR → 不派发写 Blocked-by:;影子未认领 → 先收敛成单一调度入口再入队;影子已完成 → 复核原 issue 是否过时。主 backlog 是唯一调度权威。

3. 决策落在原 issue 上(step 8 重写,回应维护者「[决策] issue 会不会越来越多」)。 默认把两轴分析评论到所属 issue 并打 needs-user-decision——该标签就是维护者的收件箱,拍板后摘标即回队列,不产生记账 issue;仅当决策没有天然归属(横跨多 issue / 凭空冒出)才单独建 [决策] issue。

4. 开发模型策略(step 5,维护者指定)。 派发开发 agent 一律传 model: "opus";PM 会话保持更强的编排模型,把判断力花在分诊、复核与决策框架上。

备注

🤖 Generated with Claude Code

https://claude.ai/code/session_012C2cd7tL8QDoZ2QKN3djJ5


Generated by Claude Code

…o dedup, escalate-on-issue, dev model policy

Four mechanics hardened from the first live dispatch round:

- Claim protocol: shared GitHub identity means assignee alone cannot say
  WHICH agent claimed — a fixed-shape claim comment (round + branch name)
  carries identity, a comment read-back settles races (first comment
  wins), early branch push closes the claimed-but-invisible gap, and
  stale claims (24h, no branch, no PR) are reclaimed after inquiry.
- Cross-repo dedup at triage: follow cross-references and keyword-search
  sibling repos for an issue's shadow; claimed shadow blocks dispatch,
  unclaimed shadow converges to one entry first, done shadow triggers a
  staleness check. The main backlog stays the only scheduling authority.
- Escalation lands ON the issue it belongs to (analysis comment +
  needs-user-decision label as the maintainer's inbox); a separate
  [decision] issue only when no natural anchor exists — decision cards
  no longer accumulate.
- Dev dispatches pass model: opus; the PM session keeps the stronger
  orchestration model (maintainer policy).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012C2cd7tL8QDoZ2QKN3djJ5
@vercel

vercel Bot commented Aug 2, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
objectstack Ignored Ignored Aug 2, 2026 3:06am

Request Review

@github-actions github-actions Bot added documentation Improvements or additions to documentation tooling size/s labels Aug 2, 2026
…s land via the merge queue

Maintainer policy: once the PM's review verdict is ACCEPT and every CI
check is green, the PM marks the dev-agent PR ready and adds it to the
merge queue (the repo's sanctioned path — the queue lands it only if the
rebuild against current main is green). Scope-limited: dev-agent PRs
dispatched by this loop only; the PM's own tooling PRs stay with the
maintainer; no red, unreviewed, or queue-bypassing merges.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012C2cd7tL8QDoZ2QKN3djJ5
@os-zhuang
os-zhuang marked this pull request as ready for review August 2, 2026 04:01
@os-zhuang
os-zhuang added this pull request to the merge queue Aug 2, 2026
Merged via the queue into main with commit 9503465 Aug 2, 2026
17 checks passed
@os-zhuang
os-zhuang deleted the claude/pm-agent-task-dispatch-r4cepu branch August 2, 2026 07:52
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 tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants