clavix 5.0.0 → 5.1.0

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.
Files changed (45) hide show
  1. package/dist/cli/commands/init.js +53 -153
  2. package/dist/cli/commands/update.js +18 -21
  3. package/dist/core/doc-injector.d.ts +2 -2
  4. package/dist/core/doc-injector.js +12 -12
  5. package/dist/index 2.js +13 -0
  6. package/dist/index.d 2.ts +4 -0
  7. package/dist/templates/agents/agents.md +29 -28
  8. package/dist/templates/agents/copilot-instructions.md +43 -38
  9. package/dist/templates/agents/octo.md +42 -38
  10. package/dist/templates/agents/warp.md +25 -26
  11. package/dist/templates/instructions/README.md +20 -19
  12. package/dist/templates/instructions/core/clavix-mode.md +10 -25
  13. package/dist/templates/instructions/core/mode-enforcement.md +10 -11
  14. package/dist/templates/slash-commands/_canonical/archive.md +1 -1
  15. package/dist/templates/slash-commands/_canonical/implement.md +227 -14
  16. package/dist/templates/slash-commands/_canonical/improve.md +7 -7
  17. package/dist/templates/slash-commands/_canonical/plan.md +9 -21
  18. package/dist/templates/slash-commands/_canonical/prd.md +1 -1
  19. package/dist/templates/slash-commands/_canonical/start.md +1 -1
  20. package/dist/templates/slash-commands/_canonical/summarize.md +3 -3
  21. package/dist/templates/slash-commands/_canonical/verify.md +14 -14
  22. package/dist/templates/slash-commands/_components/agent-protocols/decision-rules.md +5 -6
  23. package/dist/templates/slash-commands/_components/agent-protocols/state-awareness.md +5 -7
  24. package/dist/templates/slash-commands/_components/troubleshooting/vibecoder-recovery.md +2 -2
  25. package/dist/utils/agent-error-messages.js +13 -12
  26. package/package.json +1 -1
  27. package/dist/templates/slash-commands/_canonical/execute.md +0 -276
  28. package/dist/templates/slash-commands/_components/agent-protocols/assertion-checkpoints.md +0 -122
  29. package/dist/templates/slash-commands/_components/agent-protocols/file-formats.md +0 -169
  30. package/dist/templates/slash-commands/_components/agent-protocols/quality-output.md +0 -94
  31. package/dist/templates/slash-commands/_components/agent-protocols/self-correction.md +0 -61
  32. package/dist/templates/slash-commands/_components/agent-protocols/state-assertion.md +0 -51
  33. package/dist/templates/slash-commands/_components/agent-protocols/verification-methods.md +0 -184
  34. package/dist/templates/slash-commands/_components/mode-headers/implementation-mode.md +0 -21
  35. package/dist/templates/slash-commands/_components/mode-headers/planning-mode.md +0 -17
  36. package/dist/templates/slash-commands/_components/mode-headers/self-correction.md +0 -13
  37. package/dist/templates/slash-commands/_components/references/intent-types.md +0 -39
  38. package/dist/templates/slash-commands/_components/sections/file-saving-protocol.md +0 -40
  39. package/dist/templates/slash-commands/_components/sections/intent-detection.md +0 -24
  40. package/dist/templates/slash-commands/_components/sections/pattern-visibility.md +0 -122
  41. package/dist/templates/slash-commands/_components/sections/quality-assessment.md +0 -26
  42. package/dist/templates/slash-commands/_components/sections/workflow-navigation.md +0 -13
  43. package/dist/templates/slash-commands/_components/troubleshooting/file-not-saved.md +0 -19
  44. package/dist/templates/slash-commands/_components/troubleshooting/mode-confusion.md +0 -46
  45. package/dist/templates/slash-commands/_components/troubleshooting/triage-escalation.md +0 -26
@@ -4,7 +4,7 @@ These instructions enhance GitHub Copilot's understanding of Clavix prompt optim
4
4
 
5
5
  ---
6
6
 
7
- ## ⛔ CLAVIX MODE ENFORCEMENT (v4.7)
7
+ ## ⛔ CLAVIX MODE ENFORCEMENT
8
8
 
9
9
  **CRITICAL: Know which mode you're in and STOP at the right point.**
10
10
 
@@ -12,7 +12,7 @@ These instructions enhance GitHub Copilot's understanding of Clavix prompt optim
12
12
  - Fast/deep optimization - Prompt improvement only
13
13
  - Your role: Analyze, optimize, show improved prompt, **STOP**
14
14
  - ❌ DO NOT implement the prompt's requirements
15
- - ✅ After showing optimized prompt, tell user: "Run `/clavix:execute --latest` to implement"
15
+ - ✅ After showing optimized prompt, tell user: "Run `/clavix:implement --latest` to implement"
16
16
 
17
17
  **PLANNING workflows** (NO CODE ALLOWED):
18
18
  - Conversational mode, requirement extraction, PRD generation
@@ -38,8 +38,7 @@ For complete step-by-step workflows, see `.clavix/instructions/`:
38
38
  |----------|-----------------|---------|
