agileflow 2.77.0 → 2.79.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.
- package/README.md +6 -6
- package/package.json +6 -1
- package/scripts/agileflow-configure.js +174 -2
- package/scripts/agileflow-statusline.sh +171 -78
- package/scripts/agileflow-welcome.js +88 -64
- package/scripts/auto-self-improve.js +23 -45
- package/scripts/check-update.js +35 -42
- package/scripts/damage-control/bash-tool-damage-control.js +257 -0
- package/scripts/damage-control/edit-tool-damage-control.js +279 -0
- package/scripts/damage-control/patterns.yaml +227 -0
- package/scripts/damage-control/write-tool-damage-control.js +274 -0
- package/scripts/damage-control-bash.js +232 -0
- package/scripts/damage-control-edit.js +243 -0
- package/scripts/damage-control-write.js +243 -0
- package/scripts/obtain-context.js +22 -3
- package/scripts/ralph-loop.js +191 -63
- package/scripts/screenshot-verifier.js +213 -0
- package/scripts/session-manager.js +12 -33
- package/src/core/agents/accessibility.md +124 -53
- package/src/core/agents/adr-writer.md +192 -52
- package/src/core/agents/analytics.md +139 -60
- package/src/core/agents/api.md +173 -63
- package/src/core/agents/ci.md +139 -57
- package/src/core/agents/compliance.md +159 -68
- package/src/core/agents/configuration/damage-control.md +356 -0
- package/src/core/agents/configuration-damage-control.md +248 -0
- package/src/core/agents/database.md +162 -61
- package/src/core/agents/datamigration.md +179 -66
- package/src/core/agents/design.md +179 -57
- package/src/core/agents/devops.md +160 -3
- package/src/core/agents/documentation.md +204 -60
- package/src/core/agents/epic-planner.md +147 -55
- package/src/core/agents/integrations.md +197 -69
- package/src/core/agents/mentor.md +158 -57
- package/src/core/agents/mobile.md +159 -67
- package/src/core/agents/monitoring.md +154 -65
- package/src/core/agents/multi-expert.md +115 -43
- package/src/core/agents/orchestrator.md +77 -24
- package/src/core/agents/performance.md +130 -75
- package/src/core/agents/product.md +151 -55
- package/src/core/agents/qa.md +162 -74
- package/src/core/agents/readme-updater.md +178 -76
- package/src/core/agents/refactor.md +148 -95
- package/src/core/agents/research.md +143 -72
- package/src/core/agents/security.md +154 -65
- package/src/core/agents/testing.md +176 -97
- package/src/core/agents/ui.md +170 -79
- package/src/core/commands/adr/list.md +171 -0
- package/src/core/commands/adr/update.md +235 -0
- package/src/core/commands/adr/view.md +252 -0
- package/src/core/commands/adr.md +207 -50
- package/src/core/commands/agent.md +16 -0
- package/src/core/commands/assign.md +148 -44
- package/src/core/commands/auto.md +18 -1
- package/src/core/commands/babysit.md +391 -38
- package/src/core/commands/baseline.md +14 -0
- package/src/core/commands/blockers.md +170 -51
- package/src/core/commands/board.md +144 -66
- package/src/core/commands/changelog.md +15 -0
- package/src/core/commands/ci.md +179 -69
- package/src/core/commands/compress.md +18 -0
- package/src/core/commands/configure.md +16 -0
- package/src/core/commands/context/export.md +193 -4
- package/src/core/commands/context/full.md +191 -18
- package/src/core/commands/context/note.md +248 -4
- package/src/core/commands/debt.md +17 -0
- package/src/core/commands/deploy.md +208 -65
- package/src/core/commands/deps.md +15 -0
- package/src/core/commands/diagnose.md +16 -0
- package/src/core/commands/docs.md +196 -64
- package/src/core/commands/epic/list.md +170 -0
- package/src/core/commands/epic/view.md +242 -0
- package/src/core/commands/epic.md +192 -69
- package/src/core/commands/feedback.md +191 -71
- package/src/core/commands/handoff.md +162 -48
- package/src/core/commands/help.md +9 -0
- package/src/core/commands/ideate.md +446 -0
- package/src/core/commands/impact.md +16 -0
- package/src/core/commands/metrics.md +141 -37
- package/src/core/commands/multi-expert.md +77 -0
- package/src/core/commands/packages.md +16 -0
- package/src/core/commands/pr.md +161 -67
- package/src/core/commands/readme-sync.md +16 -0
- package/src/core/commands/research/analyze.md +568 -0
- package/src/core/commands/research/ask.md +345 -20
- package/src/core/commands/research/import.md +562 -19
- package/src/core/commands/research/list.md +173 -5
- package/src/core/commands/research/view.md +181 -8
- package/src/core/commands/retro.md +135 -48
- package/src/core/commands/review.md +219 -47
- package/src/core/commands/session/end.md +209 -0
- package/src/core/commands/session/history.md +210 -0
- package/src/core/commands/session/init.md +116 -0
- package/src/core/commands/session/new.md +296 -0
- package/src/core/commands/session/resume.md +166 -0
- package/src/core/commands/session/status.md +166 -0
- package/src/core/commands/setup/visual-e2e.md +462 -0
- package/src/core/commands/skill/create.md +115 -17
- package/src/core/commands/skill/delete.md +117 -0
- package/src/core/commands/skill/edit.md +104 -0
- package/src/core/commands/skill/list.md +128 -0
- package/src/core/commands/skill/test.md +135 -0
- package/src/core/commands/skill/upgrade.md +542 -0
- package/src/core/commands/sprint.md +17 -1
- package/src/core/commands/status.md +133 -21
- package/src/core/commands/story/list.md +176 -0
- package/src/core/commands/story/view.md +265 -0
- package/src/core/commands/story-validate.md +101 -1
- package/src/core/commands/story.md +204 -51
- package/src/core/commands/template.md +16 -1
- package/src/core/commands/tests.md +226 -64
- package/src/core/commands/update.md +17 -1
- package/src/core/commands/validate-expertise.md +16 -0
- package/src/core/commands/velocity.md +140 -36
- package/src/core/commands/verify.md +14 -0
- package/src/core/commands/whats-new.md +30 -0
- package/src/core/skills/_learnings/README.md +91 -0
- package/src/core/skills/_learnings/_template.yaml +106 -0
- package/src/core/skills/_learnings/code-review.yaml +118 -0
- package/src/core/skills/_learnings/commit.yaml +69 -0
- package/src/core/skills/_learnings/story-writer.yaml +71 -0
- package/src/core/templates/damage-control-patterns.yaml +234 -0
- package/src/core/templates/skill-template.md +53 -11
- package/tools/cli/commands/start.js +180 -0
- package/tools/cli/installers/ide/claude-code.js +127 -0
- package/tools/cli/tui/Dashboard.js +66 -0
- package/tools/cli/tui/StoryList.js +69 -0
- package/tools/cli/tui/index.js +16 -0
|
@@ -0,0 +1,542 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Upgrade existing skills with self-improving learning capability
|
|
3
|
+
argument-hint: [SKILL_NAME] (optional)
|
|
4
|
+
compact_context:
|
|
5
|
+
priority: medium
|
|
6
|
+
preserve_rules:
|
|
7
|
+
- "ACTIVE COMMAND: /agileflow:skill:upgrade - Adds learning capability to skills"
|
|
8
|
+
- "MUST list available skills if SKILL_NAME not provided"
|
|
9
|
+
- "MUST check if skill already has learning capability"
|
|
10
|
+
- "MUST create .agileflow/skills/_learnings/<skill>.yaml learnings file"
|
|
11
|
+
- "MUST add Self-Improving Learnings section to SKILL.md"
|
|
12
|
+
- "MUST preserve all existing skill content (only add new sections)"
|
|
13
|
+
- "MUST offer preview mode before writing changes"
|
|
14
|
+
- "MUST support batch upgrade with --all flag"
|
|
15
|
+
state_fields:
|
|
16
|
+
- selected_skill
|
|
17
|
+
- already_upgraded
|
|
18
|
+
- learnings_file_created
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
# /agileflow:skill:upgrade
|
|
22
|
+
|
|
23
|
+
Add self-improving capability to existing skills created before the learning system was introduced.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
<!-- COMPACT_SUMMARY_START -->
|
|
28
|
+
|
|
29
|
+
## 🚨 COMPACT SUMMARY - /agileflow:skill:upgrade IS ACTIVE
|
|
30
|
+
|
|
31
|
+
**CRITICAL**: This command adds learning capability to existing skills, preserving all original content.
|
|
32
|
+
|
|
33
|
+
### 🚨 RULE #1: Select Skill or Use Batch Mode
|
|
34
|
+
If SKILL_NAME not provided:
|
|
35
|
+
```bash
|
|
36
|
+
ls -d .claude/skills/*/ | xargs -I {} basename {}
|
|
37
|
+
```
|
|
38
|
+
Show options. Or use `--all` flag for batch upgrade.
|
|
39
|
+
|
|
40
|
+
### 🚨 RULE #2: Check Upgrade Status
|
|
41
|
+
Read SKILL.md and check for:
|
|
42
|
+
- Existing `## Self-Improving Learnings` section
|
|
43
|
+
- Existing `.agileflow/skills/_learnings/<skill>.yaml` file
|
|
44
|
+
|
|
45
|
+
If already upgraded:
|
|
46
|
+
```
|
|
47
|
+
✅ Skill "<skill>" already has self-improving capability!
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
### 🚨 RULE #3: Show What Will Be Added
|
|
51
|
+
Display changes that will be made:
|
|
52
|
+
```
|
|
53
|
+
📦 Upgrade: skill-name
|
|
54
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
55
|
+
|
|
56
|
+
Changes to be made:
|
|
57
|
+
|
|
58
|
+
1. SKILL.md - Add sections:
|
|
59
|
+
- ## Self-Improving Learnings
|
|
60
|
+
- Update ## Instructions to include learning workflow
|
|
61
|
+
|
|
62
|
+
2. Create new file:
|
|
63
|
+
- .agileflow/skills/_learnings/<skill>.yaml
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### 🚨 RULE #4: Offer Preview or Direct Upgrade
|
|
67
|
+
Ask:
|
|
68
|
+
```
|
|
69
|
+
Proceed with upgrade?
|
|
70
|
+
- Yes, upgrade skill
|
|
71
|
+
- Preview changes first (Recommended)
|
|
72
|
+
- Cancel
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
### 🚨 RULE #5: Create Learnings File
|
|
76
|
+
Create `.agileflow/skills/_learnings/<skill>.yaml`:
|
|
77
|
+
```yaml
|
|
78
|
+
skill: <skill>
|
|
79
|
+
version: 1
|
|
80
|
+
last_updated: <timestamp>
|
|
81
|
+
|
|
82
|
+
preferences:
|
|
83
|
+
# Will be added as skill is used
|
|
84
|
+
|
|
85
|
+
conventions:
|
|
86
|
+
# Will be extracted from corrections
|
|
87
|
+
|
|
88
|
+
anti_patterns:
|
|
89
|
+
# Things to avoid
|
|
90
|
+
|
|
91
|
+
context:
|
|
92
|
+
# Project-specific learnings
|
|
93
|
+
|
|
94
|
+
examples:
|
|
95
|
+
good: []
|
|
96
|
+
bad: []
|
|
97
|
+
|
|
98
|
+
metadata:
|
|
99
|
+
corrections_count: 0
|
|
100
|
+
approvals_count: 0
|
|
101
|
+
created: <timestamp>
|
|
102
|
+
sessions: []
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### 🚨 RULE #6: Update SKILL.md
|
|
106
|
+
Add new section AFTER "When to Use":
|
|
107
|
+
```markdown
|
|
108
|
+
## Self-Improving Learnings
|
|
109
|
+
|
|
110
|
+
This skill learns from your corrections and preferences.
|
|
111
|
+
|
|
112
|
+
**On invocation**:
|
|
113
|
+
1. Check if `.agileflow/skills/_learnings/<skill>.yaml` exists
|
|
114
|
+
2. If exists, read and apply learned preferences
|
|
115
|
+
3. Follow conventions and avoid anti-patterns from learnings
|
|
116
|
+
|
|
117
|
+
**On correction**:
|
|
118
|
+
1. When user corrects output, extract the signal
|
|
119
|
+
2. Determine confidence level...
|
|
120
|
+
3. Update the learnings file with new preference
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Also prepend learning workflow to Instructions:
|
|
124
|
+
```markdown
|
|
125
|
+
## Instructions
|
|
126
|
+
|
|
127
|
+
1. **Load learnings** (if exists):
|
|
128
|
+
- Read `.agileflow/skills/_learnings/<skill>.yaml`
|
|
129
|
+
- Apply preferences, conventions, and anti-patterns
|
|
130
|
+
|
|
131
|
+
2. **Execute skill**:
|
|
132
|
+
[... existing instructions ...]
|
|
133
|
+
|
|
134
|
+
3. **If user corrects**:
|
|
135
|
+
- Extract signal from correction
|
|
136
|
+
- Update learnings file
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
### 🚨 RULE #7: Show Success
|
|
140
|
+
```
|
|
141
|
+
✅ Skill upgraded successfully!
|
|
142
|
+
|
|
143
|
+
Modified: .claude/skills/<skill>/SKILL.md
|
|
144
|
+
Created: .agileflow/skills/_learnings/<skill>.yaml
|
|
145
|
+
|
|
146
|
+
The skill will now:
|
|
147
|
+
• Load learned preferences on each invocation
|
|
148
|
+
• Extract signals from your corrections
|
|
149
|
+
• Build up conventions over time
|
|
150
|
+
• Avoid learned anti-patterns
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
### Critical Files Created/Modified
|
|
154
|
+
| File | Purpose | Action |
|
|
155
|
+
|------|---------|--------|
|
|
156
|
+
| SKILL.md | Main skill file | Add 2 sections + update instructions |
|
|
157
|
+
| .agileflow/skills/_learnings/<skill>.yaml | Learnings file | Create new |
|
|
158
|
+
|
|
159
|
+
### Learnings File Structure
|
|
160
|
+
```yaml
|
|
161
|
+
skill: <name>
|
|
162
|
+
version: 1
|
|
163
|
+
preferences: {}
|
|
164
|
+
conventions: []
|
|
165
|
+
anti_patterns: []
|
|
166
|
+
context: {}
|
|
167
|
+
examples: {good: [], bad: []}
|
|
168
|
+
metadata: {corrections_count: 0, approvals_count: 0, created: <ts>, sessions: []}
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
### Anti-Patterns
|
|
172
|
+
- ❌ DON'T upgrade already-upgraded skills (check first)
|
|
173
|
+
- ❌ DON'T delete existing SKILL.md content (only add sections)
|
|
174
|
+
- ❌ DON'T create learnings file in wrong location
|
|
175
|
+
- ❌ DON'T skip preview mode option (let user see changes)
|
|
176
|
+
- ❌ DON'T forget to document the learning workflow in Instructions
|
|
177
|
+
|
|
178
|
+
### Batch Upgrade Mode
|
|
179
|
+
When using `--all` flag:
|
|
180
|
+
1. List all skills in `.claude/skills/`
|
|
181
|
+
2. Filter out already-upgraded skills
|
|
182
|
+
3. Ask for confirmation: "Upgrade N skills?"
|
|
183
|
+
4. Apply upgrade to each
|
|
184
|
+
5. Show summary: "Upgraded N skills"
|
|
185
|
+
|
|
186
|
+
### REMEMBER AFTER COMPACTION
|
|
187
|
+
- Upgrade is: Select → Check status → Show changes → [Preview if requested] → Create learnings file → Update SKILL.md → Confirm success
|
|
188
|
+
- Learnings file goes in .agileflow/skills/_learnings/ with skill name
|
|
189
|
+
- NEVER delete existing content, only add new sections
|
|
190
|
+
- Always ask for preview confirmation before writing
|
|
191
|
+
- Batch mode with --all upgrades all non-upgraded skills at once
|
|
192
|
+
|
|
193
|
+
<!-- COMPACT_SUMMARY_END -->
|
|
194
|
+
|
|
195
|
+
---
|
|
196
|
+
|
|
197
|
+
## What This Does
|
|
198
|
+
|
|
199
|
+
Skills created before EP-0007 (Self-Improving Skills) don't have the learning capability. This command:
|
|
200
|
+
|
|
201
|
+
1. **Adds Self-Improving Learnings section** to SKILL.md
|
|
202
|
+
2. **Creates learnings file** at `.agileflow/skills/_learnings/{skill-name}.yaml`
|
|
203
|
+
3. **Updates Instructions section** to include learning workflow steps
|
|
204
|
+
4. **Preserves all existing content** - only adds new sections
|
|
205
|
+
|
|
206
|
+
---
|
|
207
|
+
|
|
208
|
+
## Workflow
|
|
209
|
+
|
|
210
|
+
### STEP 1: Select skill to upgrade
|
|
211
|
+
|
|
212
|
+
If SKILL_NAME not provided, list available skills:
|
|
213
|
+
|
|
214
|
+
```bash
|
|
215
|
+
ls -d .claude/skills/*/ 2>/dev/null | xargs -I {} basename {}
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
Then ask user:
|
|
219
|
+
|
|
220
|
+
```xml
|
|
221
|
+
<invoke name="AskUserQuestion">
|
|
222
|
+
<parameter name="questions">[{
|
|
223
|
+
"question": "Which skill would you like to upgrade with self-improving capability?",
|
|
224
|
+
"header": "Select Skill",
|
|
225
|
+
"multiSelect": false,
|
|
226
|
+
"options": [
|
|
227
|
+
{"label": "<skill-1>", "description": "<description from frontmatter>"},
|
|
228
|
+
{"label": "<skill-2>", "description": "<description from frontmatter>"},
|
|
229
|
+
{"label": "<skill-3>", "description": "<description from frontmatter>"}
|
|
230
|
+
]
|
|
231
|
+
}]</parameter>
|
|
232
|
+
</invoke>
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
### STEP 2: Check upgrade status
|
|
236
|
+
|
|
237
|
+
Read the skill's SKILL.md and check for existing self-improving capability:
|
|
238
|
+
|
|
239
|
+
```bash
|
|
240
|
+
cat .claude/skills/<skill>/SKILL.md
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
**Check for existing sections:**
|
|
244
|
+
- Look for `## Self-Improving Learnings` section
|
|
245
|
+
- Check if `.agileflow/skills/_learnings/<skill>.yaml` exists
|
|
246
|
+
|
|
247
|
+
**If already upgraded:**
|
|
248
|
+
```
|
|
249
|
+
✅ Skill "<skill>" already has self-improving capability!
|
|
250
|
+
|
|
251
|
+
Learnings file: .agileflow/skills/_learnings/<skill>.yaml
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
Offer to view the learnings file or exit.
|
|
255
|
+
|
|
256
|
+
**If not upgraded:**
|
|
257
|
+
Continue to next step.
|
|
258
|
+
|
|
259
|
+
### STEP 3: Show what will be added
|
|
260
|
+
|
|
261
|
+
Display the changes that will be made:
|
|
262
|
+
|
|
263
|
+
```
|
|
264
|
+
📦 Upgrade: <skill>
|
|
265
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
266
|
+
|
|
267
|
+
Changes to be made:
|
|
268
|
+
|
|
269
|
+
1. SKILL.md - Add sections:
|
|
270
|
+
- ## Self-Improving Learnings
|
|
271
|
+
- Update ## Instructions to include learning workflow
|
|
272
|
+
|
|
273
|
+
2. Create new file:
|
|
274
|
+
- .agileflow/skills/_learnings/<skill>.yaml
|
|
275
|
+
|
|
276
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
### STEP 4: Confirm upgrade
|
|
280
|
+
|
|
281
|
+
```xml
|
|
282
|
+
<invoke name="AskUserQuestion">
|
|
283
|
+
<parameter name="questions">[{
|
|
284
|
+
"question": "Proceed with upgrade?",
|
|
285
|
+
"header": "Confirm",
|
|
286
|
+
"multiSelect": false,
|
|
287
|
+
"options": [
|
|
288
|
+
{"label": "Yes, upgrade skill", "description": "Add self-improving capability"},
|
|
289
|
+
{"label": "Preview changes first", "description": "Show exact changes before applying"},
|
|
290
|
+
{"label": "Cancel", "description": "Exit without changes"}
|
|
291
|
+
]
|
|
292
|
+
}]</parameter>
|
|
293
|
+
</invoke>
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
### STEP 5: Apply upgrade
|
|
297
|
+
|
|
298
|
+
**5.1: Create learnings file**
|
|
299
|
+
|
|
300
|
+
Create `.agileflow/skills/_learnings/<skill>.yaml`:
|
|
301
|
+
|
|
302
|
+
```yaml
|
|
303
|
+
# Learnings for <skill> skill
|
|
304
|
+
# This file accumulates user preferences for this skill.
|
|
305
|
+
|
|
306
|
+
skill: <skill>
|
|
307
|
+
version: 1
|
|
308
|
+
last_updated: <current-timestamp>
|
|
309
|
+
|
|
310
|
+
# =============================================================================
|
|
311
|
+
# PREFERENCES
|
|
312
|
+
# =============================================================================
|
|
313
|
+
preferences:
|
|
314
|
+
# Preferences will be added as you use this skill and Claude learns from corrections
|
|
315
|
+
|
|
316
|
+
# =============================================================================
|
|
317
|
+
# CONVENTIONS
|
|
318
|
+
# =============================================================================
|
|
319
|
+
conventions:
|
|
320
|
+
# - "Convention from skill usage will be added here"
|
|
321
|
+
|
|
322
|
+
# =============================================================================
|
|
323
|
+
# ANTI-PATTERNS
|
|
324
|
+
# =============================================================================
|
|
325
|
+
anti_patterns:
|
|
326
|
+
# - "Things to avoid will be added here"
|
|
327
|
+
|
|
328
|
+
# =============================================================================
|
|
329
|
+
# CONTEXT
|
|
330
|
+
# =============================================================================
|
|
331
|
+
context:
|
|
332
|
+
# Project-specific context will be learned here
|
|
333
|
+
|
|
334
|
+
# =============================================================================
|
|
335
|
+
# EXAMPLES
|
|
336
|
+
# =============================================================================
|
|
337
|
+
examples:
|
|
338
|
+
# good:
|
|
339
|
+
# - "Good examples will be collected here"
|
|
340
|
+
# bad:
|
|
341
|
+
# - "Bad examples will be collected here"
|
|
342
|
+
|
|
343
|
+
# =============================================================================
|
|
344
|
+
# METADATA
|
|
345
|
+
# =============================================================================
|
|
346
|
+
metadata:
|
|
347
|
+
corrections_count: 0
|
|
348
|
+
approvals_count: 0
|
|
349
|
+
created: <current-timestamp>
|
|
350
|
+
sessions: []
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
**5.2: Update SKILL.md**
|
|
354
|
+
|
|
355
|
+
Add the Self-Improving Learnings section AFTER the "What This Does" or "When to Use" section:
|
|
356
|
+
|
|
357
|
+
```markdown
|
|
358
|
+
## Self-Improving Learnings
|
|
359
|
+
|
|
360
|
+
This skill learns from your corrections and preferences.
|
|
361
|
+
|
|
362
|
+
**On invocation**:
|
|
363
|
+
1. Check if `.agileflow/skills/_learnings/<skill>.yaml` exists
|
|
364
|
+
2. If exists, read and apply learned preferences
|
|
365
|
+
3. Follow conventions and avoid anti-patterns from learnings
|
|
366
|
+
|
|
367
|
+
**On correction**:
|
|
368
|
+
1. When user corrects output, extract the signal
|
|
369
|
+
2. Determine confidence level:
|
|
370
|
+
- **high**: Explicit correction ("never do X", "always do Y")
|
|
371
|
+
- **medium**: User approved or pattern worked well
|
|
372
|
+
- **low**: Observation to review later
|
|
373
|
+
3. Update the learnings file with new preference
|
|
374
|
+
|
|
375
|
+
**Learnings file location**: `.agileflow/skills/_learnings/<skill>.yaml`
|
|
376
|
+
```
|
|
377
|
+
|
|
378
|
+
**5.3: Update Instructions section**
|
|
379
|
+
|
|
380
|
+
If the skill has an `## Instructions` section, prepend learning workflow steps:
|
|
381
|
+
|
|
382
|
+
```markdown
|
|
383
|
+
## Instructions
|
|
384
|
+
|
|
385
|
+
Step-by-step guidance for Claude:
|
|
386
|
+
|
|
387
|
+
1. **Load learnings** (if exists):
|
|
388
|
+
- Read `.agileflow/skills/_learnings/<skill>.yaml`
|
|
389
|
+
- Apply preferences, conventions, and anti-patterns
|
|
390
|
+
- Skip if file doesn't exist (first run)
|
|
391
|
+
|
|
392
|
+
2. **Execute skill**:
|
|
393
|
+
- Follow the instructions below with learned preferences applied
|
|
394
|
+
[... existing instructions ...]
|
|
395
|
+
|
|
396
|
+
3. **If user corrects**:
|
|
397
|
+
- Extract signal from correction
|
|
398
|
+
- Update learnings file
|
|
399
|
+
- Continue with corrected approach
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
### STEP 6: Show success
|
|
403
|
+
|
|
404
|
+
```
|
|
405
|
+
✅ Skill upgraded successfully!
|
|
406
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
407
|
+
|
|
408
|
+
Modified: .claude/skills/<skill>/SKILL.md
|
|
409
|
+
Created: .agileflow/skills/_learnings/<skill>.yaml
|
|
410
|
+
|
|
411
|
+
The skill will now:
|
|
412
|
+
• Load learned preferences on each invocation
|
|
413
|
+
• Extract signals from your corrections
|
|
414
|
+
• Build up conventions over time
|
|
415
|
+
• Avoid learned anti-patterns
|
|
416
|
+
|
|
417
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
418
|
+
```
|
|
419
|
+
|
|
420
|
+
---
|
|
421
|
+
|
|
422
|
+
## Preview Mode
|
|
423
|
+
|
|
424
|
+
If user selects "Preview changes first", show:
|
|
425
|
+
|
|
426
|
+
**SKILL.md diff:**
|
|
427
|
+
```diff
|
|
428
|
+
## When to Use
|
|
429
|
+
...existing content...
|
|
430
|
+
|
|
431
|
+
+ ## Self-Improving Learnings
|
|
432
|
+
+
|
|
433
|
+
+ This skill learns from your corrections and preferences.
|
|
434
|
+
+
|
|
435
|
+
+ **On invocation**:
|
|
436
|
+
+ 1. Check if `.agileflow/skills/_learnings/<skill>.yaml` exists
|
|
437
|
+
+ ...
|
|
438
|
+
```
|
|
439
|
+
|
|
440
|
+
**New file preview:**
|
|
441
|
+
```yaml
|
|
442
|
+
# .agileflow/skills/_learnings/<skill>.yaml
|
|
443
|
+
|
|
444
|
+
skill: <skill>
|
|
445
|
+
version: 1
|
|
446
|
+
...
|
|
447
|
+
```
|
|
448
|
+
|
|
449
|
+
Then ask for confirmation again.
|
|
450
|
+
|
|
451
|
+
---
|
|
452
|
+
|
|
453
|
+
## Batch Upgrade
|
|
454
|
+
|
|
455
|
+
If user wants to upgrade ALL skills:
|
|
456
|
+
|
|
457
|
+
```xml
|
|
458
|
+
<invoke name="AskUserQuestion">
|
|
459
|
+
<parameter name="questions">[{
|
|
460
|
+
"question": "Upgrade all skills at once?",
|
|
461
|
+
"header": "Batch Mode",
|
|
462
|
+
"multiSelect": false,
|
|
463
|
+
"options": [
|
|
464
|
+
{"label": "Yes, upgrade all", "description": "Apply to all skills without learnings"},
|
|
465
|
+
{"label": "No, one at a time", "description": "Select and upgrade individually"}
|
|
466
|
+
]
|
|
467
|
+
}]</parameter>
|
|
468
|
+
</invoke>
|
|
469
|
+
```
|
|
470
|
+
|
|
471
|
+
If batch mode:
|
|
472
|
+
1. List all skills in `.claude/skills/`
|
|
473
|
+
2. Filter out already-upgraded skills
|
|
474
|
+
3. Apply upgrade to each
|
|
475
|
+
4. Show summary at end
|
|
476
|
+
|
|
477
|
+
---
|
|
478
|
+
|
|
479
|
+
## Error Handling
|
|
480
|
+
|
|
481
|
+
### Skill Not Found
|
|
482
|
+
```
|
|
483
|
+
❌ Skill "<name>" not found.
|
|
484
|
+
|
|
485
|
+
Available skills:
|
|
486
|
+
- supabase-swift
|
|
487
|
+
- ui-components
|
|
488
|
+
|
|
489
|
+
Use /agileflow:skill:list to see all skills.
|
|
490
|
+
```
|
|
491
|
+
|
|
492
|
+
### No Skills Installed
|
|
493
|
+
```
|
|
494
|
+
❌ No skills installed yet.
|
|
495
|
+
|
|
496
|
+
Create a skill first: /agileflow:skill:create
|
|
497
|
+
```
|
|
498
|
+
|
|
499
|
+
### Write Permission Error
|
|
500
|
+
```
|
|
501
|
+
❌ Cannot create learnings file.
|
|
502
|
+
|
|
503
|
+
Please check permissions for:
|
|
504
|
+
.agileflow/skills/_learnings/
|
|
505
|
+
|
|
506
|
+
You may need to create the directory:
|
|
507
|
+
mkdir -p .agileflow/skills/_learnings
|
|
508
|
+
```
|
|
509
|
+
|
|
510
|
+
### SKILL.md Parse Error
|
|
511
|
+
```
|
|
512
|
+
⚠️ Could not parse SKILL.md frontmatter.
|
|
513
|
+
|
|
514
|
+
The skill file may have formatting issues.
|
|
515
|
+
Would you like me to try anyway, or edit manually?
|
|
516
|
+
```
|
|
517
|
+
|
|
518
|
+
---
|
|
519
|
+
|
|
520
|
+
## Quality Checklist
|
|
521
|
+
|
|
522
|
+
Before completing, verify:
|
|
523
|
+
- [ ] Learnings file created in correct location
|
|
524
|
+
- [ ] SKILL.md has Self-Improving Learnings section
|
|
525
|
+
- [ ] Instructions section updated (if exists)
|
|
526
|
+
- [ ] No existing content was removed
|
|
527
|
+
- [ ] Skill name matches in all locations
|
|
528
|
+
|
|
529
|
+
---
|
|
530
|
+
|
|
531
|
+
## Usage
|
|
532
|
+
|
|
533
|
+
```bash
|
|
534
|
+
# Interactive mode (recommended)
|
|
535
|
+
/agileflow:skill:upgrade
|
|
536
|
+
|
|
537
|
+
# Upgrade specific skill
|
|
538
|
+
/agileflow:skill:upgrade my-api-skill
|
|
539
|
+
|
|
540
|
+
# Batch upgrade (upgrade all at once)
|
|
541
|
+
/agileflow:skill:upgrade --all
|
|
542
|
+
```
|
|
@@ -1,7 +1,23 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: Data-driven sprint planning with velocity forecasting
|
|
3
|
-
argument-hint: [SPRINT=<id>] [DURATION=<days>] [AGENTS=<list>] [MODE=suggest|commit] [FOCUS_EPIC=<id>]
|
|
3
|
+
argument-hint: "[SPRINT=<id>] [DURATION=<days>] [AGENTS=<list>] [MODE=suggest|commit] [FOCUS_EPIC=<id>]"
|
|
4
4
|
model: haiku
|
|
5
|
+
compact_context:
|
|
6
|
+
priority: critical
|
|
7
|
+
preserve_rules:
|
|
8
|
+
- "ACTIVE COMMAND: /agileflow:sprint-plan - Sprint planner with capacity analysis"
|
|
9
|
+
- "MUST create TodoWrite task list immediately (8 steps: load knowledge, analyze capacity, calculate velocity, select stories, assess risks, generate report, commit if MODE=commit)"
|
|
10
|
+
- "MUST calculate historical velocity from last 30 days (bus/log.jsonl)"
|
|
11
|
+
- "MUST respect WIP limits (max 2 in-progress per agent)"
|
|
12
|
+
- "MUST validate dependencies resolved (only select stories with all deps status=done)"
|
|
13
|
+
- "MUST show diff preview before committing (MODE=commit)"
|
|
14
|
+
- "MUST assess risks (dependency chains, cross-agent coordination, epic staleness)"
|
|
15
|
+
- "MODE=suggest shows preview; MODE=commit updates status.json + milestones.md"
|
|
16
|
+
state_fields:
|
|
17
|
+
- sprint_id
|
|
18
|
+
- velocity_calculated
|
|
19
|
+
- story_count
|
|
20
|
+
- capacity_days
|
|
5
21
|
---
|
|
6
22
|
|
|
7
23
|
<!-- COMPACT_SUMMARY_START
|