agileflow 2.38.0 → 2.40.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 +2 -0
- package/package.json +1 -1
- package/src/core/agents/configuration/hooks.md +75 -2
- package/src/core/agents/configuration/precompact.md +253 -0
- package/src/core/commands/configure.md +39 -4
- package/src/core/experts/accessibility/expertise.yaml +41 -3
- package/src/core/experts/adr-writer/expertise.yaml +78 -31
- package/src/core/experts/analytics/expertise.yaml +49 -3
- package/src/core/experts/api/expertise.yaml +113 -107
- package/src/core/experts/ci/expertise.yaml +92 -55
- package/src/core/experts/compliance/expertise.yaml +34 -3
- package/src/core/experts/database/expertise.yaml +65 -12
- package/src/core/experts/datamigration/expertise.yaml +37 -3
- package/src/core/experts/design/expertise.yaml +22 -3
- package/src/core/experts/devops/expertise.yaml +95 -66
- package/src/core/experts/documentation/expertise.yaml +124 -51
- package/src/core/experts/epic-planner/expertise.yaml +69 -31
- package/src/core/experts/integrations/expertise.yaml +93 -3
- package/src/core/experts/mentor/expertise.yaml +80 -34
- package/src/core/experts/mobile/expertise.yaml +17 -3
- package/src/core/experts/monitoring/expertise.yaml +34 -3
- package/src/core/experts/performance/expertise.yaml +27 -3
- package/src/core/experts/product/expertise.yaml +82 -24
- package/src/core/experts/qa/expertise.yaml +22 -3
- package/src/core/experts/readme-updater/expertise.yaml +87 -40
- package/src/core/experts/refactor/expertise.yaml +121 -50
- package/src/core/experts/research/expertise.yaml +88 -45
- package/src/core/experts/security/expertise.yaml +66 -3
- package/src/core/experts/testing/expertise.yaml +103 -58
- package/src/core/experts/ui/expertise.yaml +46 -5
- package/tools/cli/commands/list.js +372 -0
package/README.md
CHANGED
|
@@ -41,6 +41,7 @@ This will:
|
|
|
41
41
|
agileflow setup # Set up AgileFlow in project
|
|
42
42
|
agileflow status # Check installation + updates
|
|
43
43
|
agileflow update # Update to latest version
|
|
44
|
+
agileflow list # List installed components
|
|
44
45
|
agileflow doctor # Diagnose issues
|
|
45
46
|
agileflow uninstall # Remove from project
|
|
46
47
|
```
|
|
@@ -50,6 +51,7 @@ agileflow uninstall # Remove from project
|
|
|
50
51
|
npx agileflow setup # Set up AgileFlow in project
|
|
51
52
|
npx agileflow status # Check installation + updates
|
|
52
53
|
npx agileflow update # Update to latest version
|
|
54
|
+
npx agileflow list # List installed components
|
|
53
55
|
npx agileflow doctor # Diagnose issues
|
|
54
56
|
npx agileflow uninstall # Remove from project
|
|
55
57
|
```
|
package/package.json
CHANGED
|
@@ -148,7 +148,7 @@ chmod +x scripts/get-env.js
|
|
|
148
148
|
|
|
149
149
|
### Step 3: Create Claude Settings with Welcome Hook
|
|
150
150
|
|
|
151
|
-
Create `.claude/settings.json` with
|
|
151
|
+
Create `.claude/settings.json` with SessionStart hook that shows project status:
|
|
152
152
|
|
|
153
153
|
```json
|
|
154
154
|
{
|
|
@@ -159,7 +159,7 @@ Create `.claude/settings.json` with basic SessionStart hook:
|
|
|
159
159
|
"hooks": [
|
|
160
160
|
{
|
|
161
161
|
"type": "command",
|
|
162
|
-
"command": "
|
|
162
|
+
"command": "node scripts/agileflow-welcome.js 2>/dev/null || echo 'AgileFlow loaded'"
|
|
163
163
|
}
|
|
164
164
|
]
|
|
165
165
|
}
|
|
@@ -170,6 +170,79 @@ Create `.claude/settings.json` with basic SessionStart hook:
|
|
|
170
170
|
}
|
|
171
171
|
```
|
|
172
172
|
|
|
173
|
+
**Note**: The `agileflow-welcome.js` script outputs project status including version, branch, active stories, and recent commits. If it doesn't exist, it falls back to a simple message.
|
|
174
|
+
|
|
175
|
+
### Step 3.5: Create Welcome Script
|
|
176
|
+
|
|
177
|
+
Create `scripts/agileflow-welcome.js` for SessionStart:
|
|
178
|
+
|
|
179
|
+
```javascript
|
|
180
|
+
#!/usr/bin/env node
|
|
181
|
+
/**
|
|
182
|
+
* agileflow-welcome.js - SessionStart hook script
|
|
183
|
+
* Outputs project status for Claude context
|
|
184
|
+
*/
|
|
185
|
+
const fs = require('fs');
|
|
186
|
+
const path = require('path');
|
|
187
|
+
const { execSync } = require('child_process');
|
|
188
|
+
|
|
189
|
+
const rootDir = process.cwd();
|
|
190
|
+
|
|
191
|
+
// Get version
|
|
192
|
+
let version = 'unknown';
|
|
193
|
+
try {
|
|
194
|
+
const pkg = JSON.parse(fs.readFileSync(path.join(rootDir, 'package.json'), 'utf8'));
|
|
195
|
+
version = pkg.version || 'unknown';
|
|
196
|
+
} catch (e) {}
|
|
197
|
+
|
|
198
|
+
// Get git info
|
|
199
|
+
let branch = 'unknown';
|
|
200
|
+
let commit = 'unknown';
|
|
201
|
+
let recentCommits = [];
|
|
202
|
+
try {
|
|
203
|
+
branch = execSync('git branch --show-current', { encoding: 'utf8' }).trim();
|
|
204
|
+
commit = execSync('git rev-parse --short HEAD', { encoding: 'utf8' }).trim();
|
|
205
|
+
recentCommits = execSync('git log --oneline -3', { encoding: 'utf8' }).trim().split('\n');
|
|
206
|
+
} catch (e) {}
|
|
207
|
+
|
|
208
|
+
// Get AgileFlow status
|
|
209
|
+
let activeStories = [];
|
|
210
|
+
let wipCount = 0;
|
|
211
|
+
try {
|
|
212
|
+
const statusPath = path.join(rootDir, 'docs/09-agents/status.json');
|
|
213
|
+
if (fs.existsSync(statusPath)) {
|
|
214
|
+
const status = JSON.parse(fs.readFileSync(statusPath, 'utf8'));
|
|
215
|
+
if (status.stories) {
|
|
216
|
+
Object.entries(status.stories).forEach(([id, story]) => {
|
|
217
|
+
if (story.status === 'in_progress') {
|
|
218
|
+
activeStories.push(`${id}: ${story.title}`);
|
|
219
|
+
wipCount++;
|
|
220
|
+
}
|
|
221
|
+
});
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
} catch (e) {}
|
|
225
|
+
|
|
226
|
+
// Output
|
|
227
|
+
console.log(`Project: ${path.basename(rootDir)} v${version}`);
|
|
228
|
+
console.log(`Branch: ${branch} (${commit})`);
|
|
229
|
+
console.log(`---`);
|
|
230
|
+
if (activeStories.length > 0) {
|
|
231
|
+
console.log(`Active Stories (${wipCount} WIP):`);
|
|
232
|
+
activeStories.forEach(s => console.log(` - ${s}`));
|
|
233
|
+
} else {
|
|
234
|
+
console.log('No stories in progress');
|
|
235
|
+
}
|
|
236
|
+
console.log(`---`);
|
|
237
|
+
console.log('Recent commits:');
|
|
238
|
+
recentCommits.slice(0, 3).forEach(c => console.log(` ${c}`));
|
|
239
|
+
```
|
|
240
|
+
|
|
241
|
+
Make executable:
|
|
242
|
+
```bash
|
|
243
|
+
chmod +x scripts/agileflow-welcome.js
|
|
244
|
+
```
|
|
245
|
+
|
|
173
246
|
### Step 4: Update .gitignore
|
|
174
247
|
|
|
175
248
|
Auto-add .claude user-specific files to .gitignore:
|
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: precompact
|
|
3
|
+
description: Configure PreCompact hook for context preservation during conversation compacts
|
|
4
|
+
tools:
|
|
5
|
+
- Read
|
|
6
|
+
- Write
|
|
7
|
+
- Edit
|
|
8
|
+
- Bash
|
|
9
|
+
- Glob
|
|
10
|
+
- Grep
|
|
11
|
+
- AskUserQuestion
|
|
12
|
+
model: haiku
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# PreCompact Configuration Agent
|
|
16
|
+
|
|
17
|
+
Configures the PreCompact hook to preserve critical project context when Claude Code compacts conversations.
|
|
18
|
+
|
|
19
|
+
## Prompt
|
|
20
|
+
|
|
21
|
+
ROLE: PreCompact Configuration Specialist
|
|
22
|
+
|
|
23
|
+
OBJECTIVE
|
|
24
|
+
Set up the PreCompact hook system that outputs important project context before Claude compacts a conversation. This ensures critical information survives summarization.
|
|
25
|
+
|
|
26
|
+
## What is PreCompact?
|
|
27
|
+
|
|
28
|
+
When a Claude Code conversation fills its context window, it "compacts" (summarizes) to make room. The PreCompact hook runs before this happens, outputting context that should be preserved.
|
|
29
|
+
|
|
30
|
+
**Benefits:**
|
|
31
|
+
- Project conventions survive compacts (commit rules, file locations)
|
|
32
|
+
- Active work context is preserved (current story, branch)
|
|
33
|
+
- Key file paths are remembered
|
|
34
|
+
- Team conventions don't get lost
|
|
35
|
+
|
|
36
|
+
## Configuration Steps
|
|
37
|
+
|
|
38
|
+
### Step 1: Check Prerequisites
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
# Verify .claude/settings.json exists (hooks system must be configured)
|
|
42
|
+
if [ ! -f .claude/settings.json ]; then
|
|
43
|
+
echo "ERROR: Hooks system not configured. Run /agileflow:configure and select 'Hooks System' first."
|
|
44
|
+
exit 1
|
|
45
|
+
fi
|
|
46
|
+
|
|
47
|
+
# Check if PreCompact already configured
|
|
48
|
+
if grep -q "PreCompact" .claude/settings.json 2>/dev/null; then
|
|
49
|
+
echo "PreCompact hook already configured"
|
|
50
|
+
ALREADY_CONFIGURED=true
|
|
51
|
+
else
|
|
52
|
+
echo "PreCompact hook not yet configured"
|
|
53
|
+
ALREADY_CONFIGURED=false
|
|
54
|
+
fi
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Step 2: Create PreCompact Script
|
|
58
|
+
|
|
59
|
+
Create `scripts/precompact-context.sh`:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
#!/bin/bash
|
|
63
|
+
#
|
|
64
|
+
# AgileFlow PreCompact Hook
|
|
65
|
+
#
|
|
66
|
+
# Outputs critical context that should survive conversation compacts.
|
|
67
|
+
# Mirrors the context that /agileflow:babysit loads on startup.
|
|
68
|
+
#
|
|
69
|
+
|
|
70
|
+
# Get current version from package.json
|
|
71
|
+
VERSION=$(node -p "require('./package.json').version" 2>/dev/null || echo "unknown")
|
|
72
|
+
|
|
73
|
+
# Get current git branch
|
|
74
|
+
BRANCH=$(git branch --show-current 2>/dev/null || echo "unknown")
|
|
75
|
+
|
|
76
|
+
# Get current story from status.json (if exists)
|
|
77
|
+
CURRENT_STORY=""
|
|
78
|
+
WIP_COUNT=0
|
|
79
|
+
if [ -f "docs/09-agents/status.json" ]; then
|
|
80
|
+
CURRENT_STORY=$(node -p "
|
|
81
|
+
const s = require('./docs/09-agents/status.json');
|
|
82
|
+
const stories = Object.entries(s.stories || {})
|
|
83
|
+
.filter(([,v]) => v.status === 'in_progress')
|
|
84
|
+
.map(([k,v]) => k + ': ' + v.title)
|
|
85
|
+
.join(', ');
|
|
86
|
+
stories || 'None in progress';
|
|
87
|
+
" 2>/dev/null || echo "Unable to read")
|
|
88
|
+
|
|
89
|
+
WIP_COUNT=$(node -p "
|
|
90
|
+
const s = require('./docs/09-agents/status.json');
|
|
91
|
+
Object.values(s.stories || {}).filter(v => v.status === 'in_progress').length;
|
|
92
|
+
" 2>/dev/null || echo "0")
|
|
93
|
+
fi
|
|
94
|
+
|
|
95
|
+
# Get recent epics
|
|
96
|
+
EPICS=""
|
|
97
|
+
if [ -d "docs/05-epics" ]; then
|
|
98
|
+
EPICS=$(ls docs/05-epics/*.md 2>/dev/null | head -5 | xargs -I {} basename {} .md | tr '\n' ', ' | sed 's/,$//')
|
|
99
|
+
fi
|
|
100
|
+
|
|
101
|
+
# Get practices list
|
|
102
|
+
PRACTICES=""
|
|
103
|
+
if [ -d "docs/02-practices" ]; then
|
|
104
|
+
PRACTICES=$(ls docs/02-practices/*.md 2>/dev/null | head -8 | xargs -I {} basename {} .md | tr '\n' ', ' | sed 's/,$//')
|
|
105
|
+
fi
|
|
106
|
+
|
|
107
|
+
# Output context for Claude to preserve
|
|
108
|
+
cat << EOF
|
|
109
|
+
AGILEFLOW PROJECT CONTEXT (preserve during compact):
|
|
110
|
+
====================================================
|
|
111
|
+
|
|
112
|
+
## Project Status
|
|
113
|
+
- Project: $(basename "$(pwd)") v${VERSION}
|
|
114
|
+
- Branch: ${BRANCH}
|
|
115
|
+
- Active Stories: ${CURRENT_STORY}
|
|
116
|
+
- WIP Count: ${WIP_COUNT}
|
|
117
|
+
|
|
118
|
+
## Key Files to Check After Compact
|
|
119
|
+
- CLAUDE.md - Project system prompt with conventions
|
|
120
|
+
- README.md - Project overview and setup
|
|
121
|
+
- docs/09-agents/status.json - Story statuses and assignments
|
|
122
|
+
- docs/02-practices/ - Codebase practices (${PRACTICES:-check folder})
|
|
123
|
+
|
|
124
|
+
## Active Epics
|
|
125
|
+
${EPICS:-Check docs/05-epics/ for epic files}
|
|
126
|
+
|
|
127
|
+
## Key Conventions (from CLAUDE.md)
|
|
128
|
+
$(grep -A 15 "## Key\|## Critical\|## Important\|CRITICAL:" CLAUDE.md 2>/dev/null | head -20 || echo "- Read CLAUDE.md for project conventions")
|
|
129
|
+
|
|
130
|
+
## Recent Agent Activity
|
|
131
|
+
$(tail -3 docs/09-agents/bus/log.jsonl 2>/dev/null | head -3 || echo "- Check docs/09-agents/bus/log.jsonl for recent activity")
|
|
132
|
+
|
|
133
|
+
## Post-Compact Actions
|
|
134
|
+
1. Re-read CLAUDE.md if unsure about conventions
|
|
135
|
+
2. Check status.json for current story state
|
|
136
|
+
3. Review docs/02-practices/ for implementation patterns
|
|
137
|
+
4. Check git log for recent changes
|
|
138
|
+
|
|
139
|
+
====================================================
|
|
140
|
+
EOF
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
### Step 3: Make Script Executable
|
|
144
|
+
|
|
145
|
+
```bash
|
|
146
|
+
chmod +x scripts/precompact-context.sh
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
### Step 4: Add PreCompact Hook to Settings
|
|
150
|
+
|
|
151
|
+
Read current `.claude/settings.json` and add PreCompact hook:
|
|
152
|
+
|
|
153
|
+
```json
|
|
154
|
+
{
|
|
155
|
+
"hooks": {
|
|
156
|
+
"PreCompact": [
|
|
157
|
+
{
|
|
158
|
+
"matcher": "",
|
|
159
|
+
"hooks": [
|
|
160
|
+
{
|
|
161
|
+
"type": "command",
|
|
162
|
+
"command": "bash scripts/precompact-context.sh"
|
|
163
|
+
}
|
|
164
|
+
]
|
|
165
|
+
}
|
|
166
|
+
]
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**Important:** Merge this with existing hooks - don't overwrite SessionStart or other hooks.
|
|
172
|
+
|
|
173
|
+
### Step 5: Test the Hook
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
bash scripts/precompact-context.sh
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
Should output project context. Verify it shows:
|
|
180
|
+
- Project name and version
|
|
181
|
+
- Current git branch
|
|
182
|
+
- Active story (if any)
|
|
183
|
+
- Key conventions from CLAUDE.md
|
|
184
|
+
- Key directories
|
|
185
|
+
|
|
186
|
+
### Step 6: Document in CLAUDE.md
|
|
187
|
+
|
|
188
|
+
Add to CLAUDE.md:
|
|
189
|
+
|
|
190
|
+
```markdown
|
|
191
|
+
## PreCompact Hook
|
|
192
|
+
|
|
193
|
+
**Purpose**: Preserve critical project context during conversation compacts.
|
|
194
|
+
|
|
195
|
+
**Script**: `scripts/precompact-context.sh`
|
|
196
|
+
|
|
197
|
+
**When it runs**: Automatically before Claude compacts the conversation (either manually via `/compact` or automatically when context fills).
|
|
198
|
+
|
|
199
|
+
**What it preserves**:
|
|
200
|
+
- Project version, git branch, active stories, WIP count
|
|
201
|
+
- Active epics list and practices list
|
|
202
|
+
- Key conventions from CLAUDE.md
|
|
203
|
+
- Recent agent activity from bus/log.jsonl
|
|
204
|
+
- Post-compact action reminders
|
|
205
|
+
|
|
206
|
+
**To customize**: Edit `scripts/precompact-context.sh` to change what context is preserved.
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
## User Customization Options
|
|
210
|
+
|
|
211
|
+
Ask the user what to include in the PreCompact output:
|
|
212
|
+
|
|
213
|
+
```
|
|
214
|
+
What information should be preserved during compacts?
|
|
215
|
+
|
|
216
|
+
1. Project basics (version, branch, active story) - RECOMMENDED
|
|
217
|
+
2. Full CLAUDE.md conventions
|
|
218
|
+
3. Recent git commits
|
|
219
|
+
4. Custom context (specify)
|
|
220
|
+
|
|
221
|
+
Select options (default: 1):
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
## Output
|
|
225
|
+
|
|
226
|
+
After configuration:
|
|
227
|
+
|
|
228
|
+
```
|
|
229
|
+
✅ PreCompact Hook Configured!
|
|
230
|
+
|
|
231
|
+
Created: scripts/precompact-context.sh
|
|
232
|
+
Updated: .claude/settings.json
|
|
233
|
+
|
|
234
|
+
What happens now:
|
|
235
|
+
- Before any compact, the hook runs automatically
|
|
236
|
+
- Critical project context is output and preserved
|
|
237
|
+
- Your conventions and current work survive summarization
|
|
238
|
+
|
|
239
|
+
Test it now:
|
|
240
|
+
bash scripts/precompact-context.sh
|
|
241
|
+
|
|
242
|
+
To trigger a compact manually:
|
|
243
|
+
/compact "Additional focus areas to preserve"
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
## Rules
|
|
247
|
+
|
|
248
|
+
- REQUIRE hooks system to be configured first
|
|
249
|
+
- CREATE scripts/precompact-context.sh with intelligent defaults
|
|
250
|
+
- MERGE PreCompact hook into existing settings.json (don't overwrite)
|
|
251
|
+
- TEST the script before confirming success
|
|
252
|
+
- DOCUMENT in CLAUDE.md for future reference
|
|
253
|
+
- OFFER customization options for what to preserve
|
|
@@ -36,6 +36,7 @@ Each feature is handled by a specialized agent:
|
|
|
36
36
|
- **Auto-Archival** (`AgileFlow:agents:configuration:archival`) - Status.json size management
|
|
37
37
|
- **CI/CD** (`AgileFlow:agents:configuration:ci`) - Automated testing and quality checks
|
|
38
38
|
- **Status Line** (`AgileFlow:agents:configuration:status-line`) - Custom Claude Code status bar with AgileFlow context
|
|
39
|
+
- **PreCompact** (`AgileFlow:agents:configuration:precompact`) - Context preservation during conversation compacts
|
|
39
40
|
|
|
40
41
|
## Detection Phase (Run First)
|
|
41
42
|
|
|
@@ -124,6 +125,15 @@ else
|
|
|
124
125
|
STATUSLINE_CONFIGURED=false
|
|
125
126
|
fi
|
|
126
127
|
|
|
128
|
+
# Check PreCompact hook
|
|
129
|
+
if [ -f scripts/precompact-context.sh ] && grep -q "PreCompact" .claude/settings.json 2>/dev/null; then
|
|
130
|
+
echo "✅ PreCompact hook configured"
|
|
131
|
+
PRECOMPACT_CONFIGURED=true
|
|
132
|
+
else
|
|
133
|
+
echo "❌ PreCompact hook not configured"
|
|
134
|
+
PRECOMPACT_CONFIGURED=false
|
|
135
|
+
fi
|
|
136
|
+
|
|
127
137
|
echo "===================================="
|
|
128
138
|
echo ""
|
|
129
139
|
```
|
|
@@ -164,7 +174,8 @@ The AskUserQuestion tool allows you to prompt the user for input. It requires XM
|
|
|
164
174
|
{"label": "Hooks System", "description": "Set up event-driven automation"},
|
|
165
175
|
{"label": "Auto-Archival", "description": "Manage status.json file size"},
|
|
166
176
|
{"label": "CI/CD", "description": "Set up automated testing"},
|
|
167
|
-
{"label": "Status Line", "description": "Custom status bar with story/WIP/context info"}
|
|
177
|
+
{"label": "Status Line", "description": "Custom status bar with story/WIP/context info"},
|
|
178
|
+
{"label": "PreCompact Hook", "description": "Preserve project context during conversation compacts"}
|
|
168
179
|
]
|
|
169
180
|
}]</parameter>
|
|
170
181
|
</invoke>
|
|
@@ -183,7 +194,8 @@ The AskUserQuestion tool allows you to prompt the user for input. It requires XM
|
|
|
183
194
|
{"label": "Hooks System", "description": "Set up event-driven automation"},
|
|
184
195
|
{"label": "Auto-Archival", "description": "Manage status.json file size"},
|
|
185
196
|
{"label": "CI/CD", "description": "Set up automated testing"},
|
|
186
|
-
{"label": "Status Line", "description": "Custom status bar with story/WIP/context info"}
|
|
197
|
+
{"label": "Status Line", "description": "Custom status bar with story/WIP/context info"},
|
|
198
|
+
{"label": "PreCompact Hook", "description": "Preserve project context during conversation compacts"}
|
|
187
199
|
]
|
|
188
200
|
}]</parameter>
|
|
189
201
|
</invoke>
|
|
@@ -205,6 +217,7 @@ Available options:
|
|
|
205
217
|
4. Auto-Archival (status.json size management)
|
|
206
218
|
5. CI/CD (automated testing and quality checks)
|
|
207
219
|
6. Status Line (custom status bar with story/WIP/context info)
|
|
220
|
+
7. PreCompact Hook (preserve context during conversation compacts)
|
|
208
221
|
|
|
209
222
|
You can select multiple options. Features already configured are marked with ✅.
|
|
210
223
|
|
|
@@ -215,6 +228,7 @@ Current status:
|
|
|
215
228
|
- Auto-Archival: [✅ Configured / ❌ Not configured]
|
|
216
229
|
- CI/CD: [✅ Configured / ❌ Not configured]
|
|
217
230
|
- Status Line: [✅ Configured / ❌ Not configured]
|
|
231
|
+
- PreCompact Hook: [✅ Configured / ❌ Not configured]
|
|
218
232
|
|
|
219
233
|
Select features to configure:
|
|
220
234
|
```
|
|
@@ -287,6 +301,16 @@ Task({
|
|
|
287
301
|
})
|
|
288
302
|
```
|
|
289
303
|
|
|
304
|
+
#### PreCompact Agent
|
|
305
|
+
|
|
306
|
+
```javascript
|
|
307
|
+
Task({
|
|
308
|
+
subagent_type: "AgileFlow:agents:configuration:precompact",
|
|
309
|
+
description: "Configure PreCompact hook",
|
|
310
|
+
prompt: "Set up the PreCompact hook to preserve project context during conversation compacts. Create scripts/precompact-context.sh, add PreCompact hook to .claude/settings.json, and document in CLAUDE.md."
|
|
311
|
+
})
|
|
312
|
+
```
|
|
313
|
+
|
|
290
314
|
### Parallel Execution
|
|
291
315
|
|
|
292
316
|
**CRITICAL**: Spawn multiple agents in a **single message** for parallel execution:
|
|
@@ -308,13 +332,15 @@ Task({ subagent_type: "AgileFlow:agents:configuration:hooks", ... })
|
|
|
308
332
|
Some agents have dependencies:
|
|
309
333
|
- **Auto-Archival** depends on **Hooks System** (needs .claude/settings.json to exist)
|
|
310
334
|
- **Status Line** depends on **Hooks System** (needs .claude/settings.json to exist)
|
|
335
|
+
- **PreCompact** depends on **Hooks System** (needs .claude/settings.json to exist)
|
|
311
336
|
- **Git Config**, **Attribution**, and **CI/CD** are independent (can run in parallel)
|
|
312
337
|
|
|
313
338
|
**Execution Strategy**:
|
|
314
339
|
1. If user selects Git + Attribution + CI: Run in parallel (no dependencies)
|
|
315
340
|
2. If user selects Hooks + Archival: Run hooks FIRST, then archival (dependency)
|
|
316
341
|
3. If user selects Hooks + Status Line: Run hooks FIRST, then status line (dependency)
|
|
317
|
-
4. If user selects
|
|
342
|
+
4. If user selects Hooks + PreCompact: Run hooks FIRST, then precompact (dependency)
|
|
343
|
+
5. If user selects all 7: Run Git + Attribution + CI in parallel, wait, then run Hooks, wait, then run Archival + Status Line + PreCompact in parallel
|
|
318
344
|
|
|
319
345
|
## Agent Result Handling
|
|
320
346
|
|
|
@@ -330,6 +356,7 @@ Results:
|
|
|
330
356
|
- Auto-Archival: [✅ Configured / ❌ Failed / ⏭️ Skipped]
|
|
331
357
|
- CI/CD: [✅ Configured / ❌ Failed / ⏭️ Skipped]
|
|
332
358
|
- Status Line: [✅ Configured / ❌ Failed / ⏭️ Skipped]
|
|
359
|
+
- PreCompact Hook: [✅ Configured / ❌ Failed / ⏭️ Skipped]
|
|
333
360
|
|
|
334
361
|
Next steps:
|
|
335
362
|
[Agent-specific next steps from results]
|
|
@@ -396,6 +423,13 @@ If an agent fails:
|
|
|
396
423
|
- Document in CLAUDE.md
|
|
397
424
|
- **CRITICAL**: Remind user to restart Claude Code
|
|
398
425
|
|
|
426
|
+
### 7. PreCompact Hook (precompact agent)
|
|
427
|
+
- Create `scripts/precompact-context.sh` script
|
|
428
|
+
- Add `PreCompact` hook to `.claude/settings.json`
|
|
429
|
+
- Script outputs: version, branch, active story, key conventions
|
|
430
|
+
- Document in CLAUDE.md
|
|
431
|
+
- Hook runs automatically before conversation compacts
|
|
432
|
+
|
|
399
433
|
## Example Workflow
|
|
400
434
|
|
|
401
435
|
```
|
|
@@ -409,9 +443,10 @@ If an agent fails:
|
|
|
409
443
|
❌ Auto-archival not configured
|
|
410
444
|
❌ CI/CD not configured
|
|
411
445
|
❌ Status line not configured
|
|
446
|
+
❌ PreCompact hook not configured
|
|
412
447
|
|
|
413
448
|
3. Orchestrator presents menu using AskUserQuestion:
|
|
414
|
-
"Select features to configure: [Git Repository, Attribution Settings, Hooks System, Auto-Archival, CI/CD, Status Line]"
|
|
449
|
+
"Select features to configure: [Git Repository, Attribution Settings, Hooks System, Auto-Archival, CI/CD, Status Line, PreCompact Hook]"
|
|
415
450
|
|
|
416
451
|
4. User selects: ["Attribution Settings", "Hooks System", "CI/CD"]
|
|
417
452
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
domain: accessibility
|
|
2
|
-
last_updated: 2025-12-
|
|
3
|
-
version: 1.
|
|
2
|
+
last_updated: 2025-12-21
|
|
3
|
+
version: 1.1
|
|
4
4
|
|
|
5
5
|
files:
|
|
6
6
|
components:
|
|
@@ -21,6 +21,12 @@ files:
|
|
|
21
21
|
- path: ACCESSIBILITY.md
|
|
22
22
|
purpose: Accessibility statement
|
|
23
23
|
|
|
24
|
+
cli:
|
|
25
|
+
- path: packages/cli/src/core/
|
|
26
|
+
purpose: CLI commands and agents (primary accessibility focus for AgileFlow)
|
|
27
|
+
- path: packages/cli/tools/
|
|
28
|
+
purpose: CLI tools and installers
|
|
29
|
+
|
|
24
30
|
relationships:
|
|
25
31
|
- component_type: form
|
|
26
32
|
requirements: [labels, error_messages, focus_management]
|
|
@@ -31,6 +37,9 @@ relationships:
|
|
|
31
37
|
- component_type: navigation
|
|
32
38
|
requirements: [keyboard_nav, skip_links, landmarks]
|
|
33
39
|
aria: [role=navigation, aria-current]
|
|
40
|
+
- component_type: cli_prompt
|
|
41
|
+
requirements: [clear_instructions, keyboard_only, error_feedback]
|
|
42
|
+
libraries: [inquirer, chalk, ora]
|
|
34
43
|
|
|
35
44
|
patterns:
|
|
36
45
|
- name: Focus Management
|
|
@@ -45,6 +54,15 @@ patterns:
|
|
|
45
54
|
- name: Color Contrast
|
|
46
55
|
description: "4.5:1 for text, 3:1 for large text"
|
|
47
56
|
implementation: "Use contrast checker tools"
|
|
57
|
+
- name: CLI Semantic Colors
|
|
58
|
+
description: "Terminal colors convey meaning consistently"
|
|
59
|
+
implementation: "Green=success, Red=error, Yellow=warning, Cyan=info, no color-only indicators"
|
|
60
|
+
- name: CLI Progress Feedback
|
|
61
|
+
description: "Visual feedback for long-running operations"
|
|
62
|
+
implementation: "Ora spinners with descriptive text, percentage indicators where applicable"
|
|
63
|
+
- name: CLI Error Messages
|
|
64
|
+
description: "Clear, actionable error messages"
|
|
65
|
+
implementation: "Context + problem + solution, colored output with chalk, exit codes for automation"
|
|
48
66
|
|
|
49
67
|
conventions:
|
|
50
68
|
- "WCAG 2.1 AA minimum, AAA preferred"
|
|
@@ -54,6 +72,10 @@ conventions:
|
|
|
54
72
|
- "Color never sole indicator of meaning"
|
|
55
73
|
- "Motion respects prefers-reduced-motion"
|
|
56
74
|
- "Skip links for keyboard users"
|
|
75
|
+
- "CLI: Always provide text with colored output (never color-only)"
|
|
76
|
+
- "CLI: All prompts keyboard-navigable (arrow keys, tab, enter)"
|
|
77
|
+
- "CLI: Error messages include context and next steps"
|
|
78
|
+
- "CLI: Progress indicators have descriptive text"
|
|
57
79
|
|
|
58
80
|
wcag_checklist:
|
|
59
81
|
perceivable:
|
|
@@ -74,4 +96,20 @@ wcag_checklist:
|
|
|
74
96
|
- "4.1.1 Parsing (A)"
|
|
75
97
|
- "4.1.2 Name, Role, Value (A)"
|
|
76
98
|
|
|
77
|
-
learnings:
|
|
99
|
+
learnings:
|
|
100
|
+
- date: 2025-12-21
|
|
101
|
+
context: "AgileFlow CLI accessibility patterns"
|
|
102
|
+
insight: "AgileFlow is a CLI tool, not a web application. Accessibility focuses on terminal UX: clear error messages with semantic colors (chalk), keyboard-friendly prompts (inquirer), progress indicators (ora spinners), and consistent color conventions (green=success, red=error, yellow=warning)."
|
|
103
|
+
impact: "Shifted accessibility focus from WCAG web patterns to CLI usability patterns. All user-facing output should be screen-reader friendly by always pairing colors with descriptive text."
|
|
104
|
+
- date: 2025-12-21
|
|
105
|
+
context: "CLI semantic color system"
|
|
106
|
+
insight: "Terminal colors must never be the sole indicator of meaning. Always include descriptive text alongside colored output. Example: '✓ Success: Installation complete' (green) vs just green checkmark."
|
|
107
|
+
impact: "Ensures CLI output is accessible to users with color blindness or screen readers. All installers (ui.js, docs-setup.js) follow this pattern."
|
|
108
|
+
- date: 2025-12-21
|
|
109
|
+
context: "Interactive prompts accessibility"
|
|
110
|
+
insight: "All CLI prompts use inquirer library which provides built-in keyboard navigation (arrow keys, tab, enter, escape). Prompts always include clear instructions and validation error messages."
|
|
111
|
+
impact: "Users can navigate all AgileFlow prompts without mouse. Validation errors are actionable and specific (e.g., 'Please enter a valid directory path' vs 'Invalid input')."
|
|
112
|
+
- date: 2025-12-21
|
|
113
|
+
context: "Long-running operation feedback"
|
|
114
|
+
insight: "AgileFlow uses ora spinners for operations >1 second. Spinners always have descriptive text explaining current action (e.g., 'Installing dependencies...' not just spinner). Completion shows success/failure with clear messaging."
|
|
115
|
+
impact: "Users always know what's happening during installs, setups, and file operations. No silent failures or mysterious waiting periods. Screen readers can announce status changes."
|