review-change

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Review Change

变更评审

Quality gate: run every applicable review and skip the rest, then synthesize and classify one report. Findings only; never edit or refactor.
质量门禁:运行所有适用的评审,跳过其余评审,然后合并结果并生成一份分类报告。仅输出问题发现;绝不编辑或重构代码。

Turn contract

交互契约

Load and verify the canonical Turn contract (11 boxes) before ending every turn. Skill-specific additions (receipt closeout, isolation rule, applicability) live here and in REVIEW_PROCESS.md. Missing reference → STOP.
For a final PR review, the turn is incomplete until this additional box passes:
text
✓ Decision: REVIEW-PASS + PR exists → `gh pr comment <N> --body-file <path>` RUN;
  then `gh pr view <N> --json comments` RUN and the newest exact-HEAD
  `review-change:pass` marker is confirmed before printing `→ Next:`
The receipt closeout is a precondition of the report, not a follow-up: do not print the fixed report block until the comment is current. A clean report without that current receipt must not recommend
/audit-pr
.
For
REVIEW-FAIL
or
NEEDS-DECISION
, list every open finding ID in the closing recommendation, joined with
+
; the review must never hand off only the first finding.
Consume the internal verification contract; the reviewer checks the same frozen
ACCEPTANCE.md
blob as the executor before mapping candidate evidence.
在每轮交互结束前,加载并验证标准Turn contract(11项检查)。技能专属的补充内容(收尾确认、隔离规则、适用性)在此文档及REVIEW_PROCESS.md中。若缺失参考文档→立即停止。
对于最终的PR评审,需完成以下额外检查项才算交互完成:
text
✓ Decision: REVIEW-PASS + PR exists → `gh pr comment <N> --body-file <path>` RUN;
  then `gh pr view <N> --json comments` RUN and the newest exact-HEAD
  `review-change:pass` marker is confirmed before printing `→ Next:`
收尾确认是生成报告的前提条件,而非后续步骤:在确认评论已更新前,不得输出固定格式的报告块。若没有当前的收尾确认,即使报告无问题也不得推荐使用
/audit-pr
若评审结果为
REVIEW-FAIL
NEEDS-DECISION
,需在收尾建议中列出所有未解决的问题ID,用
+
连接;评审不得仅移交第一个发现的问题。
遵循内部的验证契约;评审者在映射候选证据前,需与执行者检查同一个冻结的
ACCEPTANCE.md
文件。

When to use

使用场景

  • Mandatory before every merge. Review in a context that did not implement the change; if it did, stop and hand off to a fresh one.
    execute-phase
    may also recommend optional checkpoints at layer boundary, accumulation or sensitivity (
    #77
    ).
  • Use when you need applicable reviews without irrelevant passes.
  • 合并前强制要求。在未参与变更实现的环境中进行评审;若评审环境参与了变更实现,则停止评审并移交至全新环境。
    execute-phase
    也可能建议在层边界、代码累积或敏感点处设置可选检查点(
    #77
    )。
  • 当你需要仅针对适用场景进行评审,避免无关检查时使用。

Scope

评审范围

Default target is the current change (branch diff vs the default branch); accept a path/glob to widen or narrow. State the scope at the top of the report.
默认评审目标为当前变更(分支与默认分支的差异);可接受路径/通配符来扩大或缩小范围。需在报告顶部说明评审范围。

Step 0 — Discover the project & the change (always first)

步骤0 — 了解项目与变更(始终第一步)

Per Workflow conventions + documentation map, decide axes from:
  1. Project nature: UI (
    docs/frontend/
    ), web/mobile/CLI/library/backend, and optional recorded platform skills (extras only).
  2. Footprint: what the diff touches (UI, API, infra, domain). An axis applies only when both project and footprint support it.
根据工作流规范及文档映射,从以下维度确定评审轴:
  1. 项目性质:UI(
    docs/frontend/
    )、Web/移动/CLI/库/后端,以及可选的已记录平台技能(仅额外内容)。
  2. 影响范围:变更涉及的内容(UI、API、基础设施、业务领域)。只有当项目性质与影响范围均支持某一轴时,该轴才适用。

