Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Add copy buttons to all
 blocks\n(function() {\n function addCopyButtons() {\n document.querySelectorAll('pre code').forEach(function(codeBlock) {\n if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;\n codeBlock.parentElement.setAttribute('data-copy-added', 'true');\n \n var btn = document.createElement('button');\n btn.textContent = 'Copy';\n btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';\n btn.onmouseover = function() { this.style.opacity = '1'; };\n btn.onmouseout = function() { this.style.opacity = '0.7'; };\n btn.onclick = function() {\n navigator.clipboard.writeText(codeBlock.textContent).then(function() {\n btn.textContent = 'Copied!';\n setTimeout(function() { btn.textContent = 'Copy'; }, 1500);\n });\n };\n codeBlock.parentElement.style.position = 'relative';\n codeBlock.parentElement.appendChild(btn);\n });\n }\n \n addCopyButtons();\n \n // Re-run on dynamic content\n var observer = new MutationObserver(addCopyButtons);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Add Copy Buttons to Code Blocks");
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Force GitHub README to respect dark mode\n(function() {\n var style = document.createElement('style');\n style.textContent = '\n .markdown-body {\n color-scheme: dark light;\n }\n .markdown-body pre { background: #161b22 !important; }\n .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; }\n .markdown-body table th, .markdown-body table td { border-color: #30363d !important; }\n .markdown-body img { background: #0d1117; }\n .markdown-body blockquote { border-left-color: #8b949e; }\n .markdown-body hr { border-color: #30363d; }\n ';\n document.head.appendChild(style);\n})();", "GitHub Dark Mode README Fix"); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Highlight search terms from Google/DuckDuckGo/Bing referrer\n(function() {\n var ref = document.referrer;\n var terms = [];\n \n if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) {\n var url = new URL(ref);\n var q = url.searchParams.get('q') || url.searchParams.get('p');\n if (q) {\n terms = q.split(/\\s+/).filter(function(t) { return t.length > 2; });\n }\n }\n \n if (terms.length === 0) return;\n \n var style = document.createElement('style');\n style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }';\n document.head.appendChild(style);\n \n function highlight(node) {\n if (node.nodeType === 3) { // text node\n var text = node.textContent;\n var found = false;\n terms.forEach(function(term) {\n var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\') + ')', 'gi');\n if (regex.test(text)) {\n found = true;\n var frag = document.createDocumentFragment();\n var parts = text.split(regex);\n parts.forEach(function(part, i) {\n if (i % 2 === 0) {\n frag.appendChild(document.createTextNode(part));\n } else {\n var span = document.createElement('span');\n span.className = 'userscript-highlight';\n span.textContent = part;\n frag.appendChild(span);\n }\n });\n node.parentNode.replaceChild(frag, node);\n }\n });\n } else if (node.nodeType === 1 && node.childNodes) { // element\n var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT'];\n if (!skipTags.includes(node.tagName)) {\n Array.from(node.childNodes).forEach(highlight);\n }\n }\n }\n \n highlight(document.body);\n \n // Re-highlight on dynamic content\n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1 || node.nodeType === 3) highlight(node);\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Highlight Search Terms"); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Strip utm_, fbclid, gclid, etc. from all links on page\n(function() {\n var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content',\n 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid',\n 'ref', 'ref_src', 'source', 'medium', 'campaign'];\n \n function cleanUrl(url) {\n try {\n var u = new URL(url, window.location.origin);\n var changed = false;\n trackingParams.forEach(function(p) {\n if (u.searchParams.has(p)) {\n u.searchParams.delete(p);\n changed = true;\n }\n });\n return changed ? u.toString() : url;\n } catch (e) {\n return url;\n }\n }\n \n function cleanLinks() {\n document.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n \n cleanLinks();\n \n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1) {\n if (node.tagName === 'A') cleanLinks();\n node.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Remove Tracking Parameters from Links"); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Auto-enable theater mode on YouTube\n(function() {\n function tryTheater() {\n var btn = document.querySelector('button[aria-label=\"Theater mode\"], ytd-player #player button[title=\"Theater mode\"]');\n if (btn && !btn.classList.contains('activated')) {\n btn.click();\n }\n }\n \n // Try immediately\n tryTheater();\n \n // Try after navigation (SPA)\n var lastUrl = location.href;\n setInterval(function() {\n if (location.href !== lastUrl) {\n lastUrl = location.href;\n setTimeout(tryTheater, 500);\n }\n }, 1000);\n \n // Also try on player load\n var observer = new MutationObserver(tryTheater);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "YouTube Theater Mode Default"); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Remove or un-stick sticky/fixed headers that block content\n(function() {\n function unstick() {\n document.querySelectorAll('header, nav, [role=\"banner\"], .header, .navbar, .sticky, .fixed-top, [style*=\"position: fixed\"], [style*=\"position:sticky\"]').forEach(function(el) {\n if (el.style.position === 'fixed' || el.style.position === 'sticky' || \n getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') {\n el.style.position = 'static';\n el.style.top = 'auto';\n el.style.zIndex = 'auto';\n }\n });\n }\n \n unstick();\n \n var observer = new MutationObserver(unstick);\n observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] });\n})();", "Kill Sticky Headers"); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Universal Dark Mode - works on any site\n(function() {\n var enabled = true;\n \n function applyDarkMode() {\n if (!enabled) return;\n \n // Create style element if it doesn't exist\n var style = document.getElementById('universal-dark-mode-style');\n if (!style) {\n style = document.createElement('style');\n style.id = 'universal-dark-mode-style';\n document.head.appendChild(style);\n }\n \n // Dark mode CSS - inverts colors but preserves images/video\n style.textContent = '\n /* Invert everything except media */\n html {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #1a1a2e !important;\n }\n \n /* Restore images, videos, iframes, canvas */\n img, video, iframe, canvas, svg, picture, [style*=\"background-image\"] {\n filter: invert(1) hue-rotate(180deg) !important;\n }\n \n /* Preserve specific elements that should not be inverted */\n .no-dark-mode, .no-dark-mode *,\n [data-theme=\"light\"], [data-theme=\"light\"],\n .ace_editor, .ace_editor *,\n .CodeMirror, .CodeMirror *,\n .monaco-editor, .monaco-editor *,\n .markdown-body pre, .markdown-body pre *,\n .highlight, .highlight *,\n pre code, pre code * {\n filter: none !important;\n }\n \n /* Fix common UI elements */\n .modal, .popup, .dropdown-menu, .tooltip, .popover {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #2d2d44 !important;\n border-color: #444 !important;\n }\n \n /* Scrollbars */\n ::-webkit-scrollbar { background: #1a1a2e !important; }\n ::-webkit-scrollbar-thumb { background: #444 !important; }\n ::-webkit-scrollbar-thumb:hover { background: #555 !important; }\n \n /* Selection */\n ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ';\n }\n \n function removeDarkMode() {\n var style = document.getElementById('universal-dark-mode-style');\n if (style) style.remove();\n }\n \n // Toggle with Alt+Shift+D\n document.addEventListener('keydown', function(e) {\n if (e.altKey && e.shiftKey && e.key === 'D') {\n e.preventDefault();\n enabled = !enabled;\n if (enabled) {\n applyDarkMode();\n console.log('[Universal Dark Mode] Enabled');\n } else {\n removeDarkMode();\n console.log('[Universal Dark Mode] Disabled');\n }\n }\n });\n \n // Apply on load\n applyDarkMode();\n \n // Re-apply on dynamic content\n var observer = new MutationObserver(function(mutations) {\n if (enabled && !document.getElementById('universal-dark-mode-style')) {\n applyDarkMode();\n }\n });\n observer.observe(document.head, { childList: true });\n \n console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle');\n})();", "Universal Dark Mode"); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content
Merged
4 changes: 0 additions & 4 deletions .claude/skills/pm-dispatch/references/lanes/cli.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,10 +14,6 @@

## 常设承诺

- **Required checks 六个**:`TypeScript Type Check` · `Lint & Repo Gates` ·
`Test Core` · `Dogfood Regression Gate` · `Build Core` ·
`Temporal Conformance (live PG + MySQL)` —— 逐 job 读各自 `conclusion`,⛔ 不认
聚合,`in_progress` 不是过;advisory 门禁红进 main 是共享损伤,照样止血立单。
- **PR 侧绿 ≠ 队列侧绿**;队列分支读法与边界在 platform-readings(条目名
`main/pr-{number}-{parent sha}`,parent sha 可重建队序;⚠️ ref 在出队后滞留)。
- `dispatch-gates.mjs` 只报**路径推导**的地板 —— 条款②从卡**内容**判且优先于它;已知盲
Expand Down
2 changes: 0 additions & 2 deletions .claude/skills/pm-dispatch/references/lanes/services.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -18,8 +18,6 @@
—— 单独的绿不是证据。
- **安全族卡的披露纪律**:复现配方不落任何公开面(卡、PR、评论);证据以抽象描述
或私有通道承载。
- 门禁读数不轻信聚合:`check:type-check-debt` 可以在包级 typecheck 绿时红;
`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。

## 席内判断

Expand Down
10 changes: 10 additions & 0 deletions .claude/skills/pm-dispatch/references/platform-readings.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -294,6 +294,16 @@
降档(那正是降档保险丝要拒的替换),但「本车道 fable 强制」多是过宽的回忆 ——
`dispatch-gates.mjs --tier PATH` 逐路径现推(实测:`SKILL.md` 与 `.claude/agents/**` 强制,`scripts/pm/**`
与 `references/**` 无 ⇒ 全阻塞的三卡 fold 拆成 1 阻 3 可跑);路径线是**下限不是放行**。
- **required checks 的名单是每仓事实**(逐 job 读判定的规则住上面队列段):objectstack 六个 ——
`TypeScript Type Check` · `Lint & Repo Gates` · `Test Core` · `Dogfood Regression Gate` ·
`Build Core` · `Temporal Conformance (live PG + MySQL)`;`in_progress` 不是过;advisory 门禁
红进 main 是共享损伤,照样止血立单。⛔ 聚合命令同样不作判定:`check:type-check-debt` 可在
包级 typecheck 绿时红;`check:i18n` 以「PREREQUISITE NOT MET — workspace CLI 未 build」退 3 不是漂移。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。

## 闭合关键词解析(PR 正文写侧)

Expand Down
5 changes: 0 additions & 5 deletions .claude/skills/pm-dispatch/references/rest-channel.md
Original file line numberDiff line numberDiff line change
Expand Up@@ -76,11 +76,6 @@ payload → REST → MCP/GraphQL** 的策略住那里,本表是逐操作的通
`PUT .../pulls/{n}/merge`,强制队列 ruleset 下回 **405 `Changes must be made through the merge queue`**;② PR
上的 `added_to_merge_queue` timeline 事件;③ 对已入队 PR 调 update-branch 回「已入队分支不能更新,
要改先出队」。①② 拼写与边界是 `platform-readings.md` 队列段既有行,本条只归拢判据。
- ⚠️ **计数不是机理读数(被当天推翻的推断的墓碑)**:「`GET .../actions/runs?event=merge_group`
计数 0 ⇒ required 集为空」提出当天即被自身推翻 —— 同一姊妹仓 2026-08-24 首现 merge_group
run(0 → 8),同日再测 224(阳性对照 `event=pull_request` 全程非零)。计数答「至今发生过没有」,
不答「机制在不在」:零计数只作**弱先验**,判 required 集为空要读 ruleset
的 required 集本身、或看队列合并是否真在等检查;⛔ 别处写下的计数值一律先复测再用。
- **required job 名与分片矩阵的改名耦合(现行,自 2026-08-24)**:
队列 required 集按 **job / check-run 名**匹配,**workflow 名从不作为 check context 出现**(所以拿
workflow 名在选择器里搜什么也搜不到);改其中任一 job 名**或 test 分片矩阵的形状**,
Expand Down
69 changes: 68 additions & 1 deletion scripts/check-ratchet-remedy-authority.mjs
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,6 +16,49 @@
// precedents are check-type-source-resolution.mjs, check-test-source-alias.mjs,
// check-adr-links.mjs and check-driver-memory-census.mjs.
//
// ── The ruled EXCEPTION: an authorised cross-file move (2026-09-03) ─────────
//
// The disjunction above asks WHO may take a registry-growing remedy, and on a
// shrink-only ratchet the answer was always "a maintainer, per instance". One
// class of act is now authorised generally instead of one PR at a time.
// Maintainer ruling, 2026-09-03, adopting option A of item 5 in the skills
// optimization programme's third decision batch (#14685, comment 5520452691) —
// verbatim and untranslated: 「同意」; the text it adopts:
//
// the per-file line ratchet admits a cross-file move in one PR when the
// destination's allowance rises by no more than the source's net decrease and
// total lines do not increase, with the ruling cited in the ratchet comment;
// `check:ratchet-remedy-authority`'s self-description gains this exception
//
// So: a cross-file MOVE in the per-file line ratchet is NOT a maintainer-only
// remedy while all three conditions hold — the destination's raise is covered by
// the named sources' net decrease, the map-wide total does not increase, and the
// raised entry cites that ruling. The scope is exactly the act the ruling names,
// in the gate the ruling names. A raise failing any condition is an ordinary
// raise and belongs to a maintainer as before, and no other ratchet in this farm
// gains anything: the reason a move is not a weakening is that the corpus SHRANK
// on net, which is a property of the act, not of the author.
//
// ⚠️ TODAY THE EXCEPTION IS DOCUMENTARY, and recording that is half the point of
// writing it here. The corpus walk is a NON-RECURSIVE readdir of `scripts/` (see
// corpusFiles), and the gate the ruling amends lives one directory down, in
// scripts/pm/ — it has never been in this sweep, so no verdict of this gate
// moves. A self-test assertion pins that, so a wider walk reds HERE and makes
// the class a decision someone takes rather than one that lands in silence.
//
// ⛔ NO NEW VERDICT CLASS. `marked` / `refused` / `unmarked` / `excluded` stay as
// they are. A fifth class for "authorised by standing ruling" would have a
// population of zero in this corpus, and an unreachable class is a claim of
// enforcement nobody has — the same defect this file's control corpus exists to
// prevent, one level up. If the walk ever reaches a gate offering this act, the
// honest first move is to read that gate's own verdict and record it in CONTROL,
// the way every instance in this file arrived.
//
// ⛔ THIS SECTION IS COMMENT, never a string literal — the header warning above,
// applied to itself. It describes an act that grows a registry, so in
// author-facing text it would make this gate an instance of the convention it
// enforces and flip its own verdict off `excluded`.
//
// WHY A SWEEP AND NOT A SHARED MODULE. #8519 proposed a shared helper module as
// the enforcement route. It is not one: a module is reachable only from gates
// that choose to import it, so it standardises the gates that already agreed and
Expand DownExpand Up@@ -146,11 +189,12 @@ const SELF_TEST_BATTERIES = Object.freeze({
'(19) …and the mirror: the token in a string literal DOES count. Paired with': 1,
'(17) This gate must not be an instance of its own convention.': 1,
'(20) The declared population, held to the walk in BOTH directions (#13813)': 7,
'(21) The ruled cross-file-move exception (2026-09-03)': 2,
});

// DELETING an entry silences that battery's floor exactly as effectively as
// zeroing it, so the roster's own size is pinned too.
const SELF_TEST_BATTERY_FLOOR = 20;
const SELF_TEST_BATTERY_FLOOR = 21;

// The key an assertion is filed under when no battery is open. It is not a
// declared battery, so it reds by the same set difference rather than silently
Expand DownExpand Up@@ -1347,6 +1391,29 @@ function selfTest() {
+ 'nothing, and a dead declaration prints as the same silence as declaring nothing)',
!ROOT_DIR_WATCH_HINTS.some((h) => h.includes('{')));

// ── (21) The ruled cross-file-move exception (2026-09-03) ───────────────
//
// Two assertions, and both are about THIS FILE rather than about the ratchet
// the ruling amends: where the exception is written down, and whether it is
// doing anything yet. Neither can be held by the run — a header section runs
// green whatever it says, which is exactly how a documented exception drifts
// into a claimed one.
battery('(21) The ruled cross-file-move exception (2026-09-03)');
const selfSrc = readFileSync(join(SCRIPTS_DIR, SELF_FILE), 'utf8');
// ⛔ The phrase is ASSEMBLED, never spelled, for the reason the ADD hoist above gives in
// its own case: a literal spelling would put the phrase into THIS file's author-facing text
// and falsify the assertion below by the act of making it.
const EXCEPTION_PHRASE = ['cross-file', 'MOVE'].join(' ');
expect('the ruled exception is recorded in COMMENT space only — written into author-facing text '
+ 'it would describe a registry-growing act, and this gate would then read as an instance of '
+ 'the convention it enforces, which is what assertion (17) catches',
selfSrc.includes(EXCEPTION_PHRASE)
&& !authorFacingMessages(selfSrc).some((m) => m.includes(EXCEPTION_PHRASE)));

expect('the ruled exception is documentary today: the amended line ratchet lives one directory '
+ 'down and this walk is non-recursive, so a wider walk reds HERE rather than admitting a new '
+ 'remedy class in silence',
!corpusFiles().includes('check-skill-line-ratchet.mjs'));
// ── The floor: every declared battery RAN, and ran its cases (#13489) ───
//
// Evaluated after every battery has had its chance and BEFORE the verdict, so
Expand Down
Loading
Loading