AgentSkillsCN

review-pr

适用于在提交前审查当前分支或 PR。将工作与 `git parent-branch` 对比,忽略生成的 `.wat`、`.hir`、`.masm` 和 `.lock` 文件,将审查细化为专注的子代理,并将可操作的编号发现写入 `review.md`。

SKILL.md
--- frontmatter
name: review-pr
description: Use when asked to review the current branch or a PR before submission. Compares the work against `git parent-branch`, ignores generated `.wat`, `.hir`, `.masm`, and `.lock` files, fans review out to focused subagents, and writes actionable numbered findings to `review.md`.

Review PR

Use this skill for a pre-submit review of the current branch.

Workflow

Run each of the following questions in a separate subagent with xhigh reasoning effort:

  • Look at the big picture (system design, architecture). Do you see a better way to implement this?
  • Correctness: Are there potential bugs, logical errors, or edge cases missed? For a code change, also find and analyze the full code of the function/class.
  • Suggestions: Do you have any suggestions on how to improve the code?

Run the following questions (all of them) in one separate subagent with high reasoning effort:

  • Style: Does the code changes adhere to the style this crate is written in? Error handling in particular.
  • Readability: How easily comprehensible is the resulted code? Any need for splitting the functions to make them more comprehensible?
  • Maintainability: Do you see any ways to improve the maintainability of the new/changed code?
  • Documentation: Modules, functions, types and structs should be documented. Need to add code comments to tricky, non-obvious parts of the code?
  • Naming: Are new names descriptive and unambiguous?
  • Clean up: Any dbg! (including commented out) in the new code besides tests? Any commented out code that looks like it was forgotten and should be removed?
  • Any TODO: left in the new code?
  • Suggestions: Do you have any suggestions on how to improve the code?

Provide detailed feedback, referencing the task context and specific code lines from the diff. Only include what you suggest to change/fix, skip the positive feedback where everything is fine. Number each note and write them in a readable form to a file review.md (append if there is one).