Install any skill in seconds. Free to start, no credit card required.
Get Started Free →devcxl/code-review
从固定点(commit、branch、tag 或 merge-base)开始,沿两条轴线审查变更——规范(代码是否遵循仓库文档化的编码规范?)和规格(代码是否与原始 issue/PRD 的要求一致?)。两条审查线在并行子 agent 中运行,并以并排方式报告结果。当用户想审查一个分支、PR、进行中的变更,或要求"从 X 开始审查"时使用。
Passed 18 of 20 test cases with the skill, and 12 of 20 without it.
and 4 more in the full report
6 fixed12 passed either way2 still failing0 broke2 errored
Tokens, turns and time describe resource use, not a dollar price.
One of 6 test cases the skill fixed. Same model, same prompt, with and without the skill.
请帮我做一下双轴代码审查,检查代码风格规范以及需求变动的规格符合度。
| Checked | Without skill | With skill |
|---|---|---|
| Prompts the user to specify a baseline fixed point | Missed | Passed |
| Halts review workflow until the baseline fixed point is supplied | Missed | Passed |
The instructions your model reads when the skill loads.
对 HEAD 与用户指定的固定点之间的 diff 进行双轴审查:
两条轴线作为并行子 agent 运行,互不污染彼此的上下文,然后由本技能汇总双方的发现。
Issue 跟踪器应该已经提供给你了。如果没有,请告诉用户运行 /setup-matt-pocock-skills。
用户说的任何东西都可以作为固定点——commit SHA、分支名、tag、main、HEAD~5 等等。不要随意发挥,直接传入即可。如果用户没有指定,则询问:"以什么为基准进行审查——一个分支、一个 commit、还是 main?" 没有得到答案之前不要继续。
捕获 diff 命令:git diff <fixed-point>...HEAD(三个点,这样比较的是 merge-base)。同时通过 git log <fixed-point>..HEAD --oneline 记录 commit 列表。
在继续之前,确认固定点能解析(git rev-parse <fixed-point>)且 diff 非空。错误的引用或空的 diff 应该在此处失败——不应该让两个并行子 agent 来处理。
按以下顺序查找原始规格:
#123、Closes #45、GitLab !67 等)——按照 tracker 文档中的工作流来获取。docs/、specs/ 或 .scratch/ 下与分支名或功能名匹配的 PRD/规格文件。搜索仓库,找出所有记载代码编写规范的文件。若存在 CODING_STANDARDS.md 或 CONTRIBUTING.md,必须将它们列入来源。
除了仓库记录的内容外,规范轴线始终携带下面的气味基线(smell baseline)——一组来自 Fowler《重构》第 3 章的固定代码气味,即使仓库没有任何文档也适用。两条约束规则:
每个气味的格式为它是什么 → 如何修复;将其与 diff 匹配:
test cases passed, vs 12 / 20 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.