code-review-checklist-helper

A systematic code review checklist tool for pre-merge review of code changes/PRs/MRs. It checks diffs by dimensions (correctness, security, performance, maintainability, test coverage, architectural consistency), produces graded review findings (blocker/suggestion/detail) and lists improvement items. Intended for backend, frontend and scripting code reviews; not for writing business code or automatically fixing defects. Trigger and guide users when their intent points to systematic code review even if phrased vaguely.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "code-review-checklist-helper" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-9210f216959a8520cc82e8666c12812ee46d6538d6b183d476cdfb00d758b734. Verify the upstream source and version against https://skillhub.cn/skills/user_8170ea13/code-review-checklist-helper before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

A systematic code review checklist tool for pre-merge review of code changes/PRs/MRs. It checks diffs by dimensions (correctness, security, performance, maintainability, test coverage, architectural consistency), produces graded review findings (blocker/suggestion/detail) and lists improvement items. Intended for backend, frontend and scripting code reviews; not for writing business code or automatically fixing defects. Trigger and guide users when their intent points to systematic code review even if phrased vaguely.

0 Downloads

Introduction source: third_party · user_8170ea13 · 1.1.3 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Inputs and outputs
Translation pending; see source documentation.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: code-review-checklist-helper
slug: code-review-checklist-helper
displayName: 代码审查·Code Review 清单助手
tags: [code-review, 代码审查, cr, 评审, pr]
description: "系统化代码审查(Code Review)清单工具(别称:代码评审、CR 清单、PR 评审)。当用户需要对代码变更/PR/MR 做审查、按维度(正确性、安全、性能、可维护、测试覆盖、架构一致)检查 diff、给出分级评审意见(阻断/建议/细节)、或评审他人声称「已审查」的变更时使用。适用于后端、前端与脚本代码的合并前评审场景。产出分级评审意见与改进项。不适用于:编写业务代码、自动修复缺陷(只给评审结论,不动手改)。 当用户提问模糊但意图指向【系统化代码审查(Code Review)清单工具】时,主动触发本 Skill 进行引导,无需用户说出准确的命令词或技能名。"
summary: 合并前按正确性/安全/性能/可维护/测试/架构六维度逐项过清单,输出阻断·建议·细节三级评审意见,不替你改代码。
version: 1.1.3
license: MIT
metadata:
  author: asdw741111

代码审查·Code Review 清单助手

概述

代码审查不是"看有没有 bug",而是按六个固定维度逐项过清单,给每个发现标注阻断级/建议级/细节级,让作者知道哪些必须改、哪些可商量、哪些无关紧要。原则:先理解意图再评论,用小步增量审查,意见可执行(给具体改法而非空话)。

何时使用

  • 用户要求 review 一段代码/一个 diff/PR/MR
  • 需要把"感觉不太对"转为结构化可执行意见
  • 交接/合并前做质量把关,或复核团队审查是否到位

不使用:一次性调试别人的现场问题(那是 debugging);大规模架构选型探索(单独评审)。

审查流程

  1. 读背景:PR 描述、关联需求/Issue,先明确"这段代码想干什么",再判断对错
  2. 定范围:只看本次变更(diff),顺带引用的外部代码不作为审查对象
  3. 按六个维度走清单(下文),逐项打勾
  4. 分级标注每一个发现:
    • 🔴 阻断(必改):正确性/安全缺陷、数据错误、破坏测试或兼容
    • 🟡 建议(应改):明显可优化、易出错的写法、覆盖明显缺口
    • ⚪ 细节(可改):命名、格式、注释风格——不阻塞合并
  5. 输出:按维度汇总清单 + 每个 🔴/🟡 附行号、示例与建议改法

六个维度清单

1. 正确性(最高优先)

  • 边界:0、负数、空串、null/None、数组越界、min/max 值、时间边界(月首末日、时区)
  • 条件逻辑:方向是否写反、>= vs >、短路求值、空判断顺序
  • 错误处理:异常/错误码是否被吞掉;部分失败是否回滚;外层能否捕获
  • 并发与状态:共享可变状态、竞态、锁顺序、幂等
  • 数据一致性:金额/精度运算(浮点陷阱)、事务边界、缓存与库数据一致性
  • 变更影响:是否改到共用函数、是否破坏调用方契约(签名/返回类型)

