@iservu-inc/adf-cli 0.3.6 → 0.4.13

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 (29) hide show
  1. package/.project/chats/{current → complete}/2025-10-03_AI-PROVIDER-INTEGRATION.md +34 -35
  2. package/.project/chats/complete/2025-10-04_CONFIG-COMMAND.md +503 -0
  3. package/.project/chats/complete/2025-10-04_PHASE-4-1-SMART-FILTERING.md +381 -0
  4. package/.project/chats/current/2025-10-04_PHASE-4-2-COMPLETION-AND-ROADMAP.md +344 -0
  5. package/.project/chats/current/2025-10-04_PHASE-4-2-LEARNING-SYSTEM.md +239 -0
  6. package/.project/chats/current/SESSION-STATUS.md +142 -33
  7. package/.project/docs/PHASE-4-2-LEARNING-SYSTEM.md +881 -0
  8. package/.project/docs/ROADMAP.md +540 -0
  9. package/.project/docs/SMART-FILTERING-SYSTEM.md +385 -0
  10. package/.project/docs/goals/PROJECT-VISION.md +63 -11
  11. package/CHANGELOG.md +125 -1
  12. package/README.md +476 -381
  13. package/lib/analyzers/project-analyzer.js +380 -0
  14. package/lib/commands/config.js +68 -1
  15. package/lib/commands/init.js +3 -22
  16. package/lib/filters/question-filter.js +480 -0
  17. package/lib/frameworks/interviewer.js +208 -4
  18. package/lib/learning/learning-manager.js +447 -0
  19. package/lib/learning/pattern-detector.js +376 -0
  20. package/lib/learning/rule-generator.js +304 -0
  21. package/lib/learning/skip-tracker.js +260 -0
  22. package/lib/learning/storage.js +296 -0
  23. package/package.json +70 -69
  24. package/tests/learning-storage.test.js +184 -0
  25. package/tests/pattern-detector.test.js +297 -0
  26. package/tests/project-analyzer.test.js +221 -0
  27. package/tests/question-filter.test.js +297 -0
  28. package/tests/skip-tracker.test.js +198 -0
  29. /package/.project/chats/{current → complete}/2025-10-03_FRAMEWORK-UPDATE-SYSTEM.md +0 -0
