Claude Skill

code-review

Reviews code changes with a risk-ordered checklist and finds what a diff touches. Use whenever the user asks to review a pull request, diff, commit or file, wants feedback on their code, asks "is this safe to merge", or wants a self-review before opening a PR, even if they only p

LLM Mart · 0 points · 0 views 0 listing impressions 0 install-command copies
Download mehranqadirian-skills-software-engineering_code-review-c88187d.zip · 5 KB

Install

skills CLI npx skills add https://github.com/MehranQadirian/skills/tree/main/software-engineering/code-review
Claude Code claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install mehranqadirian-skills@llmmart
Git git clone https://github.com/MehranQadirian/skills.git

The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole mehranqadirian/skills collection as a plugin from our marketplace. Git is the plain clone.

README

code-review

A Claude skill that reviews code changes by risk, with a scope script and a clear blocker, suggestion and nit format.

What it does

  • Summarizes a diff with review_scope.sh: size, categories, risk flags, missing tests
  • Reviews in a fixed order: design, correctness, security, tests, operations, readability
  • Separates blockers from suggestions and nits
  • Writes concrete comments with file, line, reason and fix

Try it

Review my branch against main before I open a PR.

Is this change safe to merge? Here is the diff.

Give me a self-review checklist for this migration.

Install

Claude.ai: zip this folder, then go to Settings > Capabilities > Skills > Upload.

Claude Code:

cp -r software-engineering/code-review ~/.claude/skills/

Structure

code-review/
├── SKILL.md                    skill instructions for Claude
├── scripts/review_scope.sh     diff scope and risk flags
└── references/checklist.md     review checklist and comment style

Skill manifest

code-review

Review for correctness and risk first, style last. Report findings so the author knows what blocks the merge and what is optional.

code-review/
├── SKILL.md
├── scripts/
│   └── review_scope.sh    size, categories, risk flags, missing tests, debug leftovers
└── references/
    └── checklist.md       design, correctness, security, tests, performance, comment style

When to use

  • Reviewing a PR, branch, commit or pasted snippet
  • Self-review before opening a PR
  • Deciding whether a change is safe to merge or release

Workflow

  1. Scope: run bash scripts/review_scope.sh origin/main inside the repo. It shows size, risk flags (migrations, auth, dependencies, CI, secret-like files), whether tests changed, and leftover debug lines.
  2. Understand intent: read the PR description or commit messages. State the goal in one sentence. If it is unclear, ask.
  3. Read for design: wrong approach beats any line level comment.
  4. Read for correctness and risk using references/checklist.md, in order: design, correctness, security, tests, performance and operations, readability.
  5. Verify claims: run the tests, reproduce the bug, or trace one path by hand. Do not assume the tests cover it.
  6. Write the review with severity prefixes (below).

Output format

Summary: one or two sentences on what the change does and the overall verdict.

Blockers
- path:line  what is wrong, why it matters, suggested fix

Suggestions
- path:line  ...

Questions
- ...

Nits
- ...

What is good
- one or two specific things

Verdict is one of: approve, approve with suggestions, request changes. Use request changes only when there is at least one blocker.

Rules

  • Be specific: file, line, reason, fix. "Looks wrong" is not a review.
  • Separate blockers from preferences. Never block on style a formatter can handle.
  • Review the change, not the author. Prefer questions to accusations.
  • Do not review what you did not read; say which parts you skipped.
  • Large diffs: say so, review by risk, and ask to split.
  • If you find a secret, say "possible secret in file:line" without repeating it, and point to secrets-hygiene.

What to report back

Field Content
Verdict approve, approve with suggestions, request changes
Scope files, size, risk flags from the script
Verified tests run, paths traced, what was not checked
Findings grouped by severity with file and line

Related skills

  • secrets-hygiene: scan the change for credentials
  • systematic-debugging: reproduce and prove a suspected bug found in review
  • commitsmith: clean, scoped commit messages for the fixes
