Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude/skills/pm-dispatch/references/triage-duties.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
- UTC 3 倍数时的轮次记录报 24h 流量:卡新建/关闭/净增,合并 PR 数,open p1,引契约复核新卡数。
- 析取 ①全裸(无 `pm:*`/`needs-user-decision`/`domain:*`);② `pm:queue` 无 `domain:*`(仅多车道仓);
- ③ `domain:*` 无 pm-state;④ `pm:queue`+`domain:*` 无 `priority:*`;②③④ 只取 `updated_at` 早于 ~2min。
- 排除 `tracking`、`status:parked`、全部 `pm:seat` 贴、`qa-run` 记录。
- 排除 `tracking`、`status:parked`、全部 `pm:seat` 贴、`qa-run` 与 `eval-run` 记录。
- 析取 ⑤:窗内新建且 `pm:queue`/`priority:*` 与建卡同分钟,照未分诊首触;⛔ 不凭 actor。
- 首触定级与五析取 sweep 每 fire 跑到清空,先于旧卡重验:⛔ 无每轮预算、无逐卡豁免评论。
- 五析取由 `node scripts/pm/first-touch-sweep.mjs --since=ISO` 照原文全量跑,⛔ 不手敲窄化或截断。
Expand Down
79 changes: 52 additions & 27 deletions .claude/skills/scenario-eval/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,51 +26,67 @@ metadata:
## 0. 环境 —— 照 README〈Running the cards in a Claude Code cloud session〉

- 订阅登录(`claude auth status` 答 `oauth_token`),`ANTHROPIC_API_KEY` / `ANTHROPIC_AUTH_TOKEN` 都 unset;
⛔ 不用 API 计费的模型。权限模式非 Auto。前台命令有时限,一轮里每条 runner 命令都放后台。
⛔ 不用 API 计费的模型。权限模式非 Auto。前台命令有时限,一轮里每条 runner 命令都放后
台。
- 先建依赖:`pnpm install && pnpm --filter '@objectstack/scenarios^...' build`;
没建就跑会停在 `ERR_MODULE_NOT_FOUND`,那是环境,不是读数。
- 记下 `claude --version`:effort 档位表随 CLI 版本变,记录的环境行要带它。
- runner 的 sha 整轮钉死:轮中 ⛔ 不拉 `main`。评分器改了,分数就不可比;要用新评分器,走 §4 回放。
- runner 的 sha 整轮钉死:轮中 ⛔ 不拉 `main`。评分器改了,分数就不可比;要用新评分器,走 §4
回放。

## 1. 规划这一轮

- **control 卡每轮必跑**:`grep -l '"tier": "control"' docs/qa/scenarios/*.json` 读出名单,⛔ 不凭记忆列。
三张小卡可同一条命令(`--only A,B,C`);首轮实测一次重复 haiku 约 45 分钟、opus low 约 25 分钟。
三张小卡可同一条命令(`--only A,B,C`);首轮实测一次重复 haiku 约 45 分钟、opus low 约 25 分
钟。
- **starter 卡只跑 scratch**(`--modes scratch`),一卡一条命令(`--only ID`):一条后台命令限 2 小时,
starter 的搭建就要 20–30 分钟;同一容器至多两条并行,各自起各自的端口(README 原文)。
- `template` 模式要一份已验证的构建(`--template F`),不进例行;本轮的问题点名它才跑。
- **包来源**:评测量的是客户拿到的东西 —— `--packages published`(默认),并用
`--create-version V` 把整轮所有配置与重复钉在同一个发布版本上;`workspace` 是 QA 席测未发布波的用法。
- 规划写成一张表再动手:卡 × 配置 × 重复 → 命令条数 × 预计墙钟;超出 2 小时的一条拆开。
`--create-version V` 把整轮所有配置与重复钉在同一个发布版本上;`workspace` 是 QA 席测未发布
波的用法。
- 规划写成一张表再动手:卡 × 配置 × 重复 → 命令条数 × 预计墙钟;超出 2 小时的一条拆
开。

## 2. 配置