39
39
  | **Conversational Mode** | `workflows/start.md` | Natural requirements gathering through discussion |
40
40
  | **Extract Requirements** | `workflows/summarize.md` | Analyze conversation → mini-PRD + optimized prompts |
41
- | **Quick Optimization** | `workflows/fast.md` | Intent detection + quality assessment + smart triage |
42
- | **Deep Analysis** | `workflows/deep.md` | Comprehensive with alternatives, validation, edge cases |
41
+ | **Prompt Optimization** | `workflows/improve.md` | Intent detection + quality assessment + auto-depth selection |
43
42
  | **PRD Generation** | `workflows/prd.md` | Socratic questions → full PRD + quick PRD |
44
43
  | **Mode Boundaries** | `core/clavix-mode.md` | Planning vs implementation distinction |
45
44
 
@@ -54,33 +53,39 @@ For complete step-by-step workflows, see `.clavix/instructions/`:
54
53
 
55
54
  ---
56
55
 
57
- ## 📋 CLI Quick Reference
56
+ ## 📋 Clavix Commands (v5)
58
57
 
58
+ ### Setup Commands (CLI)
59
59
  | Command | Purpose |
60
60
  |---------|---------|
61
- | `clavix fast "<prompt>"` | Quick optimization (CLI auto-saves; slash commands require manual saving per template instructions) |
62
- | `clavix deep "<prompt>"` | Deep analysis (CLI auto-saves; slash commands require manual saving per template instructions) |
63
- | `clavix execute [--latest]` | Execute saved prompts (--latest, --fast, --deep, --id supported) |
64
- | `clavix prompts list` | View saved prompts with status (NEW, EXECUTED, OLD, STALE) |
65
- | `clavix prompts clear` | Manage cleanup (--executed, --stale, --fast, --deep, --all, --force) |
66
- | `clavix prd` | Guided PRD generation |
67
- | `clavix plan` | Transform PRD → tasks |
68
- | `clavix implement [--commit-strategy]` | Execute tasks |
69
- | `clavix start` | Begin conversational session |
70
- | `clavix summarize [session-id]` | Extract PRD from session |
71
- | `clavix list` | List sessions/outputs |
72
- | `clavix archive [project]` | Archive/restore projects |
73
- | `clavix update` | Refresh documentation |
61
+ | `clavix init` | Initialize Clavix in a project |
62
+ | `clavix update` | Update templates after package update |
63
+ | `clavix config` | Manage configuration |
64
+ | `clavix version` | Show version |
65
+
66
+ ### Workflow Commands (Slash Commands)
67
+ All workflows are executed via slash commands:
68
+
69
+ | Slash Command | Purpose |
70
+ |---------------|---------|
71
+ | `/clavix:improve` | Optimize prompts (auto-selects depth) |
72
+ | `/clavix:prd` | Generate PRD through guided questions |
73
+ | `/clavix:plan` | Create task breakdown from PRD |
74
+ | `/clavix:implement` | Execute tasks or prompts (auto-detects source) |
75
+ | `/clavix:start` | Begin conversational session |
76
+ | `/clavix:summarize` | Extract requirements from conversation |
77
+ | `/clavix:verify` | Verify implementation |
78
+ | `/clavix:archive` | Archive completed projects |
74
79
 
75
80
  ---
76
81
 
77
- ## 🔄 Prompt Lifecycle Management (v2.7+)
82
+ ## 🔄 Prompt Lifecycle Workflow
78
83
 
79
- **Prompt Lifecycle Workflow:**
80
- 1. **Optimize**: `clavix fast/deep "<prompt>"` → CLI auto-saves; slash commands require manual saving per template instructions
81
- 2. **Review**: `clavix prompts list` View all saved prompts with status
82
- 3. **Execute**: `clavix execute --latest` → Implement when ready
83
- 4. **Cleanup**: `clavix prompts clear --executed` Remove completed prompts
84
+ **Prompt Lifecycle:**
85
+ 1. **Optimize**: `/clavix:improve` → Analyzes and improves your prompt
86
+ 2. **Review**: Agent reads `.clavix/outputs/prompts/*.md` to list saved prompts
87
+ 3. **Execute**: `/clavix:implement --latest` → Implement when ready
88
+ 4. **Cleanup**: Agent deletes old prompt files from `.clavix/outputs/prompts/`
84
89
 
85
90
  ---
86
91
 
@@ -94,10 +99,10 @@ PRD Creation → Task Planning → Implementation → Archive
94
99
 
95
100
  **Detailed steps:**
96
101
 
97
- 1. **Planning Phase** - User creates PRD (conversational or direct)
98
- 2. **Task Preparation** - `clavix plan` transforms PRD into tasks.md
99
- 3. **Implementation Phase** - `clavix implement` executes tasks systematically
100
- 4. **Completion** - `clavix archive` archives completed work
102
+ 1. **Planning Phase** - `/clavix:prd` or `/clavix:start` `/clavix:summarize`
103
+ 2. **Task Preparation** - `/clavix:plan` transforms PRD into tasks.md
104
+ 3. **Implementation Phase** - `/clavix:implement` executes tasks systematically
105
+ 4. **Completion** - `/clavix:archive` archives completed work
101
106
 
