@vfarcic/dot-ai 0.106.0 → 0.108.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vfarcic/dot-ai",
3
- "version": "0.106.0",
3
+ "version": "0.108.0",
4
4
  "description": "AI-powered development productivity platform that enhances software development workflows through intelligent automation and AI-driven assistance",
5
5
  "mcpName": "io.github.vfarcic/dot-ai",
6
6
  "main": "dist/index.js",
@@ -0,0 +1,306 @@
1
+ ---
2
+ name: prd-close
3
+ description: Close a PRD that is already implemented or no longer needed
4
+ category: project-management
5
+ ---
6
+
7
+ # Close PRD
8
+
9
+ Close a PRD that is already implemented (in previous work or external projects) or is no longer needed. This workflow updates the PRD status, archives it, updates the GitHub issue, and commits directly to main without triggering CI.
10
+
11
+ ## When to Use This Command
12
+
13
+ **Use `/prd-close` when:**
14
+ - ✅ PRD functionality is already implemented in a separate project or previous work
15
+ - ✅ PRD is no longer relevant (superseded, requirements changed, out of scope)
16
+ - ✅ PRD requirements are satisfied by existing functionality
17
+ - ✅ No new code implementation is needed in this repository
18
+
19
+ **DO NOT use `/prd-close` when:**
20
+ - ❌ You just finished implementing the PRD (use `/prd-done` instead)
21
+ - ❌ PRD has active implementation work in progress
22
+ - ❌ There are uncommitted code changes that need to be part of a PR
23
+
24
+ ## Usage
25
+
26
+ ```bash
27
+ # Interactive mode - will prompt for PRD number and closure reason
28
+ /prd-close
29
+
30
+ # With PRD number
31
+ /prd-close 20
32
+
33
+ # With PRD number and reason
34
+ /prd-close 20 "Already implemented by dot-ai-controller"
35
+ ```
36
+
37
+ ## Workflow Steps
38
+
39
+ ### Step 1: Identify PRD and Reason
40
+
41
+ **If PRD number not provided:**
42
+ - Check conversation context for recent PRD discussion
43
+ - Check git branch for PRD indicators (e.g., `feature/prd-X`)
44
+ - If unclear, prompt user for PRD number
45
+
46
+ **Closure Reason Categories:**
47
+ - **Already Implemented**: Functionality exists in external project or previous work
48
+ - **No Longer Needed**: Requirements changed, out of scope, or superseded
49
+ - **Duplicate**: Another PRD covers the same functionality
50
+ - **Deferred**: Moved to future version or different project
51
+
52
+ **Required Information:**
53
+ - PRD number
54
+ - Closure reason (brief description)
55
+ - Implementation reference (if already implemented): link to repo, PR, or documentation
56
+
57
+ ### Step 2: Read and Validate PRD
58
+
59
+ Read the current PRD file from `prds/[number]-*.md`:
60
+
61
+ **Validation checks:**
62
+ - [ ] PRD file exists and is readable
63
+ - [ ] Confirm with user that this PRD should be closed
64
+ - [ ] Verify closure reason makes sense given PRD content
65
+ - [ ] Ask user for implementation evidence (if "already implemented")
66
+
67
+ **Present PRD summary to user:**
68
+ ```markdown
69
+ ## PRD #X: [Title]
70
+ **Status**: [Current Status]
71
+ **Created**: [Date]
72
+
73
+ **Summary**: [Brief description of what PRD requested]
74
+
75
+ **Proposed Action**: Close as [reason]
76
+ **Implementation Reference**: [If applicable]
77
+
78
+ Proceed with closure? (yes/no)
79
+ ```
80
+
81
+ ### Step 3: Update PRD File
82
+
83
+ Update the PRD metadata and add completion work log:
84
+
85
+ **Metadata Updates:**
86
+ ```markdown
87
+ **Status**: Complete [or] No Longer Needed [or] Duplicate
88
+ **Last Updated**: [Current Date]
89
+ **Completed**: [Current Date] [or] **Closed**: [Current Date]
90
+ ```
91
+
92
+ **Add Work Log Entry:**
93
+ ```markdown
94
+ ### [Date]: PRD Closure - [Reason Category]
95
+ **Duration**: N/A (administrative closure)
96
+ **Status**: [Complete/Closed]
97
+
98
+ **Closure Summary**:
99
+ [Explain why PRD is being closed]
100
+
101
+ **Implementation Evidence**: [If applicable]
102
+ [Link to external project, previous PR, or existing functionality]
103
+
104
+ **Key Points**:
105
+ - [What was requested in original PRD]
106
+ - [How/where it was implemented, or why no longer needed]
107
+ - [Any gaps or differences from original requirements]
108
+
109
+ [If "Already Implemented"]
110
+ **Functionality Delivered**:
111
+ - [Feature 1] - Implemented in [location/project]
112
+ - [Feature 2] - Implemented in [location/project]
113
+
114
+ [If "No Longer Needed"]
115
+ **Reason for Closure**:
116
+ - [Why requirements changed]
117
+ - [What superseded this PRD]
118
+ ```
119
+
120
+ ### Step 4: Move PRD to Archive
121
+
122
+ Move the PRD file to the done directory:
123
+
124
+ ```bash
125
+ # Create done directory if it doesn't exist
126
+ mkdir -p prds/done
127
+
128
+ # Move PRD file
129
+ git mv prds/[number]-[name].md prds/done/
130
+ ```
131
+
132
+ ### Step 5: Update GitHub Issue
133
+
134
+ **Reopen issue temporarily to update:**
135
+ ```bash
136
+ gh issue reopen [number]
137
+ ```
138
+
139
+ **Update issue description with new PRD path and status:**
140
+ ```bash
141
+ gh issue edit [number] --body "$(cat <<'EOF'
142
+ ## PRD: [Title]
143
+
144
+ **Problem**: [Original problem statement]
145
+
146
+ **Solution**: [Original solution statement]
147
+
148
+ **Detailed PRD**: See [prds/done/[number]-[name].md](./prds/done/[number]-[name].md)
149
+
150
+ **Priority**: [Original Priority]
151
+
152
+ **Status**: ✅ **[COMPLETE/CLOSED]** - [Brief reason]
153
+ EOF
154
+ )"
155
+ ```
156
+
157
+ ### Step 6: Close GitHub Issue
158
+
159
+ Close the issue with comprehensive closure comment:
160
+
161
+ ```bash
162
+ gh issue close [number] --comment "$(cat <<'EOF'
163
+ ## ✅ PRD #[number] Closed - [Reason Category]
164
+
165
+ [Detailed explanation of why PRD is being closed]
166
+
167
+ ### [If "Already Implemented"]
168
+ **Implementation Details**
169
+
170
+ This PRD requested [functionality]. **All core requirements are satisfied** by [implementation reference].
171
+
172
+ | Requirement | Implementation | Status |
173
+ |-------------|----------------|--------|
174
+ | [Requirement 1] | [Where implemented] | ✅ Complete |
175
+ | [Requirement 2] | [Where implemented] | ✅ Complete |
176
+
177
+ **Implementation Reference**: [Link to project/repo/PR]
178
+
179
+ [If there are gaps]
180
+ **Not Implemented** (deferred or out of scope):
181
+ - [Feature X] - [Why not needed or deferred]
182
+
183
+ ### [If "No Longer Needed"]
184
+ **Reason for Closure**
185
+
186
+ [Explain why requirements changed, what superseded this, or why it's out of scope]
187
+
188
+ **Alternative Approach**: [If applicable]
189
+ [What replaced this PRD or how needs are met differently]
190
+
191
+ ### Files
192
+
193
+ **PRD Location**: `prds/done/[number]-[name].md`
194
+ **Status**: [Complete/Closed]
195
+ **Closed**: [Date]
196
+ EOF
197
+ )"
198
+ ```
199
+
200
+ ### Step 7: Commit and Push
201
+
202
+ **Commit changes directly to main with skip CI:**
203
+
204
+ ```bash
205
+ # Stage all changes
206
+ git add .
207
+
208
+ # Verify what will be committed
209
+ git status
210
+
211
+ # Commit with skip CI flag
212
+ git commit -m "docs(prd-[number]): close PRD #[number] - [brief reason] [skip ci]
213
+
214
+ - Moved PRD to prds/done/ directory
215
+ - Updated PRD status to [Complete/Closed]
216
+ - Added work log documenting [closure reason]
217
+ - Updated GitHub issue description with new path
218
+ - [Implementation details or reason]
219
+
220
+ Closes #[number]"
221
+
222
+ # Push to remote
223
+ git push origin main
224
+ ```
225
+
226
+ **Important**:
227
+ - Always use `[skip ci]` flag to avoid unnecessary CI runs for documentation changes
228
+ - Include issue reference (`Closes #[number]`) to link commit to issue
229
+
230
+ ## Example Scenarios
231
+
232
+ ### Example 1: Already Implemented in External Project
233
+
234
+ ```bash
235
+ /prd-close 20 "Implemented by dot-ai-controller"
236
+ ```
237
+
238
+ **Closure Comment:**
239
+ ```markdown
240
+ ## ✅ PRD #20 Closed - Already Implemented
241
+
242
+ This PRD requested proactive Kubernetes cluster monitoring with AI-powered remediation.
243
+ **Core functionality (60-80%) is already implemented** by the separate
244
+ [dot-ai-controller](https://github.com/vfarcic/dot-ai-controller) project.
245
+
246
+ | Requirement | Implementation | Status |
247
+ |-------------|----------------|--------|
248
+ | Continuous health checks | Event-based monitoring via K8s events | ✅ Complete |
249
+ | Intelligent alerting | Slack notifications with AI analysis | ✅ Complete |
250
+ | Automated remediation | Automatic/manual modes with confidence thresholds | ✅ Complete |
251
+ | Anomaly detection | AI-powered event analysis | ✅ Complete |
252
+
253
+ **Not Implemented** (advanced features, may be future PRD):
254
+ - Continuous metrics monitoring (Prometheus-style)
255
+ - Predictive analytics with baseline learning
256
+ - Multi-channel alerting (email, PagerDuty)
257
+ ```
258
+
259
+ ### Example 2: Duplicate PRD
260
+
261
+ ```bash
262
+ /prd-close 45 "Duplicate of PRD #44"
263
+ ```
264
+
265
+ **Closure Comment:**
266
+ ```markdown
267
+ ## 🔄 PRD #45 Closed - Duplicate
268
+
269
+ This PRD covers the same functionality as PRD #44. Consolidating all work
270
+ under PRD #44 to avoid fragmentation.
271
+
272
+ **Action**: Continue work on PRD #44 instead.
273
+ ```
274
+
275
+ ### Example 3: No Longer Needed
276
+
277
+ ```bash
278
+ /prd-close 12 "Requirements changed, out of scope"
279
+ ```
280
+
281
+ **Closure Comment:**
282
+ ```markdown
283
+ ## ⏸️ PRD #12 Closed - No Longer Needed
284
+
285
+ After discussion, this approach no longer aligns with project direction.
286
+ Requirements have evolved and this PRD is out of scope.
287
+
288
+ **Alternative Approach**: Using [different solution/approach] instead.
289
+ ```
290
+
291
+ ## Success Criteria
292
+
293
+ ✅ **PRD file updated** with completion/closure metadata and work log
294
+ ✅ **PRD archived** to `prds/done/` directory
295
+ ✅ **GitHub issue updated** with new PRD path
296
+ ✅ **GitHub issue closed** with comprehensive closure comment
297
+ ✅ **Changes committed to main** with skip CI flag
298
+ ✅ **Changes pushed to remote** repository
299
+
300
+ ## Notes
301
+
302
+ - **No PR required**: This workflow commits directly to main for documentation-only changes
303
+ - **Skip CI**: Always include `[skip ci]` to avoid unnecessary CI runs
304
+ - **Comprehensive documentation**: Ensure work log and issue comment clearly explain closure
305
+ - **Implementation references**: Link to external projects, repos, or PRs where functionality exists
306
+ - **Gap acknowledgment**: Be honest about what's implemented vs. what's missing
@@ -116,4 +116,66 @@ Work through the PRD template focusing on project management, milestone tracking
116
116
  6. **Milestone Definition**: Define 5-10 major milestones that represent meaningful progress
117
117
  7. **Review & Validation**: Ensure completeness and clarity
118
118
 
119
- **CRITICAL**: Steps 2-4 must happen in this exact order to avoid the chicken-and-egg problem of needing the issue ID for the filename.
119
+ **CRITICAL**: Steps 2-4 must happen in this exact order to avoid the chicken-and-egg problem of needing the issue ID for the filename.
120
+
121
+ ## Next Steps After PRD Creation
122
+
123
+ After completing the PRD, present the user with numbered options:
124
+
125
+ ```
126
+ ✅ PRD Created Successfully!
127
+
128
+ **PRD File**: prds/[issue-id]-[feature-name].md
129
+ **GitHub Issue**: #[issue-id]
130
+
131
+ What would you like to do next?
132
+
133
+ **1. Start working on this PRD now**
134
+ Begin implementation immediately (recommended if you're ready to start)
135
+
136
+ **2. Commit and push PRD for later**
137
+ Save the PRD and work on it later (will use [skip ci] flag)
138
+
139
+ Please enter 1 or 2:
140
+ ```
141
+
142
+ ### Option 1: Start Working Now
143
+
144
+ If user chooses option 1, execute: **prd-start [issue-id]**
145
+
146
+ This will help identify the first task and set up the development workflow.
147
+
148
+ ### Option 2: Commit and Push for Later
149
+
150
+ If user chooses option 2:
151
+
152
+ ```bash
153
+ # Stage the PRD file
154
+ git add prds/[issue-id]-[feature-name].md
155
+
156
+ # Commit with skip CI flag to avoid unnecessary CI runs
157
+ git commit -m "docs(prd-[issue-id]): create PRD #[issue-id] - [feature-name] [skip ci]
158
+
159
+ - Created PRD for [brief feature description]
160
+ - Defined [X] major milestones
161
+ - Documented problem, solution, and success criteria
162
+ - Ready for implementation"
163
+
164
+ # Push to main
165
+ git push origin main
166
+ ```
167
+
168
+ **Confirmation Message:**
169
+ ```
170
+ ✅ PRD committed and pushed to main
171
+
172
+ The PRD is now available in the repository. To start working on it later, execute:
173
+ prd-start [issue-id]
174
+ ```
175
+
176
+ ## Important Notes
177
+
178
+ - **Option 1**: Best when you have time to begin implementation immediately
179
+ - **Option 2**: Best when creating multiple PRDs or planning future work
180
+ - **Skip CI flag**: Always use `[skip ci]` when committing PRD-only changes
181
+ - **Issue reference**: Include issue number in commit message for traceability