agileflow 2.80.0 → 2.82.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 +1 -1
- package/scripts/agent-loop.js +765 -0
- package/scripts/agileflow-configure.js +3 -1
- package/scripts/agileflow-welcome.js +65 -0
- package/scripts/damage-control-bash.js +22 -115
- package/scripts/damage-control-edit.js +19 -156
- package/scripts/damage-control-write.js +19 -156
- package/scripts/lib/damage-control-utils.js +251 -0
- package/scripts/obtain-context.js +57 -2
- package/scripts/ralph-loop.js +516 -32
- package/scripts/session-manager.js +434 -20
- package/src/core/agents/configuration-visual-e2e.md +300 -0
- package/src/core/agents/orchestrator.md +301 -6
- package/src/core/commands/babysit.md +193 -15
- package/src/core/commands/batch.md +362 -0
- package/src/core/commands/choose.md +337 -0
- package/src/core/commands/configure.md +372 -100
- package/src/core/commands/session/end.md +332 -103
- package/src/core/commands/workflow.md +344 -0
- package/src/core/commands/setup/visual-e2e.md +0 -462
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Define and run parameterized workflow templates
|
|
3
|
+
argument-hint: <template> [arguments...]
|
|
4
|
+
compact_context:
|
|
5
|
+
priority: normal
|
|
6
|
+
preserve_rules:
|
|
7
|
+
- "Workflows are reusable templates with arguments"
|
|
8
|
+
- "Template format: {{arg_name}} for substitution"
|
|
9
|
+
- "Built-in workflows: review, test-feature, implement, analyze"
|
|
10
|
+
- "Custom workflows in docs/08-project/workflows/"
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# /agileflow:workflow
|
|
14
|
+
|
|
15
|
+
Run parameterized workflow templates. Enables DRY patterns for common multi-step operations.
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## STEP 0: Gather Context
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
node .agileflow/scripts/obtain-context.js workflow
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
<!-- COMPACT_SUMMARY_START -->
|
|
28
|
+
|
|
29
|
+
## Compact Summary
|
|
30
|
+
|
|
31
|
+
**Role**: Workflow Runner - Execute parameterized templates
|
|
32
|
+
|
|
33
|
+
**Template syntax**: `{{arg}}` for argument substitution
|
|
34
|
+
|
|
35
|
+
**Built-in workflows:**
|
|
36
|
+
- `review` - Code review with configurable focus
|
|
37
|
+
- `test-feature` - Test and verify a feature
|
|
38
|
+
- `implement` - Implement a story/feature
|
|
39
|
+
- `analyze` - Analyze codebase for issues
|
|
40
|
+
|
|
41
|
+
**Usage:**
|
|
42
|
+
```
|
|
43
|
+
/agileflow:workflow review path=src/auth.ts focus=security
|
|
44
|
+
/agileflow:workflow implement story=US-0042
|
|
45
|
+
/agileflow:workflow analyze target=src/**/*.ts type=performance
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
<!-- COMPACT_SUMMARY_END -->
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
## Usage
|
|
53
|
+
|
|
54
|
+
```
|
|
55
|
+
/agileflow:workflow <template> [arg1=value1] [arg2=value2] ...
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
## Built-in Workflows
|
|
61
|
+
|
|
62
|
+
### review
|
|
63
|
+
|
|
64
|
+
Review code with configurable focus.
|
|
65
|
+
|
|
66
|
+
**Arguments:**
|
|
67
|
+
- `path` (required): File or glob pattern to review
|
|
68
|
+
- `focus` (optional): Review focus (security, performance, quality, all)
|
|
69
|
+
|
|
70
|
+
**Template:**
|
|
71
|
+
```markdown
|
|
72
|
+
## Code Review: {{path}}
|
|
73
|
+
|
|
74
|
+
Focus: {{focus:all}}
|
|
75
|
+
|
|
76
|
+
### Steps
|
|
77
|
+
1. Read the target file(s)
|
|
78
|
+
2. Analyze for {{focus}} issues
|
|
79
|
+
3. Generate findings with severity
|
|
80
|
+
4. Suggest fixes
|
|
81
|
+
|
|
82
|
+
### Experts (parallel, on-fail: continue)
|
|
83
|
+
- agileflow-security (if focus=security|all)
|
|
84
|
+
- agileflow-performance (if focus=performance|all)
|
|
85
|
+
- agileflow-testing (if focus=quality|all)
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
**Example:**
|
|
89
|
+
```
|
|
90
|
+
/agileflow:workflow review path=src/auth.ts focus=security
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
### test-feature
|
|
96
|
+
|
|
97
|
+
Test a feature end-to-end.
|
|
98
|
+
|
|
99
|
+
**Arguments:**
|
|
100
|
+
- `feature` (required): Feature name or path
|
|
101
|
+
- `coverage` (optional): Minimum coverage threshold (default: 80)
|
|
102
|
+
|
|
103
|
+
**Template:**
|
|
104
|
+
```markdown
|
|
105
|
+
## Test Feature: {{feature}}
|
|
106
|
+
|
|
107
|
+
Coverage threshold: {{coverage:80}}%
|
|
108
|
+
|
|
109
|
+
### Steps
|
|
110
|
+
1. Identify test files for feature
|
|
111
|
+
2. Run existing tests
|
|
112
|
+
3. Generate missing tests
|
|
113
|
+
4. Verify coverage >= {{coverage}}%
|
|
114
|
+
|
|
115
|
+
### Expert: agileflow-testing
|
|
116
|
+
Discretion condition: **coverage above {{coverage}}%**
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
**Example:**
|
|
120
|
+
```
|
|
121
|
+
/agileflow:workflow test-feature feature=user-auth coverage=90
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
### implement
|
|
127
|
+
|
|
128
|
+
Implement a story or feature.
|
|
129
|
+
|
|
130
|
+
**Arguments:**
|
|
131
|
+
- `story` (required): Story ID or description
|
|
132
|
+
- `mode` (optional): Implementation mode (quick, thorough, tdd)
|
|
133
|
+
|
|
134
|
+
**Template:**
|
|
135
|
+
```markdown
|
|
136
|
+
## Implement: {{story}}
|
|
137
|
+
|
|
138
|
+
Mode: {{mode:thorough}}
|
|
139
|
+
|
|
140
|
+
### Steps (based on mode)
|
|
141
|
+
|
|
142
|
+
#### If mode=quick:
|
|
143
|
+
1. Minimal implementation
|
|
144
|
+
2. Basic tests
|
|
145
|
+
3. Quick review
|
|
146
|
+
|
|
147
|
+
#### If mode=thorough:
|
|
148
|
+
1. Plan mode first
|
|
149
|
+
2. Full implementation
|
|
150
|
+
3. Comprehensive tests
|
|
151
|
+
4. Code review
|
|
152
|
+
5. Documentation
|
|
153
|
+
|
|
154
|
+
#### If mode=tdd:
|
|
155
|
+
1. Write tests first
|
|
156
|
+
2. Implement to pass tests
|
|
157
|
+
3. Refactor
|
|
158
|
+
4. Verify coverage
|
|
159
|
+
|
|
160
|
+
### Expert selection based on story domain
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
**Example:**
|
|
164
|
+
```
|
|
165
|
+
/agileflow:workflow implement story=US-0042 mode=tdd
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
---
|
|
169
|
+
|
|
170
|
+
### analyze
|
|
171
|
+
|
|
172
|
+
Analyze codebase for issues.
|
|
173
|
+
|
|
174
|
+
**Arguments:**
|
|
175
|
+
- `target` (required): Path or glob pattern
|
|
176
|
+
- `type` (required): Analysis type (security, performance, complexity, all)
|
|
177
|
+
|
|
178
|
+
**Template:**
|
|
179
|
+
```markdown
|
|
180
|
+
## Analyze: {{target}}
|
|
181
|
+
|
|
182
|
+
Type: {{type}}
|
|
183
|
+
|
|
184
|
+
### Steps
|
|
185
|
+
1. Gather files matching {{target}}
|
|
186
|
+
2. Run {{type}} analysis
|
|
187
|
+
3. Generate report with findings
|
|
188
|
+
4. Prioritize by severity
|
|
189
|
+
|
|
190
|
+
### Experts (parallel, strategy: all, on-fail: continue)
|
|
191
|
+
- agileflow-security (if type=security|all)
|
|
192
|
+
- agileflow-performance (if type=performance|all)
|
|
193
|
+
- agileflow-refactor (if type=complexity|all)
|
|
194
|
+
|
|
195
|
+
### Output
|
|
196
|
+
Markdown report with:
|
|
197
|
+
- Summary metrics
|
|
198
|
+
- Findings by severity
|
|
199
|
+
- Recommended actions
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
**Example:**
|
|
203
|
+
```
|
|
204
|
+
/agileflow:workflow analyze target=src/**/*.ts type=all
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
---
|
|
208
|
+
|
|
209
|
+
## Custom Workflows
|
|
210
|
+
|
|
211
|
+
Create custom workflows in `docs/08-project/workflows/`:
|
|
212
|
+
|
|
213
|
+
```
|
|
214
|
+
docs/08-project/workflows/
|
|
215
|
+
├── deploy-staging.md
|
|
216
|
+
├── release-check.md
|
|
217
|
+
└── onboard-feature.md
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### Custom Workflow Format
|
|
221
|
+
|
|
222
|
+
```markdown
|
|
223
|
+
---
|
|
224
|
+
name: deploy-staging
|
|
225
|
+
description: Deploy to staging environment
|
|
226
|
+
arguments:
|
|
227
|
+
- name: version
|
|
228
|
+
required: true
|
|
229
|
+
description: Version to deploy
|
|
230
|
+
- name: notify
|
|
231
|
+
required: false
|
|
232
|
+
default: true
|
|
233
|
+
description: Send Slack notification
|
|
234
|
+
---
|
|
235
|
+
|
|
236
|
+
# Deploy to Staging: {{version}}
|
|
237
|
+
|
|
238
|
+
## Pre-checks
|
|
239
|
+
1. Verify tests passing
|
|
240
|
+
2. Check no blocking PRs
|
|
241
|
+
|
|
242
|
+
## Deployment
|
|
243
|
+
1. Build version {{version}}
|
|
244
|
+
2. Deploy to staging cluster
|
|
245
|
+
3. Run smoke tests
|
|
246
|
+
|
|
247
|
+
## Post-deploy
|
|
248
|
+
{{#if notify}}
|
|
249
|
+
4. Send Slack notification
|
|
250
|
+
{{/if}}
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
### Using Custom Workflows
|
|
254
|
+
|
|
255
|
+
```
|
|
256
|
+
/agileflow:workflow deploy-staging version=2.42.0 notify=false
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
---
|
|
260
|
+
|
|
261
|
+
## Advanced Features
|
|
262
|
+
|
|
263
|
+
### Conditional Sections
|
|
264
|
+
|
|
265
|
+
Use `{{#if arg}}` for conditional content:
|
|
266
|
+
|
|
267
|
+
```markdown
|
|
268
|
+
{{#if verbose}}
|
|
269
|
+
### Verbose Output
|
|
270
|
+
Show detailed logs...
|
|
271
|
+
{{/if}}
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
### Default Values
|
|
275
|
+
|
|
276
|
+
Use `{{arg:default}}` for default values:
|
|
277
|
+
|
|
278
|
+
```markdown
|
|
279
|
+
Coverage threshold: {{coverage:80}}%
|
|
280
|
+
Mode: {{mode:thorough}}
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
### Lists
|
|
284
|
+
|
|
285
|
+
Use `{{args...}}` for multiple values:
|
|
286
|
+
|
|
287
|
+
```markdown
|
|
288
|
+
Files to process:
|
|
289
|
+
{{#each files}}
|
|
290
|
+
- {{this}}
|
|
291
|
+
{{/each}}
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
---
|
|
295
|
+
|
|
296
|
+
## Workflow Composition
|
|
297
|
+
|
|
298
|
+
Workflows can reference other workflows:
|
|
299
|
+
|
|
300
|
+
```markdown
|
|
301
|
+
## Full Release
|
|
302
|
+
|
|
303
|
+
1. /agileflow:workflow test-feature feature=all coverage=90
|
|
304
|
+
2. /agileflow:workflow analyze target=src type=security
|
|
305
|
+
3. /agileflow:workflow deploy-staging version={{version}}
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
---
|
|
309
|
+
|
|
310
|
+
## Workflow Discovery
|
|
311
|
+
|
|
312
|
+
List available workflows:
|
|
313
|
+
|
|
314
|
+
```
|
|
315
|
+
/agileflow:workflow --list
|
|
316
|
+
|
|
317
|
+
Built-in workflows:
|
|
318
|
+
- review: Code review with focus
|
|
319
|
+
- test-feature: Test a feature
|
|
320
|
+
- implement: Implement a story
|
|
321
|
+
- analyze: Analyze codebase
|
|
322
|
+
|
|
323
|
+
Custom workflows (docs/08-project/workflows/):
|
|
324
|
+
- deploy-staging: Deploy to staging
|
|
325
|
+
- release-check: Pre-release checklist
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
---
|
|
329
|
+
|
|
330
|
+
## Best Practices
|
|
331
|
+
|
|
332
|
+
1. **Use descriptive names**: `deploy-staging` not `ds`
|
|
333
|
+
2. **Document arguments**: Include types and defaults
|
|
334
|
+
3. **Keep workflows focused**: One purpose per workflow
|
|
335
|
+
4. **Use composition**: Build complex flows from simple ones
|
|
336
|
+
5. **Version workflows**: Track changes in git
|
|
337
|
+
|
|
338
|
+
---
|
|
339
|
+
|
|
340
|
+
## Integration
|
|
341
|
+
|
|
342
|
+
- Works with babysit for story implementation
|
|
343
|
+
- Can trigger from Ralph Loop
|
|
344
|
+
- Integrates with expert system for multi-domain work
|