Review code against specs, designs, and decision compliance
/plugin marketplace add asermax/claude-plugins/plugin install katachi@asermax-plugins[context]Review code for spec compliance and pattern adherence.
Context: $ARGUMENTS (optional - can be: branch, files, or description of what to review)
Skill to load:
Load the katachi:framework-core skill for workflow principles.
Decision indexes:
@docs/architecture/README.md - Architecture decisions (ADRs)
@docs/design/README.md - Design patterns (DES)
Read relevant specs/ and designs/ based on code being reviewed.
Based on input, determine what to review:
If branch specified:
git diff main...$BRANCH
If files specified:
If description specified:
If no input:
For the code being reviewed:
If documentation can't be identified:
"I see changes in [files]. Which feature is this for?
Or should I do a general code review without spec reference?"
Task(
subagent_type="katachi:code-reviewer",
prompt=f"""
Review this code.
## Code to Review
{code_content}
## Feature Spec (if applicable)
{spec_content or "No spec identified"}
## Feature Design (if applicable)
{design_content or "No design identified"}
## Relevant ADRs
{adr_content}
## Relevant DES Patterns
{des_content}
Provide structured critique covering:
- Acceptance criteria satisfaction (if spec provided)
- Design alignment (if design provided)
- Pattern compliance with ADRs/DES
- General code quality
"""
)
Show review results organized by severity:
## Code Review Results
### Critical Issues
- [Issue]: [location] - [recommendation]
### Important Issues
- [Issue]: [location] - [recommendation]
### Suggestions
- [Suggestion]
### Pattern Compliance
- ADR-007 (logging): Compliant
- DES-003 (testing): Violation at tests/test_x.py:45
### Strengths
- [What's done well]
For each issue:
Ask: "Would you like me to help fix any of these issues?"
If user wants fixes:
This is a review process: