ai-flow-dev 2.6.0 → 2.7.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.
Files changed (161) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +570 -570
  3. package/package.json +73 -73
  4. package/prompts/backend/flow-build-phase-0.md +535 -535
  5. package/prompts/backend/flow-build-phase-1.md +626 -626
  6. package/prompts/backend/flow-build-phase-10.md +340 -340
  7. package/prompts/backend/flow-build-phase-2.md +573 -573
  8. package/prompts/backend/flow-build-phase-3.md +834 -834
  9. package/prompts/backend/flow-build-phase-4.md +554 -554
  10. package/prompts/backend/flow-build-phase-5.md +703 -703
  11. package/prompts/backend/flow-build-phase-6.md +524 -524
  12. package/prompts/backend/flow-build-phase-7.md +1001 -1001
  13. package/prompts/backend/flow-build-phase-8.md +1407 -1407
  14. package/prompts/backend/flow-build-phase-9.md +477 -477
  15. package/prompts/backend/flow-build.md +137 -137
  16. package/prompts/backend/flow-check-review.md +20 -20
  17. package/prompts/backend/flow-check-test.md +14 -14
  18. package/prompts/backend/flow-check.md +67 -67
  19. package/prompts/backend/flow-commit.md +119 -119
  20. package/prompts/backend/flow-docs-sync.md +354 -354
  21. package/prompts/backend/flow-work-feature.md +61 -61
  22. package/prompts/backend/flow-work-fix.md +46 -46
  23. package/prompts/backend/flow-work-refactor.md +48 -48
  24. package/prompts/backend/flow-work-resume.md +34 -34
  25. package/prompts/backend/flow-work.md +1286 -1023
  26. package/prompts/desktop/flow-build-phase-0.md +359 -359
  27. package/prompts/desktop/flow-build-phase-1.md +295 -295
  28. package/prompts/desktop/flow-build-phase-10.md +357 -357
  29. package/prompts/desktop/flow-build-phase-2.md +282 -282
  30. package/prompts/desktop/flow-build-phase-3.md +291 -291
  31. package/prompts/desktop/flow-build-phase-4.md +308 -308
  32. package/prompts/desktop/flow-build-phase-5.md +269 -269
  33. package/prompts/desktop/flow-build-phase-6.md +350 -350
  34. package/prompts/desktop/flow-build-phase-7.md +297 -297
  35. package/prompts/desktop/flow-build-phase-8.md +541 -541
  36. package/prompts/desktop/flow-build-phase-9.md +439 -439
  37. package/prompts/desktop/flow-build.md +156 -156
  38. package/prompts/desktop/flow-check-review.md +20 -20
  39. package/prompts/desktop/flow-check-test.md +14 -14
  40. package/prompts/desktop/flow-check.md +67 -67
  41. package/prompts/desktop/flow-commit.md +119 -119
  42. package/prompts/desktop/flow-docs-sync.md +354 -354
  43. package/prompts/desktop/flow-work-feature.md +61 -61
  44. package/prompts/desktop/flow-work-fix.md +46 -46
  45. package/prompts/desktop/flow-work-refactor.md +48 -48
  46. package/prompts/desktop/flow-work-resume.md +34 -34
  47. package/prompts/desktop/flow-work.md +1390 -1023
  48. package/prompts/frontend/flow-build-phase-0.md +425 -425
  49. package/prompts/frontend/flow-build-phase-1.md +626 -626
  50. package/prompts/frontend/flow-build-phase-10.md +33 -33
  51. package/prompts/frontend/flow-build-phase-2.md +573 -573
  52. package/prompts/frontend/flow-build-phase-3.md +782 -782
  53. package/prompts/frontend/flow-build-phase-4.md +554 -554
  54. package/prompts/frontend/flow-build-phase-5.md +703 -703
  55. package/prompts/frontend/flow-build-phase-6.md +524 -524
  56. package/prompts/frontend/flow-build-phase-7.md +1001 -1001
  57. package/prompts/frontend/flow-build-phase-8.md +872 -872
  58. package/prompts/frontend/flow-build-phase-9.md +94 -94
  59. package/prompts/frontend/flow-build.md +137 -137
  60. package/prompts/frontend/flow-check-review.md +20 -20
  61. package/prompts/frontend/flow-check-test.md +14 -14
  62. package/prompts/frontend/flow-check.md +67 -67
  63. package/prompts/frontend/flow-commit.md +119 -119
  64. package/prompts/frontend/flow-docs-sync.md +550 -550
  65. package/prompts/frontend/flow-work-feature.md +61 -61
  66. package/prompts/frontend/flow-work-fix.md +38 -38
  67. package/prompts/frontend/flow-work-refactor.md +48 -48
  68. package/prompts/frontend/flow-work-resume.md +34 -34
  69. package/prompts/frontend/flow-work.md +1320 -1027
  70. package/prompts/mobile/flow-build-phase-0.md +425 -425
  71. package/prompts/mobile/flow-build-phase-1.md +626 -626
  72. package/prompts/mobile/flow-build-phase-10.md +32 -32
  73. package/prompts/mobile/flow-build-phase-2.md +573 -573
  74. package/prompts/mobile/flow-build-phase-3.md +782 -782
  75. package/prompts/mobile/flow-build-phase-4.md +554 -554
  76. package/prompts/mobile/flow-build-phase-5.md +703 -703
  77. package/prompts/mobile/flow-build-phase-6.md +524 -524
  78. package/prompts/mobile/flow-build-phase-7.md +1001 -1001
  79. package/prompts/mobile/flow-build-phase-8.md +888 -888
  80. package/prompts/mobile/flow-build-phase-9.md +90 -90
  81. package/prompts/mobile/flow-build.md +135 -135
  82. package/prompts/mobile/flow-check-review.md +20 -20
  83. package/prompts/mobile/flow-check-test.md +14 -14
  84. package/prompts/mobile/flow-check.md +67 -67
  85. package/prompts/mobile/flow-commit.md +119 -119
  86. package/prompts/mobile/flow-docs-sync.md +620 -620
  87. package/prompts/mobile/flow-work-feature.md +61 -61
  88. package/prompts/mobile/flow-work-fix.md +46 -46
  89. package/prompts/mobile/flow-work-refactor.md +48 -48
  90. package/prompts/mobile/flow-work-resume.md +34 -34
  91. package/prompts/mobile/flow-work.md +1329 -1023
  92. package/prompts/shared/mermaid-guidelines.md +102 -102
  93. package/prompts/shared/scope-levels.md +114 -114
  94. package/prompts/shared/smart-skip-preflight.md +214 -214
  95. package/prompts/shared/story-points.md +55 -55
  96. package/prompts/shared/task-format.md +74 -74
  97. package/prompts/shared/task-summary-template.md +277 -277
  98. package/templates/AGENT.template.md +443 -443
  99. package/templates/backend/.clauderules.template +112 -112
  100. package/templates/backend/.cursorrules.template +102 -102
  101. package/templates/backend/README.template.md +2 -2
  102. package/templates/backend/ai-instructions.template.md +2 -2
  103. package/templates/backend/copilot-instructions.template.md +2 -2
  104. package/templates/backend/docs/api.template.md +320 -320
  105. package/templates/backend/docs/business-flows.template.md +97 -97
  106. package/templates/backend/docs/code-standards.template.md +2 -2
  107. package/templates/backend/docs/contributing.template.md +3 -3
  108. package/templates/backend/docs/data-model.template.md +520 -520
  109. package/templates/backend/docs/testing.template.md +2 -2
  110. package/templates/backend/project-brief.template.md +2 -2
  111. package/templates/backend/specs/configuration.template.md +2 -2
  112. package/templates/backend/specs/security.template.md +2 -2
  113. package/templates/desktop/.clauderules.template +112 -112
  114. package/templates/desktop/.cursorrules.template +102 -102
  115. package/templates/desktop/README.template.md +170 -170
  116. package/templates/desktop/ai-instructions.template.md +366 -366
  117. package/templates/desktop/copilot-instructions.template.md +140 -140
  118. package/templates/desktop/docs/docs/api.template.md +320 -320
  119. package/templates/desktop/docs/docs/architecture.template.md +724 -724
  120. package/templates/desktop/docs/docs/business-flows.template.md +102 -102
  121. package/templates/desktop/docs/docs/code-standards.template.md +792 -792
  122. package/templates/desktop/docs/docs/contributing.template.md +149 -149
  123. package/templates/desktop/docs/docs/data-model.template.md +520 -520
  124. package/templates/desktop/docs/docs/operations.template.md +720 -720
  125. package/templates/desktop/docs/docs/testing.template.md +722 -722
  126. package/templates/desktop/project-brief.template.md +150 -150
  127. package/templates/desktop/specs/specs/configuration.template.md +121 -121
  128. package/templates/desktop/specs/specs/security.template.md +392 -392
  129. package/templates/frontend/README.template.md +2 -2
  130. package/templates/frontend/ai-instructions.template.md +2 -2
  131. package/templates/frontend/docs/api-integration.template.md +362 -362
  132. package/templates/frontend/docs/components.template.md +2 -2
  133. package/templates/frontend/docs/error-handling.template.md +360 -360
  134. package/templates/frontend/docs/operations.template.md +107 -107
  135. package/templates/frontend/docs/performance.template.md +124 -124
  136. package/templates/frontend/docs/pwa.template.md +119 -119
  137. package/templates/frontend/docs/state-management.template.md +2 -2
  138. package/templates/frontend/docs/styling.template.md +2 -2
  139. package/templates/frontend/docs/testing.template.md +2 -2
  140. package/templates/frontend/project-brief.template.md +2 -2
  141. package/templates/frontend/specs/accessibility.template.md +95 -95
  142. package/templates/frontend/specs/configuration.template.md +2 -2
  143. package/templates/frontend/specs/security.template.md +175 -175
  144. package/templates/fullstack/README.template.md +252 -252
  145. package/templates/fullstack/ai-instructions.template.md +444 -444
  146. package/templates/fullstack/project-brief.template.md +157 -157
  147. package/templates/fullstack/specs/configuration.template.md +340 -340
  148. package/templates/mobile/README.template.md +167 -167
  149. package/templates/mobile/ai-instructions.template.md +196 -196
  150. package/templates/mobile/docs/app-store.template.md +135 -135
  151. package/templates/mobile/docs/architecture.template.md +63 -63
  152. package/templates/mobile/docs/native-features.template.md +94 -94
  153. package/templates/mobile/docs/navigation.template.md +59 -59
  154. package/templates/mobile/docs/offline-strategy.template.md +65 -65
  155. package/templates/mobile/docs/permissions.template.md +56 -56
  156. package/templates/mobile/docs/state-management.template.md +85 -85
  157. package/templates/mobile/docs/testing.template.md +109 -109
  158. package/templates/mobile/project-brief.template.md +69 -69
  159. package/templates/mobile/specs/build-configuration.template.md +91 -91
  160. package/templates/mobile/specs/deployment.template.md +92 -92
  161. package/templates/work.template.md +47 -47
