当设计或修改 REST API 响应结构、处理 API 返回值时触发。防止 API 设计缺陷导致的字段错位、类型歧义等问题。
The English summary is being prepared. Showing the original description.
结构化代码审查工作流,适用于显式 quick/full/security review;不负责普通实现或 bug 修复流程。
The English summary is being prepared. Showing the original description.
See how to installReview the instructions the agent will receive before you install.
当用户明确要求 review、quick review 或 security review 时,使用本技能。
不要用于:
用户可以指定审查目标:
$cc-review、$cc-review quick、$cc-review security$cc-review <commit-hash>、$cc-review quick <commit-hash>、$cc-review security <commit-hash>参数解析规则:
$cc-review quick abc123 或 $cc-review abc123 quick 均可)面向当前 diff 或指定提交,快速给出高价值反馈。
Git 命令:
git diff --stat + git diffgit show --stat <commit> + git show <commit>围绕受影响调用链、输入输出契约和回归面做更完整的审查。
Git 命令:
git diff --merge-base origin/HEADgit show <commit>重点检查认证授权、输入校验、命令执行、数据暴露和权限边界。
Git 命令:
git diff --merge-base origin/HEADgit show <commit>当用户指定 commit hash 时,必须先验证其有效性:
# 验证 commit 是否存在
if ! git rev-parse --verify "$TARGET^{commit}" >/dev/null 2>&1; then
echo "❌ 错误:无效的 commit hash: $TARGET"
echo ""
echo "请检查:"
echo "1. commit hash 是否正确(可以是完整 hash 或短 hash)"
echo "2. commit 是否存在于当前仓库"
echo ""
echo "提示:使用 'git log' 查看可用的 commit"
exit 1
fi
# 获取完整 hash 和提交信息
FULL_HASH=$(git rev-parse "$TARGET")
COMMIT_MSG=$(git log -1 --pretty=format:"%s" "$TARGET")
审查报告开头应包含审查范围信息:
### 审查范围
**提交**: `<full-hash>`
**信息**: <commit-message>
**作者**: <author-name> <<author-email>>
**时间**: <commit-date>
references/quick-review.md 与 references/full-review.md。references/review-priority.mdreferences/quick-review.mdreferences/full-review.mdreferences/security-review.mdNo reviews yet. Tell others what you thought.
No login needed. Share how it worked for you, ask a question, or note where it did not run.
No comments yet. Be the first to write one.
当设计或修改 REST API 响应结构、处理 API 返回值时触发。防止 API 设计缺陷导致的字段错位、类型歧义等问题。
The English summary is being prepared. Showing the original description.
当设计或修改 REST API 响应结构、处理 API 返回值,或生成 Excel/CSV/PDF/对账文件等下游产物时触发。防止 API 设计缺陷导致的字段错位、类型歧义,以及生成产物时关键字段缺失但静默成功的问题。
The English summary is being prepared. Showing the original description.
网关/代理/WAF/CDN 中间件的安全关键词匹配实现规范,防止纯子串匹配误判正常响应内容中的技术术语(如 Cloudflare、502、error)
The English summary is being prepared. Showing the original description.
当 API/任务可能执行超过 10 秒(批量数据处理、远程 API 批量调用、全表扫描、跨租户聚合)时触发。防止同步接口被网关 30s 超时切断、用户重复点击触发并发、状态缓存内存泄漏等问题。提供异步任务状态机标准模板。
The English summary is being prepared. Showing the original description.
Bash 脚本与系统命令规范。禁止行尾注释,强制使用 tee/heredoc 写入,提升命令执行的可维护性。
The English summary is being prepared. Showing the original description.
当用户操作 .sh、Dockerfile、Makefile、.yml、.yaml 文件,或在 Markdown 中编写 bash 代码块时触发。提供 Bash 编写规范。
The English summary is being prepared. Showing the original description.