claude-code-workflow 6.3.48 → 6.3.49
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/.claude/CLAUDE.md +6 -8
- package/.claude/agents/action-planning-agent.md +28 -45
- package/.claude/agents/cli-lite-planning-agent.md +93 -1
- package/.claude/agents/code-developer.md +144 -27
- package/.claude/commands/ccw-coordinator.md +175 -21
- package/.claude/commands/ccw-debug.md +832 -0
- package/.claude/commands/ccw.md +90 -9
- package/.claude/commands/cli/cli-init.md +1 -0
- package/.claude/commands/issue/convert-to-plan.md +718 -0
- package/.claude/commands/issue/from-brainstorm.md +382 -0
- package/.claude/commands/memory/tips.md +332 -0
- package/.claude/commands/workflow/analyze-with-file.md +804 -0
- package/.claude/commands/workflow/brainstorm/auto-parallel.md +18 -43
- package/.claude/commands/workflow/brainstorm/role-analysis.md +705 -0
- package/.claude/commands/workflow/brainstorm-with-file.md +1153 -0
- package/.claude/commands/workflow/debug-with-file.md +7 -5
- package/.claude/commands/workflow/execute.md +6 -4
- package/.claude/commands/workflow/lite-plan.md +2 -2
- package/.claude/commands/workflow/plan-verify.md +162 -327
- package/.claude/commands/workflow/plan.md +162 -26
- package/.claude/commands/workflow/replan.md +78 -2
- package/.claude/commands/workflow/{review-fix.md → review-cycle-fix.md} +6 -6
- package/.claude/commands/workflow/review-module-cycle.md +2 -2
- package/.claude/commands/workflow/review-session-cycle.md +2 -2
- package/.claude/commands/workflow/tools/conflict-resolution.md +16 -26
- package/.claude/commands/workflow/tools/context-gather.md +81 -118
- package/.claude/commands/workflow/tools/task-generate-agent.md +94 -10
- package/.claude/skills/ccw-help/command.json +4 -4
- package/.claude/skills/lite-skill-generator/SKILL.md +650 -0
- package/.claude/skills/lite-skill-generator/templates/simple-skill.md +68 -0
- package/.claude/skills/lite-skill-generator/templates/style-guide.md +64 -0
- package/.claude/skills/skill-generator/SKILL.md +277 -85
- package/.claude/skills/skill-generator/phases/01-requirements-discovery.md +4 -15
- package/.claude/skills/skill-generator/phases/02-structure-generation.md +72 -17
- package/.claude/skills/skill-generator/phases/03-phase-generation.md +218 -51
- package/.claude/skills/skill-generator/phases/04-specs-templates.md +111 -41
- package/.claude/skills/skill-generator/phases/05-validation.md +139 -56
- package/.claude/skills/skill-generator/templates/autonomous-action.md +78 -268
- package/.claude/skills/skill-generator/templates/autonomous-orchestrator.md +14 -0
- package/.claude/skills/skill-generator/templates/code-analysis-action.md +12 -0
- package/.claude/skills/skill-generator/templates/llm-action.md +12 -0
- package/.claude/skills/skill-generator/templates/script-template.md +368 -0
- package/.claude/skills/skill-generator/templates/sequential-phase.md +14 -0
- package/.claude/skills/skill-generator/templates/skill-md.md +14 -0
- package/.claude/skills/skill-tuning/SKILL.md +130 -266
- package/.claude/skills/skill-tuning/phases/orchestrator.md +95 -283
- package/.claude/skills/skill-tuning/specs/problem-taxonomy.md +90 -198
- package/.claude/skills/skill-tuning/specs/tuning-strategies.md +193 -1345
- package/.claude/workflows/cli-templates/schemas/plan-verify-agent-schema.json +47 -0
- package/.claude/workflows/cli-templates/schemas/verify-json-schema.json +158 -0
- package/.claude/workflows/cli-tools-usage.md +1 -1
- package/.codex/AGENTS.md +1 -3
- package/.codex/prompts/analyze-with-file.md +607 -0
- package/.codex/prompts/brainstorm-to-cycle.md +455 -0
- package/.codex/prompts/brainstorm-with-file.md +933 -0
- package/.codex/prompts/debug-with-file.md +15 -20
- package/.codex/skills/ccw-cli-tools/SKILL.md +559 -0
- package/ccw/dist/commands/cli.d.ts.map +1 -1
- package/ccw/dist/commands/cli.js +29 -5
- package/ccw/dist/commands/cli.js.map +1 -1
- package/ccw/dist/commands/issue.d.ts +2 -0
- package/ccw/dist/commands/issue.d.ts.map +1 -1
- package/ccw/dist/commands/issue.js +62 -20
- package/ccw/dist/commands/issue.js.map +1 -1
- package/ccw/dist/config/litellm-api-config-manager.d.ts.map +1 -1
- package/ccw/dist/config/litellm-api-config-manager.js +5 -3
- package/ccw/dist/config/litellm-api-config-manager.js.map +1 -1
- package/ccw/dist/config/litellm-provider-models.d.ts +73 -0
- package/ccw/dist/config/litellm-provider-models.d.ts.map +1 -0
- package/ccw/dist/config/litellm-provider-models.js +172 -0
- package/ccw/dist/config/litellm-provider-models.js.map +1 -0
- package/ccw/dist/config/provider-models.d.ts +25 -51
- package/ccw/dist/config/provider-models.d.ts.map +1 -1
- package/ccw/dist/config/provider-models.js +84 -149
- package/ccw/dist/config/provider-models.js.map +1 -1
- package/ccw/dist/config/storage-paths.d.ts.map +1 -1
- package/ccw/dist/config/storage-paths.js +23 -5
- package/ccw/dist/config/storage-paths.js.map +1 -1
- package/ccw/dist/core/auth/csrf-middleware.js +3 -3
- package/ccw/dist/core/auth/csrf-middleware.js.map +1 -1
- package/ccw/dist/core/dashboard-generator.d.ts.map +1 -1
- package/ccw/dist/core/dashboard-generator.js +3 -1
- package/ccw/dist/core/dashboard-generator.js.map +1 -1
- package/ccw/dist/core/routes/claude-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/claude-routes.js +206 -14
- package/ccw/dist/core/routes/claude-routes.js.map +1 -1
- package/ccw/dist/core/routes/cli-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/cli-routes.js.map +1 -1
- package/ccw/dist/core/routes/commands-routes.d.ts +7 -0
- package/ccw/dist/core/routes/commands-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/commands-routes.js +480 -0
- package/ccw/dist/core/routes/commands-routes.js.map +1 -0
- package/ccw/dist/core/routes/model-routes.d.ts +11 -0
- package/ccw/dist/core/routes/model-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/model-routes.js +112 -0
- package/ccw/dist/core/routes/model-routes.js.map +1 -0
- package/ccw/dist/core/routes/nav-status-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/nav-status-routes.js +84 -1
- package/ccw/dist/core/routes/nav-status-routes.js.map +1 -1
- package/ccw/dist/core/routes/provider-routes.d.ts +11 -0
- package/ccw/dist/core/routes/provider-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/provider-routes.js +67 -0
- package/ccw/dist/core/routes/provider-routes.js.map +1 -0
- package/ccw/dist/core/routes/skills-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/skills-routes.js +219 -7
- package/ccw/dist/core/routes/skills-routes.js.map +1 -1
- package/ccw/dist/core/routes/system-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/system-routes.js +58 -6
- package/ccw/dist/core/routes/system-routes.js.map +1 -1
- package/ccw/dist/core/server.d.ts.map +1 -1
- package/ccw/dist/core/server.js +13 -0
- package/ccw/dist/core/server.js.map +1 -1
- package/ccw/dist/mcp-server/index.js +2 -2
- package/ccw/dist/mcp-server/index.js.map +1 -1
- package/ccw/dist/tools/claude-cli-tools.d.ts +48 -11
- package/ccw/dist/tools/claude-cli-tools.d.ts.map +1 -1
- package/ccw/dist/tools/claude-cli-tools.js +146 -50
- package/ccw/dist/tools/claude-cli-tools.js.map +1 -1
- package/ccw/dist/tools/cli-config-manager.d.ts +1 -13
- package/ccw/dist/tools/cli-config-manager.d.ts.map +1 -1
- package/ccw/dist/tools/cli-config-manager.js +3 -27
- package/ccw/dist/tools/cli-config-manager.js.map +1 -1
- package/ccw/dist/tools/cli-executor-core.d.ts.map +1 -1
- package/ccw/dist/tools/cli-executor-core.js +7 -2
- package/ccw/dist/tools/cli-executor-core.js.map +1 -1
- package/ccw/dist/tools/cli-executor-state.d.ts.map +1 -1
- package/ccw/dist/tools/cli-history-store.d.ts +11 -0
- package/ccw/dist/tools/cli-history-store.d.ts.map +1 -1
- package/ccw/dist/tools/cli-history-store.js +82 -2
- package/ccw/dist/tools/cli-history-store.js.map +1 -1
- package/ccw/dist/tools/command-registry.d.ts +7 -0
- package/ccw/dist/tools/command-registry.d.ts.map +1 -1
- package/ccw/dist/tools/command-registry.js +14 -1
- package/ccw/dist/tools/command-registry.js.map +1 -1
- package/ccw/dist/tools/generate-module-docs.d.ts.map +1 -1
- package/ccw/dist/tools/generate-module-docs.js +11 -7
- package/ccw/dist/tools/generate-module-docs.js.map +1 -1
- package/ccw/dist/tools/litellm-executor.d.ts +1 -0
- package/ccw/dist/tools/litellm-executor.d.ts.map +1 -1
- package/ccw/dist/tools/litellm-executor.js +11 -9
- package/ccw/dist/tools/litellm-executor.js.map +1 -1
- package/ccw/dist/types/skill-types.d.ts +97 -0
- package/ccw/dist/types/skill-types.d.ts.map +1 -0
- package/ccw/dist/types/skill-types.js +6 -0
- package/ccw/dist/types/skill-types.js.map +1 -0
- package/ccw/src/commands/cli.ts +36 -5
- package/ccw/src/commands/issue.ts +81 -26
- package/ccw/src/config/litellm-api-config-manager.ts +5 -3
- package/ccw/src/config/litellm-provider-models.ts +222 -0
- package/ccw/src/config/provider-models.ts +91 -190
- package/ccw/src/config/storage-paths.ts +20 -5
- package/ccw/src/core/auth/csrf-middleware.ts +3 -3
- package/ccw/src/core/dashboard-generator.ts +3 -1
- package/ccw/src/core/routes/claude-routes.ts +233 -15
- package/ccw/src/core/routes/cli-routes.ts +2 -3
- package/ccw/src/core/routes/commands-routes.ts +620 -0
- package/ccw/src/core/routes/nav-status-routes.ts +95 -1
- package/ccw/src/core/routes/provider-routes.ts +78 -0
- package/ccw/src/core/routes/skills-routes.ts +266 -45
- package/ccw/src/core/routes/system-routes.ts +102 -50
- package/ccw/src/core/server.ts +13 -0
- package/ccw/src/mcp-server/index.ts +2 -2
- package/ccw/src/templates/dashboard-css/18-cli-settings.css +35 -0
- package/ccw/src/templates/dashboard-css/37-commands.css +193 -0
- package/ccw/src/templates/dashboard-js/components/navigation.js +4 -0
- package/ccw/src/templates/dashboard-js/i18n.js +116 -0
- package/ccw/src/templates/dashboard-js/views/cli-manager.js +249 -4
- package/ccw/src/templates/dashboard-js/views/commands-manager.js +503 -0
- package/ccw/src/templates/dashboard-js/views/issue-manager.js +7 -7
- package/ccw/src/templates/dashboard-js/views/mcp-manager.js +2 -7
- package/ccw/src/templates/dashboard-js/views/skills-manager.js +164 -23
- package/ccw/src/templates/dashboard.html +7 -0
- package/ccw/src/tools/claude-cli-tools.ts +170 -56
- package/ccw/src/tools/cli-config-manager.ts +2 -33
- package/ccw/src/tools/cli-executor-core.ts +8 -2
- package/ccw/src/tools/cli-history-store.ts +92 -2
- package/ccw/src/tools/command-registry.ts +16 -1
- package/ccw/src/tools/generate-module-docs.ts +11 -7
- package/ccw/src/tools/litellm-executor.ts +13 -9
- package/ccw/src/types/skill-types.ts +99 -0
- package/package.json +1 -1
- package/.claude/commands/enhance-prompt.md +0 -93
- package/.claude/commands/memory/code-map-memory.md +0 -687
- package/.claude/commands/memory/docs.md +0 -615
- package/.claude/commands/memory/load-skill-memory.md +0 -182
- package/.claude/commands/memory/skill-memory.md +0 -525
- package/.claude/commands/memory/swagger-docs.md +0 -773
- package/.claude/commands/memory/tech-research-rules.md +0 -310
- package/.claude/commands/memory/workflow-skill-memory.md +0 -517
- package/.claude/commands/task/breakdown.md +0 -208
- package/.claude/commands/task/create.md +0 -152
- package/.claude/commands/task/execute.md +0 -270
- package/.claude/commands/task/replan.md +0 -441
- package/.claude/commands/version.md +0 -254
- package/.claude/commands/workflow/action-plan-verify.md +0 -485
- package/.claude/commands/workflow/brainstorm/api-designer.md +0 -587
- package/.claude/commands/workflow/brainstorm/data-architect.md +0 -220
- package/.claude/commands/workflow/brainstorm/product-manager.md +0 -200
- package/.claude/commands/workflow/brainstorm/product-owner.md +0 -200
- package/.claude/commands/workflow/brainstorm/scrum-master.md +0 -200
- package/.claude/commands/workflow/brainstorm/subject-matter-expert.md +0 -200
- package/.claude/commands/workflow/brainstorm/system-architect.md +0 -389
- package/.claude/commands/workflow/brainstorm/ui-designer.md +0 -221
- package/.claude/commands/workflow/brainstorm/ux-expert.md +0 -221
- package/.claude/commands/workflow/debug.md +0 -331
- package/.claude/commands/workflow/develop-with-file.md +0 -1044
- package/.claude/skills/ccw-loop/README.md +0 -303
- package/.claude/skills/skill-generator/templates/script-bash.md +0 -277
- package/.claude/skills/skill-generator/templates/script-python.md +0 -198
- package/.codex/prompts/debug.md +0 -318
- package/ccw/src/core/routes/mcp-routes.ts.backup +0 -549
|
@@ -1,208 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: breakdown
|
|
3
|
-
description: Decompose complex task into subtasks with dependency mapping, creates child task JSONs with parent references and execution order
|
|
4
|
-
argument-hint: "[-y|--yes] task-id"
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Auto Mode
|
|
8
|
-
|
|
9
|
-
When `--yes` or `-y`: Auto-confirm breakdown, use recommended subtask structure.
|
|
10
|
-
|
|
11
|
-
# Task Breakdown Command (/task:breakdown)
|
|
12
|
-
|
|
13
|
-
## Overview
|
|
14
|
-
Breaks down complex tasks into executable subtasks with context inheritance and agent assignment.
|
|
15
|
-
|
|
16
|
-
## Core Principles
|
|
17
|
-
**File Cohesion:** Related files must stay in same task
|
|
18
|
-
**10-Task Limit:** Total tasks cannot exceed 10 (triggers re-scoping)
|
|
19
|
-
|
|
20
|
-
## Core Features
|
|
21
|
-
|
|
22
|
-
**CRITICAL**: Manual breakdown with safety controls to prevent file conflicts and task limit violations.
|
|
23
|
-
|
|
24
|
-
### Breakdown Process
|
|
25
|
-
1. **Session Check**: Verify active session contains parent task
|
|
26
|
-
2. **Task Validation**: Ensure parent is `pending` status
|
|
27
|
-
3. **10-Task Limit Check**: Verify breakdown won't exceed total limit
|
|
28
|
-
4. **Manual Decomposition**: User defines subtasks with validation
|
|
29
|
-
5. **File Conflict Detection**: Warn if same files appear in multiple subtasks
|
|
30
|
-
6. **Similar Function Warning**: Alert if subtasks have overlapping functionality
|
|
31
|
-
7. **Context Distribution**: Inherit parent requirements and scope
|
|
32
|
-
8. **Agent Assignment**: Auto-assign agents based on subtask type
|
|
33
|
-
9. **TODO_LIST Update**: Regenerate TODO_LIST.md with new structure
|
|
34
|
-
|
|
35
|
-
### Breakdown Rules
|
|
36
|
-
- Only `pending` tasks can be broken down
|
|
37
|
-
- **Manual breakdown only**: Automated breakdown disabled to prevent violations
|
|
38
|
-
- Parent becomes `container` status (not executable)
|
|
39
|
-
- Subtasks use format: IMPL-N.M (max 2 levels)
|
|
40
|
-
- Context flows from parent to subtasks
|
|
41
|
-
- All relationships tracked in JSON
|
|
42
|
-
- **10-task limit enforced**: Breakdown rejected if total would exceed 10 tasks
|
|
43
|
-
- **File cohesion preserved**: Same files cannot be split across subtasks
|
|
44
|
-
|
|
45
|
-
## Usage
|
|
46
|
-
|
|
47
|
-
### Basic Breakdown
|
|
48
|
-
```bash
|
|
49
|
-
/task:breakdown impl-1
|
|
50
|
-
```
|
|
51
|
-
|
|
52
|
-
Interactive process:
|
|
53
|
-
```
|
|
54
|
-
Task: Build authentication module
|
|
55
|
-
Current total tasks: 6/10
|
|
56
|
-
|
|
57
|
-
MANUAL BREAKDOWN REQUIRED
|
|
58
|
-
Define subtasks manually (remaining capacity: 4 tasks):
|
|
59
|
-
|
|
60
|
-
1. Enter subtask title: User authentication core
|
|
61
|
-
Focus files: models/User.js, routes/auth.js, middleware/auth.js
|
|
62
|
-
|
|
63
|
-
2. Enter subtask title: OAuth integration
|
|
64
|
-
Focus files: services/OAuthService.js, routes/oauth.js
|
|
65
|
-
|
|
66
|
-
FILE CONFLICT DETECTED:
|
|
67
|
-
- routes/auth.js appears in multiple subtasks
|
|
68
|
-
- Recommendation: Merge related authentication routes
|
|
69
|
-
|
|
70
|
-
SIMILAR FUNCTIONALITY WARNING:
|
|
71
|
-
- "User authentication" and "OAuth integration" both handle auth
|
|
72
|
-
- Consider combining into single task
|
|
73
|
-
|
|
74
|
-
# Use AskUserQuestion for confirmation
|
|
75
|
-
AskUserQuestion({
|
|
76
|
-
questions: [{
|
|
77
|
-
question: "File conflicts and/or similar functionality detected. How do you want to proceed?",
|
|
78
|
-
header: "Confirm",
|
|
79
|
-
options: [
|
|
80
|
-
{ label: "Proceed with breakdown", description: "Accept the risks and create the subtasks as defined." },
|
|
81
|
-
{ label: "Restart breakdown", description: "Discard current subtasks and start over." },
|
|
82
|
-
{ label: "Cancel breakdown", description: "Abort the operation and leave the parent task as is." }
|
|
83
|
-
],
|
|
84
|
-
multiSelect: false
|
|
85
|
-
}]
|
|
86
|
-
})
|
|
87
|
-
|
|
88
|
-
User selected: "Proceed with breakdown"
|
|
89
|
-
|
|
90
|
-
Task IMPL-1 broken down:
|
|
91
|
-
IMPL-1: Build authentication module (container)
|
|
92
|
-
├── IMPL-1.1: User authentication core -> @code-developer
|
|
93
|
-
└── IMPL-1.2: OAuth integration -> @code-developer
|
|
94
|
-
|
|
95
|
-
Files updated: .task/IMPL-1.json + 2 subtask files + TODO_LIST.md
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
## Decomposition Logic
|
|
99
|
-
|
|
100
|
-
### Agent Assignment
|
|
101
|
-
- **Design/Planning** → `@planning-agent`
|
|
102
|
-
- **Implementation** → `@code-developer`
|
|
103
|
-
- **Testing** → `@code-developer` (type: "test-gen")
|
|
104
|
-
- **Test Validation** → `@test-fix-agent` (type: "test-fix")
|
|
105
|
-
- **Review** → `@universal-executor` (optional)
|
|
106
|
-
|
|
107
|
-
### Context Inheritance
|
|
108
|
-
- Subtasks inherit parent requirements
|
|
109
|
-
- Scope refined for specific subtask
|
|
110
|
-
- Implementation details distributed appropriately
|
|
111
|
-
|
|
112
|
-
## Safety Controls
|
|
113
|
-
|
|
114
|
-
### File Conflict Detection
|
|
115
|
-
**Validates file cohesion across subtasks:**
|
|
116
|
-
- Scans `focus_paths` in all subtasks
|
|
117
|
-
- Warns if same file appears in multiple subtasks
|
|
118
|
-
- Suggests merging subtasks with overlapping files
|
|
119
|
-
- Blocks breakdown if critical conflicts detected
|
|
120
|
-
|
|
121
|
-
### Similar Functionality Detection
|
|
122
|
-
**Prevents functional overlap:**
|
|
123
|
-
- Analyzes subtask titles for similar keywords
|
|
124
|
-
- Warns about potential functional redundancy
|
|
125
|
-
- Suggests consolidation of related functionality
|
|
126
|
-
- Examples: "user auth" + "login system" → merge recommendation
|
|
127
|
-
|
|
128
|
-
### 10-Task Limit Enforcement
|
|
129
|
-
**Hard limit compliance:**
|
|
130
|
-
- Counts current total tasks in session
|
|
131
|
-
- Calculates breakdown impact on total
|
|
132
|
-
- Rejects breakdown if would exceed 10 tasks
|
|
133
|
-
- Suggests re-scoping if limit reached
|
|
134
|
-
|
|
135
|
-
### Manual Control Requirements
|
|
136
|
-
**User-driven breakdown only:**
|
|
137
|
-
- No automatic subtask generation
|
|
138
|
-
- User must define each subtask title and scope
|
|
139
|
-
- Real-time validation during input
|
|
140
|
-
- Confirmation required before execution
|
|
141
|
-
|
|
142
|
-
## Implementation Details
|
|
143
|
-
|
|
144
|
-
- Complete task JSON schema
|
|
145
|
-
- Implementation field structure
|
|
146
|
-
- Context inheritance rules
|
|
147
|
-
- Agent assignment logic
|
|
148
|
-
|
|
149
|
-
## Validation
|
|
150
|
-
|
|
151
|
-
### Pre-breakdown Checks
|
|
152
|
-
1. Active session exists
|
|
153
|
-
2. Task found in session
|
|
154
|
-
3. Task status is `pending`
|
|
155
|
-
4. Not already broken down
|
|
156
|
-
5. **10-task limit compliance**: Total tasks + new subtasks ≤ 10
|
|
157
|
-
6. **Manual mode enabled**: No automatic breakdown allowed
|
|
158
|
-
|
|
159
|
-
### Post-breakdown Actions
|
|
160
|
-
1. Update parent to `container` status
|
|
161
|
-
2. Create subtask JSON files
|
|
162
|
-
3. Update parent subtasks list
|
|
163
|
-
4. Update session stats
|
|
164
|
-
5. **Regenerate TODO_LIST.md** with new hierarchy
|
|
165
|
-
6. Validate file paths in focus_paths
|
|
166
|
-
7. Update session task count
|
|
167
|
-
|
|
168
|
-
## Examples
|
|
169
|
-
|
|
170
|
-
### Basic Breakdown
|
|
171
|
-
```bash
|
|
172
|
-
/task:breakdown impl-1
|
|
173
|
-
|
|
174
|
-
impl-1: Build authentication (container)
|
|
175
|
-
├── impl-1.1: Design schema -> @planning-agent
|
|
176
|
-
├── impl-1.2: Implement logic + tests -> @code-developer
|
|
177
|
-
└── impl-1.3: Execute & fix tests -> @test-fix-agent
|
|
178
|
-
```
|
|
179
|
-
|
|
180
|
-
## Error Handling
|
|
181
|
-
|
|
182
|
-
```bash
|
|
183
|
-
# Task not found
|
|
184
|
-
Task IMPL-5 not found
|
|
185
|
-
|
|
186
|
-
# Already broken down
|
|
187
|
-
Task IMPL-1 already has subtasks
|
|
188
|
-
|
|
189
|
-
# Wrong status
|
|
190
|
-
Cannot breakdown completed task IMPL-2
|
|
191
|
-
|
|
192
|
-
# 10-task limit exceeded
|
|
193
|
-
Breakdown would exceed 10-task limit (current: 8, proposed: 4)
|
|
194
|
-
Suggestion: Re-scope project into smaller iterations
|
|
195
|
-
|
|
196
|
-
# File conflicts detected
|
|
197
|
-
File conflict: routes/auth.js appears in IMPL-1.1 and IMPL-1.2
|
|
198
|
-
Recommendation: Merge subtasks or redistribute files
|
|
199
|
-
|
|
200
|
-
# Similar functionality warning
|
|
201
|
-
Similar functions detected: "user login" and "authentication"
|
|
202
|
-
Consider consolidating related functionality
|
|
203
|
-
|
|
204
|
-
# Manual breakdown required
|
|
205
|
-
Automatic breakdown disabled. Use manual breakdown process.
|
|
206
|
-
```
|
|
207
|
-
|
|
208
|
-
**System ensures**: Manual breakdown control with file cohesion enforcement, similar functionality detection, and 10-task limit compliance
|
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: create
|
|
3
|
-
description: Generate task JSON from natural language description with automatic file pattern detection, scope inference, and dependency analysis
|
|
4
|
-
argument-hint: "\"task title\""
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# Task Create Command (/task:create)
|
|
8
|
-
|
|
9
|
-
## Overview
|
|
10
|
-
Creates new implementation tasks with automatic context awareness and ID generation.
|
|
11
|
-
|
|
12
|
-
## Core Principles
|
|
13
|
-
**Task System:** @~/.claude/workflows/task-core.md
|
|
14
|
-
|
|
15
|
-
## Core Features
|
|
16
|
-
|
|
17
|
-
### Automatic Behaviors
|
|
18
|
-
- **ID Generation**: Auto-generates IMPL-N format (max 2 levels)
|
|
19
|
-
- **Context Inheritance**: Inherits from active workflow session
|
|
20
|
-
- **JSON Creation**: Creates task JSON in active session
|
|
21
|
-
- **Status Setting**: Initial status = "pending"
|
|
22
|
-
- **Agent Assignment**: Suggests agent based on task type
|
|
23
|
-
- **Session Integration**: Updates workflow session stats
|
|
24
|
-
|
|
25
|
-
### Context Awareness
|
|
26
|
-
- Validates active workflow session exists
|
|
27
|
-
- Avoids duplicate task IDs
|
|
28
|
-
- Inherits session requirements and scope
|
|
29
|
-
- Suggests task relationships
|
|
30
|
-
|
|
31
|
-
## Usage
|
|
32
|
-
|
|
33
|
-
### Basic Creation
|
|
34
|
-
```bash
|
|
35
|
-
/task:create "Build authentication module"
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
Output:
|
|
39
|
-
```
|
|
40
|
-
Task created: IMPL-1
|
|
41
|
-
Title: Build authentication module
|
|
42
|
-
Type: feature
|
|
43
|
-
Agent: code-developer
|
|
44
|
-
Status: pending
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
### Task Types
|
|
48
|
-
- `feature` - New functionality (default)
|
|
49
|
-
- `bugfix` - Bug fixes
|
|
50
|
-
- `refactor` - Code improvements
|
|
51
|
-
- `test` - Test implementation
|
|
52
|
-
- `docs` - Documentation
|
|
53
|
-
|
|
54
|
-
## Task Creation Process
|
|
55
|
-
|
|
56
|
-
1. **Session Validation**: Check active workflow session
|
|
57
|
-
2. **ID Generation**: Auto-increment IMPL-N
|
|
58
|
-
3. **Context Inheritance**: Load workflow context
|
|
59
|
-
4. **Implementation Setup**: Initialize implementation field
|
|
60
|
-
5. **Agent Assignment**: Select appropriate agent
|
|
61
|
-
6. **File Creation**: Save JSON to .task/ directory
|
|
62
|
-
7. **Session Update**: Update workflow stats
|
|
63
|
-
|
|
64
|
-
**Task Schema**: See @~/.claude/workflows/task-core.md for complete JSON structure
|
|
65
|
-
|
|
66
|
-
## Implementation Field Setup
|
|
67
|
-
|
|
68
|
-
### Auto-Population Strategy
|
|
69
|
-
- **Detailed info**: Extract from task description and scope
|
|
70
|
-
- **Missing info**: Mark `pre_analysis` as multi-step array format for later pre-analysis
|
|
71
|
-
- **Basic structure**: Initialize with standard template
|
|
72
|
-
|
|
73
|
-
### Analysis Triggers
|
|
74
|
-
When implementation details incomplete:
|
|
75
|
-
```bash
|
|
76
|
-
Task requires analysis for implementation details
|
|
77
|
-
Suggest running: gemini analysis for file locations and dependencies
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
## File Management
|
|
81
|
-
|
|
82
|
-
### JSON Task File
|
|
83
|
-
- **Location**: `.task/IMPL-[N].json` in active session
|
|
84
|
-
- **Content**: Complete task with implementation field
|
|
85
|
-
- **Updates**: Session stats only
|
|
86
|
-
|
|
87
|
-
### Simple Process
|
|
88
|
-
1. Validate session and inputs
|
|
89
|
-
2. Generate task JSON
|
|
90
|
-
3. Update session stats
|
|
91
|
-
4. Notify completion
|
|
92
|
-
|
|
93
|
-
## Context Inheritance
|
|
94
|
-
|
|
95
|
-
Tasks inherit from:
|
|
96
|
-
1. **Active Session** - Requirements and scope from workflow-session.json
|
|
97
|
-
2. **Planning Document** - Context from IMPL_PLAN.md
|
|
98
|
-
3. **Parent Task** - For subtasks (IMPL-N.M format)
|
|
99
|
-
|
|
100
|
-
## Agent Assignment
|
|
101
|
-
|
|
102
|
-
Based on task type and title keywords:
|
|
103
|
-
- **Build/Implement** → @code-developer
|
|
104
|
-
- **Design/Plan** → @planning-agent
|
|
105
|
-
- **Test Generation** → @code-developer (type: "test-gen")
|
|
106
|
-
- **Test Execution/Fix** → @test-fix-agent (type: "test-fix")
|
|
107
|
-
- **Review/Audit** → @universal-executor (optional, only when explicitly requested)
|
|
108
|
-
|
|
109
|
-
## Validation Rules
|
|
110
|
-
|
|
111
|
-
1. **Session Check** - Active workflow session required
|
|
112
|
-
2. **Duplicate Check** - Avoid similar task titles
|
|
113
|
-
3. **ID Uniqueness** - Auto-increment task IDs
|
|
114
|
-
4. **Schema Validation** - Ensure proper JSON structure
|
|
115
|
-
|
|
116
|
-
## Error Handling
|
|
117
|
-
|
|
118
|
-
```bash
|
|
119
|
-
# No workflow session
|
|
120
|
-
No active workflow found
|
|
121
|
-
Use: /workflow init "project name"
|
|
122
|
-
|
|
123
|
-
# Duplicate task
|
|
124
|
-
Similar task exists: IMPL-3
|
|
125
|
-
Continue anyway? (y/n)
|
|
126
|
-
|
|
127
|
-
# Max depth exceeded
|
|
128
|
-
Cannot create IMPL-1.2.1 (max 2 levels)
|
|
129
|
-
Use: IMPL-2 for new main task
|
|
130
|
-
```
|
|
131
|
-
|
|
132
|
-
## Examples
|
|
133
|
-
|
|
134
|
-
### Feature Task
|
|
135
|
-
```bash
|
|
136
|
-
/task:create "Implement user authentication"
|
|
137
|
-
|
|
138
|
-
Created IMPL-1: Implement user authentication
|
|
139
|
-
Type: feature
|
|
140
|
-
Agent: code-developer
|
|
141
|
-
Status: pending
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
### Bug Fix
|
|
145
|
-
```bash
|
|
146
|
-
/task:create "Fix login validation bug" --type=bugfix
|
|
147
|
-
|
|
148
|
-
Created IMPL-2: Fix login validation bug
|
|
149
|
-
Type: bugfix
|
|
150
|
-
Agent: code-developer
|
|
151
|
-
Status: pending
|
|
152
|
-
```
|
|
@@ -1,270 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: execute
|
|
3
|
-
description: Execute task JSON using appropriate agent (@doc-generator/@implementation-agent/@test-agent) with pre-analysis context loading and status tracking
|
|
4
|
-
argument-hint: "task-id"
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Command Overview: /task:execute
|
|
8
|
-
|
|
9
|
-
**Purpose**: Executes tasks using intelligent agent selection, context preparation, and progress tracking.
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
## Execution Modes
|
|
13
|
-
|
|
14
|
-
- **auto (Default)**
|
|
15
|
-
- Fully autonomous execution with automatic agent selection.
|
|
16
|
-
- Provides progress updates at each checkpoint.
|
|
17
|
-
- Automatically completes the task when done.
|
|
18
|
-
- **guided**
|
|
19
|
-
- Executes step-by-step, requiring user confirmation at each checkpoint.
|
|
20
|
-
- Allows for dynamic adjustments and manual review during the process.
|
|
21
|
-
- **review**
|
|
22
|
-
- Optional manual review using `@universal-executor`.
|
|
23
|
-
- Used only when explicitly requested by user.
|
|
24
|
-
|
|
25
|
-
## Agent Selection Logic
|
|
26
|
-
|
|
27
|
-
The system determines the appropriate agent for a task using the following logic.
|
|
28
|
-
|
|
29
|
-
```pseudo
|
|
30
|
-
FUNCTION select_agent(task, agent_override):
|
|
31
|
-
// A manual override always takes precedence.
|
|
32
|
-
// Corresponds to the --agent=<agent-type> flag.
|
|
33
|
-
IF agent_override IS NOT NULL:
|
|
34
|
-
RETURN agent_override
|
|
35
|
-
|
|
36
|
-
// If no override, select based on keywords in the task title.
|
|
37
|
-
ELSE:
|
|
38
|
-
CASE task.title:
|
|
39
|
-
WHEN CONTAINS "Build API", "Implement":
|
|
40
|
-
RETURN "@code-developer"
|
|
41
|
-
WHEN CONTAINS "Design schema", "Plan":
|
|
42
|
-
RETURN "@planning-agent"
|
|
43
|
-
WHEN CONTAINS "Write tests", "Generate tests":
|
|
44
|
-
RETURN "@code-developer" // type: test-gen
|
|
45
|
-
WHEN CONTAINS "Execute tests", "Fix tests", "Validate":
|
|
46
|
-
RETURN "@test-fix-agent" // type: test-fix
|
|
47
|
-
WHEN CONTAINS "Review code":
|
|
48
|
-
RETURN "@universal-executor" // Optional manual review
|
|
49
|
-
DEFAULT:
|
|
50
|
-
RETURN "@code-developer" // Default agent
|
|
51
|
-
END CASE
|
|
52
|
-
END FUNCTION
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
## Core Execution Protocol
|
|
56
|
-
|
|
57
|
-
`Pre-Execution` -> `Execution` -> `Post-Execution`
|
|
58
|
-
|
|
59
|
-
### Pre-Execution Protocol
|
|
60
|
-
|
|
61
|
-
`Validate Task & Dependencies` **->** `Prepare Execution Context` **->** `Coordinate with TodoWrite`
|
|
62
|
-
|
|
63
|
-
- **Validation**: Checks for the task's JSON file in `.task/` and resolves its dependencies.
|
|
64
|
-
- **Context Preparation**: Loads task and workflow context, preparing it for the selected agent.
|
|
65
|
-
- **Session Context Injection**: Provides workflow directory paths to agents for TODO_LIST.md and summary management.
|
|
66
|
-
- **TodoWrite Coordination**: Generates execution Todos and checkpoints, syncing with `TODO_LIST.md`.
|
|
67
|
-
|
|
68
|
-
### Post-Execution Protocol
|
|
69
|
-
|
|
70
|
-
`Update Task Status` **->** `Generate Summary` **->** `Save Artifacts` **->** `Sync All Progress` **->** `Validate File Integrity`
|
|
71
|
-
|
|
72
|
-
- Updates status in the task's JSON file and `TODO_LIST.md`.
|
|
73
|
-
- Creates a summary in `.summaries/`.
|
|
74
|
-
- Stores outputs and syncs progress across the entire workflow session.
|
|
75
|
-
|
|
76
|
-
### Task & Subtask Execution Logic
|
|
77
|
-
|
|
78
|
-
This logic defines how single, multiple, or parent tasks are handled.
|
|
79
|
-
|
|
80
|
-
```pseudo
|
|
81
|
-
FUNCTION execute_task_command(task_id, mode, parallel_flag):
|
|
82
|
-
// Handle parent tasks by executing their subtasks.
|
|
83
|
-
IF is_parent_task(task_id):
|
|
84
|
-
subtasks = get_subtasks(task_id)
|
|
85
|
-
EXECUTE_SUBTASK_BATCH(subtasks, mode)
|
|
86
|
-
|
|
87
|
-
// Handle wildcard execution (e.g., IMPL-001.*)
|
|
88
|
-
ELSE IF task_id CONTAINS "*":
|
|
89
|
-
subtasks = find_matching_tasks(task_id)
|
|
90
|
-
IF parallel_flag IS true:
|
|
91
|
-
EXECUTE_IN_PARALLEL(subtasks)
|
|
92
|
-
ELSE:
|
|
93
|
-
FOR each subtask in subtasks:
|
|
94
|
-
EXECUTE_SINGLE_TASK(subtask, mode)
|
|
95
|
-
|
|
96
|
-
// Default case for a single task ID.
|
|
97
|
-
ELSE:
|
|
98
|
-
EXECUTE_SINGLE_TASK(task_id, mode)
|
|
99
|
-
END FUNCTION
|
|
100
|
-
```
|
|
101
|
-
|
|
102
|
-
### Error Handling & Recovery Logic
|
|
103
|
-
|
|
104
|
-
```pseudo
|
|
105
|
-
FUNCTION pre_execution_check(task):
|
|
106
|
-
// Ensure dependencies are met before starting.
|
|
107
|
-
IF task.dependencies ARE NOT MET:
|
|
108
|
-
LOG_ERROR("Cannot execute " + task.id)
|
|
109
|
-
LOG_INFO("Blocked by: " + unmet_dependencies)
|
|
110
|
-
HALT_EXECUTION()
|
|
111
|
-
|
|
112
|
-
FUNCTION on_execution_failure(checkpoint):
|
|
113
|
-
// Provide user with recovery options upon failure.
|
|
114
|
-
LOG_WARNING("Execution failed at checkpoint " + checkpoint)
|
|
115
|
-
PRESENT_OPTIONS([
|
|
116
|
-
"Retry from checkpoint",
|
|
117
|
-
"Retry from beginning",
|
|
118
|
-
"Switch to guided mode",
|
|
119
|
-
"Abort execution"
|
|
120
|
-
])
|
|
121
|
-
AWAIT user_input
|
|
122
|
-
// System performs the selected action.
|
|
123
|
-
END FUNCTION
|
|
124
|
-
```
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
### Simplified Context Structure (JSON)
|
|
128
|
-
|
|
129
|
-
This is the simplified data structure loaded to provide context for task execution.
|
|
130
|
-
|
|
131
|
-
```json
|
|
132
|
-
{
|
|
133
|
-
"task": {
|
|
134
|
-
"id": "IMPL-1",
|
|
135
|
-
"title": "Build authentication module",
|
|
136
|
-
"type": "feature",
|
|
137
|
-
"status": "active",
|
|
138
|
-
"agent": "code-developer",
|
|
139
|
-
"context": {
|
|
140
|
-
"requirements": ["JWT authentication", "OAuth2 support"],
|
|
141
|
-
"scope": ["src/auth/*", "tests/auth/*"],
|
|
142
|
-
"acceptance": ["Module handles JWT tokens", "OAuth2 flow implemented"],
|
|
143
|
-
"inherited_from": "WFS-user-auth"
|
|
144
|
-
},
|
|
145
|
-
"relations": {
|
|
146
|
-
"parent": null,
|
|
147
|
-
"subtasks": ["IMPL-1.1", "IMPL-1.2"],
|
|
148
|
-
"dependencies": ["IMPL-0"]
|
|
149
|
-
},
|
|
150
|
-
"implementation": {
|
|
151
|
-
"files": [
|
|
152
|
-
{
|
|
153
|
-
"path": "src/auth/login.ts",
|
|
154
|
-
"location": {
|
|
155
|
-
"function": "authenticateUser",
|
|
156
|
-
"lines": "25-65",
|
|
157
|
-
"description": "Main authentication logic"
|
|
158
|
-
},
|
|
159
|
-
"original_code": "// Code snippet extracted via gemini analysis",
|
|
160
|
-
"modifications": {
|
|
161
|
-
"current_state": "Basic password authentication only",
|
|
162
|
-
"proposed_changes": [
|
|
163
|
-
"Add JWT token generation",
|
|
164
|
-
"Implement OAuth2 callback handling",
|
|
165
|
-
"Add multi-factor authentication support"
|
|
166
|
-
],
|
|
167
|
-
"logic_flow": [
|
|
168
|
-
"validateCredentials() ───► checkUserExists()",
|
|
169
|
-
"◊─── if password ───► generateJWT() ───► return token",
|
|
170
|
-
"◊─── if OAuth ───► validateOAuthCode() ───► exchangeForToken()",
|
|
171
|
-
"◊─── if MFA ───► sendMFACode() ───► awaitVerification()"
|
|
172
|
-
],
|
|
173
|
-
"reason": "Support modern authentication standards and security requirements",
|
|
174
|
-
"expected_outcome": "Comprehensive authentication system supporting multiple methods"
|
|
175
|
-
}
|
|
176
|
-
}
|
|
177
|
-
],
|
|
178
|
-
"context_notes": {
|
|
179
|
-
"dependencies": ["jsonwebtoken", "passport", "speakeasy"],
|
|
180
|
-
"affected_modules": ["user-session", "auth-middleware", "api-routes"],
|
|
181
|
-
"risks": [
|
|
182
|
-
"Breaking changes to existing login endpoints",
|
|
183
|
-
"Token storage and rotation complexity",
|
|
184
|
-
"OAuth provider configuration dependencies"
|
|
185
|
-
],
|
|
186
|
-
"performance_considerations": "JWT validation adds ~10ms per request, OAuth callbacks may timeout",
|
|
187
|
-
"error_handling": "Ensure sensitive authentication errors don't leak user enumeration data"
|
|
188
|
-
},
|
|
189
|
-
"pre_analysis": [
|
|
190
|
-
{
|
|
191
|
-
"action": "analyze patterns",
|
|
192
|
-
"template": "~/.claude/workflows/cli-templates/prompts/analysis/02-analyze-code-patterns.txt",
|
|
193
|
-
"method": "gemini"
|
|
194
|
-
}
|
|
195
|
-
]
|
|
196
|
-
}
|
|
197
|
-
},
|
|
198
|
-
"workflow": {
|
|
199
|
-
"session": "WFS-user-auth",
|
|
200
|
-
"phase": "IMPLEMENT",
|
|
201
|
-
"session_context": {
|
|
202
|
-
"workflow_directory": ".workflow/active/WFS-user-auth/",
|
|
203
|
-
"todo_list_location": ".workflow/active/WFS-user-auth/TODO_LIST.md",
|
|
204
|
-
"summaries_directory": ".workflow/active/WFS-user-auth/.summaries/",
|
|
205
|
-
"task_json_location": ".workflow/active/WFS-user-auth/.task/"
|
|
206
|
-
}
|
|
207
|
-
},
|
|
208
|
-
"execution": {
|
|
209
|
-
"agent": "code-developer",
|
|
210
|
-
"mode": "auto",
|
|
211
|
-
"attempts": 0
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
```
|
|
215
|
-
|
|
216
|
-
### Agent-Specific Context
|
|
217
|
-
|
|
218
|
-
Different agents receive context tailored to their function, including implementation details:
|
|
219
|
-
|
|
220
|
-
**`@code-developer`**:
|
|
221
|
-
- Complete implementation.files array with file paths and locations
|
|
222
|
-
- original_code snippets and proposed_changes for precise modifications
|
|
223
|
-
- logic_flow diagrams for understanding data flow
|
|
224
|
-
- Dependencies and affected modules for integration planning
|
|
225
|
-
- Performance and error handling considerations
|
|
226
|
-
|
|
227
|
-
**`@planning-agent`**:
|
|
228
|
-
- High-level requirements, constraints, success criteria
|
|
229
|
-
- Implementation risks and mitigation strategies
|
|
230
|
-
- Architecture implications from implementation.context_notes
|
|
231
|
-
|
|
232
|
-
**`@test-fix-agent`**:
|
|
233
|
-
- Test files to execute from task.context.focus_paths
|
|
234
|
-
- Source files to fix from implementation.files[].path
|
|
235
|
-
- Expected behaviors from implementation.modifications.logic_flow
|
|
236
|
-
- Error conditions to validate from implementation.context_notes.error_handling
|
|
237
|
-
- Performance requirements from implementation.context_notes.performance_considerations
|
|
238
|
-
|
|
239
|
-
**`@universal-executor`**:
|
|
240
|
-
- Used for optional manual reviews when explicitly requested
|
|
241
|
-
- Code quality standards and implementation patterns
|
|
242
|
-
- Security considerations from implementation.context_notes.risks
|
|
243
|
-
- Dependency validation from implementation.context_notes.dependencies
|
|
244
|
-
- Architecture compliance checks
|
|
245
|
-
|
|
246
|
-
### Simplified File Output
|
|
247
|
-
|
|
248
|
-
- **Task JSON File (`.task/<task-id>.json`)**: Updated with status and last attempt time only.
|
|
249
|
-
- **Session File (`workflow-session.json`)**: Updated task stats (completed count).
|
|
250
|
-
- **Summary File**: Generated in `.summaries/` upon completion (optional).
|
|
251
|
-
|
|
252
|
-
### Simplified Summary Template
|
|
253
|
-
|
|
254
|
-
Optional summary file generated at `.summaries/IMPL-[task-id]-summary.md`.
|
|
255
|
-
|
|
256
|
-
```markdown
|
|
257
|
-
# Task Summary: IMPL-1 Build Authentication Module
|
|
258
|
-
|
|
259
|
-
## What Was Done
|
|
260
|
-
- Created src/auth/login.ts with JWT validation
|
|
261
|
-
- Added tests in tests/auth.test.ts
|
|
262
|
-
|
|
263
|
-
## Execution Results
|
|
264
|
-
- **Agent**: code-developer
|
|
265
|
-
- **Status**: completed
|
|
266
|
-
|
|
267
|
-
## Files Modified
|
|
268
|
-
- `src/auth/login.ts` (created)
|
|
269
|
-
- `tests/auth.test.ts` (created)
|
|
270
|
-
```
|