Applicability matrix (default; the project's docs refine it)

适用性矩阵(默认;项目文档可细化)

Every axis maps to a skill of the workflow's own internal review pack (
skills/review-*
— installed with the workflow, so none can be missing):
Axis — internal pack skillWebMobileConsole/CLILib/SDKBackend/Infra
review-code
(correctness, simplification, dead code, duplication, arch)
review-security
review-verify
(run it, confirm real behavior, tests)
review-design
(UI/UX)
TUI only
review-a11y
rare
review-brand
(voice/copy)
output text
review-perf
review-seo
API ergonomics / usage docs (inline pass)if APIif APIflags/help✓✓
review-implementation
(the single classifier over the synthesized table — process step 7) and
review-debt
(the debt transform over the classified table — process step 8) are not axis finders: they run once per review, not per axis.
每个轴对应工作流内部评审包中的一项技能(
skills/review-*
— 随工作流安装,无缺失):
轴 — 内部包技能Web移动控制台/CLI库/SDK后端/基础设施
review-code
(正确性、简化、死代码、重复代码、架构)
review-security
review-verify
(运行验证、确认实际行为、测试)
review-design
(UI/UX)
仅TUI
review-a11y
罕见
review-brand
(语气/文案)
输出文本
review-perf
review-seo
API 易用性 / 使用文档(内联检查)若涉及API若涉及API命令行参数/帮助✓✓
review-implementation
(对合并后的结果表进行分类的单一分类器 — 流程步骤7)和
review-debt
(对分类后的结果表进行债务转换 — 流程步骤8)不属于轴查找器:它们在每次评审中仅运行一次,而非每个轴运行一次。

Isolation rule (default — every pass, not only adversarial)

隔离规则(默认 — 每次检查均适用,不仅限于对抗式评审)

Each applicable pass, the classifier (step 7), and debt transform (step 8) runs isolated/context-clean and returns only its fixed findings table plus
PASS | FAIL
—never diff or prose. Spawn one fresh subagent/headless run per pass; without those, use a fresh conversation. Pass only scope, its checklist, and Step 0 docs; cap full non-diff reads at 10 (targeted ≤50-line reads/greps excluded). The orchestrator retains tables, not sources, and fuses them in step 6. Inline fallback is sequential table reduction. A pass runs at its own tier or stronger, never weaker.
每个适用的检查、分类器(步骤7)和债务转换(步骤8)均需在独立/干净的上下文中运行,仅返回固定格式的问题发现表及
PASS | FAIL
结果——绝不返回差异内容或散文式描述。为每次检查生成一个全新的子Agent/无头运行实例;若无法实现,则使用全新对话。仅传递评审范围、检查清单及步骤0的文档;非差异内容的完整读取上限为10次(针对性的≤50行读取/ grep除外)。编排器仅保留结果表,不保留源内容,并在步骤6中合并这些表。内联回退方案为顺序表归约。检查需在自身层级或更强层级运行,绝不使用更弱层级。

Progressive loading — choose one review route

渐进式加载 — 选择一条评审路径

