بنقرة واحدة
code-review
Review current git changes or latest commit using code-reviewer and architect-reviewer agents
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Review current git changes or latest commit using code-reviewer and architect-reviewer agents
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
| name | code-review |
| description | Review current git changes or latest commit using code-reviewer and architect-reviewer agents |
| allowed-tools | Bash(git status:*), Bash(git diff:*), Bash(git log:*), Bash(git show:*), Task |
| disable-model-invocation | true |
Perform comprehensive code review of current changes or latest commit. Automatically invokes:
Check for uncommitted changes:
git status --porcelain
Decision:
git diffgit log -1 and git show HEADExtract metrics from git output:
Count:
Detect:
migrations/, schema.prisma, *.sql)*.graphql, openapi.yaml, API route files)package.json, go.mod, docker-compose.yml)Always execute using Task tool with subagent_type: "code-reviewer":
Perform comprehensive code review of the current changes.
Focus areas:
- Code quality: readability, naming, structure
- Security: exposed secrets, input validation, vulnerability patterns
- Error handling: edge cases, error messages, recovery
- Performance: obvious bottlenecks, inefficient patterns
- Testing: coverage for critical paths
- Coding standards compliance
Changes to review:
{paste git diff or git show output}
Provide feedback organized by:
- Critical issues (must fix before merge)
- Warnings (should fix)
- Suggestions (consider improving)
Include specific code examples and fix recommendations.
The code-reviewer agent has access to Read, Write, Edit, Bash, and Grep tools and will analyze the code thoroughly.
Scope Classification Criteria (score each criterion met):
| Criterion | Threshold | Score |
|---|---|---|
| Files Modified | ≥ 8 files | +1 |
| Total Lines Changed | ≥ 300 lines | +1 |
| Directories Affected | ≥ 3 directories | +1 |
| New Module/Package | New directory with ≥3 files | +1 |
| API Contract Changes | Modified: schema/, .graphql, api/, route files | +1 |
| Database Schema | Modified: migrations, schema files, ORM models | +1 |
| Config/Infrastructure | Modified: docker-compose, Dockerfile, K8s, CI/CD | +1 |
| Dependency Changes | Modified: package.json, go.mod, requirements.txt | +1 |
Decision:
code-reviewer onlycode-reviewer and architect-reviewerRequest architect-reviewer using Task tool with subagent_type: "architect-reviewer":
Perform architectural review of these changes.
Change scope:
- Files changed: {count}
- Lines: +{added} -{removed}
- Directories affected: {list}
- Scope score: {X}/8
- Triggered by: {list of criteria met}
Evaluate:
- System design impact
- Scalability implications
- Technology choice justification
- Integration pattern soundness
- Security architecture
- Technical debt introduced/resolved
- Evolution path clarity
Provide strategic recommendations prioritized by:
- Critical architectural risks
- Design improvement opportunities
- Long-term maintainability concerns
Changes to review:
{paste git diff or git show output}
The architect-reviewer agent has access to Read, Write, Edit, Bash, Glob, and Grep tools for comprehensive analysis.
Generate consolidated review summary:
# Code Review Report
**Generated**: {timestamp}
**Scope**: {uncommitted changes / latest commit: {hash}}
**Files Changed**: {count}
**Reviewers Invoked**: code-reviewer{, architect-reviewer if applicable}
---
## 📊 Change Summary
- **Lines**: +{added} -{removed}
- **Files**: {count} ({new_count} new, {modified_count} modified)
- **Directories**: {affected directories}
---
## 🔍 Code Reviewer Feedback
{consolidated output from code-reviewer agent}
---
## 🏗️ Architecture Reviewer Feedback
{if invoked, consolidated output from architect-reviewer agent}
{if not invoked, state: "Architectural review not required for this change scope"}
---
## ✅ Review Checklist
Based on agent feedback, generate action items:
### Critical (Must Fix)
- [ ] {issue 1}
- [ ] {issue 2}
### High Priority (Should Fix)
- [ ] {issue 3}
### Suggestions (Consider)
- [ ] {improvement 1}
---
## 📝 Next Steps
{recommended actions based on review results}
# Review uncommitted changes
/code-review
# Review specific commit (pass commit hash in conversation)
# User: "Review commit abc123"
# Then: /code-review
git status --porcelain to detect changesgit diff to get uncommitted changesgit diff --stat for metricsgit log -1 --oneline to get latest commitgit show HEAD to get commit changesgit show HEAD --stat for metricsToken optimization:
git diff --stat and git show --stat for metrics (avoid full diff parsing)Transform verbose natural language requests into structured bilingual documentation (Korean for review + English for AI prompts)
Review comments and suggest cleanup (identify unnecessary comments, recommend improvements)
Generate Conventional Commits-compliant messages (feat/fix/docs/chore) in Korean and English
Identify and safely remove dead code, deprecated code, and unused exports from codebase
Generate business rule documentation from domain knowledge and requirements
Implement UI E2E tests sequentially using Playwright MCP, stop on bug discovery