Skip to content

Commit 21e36a2

Browse files
claude[bot]claude
andauthored
docs(pm-dispatch): read the verify-lock queue depth before each dispatch and hold at depth ≥ 2 (#14944 Q1 B) (#16271)
* docs(pm-dispatch): read the verify-lock queue depth before each dispatch and hold at depth >= 2 The dispatch cap counts cards in flight; the container-wide heavy-verify lock is one unit wide, and the measured exit-99 (NOT MEASURED) rate is a function of arrival queue depth alone: 1% / 23% / 36% / 56% at depth 1 / 2 / 3 / 4. The PM loop now reads `scripts/pm/os-verify-lock.sh --status` before the N-th dispatch and waits while the arrival depth (`queue N:` lines + the dev's own run; holder and parked slots not counted) would reach LOCK_DEPTH_HOLD = 2. The nominal `batch` cap is unchanged; `priority:p0` may still exceed `batch` but does not cross the depth hold. Both places carry the rule (SKILL.md and references/core-rules.md). The four added lines are paid inside the same file by four same-topic merges, so the line ratchet stays at its ceilings. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8 * docs(pm-dispatch): re-fold the depth-hold rules onto main after #16339 The merge of origin/main brought SKILL.md to 813 lines against a ceiling of 811: both sides were line-neutral against the merge base, but the folds this branch used to pay for its four depth-hold lines landed in regions main had re-folded independently, so the resolution kept both. Pay the +2 with two more same-topic folds inside the same file — no rule removed, no ceiling raised, no cross-file move: - the two seat invariants "循环必须能从全新会话恢复" and "PM 不写文件、不写代码" join on one line (112 bytes); the separator before 唯一例外 drops from ; to , so the exception still reads as the no-writing rule's, not the recovery one's. - the two conditional-clause items 拒收用例 and 过滤/谓词语义 join on one line (119 bytes) inside the enumeration they already belong to. Ratchet reads SKILL.md 811/811 headroom 0, widest table row 342 (pin 342), core-rules.md 150/150. Every prose line stays within the 120-byte budget. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TezFG8ZMrNH6n5VTNpPpdH --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent abb140c commit 21e36a2

2 files changed

Lines changed: 11 additions & 11 deletions

File tree

.claude/skills/pm-dispatch/SKILL.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
114114
| `target:<major>` | 发版阻塞:每个 backlog 恰好一个生产者 |
115115
| `pm:epic`(父单或 sub-issue) | 已由 epic PM 保留;其它 PM 永不取;⛔ 永不与 `pm:queue` 同挂 |
116116
| `pm:seat` | 座位登记贴:协议载体,不是待分诊的工作 |
117-
| `priority:p0` | 插队:可超 `batch`、破轮次立即派发;⛔ 不豁免同文件串行与认领协议 |
117+
| `priority:p0` | 插队:可超 `batch`、破轮次立即派发;⛔ 不豁免同文件串行、深度等待与认领协议 |
118118
| open PR 引用该单 | 已实现,复核中 |
119119
| merged PR 带 `Fixes #n` | 完成(GitHub 关单) |
120120

@@ -282,8 +282,7 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
282282
- 原则错/缺 → skills 席专题;可机械化项 → 门禁/脚本卡,⛔ 不是散文。
283283
- 平台事实变化 → references 事实表改一行。
284284
- 三类以 `finding` 入 skills 车道由该席分诊;三类之外默认关 not planned。
285-
- 经验教训散文不再入技能文本。
286-
- 交接按收尾清单逐步走完,并 `list_triggers` 清点自设定时器。
285+
- 经验教训散文不再入技能文本;交接按收尾清单逐步走完,并 `list_triggers` 清点自设定时器。
287286
- 归档自己派出的会话是不可移交的义务。
288287
- 四段模板、状态词表、接管/退场收尾清单细则见 `references/seat-post-protocol.md`
289288
- epic 委托不入座位贴体系;`packages/spec` 恒归 spec 座位。
@@ -436,6 +435,10 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
436435
- 工作项面:卡片与分诊评论列的每条工作项逐条对树核验是否仍未完成,⛔ 不对卡核验。
437436
- 每条工作项写进派发令时都是 dev 首先证伪的前提。
438437
- 并行度以 `batch` 封顶;同批独立性按文件面不相交判,⛔ 不按包;`priority:p0` 可超 `batch`
438+
- 第 N 单派发前读 `scripts/pm/os-verify-lock.sh --status`:到达深度 ≥ `LOCK_DEPTH_HOLD`(= 2)即等。
439+
- 到达深度 = `queue N:` 行数 + 1(待派 dev 的运行算作到达);`state:` holder 与 `parked` 行不计。
440+
- 有效上限是锁宽的函数,⛔ 不是第二个 `batch`;`priority:p0` 可超 `batch`,⛔ 不越过深度等待。
441+
- 阈值出处是深度表:深度 1/2/3/4 的 exit 99 率 1%/23%/36%/56%;等待不填槽,读数带 UTC 写进认领。
439442
- 同文件单跨轮硬串行;延后不是搁置,被延后那一刻就把已知的坑记到该 issue 上。
440443
- 家族派发是范围澄清不是豁免:一个 dev 有意覆盖 N 张同区域已裁卡,可折叠为一次派发。
441444
- 折叠准入五门全过才可折:① 同缺陷形态同修法(⛔ 不是同关键词/同子系统)。
@@ -521,8 +524,7 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
521524
- 契约复审档留给裁决/复审子代理、skills 席与条款②工作。
522525
- 降档出口两条:额度耗尽豁免,与主动预降(余量吃紧可预先降档)。
523526
- 额度耗尽豁免仅当契约复审档实测不可用才落默认判断档,⛔ 不再往下。
524-
- 降档的档位与理由记入认领评论 Container & model 行。
525-
- 档位逐次派发显式传参,永不省略。
527+
- 降档的档位与理由记入认领评论 Container & model 行;档位逐次派发显式传参,永不省略。
526528
- 解析顺序、pin 语义与允许名单回退陷阱以 os-dev 定义 frontmatter 注释为权威。
527529
- 分诊 suggestion 行是输入不是决定,不采纳给理由。
528530
- 派发词 ⛔ 默认不整段粘贴 issue 正文:让 dev 自己读全文与全部评论并自查正文完整性。
@@ -550,8 +552,7 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
550552
- 被在飞重叠完全覆盖就停下回报,⛔ 不硬造 diff。
551553
- 翻转公开语义的裁决随卡带全仓 pin 清扫,两句缺一不可,原文见 runbook。
552554
- 条件性标准条款命中判据才抄:多实现面 ⇒ 共享一致性覆盖。
553-
- 拒收用例 ⇒ `code`+`status` 最低断言。
554-
- 过滤/谓词语义 ⇒ 编译面清单逐面申报,⛔ 静默略过。
555+
- 拒收用例 ⇒ `code`+`status` 最低断言;过滤/谓词语义 ⇒ 编译面清单逐面申报,⛔ 静默略过。
555556
- 前提先行写明:issue 正文是线索不是规格。
556557
- 资源与后端:S 级机械 + M ⇒ `mode:subagent`;S 级但不机械(判断面在设计不在门禁)按 M 待遇。
557558
- `mode:cloud` 只保留给 L/XL、必须活过 PM 会话的工作、浏览器/dogfood 验证。
@@ -701,8 +702,7 @@ PM 的工作是循环:选卡 → 认领 → 派发 → 收集 → 复核 → 报
701702
- 权威的墙信号是失败本身:撞墙报文里的重置时刻在那一刻可得、事前查不到,记下来。
702703
- 跨墙定时器:拿到重置时刻 ⇒ 一发定点(reset + 缓冲)优先。
703704
- 没有重置时刻 ⇒ 挂每小时 cron Routine,⛔ 不用 send_later 链。
704-
- 第一枪成功的 fire 跑恢复后删除 cron。
705-
- fired 文本照定时器写法纪律。
705+
- 第一枪成功的 fire 跑恢复后删除 cron;fired 文本照定时器写法纪律。
706706
- 恢复 playbook 链的是既有规则:逐个探在飞云卡 → 直接验收兜底或 transcript 复活。
707707
- 随后重挂常规巡检 → 照常跑轮。
708708

.claude/skills/pm-dispatch/references/core-rules.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
- 受管面由维护者人工合并且合并即审核记录,⛔ 席位永不以任一账号对受管面 PR 批准。
99
- ⛔ 永不代维护者回答产品或架构问题,唯一例外是已裁的代裁车道。
1010
- ⛔ 永不派发 assignee 属于别人的 issue,⛔ 永不派发带决策标签的 issue。
11-
- 并行度以 `batch` 封顶,同批按构造文件面不相交。
11+
- 并行度以 `batch` 封顶,验证锁到达深度 ≥ `LOCK_DEPTH_HOLD`(2)即等;同批按构造文件面不相交。
1212
## 入口与角色
1313
- 座位角色由 `/pm-dispatch` 参数认定;无角色参数按执行姿态跑,车道由座位贴认定。
1414
- 开轮第一个动作是一次最便宜的车道盘点查询,⛔ 在它之前不读任何长文本。
@@ -35,7 +35,7 @@
3535
- `pm:blocked` 配正文行 `Blocked-by:`,工已完而卡在门禁的同用此态并写 `Unlock-action:` 行。
3636
- `pm:awaiting-maintainer` 只剩站外人工动作;`pm:blocking` 是反向索引推导的缓存 ⛔ 不手工挂。
3737
- `pm:retriage` 并存 ⛔ 不摘原标且跳过派发;`finding` 恒等于待首次定级、定级即离标。
38-
- 插队标签可超 `batch` 立即派发,⛔ 不豁免同文件串行与认领协议
38+
- 插队标签可超 `batch` 立即派发,⛔ 不豁免同文件串行、深度等待与认领协议
3939
- 五个 pm 状态标签加 `needs-user-decision` 共六态互斥,转换恒一笔 replace,队列卡逾三天欠转换。
4040
- 关闭即在同一笔摘掉 pm 状态标;状态变更不过夜,半状态在结束会话前补齐或回滚。
4141
- 等待别的座位也是状态、写在卡上才存在;代他人指令的关闭须带指令、原话与出处三件。

0 commit comments

Comments
 (0)