After applicability and isolation are established:
The reference allowlist is exactly the seven linked paths below. Never invent or read another
references/
path.
Invocation routeLOAD in this orderSKIP
Default reviewreview processadversarial recommendationpersist and decideoutput and guardrailssynthesis, portability, adversarial setup
--adversarial N
review process → adversarial setup before reviewers → adversarial synthesis before fusion → persist/decide → output/guardrailsportability
--synthesize
review process → adversarial synthesis plus the supplied reviewer tables → persist/decide → output/guardrailsadversarial setup, portability
legacy
--merge
print the fixed migration refusal below and stop — zero git/forge mutationeverything
Legacy
--merge
is removed — not an alias.
Calling
/review-change --merge
prints this fixed migration refusal and stops before any git or forge mutation command runs:
migration: --merge is removed. Table fusion is --synthesize: pass the fixed
reviewer tables the same way and the synthesis contract fuses them. No
repository merge is performed by this skill.
Active review paths use only
--synthesize
/fusion language. Add portability only when contexts, parallelism, slash commands or tier controls are unavailable.
docs/workflow/REPOSITORY_STATE.md
is evidence for output/guardrails, not a skill reference; that route owns NRS and Architectural invariants rules.
Resources are one hop from this file. Fixed reviewer/synthesis/output contracts are literal. Missing required resource → stop; never approximate a review contract.
确定适用性与隔离规则后:
参考白名单仅包含以下7个链接路径。不得创建或读取其他
references/
路径。
调用路径按此顺序加载跳过内容
默认评审评审流程对抗式评审建议记录与决策输出与防护规则结果合并、可移植性、对抗式设置
--adversarial N
评审流程 → 评审前加载对抗式设置 → 合并前加载对抗式结果合并 → 记录/决策 → 输出/防护规则可移植性
--synthesize
评审流程 → 对抗式结果合并 + 提供的评审结果表 → 记录/决策 → 输出/防护规则对抗式设置、可移植性
旧版
--merge
打印以下固定的迁移拒绝信息并停止 — 不执行任何git/代码托管平台操作所有内容
旧版
--merge
已移除 — 无别名。调用
/review-change --merge
将打印以下固定的
迁移拒绝
信息,并在执行任何git或代码托管平台操作前停止:
migration: --merge is removed. Table fusion is --synthesize: pass the fixed
reviewer tables the same way and the synthesis contract fuses them. No
repository merge is performed by this skill.
当前有效的评审路径仅使用
--synthesize
/合并相关术语。仅当上下文、并行性、斜杠命令或层级控制不可用时,才添加可移植性
docs/workflow/REPOSITORY_STATE.md
是输出/防护规则的参考证据,而非技能参考文档;该路径负责NRS和架构不变性规则。
资源均与此文件处于同一层级。固定的评审者/结果合并/输出契约为字面内容。若缺失必需资源→停止;绝不近似评审契约。

Portability

可移植性

Keep reviewer contexts isolated. Use portability for sequential/headless fallbacks; never collapse independent adversarial passes.
保持评审者上下文独立。使用可移植性作为顺序/无头回退方案;绝不合并独立的对抗式检查。

Relationship to other skills

与其他技能的关系

Orchestrates internal finders (
review-code
,
review-security
,
review-verify
,
review-design
,
review-a11y
,
review-brand
,
review-perf
,
review-seo
), then one
review-implementation
classifier and
review-debt
transform, isolated by default; installed platform packs are optional.
triage-issue
is user-invoked only for independent proposals (D3). It is Stage 4: checkpoint reviews are optional, the end review is mandatory and fresh.
fix-now
folds in-unit,
replan-in-unit
adds user-confirmed phases, and independent work becomes proposals.
audit-pr
consumes only the verified PR-comment receipt, never the chat report;
product-audit
is the periodic sweep;
loop-review-fold
may run this skill fresh and route FAIL to
fold-findings
.
编排内部查找器(
review-code
review-security
review-verify
review-design
review-a11y
review-brand
review-perf
review-seo
),然后运行一次
review-implementation
分类器和
review-debt
转换,默认情况下相互隔离;已安装的平台包为可选。
triage-issue
仅由用户调用,用于独立提案(D3)。此技能属于第4阶段:检查点评审为可选,最终评审为强制且需在全新环境中进行。
fix-now
将问题合并至单元内,
replan-in-unit
添加用户确认的阶段,独立工作将成为提案。
audit-pr
仅使用已验证的PR评论记录,绝不使用聊天报告;
product-audit
为定期扫描;
loop-review-fold
可重新运行此技能,并将失败结果路由至
fold-findings

Done when

完成标志

  • One synthesized/classified table covers every applicable axis, lists skipped axes with reasons, and includes manual checks. Every finding has a destination: fold, confirmed replan phase, surfaced decision, or user-routed proposal; none is silently lost and review creates no backlog (D3). Print the closing
    → Next:
    block (clean →
    /audit-pr
    ; recurring drift →
    /product-audit
    ) and change no code.
  • 一份合并后的分类表覆盖所有适用的评审轴,列出跳过的轴及原因,并包含人工检查项。每个问题都有明确的处理方向:合并至单元内、确认重新规划阶段、提交决策或用户路由至提案;无问题被静默忽略,且评审不会产生待办积压(D3)。打印收尾的
    → Next:
    块(无问题→
    /audit-pr
    ;持续漂移→
    /product-audit
    ),且不得修改任何代码。