@@ -1,357 +1,357 @@
1
- ## PHASE 10: User Stories Generation (5-10 min)
2
-
3
- > **Order for this phase:** OPTIONAL. Executed after Phase 9 or on demand.
4
-
5
- ### Objective
6
-
7
- Generate comprehensive User Stories from the Implementation Roadmap, mapping features to user needs.
8
-
9
- ---
10
-
11
- ## User Story Format
12
-
13
- ```
14
- # HU-XXX-XXX: [User Story Title]
15
-
16
- **Epic:** EP-XXX - [Epic Name]
17
- **Priority:** P0 / P1 / P2 / P3
18
- **Story Points:** X SP
19
- **Status:** Not Started
20
-
21
- ---
22
-
23
- ## User Story
24
-
25
- **As a** [user type],
26
- **I want** [goal/desire],
27
- **So that** [benefit/value].
28
-
29
- ---
30
-
31
- ## Acceptance Criteria
32
-
33
- - [ ] Given [context], when [action], then [expected result]
34
- - [ ] Given [context], when [action], then [expected result]
35
- - [ ] Given [context], when [action], then [expected result]
36
-
37
- ---
38
-
39
- ## Technical Tasks
40
-
41
- From planning/roadmap.md:
42
-
43
- - [ ] TXXX [CAT] Description • 1 SP → {{path}} | deps: TXXX
44
- - [ ] TXXX [CAT] Description • 1 SP → {{path}} | deps: TXXX
45
-
46
- ---
47
-
48
- ## Definition of Done
49
-
50
- - [ ] All technical tasks completed
51
- - [ ] All acceptance criteria met
52
- - [ ] Unit tests passing
53
- - [ ] UI tests passing (if applicable)
54
- - [ ] Code reviewed
55
- - [ ] Documentation updated
56
-
57
- ---
58
-
59
- ## Notes
60
-
61
- [Additional context, dependencies, or considerations]
62
-
63
- ---
64
-
65
- **Created:** 2025-02-03
66
- **Updated:** 2025-02-03
67
- ```
68
-
69
- ---
70
-
71
- ## Workflow: 4 Steps
72
-
73
- ### Step 10.1: Extract Epics and Features
74
-
75
- **Read planning/roadmap.md and extract:**
76
-
77
- ```
78
- EPICS FOUND:
79
- ├── EP-001: Foundation (15 SP)
80
- ├── EP-002: Data Layer (25 SP)
81
- ├── EP-003: Business Logic (20 SP)
82
- ├── EP-004: UI Foundation (20 SP)
83
- ├── EP-005: UI Components (30 SP)
84
- ├── EP-006: Controllers (25 SP)
85
- ├── EP-007: Features (35 SP)
86
- └── EP-008: Packaging (10 SP)
87
-
88
- FEATURES EXTRACTED (from project-brief.md + docs):
89
- ├── User Authentication
90
- ├── Project Management
91
- ├── Task Management
92
- ├── File Operations
93
- ├── Search & Filter
94
- ├── Reports & Export
95
- └── Settings & Preferences
96
- ```
97
-
98
- ---
99
-
100
- ### Step 10.2: Map Features to User Stories
101
-
102
- **Generate User Story for each feature:**
103
-
104
- **Example: User Authentication**
105
-
106
- ```markdown
107
- # HU-001-001: User Login
108
-
109
- **Epic:** EP-001 - Foundation
110
- **Priority:** P0
111
- **Story Points:** 8 SP
112
- **Status:** Not Started
113
-
114
- ---
115
-
116
- ## User Story
117
-
118
- **As a** registered user,
119
- **I want** to log into the application with my credentials,
120
- **So that** I can access my personalized data and settings.
121
-
122
- ---
123
-
124
- ## Acceptance Criteria
125
-
126
- - [ ] Given I am on the login screen, when I enter valid credentials, then I am redirected to the main window
127
- - [ ] Given I am on the login screen, when I enter invalid credentials, then I see an error message "Invalid username or password"
128
- - [ ] Given I am on the login screen, when I leave fields empty, then the Login button is disabled
129
- - [ ] Given I am logged in, when I close the application, then my session is saved (if "Remember me" is checked)
130
- - [ ] Given I exceed 5 failed login attempts, when I try again, then my account is locked for 15 minutes
131
-
132
- ---
133
-
134
- ## Technical Tasks
135
-
136
- From planning/roadmap.md:
137
-
138
- - [ ] T025 [M] Create User entity (id, username, password, email) • 1 SP → {{SRC}}/{{MODEL_DIR}}/User{{EXT}} | deps: T012
139
- - [ ] T026 [D] Create UserDAO interface • 1 SP → {{SRC}}/{{DAO_DIR}}/UserDAO{{EXT}} | deps: T025
140
- - [ ] T027 [D] Implement UserDAO.findByUsername() • 1 SP → {{SRC}}/{{DAO_DIR}}/UserDAOImpl{{EXT}} | deps: T026
141
- - [ ] T028 [S] Create AuthService • 1 SP → {{SRC}}/{{SERVICE_DIR}}/AuthService{{EXT}} | deps: T027
142
- - [ ] T029 [S] Implement AuthService.login(username, password) • 2 SP → {{SRC}}/{{SERVICE_DIR}}/AuthService{{EXT}} | deps: T028
143
- - [ ] T030 [V] Create LoginDialog UI • 2 SP → {{SRC}}/{{VIEW_DIR}}/LoginDialog{{EXT}} | deps: none
144
- - [ ] T031 [C] Create LoginController • 1 SP → {{SRC}}/{{CONTROLLER_DIR}}/LoginController{{EXT}} | deps: T029,T030
145
-
146
- ---
147
-
148
- ## Definition of Done
149
-
150
- - [ ] All technical tasks completed (T025-T031)
151
- - [ ] All acceptance criteria met
152
- - [ ] Unit tests for AuthService passing
153
- - [ ] UI tests for LoginDialog passing
154
- - [ ] Code reviewed and merged
155
- - [ ] Documentation updated (docs/FEATURES.md)
156
-
157
- ---
158
-
159
- ## Notes
160
-
161
- - Password must be hashed (BCrypt) before storing
162
- - Session token stored securely (Preferences API or Keychain)
163
- - Lock mechanism uses timestamp in database
164
- - "Remember me" stores encrypted token
165
-
166
- ---
167
-
168
- **Created:** 2025-02-03
169
- **Updated:** 2025-02-03
170
- ```
171
-
172
- ---
173
-
174
- ### Step 10.3: Generate Remaining User Stories
175
-
176
- **Generate User Stories for all features:**
177
-
178
- ```
179
- USER STORIES TO GENERATE:
180
-
181
- EP-001: Foundation
182
- ├── HU-001-001: User Login (P0, 8 SP)
183
- └── HU-001-002: User Registration (P0, 8 SP)
184
-
185
- EP-002: Data Layer
186
- ├── HU-002-001: Persist User Data (P0, 5 SP)
187
- ├── HU-002-002: Persist Project Data (P0, 5 SP)
188
- └── HU-002-003: Persist Task Data (P0, 5 SP)
189
-
190
- EP-003: Business Logic
191
- ├── HU-003-001: Validate User Input (P0, 3 SP)
192
- ├── HU-003-002: Calculate Project Progress (P1, 5 SP)
193
- └── HU-003-003: Manage Task Status (P1, 5 SP)
194
-
195
- EP-004: UI Foundation
196
- ├── HU-004-001: Navigate Main Window (P0, 8 SP)
197
- ├── HU-004-002: Access Menu Bar (P0, 5 SP)
198
- └── HU-004-003: Use Toolbar (P1, 3 SP)
199
-
200
- EP-005: UI Components
201
- ├── HU-005-001: Create New Project (P0, 8 SP)
202
- ├── HU-005-002: Edit Project Details (P1, 5 SP)
203
- ├── HU-005-003: Delete Project (P1, 3 SP)
204
- ├── HU-005-004: Create New Task (P0, 8 SP)
205
- ├── HU-005-005: Edit Task Details (P1, 5 SP)
206
- └── HU-005-006: Delete Task (P1, 3 SP)
207
-
208
- EP-006: Controllers
209
- ├── HU-006-001: Handle Button Clicks (P0, 3 SP)
210
- ├── HU-006-002: Handle Keyboard Shortcuts (P1, 5 SP)
211
- └── HU-006-003: Handle Drag & Drop (P1, 5 SP)
212
-
213
- EP-007: Features
214
- ├── HU-007-001: Search Projects (P1, 8 SP)
215
- ├── HU-007-002: Filter Tasks (P1, 5 SP)
216
- ├── HU-007-003: Export to PDF (P1, 8 SP)
217
- ├── HU-007-004: Import from CSV (P2, 8 SP)
218
- └── HU-007-005: Generate Reports (P1, 8 SP)
219
-
220
- EP-008: Packaging
221
- ├── HU-008-001: Install Application (P0, 3 SP)
222
- └── HU-008-002: Auto-Update Application (P2, 8 SP)
223
-
224
- TOTAL: 30 User Stories
225
- ```
226
-
227
- ---
228
-
229
- ### Step 10.4: Generate planning/user-stories/ structure
230
-
231
- **Create directory structure:**
232
-
233
- ```
234
- planning/
235
- ├── roadmap.md (already exists from Phase 9)
236
- └── user-stories/
237
- ├── EP-001-Foundation/
238
- │ ├── HU-001-001.md (User Login)
239
- │ └── HU-001-002.md (User Registration)
240
- ├── EP-002-Data-Layer/
241
- │ ├── HU-002-001.md (Persist User Data)
242
- │ ├── HU-002-002.md (Persist Project Data)
243
- │ └── HU-002-003.md (Persist Task Data)
244
- ├── EP-003-Business-Logic/
245
- │ ├── HU-003-001.md
246
- │ ├── HU-003-002.md
247
- │ └── HU-003-003.md
248
- ├── EP-004-UI-Foundation/
249
- │ ├── HU-004-001.md
250
- │ ├── HU-004-002.md
251
- │ └── HU-004-003.md
252
- ├── EP-005-UI-Components/
253
- │ ├── HU-005-001.md
254
- │ ├── HU-005-002.md
255
- │ ├── HU-005-003.md
256
- │ ├── HU-005-004.md
257
- │ ├── HU-005-005.md
258
- │ └── HU-005-006.md
259
- ├── EP-006-Controllers/
260
- │ ├── HU-006-001.md
261
- │ ├── HU-006-002.md
262
- │ └── HU-006-003.md
263
- ├── EP-007-Features/
264
- │ ├── HU-007-001.md
265
- │ ├── HU-007-002.md
266
- │ ├── HU-007-003.md
267
- │ ├── HU-007-004.md
268
- │ └── HU-007-005.md
269
- └── EP-008-Packaging/
270
- ├── HU-008-001.md
271
- └── HU-008-002.md
272
- ```
273
-
274
- ---
275
-
276
- ### Phase 10 Output
277
-
278
- ```
279
- ✅ User Stories generated!
280
-
281
- Created: planning/user-stories/
282
-
283
- Summary:
284
- - 30 User Stories created
285
- - 8 Epic directories
286
- - All stories linked to roadmap tasks
287
- - Acceptance criteria defined
288
- - Definition of Done included
289
-
290
- File structure:
291
- planning/
292
- ├── roadmap.md (180 tasks)
293
- └── user-stories/
294
- ├── EP-001-Foundation/ (2 stories, 16 SP)
295
- ├── EP-002-Data-Layer/ (3 stories, 15 SP)
296
- ├── EP-003-Business-Logic/ (3 stories, 13 SP)
297
- ├── EP-004-UI-Foundation/ (3 stories, 16 SP)
298
- ├── EP-005-UI-Components/ (6 stories, 32 SP)
299
- ├── EP-006-Controllers/ (3 stories, 13 SP)
300
- ├── EP-007-Features/ (5 stories, 37 SP)
301
- └── EP-008-Packaging/ (2 stories, 11 SP)
302
-
303
- Next steps:
304
- 1. Review planning/user-stories/
305
- 2. Start implementation with /flow-work HU-001-001
306
- 3. Or continue by Epic: /flow-work EP-001
307
-
308
- Documentation complete! 🎉
309
- ```
310
-
311
- ---
312
-
313
- ## Final Summary
314
-
315
- ```
316
- 🎉 ALL PHASES COMPLETE!
317
-
318
- You now have:
319
- ✅ Phase 0: Project Discovery (existing projects)
320
- ✅ Phase 1: Desktop UX & Requirements
321
- ✅ Phase 2: UI Components (Swing/JavaFX/SWT)
322
- ✅ Phase 3: Architecture (MVC/MVP/MVVM)
323
- ✅ Phase 4: Data & Storage
324
- ✅ Phase 5: Code Standards
325
- ✅ Phase 6: Testing Strategy
326
- ✅ Phase 7: Packaging & Deployment
327
- ✅ Phase 8: Project Setup & Docs
328
- ✅ Phase 9: Implementation Roadmap (180 tasks)
329
- ✅ Phase 10: User Stories (30 stories)
330
-
331
- Generated files:
332
- 📄 project-brief.md
333
- 📄 docs/ARCHITECTURE.md
334
- 📄 docs/DATABASE.md
335
- 📄 docs/DEVELOPMENT.md
336
- 📄 docs/DEPLOYMENT.md
337
- 📄 planning/roadmap.md
338
- 📁 planning/user-stories/ (30 files)
339
- 📄 README.md
340
- 📄 .gitignore
341
-
342
- Ready to start development!
343
-
344
- Commands:
345
- - /flow-work HU-001-001 → Implement User Login
346
- - /flow-work EP-001 → Implement Foundation Epic
347
- - /flow-work T001 → Implement specific task
348
- - /flow-check → Review code quality
349
- - /flow-commit → Commit changes
350
-
351
- Happy coding! 🚀
352
- ```
353
-
354
- ---
355
-
356
- **Last Updated:** 2025-02-03
357
- **Version:** 1.0.0
1
+ ## PHASE 10: User Stories Generation (5-10 min)
2
+
3
+ > **Order for this phase:** OPTIONAL. Executed after Phase 9 or on demand.
4
+
5
+ ### Objective
6
+
7
+ Generate comprehensive User Stories from the Implementation Roadmap, mapping features to user needs.
8
+
9
+ ---
10
+
11
+ ## User Story Format
12
+
13
+ ```
14
+ # HU-XXX-XXX: [User Story Title]
15
+
16
+ **Epic:** EP-XXX - [Epic Name]
17
+ **Priority:** P0 / P1 / P2 / P3
18
+ **Story Points:** X SP
19
+ **Status:** Not Started
20
+
21
+ ---
22
+
23
+ ## User Story
24
+
25
+ **As a** [user type],
26
+ **I want** [goal/desire],
27
+ **So that** [benefit/value].
28
+
29
+ ---
30
+
31
+ ## Acceptance Criteria
32
+
33
+ - [ ] Given [context], when [action], then [expected result]
34
+ - [ ] Given [context], when [action], then [expected result]
35
+ - [ ] Given [context], when [action], then [expected result]
36
+
37
+ ---
38
+
39
+ ## Technical Tasks
40
+
41
+ From planning/roadmap.md:
42
+
43
+ - [ ] TXXX [CAT] Description • 1 SP → {{path}} | deps: TXXX
44
+ - [ ] TXXX [CAT] Description • 1 SP → {{path}} | deps: TXXX
45
+
46
+ ---
47
+
48
+ ## Definition of Done
49
+
50
+ - [ ] All technical tasks completed
51
+ - [ ] All acceptance criteria met
52
+ - [ ] Unit tests passing
53
+ - [ ] UI tests passing (if applicable)
54
+ - [ ] Code reviewed
55
+ - [ ] Documentation updated
56
+
57
+ ---
58
+
59
+ ## Notes
60
+
61
+ [Additional context, dependencies, or considerations]
62
+
63
+ ---
64
+
65
+ **Created:** 2025-02-03
66
+ **Updated:** 2025-02-03
67
+ ```
68
+
69
+ ---
70
+
71
+ ## Workflow: 4 Steps
72
+
73
+ ### Step 10.1: Extract Epics and Features
74
+
75
+ **Read planning/roadmap.md and extract:**
76
+
77
+ ```
78
+ EPICS FOUND:
79
+ ├── EP-001: Foundation (15 SP)
80
+ ├── EP-002: Data Layer (25 SP)
81
+ ├── EP-003: Business Logic (20 SP)
82
+ ├── EP-004: UI Foundation (20 SP)
83
+ ├── EP-005: UI Components (30 SP)
84
+ ├── EP-006: Controllers (25 SP)
85
+ ├── EP-007: Features (35 SP)
86
+ └── EP-008: Packaging (10 SP)
87
+
88
+ FEATURES EXTRACTED (from project-brief.md + docs):
89
+ ├── User Authentication
90
+ ├── Project Management
91
+ ├── Task Management
92
+ ├── File Operations
93
+ ├── Search & Filter
94
+ ├── Reports & Export
95
+ └── Settings & Preferences
96
+ ```
97
+
98
+ ---
99
+
100
+ ### Step 10.2: Map Features to User Stories
101
+
102
+ **Generate User Story for each feature:**
103
+
104
+ **Example: User Authentication**
105
+
106
+ ```markdown
107
+ # HU-001-001: User Login
108
+
109
+ **Epic:** EP-001 - Foundation
110
+ **Priority:** P0
111
+ **Story Points:** 8 SP
112
+ **Status:** Not Started
113
+
114
+ ---
115
+
116
+ ## User Story
117
+
118
+ **As a** registered user,
119
+ **I want** to log into the application with my credentials,
120
+ **So that** I can access my personalized data and settings.
121
+
122
+ ---
123
+
124
+ ## Acceptance Criteria
125
+
126
+ - [ ] Given I am on the login screen, when I enter valid credentials, then I am redirected to the main window
127
+ - [ ] Given I am on the login screen, when I enter invalid credentials, then I see an error message "Invalid username or password"
128
+ - [ ] Given I am on the login screen, when I leave fields empty, then the Login button is disabled
129
+ - [ ] Given I am logged in, when I close the application, then my session is saved (if "Remember me" is checked)
130
+ - [ ] Given I exceed 5 failed login attempts, when I try again, then my account is locked for 15 minutes
131
+
132
+ ---
133
+
134
+ ## Technical Tasks
135
+
136
+ From planning/roadmap.md:
137
+
138
+ - [ ] T025 [M] Create User entity (id, username, password, email) • 1 SP → {{SRC}}/{{MODEL_DIR}}/User{{EXT}} | deps: T012
139
+ - [ ] T026 [D] Create UserDAO interface • 1 SP → {{SRC}}/{{DAO_DIR}}/UserDAO{{EXT}} | deps: T025
140
+ - [ ] T027 [D] Implement UserDAO.findByUsername() • 1 SP → {{SRC}}/{{DAO_DIR}}/UserDAOImpl{{EXT}} | deps: T026
141
+ - [ ] T028 [S] Create AuthService • 1 SP → {{SRC}}/{{SERVICE_DIR}}/AuthService{{EXT}} | deps: T027
142
+ - [ ] T029 [S] Implement AuthService.login(username, password) • 2 SP → {{SRC}}/{{SERVICE_DIR}}/AuthService{{EXT}} | deps: T028
143
+ - [ ] T030 [V] Create LoginDialog UI • 2 SP → {{SRC}}/{{VIEW_DIR}}/LoginDialog{{EXT}} | deps: none
144
+ - [ ] T031 [C] Create LoginController • 1 SP → {{SRC}}/{{CONTROLLER_DIR}}/LoginController{{EXT}} | deps: T029,T030
145
+
146
+ ---
147
+
148
+ ## Definition of Done
149
+
150
+ - [ ] All technical tasks completed (T025-T031)
151
+ - [ ] All acceptance criteria met
152
+ - [ ] Unit tests for AuthService passing
153
+ - [ ] UI tests for LoginDialog passing
154
+ - [ ] Code reviewed and merged
155
+ - [ ] Documentation updated (docs/FEATURES.md)
156
+
157
+ ---
158
+
159
+ ## Notes
160
+
161
+ - Password must be hashed (BCrypt) before storing
162
+ - Session token stored securely (Preferences API or Keychain)
163
+ - Lock mechanism uses timestamp in database
164
+ - "Remember me" stores encrypted token
165
+
166
+ ---
167
+
168
+ **Created:** 2025-02-03
169
+ **Updated:** 2025-02-03
170
+ ```
171
+
172
+ ---
173
+
174
+ ### Step 10.3: Generate Remaining User Stories
175
+
176
+ **Generate User Stories for all features:**
177
+
178
+ ```
179
+ USER STORIES TO GENERATE:
180
+
181
+ EP-001: Foundation
182
+ ├── HU-001-001: User Login (P0, 8 SP)
183
+ └── HU-001-002: User Registration (P0, 8 SP)
184
+
185
+ EP-002: Data Layer
186
+ ├── HU-002-001: Persist User Data (P0, 5 SP)
187
+ ├── HU-002-002: Persist Project Data (P0, 5 SP)
188
+ └── HU-002-003: Persist Task Data (P0, 5 SP)
189
+
190
+ EP-003: Business Logic
191
+ ├── HU-003-001: Validate User Input (P0, 3 SP)
192
+ ├── HU-003-002: Calculate Project Progress (P1, 5 SP)
193
+ └── HU-003-003: Manage Task Status (P1, 5 SP)
194
+
195
+ EP-004: UI Foundation
196
+ ├── HU-004-001: Navigate Main Window (P0, 8 SP)
197
+ ├── HU-004-002: Access Menu Bar (P0, 5 SP)
198
+ └── HU-004-003: Use Toolbar (P1, 3 SP)
199
+
200
+ EP-005: UI Components
201
+ ├── HU-005-001: Create New Project (P0, 8 SP)
202
+ ├── HU-005-002: Edit Project Details (P1, 5 SP)
203
+ ├── HU-005-003: Delete Project (P1, 3 SP)
204
+ ├── HU-005-004: Create New Task (P0, 8 SP)
205
+ ├── HU-005-005: Edit Task Details (P1, 5 SP)
206
+ └── HU-005-006: Delete Task (P1, 3 SP)
207
+
208
+ EP-006: Controllers
209
+ ├── HU-006-001: Handle Button Clicks (P0, 3 SP)
210
+ ├── HU-006-002: Handle Keyboard Shortcuts (P1, 5 SP)
211
+ └── HU-006-003: Handle Drag & Drop (P1, 5 SP)
212
+
213
+ EP-007: Features
214
+ ├── HU-007-001: Search Projects (P1, 8 SP)
215
+ ├── HU-007-002: Filter Tasks (P1, 5 SP)
216
+ ├── HU-007-003: Export to PDF (P1, 8 SP)
217
+ ├── HU-007-004: Import from CSV (P2, 8 SP)
218
+ └── HU-007-005: Generate Reports (P1, 8 SP)
219
+
220
+ EP-008: Packaging
221
+ ├── HU-008-001: Install Application (P0, 3 SP)
222
+ └── HU-008-002: Auto-Update Application (P2, 8 SP)
223
+
224
+ TOTAL: 30 User Stories
225
+ ```
226
+
227
+ ---
228
+
229
+ ### Step 10.4: Generate planning/user-stories/ structure
230
+
231
+ **Create directory structure:**
232
+
233
+ ```
234
+ planning/
235
+ ├── roadmap.md (already exists from Phase 9)
236
+ └── user-stories/
237
+ ├── EP-001-Foundation/
238
+ │ ├── HU-001-001.md (User Login)
239
+ │ └── HU-001-002.md (User Registration)
240
+ ├── EP-002-Data-Layer/
241
+ │ ├── HU-002-001.md (Persist User Data)
242
+ │ ├── HU-002-002.md (Persist Project Data)
243
+ │ └── HU-002-003.md (Persist Task Data)
244
+ ├── EP-003-Business-Logic/
245
+ │ ├── HU-003-001.md
246
+ │ ├── HU-003-002.md
247
+ │ └── HU-003-003.md
248
+ ├── EP-004-UI-Foundation/
249
+ │ ├── HU-004-001.md
250
+ │ ├── HU-004-002.md
251
+ │ └── HU-004-003.md
252
+ ├── EP-005-UI-Components/
253
+ │ ├── HU-005-001.md
254
+ │ ├── HU-005-002.md
255
+ │ ├── HU-005-003.md
256
+ │ ├── HU-005-004.md
257
+ │ ├── HU-005-005.md
258
+ │ └── HU-005-006.md
259
+ ├── EP-006-Controllers/
260
+ │ ├── HU-006-001.md
261
+ │ ├── HU-006-002.md
262
+ │ └── HU-006-003.md
263
+ ├── EP-007-Features/
264
+ │ ├── HU-007-001.md
265
+ │ ├── HU-007-002.md
266
+ │ ├── HU-007-003.md
267
+ │ ├── HU-007-004.md
268
+ │ └── HU-007-005.md
269
+ └── EP-008-Packaging/
270
+ ├── HU-008-001.md
271
+ └── HU-008-002.md
272
+ ```
273
+
274
+ ---
275
+
276
+ ### Phase 10 Output
277
+
278
+ ```
279
+ ✅ User Stories generated!
280
+
281
+ Created: planning/user-stories/
282
+
283
+ Summary:
284
+ - 30 User Stories created
285
+ - 8 Epic directories
286
+ - All stories linked to roadmap tasks
287
+ - Acceptance criteria defined
288
+ - Definition of Done included
289
+
290
+ File structure:
291
+ planning/
292
+ ├── roadmap.md (180 tasks)
293
+ └── user-stories/
294
+ ├── EP-001-Foundation/ (2 stories, 16 SP)
295
+ ├── EP-002-Data-Layer/ (3 stories, 15 SP)
296
+ ├── EP-003-Business-Logic/ (3 stories, 13 SP)
297
+ ├── EP-004-UI-Foundation/ (3 stories, 16 SP)
298
+ ├── EP-005-UI-Components/ (6 stories, 32 SP)
299
+ ├── EP-006-Controllers/ (3 stories, 13 SP)
300
+ ├── EP-007-Features/ (5 stories, 37 SP)
301
+ └── EP-008-Packaging/ (2 stories, 11 SP)
302
+
303
+ Next steps:
304
+ 1. Review planning/user-stories/
305
+ 2. Start implementation with /flow-work HU-001-001
306
+ 3. Or continue by Epic: /flow-work EP-001
307
+
308
+ Documentation complete! 🎉
309
+ ```
310
+
311
+ ---
312
+
313
+ ## Final Summary
314
+
315
+ ```
316
+ 🎉 ALL PHASES COMPLETE!
317
+
318
+ You now have:
319
+ ✅ Phase 0: Project Discovery (existing projects)
320
+ ✅ Phase 1: Desktop UX & Requirements
321
+ ✅ Phase 2: UI Components (Swing/JavaFX/SWT)
322
+ ✅ Phase 3: Architecture (MVC/MVP/MVVM)
323
+ ✅ Phase 4: Data & Storage
324
+ ✅ Phase 5: Code Standards
325
+ ✅ Phase 6: Testing Strategy
326
+ ✅ Phase 7: Packaging & Deployment
327
+ ✅ Phase 8: Project Setup & Docs
328
+ ✅ Phase 9: Implementation Roadmap (180 tasks)
329
+ ✅ Phase 10: User Stories (30 stories)
330
+
331
+ Generated files:
332
+ 📄 project-brief.md
333
+ 📄 docs/ARCHITECTURE.md
334
+ 📄 docs/DATABASE.md
335
+ 📄 docs/DEVELOPMENT.md
336
+ 📄 docs/DEPLOYMENT.md
337
+ 📄 planning/roadmap.md
338
+ 📁 planning/user-stories/ (30 files)
339
+ 📄 README.md
340
+ 📄 .gitignore
341
+
342
+ Ready to start development!
343
+
344
+ Commands:
345
+ - /flow-work HU-001-001 → Implement User Login
346
+ - /flow-work EP-001 → Implement Foundation Epic
347
+ - /flow-work T001 → Implement specific task
348
+ - /flow-check → Review code quality
349
+ - /flow-commit → Commit changes
350
+
351
+ Happy coding! 🚀
352
+ ```
353
+
354
+ ---
355
+
356
+ **Last Updated:** 2025-02-03
357
+ **Version:** 1.0.0