package/README.md CHANGED
@@ -1,381 +1,476 @@
1
- # @iservu-inc/adf-cli
2
-
3
- CLI tool for AgentDevFramework - AI-assisted development framework with multi-provider AI support.
4
-
5
- Transform your development workflow with AI-guided requirements gathering using Anthropic Claude, OpenAI GPT, Google Gemini, or OpenRouter.
6
-
7
- ## Installation
8
-
9
- ### Global Installation (Recommended)
10
-
11
- ```bash
12
- npm install -g @iservu-inc/adf-cli
13
- ```
14
-
15
- ### One-time Use (npx)
16
-
17
- ```bash
18
- npx @iservu-inc/adf-cli init
19
- ```
20
-
21
- ## Usage
22
-
23
- ### Initialize Framework
24
-
25
- Initialize AgentDevFramework in your current project:
26
-
27
- ```bash
28
- adf init
29
- ```
30
-
31
- The interactive init process will:
32
- 1. Optionally configure AI Provider (or use `adf config` later)
33
- 2. Detect if this is a new or existing project
34
- 3. Ask AI-guided questions to gather requirements
35
- 4. Optionally collect documentation URLs (e.g., API docs, design docs)
36
- 5. Optionally collect local documentation file paths (e.g., `./docs/`, `./README.md`)
37
- 6. Automatically deploy to your preferred development tool
38
-
39
- #### Workflow Selection Options
40
-
41
- Skip interactive questions and specify workflow directly:
42
-
43
- ```bash
44
- # Level 1: Rapid Development (PRP)
45
- adf init --rapid
46
-
47
- # Level 2: Specification-Driven (Balanced)
48
- adf init --balanced
49
-
50
- # Level 3: BMAD Comprehensive
51
- adf init --comprehensive
52
- ```
53
-
54
- #### Direct Tool Deployment
55
-
56
- Initialize and deploy to a specific tool in one command:
57
-
58
- ```bash
59
- adf init --tool windsurf
60
- adf init --rapid --tool cursor
61
- ```
62
-
63
- ### Configure ADF Settings
64
-
65
- Configure ADF settings like AI provider, project preferences, and more:
66
-
67
- ```bash
68
- adf config
69
- ```
70
-
71
- This command provides an interactive menu with:
72
- - **AI Provider Setup** - Configure Anthropic, OpenAI, Google Gemini, or OpenRouter
73
- - Status indicators showing what's configured (green ✓) or not (yellow ○)
74
- - Future configuration options (coming soon)
75
-
76
- You can run `adf config` anytime to:
77
- - Configure AI for the first time
78
- - Switch AI providers or models
79
- - Update your API keys
80
-
81
- ### Deploy to Development Tool
82
-
83
- Deploy framework configuration to your development tool:
84
-
85
- ```bash
86
- # Deploy to specific tool
87
- adf deploy windsurf
88
- adf deploy cursor
89
- adf deploy vscode
90
-
91
- # List available tools
92
- adf deploy --list
93
- ```
94
-
95
- **Supported Tools:**
96
- - windsurf
97
- - cursor
98
- - vscode
99
- - vscode-insider
100
- - kiro
101
- - trae
102
- - claude-code
103
- - gemini-cli
104
- - codex-cli
105
-
106
- ### Update CLI
107
-
108
- Check for and install updates:
109
-
110
- ```bash
111
- # Check and update interactively
112
- adf update
113
-
114
- # Check version only (don't install)
115
- adf update --check
116
- ```
117
-
118
- Or update directly:
119
-
120
- ```bash
121
- npm update -g @iservu-inc/adf-cli
122
- ```
123
-
124
- ### Version
125
-
126
- Check installed version:
127
-
128
- ```bash
129
- adf --version
130
- adf -v
131
- ```
132
-
133
- ## AI Provider Configuration
134
-
135
- ADF CLI requires an AI provider to guide you through requirements gathering with intelligent follow-up questions and answer quality analysis.
136
-
137
- ### Supported AI Providers
138
-
139
- - **Anthropic Claude** (Claude 3.5 Sonnet, Claude 3 Opus, etc.)
140
- - **OpenAI** (GPT-4, GPT-4 Turbo, GPT-3.5 Turbo, etc.)
141
- - **Google Gemini** (Gemini 1.5 Pro, Gemini 1.5 Flash, etc.)
142
- - **OpenRouter** (Access to 100+ models from multiple providers)
143
-
144
- ### API Key Setup
145
-
146
- Configure your AI provider using the config command:
147
-
148
- ```bash
149
- adf config
150
- ```
151
-
152
- Then select "AI Provider Setup" to:
153
-
154
- 1. **Select your AI provider** from the list above
155
- 2. **Enter your API key** (securely saved to `.adf/.env`)
156
- 3. **Choose a model** with type-to-filter autocomplete
157
-
158
- Your API key is stored locally in `.adf/.env` and never leaves your machine.
159
-
160
- **Note:** You can also configure AI during `adf init`, or skip it and configure later.
161
-
162
- **Example `.adf/.env` file:**
163
- ```env
164
- ANTHROPIC_API_KEY=sk-ant-api03-...
165
- ```
166
-
167
- ### Getting API Keys
168
-
169
- - **Anthropic:** https://console.anthropic.com/
170
- - **OpenAI:** https://platform.openai.com/api-keys
171
- - **Google Gemini:** https://ai.google.dev/
172
- - **OpenRouter:** https://openrouter.ai/keys
173
-
174
- ### AI-Powered Features
175
-
176
- The AI provider enhances your workflow by:
177
-
178
- - **Real-Time Answer Quality Analysis** - Scores your answers 0-100
179
- - **Intelligent Follow-Up Questions** - Automatically generated based on your responses
180
- - **Context-Aware Guidance** - Tailored suggestions for your project type
181
- - **Skip Functionality** - Type "skip" anytime to move forward
182
-
183
- ### Changing Providers
184
-
185
- To switch AI providers or models:
186
-
187
- ```bash
188
- adf config
189
- ```
190
-
191
- Select "AI Provider Setup" and you'll see:
192
- - **Configured** status with current provider name
193
- - Option to reconfigure with a new provider or model
194
-
195
- Your previous API keys remain saved in `.adf/.env` for easy switching between providers.
196
-
197
- ## What Gets Installed
198
-
199
- When you run `adf init`, the following structure is created in your project:
200
-
201
- ```
202
- your-project/
203
- ├── .adf/ # Framework files (isolated)
204
- │ ├── .env # AI provider API keys (gitignored, secure)
205
- │ ├── context.json # Your workflow configuration
206
- │ ├── sessions/ # Requirements gathering sessions
207
- │ ├── scripts/ # Helper scripts
208
- │ └── shared/ # Templates, agents, and resources
209
- │ ├── agents/ # Agent definition files
210
- │ ├── templates/ # PRP, BMAD, Spec-Kit templates
211
- │ ├── mcp/ # MCP configurations
212
- │ └── memory/ # Framework memory/constitution
213
- ├── .framework/ # Deployment directory
214
- └── agents/ # Deployed agent files for your tool
215
- ├── .env.template # Environment variables template
216
- ├── .[tool]rules # Tool-specific config (e.g., .windsurfrules)
217
- └── [your existing files] # Completely untouched!
218
- ```
219
-
220
- **Important:** Your `package.json` and existing project files remain completely untouched.
221
-
222
- ### context.json Structure
223
-
224
- The `.adf/context.json` file contains your workflow configuration:
225
-
226
- ```json
227
- {
228
- "version": "0.1.6",
229
- "workflow": "rapid",
230
- "projectType": "existing",
231
- "documentationUrls": [
232
- "https://api.example.com/docs"
233
- ],
234
- "documentationFiles": [
235
- "./docs/",
236
- "./README.md"
237
- ],
238
- "createdAt": "2025-10-02T...",
239
- "agents": ["dev", "qa"],
240
- "templates": {
241
- "prp": ["prp_story.md", "prp_task.md"],
242
- "bmad": false,
243
- "specKit": false
244
- }
245
- }
246
- ```
247
-
248
- ## Workflow Levels
249
-
250
- ### Level 1: Rapid Development (PRP)
251
- - **Time:** 5-15 minutes planning
252
- - **Agents:** dev, qa
253
- - **Best for:** Solo developers, simple projects, prototyping
254
- - **Templates:** PRP story, PRP task
255
-
256
- ### Level 2: Specification-Driven (Balanced)
257
- - **Time:** 30-60 minutes planning
258
- - **Agents:** analyst, pm, dev, qa
259
- - **Best for:** Small teams, moderate complexity
260
- - **Templates:** Full PRP suite, spec templates
261
-
262
- ### Level 3: BMAD Comprehensive
263
- - **Time:** 1-2+ hours planning
264
- - **Agents:** analyst, pm, architect, sm, dev, qa
265
- - **Best for:** Large teams, complex systems, strategic planning
266
- - **Templates:** Complete BMAD framework, governance tools
267
-
268
- ## Examples
269
-
270
- ### Quick Start (New Project)
271
-
272
- ```bash
273
- # Create new project directory
274
- mkdir my-new-project
275
- cd my-new-project
276
-
277
- # Initialize with Rapid workflow
278
- adf init --rapid
279
-
280
- # Deploy to Cursor
281
- adf deploy cursor
282
- ```
283
-
284
- ### Existing Project
285
-
286
- ```bash
287
- # Navigate to your project
288
- cd my-existing-project
289
-
290
- # Initialize (interactive workflow selection)
291
- adf init
292
-
293
- # Follow prompts to select workflow and deployment tool
294
- ```
295
-
296
- ### Enterprise Setup
297
-
298
- ```bash
299
- # Initialize with comprehensive workflow
300
- adf init --comprehensive
301
-
302
- # Deploy to multiple tools
303
- adf deploy windsurf
304
- adf deploy vscode
305
- ```
306
-
307
- ## Updating Framework Files
308
-
309
- When we release updates to the framework:
310
-
311
- 1. **Check for updates:**
312
- ```bash
313
- adf update --check
314
- ```
315
-
316
- 2. **Install update:**
317
- ```bash
318
- adf update
319
- ```
320
-
321
- Or directly:
322
- ```bash
323
- npm update -g @iservu-inc/adf-cli
324
- ```
325
-
326
- 3. **Re-initialize your project** (optional, for major updates):
327
- ```bash
328
- adf init
329
- # Confirm overwrite when prompted
330
- ```
331
-
332
- ## Version History
333
-
334
- See [CHANGELOG.md](./CHANGELOG.md) for detailed version history.
335
-
336
- **Latest:** v0.3.6
337
- - AI-guided requirements gathering with multi-provider support
338
- - Real-time answer quality analysis and intelligent follow-ups
339
- - Secure API key persistence in `.adf/.env`
340
- - Dynamic model fetching with autocomplete selection
341
- - Enhanced UX with visible skip instructions
342
- - Automatic deployment to your preferred IDE
343
-
344
- ## Troubleshooting
345
-
346
- ### Command not found
347
-
348
- If `adf` command is not found after installation:
349
-
350
- 1. Check global npm bin directory is in PATH:
351
- ```bash
352
- npm config get prefix
353
- ```
354
-
355
- 2. Reinstall globally:
356
- ```bash
357
- npm uninstall -g @iservu-inc/adf-cli
358
- npm install -g @iservu-inc/adf-cli
359
- ```
360
-
361
- ### Permission errors (Linux/macOS)
362
-
363
- ```bash
364
- sudo npm install -g @iservu-inc/adf-cli
365
- ```
366
-
367
- Or configure npm to install globally without sudo:
368
- ```bash
369
- npm config set prefix ~/.npm-global
370
- # Add ~/.npm-global/bin to PATH
371
- ```
372
-
373
- ## Support
374
-
375
- For issues, questions, or contributions:
376
- - GitHub: https://github.com/iservu/adf-cli
377
- - Issues: https://github.com/iservu/adf-cli/issues
378
-
379
- ## License
380
-
381
- MIT © iServU
1
+ # @iservu-inc/adf-cli
2
+
3
+ CLI tool for AgentDevFramework - AI-assisted development framework with multi-provider AI support.
4
+
5
+ Transform your development workflow with AI-guided requirements gathering using Anthropic Claude, OpenAI GPT, Google Gemini, or OpenRouter.
6
+
7
+ ## Installation
8
+
9
+ ### Global Installation (Recommended)
10
+
11
+ ```bash
12
+ npm install -g @iservu-inc/adf-cli
13
+ ```
14
+
15
+ ### One-time Use (npx)
16
+
17
+ ```bash
18
+ npx @iservu-inc/adf-cli init
19
+ ```
20
+
21
+ ## Usage
22
+
23
+ ### Initialize Framework
24
+
25
+ Initialize AgentDevFramework in your current project:
26
+
27
+ ```bash
28
+ adf init
29
+ ```
30
+
31
+ The interactive init process will:
32
+ 1. Optionally configure AI Provider (or use `adf config` later)
33
+ 2. Detect if this is a new or existing project
34
+ 3. Ask AI-guided questions to gather requirements
35
+ 4. Optionally collect documentation URLs (e.g., API docs, design docs)
36
+ 5. Optionally collect local documentation file paths (e.g., `./docs/`, `./README.md`)
37
+ 6. Automatically deploy to your preferred development tool
38
+
39
+ #### Workflow Selection Options
40
+
41
+ Skip interactive questions and specify workflow directly:
42
+
43
+ ```bash
44
+ # Level 1: Rapid Development (PRP)
45
+ adf init --rapid
46
+
47
+ # Level 2: Specification-Driven (Balanced)
48
+ adf init --balanced
49
+
50
+ # Level 3: BMAD Comprehensive
51
+ adf init --comprehensive
52
+ ```
53
+
54
+ #### Direct Tool Deployment
55
+
56
+ Initialize and deploy to a specific tool in one command:
57
+
58
+ ```bash
59
+ adf init --tool windsurf
60
+ adf init --rapid --tool cursor
61
+ ```
62
+
63
+ ### Configure ADF Settings
64
+
65
+ Configure ADF settings like AI provider, learning system, and more:
66
+
67
+ ```bash
68
+ adf config
69
+ ```
70
+
71
+ This command provides an interactive menu with:
72
+ - **AI Provider Setup** - Configure Anthropic, OpenAI, Google Gemini, or OpenRouter
73
+ - **Learning System** - Manage interview learning data and preferences
74
+ - Status indicators showing what's configured (green ), disabled (yellow ○), or has data
75
+ - Future configuration options (coming soon)
76
+
77
+ You can run `adf config` anytime to:
78
+ - Configure AI for the first time
79
+ - Switch AI providers or models
80
+ - Update your API keys
81
+ - Review learning patterns and manage learned preferences
82
+
83
+ ### Deploy to Development Tool
84
+
85
+ Deploy framework configuration to your development tool:
86
+
87
+ ```bash
88
+ # Deploy to specific tool
89
+ adf deploy windsurf
90
+ adf deploy cursor
91
+ adf deploy vscode
92
+
93
+ # List available tools
94
+ adf deploy --list
95
+ ```
96
+
97
+ **Supported Tools:**
98
+ - windsurf
99
+ - cursor
100
+ - vscode
101
+ - vscode-insider
102
+ - kiro
103
+ - trae
104
+ - claude-code
105
+ - gemini-cli
106
+ - codex-cli
107
+
108
+ ### Update CLI
109
+
110
+ Check for and install updates:
111
+
112
+ ```bash
113
+ # Check and update interactively
114
+ adf update
115
+
116
+ # Check version only (don't install)
117
+ adf update --check
118
+ ```
119
+
120
+ Or update directly:
121
+
122
+ ```bash
123
+ npm update -g @iservu-inc/adf-cli
124
+ ```
125
+
126
+ ### Version
127
+
128
+ Check installed version:
129
+
130
+ ```bash
131
+ adf --version
132
+ adf -v
133
+ ```
134
+
135
+ ## AI Provider Configuration
136
+
137
+ ADF CLI requires an AI provider to guide you through requirements gathering with intelligent follow-up questions and answer quality analysis.
138
+
139
+ ### Supported AI Providers
140
+
141
+ - **Anthropic Claude** (Claude 3.5 Sonnet, Claude 3 Opus, etc.)
142
+ - **OpenAI** (GPT-4, GPT-4 Turbo, GPT-3.5 Turbo, etc.)
143
+ - **Google Gemini** (Gemini 1.5 Pro, Gemini 1.5 Flash, etc.)
144
+ - **OpenRouter** (Access to 100+ models from multiple providers)
145
+
146
+ ### API Key Setup
147
+
148
+ Configure your AI provider using the config command:
149
+
150
+ ```bash
151
+ adf config
152
+ ```
153
+
154
+ Then select "AI Provider Setup" to:
155
+
156
+ 1. **Select your AI provider** from the list above
157
+ 2. **Enter your API key** (securely saved to `.adf/.env`)
158
+ 3. **Choose a model** with type-to-filter autocomplete
159
+
160
+ Your API key is stored locally in `.adf/.env` and never leaves your machine.
161
+
162
+ **Note:** You can also configure AI during `adf init`, or skip it and configure later.
163
+
164
+ **Example `.adf/.env` file:**
165
+ ```env
166
+ ANTHROPIC_API_KEY=sk-ant-api03-...
167
+ ```
168
+
169
+ ### Getting API Keys
170
+
171
+ - **Anthropic:** https://console.anthropic.com/
172
+ - **OpenAI:** https://platform.openai.com/api-keys
173
+ - **Google Gemini:** https://ai.google.dev/
174
+ - **OpenRouter:** https://openrouter.ai/keys
175
+
176
+ ### AI-Powered Features
177
+
178
+ The AI provider enhances your workflow by:
179
+
180
+ - **Smart Question Filtering** - Automatically analyzes your project and skips irrelevant questions (e.g., UI questions for CLI tools)
181
+ - **Learning System** - Learns from your skip behavior to improve filtering over time:
182
+ - Automatically detects patterns in skipped questions across sessions
183
+ - Generates learned rules from high-confidence patterns (75%+)
184
+ - Applies your preferences in future interviews with your approval
185
+ - Privacy-first design: all data stored locally in `.adf/learning/`
186
+ - Manage via `adf config` → Learning System
187
+ - **Real-Time Answer Quality Analysis** - Scores your answers 0-100
188
+ - **Intelligent Follow-Up Questions** - Automatically generated based on your responses
189
+ - **Context-Aware Guidance** - Tailored suggestions for your project type
190
+ - **Skip Functionality** - Type "skip" anytime to move forward
191
+
192
+ ### Changing Providers
193
+
194
+ To switch AI providers or models:
195
+
196
+ ```bash
197
+ adf config
198
+ ```
199
+
200
+ Select "AI Provider Setup" and you'll see:
201
+ - ✓ **Configured** status with current provider name
202
+ - Option to reconfigure with a new provider or model
203
+
204
+ Your previous API keys remain saved in `.adf/.env` for easy switching between providers.
205
+
206
+ ## Learning System
207
+
208
+ ADF CLI includes an intelligent Learning System that improves your interview experience by learning from your behavior across sessions.
209
+
210
+ ### How It Works
211
+
212
+ 1. **Automatic Tracking** - Silently tracks your skip and answer patterns during interviews
213
+ 2. **Pattern Detection** - Analyzes your history to identify consistent preferences:
214
+ - Questions you always skip (e.g., deployment questions for prototype projects)
215
+ - Categories you frequently skip (e.g., UI questions for CLI tools)
216
+ - Framework-specific skips (e.g., routing questions for Next.js projects)
217
+ - Answer style preferences (brief vs detailed)
218
+ 3. **Rule Generation** - Converts high-confidence patterns (≥75%) into learned rules
219
+ 4. **Adaptive Filtering** - Applies learned rules in future interviews (with your approval)
220
+
221
+ ### Managing Learning Data
222
+
223
+ Access the Learning System via:
224
+
225
+ ```bash
226
+ adf config
227
+ # Select "Learning System"
228
+ ```
229
+
230
+ **Available Options:**
231
+
232
+ - **View Skip History** - See most skipped questions and categories across all sessions
233
+ - **Review Patterns** - View detected patterns by confidence level (high/medium/low)
234
+ - **Manage Rules** - Enable, disable, or remove individual learned rules
235
+ - **Settings** - Configure learning system behavior:
236
+ - Enable/disable learning system
237
+ - Toggle tracking, pattern detection, and filter application
238
+ - Adjust confidence thresholds
239
+ - Reset to defaults
240
+ - **Clear Data** - Delete all learning data with confirmation
241
+
242
+ ### Privacy & Control
243
+
244
+ - **Local Storage** - All learning data stored in `.adf/learning/` (never transmitted externally)
245
+ - **Transparent** - View all tracked data, patterns, and rules anytime
246
+ - **User Control** - Multiple layers:
247
+ - System-level: Enable/disable entire learning system
248
+ - Feature-level: Toggle tracking, detection, and filtering separately
249
+ - Rule-level: Enable/disable individual learned rules
250
+ - Session-level: Approve learned preferences before each interview
251
+ - **No Surprises** - Learning system shows preview of rules before applying them
252
+
253
+ ### Learning Data Structure
254
+
255
+ The `.adf/learning/` directory contains:
256
+
257
+ ```
258
+ .adf/learning/
259
+ ├── skip-history.json # Skip events from all sessions
260
+ ├── answer-history.json # Answer metadata from all sessions
261
+ ├── patterns.json # Detected patterns
262
+ ├── learned-rules.json # Active learned rules
263
+ ├── config.json # Learning system settings
264
+ └── stats.json # Learning statistics
265
+ ```
266
+
267
+ ### Example Workflow
268
+
269
+ 1. **First Interview** - Skip deployment questions because you're building a prototype
270
+ 2. **Second Interview** - Skip same deployment questions again
271
+ 3. **Third Interview** - Skip deployment questions once more
272
+ 4. **Pattern Detected** - System recognizes consistent skip pattern (100% confidence)
273
+ 5. **Rule Generated** - Creates learned rule to auto-filter deployment questions
274
+ 6. **Next Interview** - System prompts: "I've learned you typically skip deployment questions. Apply this preference?"
275
+ 7. **Your Choice** - Approve to save time, or decline to answer deployment questions this time
276
+
277
+ ## What Gets Installed
278
+
279
+ When you run `adf init`, the following structure is created in your project:
280
+
281
+ ```
282
+ your-project/
283
+ ├── .adf/ # Framework files (isolated)
284
+ │ ├── .env # AI provider API keys (gitignored, secure)
285
+ │ ├── context.json # Your workflow configuration
286
+ │ ├── sessions/ # Requirements gathering sessions
287
+ │ ├── learning/ # Learning system data (skip history, patterns, rules)
288
+ │ ├── scripts/ # Helper scripts
289
+ │ └── shared/ # Templates, agents, and resources
290
+ │ ├── agents/ # Agent definition files
291
+ │ ├── templates/ # PRP, BMAD, Spec-Kit templates
292
+ │ ├── mcp/ # MCP configurations
293
+ │ └── memory/ # Framework memory/constitution
294
+ ├── .framework/ # Deployment directory
295
+ │ └── agents/ # Deployed agent files for your tool
296
+ ├── .env.template # Environment variables template
297
+ ├── .[tool]rules # Tool-specific config (e.g., .windsurfrules)
298
+ └── [your existing files] # Completely untouched!
299
+ ```
300
+
301
+ **Important:** Your `package.json` and existing project files remain completely untouched.
302
+
303
+ ### context.json Structure
304
+
305
+ The `.adf/context.json` file contains your workflow configuration:
306
+
307
+ ```json
308
+ {
309
+ "version": "0.1.6",
310
+ "workflow": "rapid",
311
+ "projectType": "existing",
312
+ "documentationUrls": [
313
+ "https://api.example.com/docs"
314
+ ],
315
+ "documentationFiles": [
316
+ "./docs/",
317
+ "./README.md"
318
+ ],
319
+ "createdAt": "2025-10-02T...",
320
+ "agents": ["dev", "qa"],
321
+ "templates": {
322
+ "prp": ["prp_story.md", "prp_task.md"],
323
+ "bmad": false,
324
+ "specKit": false
325
+ }
326
+ }
327
+ ```
328
+
329
+ ## Workflow Levels
330
+
331
+ ### Level 1: Rapid Development (PRP)
332
+ - **Time:** 5-15 minutes planning
333
+ - **Agents:** dev, qa
334
+ - **Best for:** Solo developers, simple projects, prototyping
335
+ - **Templates:** PRP story, PRP task
336
+
337
+ ### Level 2: Specification-Driven (Balanced)
338
+ - **Time:** 30-60 minutes planning
339
+ - **Agents:** analyst, pm, dev, qa
340
+ - **Best for:** Small teams, moderate complexity
341
+ - **Templates:** Full PRP suite, spec templates
342
+
343
+ ### Level 3: BMAD Comprehensive
344
+ - **Time:** 1-2+ hours planning
345
+ - **Agents:** analyst, pm, architect, sm, dev, qa
346
+ - **Best for:** Large teams, complex systems, strategic planning
347
+ - **Templates:** Complete BMAD framework, governance tools
348
+
349
+ ## Examples
350
+
351
+ ### Quick Start (New Project)
352
+
353
+ ```bash
354
+ # Create new project directory
355
+ mkdir my-new-project
356
+ cd my-new-project
357
+
358
+ # Initialize with Rapid workflow
359
+ adf init --rapid
360
+
361
+ # Deploy to Cursor
362
+ adf deploy cursor
363
+ ```
364
+
365
+ ### Existing Project
366
+
367
+ ```bash
368
+ # Navigate to your project
369
+ cd my-existing-project
370
+
371
+ # Initialize (interactive workflow selection)
372
+ adf init
373
+
374
+ # Follow prompts to select workflow and deployment tool
375
+ ```
376
+
377
+ ### Enterprise Setup
378
+
379
+ ```bash
380
+ # Initialize with comprehensive workflow
381
+ adf init --comprehensive
382
+
383
+ # Deploy to multiple tools
384
+ adf deploy windsurf
385
+ adf deploy vscode
386
+ ```
387
+
388
+ ## Updating Framework Files
389
+
390
+ When we release updates to the framework:
391
+
392
+ 1. **Check for updates:**
393
+ ```bash
394
+ adf update --check
395
+ ```
396
+
397
+ 2. **Install update:**
398
+ ```bash
399
+ adf update
400
+ ```
401
+
402
+ Or directly:
403
+ ```bash
404
+ npm update -g @iservu-inc/adf-cli
405
+ ```
406
+
407
+ 3. **Re-initialize your project** (optional, for major updates):
408
+ ```bash
409
+ adf init
410
+ # Confirm overwrite when prompted
411
+ ```
412
+
413
+ ## Version History
414
+
415
+ See [CHANGELOG.md](./CHANGELOG.md) for detailed version history.
416
+
417
+ **Latest:** v0.4.12
418
+ - **Learning System (Phase 4.2)** - Learns from your skip behavior to improve filtering
419
+ - Automatic pattern detection across interview sessions
420
+ - Learned rule generation from high-confidence patterns
421
+ - Adaptive filtering with user approval
422
+ - Learning management CLI via `adf config`
423
+ - Privacy-first local storage in `.adf/learning/`
424
+ - **Smart Question Filtering (Phase 4.1)** - Context-aware question filtering
425
+ - Project analysis (type, frameworks, languages)
426
+ - Intelligent question relevance scoring
427
+ - Time estimation for skipped questions
428
+ - User control with confidence thresholds
429
+ - Enhanced config command with Learning System integration
430
+
431
+ **Previous:** v0.3.6
432
+ - AI-guided requirements gathering with multi-provider support
433
+ - Real-time answer quality analysis and intelligent follow-ups
434
+ - Secure API key persistence in `.adf/.env`
435
+ - Dynamic model fetching with autocomplete selection
436
+ - Enhanced UX with visible skip instructions
437
+ - Automatic deployment to your preferred IDE
438
+
439
+ ## Troubleshooting
440
+
441
+ ### Command not found
442
+
443
+ If `adf` command is not found after installation:
444
+
445
+ 1. Check global npm bin directory is in PATH:
446
+ ```bash
447
+ npm config get prefix
448
+ ```
449
+
450
+ 2. Reinstall globally:
451
+ ```bash
452
+ npm uninstall -g @iservu-inc/adf-cli
453
+ npm install -g @iservu-inc/adf-cli
454
+ ```
455
+
456
+ ### Permission errors (Linux/macOS)
457
+
458
+ ```bash
459
+ sudo npm install -g @iservu-inc/adf-cli
460
+ ```
461
+
462
+ Or configure npm to install globally without sudo:
463
+ ```bash
464
+ npm config set prefix ~/.npm-global
465
+ # Add ~/.npm-global/bin to PATH
466
+ ```
467
+
468
+ ## Support
469
+
470
+ For issues, questions, or contributions:
471
+ - GitHub: https://github.com/iservu/adf-cli
472
+ - Issues: https://github.com/iservu/adf-cli/issues
473
+
474
+ ## License
475
+
476
+ MIT © iServU