mirror of
https://github.com/Donchitos/Claude-Code-Game-Studios.git
synced 2026-06-27 04:51:46 +00:00
* Add /vertical-slice skill, prototype overhaul, and workflow integration - Add /vertical-slice skill for pre-production validation (Phase 4 gate) - Overhaul /prototype skill with two-mode design: concept prototype (Phase 1) vs vertical slice (Phase 4), with clearer differentiation and higher standards for VS - Update prototyper agent to own both prototype and vertical-slice workflows - Add prototype-report.md and vertical-slice-report.md output templates - Update WORKFLOW-GUIDE, quick-start, skills-reference, agent-coordination-map, and skill-flow-diagrams to fully integrate both skills into the 7-phase pipeline - Remove orphaned empty quick-prototype/ directory Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * sync v1 counts + polish Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Add entity inventory flow, relax vertical-slice gate, improve UX authoring prompts - /asset-spec: new Phase 0b entity & screen inventory when no argument and no existing inventory — reads GDDs/art-bible, proposes categorized list, writes design/assets/entity-inventory.md collaboratively - /asset-spec: entity/character target falls back to inline user description when no source doc exists, rather than failing - /gate-check: vertical slice changed from blocking to CONCERNS-only when absent; built-but-broken slice still fails; adds entity inventory as gate artifact - /ux-design: convert inline approval prompts to AskUserQuestion for structured option capture at key authoring decision points - workflow-catalog.yaml: entity-inventory step added to pre-production; UX spec min_count raised to 3; vertical-slice and prototype marked required: false with updated descriptions - .gitignore: exclude marrow/ eval tooling directory Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * Add missing AskUserQuestion widgets to 7 skills Audit found 11 decision points across 7 skills where structured option prompts were missing — using plain text, auto-selection, or no gate at all. Skills patched: - create-epics: per-epic approval + producer CONCERNS verdict - sprint-plan: producer CONCERNS verdict with scope/timeline options - milestone-review: AT RISK / OFF TRACK producer verdicts require acknowledgement - retrospective: existing-retro handling converted from plain text [A]/[B] - quick-design: classification confirmation + draft approve/revise/redirect - tech-debt add mode: category (6 options) + effort (S/M/L/XL) structured capture - regression-suite: no-arg mode selection instead of silent auto-detect - hotfix: severity confirmation gate before workflow begins Also added AskUserQuestion to allowed-tools headers for retrospective, quick-design, tech-debt, regression-suite, and hotfix. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * Prep v1 stable: fix WORKFLOW-GUIDE counts, stale agent names, and skill model fields - WORKFLOW-GUIDE.md: correct agent count (48→49), skill count (66/68→73), add 6 missing skills to Appendix B, fix Creative category count (2→4), replace 3 non-existent agent names with correct ue-*/unity-* specialists, add missing godot-csharp/gdextension specialists to hierarchy, fix production/stories/ paths → production/epics/ - coordination-rules.md: replace "not yet used" with opt-in env var note - quick-start.md: rename duplicate "Validate the concept" label → "Prototype the mechanic" - skill-flow-diagrams.md: remove duplicate legacy UX pipeline section - All 62 skills missing model: field now have explicit model: sonnet Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix: comprehensive skill audit — consistency, UX, and flow gaps Two-pass audit fixing ~35 bugs across 41 files. Pre-production flow: - Brainstorm next-steps split into Path A (design-first) and Path B (prototype-first) — eliminates "prototype after architecture" confusion - /architecture-review added to pre-production flow in brainstorm and create-architecture handoffs - gate-check traceability check corrected to requirements-traceability.md - dev-story TR registry error now points to /architecture-review (not /create-epics) - start now writes production/stage.txt on first onboarding AskUserQuestion gaps filled: - balance-check, code-review, hotfix, day-one-patch, consistency-check all gain closing widgets and/or missing allowed-tools declarations - hotfix git branch creation now requires user confirmation - sprint-plan review-mode setup moved to Phase 0 (before gates run) - team-combat gains architecture→implementation approval gate - design-review APPROVED path consolidated from 3 widgets to 1 multiSelect All 9 team-* skills: - Phase 0 review-mode resolution added (solo/lean/full now respected) - team-audio output path fixed (design/gdd/ → design/audio/) - team-level final doc compilation delegated to level-designer subagent - team-narrative localization-lead added to composition list - team-qa sprint path fixed (flat files, not directories) - team-release NO-GO override captures written justification - team-live-ops Cancel verdict now explicitly BLOCKED Other fixes: - Art bible path standardized to design/art/art-bible.md (3 wrong refs) - AD-PHASE-GATE added to lean-mode skip list in director-gates.md - design-system duplicate 5d heading fixed; skeleton decline path added; mandatory agent spawns now respect review mode - story-readiness acceptance criteria thresholds now type-aware - create-stories gains multi-ADR and no-ADR handling guidance - consistency-check creates docs/consistency-failures.md on first run - retrospective frontmatter bash injection replaced with explicit Bash call - smoke-check ls -t gains PowerShell fallback - Conventional Commits format documented in coding-standards.md - gate-check: ADR acceptance gate, QA plan check, chain-of-verification tool-action requirement all added Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix: expose --review flag in argument-hints for all team-* skills All 9 team-* skills already implement Phase 0 review-mode resolution internally (full/lean/solo), but none advertised [--review full|lean|solo] in their argument-hint. Users had no way to discover the per-run override. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs: add SECURITY.md with coordinated disclosure policy Defines scope, reporting process (GitHub private vulnerability reporting), contributor security guidelines for hooks/skills/agents, and 90-day coordinated disclosure timeline. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs: add CONTRIBUTING.md with framework contribution guidelines Covers what PRs are welcome, skill/hook/agent technical requirements, the collaborative principle, testing expectations, commit format, and platform compatibility requirements. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * docs: add v1.0.0-beta → v1.0 upgrade section to UPGRADING.md Documents the 17 commits since the beta tag: new /vertical-slice gate, entity inventory flow in /map-systems, AskUserQuestion widgets across 7 skills, --review flag exposure on team-* skills, bug fixes (#21, #36, #42, #43, #45), and the new CONTRIBUTING.md and SECURITY.md. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
186 lines
7.5 KiB
Markdown
186 lines
7.5 KiB
Markdown
---
|
|
name: code-review
|
|
description: "Performs an architectural and quality code review on a specified file or set of files. Checks for coding standard compliance, architectural pattern adherence, SOLID principles, testability, and performance concerns."
|
|
argument-hint: "[path-to-file-or-directory]"
|
|
user-invocable: true
|
|
allowed-tools: Read, Glob, Grep, Bash, Task, AskUserQuestion
|
|
model: sonnet
|
|
agent: lead-programmer
|
|
---
|
|
|
|
## Phase 1: Load Target Files
|
|
|
|
Read the target file(s) in full. Read CLAUDE.md for project coding standards.
|
|
|
|
---
|
|
|
|
## Phase 2: Identify Engine Specialists
|
|
|
|
Read `.claude/docs/technical-preferences.md`, section `## Engine Specialists`. Note:
|
|
|
|
- The **Primary** specialist (used for architecture and broad engine concerns)
|
|
- The **Language/Code Specialist** (used when reviewing the project's primary language files)
|
|
- The **Shader Specialist** (used when reviewing shader files)
|
|
- The **UI Specialist** (used when reviewing UI code)
|
|
|
|
If the section reads `[TO BE CONFIGURED]`, no engine is pinned — skip engine specialist steps.
|
|
|
|
---
|
|
|
|
## Phase 3: ADR Compliance Check
|
|
|
|
**Argument:** `/code-review [file(s)]` may optionally include a story file path as the last argument (e.g., `/code-review src/combat/attack.gd production/epics/combat/story-001.md`). If a story path is provided, read it to extract the governing ADR reference.
|
|
|
|
Search for ADR references in, in priority order:
|
|
1. The story file (if provided as argument)
|
|
2. Header comments at the top of the implementation files
|
|
3. Commit messages referencing these files (`git log --oneline -- [file]`)
|
|
|
|
Look for patterns like `ADR-NNN` or `docs/architecture/ADR-`.
|
|
|
|
If no ADR references found, note: "No ADR references found — ADR compliance check skipped. For full ADR compliance review, provide the story path: `/code-review [files] [story-path]`."
|
|
|
|
For each referenced ADR: read the file, extract the **Decision** and **Consequences** sections, then classify any deviation:
|
|
|
|
- **ARCHITECTURAL VIOLATION** (BLOCKING): Uses a pattern explicitly rejected in the ADR
|
|
- **ADR DRIFT** (WARNING): Meaningfully diverges from the chosen approach without using a forbidden pattern
|
|
- **MINOR DEVIATION** (INFO): Small difference from ADR guidance that doesn't affect overall architecture
|
|
|
|
---
|
|
|
|
## Phase 4: Standards Compliance
|
|
|
|
Identify the system category (engine, gameplay, AI, networking, UI, tools) and evaluate:
|
|
|
|
- [ ] Public methods and classes have doc comments
|
|
- [ ] Cyclomatic complexity under 10 per method
|
|
- [ ] No method exceeds 40 lines (excluding data declarations)
|
|
- [ ] Dependencies are injected (no static singletons for game state)
|
|
- [ ] Configuration values loaded from data files
|
|
- [ ] Systems expose interfaces (not concrete class dependencies)
|
|
|
|
---
|
|
|
|
## Phase 5: Architecture and SOLID
|
|
|
|
**Architecture:**
|
|
- [ ] Correct dependency direction (engine <- gameplay, not reverse)
|
|
- [ ] No circular dependencies between modules
|
|
- [ ] Proper layer separation (UI does not own game state)
|
|
- [ ] Events/signals used for cross-system communication
|
|
- [ ] Consistent with established patterns in the codebase
|
|
|
|
**SOLID:**
|
|
- [ ] Single Responsibility: Each class has one reason to change
|
|
- [ ] Open/Closed: Extendable without modification
|
|
- [ ] Liskov Substitution: Subtypes substitutable for base types
|
|
- [ ] Interface Segregation: No fat interfaces
|
|
- [ ] Dependency Inversion: Depends on abstractions, not concretions
|
|
|
|
---
|
|
|
|
## Phase 6: Game-Specific Concerns
|
|
|
|
- [ ] Frame-rate independence (delta time usage)
|
|
- [ ] No allocations in hot paths (update loops)
|
|
- [ ] Proper null/empty state handling
|
|
- [ ] Thread safety where required
|
|
- [ ] Resource cleanup (no leaks)
|
|
|
|
---
|
|
|
|
## Phase 7: Specialist Reviews (Parallel)
|
|
|
|
Spawn all applicable specialists simultaneously via Task — do not wait for one before starting the next.
|
|
|
|
### Engine Specialists
|
|
|
|
If an engine is configured, determine which specialist applies to each file and spawn in parallel:
|
|
|
|
- Primary language files (`.gd`, `.cs`, `.cpp`) → Language/Code Specialist
|
|
- Shader files (`.gdshader`, `.hlsl`, shader graph) → Shader Specialist
|
|
- UI screen/widget code → UI Specialist
|
|
- Cross-cutting or unclear → Primary Specialist
|
|
|
|
Also spawn the **Primary Specialist** for any file touching engine architecture (scene structure, node hierarchy, lifecycle hooks).
|
|
|
|
### QA Testability Review
|
|
|
|
For Logic and Integration stories, also spawn `qa-tester` via Task in parallel with the engine specialists. Pass:
|
|
- The implementation files being reviewed
|
|
- The story's `## QA Test Cases` section (the pre-written test specs from qa-lead)
|
|
- The story's `## Acceptance Criteria`
|
|
|
|
Ask the qa-tester to evaluate:
|
|
- [ ] Are all test hooks and interfaces exposed (not hidden behind private/internal access)?
|
|
- [ ] Do the QA test cases from the story's `## QA Test Cases` section map to testable code paths?
|
|
- [ ] Are any acceptance criteria untestable as implemented (e.g., hardcoded values, no seam for injection)?
|
|
- [ ] Does the implementation introduce any new edge cases not covered by the existing QA test cases?
|
|
- [ ] Are there any observable side effects that should have a test but don't?
|
|
|
|
For Visual/Feel and UI stories: qa-tester reviews whether the manual verification steps in `## QA Test Cases` are achievable with the implementation as written — e.g., "is the state the manual checker needs to reach actually reachable?"
|
|
|
|
Collect all specialist findings before producing output.
|
|
|
|
---
|
|
|
|
## Phase 8: Output Review
|
|
|
|
```
|
|
## Code Review: [File/System Name]
|
|
|
|
### Engine Specialist Findings: [N/A — no engine configured / CLEAN / ISSUES FOUND]
|
|
[Findings from engine specialist(s), or "No engine configured." if skipped]
|
|
|
|
### Testability: [N/A — Visual/Feel or Config story / TESTABLE / GAPS / BLOCKING]
|
|
[qa-tester findings: test hooks, coverage gaps, untestable paths, new edge cases]
|
|
[If BLOCKING: implementation must expose [X] before tests in ## QA Test Cases can run]
|
|
|
|
### ADR Compliance: [NO ADRS FOUND / COMPLIANT / DRIFT / VIOLATION]
|
|
[List each ADR checked, result, and any deviations with severity]
|
|
|
|
### Standards Compliance: [X/6 passing]
|
|
[List failures with line references]
|
|
|
|
### Architecture: [CLEAN / MINOR ISSUES / VIOLATIONS FOUND]
|
|
[List specific architectural concerns]
|
|
|
|
### SOLID: [COMPLIANT / ISSUES FOUND]
|
|
[List specific violations]
|
|
|
|
### Game-Specific Concerns
|
|
[List game development specific issues]
|
|
|
|
### Positive Observations
|
|
[What is done well -- always include this section]
|
|
|
|
### Required Changes
|
|
[Must-fix items before approval — ARCHITECTURAL VIOLATIONs always appear here]
|
|
|
|
### Suggestions
|
|
[Nice-to-have improvements]
|
|
|
|
### Verdict: [APPROVED / APPROVED WITH SUGGESTIONS / CHANGES REQUIRED]
|
|
```
|
|
|
|
This skill is read-only — no files are written.
|
|
|
|
---
|
|
|
|
## Phase 9: Next Steps
|
|
|
|
Use `AskUserQuestion`:
|
|
- Prompt: "Code review complete — verdict: [APPROVED / CHANGES REQUIRED / MAJOR REVISION]. How would you like to proceed?"
|
|
- Options (adjust based on verdict):
|
|
- If APPROVED:
|
|
- `[A] Run /story-done to mark the story complete`
|
|
- `[B] Stop here`
|
|
- If CHANGES REQUIRED or MAJOR REVISION:
|
|
- `[A] Fix the issues and re-run /code-review`
|
|
- `[B] Run /story-done anyway with noted exceptions`
|
|
- `[C] Stop here`
|
|
|
|
If an ARCHITECTURAL VIOLATION is found:
|
|
- If the violation contradicts an **existing ADR**: fix the implementation to comply with `docs/architecture/[adr-file].md`. If the design has legitimately changed, run `/architecture-decision` to formally *revise* the existing ADR — do not create a competing one.
|
|
- If **no ADR exists** for the pattern that was violated: run `/architecture-decision` to document the correct approach before fixing the code.
|