- **跟踪配置** = 托管默认(写本技能时:`--model haiku --effort medium`);**参照配置** = `--model opus --effort low`。
- **跟踪配置** = 托管默认(写本技能时:`--model haiku --effort medium`);**参照配置** =
`--model opus --effort low`。
托管默认变了以座位贴为准,本技能 ⛔ 不跟着改值。其它配置只在本轮问题需要时加。
- 每条命令**显式**写 `--model` 与 `--effort`。⛔ 不用 CLI 默认模型不点名(登录不同、默认不同,还会悄悄变);
- 每条命令**显式**写 `--model` 与 `--effort`。⛔ 不用 CLI 默认模型不点名(登录不同、默认不
同,还会悄悄变);
⛔ 不靠 `CLAUDE_CODE_EFFORT_LEVEL` 环境变量:它只是 `--effort` 缺省时的回退,命令行上看不见。
- `--author-model` / `--ask-model`(及两个 effort 对应项)只在本轮要拆开搭建与问答时用,记录里写明。
- 读计分卡的 `Run · model` 与 author 行核对**实际服务的模型**:出现 `⚠ asked for` / `not <model>` 的
那次运行不属于该配置,单列说明,⛔ 不并入均值。effort 只有请求值,没有服务值可核(README)。
- `--author-model` / `--ask-model`(及两个 effort 对应项)只在本轮要拆开搭建与问答时用,记录里写
明。
- 读计分卡的 `Run · model` 与 author 行核对**实际服务的模型**:出现 `⚠ asked for` / `not <model>`
的
那次运行不属于该配置,单列说明,⛔ 不并入均值。effort 只有请求值,没有服务值可
核(README)。

## 3. 重复与噪声

- **要据此定模型或 effort 的,每配置 5 次重复。** 单次运行的问数在 control 三卡 58 题上会摆动约 ±4 题:
- **要据此定模型或 effort 的,每配置 5 次重复。** 单次运行的问数在 control 三卡 58 题上会摆
动约 ±4 题:
单次一轮只报**趋势**,⛔ 不排名次,记录的 Reading 照此措辞。
- 结果按配置报**均值 + 最小–最大**,再按卡把 5 次合并报一张表。汇总脚本 runner 里还没有:
- 结果按配置报**均值 + 最小–最大**,再按卡把 5 次合并报一张表。汇总脚本 runner 里还没
有:
手算或本席脚本都行,记录写明算法(分子分母合并,还是逐次百分比再平均)。
- 只和上一张记录的**同一配置、同一组卡**比;发布版本或 runner sha 变了,Reading 点名这一变量。
- 只和上一张记录的**同一配置、同一组卡**比;发布版本或 runner sha 变了,Reading 点名这一变
量。
- 每次重复都进记录:没跑完的照实写 `not measured` 与原因(README 的超时、`error_max_turns` 等),
⛔ 不静默重跑顶替,⛔ 不剔除离群值;重跑了就写重跑了。

## 4. 录制与回放

- **每条命令都录**:`--record FILE`,一条命令一个文件,路径带配置与第几次重复。
pnpm 在包目录里跑脚本,`--out` / `--record` 一律传绝对路径。
- **回放** `--driver recorded:FILE`:不调模型、不花额度,重评一轮旧运行。它把每个回合录下的写调用按序
重发给新起的应用,所以 Build、问数、写操作三项都能重评;一回合重发不成的记 `not measured` 并点名
- **回放** `--driver recorded:FILE`:不调模型、不花额度,重评一轮旧运行。它把每个回合录下的写
调用按序
重发给新起的应用,所以 Build、问数、写操作三项都能重评;一回合重发不成的记
`not measured` 并点名
那次调用,⛔ 不判 fail。回放拒收模型与 effort 参数,记录沿用录制时的驱动(`replayOf`)。
- 回放重评同样立一张 `eval-run` 记录:Scope 写明回放的是哪张记录的录音、评分器在哪个 sha;旧记录不改。
- 回放重评同样立一张 `eval-run` 记录:Scope 写明回放的是哪张记录的录音、评分器在哪个
sha;旧记录不改。

```bash
# --only 的三张 control 卡是写本技能时的名单;跑前照 §1 从卡文件重读
Expand All @@ -86,30 +102,39 @@ nohup pnpm --filter @objectstack/scenarios run-scenarios \

## 5. 记录 —— 一轮一张 `eval-run` issue

维护者令(原话):"objectstack 公开仓,像 qa-run"。据此场景卡评测记录立在本仓、带全分(问数基线 ② 的
数字仍不对外,见 `lanes/eval.md`)。运行产物 ⛔ 不进仓库树:run 记录 JSON、录音、日志留在 git-ignore 的默认
维护者令(原话):"objectstack 公开仓,像 qa-run"。据此场景卡评测记录立在本仓、带全分(问数基
线 ② 的
数字仍不对外,见 `lanes/eval.md`)。运行产物 ⛔ 不进仓库树:run 记录 JSON、录音、日志留在
git-ignore 的默认
`--out` 目录或本席的项目文件里;issue 就是报告,纯文本,⛔ 不放图。

- **写入门**:立单、评论、关单全走 pm-dispatch 写入门,照 `checklist-test` §4 那一段;⛔ MCP `issue_write`。
- **写入门**:立单、评论、关单全走 pm-dispatch 写入门,照 `checklist-test` §4 那一段;⛔ MCP
`issue_write`。
- **标题**:`Eval run · SCOPE × N configs × R reps · SHA8 · DATE`,如
`Eval run · control cards × 3 model configs × 5 reps · 3be13473 · 2026-11-15`;SHA8 是 runner 的 commit。
- **标签**:只带 `eval-run`;⛔ 不挂 priority / `domain:*` / `pm:*`。记录不是可派发单元,整个生命周期都不补挂。
- **标签**:只带 `eval-run`;⛔ 不挂 priority / `domain:*` / `pm:*`。记录不是可派发单元,整个生命周
期都不补挂。
- **正文**,按此顺序,英文:
- `## Environment` —— runner 仓与 sha;包来源行(`packages: published 18.4.0`)与模式;驱动与登录
(`oauth_token`,无 API key);`claude --version`;每个配置实际服务的模型与请求的 effort;花费是 CLI
报的名义数,未计费。
- `## Scope` —— 卡 id 与 tier、首轮加 iterate;配置清单;每配置重复次数;每次重复的题数、写操作数、
- `## Scope` —— 卡 id 与 tier、首轮加 iterate;配置清单;每配置重复次数;每次重复的题数、写
操作数、
Build 检查数;每条命令的退出码;`not measured` 的半边逐个点名原因(⛔ 不计入分母)。
- `## Results` —— 一行一个配置:Build · 问数 · 写操作(均值,括号最小–最大)· 每次重复的泄露标记**数**
· 搭建分钟 · 问答分钟 · 每次重复名义花费;再一张按卡合并表。泄露只写数,⛔ 不写内容。
- `## Results` —— 一行一个配置:Build · 问数 · 写操作(均值,括号最小–最大)· 每次重复的
泄露标记**数**
· 搭建分钟 · 问答分钟 · 每次重复名义花费;再一张按卡合并表。泄露只写数,⛔ 不写内
容。
- `## Reading` —— 编号结论,每条按 §3 的噪声规则措辞,并与上一张记录比。
- `## Findings filed from this run` —— 每条发现一行,写去向(§6);无则写 `none`。安全线索那一行只写
- `## Findings filed from this run` —— 每条发现一行,写去向(§6);无则写 `none`。安全线索那一行
只写
`security-findings.md` §4 的固定一句,别无其它。
- `## Records` —— 产物放在哪(路径),说明留在仓库树外、可回放。
- **收口**:§6 的每条发现都有了去向(卡号或已报的私密渠道)即由本席关 `completed`;
⛔ 不为等修复开着,修复的回测进下一轮。上一轮的记录不 supersede:每张都是它那个 sha 上的一次测量。
- **分诊扫描还不认 `eval-run`**(排除名单只列 `qa-run`):在它补进之前,记录在立单的同一轮关闭;
当轮关不了,就告诉分诊席这是一张记录、不是待分诊的卡。
⛔ 不为等修复开着,修复的回测进下一轮。上一轮的记录不 supersede:每张都是它那个 sha 上
的一次测量。
- **分诊扫描认得 `eval-run`**(与 `qa-run` 同列排除名单):记录开着等发现去向时不会被要求首
触,照上条收口关闭。
- 记录立好后给维护者一句话:链接 + 两行 Reading。