Files (skills)
  • references
    • checklist.md 2.5 KB
      Loading…
  • scripts
    • review_scope.sh 3.3 KB
      Loading…
  • README.md 1 KB
    # code-review
    
    A [Claude skill](../../README.md) that reviews code changes by risk, with a scope script and a clear blocker, suggestion and nit format.
    
    ## What it does
    
    - Summarizes a diff with `review_scope.sh`: size, categories, risk flags, missing tests
    - Reviews in a fixed order: design, correctness, security, tests, operations, readability
    - Separates blockers from suggestions and nits
    - Writes concrete comments with file, line, reason and fix
    
    ## Try it
    
    > Review my branch against main before I open a PR.
    
    > Is this change safe to merge? Here is the diff.
    
    > Give me a self-review checklist for this migration.
    
    ## Install
    
    **Claude.ai:** zip this folder, then go to Settings > Capabilities > Skills > Upload.
    
    **Claude Code:**
    
    ```bash
    cp -r software-engineering/code-review ~/.claude/skills/
    ```
    
    ## Structure
    
    ```
    code-review/
    ├── SKILL.md                    skill instructions for Claude
    ├── scripts/review_scope.sh     diff scope and risk flags
    └── references/checklist.md     review checklist and comment style
    ```
    
  • SKILL.md 3.1 KB
    ---
    name: code-review
    description: Reviews code changes with a risk-ordered checklist and finds what a diff touches. Use whenever the user asks to review a pull request, diff, commit or file, wants feedback on their code, asks "is this safe to merge", or wants a self-review before opening a PR, even if they only paste code and say "thoughts?". Reports blockers separately from suggestions and nits, with concrete fixes.
    ---
    
    # code-review
    
    Review for correctness and risk first, style last. Report findings so the author knows what blocks the merge and what is optional.
    
    ```
    code-review/
    ├── SKILL.md
    ├── scripts/
    │   └── review_scope.sh    size, categories, risk flags, missing tests, debug leftovers
    └── references/
        └── checklist.md       design, correctness, security, tests, performance, comment style
    ```
    
    ## When to use
    
    - Reviewing a PR, branch, commit or pasted snippet
    - Self-review before opening a PR
    - Deciding whether a change is safe to merge or release
    
    ## Workflow
    
    1. **Scope**: run `bash scripts/review_scope.sh origin/main` inside the repo. It shows size, risk flags (migrations, auth, dependencies, CI, secret-like files), whether tests changed, and leftover debug lines.
    2. **Understand intent**: read the PR description or commit messages. State the goal in one sentence. If it is unclear, ask.
    3. **Read for design**: wrong approach beats any line level comment.
    4. **Read for correctness and risk** using `references/checklist.md`, in order: design, correctness, security, tests, performance and operations, readability.
    5. **Verify claims**: run the tests, reproduce the bug, or trace one path by hand. Do not assume the tests cover it.
    6. **Write the review** with severity prefixes (below).
    
    ## Output format
    
    ```
    Summary: one or two sentences on what the change does and the overall verdict.
    
    Blockers
    - path:line  what is wrong, why it matters, suggested fix
    
    Suggestions
    - path:line  ...
    
    Questions
    - ...
    
    Nits
    - ...
    
    What is good
    - one or two specific things
    ```
    
    Verdict is one of: **approve**, **approve with suggestions**, **request changes**. Use request changes only when there is at least one blocker.
    
    ## Rules
    
    - Be specific: file, line, reason, fix. "Looks wrong" is not a review.
    - Separate blockers from preferences. Never block on style a formatter can handle.
    - Review the change, not the author. Prefer questions to accusations.
    - Do not review what you did not read; say which parts you skipped.
    - Large diffs: say so, review by risk, and ask to split.
    - If you find a secret, say "possible secret in file:line" without repeating it, and point to `secrets-hygiene`.
    
    ## What to report back
    
    | Field | Content |
    |-------|---------|
    | Verdict | approve, approve with suggestions, request changes |
    | Scope | files, size, risk flags from the script |
    | Verified | tests run, paths traced, what was not checked |
    | Findings | grouped by severity with file and line |
    
    ## Related skills
    
    - `secrets-hygiene`: scan the change for credentials
    - `systematic-debugging`: reproduce and prove a suspected bug found in review
    - `commitsmith`: clean, scoped commit messages for the fixes
    

Comments (0)

Sign in to join the conversation.

No comments yet.

Reviews (0)

No reviews yet.