thanh-kit 2.5.1 → 2.5.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +50 -61
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/templates/{commands → command-archive}/ask.md +5 -5
- package/templates/{commands → command-archive}/ck-help.md +18 -2
- package/templates/command-archive/docs/init.md +38 -0
- package/templates/command-archive/docs/summarize.md +22 -0
- package/templates/command-archive/docs/update.md +76 -0
- package/templates/command-archive/journal.md +18 -0
- package/templates/{commands → command-archive}/kanban.md +5 -7
- package/templates/{commands → command-archive}/plan/archive.md +2 -2
- package/templates/command-archive/plan/red-team.md +200 -0
- package/templates/command-archive/plan/validate.md +188 -0
- package/templates/command-archive/preview.md +283 -0
- package/templates/command-archive/review/codebase/parallel.md +122 -0
- package/templates/{commands → command-archive}/test/ui.md +3 -3
- package/templates/{commands → command-archive}/use-mcp.md +6 -2
- package/templates/command-archive/worktree.md +109 -0
- package/templates/{workflows → rules}/development-rules.md +12 -53
- package/templates/rules/orchestration-protocol.md +43 -0
- package/templates/{workflows → rules}/primary-workflow.md +16 -4
- package/templates/rules/team-coordination-rules.md +90 -0
- package/templates/schemas/ck-config.schema.json +381 -0
- package/templates/commands/README.md +0 -251
- package/templates/commands/bootstrap/auto/fast.md +0 -111
- package/templates/commands/bootstrap/auto/parallel.md +0 -66
- package/templates/commands/bootstrap/auto.md +0 -115
- package/templates/commands/bootstrap.md +0 -137
- package/templates/commands/brainstorm.md +0 -74
- package/templates/commands/build.md +0 -39
- package/templates/commands/checkpoint.md +0 -156
- package/templates/commands/code/auto.md +0 -170
- package/templates/commands/code/no-test.md +0 -158
- package/templates/commands/code/parallel.md +0 -55
- package/templates/commands/code-simplifier.md +0 -71
- package/templates/commands/code.md +0 -176
- package/templates/commands/compact.md +0 -57
- package/templates/commands/content/cro.md +0 -43
- package/templates/commands/content/enhance.md +0 -14
- package/templates/commands/content/fast.md +0 -13
- package/templates/commands/content/good.md +0 -16
- package/templates/commands/context.md +0 -48
- package/templates/commands/cook/auto/fast.md +0 -26
- package/templates/commands/cook/auto/parallel.md +0 -49
- package/templates/commands/cook/auto.md +0 -15
- package/templates/commands/cook/fast.md +0 -47
- package/templates/commands/cook/hard.md +0 -80
- package/templates/commands/cook/parallel.md +0 -90
- package/templates/commands/cook.md +0 -105
- package/templates/commands/create-feature.md +0 -48
- package/templates/commands/db-migrate.md +0 -52
- package/templates/commands/debug.md +0 -13
- package/templates/commands/design/3d.md +0 -83
- package/templates/commands/design/describe.md +0 -23
- package/templates/commands/design/fast.md +0 -31
- package/templates/commands/design/good.md +0 -35
- package/templates/commands/design/screenshot.md +0 -34
- package/templates/commands/design/video.md +0 -34
- package/templates/commands/docs/init.md +0 -39
- package/templates/commands/docs/summarize.md +0 -31
- package/templates/commands/docs/update.md +0 -57
- package/templates/commands/feature.md +0 -62
- package/templates/commands/fix/ci.md +0 -17
- package/templates/commands/fix/fast.md +0 -19
- package/templates/commands/fix/hard.md +0 -39
- package/templates/commands/fix/logs.md +0 -26
- package/templates/commands/fix/parallel.md +0 -54
- package/templates/commands/fix/test.md +0 -20
- package/templates/commands/fix/types.md +0 -9
- package/templates/commands/fix/ui.md +0 -48
- package/templates/commands/fix-issue.md +0 -177
- package/templates/commands/fix.md +0 -43
- package/templates/commands/generate-dto.md +0 -67
- package/templates/commands/git/cm.md +0 -5
- package/templates/commands/git/cp.md +0 -4
- package/templates/commands/git/merge.md +0 -40
- package/templates/commands/git/pr.md +0 -48
- package/templates/commands/integrate/polar.md +0 -28
- package/templates/commands/integrate/sepay.md +0 -28
- package/templates/commands/investigate.md +0 -324
- package/templates/commands/journal.md +0 -7
- package/templates/commands/lint.md +0 -47
- package/templates/commands/migration.md +0 -111
- package/templates/commands/performance.md +0 -110
- package/templates/commands/plan/ci.md +0 -33
- package/templates/commands/plan/cro.md +0 -69
- package/templates/commands/plan/fast.md +0 -86
- package/templates/commands/plan/hard.md +0 -103
- package/templates/commands/plan/parallel.md +0 -152
- package/templates/commands/plan/preview.md +0 -40
- package/templates/commands/plan/two.md +0 -52
- package/templates/commands/plan/validate.md +0 -132
- package/templates/commands/plan.md +0 -36
- package/templates/commands/pr.md +0 -49
- package/templates/commands/preview.md +0 -87
- package/templates/commands/release-notes.md +0 -144
- package/templates/commands/review/post-task.md +0 -157
- package/templates/commands/review-changes.md +0 -46
- package/templates/commands/review.md +0 -56
- package/templates/commands/scout/ext.md +0 -35
- package/templates/commands/scout.md +0 -283
- package/templates/commands/security.md +0 -119
- package/templates/commands/skill/add.md +0 -36
- package/templates/commands/skill/create.md +0 -29
- package/templates/commands/skill/fix-logs.md +0 -22
- package/templates/commands/skill/optimize/auto.md +0 -25
- package/templates/commands/skill/optimize.md +0 -34
- package/templates/commands/skill/plan.md +0 -45
- package/templates/commands/worktree.md +0 -126
- package/templates/memory/session-log.md +0 -186
- package/templates/router/README.md +0 -294
- package/templates/router/agents-guide.md +0 -38
- package/templates/router/commands-guide.md +0 -122
- package/templates/router/decision-flow.md +0 -92
- package/templates/router/skills-guide.md +0 -127
- package/templates/router/workflows-guide.md +0 -68
- package/templates/workflows/README.md +0 -241
- package/templates/workflows/orchestration-protocol.md +0 -16
- /package/templates/{commands → command-archive}/coding-level.md +0 -0
- /package/templates/{commands → command-archive}/review/codebase.md +0 -0
- /package/templates/{commands → command-archive}/test.md +0 -0
- /package/templates/{commands → command-archive}/watzup.md +0 -0
- /package/templates/{workflows → rules}/documentation-management.md +0 -0
|
@@ -1,158 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: ⚡⚡ Start coding an existing plan (no testing)
|
|
3
|
-
argument-hint: [plan]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
**MUST READ** `CLAUDE.md` then **THINK HARDER** to start working on the following plan follow the Orchestration Protocol, Core Responsibilities, Subagents Team and Development Rules:
|
|
7
|
-
<plan>$ARGUMENTS</plan>
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## Role Responsibilities
|
|
12
|
-
- You are a senior software engineer who must study the provided implementation plan end-to-end before writing code.
|
|
13
|
-
- Validate the plan's assumptions, surface blockers, and confirm priorities with the user prior to execution.
|
|
14
|
-
- Drive the implementation from start to finish, reporting progress and adjusting the plan responsibly while honoring **YAGNI**, **KISS**, and **DRY** principles.
|
|
15
|
-
|
|
16
|
-
**IMPORTANT:** Remind these rules with subagents communication:
|
|
17
|
-
- Sacrifice grammar for the sake of concision when writing reports.
|
|
18
|
-
- In reports, list any unresolved questions at the end, if any.
|
|
19
|
-
- Ensure token efficiency while maintaining high quality.
|
|
20
|
-
|
|
21
|
-
---
|
|
22
|
-
|
|
23
|
-
## Step 0: Plan Detection & Phase Selection
|
|
24
|
-
|
|
25
|
-
**If `$ARGUMENTS` is empty:**
|
|
26
|
-
1. Find latest `plan.md` in `./plans` | `find ./plans -name "plan.md" -type f -exec stat -f "%m %N" {} \; 2>/dev/null | sort -rn | head -1 | cut -d' ' -f2-`
|
|
27
|
-
2. Parse plan for phases and status, auto-select next incomplete (prefer IN_PROGRESS or earliest Planned)
|
|
28
|
-
|
|
29
|
-
**If `$ARGUMENTS` provided:** Use that plan and detect which phase to work on (auto-detect or use argument like "phase-2").
|
|
30
|
-
|
|
31
|
-
**Output:** `✓ Step 0: [Plan Name] - [Phase Name]`
|
|
32
|
-
|
|
33
|
-
**Subagent Pattern (use throughout):**
|
|
34
|
-
```
|
|
35
|
-
Task(subagent_type="[type]", prompt="[task description]", description="[brief]")
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
## Workflow Sequence
|
|
41
|
-
|
|
42
|
-
**Rules:** Follow steps 1-6 in order. Each step requires output marker starting with "✓ Step N:". Mark each complete in TodoWrite before proceeding. Do not skip steps.
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
## Step 1: Analysis & Task Extraction
|
|
47
|
-
|
|
48
|
-
Read plan file completely. Map dependencies between tasks. List ambiguities or blockers. Identify required skills/tools and activate from catalog. Parse phase file and extract actionable tasks.
|
|
49
|
-
|
|
50
|
-
**TodoWrite Initialization & Task Extraction:**
|
|
51
|
-
- Initialize TodoWrite with `Step 0: [Plan Name] - [Phase Name]` and all command steps (Step 1 through Step 6)
|
|
52
|
-
- Read phase file (e.g., phase-01-preparation.md)
|
|
53
|
-
- Look for tasks/steps/phases/sections/numbered/bulleted lists
|
|
54
|
-
- MUST convert to TodoWrite tasks:
|
|
55
|
-
- Phase Implementation tasks → Step 2.X (Step 2.1, Step 2.2, etc.)
|
|
56
|
-
- Phase Code Review tasks → Step 3.X (Step 3.1, Step 3.2, etc.)
|
|
57
|
-
- Ensure each task has UNIQUE name (increment X for each task)
|
|
58
|
-
- Add tasks to TodoWrite after their corresponding command step
|
|
59
|
-
|
|
60
|
-
**Output:** `✓ Step 1: Found [N] tasks across [M] phases - Ambiguities: [list or "none"]`
|
|
61
|
-
|
|
62
|
-
Mark Step 1 complete in TodoWrite, mark Step 2 in_progress.
|
|
63
|
-
|
|
64
|
-
---
|
|
65
|
-
|
|
66
|
-
## Step 2: Implementation
|
|
67
|
-
|
|
68
|
-
Implement selected plan phase step-by-step following extracted tasks (Step 2.1, Step 2.2, etc.). Mark tasks complete as done. For UI work, call `ui-ux-designer` subagent: "Implement [feature] UI per ./docs/design-guidelines.md". Use `ai-multimodal` skill for image assets, `imagemagick` for editing. Run type checking and compile to verify no syntax errors.
|
|
69
|
-
|
|
70
|
-
**Output:** `✓ Step 2: Implemented [N] files - [X/Y] tasks complete, compilation passed`
|
|
71
|
-
|
|
72
|
-
Mark Step 2 complete in TodoWrite, mark Step 3 in_progress.
|
|
73
|
-
|
|
74
|
-
---
|
|
75
|
-
|
|
76
|
-
## Step 3: Code Review
|
|
77
|
-
|
|
78
|
-
Call `code-reviewer` subagent: "Review changes for plan phase [phase-name]. Check security, performance, architecture, YAGNI/KISS/DRY". If critical issues found: STOP, fix all, re-run `tester` to verify, re-run `code-reviewer`. Repeat until no critical issues.
|
|
79
|
-
|
|
80
|
-
**Critical issues:** Security vulnerabilities (XSS, SQL injection, OWASP), performance bottlenecks, architectural violations, principle violations.
|
|
81
|
-
|
|
82
|
-
**Output:** `✓ Step 3: Code reviewed - [0] critical issues`
|
|
83
|
-
|
|
84
|
-
**Validation:** If critical issues > 0, Step 3 INCOMPLETE - do not proceed.
|
|
85
|
-
|
|
86
|
-
Mark Step 3 complete in TodoWrite, mark Step 4 in_progress.
|
|
87
|
-
|
|
88
|
-
---
|
|
89
|
-
|
|
90
|
-
## Step 4: User Approval ⏸ BLOCKING GATE
|
|
91
|
-
|
|
92
|
-
Present summary (3-5 bullets): what implemented, code review outcome.
|
|
93
|
-
|
|
94
|
-
**Ask user explicitly:** "Phase implementation complete. Code reviewed. Approve changes?"
|
|
95
|
-
|
|
96
|
-
**Stop and wait** - do not output Step 5 content until user responds.
|
|
97
|
-
|
|
98
|
-
**Output (while waiting):** `⏸ Step 4: WAITING for user approval`
|
|
99
|
-
|
|
100
|
-
**Output (after approval):** `✓ Step 4: User approved - Ready to complete`
|
|
101
|
-
|
|
102
|
-
Mark Step 4 complete in TodoWrite, mark Step 5 in_progress.
|
|
103
|
-
|
|
104
|
-
---
|
|
105
|
-
|
|
106
|
-
## Step 5: Finalize
|
|
107
|
-
|
|
108
|
-
**Prerequisites:** User approved in Step 4 (verified above).
|
|
109
|
-
|
|
110
|
-
1. **STATUS UPDATE - BOTH MANDATORY - PARALLEL EXECUTION:**
|
|
111
|
-
- **Call** `project-manager` sub-agent: "Update plan status in [plan-path]. Mark plan phase [phase-name] as DONE with timestamp. Update roadmap."
|
|
112
|
-
- **Call** `docs-manager` sub-agent: "Update docs for plan phase [phase-name]. Changed files: [list]."
|
|
113
|
-
|
|
114
|
-
2. **ONBOARDING CHECK:** Detect onboarding requirements (API keys, env vars, config) + generate summary report with next steps.
|
|
115
|
-
|
|
116
|
-
3. **AUTO-COMMIT (after steps 1 and 2 completes):**
|
|
117
|
-
- Run only if: Steps 1 and 2 successful + User approved + Tests passed
|
|
118
|
-
- Auto-stage, commit with message [phase - plan] and push
|
|
119
|
-
|
|
120
|
-
**Validation:** Steps 1 and 2 must complete successfully. Step 3 (auto-commit) runs only if conditions met.
|
|
121
|
-
|
|
122
|
-
Mark Step 5 complete in TodoWrite.
|
|
123
|
-
|
|
124
|
-
**Phase workflow finished. Ready for next plan phase.**
|
|
125
|
-
|
|
126
|
-
---
|
|
127
|
-
|
|
128
|
-
## Critical Enforcement Rules
|
|
129
|
-
|
|
130
|
-
**Step outputs must follow unified format:** `✓ Step [N]: [Brief status] - [Key metrics]`
|
|
131
|
-
|
|
132
|
-
**Examples:**
|
|
133
|
-
- Step 0: `✓ Step 0: [Plan Name] - [Phase Name]`
|
|
134
|
-
- Step 1: `✓ Step 1: Found [N] tasks across [M] phases - Ambiguities: [list]`
|
|
135
|
-
- Step 2: `✓ Step 2: Implemented [N] files - [X/Y] tasks complete`
|
|
136
|
-
- Step 3: `✓ Step 3: Code reviewed - [0] critical issues`
|
|
137
|
-
- Step 4: `✓ Step 4: User approved - Ready to complete`
|
|
138
|
-
- Step 5: `✓ Step 5: Finalize - Status updated - Git committed`
|
|
139
|
-
|
|
140
|
-
**If any "✓ Step N:" output missing, that step is INCOMPLETE.**
|
|
141
|
-
|
|
142
|
-
**TodoWrite tracking required:** Initialize at Step 0, mark each step complete before next.
|
|
143
|
-
|
|
144
|
-
**Mandatory subagent calls:**
|
|
145
|
-
- Step 3: `code-reviewer`
|
|
146
|
-
- Step 4: `project-manager` AND `docs-manager` (when user approves)
|
|
147
|
-
|
|
148
|
-
**Blocking gates:**
|
|
149
|
-
- Step 3: Critical issues must be 0
|
|
150
|
-
- Step 4: User must explicitly approve
|
|
151
|
-
- Step 5: Both `project-manager` and `docs-manager` must complete successfully
|
|
152
|
-
|
|
153
|
-
**REMEMBER:**
|
|
154
|
-
- Do not skip steps. Do not proceed if validation fails. Do not assume approval without user response.
|
|
155
|
-
- One plan phase per command run. Command focuses on single plan phase only.
|
|
156
|
-
- You can always generate images with `ai-multimodal` skill on the fly for visual assets.
|
|
157
|
-
- You always read and analyze the generated assets with `ai-multimodal` skill to verify they meet requirements.
|
|
158
|
-
- For image editing (removing background, adjusting, cropping), use `media-processing` skill or similar tools as needed.
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: ⚡ Execute parallel or sequential phases based on plan structure
|
|
3
|
-
argument-hint: [plan-path]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Execute plan: <plan>$ARGUMENTS</plan>
|
|
7
|
-
|
|
8
|
-
**IMPORTANT:** Activate needed skills. Ensure token efficiency. Sacrifice grammar for concision.
|
|
9
|
-
|
|
10
|
-
## Workflow
|
|
11
|
-
|
|
12
|
-
### 1. Plan Analysis
|
|
13
|
-
- Read `plan.md` from given path
|
|
14
|
-
- **Check for:** Dependency graph, Execution strategy, Parallelization Info, File Ownership matrix
|
|
15
|
-
- **Decision:** IF parallel-executable → Step 2A, ELSE → Step 2B
|
|
16
|
-
|
|
17
|
-
### 2A. Parallel Execution
|
|
18
|
-
1. Parse execution strategy (which phases concurrent/sequential, file ownership)
|
|
19
|
-
2. Launch multiple `fullstack-developer` agents simultaneously for parallel phases
|
|
20
|
-
- Pass: phase file path, environment info, file ownership boundaries
|
|
21
|
-
3. Wait for parallel group completion, verify no conflicts
|
|
22
|
-
4. Execute sequential phases (one agent per phase after dependencies)
|
|
23
|
-
5. Proceed to Step 3
|
|
24
|
-
|
|
25
|
-
### 2B. Sequential Execution
|
|
26
|
-
Follow `./.claude/workflows/primary-workflow.md`:
|
|
27
|
-
1. Use main agent step by step
|
|
28
|
-
2. Read `plan.md`, implement phases one by one
|
|
29
|
-
3. Use `project-manager` for progress updates
|
|
30
|
-
4. Use `ui-ux-designer` for frontend
|
|
31
|
-
5. Run type checking after each phase
|
|
32
|
-
6. Proceed to Step 3
|
|
33
|
-
|
|
34
|
-
### 3. Testing
|
|
35
|
-
- Use `tester` for full suite (NO fake data/mocks)
|
|
36
|
-
- If fail: `debugger` → fix → repeat
|
|
37
|
-
|
|
38
|
-
### 4. Code Review
|
|
39
|
-
- Use `code-reviewer` for all changes
|
|
40
|
-
- If critical: fix → retest
|
|
41
|
-
|
|
42
|
-
### 5. Project Management & Docs
|
|
43
|
-
- If approved: `project-manager` + `docs-manager` in parallel (update plans, docs, roadmap)
|
|
44
|
-
- If rejected: fix → repeat
|
|
45
|
-
|
|
46
|
-
### 6. Onboarding
|
|
47
|
-
- Guide user step by step (1 question at a time)
|
|
48
|
-
|
|
49
|
-
### 7. Final Report
|
|
50
|
-
- Summary, guide, next steps
|
|
51
|
-
- Ask to commit (use `git-manager` if yes)
|
|
52
|
-
|
|
53
|
-
**Examples:**
|
|
54
|
-
- Parallel: "Phases 1-3 parallel, then 4" → Launch 3 agents → Wait → Launch 1 agent
|
|
55
|
-
- Sequential: "Phase 1 → 2 → 3" → Main agent implements each phase
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
Simplify and refine code for clarity, consistency, and maintainability.
|
|
2
|
-
|
|
3
|
-
## Scope
|
|
4
|
-
|
|
5
|
-
**Target:** $ARGUMENTS (default: recently modified files)
|
|
6
|
-
|
|
7
|
-
## Simplification Actions
|
|
8
|
-
|
|
9
|
-
| Action | Description |
|
|
10
|
-
|--------|-------------|
|
|
11
|
-
| Reduce nesting | Flatten deep if/else chains with guard clauses |
|
|
12
|
-
| Extract methods | Break long methods into focused units |
|
|
13
|
-
| Simplify conditionals | Use early returns, named booleans |
|
|
14
|
-
| Remove duplication | Apply DRY, use platform patterns |
|
|
15
|
-
| Improve naming | Make code self-documenting |
|
|
16
|
-
|
|
17
|
-
## Workflow
|
|
18
|
-
|
|
19
|
-
1. **Identify targets**
|
|
20
|
-
- If no arguments: `git diff --name-only HEAD~1` for recent changes
|
|
21
|
-
- If arguments provided: use specified files/patterns
|
|
22
|
-
- Skip: generated code, migrations, vendor files
|
|
23
|
-
|
|
24
|
-
2. **Analyze each file**
|
|
25
|
-
- Identify complexity hotspots (nesting > 3, methods > 20 lines)
|
|
26
|
-
- Find duplicated code patterns
|
|
27
|
-
- Check naming clarity
|
|
28
|
-
|
|
29
|
-
3. **Apply simplifications**
|
|
30
|
-
- One refactoring type at a time
|
|
31
|
-
- Preserve all functionality
|
|
32
|
-
- Follow platform patterns
|
|
33
|
-
|
|
34
|
-
4. **Verify**
|
|
35
|
-
- Run related tests if available
|
|
36
|
-
- Confirm no behavior changes
|
|
37
|
-
|
|
38
|
-
## Platform Patterns to Apply
|
|
39
|
-
|
|
40
|
-
### Backend (C#)
|
|
41
|
-
- Extract to `Entity.XxxExpr()` static expressions
|
|
42
|
-
- Use fluent helpers: `.With()`, `.Then()`, `.PipeIf()`
|
|
43
|
-
- Move mapping to DTO `MapToObject()` / `MapToEntity()`
|
|
44
|
-
|
|
45
|
-
### Frontend (TypeScript)
|
|
46
|
-
- Use `PlatformVmStore` for state
|
|
47
|
-
- Apply `untilDestroyed()` to subscriptions
|
|
48
|
-
- Ensure BEM class naming
|
|
49
|
-
|
|
50
|
-
## Constraints
|
|
51
|
-
|
|
52
|
-
- **Preserve functionality** - No behavior changes
|
|
53
|
-
- **Keep tests passing** - Verify after changes
|
|
54
|
-
- **Follow patterns** - Use platform conventions
|
|
55
|
-
- **Document intent** - Add comments only where non-obvious
|
|
56
|
-
|
|
57
|
-
## Example
|
|
58
|
-
|
|
59
|
-
```
|
|
60
|
-
User: /code-simplifier src/Domain/Entities/Employee.cs
|
|
61
|
-
|
|
62
|
-
Claude:
|
|
63
|
-
1. Analyzed Employee.cs (145 lines)
|
|
64
|
-
2. Found: 2 nested conditionals, 1 duplicated expression
|
|
65
|
-
3. Applied:
|
|
66
|
-
- Extracted IsActiveInCompanyExpr() static expression
|
|
67
|
-
- Replaced nested if with guard clause in Validate()
|
|
68
|
-
- Renamed `x` to `employee` in lambda
|
|
69
|
-
4. Tests: All passing
|
|
70
|
-
5. Complexity reduced: 145 → 128 lines
|
|
71
|
-
```
|
|
@@ -1,176 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: ⚡⚡⚡ Start coding & testing an existing plan
|
|
3
|
-
argument-hint: [plan]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
**MUST READ** `CLAUDE.md` then **THINK HARDER** to start working on the following plan follow the Orchestration Protocol, Core Responsibilities, Subagents Team and Development Rules:
|
|
7
|
-
<plan>$ARGUMENTS</plan>
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## Role Responsibilities
|
|
12
|
-
- You are a senior software engineer who must study the provided implementation plan end-to-end before writing code.
|
|
13
|
-
- Validate the plan's assumptions, surface blockers, and confirm priorities with the user prior to execution.
|
|
14
|
-
- Drive the implementation from start to finish, reporting progress and adjusting the plan responsibly while honoring **YAGNI**, **KISS**, and **DRY** principles.
|
|
15
|
-
|
|
16
|
-
**IMPORTANT:** Remind these rules with subagents communication:
|
|
17
|
-
- Sacrifice grammar for the sake of concision when writing reports.
|
|
18
|
-
- In reports, list any unresolved questions at the end, if any.
|
|
19
|
-
- Ensure token efficiency while maintaining high quality.
|
|
20
|
-
|
|
21
|
-
---
|
|
22
|
-
|
|
23
|
-
## Step 0: Plan Detection & Phase Selection
|
|
24
|
-
|
|
25
|
-
**If `$ARGUMENTS` is empty:**
|
|
26
|
-
1. Find latest `plan.md` in `./plans` | `find ./plans -name "plan.md" -type f -exec stat -f "%m %N" {} \; 2>/dev/null | sort -rn | head -1 | cut -d' ' -f2-`
|
|
27
|
-
2. Parse plan for phases and status, auto-select next incomplete (prefer IN_PROGRESS or earliest Planned)
|
|
28
|
-
|
|
29
|
-
**If `$ARGUMENTS` provided:** Use that plan and detect which phase to work on (auto-detect or use argument like "phase-2").
|
|
30
|
-
|
|
31
|
-
**Output:** `✓ Step 0: [Plan Name] - [Phase Name]`
|
|
32
|
-
|
|
33
|
-
**Subagent Pattern (use throughout):**
|
|
34
|
-
```
|
|
35
|
-
Task(subagent_type="[type]", prompt="[task description]", description="[brief]")
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
---
|
|
39
|
-
|
|
40
|
-
## Workflow Sequence
|
|
41
|
-
|
|
42
|
-
**Rules:** Follow steps 1-6 in order. Each step requires output marker starting with "✓ Step N:". Mark each complete in TodoWrite before proceeding. Do not skip steps.
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
## Step 1: Analysis & Task Extraction
|
|
47
|
-
|
|
48
|
-
Read plan file completely. Map dependencies between tasks. List ambiguities or blockers. Identify required skills/tools and activate from catalog. Parse phase file and extract actionable tasks.
|
|
49
|
-
|
|
50
|
-
**TodoWrite Initialization & Task Extraction:**
|
|
51
|
-
- Initialize TodoWrite with `Step 0: [Plan Name] - [Phase Name]` and all command steps (Step 1 through Step 6)
|
|
52
|
-
- Read phase file (e.g., phase-01-preparation.md)
|
|
53
|
-
- Look for tasks/steps/phases/sections/numbered/bulleted lists
|
|
54
|
-
- MUST convert to TodoWrite tasks:
|
|
55
|
-
- Phase Implementation tasks → Step 2.X (Step 2.1, Step 2.2, etc.)
|
|
56
|
-
- Phase Testing tasks → Step 3.X (Step 3.1, Step 3.2, etc.)
|
|
57
|
-
- Phase Code Review tasks → Step 4.X (Step 4.1, Step 4.2, etc.)
|
|
58
|
-
- Ensure each task has UNIQUE name (increment X for each task)
|
|
59
|
-
- Add tasks to TodoWrite after their corresponding command step
|
|
60
|
-
|
|
61
|
-
**Output:** `✓ Step 1: Found [N] tasks across [M] phases - Ambiguities: [list or "none"]`
|
|
62
|
-
|
|
63
|
-
Mark Step 1 complete in TodoWrite, mark Step 2 in_progress.
|
|
64
|
-
|
|
65
|
-
---
|
|
66
|
-
|
|
67
|
-
## Step 2: Implementation
|
|
68
|
-
|
|
69
|
-
Implement selected plan phase step-by-step following extracted tasks (Step 2.1, Step 2.2, etc.). Mark tasks complete as done. For UI work, call `ui-ux-designer` subagent: "Implement [feature] UI per ./docs/design-guidelines.md". Use `ai-multimodal` skill for image assets, `imagemagick` for editing. Run type checking and compile to verify no syntax errors.
|
|
70
|
-
|
|
71
|
-
**Output:** `✓ Step 2: Implemented [N] files - [X/Y] tasks complete, compilation passed`
|
|
72
|
-
|
|
73
|
-
Mark Step 2 complete in TodoWrite, mark Step 3 in_progress.
|
|
74
|
-
|
|
75
|
-
---
|
|
76
|
-
|
|
77
|
-
## Step 3: Testing
|
|
78
|
-
|
|
79
|
-
Write tests covering happy path, edge cases, and error cases. Call `tester` subagent: "Run test suite for plan phase [phase-name]". If ANY tests fail: STOP, call `debugger` subagent: "Analyze failures: [details]", fix all issues, re-run `tester`. Repeat until 100% pass.
|
|
80
|
-
|
|
81
|
-
**Testing standards:** Unit tests may use mocks for external dependencies (APIs, DB). Integration tests use test environment. E2E tests use real but isolated data. Forbidden: commenting out tests, changing assertions to pass, TODO/FIXME to defer fixes.
|
|
82
|
-
|
|
83
|
-
**Output:** `✓ Step 3: Tests [X/X passed] - All requirements met`
|
|
84
|
-
|
|
85
|
-
**Validation:** If X ≠ total, Step 3 INCOMPLETE - do not proceed.
|
|
86
|
-
|
|
87
|
-
Mark Step 3 complete in TodoWrite, mark Step 4 in_progress.
|
|
88
|
-
|
|
89
|
-
---
|
|
90
|
-
|
|
91
|
-
## Step 4: Code Review
|
|
92
|
-
|
|
93
|
-
Call `code-reviewer` subagent: "Review changes for plan phase [phase-name]. Check security, performance, architecture, YAGNI/KISS/DRY". If critical issues found: STOP, fix all, re-run `tester` to verify, re-run `code-reviewer`. Repeat until no critical issues.
|
|
94
|
-
|
|
95
|
-
**Critical issues:** Security vulnerabilities (XSS, SQL injection, OWASP), performance bottlenecks, architectural violations, principle violations.
|
|
96
|
-
|
|
97
|
-
**Output:** `✓ Step 4: Code reviewed - [0] critical issues`
|
|
98
|
-
|
|
99
|
-
**Validation:** If critical issues > 0, Step 4 INCOMPLETE - do not proceed.
|
|
100
|
-
|
|
101
|
-
Mark Step 4 complete in TodoWrite, mark Step 5 in_progress.
|
|
102
|
-
|
|
103
|
-
---
|
|
104
|
-
|
|
105
|
-
## Step 5: User Approval ⏸ BLOCKING GATE
|
|
106
|
-
|
|
107
|
-
Present summary (3-5 bullets): what implemented, tests [X/X passed], code review outcome.
|
|
108
|
-
|
|
109
|
-
**Ask user explicitly:** "Phase implementation complete. All tests pass, code reviewed. Approve changes?"
|
|
110
|
-
|
|
111
|
-
**Stop and wait** - do not output Step 6 content until user responds.
|
|
112
|
-
|
|
113
|
-
**Output (while waiting):** `⏸ Step 5: WAITING for user approval`
|
|
114
|
-
|
|
115
|
-
**Output (after approval):** `✓ Step 5: User approved - Ready to complete`
|
|
116
|
-
|
|
117
|
-
Mark Step 5 complete in TodoWrite, mark Step 6 in_progress.
|
|
118
|
-
|
|
119
|
-
---
|
|
120
|
-
|
|
121
|
-
## Step 6: Finalize
|
|
122
|
-
|
|
123
|
-
**Prerequisites:** User approved in Step 5 (verified above).
|
|
124
|
-
|
|
125
|
-
1. **STATUS UPDATE - BOTH MANDATORY - PARALLEL EXECUTION:**
|
|
126
|
-
- **Call** `project-manager` sub-agent: "Update plan status in [plan-path]. Mark plan phase [phase-name] as DONE with timestamp. Update roadmap."
|
|
127
|
-
- **Call** `docs-manager` sub-agent: "Update docs for plan phase [phase-name]. Changed files: [list]."
|
|
128
|
-
|
|
129
|
-
2. **ONBOARDING CHECK:** Detect onboarding requirements (API keys, env vars, config) + generate summary report with next steps.
|
|
130
|
-
|
|
131
|
-
3. **AUTO-COMMIT (after steps 1 and 2 completes):**
|
|
132
|
-
- Run only if: Steps 1 and 2 successful + User approved + Tests passed
|
|
133
|
-
- Auto-stage, commit with message [phase - plan] and push
|
|
134
|
-
|
|
135
|
-
**Validation:** Steps 1 and 2 must complete successfully. Step 3 (auto-commit) runs only if conditions met.
|
|
136
|
-
|
|
137
|
-
Mark Step 6 complete in TodoWrite.
|
|
138
|
-
|
|
139
|
-
**Phase workflow finished. Ready for next plan phase.**
|
|
140
|
-
|
|
141
|
-
---
|
|
142
|
-
|
|
143
|
-
## Critical Enforcement Rules
|
|
144
|
-
|
|
145
|
-
**Step outputs must follow unified format:** `✓ Step [N]: [Brief status] - [Key metrics]`
|
|
146
|
-
|
|
147
|
-
**Examples:**
|
|
148
|
-
- Step 0: `✓ Step 0: [Plan Name] - [Phase Name]`
|
|
149
|
-
- Step 1: `✓ Step 1: Found [N] tasks across [M] phases - Ambiguities: [list]`
|
|
150
|
-
- Step 2: `✓ Step 2: Implemented [N] files - [X/Y] tasks complete`
|
|
151
|
-
- Step 3: `✓ Step 3: Tests [X/X passed] - All requirements met`
|
|
152
|
-
- Step 4: `✓ Step 4: Code reviewed - [0] critical issues`
|
|
153
|
-
- Step 5: `✓ Step 5: User approved - Ready to complete`
|
|
154
|
-
- Step 6: `✓ Step 6: Finalize - Status updated - Git committed`
|
|
155
|
-
|
|
156
|
-
**If any "✓ Step N:" output missing, that step is INCOMPLETE.**
|
|
157
|
-
|
|
158
|
-
**TodoWrite tracking required:** Initialize at Step 0, mark each step complete before next.
|
|
159
|
-
|
|
160
|
-
**Mandatory subagent calls:**
|
|
161
|
-
- Step 3: `tester`
|
|
162
|
-
- Step 4: `code-reviewer`
|
|
163
|
-
- Step 6: `project-manager` AND `docs-manager` (when user approves)
|
|
164
|
-
|
|
165
|
-
**Blocking gates:**
|
|
166
|
-
- Step 3: Tests must be 100% passing
|
|
167
|
-
- Step 4: Critical issues must be 0
|
|
168
|
-
- Step 5: User must explicitly approve
|
|
169
|
-
- Step 6: Both `project-manager` and `docs-manager` must complete successfully
|
|
170
|
-
|
|
171
|
-
**REMEMBER:**
|
|
172
|
-
- Do not skip steps. Do not proceed if validation fails. Do not assume approval without user response.
|
|
173
|
-
- One plan phase per command run. Command focuses on single plan phase only.
|
|
174
|
-
- You can always generate images with `ai-multimodal` skill on the fly for visual assets.
|
|
175
|
-
- You always read and analyze the generated assets with `ai-multimodal` skill to verify they meet requirements.
|
|
176
|
-
- For image editing (removing background, adjusting, cropping), use `ImageMagick` or similar tools as needed.
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
# Compact Context
|
|
2
|
-
|
|
3
|
-
Proactively compress the current conversation context to optimize token usage.
|
|
4
|
-
|
|
5
|
-
## When to Use
|
|
6
|
-
|
|
7
|
-
- Before starting a new task in a long session
|
|
8
|
-
- When working on multiple unrelated features
|
|
9
|
-
- At natural workflow checkpoints (after commits, PR creation)
|
|
10
|
-
- When context indicator shows high usage
|
|
11
|
-
|
|
12
|
-
## Actions
|
|
13
|
-
|
|
14
|
-
1. **Summarize completed work** - What was done, key decisions made
|
|
15
|
-
2. **Preserve essential context** - Active file paths, current task, blockers
|
|
16
|
-
3. **Clear redundant history** - Old exploration, superseded plans
|
|
17
|
-
4. **Update memory** - Save important patterns to `.claude/memory/`
|
|
18
|
-
|
|
19
|
-
## Best Practices
|
|
20
|
-
|
|
21
|
-
- Use `/compact` at natural breakpoints, not mid-task
|
|
22
|
-
- After compacting, briefly restate the current objective
|
|
23
|
-
- Check that critical file paths are still accessible
|
|
24
|
-
- If working on a bug, preserve error messages and stack traces
|
|
25
|
-
|
|
26
|
-
## Context Preservation Checklist
|
|
27
|
-
|
|
28
|
-
Before compacting, ensure you've saved:
|
|
29
|
-
|
|
30
|
-
- [ ] Current branch and uncommitted changes status
|
|
31
|
-
- [ ] Active file paths being modified
|
|
32
|
-
- [ ] Any error messages or stack traces
|
|
33
|
-
- [ ] Key decisions and their rationale
|
|
34
|
-
- [ ] Pending items from todo list
|
|
35
|
-
|
|
36
|
-
## Example Usage
|
|
37
|
-
|
|
38
|
-
```
|
|
39
|
-
User: /compact
|
|
40
|
-
Claude: Compacting context...
|
|
41
|
-
|
|
42
|
-
## Session Summary
|
|
43
|
-
- Implemented employee export feature
|
|
44
|
-
- Fixed validation bug in SaveEmployeeCommand
|
|
45
|
-
- Created unit tests for EmployeeHelper
|
|
46
|
-
|
|
47
|
-
## Active Context
|
|
48
|
-
- Branch: feature/employee-export
|
|
49
|
-
- Files: Employee.Application/Commands/ExportEmployees/
|
|
50
|
-
- Current task: Add pagination to export
|
|
51
|
-
|
|
52
|
-
## Cleared
|
|
53
|
-
- Exploration of unrelated notification code
|
|
54
|
-
- Superseded implementation approaches
|
|
55
|
-
|
|
56
|
-
Ready to continue with pagination implementation.
|
|
57
|
-
```
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Analyze the current content and optimize for conversion
|
|
3
|
-
argument-hint: [issues]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
You are an expert in conversion optimization. Analyze the content based on reported issues:
|
|
7
|
-
<issues>$ARGUMENTS</issues>
|
|
8
|
-
|
|
9
|
-
## Conversion Optimization Framework
|
|
10
|
-
|
|
11
|
-
1. Headline 4-U Formula: Useful, Unique, Urgent, Ultra-specific (80% won't read past this)
|
|
12
|
-
2. Above-Fold Value Proposition: Customer problem focus, no company story, zero scroll required
|
|
13
|
-
3. CTA First-Person Psychology: "Get MY Guide" vs "Get YOUR Guide" (90% more clicks)
|
|
14
|
-
4. 5-Field Form Maximum: Every field kills conversions, progressive profiling for the rest
|
|
15
|
-
5. Message Match Precision: Ad copy, landing page headline, broken promises = bounce
|
|
16
|
-
6. Social Proof Near CTAs: Testimonials with faces/names, results, placed at decision points
|
|
17
|
-
7. Cognitive Bias Stack: Loss aversion (fear), social proof (FOMO), anchoring (pricing)
|
|
18
|
-
8. PAS Copy Framework: Problem > Agitate > Solve, emotion before logic
|
|
19
|
-
9. Genuine Urgency Only: Real deadlines, actual limits, fake timers destroy trust forever
|
|
20
|
-
10. Price Anchoring Display: Show expensive option first, make real price feel like relief
|
|
21
|
-
11. Trust Signal Clustering: Security badges, guarantees, policies all visible together
|
|
22
|
-
12. Visual Hierarchy F-Pattern: Eyes scan F-shape, put conversions in the path
|
|
23
|
-
13. Lead Magnet Hierarchy: Templates > Checklists > Guides (instant > delayed gratification)
|
|
24
|
-
14. Objection Preemption: Address top 3 concerns before they think them, FAQ near CTA
|
|
25
|
-
15. Mobile Thumb Zone: CTAs where thumbs naturally rest, not stretching required
|
|
26
|
-
16. One-Variable Testing: Change one thing, measure impact, compound wins over time
|
|
27
|
-
17. Post-Conversion Momentum: Thank you page sells next step while excitement peaks
|
|
28
|
-
18. Cart Recovery Sequence: Email in 1 hour, retarget in 4 hours, incentive at 24 hours
|
|
29
|
-
19. Reading Level Grade 6: Smart people prefer simple, 11-word sentences, short paragraphs
|
|
30
|
-
20. TOFU/MOFU/BOFU Logic: Awareness content ≠ decision content, match intent precisely
|
|
31
|
-
21. White Space = Focus: Empty space makes CTAs impossible to miss, crowded = confused
|
|
32
|
-
22. Benefit-First Language: Features tell, benefits sell, transformations compel
|
|
33
|
-
23. Micro-Commitment Ladder: Small yes leads to big yes, start with email only
|
|
34
|
-
24. Performance Tracking Stack: Heatmaps show problems, recordings show why, events show what
|
|
35
|
-
25. Weekly Optimization Ritual: Review metrics Monday, test Tuesday, iterate or scale
|
|
36
|
-
|
|
37
|
-
## Workflow
|
|
38
|
-
|
|
39
|
-
- If the user provides screenshots, use `ai-multimodal` skill to analyze and describe conversion optimization issues in detail.
|
|
40
|
-
- If the user provides videos, use `ai-multimodal` (`video-analysis`) skill to analyze video content and identify conversion bottlenecks.
|
|
41
|
-
- If the user provides a URL, use `web_fetch` tool to fetch the content and analyze current issues.
|
|
42
|
-
- Use `/scout:ext` (preferred) or `/scout` (fallback) slash command to search the codebase for files needed to complete the task
|
|
43
|
-
- Use `copywriter` agent to write the enhanced copy into the code files, then report back to main agent.
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Analyze the current copy issues and enhance it
|
|
3
|
-
argument-hint: [issues]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Enhance the copy based on reported issues:
|
|
7
|
-
<issues>$ARGUMENTS</issues>
|
|
8
|
-
|
|
9
|
-
## Workflow
|
|
10
|
-
|
|
11
|
-
- If the user provides screenshots, use `ai-multimodal` skill to analyze and describe the issues in detail, ensuring the copywriter understands the context.
|
|
12
|
-
- If the user provides videos, use `ai-multimodal` (`video-analysis`) skill to analyze video content and extract relevant copy issues.
|
|
13
|
-
- Use `/scout:ext` (preferred) or `/scout` (fallback) slash command to search the codebase for files needed to complete the task
|
|
14
|
-
- Use `copywriter` agent to write the enhanced copy into the code files, then report back to main agent.
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Write creative & smart copy [FAST]
|
|
3
|
-
argument-hint: [user-request]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Write creative & smart copy for this user request:
|
|
7
|
-
<user_request>$ARGUMENTS</user_request>
|
|
8
|
-
|
|
9
|
-
## Workflow
|
|
10
|
-
|
|
11
|
-
- If the user provides screenshots, use `ai-multimodal` skill to analyze and describe the context.
|
|
12
|
-
- If the user provides videos, use `ai-multimodal` (`video-analysis`) skill to analyze video content.
|
|
13
|
-
- Use `copywriter` agent to write the copy, then report back to main agent.
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Write good creative & smart copy [GOOD]
|
|
3
|
-
argument-hint: [user-request]
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
Write good creative & smart copy for this user request:
|
|
7
|
-
<user_request>$ARGUMENTS</user_request>
|
|
8
|
-
|
|
9
|
-
## Workflow
|
|
10
|
-
|
|
11
|
-
- If the user provides screenshots, use `ai-multimodal` skill to analyze and describe the context in detail.
|
|
12
|
-
- If the user provides videos, use `ai-multimodal` (`video-analysis`) skill to analyze video content.
|
|
13
|
-
- Use multiple `researcher` agents in parallel to search for relevant information, then report back to main agent.
|
|
14
|
-
- Use `/scout:ext` (preferred) or `/scout` (fallback) slash command to search the codebase for files needed to complete the task
|
|
15
|
-
- Use `planner` agent to plan the copy, make sure it can satisfy the user request.
|
|
16
|
-
- Use `copywriter` agent to write the copy based on the plan, then report back to main agent.
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
# Load Project Context
|
|
2
|
-
|
|
3
|
-
Load current development context to help with subsequent tasks.
|
|
4
|
-
|
|
5
|
-
## Git Status
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
git status --short
|
|
9
|
-
git branch --show-current
|
|
10
|
-
```
|
|
11
|
-
|
|
12
|
-
## Recent Activity
|
|
13
|
-
|
|
14
|
-
```bash
|
|
15
|
-
# Recent commits
|
|
16
|
-
git log --oneline -5
|
|
17
|
-
|
|
18
|
-
# Uncommitted changes
|
|
19
|
-
git diff --stat
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
## Project Structure Reminder
|
|
23
|
-
|
|
24
|
-
**Backend Services:**
|
|
25
|
-
- `TextSnippet` - Example application service
|
|
26
|
-
- `Accounts` - Authentication & authorization
|
|
27
|
-
|
|
28
|
-
**Frontend Apps (WebV2):**
|
|
29
|
-
- `playground-text-snippet` - Example frontend application
|
|
30
|
-
|
|
31
|
-
**Key Libraries:**
|
|
32
|
-
- `platform-core` - Base components (PlatformComponent, stores)
|
|
33
|
-
- `apps-domains` - Business domain (APIs, models, validators)
|
|
34
|
-
- `platform-core` - UI components & utilities
|
|
35
|
-
|
|
36
|
-
## Development Patterns
|
|
37
|
-
|
|
38
|
-
**Backend:** Clean Architecture + CQRS + Entity Events
|
|
39
|
-
**Frontend:** Angular 19 + Nx + PlatformVmStore
|
|
40
|
-
|
|
41
|
-
## Current Session Focus
|
|
42
|
-
|
|
43
|
-
Based on the git status, identify:
|
|
44
|
-
- What files are being worked on
|
|
45
|
-
- What feature/fix is in progress
|
|
46
|
-
- Any uncommitted changes that need attention
|
|
47
|
-
|
|
48
|
-
Summarize the current state to help with subsequent tasks.
|