## 6. 发现 —— 各归各主
Expand Down
12 changes: 7 additions & 5 deletions scripts/pm/check-half-states.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -3807,7 +3807,7 @@ export const TRACKING_ANCHOR_LABEL = 'tracking';
* sweep's own protocol text (SKILL.md, Backlog sweep): flagging them would
* report the protocol's design as a defect.
*/
export const H13_EXEMPT_LABELS = [TRACKING_ANCHOR_LABEL, 'status:parked', 'qa-run'];
export const H13_EXEMPT_LABELS = [TRACKING_ANCHOR_LABEL, 'status:parked', 'qa-run', 'eval-run'];

/**
* H13 threshold — "one sweep cycle": the triage Routine fires HOURLY and its
Expand Down Expand Up @@ -8181,7 +8181,7 @@ export const H74_POPULATION_LABELS = Object.freeze(['pm:queue', 'pm:blocked']);
* `pm:queue,tooling`, identity label `platform-checklist-watchdog`). Read by
* its identity label the way `queue-flake-anchor` is, because the identity
* label is the machine's and is never graded off, while the title is one
* template's wording. Tracking anchors, epics, seat posts, QA runs, parked
* template's wording. Tracking anchors, epics, seat posts, QA and eval runs, parked
* cards and both machine anchors are never first-touched the way a lane card
* is, so their silence is the design. Census 2026-11-03 of every
* `.github/workflows/**` template that files a card: only this one applies
Expand All @@ -8194,6 +8194,7 @@ export const H74_EXEMPT_LABELS = Object.freeze([
'pm:epic',
'pm:seat',
'qa-run',
'eval-run',
'status:parked',
'queue-flake-anchor',
'platform-checklist-watchdog',
Expand Down Expand Up @@ -8356,7 +8357,7 @@ export function h74QueuedWithoutTriageAudit(issue, commentBodies, parent) {
'audit` on the triage mailbox in the same round (`record-recognisers.mjs --mailbox-keys` prints the shape) ' +
'— ⛔ never a silent wait, and never a report to the maintainer in the mailbox\'s place. Report-only: ⛔ ' +
'never a label, comment or body written from this script. Exempt by design: `tracking`, `pm:epic`, ' +
'`pm:seat`, `qa-run`, `status:parked`, `queue-flake-anchor` and `platform-checklist-watchdog` carriers; a non-fleet card (human ' +
'`pm:seat`, `qa-run`, `eval-run`, `status:parked`, `queue-flake-anchor` and `platform-checklist-watchdog` carriers; a non-fleet card (human ' +
'author, no seat signature); a main-red anchor card; a sub-issue inheriting its parent\'s domain or grade.'
);
}
Expand Down Expand Up @@ -27217,6 +27218,7 @@ async function selfTest() {
t('H13: status:parked exemption (its normal shape IS this one)', h13DomainWithoutPmState(domainCard(['domain:services', 'status:parked'], hoursAgo(200)), NOW), null);
t('H13: tracking exemption', h13DomainWithoutPmState(domainCard(['domain:devx', 'tracking'], hoursAgo(200)), NOW), null);
t('H13: qa-run exemption', h13DomainWithoutPmState(domainCard(['domain:cli', 'qa-run'], hoursAgo(200)), NOW), null);
t('H13: eval-run exemption', h13DomainWithoutPmState(domainCard(['domain:cli', 'eval-run'], hoursAgo(200)), NOW), null);
t('H13: no domain label is out of scope however bare', h13DomainWithoutPmState(domainCard(['bug'], hoursAgo(200)), NOW), null);
t('H13: fresh half-state is intake latency, not a finding', h13DomainWithoutPmState(domainCard(['domain:engine-core'], hoursAgo(1)), NOW), null);
t('H13: exactly at the threshold -> clean (strictly beyond fires)', h13DomainWithoutPmState(domainCard(['domain:engine-core'], hoursAgo(DOMAIN_HALF_STATE_STALE_HOURS)), NOW), null);
Expand Down Expand Up @@ -29030,7 +29032,7 @@ async function selfTest() {
b(BATTERY74, 'H74 thread states: UNREADABLE fires UNJUDGED, never clean', row74(null).startsWith(UNJUDGED_MARKER) && isUnjudgedFinding(row74(null)) && row74(null).includes('not empty'), true);
b(BATTERY74, 'H74 population: `pm:blocked` is spoken about too, and the row names it', row74([], { labels: [{ name: 'pm:blocked' }, { name: 'domain:spec' }] }).startsWith('`pm:blocked` with'), true);
b(BATTERY74, '⛔ H74 population: a `pm:dispatched` card is out of scope (its claim is H2\'s subject)', h74([], { labels: [{ name: 'pm:dispatched' }, { name: 'domain:spec' }] }), null);
for (const exempt of ['tracking', 'pm:epic', 'pm:seat', 'qa-run', 'status:parked', 'queue-flake-anchor', 'platform-checklist-watchdog']) {
for (const exempt of ['tracking', 'pm:epic', 'pm:seat', 'qa-run', 'eval-run', 'status:parked', 'queue-flake-anchor', 'platform-checklist-watchdog']) {
b(BATTERY74, `⛔ H74 exempt: a \`${exempt}\` carrier is silent`, h74([], { labels: [{ name: 'pm:queue' }, { name: exempt }] }), null);
}
b(BATTERY74, 'H74 exempt control: the same card with an unrelated label beside `pm:queue` still fires', typeof h74([], { labels: [{ name: 'pm:queue' }, { name: 'tooling' }] }), 'string');
Expand Down Expand Up @@ -29062,7 +29064,7 @@ async function selfTest() {
b(BATTERY74, 'H74 inherit reader: a null, undefined or sentinel parent inherits nothing, never a crash', [h74InheritsFromParent(card74(), null), h74InheritsFromParent(card74(), undefined), h74InheritsFromParent(card74(), H74_PARENT_UNREADABLE), h74InheritsFromParent(card74(), { labels: undefined })].some(Boolean), false);
b(BATTERY74, '⛔ H74 population: a closed card, a PR row, an unreadable `labels` and a missing row are all silent, none a crash', [h74([], { state: 'closed' }), h74([], { pull_request: {} }), h74([], { labels: undefined }), h74QueuedWithoutTriageAudit(undefined, [])].every((v) => v === null), true);
b(BATTERY74, 'H74 population: a null body is no crash and no record — the card still fires on an empty thread', typeof h74([], { body: null }), 'string');
b(BATTERY74, 'H74 exempt list: the constant carries exactly the filing card\'s six labels plus the watchdog anchor\'s identity label', [...H74_EXEMPT_LABELS].sort().join(), ['platform-checklist-watchdog', 'pm:epic', 'pm:seat', 'qa-run', 'queue-flake-anchor', 'status:parked', 'tracking'].join());
b(BATTERY74, 'H74 exempt list: the constant carries exactly the filing card\'s six labels plus the watchdog anchor\'s identity label and the eval record\'s', [...H74_EXEMPT_LABELS].sort().join(), ['eval-run', 'platform-checklist-watchdog', 'pm:epic', 'pm:seat', 'qa-run', 'queue-flake-anchor', 'status:parked', 'tracking'].join());
// The watchdog anchor as fleet-patrols.yml files it: App author, `pm:queue,tooling` routing, identity label. Its
// title does NOT open the main-red regex (no colon before `red on main`), so the identity label is what exempts it.
const WATCHDOG74 = { title: 'check:platform-checklist is red on main', user: APP74, body: 'os-platform-checklist-watchdog\n\nThe gate is red on main.' };
Expand Down
Loading
Loading