Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
A direct command skips the review prompt. Inspect the source before running it.
โก Are glossary.md terms consistently used in code?
- Business terms โ Code naming matching
- Global standard terms โ API response field names matching
โก Do entity definitions match actual types?
โก Do relationship definitions match actual implementation?
โก Are design tokens defined? (CSS Variables / ThemeData)
โก Do components use tokens? (no hardcoded colors)
โก Are component variants consistent?
โก Dark mode support (if defined)
โก API client layer structure compliance
- Components โ hooks โ services โ apiClient
- No direct fetch calls
โก Type consistency
- Phase 4 API spec types = Phase 6 client types
โก Error handling consistency
- Global error handler usage
- Error code-specific handling logic
โก State management pattern consistency
Phase 7 โ Verify: Security/SEO Application
โก Authentication/authorization middleware applied
โก Input validation (server-side)
โก XSS, CSRF defense
โก No sensitive info exposed to client
โก SEO meta tags applied
โก Is there business logic in components?
โก Are there direct API calls? (should go through hooks)
โก Is state management properly separated?
โก Do components have single responsibility?
Application Layer (Services)
โก Are domain logic and infrastructure logic separated?
โก Are external dependencies abstracted?
โก Is the structure testable?
โก Are use cases clearly defined?
Domain Layer (Types/Entities)
โก Are there no external library dependencies?
โก Does it contain only pure business rules?
โก Do types match Phase 1 schema?
Infrastructure Layer (API Client)
โก Are external service calls abstracted?
โก Is error handling consistent?
โก Is configuration managed via environment variables?
Architecture Review Checklist
Structure
Does folder structure match conventions
Is separation of concerns well done
Is dependency direction correct (outside โ inside)
Patterns
Are consistent patterns used
Is there unnecessary abstraction
Is proper encapsulation done
Convention Review Checklist
Naming
Does it follow Phase 2 defined rules
Are meaningful names used
Is there consistency
Code Style
Unified indentation, quotes, etc.
Is file length appropriate
Is function length appropriate
Code Quality Checklist
Is there duplicate code
Are there highly complex functions
Is error handling appropriate
Is type safety ensured
AI-Assisted Review
Request code review from Claude:
"Review this project's code.
- Does it follow CONVENTIONS.md rules
- Is there architecture consistency
- Are there potential bugs or improvements"
Template
See templates/pipeline/phase-8-review.template.md
Next Phase
Phase 9: Deployment โ After review completion, deploy to production
6. In-Depth Code Quality Review
6.1 Duplicate Code Detection
Detection Methods
# 1. Search for similar function names
grep -r "function.*format" src/
grep -r "function.*calculate" src/
grep -r "function.*get.*By" src/
# 2. Search for similar patterns
grep -rn "reduce.*sum" src/
grep -rn "filter.*map" src/
grep -rn "useState.*useEffect" src/
Handling by Duplication Type
Type
Example
Solution
Exact duplicate
Same code copy-paste
Extract to function
Structural similarity
Same logic, different data
Parameterize
Conceptual similarity
Different implementations for similar purpose
Integrate or interface
Duplicate Code Checklist
โก Is the same logic in 2+ places?
โก Are there multiple functions with similar names?
โก Is the same data transformation repeated?
โก Are similar UI patterns repeated?
โก Is the same API call pattern repeated?
โก Is similar error handling repeated?
6.2 Reusability Assessment
Assessment Criteria
Score
Criteria
Description
โญโญโญ
High
Can be used in other projects
โญโญ
Medium
Can be used in multiple places within same project
โญ
Low
Used only for specific feature
Reusability Checklist
Check for each function/component:
โก Is it tied to a specific domain?
โก Does it depend on external state?
โก Are parameters generic?
โก Is the return value predictable?
โก Are there side effects?
6.3 Extensibility Assessment
Extensibility Check
When new requirements come:
โก Can it be added without modifying existing code?
โก Can behavior be changed by configuration only?
โก Is adding new types/cases easy?
โก Can it be extended without adding conditionals?
Extensibility Anti-patterns
// โ Requires modification for each extensionfunctionprocess(type: string) {
if (type === 'a') { /* ... */ }
elseif (type === 'b') { /* ... */ }
// Add else if for each new type...
}
// โ Hardcoded listconstALLOWED_TYPES = ['a', 'b', 'c']
// โ Enumerated switch statementsswitch (action.type) {
case'ADD': // ...case'REMOVE': // ...// Add case for each new action...
}
โก Does the class/function change for only one reason?
โก Does the name clearly explain the role?
โก Is "and" in the name? โ Needs separation
O - Open/Closed (OCP)
โก Is it open for extension? (new features can be added)
โก Is it closed for modification? (no existing code changes needed)
โก Are interfaces/abstractions used?
L - Liskov Substitution (LSP)
โก Can subtypes replace parent types?
โก Do overridden methods keep the contract?
I - Interface Segregation (ISP)
โก Is the interface too large?
โก Must unused methods be implemented?
โก Can the interface be split smaller?
D - Dependency Inversion (DIP)
โก Does it depend on abstractions instead of concrete classes?
โก Are dependencies injected? (DI)
โก Is the structure testable?
6.5 Refactoring Priority
Urgent (Required before deployment):
1. Duplication that can cause bugs
2. Security vulnerabilities
3. Performance bottlenecks
High (As soon as possible):
4. Same logic duplicated in 3+ places
5. Files over 200 lines
6. Nesting deeper than 5 levels
Medium (Next sprint):
7. Structure lacking extensibility
8. Naming inconsistencies
9. Structure difficult to test
Low (Backlog):
10. Style inconsistencies
11. Excessive comments
12. Unused code
7. AI Code Review Request Template
Please review the code from these perspectives:
1. Duplicate Code
- Are there similar functions/components?
- Is there common logic that can be extracted?
2. Reusability
- Can it be used generically?
- Is it tied to a specific domain?
3. Extensibility
- Can it flexibly respond to new requirements?
- Are there hardcoded parts?
4. SOLID Principles
- Does it follow single responsibility?
- Is it open for extension and closed for modification?
5. Convention Compliance
- Does it follow CONVENTIONS.md rules?
- Is naming consistent?
Please identify parts that need refactoring and their priority.
8. Gap Analysis (Design vs Implementation)
Gap Analysis Report Template
# Gap Analysis Report## Analysis Target- Design document: docs/02-design/{feature}.design.md
- Implementation path: src/features/{feature}/
## Results by Category### API Endpoints
| Design | Implementation | Status |
|--------|----------------|--------|
| POST /api/users | POST /api/users | โ Match |
| GET /api/users/:id | - | โ Not implemented |
| - | DELETE /api/users/:id | โ ๏ธ Missing from design |
### Data Model
| Design Entity | Implementation | Status |
|---------------|----------------|--------|
| User | types/user.ts | โ Match |
| UserRole | - | โ Not implemented |
### Match Rate- Total items: 10
- Matches: 7
- Not implemented: 2
- Missing from design: 1
-**Match Rate: 70%**