2. 安全

  • 注入:SQL/命令/XSS(拼接字符串进查询、innerHTML、未转义输出)
  • 认证与越权:改 ID/对象属主即可访问他人数据(IDOR);接口未鉴权
  • 敏感信息:日志/错误/响应泄露 token、密码、密钥、内部堆栈
  • 输入校验:服务端必须校验,不依赖前端;长度/类型/枚举白名单
  • 依赖:是否引入已弃用/可疑包;无必要提升权限

3. 性能

  • 算法/复杂度:循环里查库/正则、O(n²)、可避免的全表扫
  • N+1 查询:ORM 循环内查询 → 批量
  • 资源:数据库连接/文件句柄/内存未释放;长事务;异常路径泄漏
  • 热点:热路径上做无谓分配、序列化、日志

4. 可维护性

  • 命名是否表意;魔法数是否提常量;重复代码是否可合并
  • 函数/方法是否过长、职责单一
  • 死代码:未用 import、未用分支、注释掉的代码(删除而非保留)
  • 是否在正确的一层做事(业务逻辑没漏进 controller/数据层并排放 SQL)

5. 测试

  • 是否覆盖业务主干与关键分支、边界、异常路径
  • 断言是否有效(不是"测试通过但什么都不验证")
  • 是否制造了脆弱的伪测试(依赖顺序、睡 sleep、测实现细节而非行为)

6. 架构与一致性

  • 是否符合项目既有分层、命名、错误处理、日志规范
  • 依赖方向合理;向后兼容性(API/配置/DB 变更)有迁移或灰度
  • 不必要的设计膨胀(为"未来"过度抽象)

评审意见写法

  • 具体到行:"L42:user.name 未判空,此处传 null 会 NPE,建议 user?.name ?: "匿名""
  • 给出动机:说明为什么(安全/正确性/可读),不是"我觉得"
  • 先肯定亮点后提问题,可商量事项明确说"可不改"
  • 不贴"重写这段吧";给最小改法或替代方案

常见错误

错误 修正
只看风格忽略正确性 先正确性/安全,再可维护,最后风格
所有意见一个档次 分级标注,阻断级才要求阻塞合并
无背景盲审 先读 PR 描述与关联需求
放大镜下挑错不漏主干缺陷 主干边界/越权/异常路径优先于命名
橡皮图章式"LGTM" 至少过一遍六个维度并在关键分支表态
空泛评价"可以优化下" 给行号+示例+改法

检查清单(输出前自查)

  • [ ] 读懂了变更意图并写进结论开场
  • [ ] 六个维度均过一遍(哪怕各一句"无问题")
  • [ ] 正确性、安全维度无 🔴 遗漏
  • [ ] 每条意见有行号/代码引用与建议改法
  • [ ] 分级明确:阻断/建议/细节
  • [ ] 语言建设性,有动机说明、不居高临下
  • [ ] 测试维度查看是否覆盖主干与分支

Current listing version

1.1.3

Verify the source revision ↗

Safety and assessment details

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value95/100

Highlights

  • 高价值高频刚需工具,直接解决开发者代码合并前质量把关的核心痛点
  • 覆盖六大评审维度,提供分级意见体系,显著提升评审效率与质量
  • 适用于后端、前端、脚本等多种代码类型,受众广泛
Trigger Precision95/100

Highlights

  • 触发场景描述完整,涵盖 review 代码/diff/PR/MR 等多种使用情境
  • 支持模糊意图触发,降低用户使用门槛
  • 明确排除不适用场景,边界清晰
Structure and Standards95/100

Highlights

  • 流程步骤清晰完整,从理解意图到输出意见形成闭环
  • frontmatter 完整规范,包含必要元数据
  • 提供自查清单和常见错误修正表,增强实用性
Execution Reliability95/100

Highlights

  • 六维度清单具体可操作,分级标准明确
  • 提供输出前自查机制,确保评审质量
  • 执行流程闭环,无关键漏洞
Evidence Verifiability (mean of the first four)95/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

  • Accounts, secrets or authorization

    Use a dedicated least-privilege account. Keep secrets out of public content and command logs; verify the receiving service and tenant.

    Mentioned in main document · lines 51

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.