ai-flow-dev 2.1.1 → 2.1.2

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.
@@ -59,7 +59,6 @@ Extracting structured information...
59
59
  **Extract and analyze:**
60
60
 
61
61
  1. **Business Context** (from `project-brief.md`):
62
-
63
62
  - Primary objectives
64
63
  - Target users
65
64
  - Success metrics
@@ -67,48 +66,41 @@ Extracting structured information...
67
66
  - Timeline (if specified)
68
67
 
69
68
  2. **Technical Stack** (from `ai-instructions.md`):
70
-
71
69
  - Language and version
72
70
  - Framework and version
73
71
  - Database and ORM
74
72
  - Key libraries
75
73
 
76
74
  3. **System Architecture** (from `docs/architecture.md`):
77
-
78
75
  - Architecture pattern (Clean, Hexagonal, Layered, MVC)
79
76
  - Layers/modules structure
80
77
  - Integration points
81
78
  - External services
82
79
 
83
80
  4. **Data Model** (from `docs/data-model.md`):
84
-
85
81
  - All entities/models
86
82
  - Relationships (1:1, 1:N, N:M)
87
83
  - Key fields per entity
88
84
  - Validation rules
89
85
 
90
86
  5. **API Endpoints** (from `docs/api.md`):
91
-
92
87
  - All routes
93
88
  - HTTP methods
94
89
  - Authentication requirements
95
90
  - Request/response schemas
96
91
 
97
92
  6. **Business Flows** (from `docs/business-flows.md`):
98
-
99
93
  - User journeys
100
94
  - Critical workflows
101
95
  - State transitions
102
96
 
103
97
  7. **Security Requirements** (from `specs/security.md`):
104
-
105
98
  - Authentication method
106
99
  - Authorization strategy (RBAC, ABAC, etc.)
107
100
  - Compliance requirements
108
101
  - Security features
109
102
 
110
103
  8. **Testing Strategy** (from `docs/testing.md`):
111
-
112
104
  - Unit test coverage target
113
105
  - Integration test scope
114
106
  - E2E test scenarios
@@ -1276,16 +1268,20 @@ Open roadmap.md and let's ship this! 💪
1276
1268
  ```
1277
1269
  Would you like to:
1278
1270
 
1279
- A) Start implementing first feature now (recommended)
1280
- Will execute: /feature new "{{FIRST_FEATURE_NAME}}"
1271
+ A) 📖 Continue to Phase 10: User Stories (RECOMMENDED)
1272
+ Generate detailed User Stories with acceptance criteria
1273
+ → Will execute: /flow-build fase 10
1274
+
1275
+ B) ✅ Start implementing from roadmap directly
1276
+ → Will execute: /flow-dev-feature {{FIRST_FEATURE_ID}}
1281
1277
 
1282
- B) 📋 Review roadmap first
1278
+ C) 📋 Review roadmap first
1283
1279
  → Will open roadmap.md
1284
1280
 
1285
- C) ✏️ Customize roadmap
1281
+ D) ✏️ Customize roadmap
1286
1282
  → Will open roadmap.md for editing
1287
1283
 
1288
- Your choice (A/B/C): __
1284
+ Your choice (A/B/C/D): __
1289
1285
  ```
1290
1286
 
1291
1287
  ---
@@ -1297,7 +1293,6 @@ Your choice (A/B/C): __
1297
1293
  The Story Point estimates are based on:
1298
1294
 
1299
1295
  1. **Complexity factors:**
1300
-
1301
1296
  - Number of entities involved
1302
1297
  - Business logic complexity
1303
1298
  - Integration complexity
@@ -1305,7 +1300,6 @@ The Story Point estimates are based on:
1305
1300
  - Security requirements
1306
1301
 
1307
1302
  2. **Historical data:**
1308
-
1309
1303
  - Simple CRUD: 3-5 SP
1310
1304
  - Auth systems: 13-21 SP