102
107
  **Key principle:** Planning workflows create documents. Implementation workflows write code.
103
108
 
@@ -113,17 +118,17 @@ When analyzing prompts, consider these 5 dimensions:
113
118
  - **Completeness**: All specs provided (persona, format, tone, success criteria)?
114
119
  - **Actionability**: Can AI take immediate action?
115
120
 
116
- **Reference:** See `workflows/fast.md` for complete quality assessment patterns
121
+ **Reference:** See `workflows/improve.md` for complete quality assessment patterns
117
122
 
118
123
  ---
119
124
 
120
125
  ## 💡 Best Practices for GitHub Copilot
121
126
 
122
- 1. **Suggest appropriate workflow** - Fast for simple prompts, deep for complex, PRD for strategic
127
+ 1. **Suggest appropriate workflow** - `/clavix:improve` for prompts, `/clavix:prd` for strategic planning
123
128
  2. **Reference instruction files** - Point to `.clavix/instructions/workflows/*.md` instead of recreating steps
124
129
  3. **Respect mode boundaries** - Planning mode = no code, Implementation mode = write code
125
130
  4. **Use quality dimensions** - Apply 5-dimension assessment principles in responses
126
- 5. **Guide users to CLI** - Recommend appropriate `clavix` commands for their needs
131
+ 5. **Guide users to slash commands** - Recommend appropriate `/clavix:*` commands for their needs
127
132
 
128
133
  ---
129
134
 
@@ -132,17 +137,17 @@ When analyzing prompts, consider these 5 dimensions:
132
137
  ### ❌ Jumping to implementation during planning
133
138
  **Wrong:** User discusses feature → Copilot generates code immediately
134
139
 
135
- **Right:** User discusses feature → Suggest `clavix prd` or `clavix start` → Create planning docs first
140
+ **Right:** User discusses feature → Suggest `/clavix:prd` or `/clavix:start` → Create planning docs first
136
141
 
137
142
  ### ❌ Not suggesting Clavix workflows
138
143
  **Wrong:** User asks "How should I phrase this?" → Copilot provides generic advice
139
144
 
140
- **Right:** User asks "How should I phrase this?" → Suggest `clavix fast "<prompt>"` for quality assessment
145
+ **Right:** User asks "How should I phrase this?" → Suggest `/clavix:improve` for quality assessment
141
146
 
142
147
  ### ❌ Recreating workflow steps inline
143
148
  **Wrong:** Copilot explains entire PRD generation process in chat
144
149
 
145
- **Right:** Copilot references `.clavix/instructions/workflows/prd.md` and suggests running `clavix prd`
150
+ **Right:** Copilot references `.clavix/instructions/workflows/prd.md` and suggests running `/clavix:prd`
146
151
 
147
152
  ---
148
153
 
@@ -151,7 +156,7 @@ When analyzing prompts, consider these 5 dimensions:
151
156
  When users ask for help with prompts or requirements:
152
157
 
153
158
  1. **Detect need** - Identify if user needs planning, optimization, or implementation
154
- 2. **Suggest command** - Recommend appropriate `clavix` command
159
+ 2. **Suggest slash command** - Recommend appropriate `/clavix:*` command
155
160
  3. **Explain benefit** - Describe expected output and value
156
161
  4. **Help interpret** - Assist with understanding Clavix-generated outputs
157
162
  5. **Apply principles** - Use quality dimensions in your responses
@@ -159,10 +164,10 @@ When users ask for help with prompts or requirements:
159
164
  **Example flow:**
160
165
  ```
161
166
  User: "I want to build a dashboard but I'm not sure how to phrase the requirements"
162
- Copilot: "I suggest running `clavix start` to begin conversational requirements gathering.
167
+ Copilot: "I suggest running `/clavix:start` to begin conversational requirements gathering.
163
168
  This will help us explore your needs naturally, then we can extract structured requirements
164
- with `clavix summarize`. Alternatively, if you have a rough idea, try:
165
- clavix fast 'Build a dashboard for...' for quick optimization."
169
+ with `/clavix:summarize`. Alternatively, if you have a rough idea, try:
170
+ `/clavix:improve 'Build a dashboard for...'` for quick optimization."
166
171
  ```
167
172
 
168
173
  ---
@@ -4,7 +4,7 @@ Clavix workflows optimized for Octofriend's capabilities: model switching, multi
4
4
 
5
5
  ---
6
6
 
7
- ## ⛔ CLAVIX MODE ENFORCEMENT (v4.11)
7
+ ## ⛔ CLAVIX MODE ENFORCEMENT
8
8
 
9
9
  **CRITICAL: Know which mode you're in and STOP at the right point.**
10
10
 
@@ -12,7 +12,7 @@ Clavix workflows optimized for Octofriend's capabilities: model switching, multi
12
12
  - `/clavix:improve` - Prompt optimization with smart depth auto-selection
13
13
  - Your role: Analyze, optimize, show improved prompt, **STOP**
14
14
  - ❌ DO NOT implement the prompt's requirements
15
- - ✅ After showing optimized prompt, tell user: "Run `/clavix:execute --latest` to implement"
15
+ - ✅ After showing optimized prompt, tell user: "Run `/clavix:implement --latest` to implement"
16
16
 
17
17
  **PLANNING workflows** (NO CODE ALLOWED):
18
18
  - `/clavix:start`, `/clavix:summarize`, `/clavix:prd`, `/clavix:plan`
@@ -20,9 +20,10 @@ Clavix workflows optimized for Octofriend's capabilities: model switching, multi
20
20
  - ❌ DO NOT implement features during these workflows
21
21
 
22
22
  **IMPLEMENTATION workflows** (CODE ALLOWED):
23
- - `/clavix:implement`, `/clavix:execute`, `clavix task-complete`
23
+ - `/clavix:implement`
24
24
  - Your role: Write code, execute tasks, implement features
25
25
  - ✅ DO implement code during these workflows
26
+ - Mark task completion by editing tasks.md directly (`- [ ]` → `- [x]`)
26
27
 
27
28
  See `.clavix/instructions/core/clavix-mode.md` for complete mode documentation.
28
29
 
@@ -115,35 +116,39 @@ Autofix handles edge cases gracefully - let it work.
115
116
 
116
117
  ---
117
118
 
118
- ## 📋 CLI Quick Reference
119
-
120
- | Command | Purpose | Output |
121
- |---------|---------|--------|
122
- | `clavix init` | Setup Clavix in project | `.clavix/config.json` |
123
- | `clavix prd` | Generate PRD through questions | `full-prd.md` + `quick-prd.md` |
124
- | `clavix fast "<prompt>"` | Quick prompt improvement (CLI auto-saves prompts; Slash commands require manual saving per template instructions) | Saved to `.clavix/outputs/prompts/fast/` |
125
- | `clavix deep "<prompt>"` | Comprehensive analysis (CLI auto-saves prompts; Slash commands require manual saving per template instructions) | Saved to `.clavix/outputs/prompts/deep/` |
126
- | `clavix execute [--latest]` | Execute prompt (interactive or --latest for most recent) | Implementation |
127
- | `clavix prompts list` | View all saved prompts with status | NEW, EXECUTED, OLD, STALE |
128
- | `clavix prompts clear` | Manage cleanup (--executed, --stale, --fast, --deep, --all) | Cleanup report |
129
- | `clavix start` | Conversational requirements | Session captured |
130
- | `clavix summarize` | Extract from conversation | `mini-prd.md` + prompts |
131
- | `clavix plan` | Generate tasks from PRD | `tasks.md` |
132
- | `clavix implement` | Execute tasks | Implementation + commits |
133
- | `clavix list` | Show sessions/outputs | List view |
134
- | `clavix update` | Refresh documentation | Updates managed files |
119
+ ## 📋 Clavix Commands (v5)
120
+
121
+ ### Setup Commands (CLI)
122
+ | Command | Purpose |
123
+ |---------|---------|
124
+ | `clavix init` | Initialize Clavix in a project |
125
+ | `clavix update` | Update templates after package update |
126
+ | `clavix config` | Manage configuration |
127
+ | `clavix version` | Show version |
128
+
129
+ ### Workflow Commands (Slash Commands)
130
+ | Slash Command | Purpose |
131
+ |---------------|---------|
132
+ | `/clavix:improve` | Optimize prompts (auto-selects depth) |
133
+ | `/clavix:prd` | Generate PRD through questions |
134
+ | `/clavix:plan` | Create task breakdown from PRD |
135
+ | `/clavix:implement` | Execute tasks or prompts (auto-detects source) |
136
+ | `/clavix:start` | Begin conversational session |
137
+ | `/clavix:summarize` | Extract requirements from conversation |
138
+ | `/clavix:verify` | Verify implementation |
139
+ | `/clavix:archive` | Archive completed projects |
135
140
 
136
141
  ---
137
142
 
138
143
  ## 🔄 Prompt Execution Workflow
139
144
 
140
- **When you have a saved prompt to execute prompt:**
145
+ **When you have a saved prompt to execute:**
141
146
 
142
- 1. **List available prompts**: `clavix prompts list` - See all saved prompts with status
143
- 2. **execute prompt**: `clavix execute --latest` - implement saved prompt interactively
144
- 3. **implement saved prompt**: Agent executes the optimized prompt and implements the feature
147
+ 1. **List available prompts**: List files in `.clavix/outputs/prompts/*.md`
148
+ 2. **Execute prompt**: `/clavix:implement --latest` - implement saved prompt
149
+ 3. **Implement**: Agent reads the optimized prompt and implements the feature
145
150
 
146
- **Note:** CLI auto-saves prompts from fast/deep commands. Slash commands require manual saving per template instructions.
151
+ **Note:** Slash commands save prompts as `.md` files with frontmatter metadata.
147
152
 
148
153
  ---
149
154
 
@@ -151,26 +156,25 @@ Autofix handles edge cases gracefully - let it work.
151
156
 
152
157
  **Complete project flow:**
153
158
 
154
- 1. **Planning** (`clavix prd`)
159
+ 1. **Planning** (`/clavix:prd`)
155
160
  - Creates PRD (full + quick versions)
156
161
  - Saves to `.clavix/outputs/{project}/`
157
162
 
158
- 2. **Task Preparation** (`clavix plan`)
163
+ 2. **Task Preparation** (`/clavix:plan`)
159
164
  - Transforms PRD → curated tasks.md
160
165
  - Phase-based organization
161
166
 
162
- 3. **Implementation** (`clavix implement`)
167
+ 3. **Implementation** (`/clavix:implement`)
163
168
  - Agent executes tasks systematically
164
- - Uses `clavix task-complete` for progress
169
+ - Marks progress by editing tasks.md (`- [ ]` `- [x]`)
165
170
  - Optional git commit strategies
166
171
 
167
- 4. **Completion** (`clavix archive`)
172
+ 4. **Completion** (`/clavix:archive`)
168
173
  - Archives completed project
169
174
 
170
175
  **Alternative quick paths:**
171
- - **Quick improvement**: `clavix fast` → `clavix execute` → Done
172
- - **Deep analysis**: `clavix deep` → `clavix execute` → Done
173
- - **Conversational**: `clavix start` → `clavix summarize` → `clavix execute` → Done
176
+ - **Quick improvement**: `/clavix:improve` → `/clavix:implement --latest` → Done
177
+ - **Conversational**: `/clavix:start` → `/clavix:summarize` → `/clavix:implement` → Done
174
178
 
175
179
  ---
176
180
 
@@ -189,9 +193,9 @@ Autofix handles edge cases gracefully - let it work.
189
193
  ## ⚠️ Common Mistakes
190
194
 
191
195
  ### ❌ Implementing during planning workflows
192
- **Wrong:** User runs `clavix prd`, you generate PRD then start building features
196
+ **Wrong:** User runs `/clavix:prd`, you generate PRD then start building features
193
197
 
194
- **Right:** User runs `clavix prd`, you generate PRD, save files, suggest `clavix plan` as next step
198
+ **Right:** User runs `/clavix:prd`, you generate PRD, save files, suggest `/clavix:plan` as next step
195
199
 
196
200
  ### ❌ Skipping file creation
197
201
  **Wrong:** Display optimized prompt, stop there
@@ -201,7 +205,7 @@ Autofix handles edge cases gracefully - let it work.
201
205
  ### ❌ Not referencing instruction files
202
206
  **Wrong:** Trying to remember workflow details from this file
203
207
 
204
- **Right:** "See `.clavix/instructions/workflows/fast.md` for complete workflow"
208
+ **Right:** "See `.clavix/instructions/workflows/improve.md` for complete workflow"
205
209
 
206
210
  ### ❌ Using wrong model for task
207
211
  **Wrong:** Using fast model for complex architectural planning
@@ -212,9 +216,9 @@ Autofix handles edge cases gracefully - let it work.
212
216
 
213
217
  ## 🆘 When in Doubt
214
218
 
215
- 1. **Check which command was run** - Determines your mode (planning vs implementation)
219
+ 1. **Check which slash command was run** - Determines your mode (planning vs implementation)
216
220
  2. **Reference instruction files** - They have complete step-by-step guidance
217
- 3. **Ask the user** - "Should I implement this (run `clavix implement`), or continue planning?"
221
+ 3. **Ask the user** - "Should I implement this (run `/clavix:implement`), or continue planning?"
218
222
  4. **Switch models** - Use thinking models for complex planning tasks
219
223
 
220
224
  ---
@@ -4,7 +4,7 @@ Clavix helps Warp developers turn rough ideas into quality, AI-ready prompts and
4
4
 
5
5
  ---
6
6
 
7
- ### ⛔ CLAVIX MODE ENFORCEMENT (v4.7)
7
+ ### ⛔ CLAVIX MODE ENFORCEMENT
8
8
 
9
9
  **CRITICAL: Know which mode you're in and STOP at the right point.**
10
10
 
@@ -12,7 +12,7 @@ Clavix helps Warp developers turn rough ideas into quality, AI-ready prompts and
12
12
  - Fast/deep optimization - Prompt improvement only
13
13
  - Your role: Analyze, optimize, show improved prompt, **STOP**
14
14
  - ❌ DO NOT implement the prompt's requirements
15
- - ✅ After showing optimized prompt, tell user: "Run `/clavix:execute --latest` to implement"
15
+ - ✅ After showing optimized prompt, tell user: "Run `/clavix:implement --latest` to implement"
16
16
 
17
17
  **PLANNING workflows** (NO CODE ALLOWED):
18
18
  - Conversational mode, requirement extraction, PRD generation
@@ -33,8 +33,7 @@ See `.clavix/instructions/core/clavix-mode.md` for complete mode documentation.
33
33
  For complete step-by-step workflows, see `.clavix/instructions/`:
34
34
  - `.clavix/instructions/workflows/start.md` - Conversational mode
35
35
  - `.clavix/instructions/workflows/summarize.md` - Extract requirements
36
- - `.clavix/instructions/workflows/fast.md` - Quick prompt optimization
37
- - `.clavix/instructions/workflows/deep.md` - Comprehensive analysis
36
+ - `.clavix/instructions/workflows/improve.md` - Prompt optimization (auto-depth)
38
37
  - `.clavix/instructions/workflows/prd.md` - PRD generation
39
38
  - `.clavix/instructions/troubleshooting/` - Common issues
40
39
 
@@ -47,25 +46,25 @@ For complete step-by-step workflows, see `.clavix/instructions/`:
47
46
  - Or run ad hoc: `npx clavix@latest init`
48
47
  - Verify setup: `clavix version`
49
48
 
50
- ### Common commands
51
- - `clavix init` interactive integration setup (regenerates docs & commands)
52
- - `clavix fast "<prompt>"` – quick quality assessment (5 dimensions) and improved prompt. CLI auto-saves; slash commands need manual saving per template instructions.
53
- - `clavix deep "<prompt>"` comprehensive analysis with alternatives, edge cases, and validation checklists. CLI auto-saves; slash commands need manual saving per template instructions.
54
- - `clavix execute [--latest]` execute saved prompts from fast/deep. Interactive selection or `--latest` for most recent.
55
- - `clavix prompts list` view all saved prompts with age/status (NEW, EXECUTED, OLD, STALE)
56
- - `clavix prompts clear [--executed|--stale|--fast|--deep]` cleanup executed or old prompts
57
- - `clavix prd` – answer focused questions to create full/quick PRDs
58
- - `clavix plan` – transform PRDs or sessions into task lists
59
- - `clavix implement [--commit-strategy=<type>]` execute tasks (git: per-task, per-5-tasks, per-phase, none [default])
60
- - `clavix task-complete <taskId>` – mark task completed with validation and optional git commit
61
- - `clavix start` capture requirement conversations in Warp
62
- - `clavix summarize [session-id]` extract mini PRDs and optimized prompts
63
- - `clavix list` list sessions/outputs (`--sessions`, `--outputs`, `--archived`)
64
- - `clavix show [session-id]` inspect sessions or use `--output <project>`
65
- - `clavix archive [project]` archive projects (or `--restore` to bring them back)
66
- - `clavix config get|set|edit|reset` manage `.clavix/config.json`
67
- - `clavix update` refresh documentation/commands (`--docs-only`, `--commands-only`)
68
- - `clavix version` print installed CLI version
49
+ ### CLI Commands (v5)
50
+ | Command | Purpose |
51
+ |---------|---------|
52
+ | `clavix init` | Initialize Clavix in a project |
53
+ | `clavix update` | Update templates after package update |
54
+ | `clavix config` | Manage configuration |
55
+ | `clavix version` | Show version |
56
+
57
+ ### Slash Commands (Workflows)
58
+ | Slash Command | Purpose |
59
+ |---------------|---------|
60
+ | `/clavix:improve` | Optimize prompts (auto-selects depth) |
61
+ | `/clavix:prd` | Generate PRD through guided questions |
62
+ | `/clavix:plan` | Create task breakdown from PRD |
63
+ | `/clavix:implement` | Execute tasks or prompts (auto-detects source) |
64
+ | `/clavix:start` | Begin conversational session |
65
+ | `/clavix:summarize` | Extract requirements from conversation |
66
+ | `/clavix:verify` | Verify implementation |
67
+ | `/clavix:archive` | Archive completed projects |
69
68
 
70
69
  ### Outputs
71
70
  - Project artifacts live under `.clavix/outputs/<project>/`
@@ -86,14 +85,14 @@ For complete step-by-step workflows, see `.clavix/instructions/`:
86
85
  ### ⚠️ Common Mistakes
87
86
 
88
87
  #### ❌ Jumping to implementation during planning
89
- **Wrong:** User runs `clavix prd`, you generate PRD then start building features
88
+ **Wrong:** User runs `/clavix:prd`, you generate PRD then start building features
90
89
 
91
- **Right:** User runs `clavix prd`, you generate PRD, save files, suggest `clavix plan` as next step
90
+ **Right:** User runs `/clavix:prd`, you generate PRD, save files, suggest `/clavix:plan` as next step
92
91
 
93
92
  #### ❌ Not referencing instruction files
94
93
  **Wrong:** Trying to remember workflow details from this file
95
94
 
96
- **Right:** "See `.clavix/instructions/workflows/fast.md` for complete workflow"
95
+ **Right:** "See `.clavix/instructions/workflows/improve.md` for complete workflow"
97
96
 
98
97
  ---
99
98
 
@@ -4,7 +4,7 @@ This directory contains the complete instruction set for AI agents consuming Cla
4
4
 
5
5
  ---
6
6
 
7
- ## 📐 Documentation Architecture (v4.11)
7
+ ## 📐 Documentation Architecture
8
8
 
9
9
  ```
10
10
  Canonical Templates (SOURCE OF TRUTH)
@@ -14,8 +14,7 @@ Canonical Templates (SOURCE OF TRUTH)
14
14
  ├── start.md - Conversational mode entry
15
15
  ├── summarize.md - Extract requirements from conversation
16
16
  ├── plan.md - Task breakdown from PRD
17
- ├── implement.md - Execute tasks with progress tracking
18
- ├── execute.md - Run saved prompts
17
+ ├── implement.md - Execute tasks or prompts (auto-detection)
19
18
  ├── verify.md - Post-implementation verification
20
19
  └── archive.md - Archive completed projects
21
20
  ↓ (referenced by)
@@ -133,16 +132,18 @@ PRD Creation → Task Planning → Implementation → Verification → Archive
133
132
  | `/clavix:prd` | Planning | ✗ NO |
134
133
  | `/clavix:plan` | Planning | ✗ NO |
135
134
  | `/clavix:implement` | Implementation | ✓ YES |
136
- | `/clavix:execute` | Implementation | ✓ YES |
137
135
  | `/clavix:verify` | Verification | Context-dependent |
138
136
  | `/clavix:archive` | Management | ✗ NO |
139
137
 
140
- ### Agent-Only Commands (No Slash Command)
138
+ ### Agent Operations (v5 Agentic-First)
141
139
 
142
- | CLI Command | Purpose | Invoked By |
143
- |-------------|---------|------------|
144
- | `clavix analyze` | Internal prompt analysis | `improve` workflow |
145
- | `clavix task-complete` | Mark task done | `implement` workflow |
140
+ In v5, agents use native tools (Write, Edit, Bash) instead of CLI commands:
141
+
142
+ | Operation | How Agent Performs It |
143
+ |-----------|----------------------|
144
+ | Save prompt | Use Write tool to create `.clavix/outputs/prompts/<id>.md` |
145
+ | Mark task done | Use Edit tool to change `- [ ]` to `- [x]` in tasks.md |
146
+ | Archive project | Use Bash tool to move directory to archive/ |
146
147
 
147
148
  ---
148
149
 
@@ -174,14 +175,14 @@ PRD Creation → Task Planning → Implementation → Verification → Archive
174
175
 
175
176
  ### Preventing the "Half-Update" Problem
176
177
 
177
- The v4.11.2 release introduced validation to catch incomplete updates:
178
+ Clavix includes validation to catch incomplete updates:
178
179
 
179
180
  ```bash
180
181
  # Run before committing
181
182
  npm run validate:consistency
182
183
 
183
184
  # Checks performed:
184
- # - No legacy command references (fast, deep commands removed in v4.11)
185
+ # - No legacy command references (removed deprecated commands)
185
186
  # - All CLI commands have templates (if required)
186
187
  # - All templates have CLI implementations
187
188
  # - No deprecated version references
@@ -240,12 +241,12 @@ npm run validate:consistency
240
241
 
241
242
  ### "Legacy command references found"
242
243
 
243
- **Root cause:** Template not updated during v4.11 migration
244
+ **Root cause:** Template not updated during migration
244
245
 
245
246
  **Fix:**
246
247
  1. Run `npm run validate:consistency` to find all occurrences
247
- 2. Replace legacy fast/deep commands with `clavix improve`
248
- 3. Replace "fast mode"/"deep mode" with "standard depth"/"comprehensive depth"
248
+ 2. Replace legacy commands with current equivalents (e.g., `/clavix:implement`)
249
+ 3. Replace deprecated terminology (e.g., "fast mode" "standard depth")
249
250
  4. Update any navigation references
250
251
 
251
252
  ### "Template doesn't match CLI behavior"
@@ -264,14 +265,14 @@ npm run validate:consistency
264
265
  ## 📚 Key Files Reference
265
266
 
266
267
  ### Canonical Templates (Start Here)
267
- - `improve.md` - Unified prompt optimization (v4.11)
268
+ - `improve.md` - Unified prompt optimization
268
269
  - `prd.md` - PRD generation workflow
269
- - `implement.md` - Task execution workflow
270
+ - `implement.md` - Task and prompt execution workflow
270
271
 
271
272
  ### Agent Protocols
272
- - `_components/agent-protocols/self-correction.md` - Mistake detection
273
- - `_components/agent-protocols/state-awareness.md` - Workflow state tracking
274
273
  - `_components/agent-protocols/decision-rules.md` - Decision logic
274
+ - `_components/agent-protocols/state-awareness.md` - Workflow state tracking
275
+ - `_components/agent-protocols/error-handling.md` - Error recovery patterns
275
276
 
276
277
  ### Validation
277
278
  - `scripts/validate-consistency.ts` - TypeScript ↔ Template validator
@@ -279,6 +280,6 @@ npm run validate:consistency
279
280
 
280
281
  ---
