[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M71Q67GZX08QTNWRQJFZQ48M":3,"skill-same:01M71Q67GZX08QTNWRQJFZQ48M":73},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":27,"publishedAt":40,"linkOnly":41,"markdownContent":42,"markdownBody":43,"frontMatter":44,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":48,"repositoryHtmlUrl":49,"repositoryHomepageUrl":50,"ownerHtmlUrl":51,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":52,"install":53,"resources":66},"01M71Q67GZX08QTNWRQJFZQ48M","code-review",null,"从固定点（commit、branch、tag 或 merge-base）开始，按 Standards（代码是否符合本仓库记录的编码标准？）和 Spec（代码是否符合来源 issue\u002Fspec 的要求？）两个轴线审查变更。两个审查会在并行子代理中运行，并并排报告。适用于用户想审查 branch、PR、进行中的变更，或要求“review since X”时。","vinvcn\u002Fmattpocock-skills-zh-CN","vinvcn","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F120928190?v=4","01M71Q60C4V98DEXHGN2VXFSZB","01M71Q60D6PRAJHKQRY33ZNE59",5797,"MIT","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fengineering\u002Fcode-review\u002FSKILL.md",[17,22],{"categoryNo":18,"categoryName":19,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000007","代码审查","SCENARIO","使用场景",{"categoryNo":23,"categoryName":24,"taxonomyType":25,"taxonomyTypeDesc":26},"01JBSEEDCAT000000000000030","开发工程师","PROFESSION","适用职业",[28,29,30,31,32,33,34,35,36,37,38,39],"code review","review","code","spec","commit","merge","pr","branch","standards","issue","base","报告","2026-11-10 13:02:02",false,"---\nname: code-review\ndescription: \"从固定点（commit、branch、tag 或 merge-base）开始，按 Standards（代码是否符合本仓库记录的编码标准？）和 Spec（代码是否符合来源 issue\u002Fspec 的要求？）两个轴线审查变更。两个审查会在并行子代理中运行，并并排报告。适用于用户想审查 branch、PR、进行中的变更，或要求“review since X”时。\"\n---\n\n对用户提供的 fixed point 与 `HEAD` 之间的 diff 做双轴 review：\n\n- **Standards**：代码是否符合这个 repo 记录下来的 coding standards？\n- **Spec**：代码是否忠实实现来源 issue \u002F spec？\n\n两个轴线都作为**并行 sub-agents**运行，避免互相污染 context；然后这个 skill 聚合它们的 findings。每个 sub-agent 都要使用全新的 context window 启动。\n\nIssue tracker 应该已经提供给你；如果没有，请让用户运行 `\u002Fsetup-matt-pocock-skills`。\n\n## 流程\n\n### 1. 确定 fixed point\n\n用户说的任何内容都是 fixed point：commit SHA、branch name、tag、`main`、`HEAD~5` 等。如果用户没有指定，就询问。\n\n先捕获一次 diff command：`git diff \u003Cfixed-point>...HEAD`（three-dot，因此比较对象是 merge-base）。同时用 `git log \u003Cfixed-point>..HEAD --oneline` 记录 commits 列表。\n\n继续前，确认 fixed point 能解析（`git rev-parse \u003Cfixed-point>`），并且 diff 非空。错误 ref 或空 diff 应该在这里失败，而不是进入两个并行 sub-agents 后才失败。\n\n### 2. 找到 spec 来源\n\n按以下顺序寻找来源 spec：\n\n1. Commit messages 中的 issue references（`#123`、`Closes #45`、GitLab `!67` 等），按 tracker doc 中的 workflow 获取。\n2. 用户作为 argument 传入的 path。\n3. `docs\u002F`、`specs\u002F` 或 `.scratch\u002F` 下与 branch name 或 feature 匹配的 spec 文件。\n4. 如果什么都找不到，询问用户 spec 在哪里。如果用户说没有 spec，**Spec** sub-agent 跳过并报告 “no spec available”。\n\n### 3. 找到 standards 来源\n\n搜索 repo 中所有记录代码应该如何写的文件。当 `CODING_STANDARDS.md` 或 `CONTRIBUTING.md` 存在时，必须列入清单。\n\n在 repo 自己记录的 standards 之外，Standards 轴线始终带有下面的 **smell baseline**：一组固定的 Fowler code smells（_Refactoring_ 第 3 章），即使 repo 没有任何约定也适用。有两条规则：\n\n- **The repo overrides.** 已记录的 repo standard 永远优先；如果它认可 baseline 会标记的东西，就压制该 smell。\n- **Always a judgement call.** 每个 smell 都是带 label 的 heuristic（例如 \"possible Feature Envy\"），不是硬性违规；和这里的其他 standard 一样，跳过 tooling 已经强制检查的内容。\n\n每个 smell 按 _what it is_ -> _how to fix_ 读取，并对照 diff：\n\n- **Mysterious Name**：function、variable 或 type 的名称没有说明它做什么或装什么。-> rename it；如果找不到诚实名称，设计本身可能浑浊。\n- **Duplicated Code**：同一 logic shape 出现在多个 hunk 或 file 中。-> 抽出共享形状，让两边调用。\n- **Feature Envy**：method 访问另一个 object 的 data 多于自己的 data。-> 把 method 移到它羡慕的数据上。\n- **Data Clumps**：同几组 fields 或 params 总是一起出现。-> 包成一个 type 来传。\n- **Primitive Obsession**：primitive 或 string 代替了值得拥有自有 type 的 domain concept。-> 给该 concept 一个小 type。\n- **Repeated Switches**：对同一 type 的相同 `switch`\u002F`if` cascade 在改动中重复。-> 换成 polymorphism，或共享一个 map。\n- **Shotgun Surgery**：一个 logical change 迫使 diff 分散修改很多文件。-> 把一起变化的东西收拢进一个 module。\n- **Divergent Change**：一个 file 或 module 因多个无关原因被修改。-> 拆分，让每个 module 只因一个原因变化。\n- **Speculative Generality**：为 spec 没有的需求增加 abstraction、params 或 hooks。-> 删除它，inline 回来，直到有真实需要。\n- **Message Chains**：caller 不该依赖的长链式导航 `a.b().c().d()`。-> 把这段导航藏到第一个 object 的一个 method 后面。\n- **Middle Man**：class 或 function 基本只是在继续委托。-> 删掉它，直接调用真实目标。\n- **Refused Bequest**：subclass 或 implementer 忽略或 override 了继承来的大部分内容。-> 去掉 inheritance，使用 composition。\n\n### 4. 并行启动两个 sub-agents\n\n把两个 sub-agent 调用一起发出，在前台运行，并聚合它们返回的报告。\n\n**Standards sub-agent prompt** 包含：\n\n- 完整 diff command 和 commit list。\n- Step 3 中找到的 standards-source files 列表，**以及 Step 3 的 smell baseline 全文**；sub-agent 没有其他方式读取它。\n- Brief：\"Report, per file\u002Fhunk where relevant, (a) every place the diff violates a documented standard: cite the standard (file + the rule); and (b) any baseline smell you spot: name it and quote the hunk. Distinguish hard violations from judgement calls: documented-standard breaches can be hard, but baseline smells are always judgement calls, and a documented repo standard overrides the baseline. Skip anything tooling enforces. Under 400 words.\"\n\n**Spec sub-agent prompt** 包含：\n\n- Diff command 和 commit list。\n- Spec 的 path 或已获取内容。\n- Brief：\"Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words.\"\n\n如果缺少 spec，跳过 Spec sub-agent，并在最终报告中说明。\n\n### 5. 汇总\n\n在 `## Standards` 和 `## Spec` headings 下展示两个 reports，可原样或轻微清理。**不要**合并或重新排序 findings；这两个轴线刻意保持分离（见 _为什么是两条轴线_）。\n\n最后用一行总结：每个轴线的 findings 总数，以及每个轴线内最严重的问题（如果有）。不要跨轴线选一个总冠军；分离就是为了避免这种 reranking。\n\n## 为什么是两条轴线\n\n一个变更可能通过其中一个轴线，但失败在另一个轴线：\n\n- 代码符合所有 standard，但实现了错误的东西 -> **Standards pass, Spec fail.**\n- 代码完全符合 issue 要求，但破坏了项目约定 -> **Spec pass, Standards fail.**\n\n分开报告能避免一个轴线掩盖另一个轴线。\n","对用户提供的 fixed point 与 `HEAD` 之间的 diff 做双轴 review：\n\n- **Standards**：代码是否符合这个 repo 记录下来的 coding standards？\n- **Spec**：代码是否忠实实现来源 issue \u002F spec？\n\n两个轴线都作为**并行 sub-agents**运行，避免互相污染 context；然后这个 skill 聚合它们的 findings。每个 sub-agent 都要使用全新的 context window 启动。\n\nIssue tracker 应该已经提供给你；如果没有，请让用户运行 `\u002Fsetup-matt-pocock-skills`。\n\n## 流程\n\n### 1. 确定 fixed point\n\n用户说的任何内容都是 fixed point：commit SHA、branch name、tag、`main`、`HEAD~5` 等。如果用户没有指定，就询问。\n\n先捕获一次 diff command：`git diff \u003Cfixed-point>...HEAD`（three-dot，因此比较对象是 merge-base）。同时用 `git log \u003Cfixed-point>..HEAD --oneline` 记录 commits 列表。\n\n继续前，确认 fixed point 能解析（`git rev-parse \u003Cfixed-point>`），并且 diff 非空。错误 ref 或空 diff 应该在这里失败，而不是进入两个并行 sub-agents 后才失败。\n\n### 2. 找到 spec 来源\n\n按以下顺序寻找来源 spec：\n\n1. Commit messages 中的 issue references（`#123`、`Closes #45`、GitLab `!67` 等），按 tracker doc 中的 workflow 获取。\n2. 用户作为 argument 传入的 path。\n3. `docs\u002F`、`specs\u002F` 或 `.scratch\u002F` 下与 branch name 或 feature 匹配的 spec 文件。\n4. 如果什么都找不到，询问用户 spec 在哪里。如果用户说没有 spec，**Spec** sub-agent 跳过并报告 “no spec available”。\n\n### 3. 找到 standards 来源\n\n搜索 repo 中所有记录代码应该如何写的文件。当 `CODING_STANDARDS.md` 或 `CONTRIBUTING.md` 存在时，必须列入清单。\n\n在 repo 自己记录的 standards 之外，Standards 轴线始终带有下面的 **smell baseline**：一组固定的 Fowler code smells（_Refactoring_ 第 3 章），即使 repo 没有任何约定也适用。有两条规则：\n\n- **The repo overrides.** 已记录的 repo standard 永远优先；如果它认可 baseline 会标记的东西，就压制该 smell。\n- **Always a judgement call.** 每个 smell 都是带 label 的 heuristic（例如 \"possible Feature Envy\"），不是硬性违规；和这里的其他 standard 一样，跳过 tooling 已经强制检查的内容。\n\n每个 smell 按 _what it is_ -> _how to fix_ 读取，并对照 diff：\n\n- **Mysterious Name**：function、variable 或 type 的名称没有说明它做什么或装什么。-> rename it；如果找不到诚实名称，设计本身可能浑浊。\n- **Duplicated Code**：同一 logic shape 出现在多个 hunk 或 file 中。-> 抽出共享形状，让两边调用。\n- **Feature Envy**：method 访问另一个 object 的 data 多于自己的 data。-> 把 method 移到它羡慕的数据上。\n- **Data Clumps**：同几组 fields 或 params 总是一起出现。-> 包成一个 type 来传。\n- **Primitive Obsession**：primitive 或 string 代替了值得拥有自有 type 的 domain concept。-> 给该 concept 一个小 type。\n- **Repeated Switches**：对同一 type 的相同 `switch`\u002F`if` cascade 在改动中重复。-> 换成 polymorphism，或共享一个 map。\n- **Shotgun Surgery**：一个 logical change 迫使 diff 分散修改很多文件。-> 把一起变化的东西收拢进一个 module。\n- **Divergent Change**：一个 file 或 module 因多个无关原因被修改。-> 拆分，让每个 module 只因一个原因变化。\n- **Speculative Generality**：为 spec 没有的需求增加 abstraction、params 或 hooks。-> 删除它，inline 回来，直到有真实需要。\n- **Message Chains**：caller 不该依赖的长链式导航 `a.b().c().d()`。-> 把这段导航藏到第一个 object 的一个 method 后面。\n- **Middle Man**：class 或 function 基本只是在继续委托。-> 删掉它，直接调用真实目标。\n- **Refused Bequest**：subclass 或 implementer 忽略或 override 了继承来的大部分内容。-> 去掉 inheritance，使用 composition。\n\n### 4. 并行启动两个 sub-agents\n\n把两个 sub-agent 调用一起发出，在前台运行，并聚合它们返回的报告。\n\n**Standards sub-agent prompt** 包含：\n\n- 完整 diff command 和 commit list。\n- Step 3 中找到的 standards-source files 列表，**以及 Step 3 的 smell baseline 全文**；sub-agent 没有其他方式读取它。\n- Brief：\"Report, per file\u002Fhunk where relevant, (a) every place the diff violates a documented standard: cite the standard (file + the rule); and (b) any baseline smell you spot: name it and quote the hunk. Distinguish hard violations from judgement calls: documented-standard breaches can be hard, but baseline smells are always judgement calls, and a documented repo standard overrides the baseline. Skip anything tooling enforces. Under 400 words.\"\n\n**Spec sub-agent prompt** 包含：\n\n- Diff command 和 commit list。\n- Spec 的 path 或已获取内容。\n- Brief：\"Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words.\"\n\n如果缺少 spec，跳过 Spec sub-agent，并在最终报告中说明。\n\n### 5. 汇总\n\n在 `## Standards` 和 `## Spec` headings 下展示两个 reports，可原样或轻微清理。**不要**合并或重新排序 findings；这两个轴线刻意保持分离（见 _为什么是两条轴线_）。\n\n最后用一行总结：每个轴线的 findings 总数，以及每个轴线内最严重的问题（如果有）。不要跨轴线选一个总冠军；分离就是为了避免这种 reranking。\n\n## 为什么是两条轴线\n\n一个变更可能通过其中一个轴线，但失败在另一个轴线：\n\n- 代码符合所有 standard，但实现了错误的东西 -> **Standards pass, Spec fail.**\n- 代码完全符合 issue 要求，但破坏了项目约定 -> **Spec pass, Standards fail.**\n\n分开报告能避免一个轴线掩盖另一个轴线。\n",{"name":5,"description":7},"main","c5c5e87cc1df26aeb7dba345ad9f846434d2b3d4","skills\u002Fengineering\u002Fcode-review",450,"https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN","https:\u002F\u002Fskills.sh\u002Fvinvcn\u002Fmattpocock-skills-zh-CN","https:\u002F\u002Fgithub.com\u002Fvinvcn","2026-11-10 17:40:42",{"source":8,"skillName":5,"commands":54,"prompt":64,"zipAvailable":65},[55,58,61],{"tool":56,"command":57},"npx","npx skills add vinvcn\u002Fmattpocock-skills-zh-CN --skill code-review",{"tool":59,"command":60},"bunx","bunx skills add vinvcn\u002Fmattpocock-skills-zh-CN --skill code-review",{"tool":62,"command":63},"pnpm","pnpm dlx skills add vinvcn\u002Fmattpocock-skills-zh-CN --skill code-review","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fengineering\u002Fcode-review\u002FSKILL.md",true,[67],{"path":68,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":71,"sourceHtmlUrl":72},"agents\u002Fopenai.yaml","REFERENCE","参考文档",94,"https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fengineering\u002Fcode-review\u002Fagents\u002Fopenai.yaml",[74,94,104,114,124,133],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":89,"publishedAt":40},"01M71Q8F3M8YFP6WYVYQP61KBT","writing-for-agents","为 agent 编写文档。适用于创建或编辑 skills，或修改 AGENTS.md 或 CLAUDE.md 时。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fwriting-for-agents\u002FSKILL.md",[80,83,86],{"categoryNo":81,"categoryName":82,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000018","写作与文案",{"categoryNo":84,"categoryName":85,"taxonomyType":20,"taxonomyTypeDesc":21},"01JBSEEDCAT000000000000023","Skill与智能体开发",{"categoryNo":87,"categoryName":88,"taxonomyType":25,"taxonomyTypeDesc":26},"01JBSEEDCAT000000000000036","内容创作者",[90,91,92,93],"for","writing for agents","writing","文档",{"skillNo":95,"name":96,"nameZh":6,"description":97,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":98,"categories":99,"keywords":100,"publishedAt":40},"01M71Q8DHRPYE6R648CQ7NAHYN","wait-what","停一下：刚才那条消息没有说清楚，重新表述一遍。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fwait-what\u002FSKILL.md",[],[101,102,103],"wait","wait what","true",{"skillNo":105,"name":106,"nameZh":6,"description":107,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":40},"01M71Q8C8CBSRJRP8Y0JRZ7RJ7","to-questionnaire","把你无法完整回答的 decision 转成一份交给他人填写的 questionnaire。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fto-questionnaire\u002FSKILL.md",[],[111,112,113,103],"questionnaire","to questionnaire","decision",{"skillNo":115,"name":116,"nameZh":6,"description":117,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":123,"publishedAt":40},"01M71Q8ASS9A6P84PSC02YFKHB","teach","在这个工作区中教用户一个新技能或概念。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fteach\u002FSKILL.md",[120],{"categoryNo":121,"categoryName":122,"taxonomyType":25,"taxonomyTypeDesc":26},"01JBSEEDCAT000000000000039","教师与教育",[116,103],{"skillNo":125,"name":126,"nameZh":6,"description":127,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":128,"categories":129,"keywords":130,"publishedAt":40},"01M71Q89C2C2QRR3J3H64ZKH0P","handoff","把当前对话压缩成交接文档，让另一个代理接手。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fhandoff\u002FSKILL.md",[],[126,103,131,132,93],"对话","压缩",{"skillNo":134,"name":135,"nameZh":6,"description":136,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":137,"categories":138,"keywords":139,"publishedAt":40},"01M71Q883CXWF0BGDQC3Y8TJZ2","grilling","围绕计划、decision 或 idea 持续追问用户。适用于用户想对自己的思路做压力测试，或使用任何 “grill” 触发措辞时。","https:\u002F\u002Fgithub.com\u002Fvinvcn\u002Fmattpocock-skills-zh-CN\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fgrilling\u002FSKILL.md",[],[135,140,141,113,142],"idea","grill","testing"]