1311
1305
  - Payment integrations: 13-21 SP
@@ -1445,7 +1439,6 @@ Please fix documentation and re-run Phase 9
1445
1439
 
1446
1440
  ---
1447
1441
 
1448
- **CONTINUE TO:** End (Phase 9 is the final phase)
1449
-
1450
- **SUCCESS:** Complete implementation roadmap with Story Points generated! Ready to start building! 🚀
1442
+ **CONTINUE TO:** Phase 10 (User Stories) - OPTIONAL
1451
1443
 
1444
+ **SUCCESS:** Complete implementation roadmap with Story Points generated! Ready to start building or continue to Phase 10 for detailed User Stories! 🚀
@@ -36,17 +36,30 @@ Automate commit creation with:
36
36
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
37
37
  ```
38
38
 
39
+ **CRITICAL: Execute ALL detection methods in parallel to catch:**
40
+
41
+ - Modified files (unstaged/staged)
42
+ - **NEW untracked files** (not detected by get_changed_files)
43
+ - Deleted files
44
+
39
45
  **Execute these tools automatically in parallel (NO user confirmation):**
40
46
 
41
47
  ```typescript
42
- // Gather all changes
48
+ // 1. Standard Git Changes (modified/staged files)
43
49
  await Promise.all([
44
50
  get_changed_files({ sourceControlState: ['unstaged'] }),
45
51
  get_changed_files({ sourceControlState: ['staged'] }),
46
52
  get_changed_files({}), // All states
47
53
  ]);
48
54
 