281
282
 
282
- **Last updated:** v4.11.2 (November 2025)
283
+ **Last updated:** v5.1.0
283
284
 
284
285
  **Validation:** Run `npm run validate:consistency` before committing changes.
@@ -20,7 +20,7 @@ Clavix has **two distinct modes** based on the command type:
20
20
 
21
21
  ### CLAVIX IMPLEMENTATION MODE (Code Execution)
22
22
 
23
- **Commands:** `/clavix:implement`, `/clavix:execute`, `/clavix:task-complete`
23
+ **Commands:** `/clavix:implement`
24
24
 
25
25
  **Your role:**
26
26
  - Write code and implement features
@@ -44,8 +44,6 @@ Clavix has **two distinct modes** based on the command type:
44
44
  | `/clavix:prd` | Planning | ✗ NO |
45
45
  | `/clavix:plan` | Planning (Pre-Implementation) | ✗ NO |
46
46
  | `/clavix:implement` | Implementation | ✓ YES |
47
- | `/clavix:execute` | Implementation | ✓ YES |
48
- | `/clavix:task-complete` | Implementation | ✓ YES |
49
47
 
50
48
  ---
51
49
 
@@ -87,9 +85,9 @@ Clavix has **two distinct modes** based on the command type:
87
85
  - Output: `.clavix/outputs/{project}/tasks.md`
88
86
 
89
87
  3. **Implementation Phase** (`/clavix:implement`)
90
- - Agent executes tasks systematically
88
+ - Agent executes tasks or prompts systematically (auto-detects source)
91
89
  - Mode: IMPLEMENTATION
92
- - Uses `task-complete` to mark progress
90
+ - Agent edits tasks.md directly (`- [ ]` → `- [x]`) to mark progress
93
91
 
94
92
  4. **Completion** (`/clavix:archive`)
95
93
  - Archives completed project
@@ -104,7 +102,7 @@ Clavix has **two distinct modes** based on the command type:
104
102
  **User says:** "Now implement this" or "Build this feature"
105
103
  → **Switch to IMPLEMENTATION MODE** if not already in implementation command
106
104
 
107
- **User runs:** `/clavix:implement` or `/clavix:execute`
105
+ **User runs:** `/clavix:implement`
108
106
  → **You are in IMPLEMENTATION MODE** - write code
109
107
 
110
108
  **User runs:** `/clavix:prd` or `/clavix:improve` or `/clavix:start`
@@ -199,21 +197,7 @@ export function TodoApp() {
199
197
 
200
198
  ---
201
199
 
202
- ### Scenario 4: User Runs Execute Command
203
-
204
- **Command:** `/clavix:execute` or `/clavix:execute --latest`
205
-
206
- **Your mode:** CLAVIX IMPLEMENTATION MODE
207
-
208
- **Actions:**
209
- - Load saved prompt from fast/deep workflow
210
- - Implement the feature described in the prompt
211
- - Write actual code
212
- - Complete the implementation
213
-
214
- ---
215
-
216
- ### Scenario 5: Ambiguous Request During Planning
200
+ ### Scenario 4: Ambiguous Request During Planning
217
201
 
218
202
  **User:** "What do you think about adding real-time updates?"
219
203
 
@@ -230,14 +214,14 @@ export function TodoApp() {
230
214
 
231
215
  ---
232
216
 
233
- ### Scenario 6: User Gives Direct Implementation Request
217
+ ### Scenario 5: User Gives Direct Implementation Request
234
218
 
235
219
  **User:** "Now implement this feature" or "Build the dashboard we discussed"
236
220
 
237
221
  **Your mode:** Check context first
238
222
 
239
223
  **If no `/clavix:implement` command was run:**
240
- - Suggest: "To implement this, please run `/clavix:implement` or `/clavix:execute`. This ensures proper task tracking and file management."
224
+ - Suggest: "To implement this, please run `/clavix:implement`. This ensures proper task tracking and file management."
241
225
 
242
226
  **If `/clavix:implement` command was run:**
243
227
  - You're already in CLAVIX IMPLEMENTATION MODE
@@ -261,13 +245,14 @@ If you catch yourself implementing during a Clavix workflow:
261
245
 
262
246
  **Two distinct Clavix modes:**
263
247
 
264
- 1. **CLAVIX PLANNING MODE** (`start`, `summarize`, `fast`, `deep`, `prd`, `plan`)
248
+ 1. **CLAVIX PLANNING MODE** (`start`, `summarize`, `improve`, `prd`, `plan`)
265
249
  - Create PRDs, prompts, documentation
266
250
  - DO NOT implement features
267
251
 
268
- 2. **CLAVIX IMPLEMENTATION MODE** (`implement`, `execute`, `task-complete`)
252
+ 2. **CLAVIX IMPLEMENTATION MODE** (`implement`)
269
253
  - Write code and build features
270
254
  - DO implement what's been planned
255
+ - Auto-detects tasks.md or prompts/
271
256
 
272
257
  **Standard workflow:** PRD → Plan → Implement → Archive
273
258