49
- // Search for modified files by extension
55
+ // 2. CRITICAL: Detect untracked files (new files never added to git)
56
+ await run_in_terminal({
57
+ command: 'git status --porcelain',
58
+ explanation: 'Detect untracked files (??), modified (M), added (A), deleted (D)',
59
+ isBackground: false,
60
+ });
61
+
62
+ // 3. Search for modified files by extension (backup detection)
50
63
  await Promise.all([
51
64
  file_search({ query: '**/*.{ts,js,tsx,jsx}', maxResults: 200 }),
52
65
  file_search({ query: '**/*.{cs,fs,vb}', maxResults: 200 }),
@@ -54,7 +67,7 @@ await Promise.all([
54
67
  file_search({ query: '**/*.{md,json,yaml,yml}', maxResults: 100 }),
55
68
  ]);
56
69
 
57
- // Detect code patterns
70
+ // 4. Detect code patterns (helps with grouping)
58
71
  await Promise.all([
59
72
  grep_search({
60
73
  query: 'class|interface|type|struct|enum',
@@ -69,6 +82,41 @@ await Promise.all([
69
82
  ]);
70
83
  ```
71
84
 
85
+ **Parse `git status --porcelain` output:**
86
+
87
+ ```typescript
88
+ // Output format:
89
+ // ?? file.ts → Untracked (new file)
90
+ // M file.ts → Modified (staged)
91
+ // M file.ts → Modified (unstaged)
92
+ // A file.ts → Added (staged)
93
+ // D file.ts → Deleted (staged)
94
+ // ?? src/ → Untracked directory
95
+
96
+ // Parse logic:
97
+ const parseGitStatus = (output: string) => {
98
+ const lines = output.split('\n').filter(Boolean);
99
+ const files = {
100
+ untracked: [],
101
+ modified: [],
102
+ added: [],
103
+ deleted: [],
104
+ };
105
+
106
+ lines.forEach((line) => {
107
+ const status = line.slice(0, 2);
108
+ const filePath = line.slice(3);
109
+
110
+ if (status === '??') files.untracked.push(filePath);
111
+ else if (status.includes('M')) files.modified.push(filePath);
112
+ else if (status.includes('A')) files.added.push(filePath);
113
+ else if (status.includes('D')) files.deleted.push(filePath);
114
+ });
115
+
116
+ return files;
117
+ };
118
+ ```
119
+
72
120
  **If NO changes detected:**
73
121
 
74
122
  ```
@@ -84,16 +132,26 @@ Working directory is clean.
84
132
  ```
85
133
  ✅ Changes detected:
86
134
 
87
- Unstaged: [N] files
88
- Staged: [N] files
135
+ Untracked: [N] files (new files never added to git)
136
+ Unstaged: [N] files (modified files not staged)
137
+ Staged: [N] files (files ready to commit)
138
+ Deleted: [N] files
89
139
 
90
140
  File types:
91
141
  - Source code: [N] files
92
142
  - Tests: [N] files
93
143
  - Documentation: [N] files
94
144
  - Configuration: [N] files
145
+
146
+ Examples:
147
+ ?? .gitignore (untracked)
148
+ ?? src/ (untracked directory)
149
+ M README.md (modified, unstaged)
150
+ A package.json (added, staged)
95
151
  ```
96
152
 
153
+ **IMPORTANT:** Untracked files (`??`) are NEW files that must be detected with `git status --porcelain` because `get_changed_files()` does NOT see them.
154
+
97
155
  ---
98
156
 
99
157
  ### Step 2: Intelligent Grouping (Automatic)
@@ -503,12 +561,14 @@ Click "Allow" to execute →
503
561
 
504
562
  Error: [error message]
505
563
 
506
- Suggestions:
507
- - Run: git pull origin [branch] --rebase
508
- - Resolve conflicts if any
509
- - Run: /flow-dev-commit again to retry
510
- ```
564
+ | Step | Actions | User Interaction |
565
+ | ------ | -------------------------------------------------------------------------- | ---------------------- |
566
+ | Step 1 | `get_changed_files()`, `git status --porcelain`, `file_search()`, `grep_search()` | Automatic (read-only) |
567
+ | Step 2 | Analyze and group files | Automatic |
568
+ | Step 3 | `git add` + `git commit` (per group) | Click Allow per commit |
569
+ | Step 4 | `git log` (automatic) + `git push` (manual) | Auto log / Allow push |
511
570
 
571
+ **CRITICAL:** Always run `git status --porcelain` in Step 1 to detect untracked files (`??`) that `get_changed_files()` cannot see.
512
572
  ---
513
573
 
514
574
  ## 🎯 Execution Model
@@ -553,6 +613,7 @@ Universal patterns that work across languages/frameworks:
553
613
  **Changes detected:**
554
614
 
555
615
  ```
616
+
556
617
  src/modules/products/entities/product.entity.ts
557
618
  src/modules/products/dto/create-product.dto.ts
558
619
  src/modules/products/dto/update-product.dto.ts
@@ -560,16 +621,17 @@ src/modules/products/dto/product-response.dto.ts
560
621
  src/modules/products/products.service.ts
561
622
  src/modules/products/products.controller.ts
562
623
  src/modules/products/products.module.ts
563
- src/modules/products/__tests__/products.service.spec.ts
564
- src/modules/products/__tests__/products.controller.spec.ts
624
+ src/modules/products/**tests**/products.service.spec.ts
625
+ src/modules/products/**tests**/products.controller.spec.ts
565
626
  docs/api.md (products section)
566
- ```
627
+
628
+ ````
567
629
 
568
630
  **Commits generated (1 commit):**
569
631
 
570
632
  ```bash
571
633
  git add src/modules/products/entities/product.entity.ts src/modules/products/dto/create-product.dto.ts src/modules/products/dto/update-product.dto.ts src/modules/products/dto/product-response.dto.ts src/modules/products/products.service.ts src/modules/products/products.controller.ts src/modules/products/products.module.ts src/modules/products/__tests__/products.service.spec.ts src/modules/products/__tests__/products.controller.spec.ts docs/api.md && git commit -m "feat(products): implement product management with CRUD operations"
572
- ```
634
+ ````
573
635
 
574
636
  ### Example 2: Refactoring Across Modules
575
637