@morozinc/opencode-bmad-plugin 0.0.0-stage โ 0.1.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/LICENSE +31 -0
- package/NOTICE.md +6 -0
- package/README.md +64 -2
- package/dist/gui-experimental.cjs +64 -0
- package/docs/screenshots/artifact-storage.png +0 -0
- package/package.json +53 -4
- package/skills/bmad-code-review/SKILL.md +23 -0
- package/skills/bmad-code-review/reference/SKILL.md +90 -0
- package/skills/bmad-code-review/reference/customize.toml +41 -0
- package/skills/bmad-code-review/reference/steps/step-01-gather-context.md +85 -0
- package/skills/bmad-code-review/reference/steps/step-02-review.md +35 -0
- package/skills/bmad-code-review/reference/steps/step-03-triage.md +49 -0
- package/skills/bmad-code-review/reference/steps/step-04-present.md +132 -0
- package/skills/bmad-create-architecture/SKILL.md +23 -0
- package/skills/bmad-create-architecture/reference/SKILL.md +74 -0
- package/skills/bmad-create-architecture/reference/architecture-decision-template.md +12 -0
- package/skills/bmad-create-architecture/reference/customize.toml +41 -0
- package/skills/bmad-create-architecture/reference/data/domain-complexity.csv +13 -0
- package/skills/bmad-create-architecture/reference/data/project-types.csv +7 -0
- package/skills/bmad-create-architecture/reference/steps/step-01-init.md +153 -0
- package/skills/bmad-create-architecture/reference/steps/step-01b-continue.md +173 -0
- package/skills/bmad-create-architecture/reference/steps/step-02-context.md +224 -0
- package/skills/bmad-create-architecture/reference/steps/step-03-starter.md +329 -0
- package/skills/bmad-create-architecture/reference/steps/step-04-decisions.md +318 -0
- package/skills/bmad-create-architecture/reference/steps/step-05-patterns.md +359 -0
- package/skills/bmad-create-architecture/reference/steps/step-06-structure.md +379 -0
- package/skills/bmad-create-architecture/reference/steps/step-07-validation.md +361 -0
- package/skills/bmad-create-architecture/reference/steps/step-08-complete.md +82 -0
- package/skills/bmad-create-epics-and-stories/SKILL.md +23 -0
- package/skills/bmad-create-epics-and-stories/reference/SKILL.md +93 -0
- package/skills/bmad-create-epics-and-stories/reference/customize.toml +41 -0
- package/skills/bmad-create-epics-and-stories/reference/steps/step-01-validate-prerequisites.md +255 -0
- package/skills/bmad-create-epics-and-stories/reference/steps/step-02-design-epics.md +242 -0
- package/skills/bmad-create-epics-and-stories/reference/steps/step-03-create-stories.md +255 -0
- package/skills/bmad-create-epics-and-stories/reference/steps/step-04-final-validation.md +143 -0
- package/skills/bmad-create-epics-and-stories/reference/templates/epics-template.md +61 -0
- package/skills/bmad-create-story/SKILL.md +23 -0
- package/skills/bmad-create-story/reference/SKILL.md +429 -0
- package/skills/bmad-create-story/reference/checklist.md +357 -0
- package/skills/bmad-create-story/reference/customize.toml +41 -0
- package/skills/bmad-create-story/reference/discover-inputs.md +88 -0
- package/skills/bmad-create-story/reference/template.md +49 -0
- package/skills/bmad-dev-story/SKILL.md +23 -0
- package/skills/bmad-dev-story/reference/SKILL.md +500 -0
- package/skills/bmad-dev-story/reference/checklist.md +80 -0
- package/skills/bmad-dev-story/reference/customize.toml +41 -0
- package/skills/bmad-document-project/SKILL.md +23 -0
- package/skills/bmad-document-project/reference/SKILL.md +62 -0
- package/skills/bmad-document-project/reference/checklist.md +245 -0
- package/skills/bmad-document-project/reference/customize.toml +41 -0
- package/skills/bmad-document-project/reference/documentation-requirements.csv +12 -0
- package/skills/bmad-document-project/reference/instructions.md +128 -0
- package/skills/bmad-document-project/reference/templates/deep-dive-template.md +345 -0
- package/skills/bmad-document-project/reference/templates/index-template.md +169 -0
- package/skills/bmad-document-project/reference/templates/project-overview-template.md +103 -0
- package/skills/bmad-document-project/reference/templates/project-scan-report-schema.json +160 -0
- package/skills/bmad-document-project/reference/templates/source-tree-template.md +135 -0
- package/skills/bmad-document-project/reference/workflows/deep-dive-instructions.md +300 -0
- package/skills/bmad-document-project/reference/workflows/deep-dive-workflow.md +34 -0
- package/skills/bmad-document-project/reference/workflows/full-scan-instructions.md +1108 -0
- package/skills/bmad-document-project/reference/workflows/full-scan-workflow.md +34 -0
- package/skills/bmad-generate-project-context/SKILL.md +23 -0
- package/skills/bmad-generate-project-context/reference/SKILL.md +81 -0
- package/skills/bmad-generate-project-context/reference/customize.toml +41 -0
- package/skills/bmad-generate-project-context/reference/project-context-template.md +21 -0
- package/skills/bmad-generate-project-context/reference/steps/step-01-discover.md +186 -0
- package/skills/bmad-generate-project-context/reference/steps/step-02-generate.md +321 -0
- package/skills/bmad-generate-project-context/reference/steps/step-03-complete.md +284 -0
- package/skills/bmad-help/SKILL.md +19 -0
- package/skills/bmad-help/reference/SKILL.md +75 -0
- package/skills/bmad-prd/SKILL.md +23 -0
- package/skills/bmad-prd/reference/SKILL.md +92 -0
- package/skills/bmad-prd/reference/assets/headless-schemas.md +76 -0
- package/skills/bmad-prd/reference/assets/prd-template.md +165 -0
- package/skills/bmad-prd/reference/assets/prd-validation-checklist.md +135 -0
- package/skills/bmad-prd/reference/assets/validation-report-template.html +325 -0
- package/skills/bmad-prd/reference/customize.toml +147 -0
- package/skills/bmad-prd/reference/references/headless.md +39 -0
- package/skills/bmad-prd/reference/references/validate.md +97 -0
- package/skills/bmad-product-brief/SKILL.md +22 -0
- package/skills/bmad-product-brief/reference/SKILL.md +91 -0
- package/skills/bmad-product-brief/reference/assets/brief-template.md +41 -0
- package/skills/bmad-product-brief/reference/customize.toml +99 -0
- package/skills/bmad-quick-dev/SKILL.md +26 -0
- package/skills/bmad-quick-dev/reference/SKILL.md +111 -0
- package/skills/bmad-quick-dev/reference/compile-epic-context.md +62 -0
- package/skills/bmad-quick-dev/reference/customize.toml +41 -0
- package/skills/bmad-quick-dev/reference/spec-template.md +88 -0
- package/skills/bmad-quick-dev/reference/step-01-clarify-and-route.md +100 -0
- package/skills/bmad-quick-dev/reference/step-02-plan.md +47 -0
- package/skills/bmad-quick-dev/reference/step-03-implement.md +41 -0
- package/skills/bmad-quick-dev/reference/step-04-review.md +50 -0
- package/skills/bmad-quick-dev/reference/step-05-present.md +78 -0
- package/skills/bmad-quick-dev/reference/step-oneshot.md +71 -0
- package/skills/bmad-quick-dev/reference/sync-sprint-status.md +19 -0
- package/skills/bmad-sprint-planning/SKILL.md +23 -0
- package/skills/bmad-sprint-planning/reference/SKILL.md +300 -0
- package/skills/bmad-sprint-planning/reference/checklist.md +33 -0
- package/skills/bmad-sprint-planning/reference/customize.toml +41 -0
- package/skills/bmad-sprint-planning/reference/sprint-status-template.yaml +56 -0
- package/src/gui.tsx +127 -0
- package/src/index.ts +114 -0
- package/src/rpc.ts +27 -0
- package/src/storage.ts +21 -0
|
@@ -0,0 +1,321 @@
|
|
|
1
|
+
# Step 2: Context Rules Generation
|
|
2
|
+
|
|
3
|
+
## MANDATORY EXECUTION RULES (READ FIRST):
|
|
4
|
+
|
|
5
|
+
- ๐ NEVER generate content without user input
|
|
6
|
+
- โ
ALWAYS treat this as collaborative discovery between technical peers
|
|
7
|
+
- ๐ YOU ARE A FACILITATOR, not a content generator
|
|
8
|
+
- ๐ฌ FOCUS on unobvious rules that AI agents need to be reminded of
|
|
9
|
+
- ๐ฏ KEEP CONTENT LEAN - optimize for LLM context efficiency
|
|
10
|
+
- โ ๏ธ ABSOLUTELY NO TIME ESTIMATES - AI development speed has fundamentally changed
|
|
11
|
+
- โ
YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
|
|
12
|
+
- โ
YOU MUST ALWAYS WRITE all artifact and document content in `{document_output_language}`
|
|
13
|
+
|
|
14
|
+
## EXECUTION PROTOCOLS:
|
|
15
|
+
|
|
16
|
+
- ๐ฏ Show your analysis before taking any action
|
|
17
|
+
- ๐ Focus on specific, actionable rules rather than general advice
|
|
18
|
+
- โ ๏ธ Present A/P/C menu after each major rule category
|
|
19
|
+
- ๐พ ONLY save when user chooses C (Continue)
|
|
20
|
+
- ๐ Update frontmatter with completed sections
|
|
21
|
+
- ๐ซ FORBIDDEN to load next step until all sections are complete
|
|
22
|
+
|
|
23
|
+
## COLLABORATION MENUS (A/P/C):
|
|
24
|
+
|
|
25
|
+
This step will generate content and present choices for each rule category:
|
|
26
|
+
|
|
27
|
+
- **A (Advanced Elicitation)**: Use discovery protocols to explore nuanced implementation rules
|
|
28
|
+
- **P (Party Mode)**: Bring multiple perspectives to identify critical edge cases
|
|
29
|
+
- **C (Continue)**: Save the current rules and proceed to next category
|
|
30
|
+
|
|
31
|
+
## PROTOCOL INTEGRATION:
|
|
32
|
+
|
|
33
|
+
- When 'A' selected: Invoke the `bmad-advanced-elicitation` skill
|
|
34
|
+
- When 'P' selected: Invoke the `bmad-party-mode` skill
|
|
35
|
+
- PROTOCOLS always return to display this step's A/P/C menu after the A or P have completed
|
|
36
|
+
- User accepts/rejects protocol changes before proceeding
|
|
37
|
+
|
|
38
|
+
## CONTEXT BOUNDARIES:
|
|
39
|
+
|
|
40
|
+
- Discovery results from step-1 are available
|
|
41
|
+
- Technology stack and existing patterns are identified
|
|
42
|
+
- Focus on rules that prevent implementation mistakes
|
|
43
|
+
- Prioritize unobvious details that AI agents might miss
|
|
44
|
+
|
|
45
|
+
## YOUR TASK:
|
|
46
|
+
|
|
47
|
+
Collaboratively generate specific, critical rules that AI agents must follow when implementing code in this project.
|
|
48
|
+
|
|
49
|
+
## CONTEXT GENERATION SEQUENCE:
|
|
50
|
+
|
|
51
|
+
### 1. Technology Stack & Versions
|
|
52
|
+
|
|
53
|
+
Document the exact technology stack from discovery:
|
|
54
|
+
|
|
55
|
+
**Core Technologies:**
|
|
56
|
+
Based on user skill level, present findings:
|
|
57
|
+
|
|
58
|
+
**Expert Mode:**
|
|
59
|
+
"Technology stack from your architecture and package files:
|
|
60
|
+
{{exact_technologies_with_versions}}
|
|
61
|
+
|
|
62
|
+
Any critical version constraints I should document for agents?"
|
|
63
|
+
|
|
64
|
+
**Intermediate Mode:**
|
|
65
|
+
"I found your technology stack:
|
|
66
|
+
|
|
67
|
+
**Core Technologies:**
|
|
68
|
+
{{main_technologies_with_versions}}
|
|
69
|
+
|
|
70
|
+
**Key Dependencies:**
|
|
71
|
+
{{important_dependencies_with_versions}}
|
|
72
|
+
|
|
73
|
+
Are there any version constraints or compatibility notes agents should know about?"
|
|
74
|
+
|
|
75
|
+
**Beginner Mode:**
|
|
76
|
+
"Here are the technologies you're using:
|
|
77
|
+
|
|
78
|
+
**Main Technologies:**
|
|
79
|
+
{{friendly_description_of_tech_stack}}
|
|
80
|
+
|
|
81
|
+
**Important Notes:**
|
|
82
|
+
{{key_things_agents_need_to_know_about_versions}}
|
|
83
|
+
|
|
84
|
+
Should I document any special version rules or compatibility requirements?"
|
|
85
|
+
|
|
86
|
+
### 2. Language-Specific Rules
|
|
87
|
+
|
|
88
|
+
Focus on unobvious language patterns agents might miss:
|
|
89
|
+
|
|
90
|
+
**TypeScript/JavaScript Rules:**
|
|
91
|
+
"Based on your codebase, I notice some specific patterns:
|
|
92
|
+
|
|
93
|
+
**Configuration Requirements:**
|
|
94
|
+
{{typescript_config_rules}}
|
|
95
|
+
|
|
96
|
+
**Import/Export Patterns:**
|
|
97
|
+
{{import_export_conventions}}
|
|
98
|
+
|
|
99
|
+
**Error Handling Patterns:**
|
|
100
|
+
{{error_handling_requirements}}
|
|
101
|
+
|
|
102
|
+
Are these patterns correct? Any other language-specific rules agents should follow?"
|
|
103
|
+
|
|
104
|
+
**Python/Ruby/Other Language Rules:**
|
|
105
|
+
Adapt to the actual language in use with similar focused questions.
|
|
106
|
+
|
|
107
|
+
### 3. Framework-Specific Rules
|
|
108
|
+
|
|
109
|
+
Document framework-specific patterns:
|
|
110
|
+
|
|
111
|
+
**React Rules (if applicable):**
|
|
112
|
+
"For React development, I see these patterns:
|
|
113
|
+
|
|
114
|
+
**Hooks Usage:**
|
|
115
|
+
{{hooks_usage_patterns}}
|
|
116
|
+
|
|
117
|
+
**Component Structure:**
|
|
118
|
+
{{component_organization_rules}}
|
|
119
|
+
|
|
120
|
+
**State Management:**
|
|
121
|
+
{{state_management_patterns}}
|
|
122
|
+
|
|
123
|
+
**Performance Rules:**
|
|
124
|
+
{{performance_optimization_requirements}}
|
|
125
|
+
|
|
126
|
+
Should I add any other React-specific rules?"
|
|
127
|
+
|
|
128
|
+
**Other Framework Rules:**
|
|
129
|
+
Adapt for Vue, Angular, Next.js, Express, etc.
|
|
130
|
+
|
|
131
|
+
### 4. Testing Rules
|
|
132
|
+
|
|
133
|
+
Focus on testing patterns that ensure consistency:
|
|
134
|
+
|
|
135
|
+
**Test Structure Rules:**
|
|
136
|
+
"Your testing setup shows these patterns:
|
|
137
|
+
|
|
138
|
+
**Test Organization:**
|
|
139
|
+
{{test_file_organization}}
|
|
140
|
+
|
|
141
|
+
**Mock Usage:**
|
|
142
|
+
{{mock_patterns_and_conventions}}
|
|
143
|
+
|
|
144
|
+
**Test Coverage Requirements:**
|
|
145
|
+
{{coverage_expectations}}
|
|
146
|
+
|
|
147
|
+
**Integration vs Unit Test Rules:**
|
|
148
|
+
{{test_boundary_patterns}}
|
|
149
|
+
|
|
150
|
+
Are there testing rules agents should always follow?"
|
|
151
|
+
|
|
152
|
+
### 5. Code Quality & Style Rules
|
|
153
|
+
|
|
154
|
+
Document critical style and quality rules:
|
|
155
|
+
|
|
156
|
+
**Linting/Formatting:**
|
|
157
|
+
"Your code style configuration requires:
|
|
158
|
+
|
|
159
|
+
**ESLint/Prettier Rules:**
|
|
160
|
+
{{specific_linting_rules}}
|
|
161
|
+
|
|
162
|
+
**Code Organization:**
|
|
163
|
+
{{file_and_folder_structure_rules}}
|
|
164
|
+
|
|
165
|
+
**Naming Conventions:**
|
|
166
|
+
{{naming_patterns_agents_must_follow}}
|
|
167
|
+
|
|
168
|
+
**Documentation Requirements:**
|
|
169
|
+
{{comment_and_documentation_patterns}}
|
|
170
|
+
|
|
171
|
+
Any additional code quality rules?"
|
|
172
|
+
|
|
173
|
+
### 6. Development Workflow Rules
|
|
174
|
+
|
|
175
|
+
Document workflow patterns that affect implementation:
|
|
176
|
+
|
|
177
|
+
**Git/Repository Rules:**
|
|
178
|
+
"Your project uses these patterns:
|
|
179
|
+
|
|
180
|
+
**Branch Naming:**
|
|
181
|
+
{{branch_naming_conventions}}
|
|
182
|
+
|
|
183
|
+
**Commit Message Format:**
|
|
184
|
+
{{commit_message_patterns}}
|
|
185
|
+
|
|
186
|
+
**PR Requirements:**
|
|
187
|
+
{{pull_request_checklist}}
|
|
188
|
+
|
|
189
|
+
**Deployment Patterns:**
|
|
190
|
+
{{deployment_considerations}}
|
|
191
|
+
|
|
192
|
+
Should I document any other workflow rules?"
|
|
193
|
+
|
|
194
|
+
### 7. Critical Don't-Miss Rules
|
|
195
|
+
|
|
196
|
+
Identify rules that prevent common mistakes:
|
|
197
|
+
|
|
198
|
+
**Anti-Patterns to Avoid:**
|
|
199
|
+
"Based on your codebase, here are critical things agents must NOT do:
|
|
200
|
+
|
|
201
|
+
{{critical_anti_patterns_with_examples}}
|
|
202
|
+
|
|
203
|
+
**Edge Cases:**
|
|
204
|
+
{{specific_edge_cases_agents_should_handle}}
|
|
205
|
+
|
|
206
|
+
**Security Rules:**
|
|
207
|
+
{{security_considerations_agents_must_follow}}
|
|
208
|
+
|
|
209
|
+
**Performance Gotchas:**
|
|
210
|
+
{{performance_patterns_to_avoid}}
|
|
211
|
+
|
|
212
|
+
Are there other 'gotchas' agents should know about?"
|
|
213
|
+
|
|
214
|
+
### 8. Generate Context Content
|
|
215
|
+
|
|
216
|
+
For each category, prepare lean content for the project context file:
|
|
217
|
+
|
|
218
|
+
#### Content Structure:
|
|
219
|
+
|
|
220
|
+
```markdown
|
|
221
|
+
## Technology Stack & Versions
|
|
222
|
+
|
|
223
|
+
{{concise_technology_list_with_exact_versions}}
|
|
224
|
+
|
|
225
|
+
## Critical Implementation Rules
|
|
226
|
+
|
|
227
|
+
### Language-Specific Rules
|
|
228
|
+
|
|
229
|
+
{{bullet_points_of_critical_language_rules}}
|
|
230
|
+
|
|
231
|
+
### Framework-Specific Rules
|
|
232
|
+
|
|
233
|
+
{{bullet_points_of_framework_patterns}}
|
|
234
|
+
|
|
235
|
+
### Testing Rules
|
|
236
|
+
|
|
237
|
+
{{bullet_points_of_testing_requirements}}
|
|
238
|
+
|
|
239
|
+
### Code Quality & Style Rules
|
|
240
|
+
|
|
241
|
+
{{bullet_points_of_style_and_quality_rules}}
|
|
242
|
+
|
|
243
|
+
### Development Workflow Rules
|
|
244
|
+
|
|
245
|
+
{{bullet_points_of_workflow_patterns}}
|
|
246
|
+
|
|
247
|
+
### Critical Don't-Miss Rules
|
|
248
|
+
|
|
249
|
+
{{bullet_points_of_anti_patterns_and_edge_cases}}
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
### 9. Present Content and Menu
|
|
253
|
+
|
|
254
|
+
After each category, show the generated rules and present choices:
|
|
255
|
+
|
|
256
|
+
"I've drafted the {{category_name}} rules for your project context.
|
|
257
|
+
|
|
258
|
+
**Here's what I'll add:**
|
|
259
|
+
|
|
260
|
+
[Show the complete markdown content for this category]
|
|
261
|
+
|
|
262
|
+
**What would you like to do?**
|
|
263
|
+
[A] Advanced Elicitation - Explore nuanced rules for this category
|
|
264
|
+
[P] Party Mode - Review from different implementation perspectives
|
|
265
|
+
[C] Continue - Save these rules and move to next category"
|
|
266
|
+
|
|
267
|
+
**HALT โ wait for user selection before proceeding.**
|
|
268
|
+
|
|
269
|
+
### 10. Handle Menu Selection
|
|
270
|
+
|
|
271
|
+
#### If 'A' (Advanced Elicitation):
|
|
272
|
+
|
|
273
|
+
- Invoke the `bmad-advanced-elicitation` skill with current category rules
|
|
274
|
+
- Process enhanced rules that come back
|
|
275
|
+
- Ask user: "Accept these enhanced rules for {{category}}? (y/n)"
|
|
276
|
+
- If yes: Update content, then return to A/P/C menu
|
|
277
|
+
- If no: Keep original content, then return to A/P/C menu
|
|
278
|
+
|
|
279
|
+
#### If 'P' (Party Mode):
|
|
280
|
+
|
|
281
|
+
- Invoke the `bmad-party-mode` skill with category rules context
|
|
282
|
+
- Process collaborative insights on implementation patterns
|
|
283
|
+
- Ask user: "Accept these changes to {{category}} rules? (y/n)"
|
|
284
|
+
- If yes: Update content, then return to A/P/C menu
|
|
285
|
+
- If no: Keep original content, then return to A/P/C menu
|
|
286
|
+
|
|
287
|
+
#### If 'C' (Continue):
|
|
288
|
+
|
|
289
|
+
- Save the current category content to project context file
|
|
290
|
+
- Update frontmatter: `sections_completed: [...]`
|
|
291
|
+
- Proceed to next category or step-03 if complete
|
|
292
|
+
|
|
293
|
+
## APPEND TO PROJECT CONTEXT:
|
|
294
|
+
|
|
295
|
+
When user selects 'C' for a category, append the content directly to `{output_folder}/project-context.md` using the structure from step 8.
|
|
296
|
+
|
|
297
|
+
## SUCCESS METRICS:
|
|
298
|
+
|
|
299
|
+
โ
All critical technology versions accurately documented
|
|
300
|
+
โ
Language-specific rules cover unobvious patterns
|
|
301
|
+
โ
Framework rules capture project-specific conventions
|
|
302
|
+
โ
Testing rules ensure consistent test quality
|
|
303
|
+
โ
Code quality rules maintain project standards
|
|
304
|
+
โ
Workflow rules prevent implementation conflicts
|
|
305
|
+
โ
Content is lean and optimized for LLM context
|
|
306
|
+
โ
A/P/C menu presented and handled correctly for each category
|
|
307
|
+
|
|
308
|
+
## FAILURE MODES:
|
|
309
|
+
|
|
310
|
+
โ Including obvious rules that agents already know
|
|
311
|
+
โ Making content too verbose for LLM context efficiency
|
|
312
|
+
โ Missing critical anti-patterns or edge cases
|
|
313
|
+
โ Not getting user validation for each rule category
|
|
314
|
+
โ Not documenting exact versions and configurations
|
|
315
|
+
โ Not presenting A/P/C menu after content generation
|
|
316
|
+
|
|
317
|
+
## NEXT STEP:
|
|
318
|
+
|
|
319
|
+
After completing all rule categories and user selects 'C' for the final category, load `./step-03-complete.md` to finalize the project context file.
|
|
320
|
+
|
|
321
|
+
Remember: Do NOT proceed to step-03 until all categories are complete and user explicitly selects 'C' for each!
|
|
@@ -0,0 +1,284 @@
|
|
|
1
|
+
# Step 3: Context Completion & Finalization
|
|
2
|
+
|
|
3
|
+
## MANDATORY EXECUTION RULES (READ FIRST):
|
|
4
|
+
|
|
5
|
+
- ๐ NEVER generate content without user input
|
|
6
|
+
- โ
ALWAYS treat this as collaborative completion between technical peers
|
|
7
|
+
- ๐ YOU ARE A FACILITATOR, not a content generator
|
|
8
|
+
- ๐ฌ FOCUS on finalizing a lean, LLM-optimized project context
|
|
9
|
+
- ๐ฏ ENSURE all critical rules are captured and actionable
|
|
10
|
+
- โ ๏ธ ABSOLUTELY NO TIME ESTIMATES - AI development speed has fundamentally changed
|
|
11
|
+
- โ
YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
|
|
12
|
+
|
|
13
|
+
## EXECUTION PROTOCOLS:
|
|
14
|
+
|
|
15
|
+
- ๐ฏ Show your analysis before taking any action
|
|
16
|
+
- ๐ Review and optimize content for LLM context efficiency
|
|
17
|
+
- ๐ Update frontmatter with completion status
|
|
18
|
+
- ๐ซ NO MORE STEPS - this is the final step
|
|
19
|
+
|
|
20
|
+
## CONTEXT BOUNDARIES:
|
|
21
|
+
|
|
22
|
+
- All rule categories from step-2 are complete
|
|
23
|
+
- Technology stack and versions are documented
|
|
24
|
+
- Focus on final review, optimization, and completion
|
|
25
|
+
- Ensure the context file is ready for AI agent consumption
|
|
26
|
+
|
|
27
|
+
## YOUR TASK:
|
|
28
|
+
|
|
29
|
+
Complete the project context file, optimize it for LLM efficiency, and provide guidance for usage and maintenance.
|
|
30
|
+
|
|
31
|
+
## COMPLETION SEQUENCE:
|
|
32
|
+
|
|
33
|
+
### 1. Review Complete Context File
|
|
34
|
+
|
|
35
|
+
Read the entire project context file and analyze:
|
|
36
|
+
|
|
37
|
+
**Content Analysis:**
|
|
38
|
+
|
|
39
|
+
- Total length and readability for LLMs
|
|
40
|
+
- Clarity and specificity of rules
|
|
41
|
+
- Coverage of all critical areas
|
|
42
|
+
- Actionability of each rule
|
|
43
|
+
|
|
44
|
+
**Structure Analysis:**
|
|
45
|
+
|
|
46
|
+
- Logical organization of sections
|
|
47
|
+
- Consistency of formatting
|
|
48
|
+
- Absence of redundant or obvious information
|
|
49
|
+
- Optimization for quick scanning
|
|
50
|
+
|
|
51
|
+
### 2. Optimize for LLM Context
|
|
52
|
+
|
|
53
|
+
Ensure the file is lean and efficient:
|
|
54
|
+
|
|
55
|
+
**Content Optimization:**
|
|
56
|
+
|
|
57
|
+
- Remove any redundant rules or obvious information
|
|
58
|
+
- Combine related rules into concise bullet points
|
|
59
|
+
- Use specific, actionable language
|
|
60
|
+
- Ensure each rule provides unique value
|
|
61
|
+
|
|
62
|
+
**Formatting Optimization:**
|
|
63
|
+
|
|
64
|
+
- Use consistent markdown formatting
|
|
65
|
+
- Implement clear section hierarchy
|
|
66
|
+
- Ensure scannability with strategic use of bolding
|
|
67
|
+
- Maintain readability while maximizing information density
|
|
68
|
+
|
|
69
|
+
### 3. Final Content Structure
|
|
70
|
+
|
|
71
|
+
Ensure the final structure follows this optimized format:
|
|
72
|
+
|
|
73
|
+
```markdown
|
|
74
|
+
# Project Context for AI Agents
|
|
75
|
+
|
|
76
|
+
_This file contains critical rules and patterns that AI agents must follow when implementing code in this project. Focus on unobvious details that agents might otherwise miss._
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
## Technology Stack & Versions
|
|
81
|
+
|
|
82
|
+
{{concise_technology_list}}
|
|
83
|
+
|
|
84
|
+
## Critical Implementation Rules
|
|
85
|
+
|
|
86
|
+
### Language-Specific Rules
|
|
87
|
+
|
|
88
|
+
{{specific_language_rules}}
|
|
89
|
+
|
|
90
|
+
### Framework-Specific Rules
|
|
91
|
+
|
|
92
|
+
{{framework_patterns}}
|
|
93
|
+
|
|
94
|
+
### Testing Rules
|
|
95
|
+
|
|
96
|
+
{{testing_requirements}}
|
|
97
|
+
|
|
98
|
+
### Code Quality & Style Rules
|
|
99
|
+
|
|
100
|
+
{{style_and_quality_patterns}}
|
|
101
|
+
|
|
102
|
+
### Development Workflow Rules
|
|
103
|
+
|
|
104
|
+
{{workflow_patterns}}
|
|
105
|
+
|
|
106
|
+
### Critical Don't-Miss Rules
|
|
107
|
+
|
|
108
|
+
{{anti_patterns_and_edge_cases}}
|
|
109
|
+
|
|
110
|
+
---
|
|
111
|
+
|
|
112
|
+
## Usage Guidelines
|
|
113
|
+
|
|
114
|
+
**For AI Agents:**
|
|
115
|
+
|
|
116
|
+
- Read this file before implementing any code
|
|
117
|
+
- Follow ALL rules exactly as documented
|
|
118
|
+
- When in doubt, prefer the more restrictive option
|
|
119
|
+
- Update this file if new patterns emerge
|
|
120
|
+
|
|
121
|
+
**For Humans:**
|
|
122
|
+
|
|
123
|
+
- Keep this file lean and focused on agent needs
|
|
124
|
+
- Update when technology stack changes
|
|
125
|
+
- Review quarterly for outdated rules
|
|
126
|
+
- Remove rules that become obvious over time
|
|
127
|
+
|
|
128
|
+
Last Updated: {{date}}
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
### 4. Present Completion Summary
|
|
132
|
+
|
|
133
|
+
Based on user skill level, present the completion:
|
|
134
|
+
|
|
135
|
+
**Expert Mode:**
|
|
136
|
+
"Project context complete. Optimized for LLM consumption with {{rule_count}} critical rules across {{section_count}} sections.
|
|
137
|
+
|
|
138
|
+
File saved to: `{output_folder}/project-context.md`
|
|
139
|
+
|
|
140
|
+
Ready for AI agent integration."
|
|
141
|
+
|
|
142
|
+
**Intermediate Mode:**
|
|
143
|
+
"Your project context is complete and optimized for AI agents!
|
|
144
|
+
|
|
145
|
+
**What we created:**
|
|
146
|
+
|
|
147
|
+
- {{rule_count}} critical implementation rules
|
|
148
|
+
- Technology stack with exact versions
|
|
149
|
+
- Framework-specific patterns and conventions
|
|
150
|
+
- Testing and quality guidelines
|
|
151
|
+
- Workflow and anti-pattern rules
|
|
152
|
+
|
|
153
|
+
**Key benefits:**
|
|
154
|
+
|
|
155
|
+
- AI agents will implement consistently with your standards
|
|
156
|
+
- Reduced context switching and implementation errors
|
|
157
|
+
- Clear guidance for unobvious project requirements
|
|
158
|
+
|
|
159
|
+
**Next steps:**
|
|
160
|
+
|
|
161
|
+
- AI agents should read this file before implementing
|
|
162
|
+
- Update as your project evolves
|
|
163
|
+
- Review periodically for optimization"
|
|
164
|
+
|
|
165
|
+
**Beginner Mode:**
|
|
166
|
+
"Excellent! Your project context guide is ready! ๐
|
|
167
|
+
|
|
168
|
+
**What this does:**
|
|
169
|
+
Think of this as a 'rules of the road' guide for AI agents working on your project. It ensures they all follow the same patterns and avoid common mistakes.
|
|
170
|
+
|
|
171
|
+
**What's included:**
|
|
172
|
+
|
|
173
|
+
- Exact technology versions to use
|
|
174
|
+
- Critical coding rules they might miss
|
|
175
|
+
- Testing and quality standards
|
|
176
|
+
- Workflow patterns to follow
|
|
177
|
+
|
|
178
|
+
**How AI agents use it:**
|
|
179
|
+
They read this file before writing any code, ensuring everything they create follows your project's standards perfectly.
|
|
180
|
+
|
|
181
|
+
Your project context is saved and ready to help agents implement consistently!"
|
|
182
|
+
|
|
183
|
+
### 5. Final File Updates
|
|
184
|
+
|
|
185
|
+
Update the project context file with completion information:
|
|
186
|
+
|
|
187
|
+
**Frontmatter Update:**
|
|
188
|
+
|
|
189
|
+
```yaml
|
|
190
|
+
---
|
|
191
|
+
project_name: '{{project_name}}'
|
|
192
|
+
user_name: '{{user_name}}'
|
|
193
|
+
date: '{{date}}'
|
|
194
|
+
sections_completed:
|
|
195
|
+
['technology_stack', 'language_rules', 'framework_rules', 'testing_rules', 'quality_rules', 'workflow_rules', 'anti_patterns']
|
|
196
|
+
status: 'complete'
|
|
197
|
+
rule_count: { { total_rules } }
|
|
198
|
+
optimized_for_llm: true
|
|
199
|
+
---
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
**Add Usage Section:**
|
|
203
|
+
Append the usage guidelines from step 3 to complete the document.
|
|
204
|
+
|
|
205
|
+
### 6. Completion Validation
|
|
206
|
+
|
|
207
|
+
Final checks before completion:
|
|
208
|
+
|
|
209
|
+
**Content Validation:**
|
|
210
|
+
โ
All critical technology versions documented
|
|
211
|
+
โ
Language-specific rules are specific and actionable
|
|
212
|
+
โ
Framework rules cover project conventions
|
|
213
|
+
โ
Testing rules ensure consistency
|
|
214
|
+
โ
Code quality rules maintain standards
|
|
215
|
+
โ
Workflow rules prevent conflicts
|
|
216
|
+
โ
Anti-pattern rules prevent common mistakes
|
|
217
|
+
|
|
218
|
+
**Format Validation:**
|
|
219
|
+
โ
Content is lean and optimized for LLMs
|
|
220
|
+
โ
Structure is logical and scannable
|
|
221
|
+
โ
No redundant or obvious information
|
|
222
|
+
โ
Consistent formatting throughout
|
|
223
|
+
|
|
224
|
+
### 7. Completion Message
|
|
225
|
+
|
|
226
|
+
Present final completion to user:
|
|
227
|
+
|
|
228
|
+
"โ
**Project Context Generation Complete!**
|
|
229
|
+
|
|
230
|
+
Your optimized project context file is ready at:
|
|
231
|
+
`{output_folder}/project-context.md`
|
|
232
|
+
|
|
233
|
+
**๐ Context Summary:**
|
|
234
|
+
|
|
235
|
+
- {{rule_count}} critical rules for AI agents
|
|
236
|
+
- {{section_count}} comprehensive sections
|
|
237
|
+
- Optimized for LLM context efficiency
|
|
238
|
+
- Ready for immediate agent integration
|
|
239
|
+
|
|
240
|
+
**๐ฏ Key Benefits:**
|
|
241
|
+
|
|
242
|
+
- Consistent implementation across all AI agents
|
|
243
|
+
- Reduced common mistakes and edge cases
|
|
244
|
+
- Clear guidance for project-specific patterns
|
|
245
|
+
- Minimal LLM context usage
|
|
246
|
+
|
|
247
|
+
**๐ Next Steps:**
|
|
248
|
+
|
|
249
|
+
1. AI agents will automatically read this file when implementing
|
|
250
|
+
2. Update this file when your technology stack or patterns evolve
|
|
251
|
+
3. Review quarterly to optimize and remove outdated rules
|
|
252
|
+
|
|
253
|
+
Your project context will help ensure high-quality, consistent implementation across all development work. Great work capturing your project's critical implementation requirements!"
|
|
254
|
+
|
|
255
|
+
## SUCCESS METRICS:
|
|
256
|
+
|
|
257
|
+
โ
Complete project context file with all critical rules
|
|
258
|
+
โ
Content optimized for LLM context efficiency
|
|
259
|
+
โ
All technology versions and patterns documented
|
|
260
|
+
โ
File structure is logical and scannable
|
|
261
|
+
โ
Usage guidelines included for agents and humans
|
|
262
|
+
โ
Frontmatter properly updated with completion status
|
|
263
|
+
โ
User provided with clear next steps and benefits
|
|
264
|
+
|
|
265
|
+
## FAILURE MODES:
|
|
266
|
+
|
|
267
|
+
โ Final content is too verbose for LLM consumption
|
|
268
|
+
โ Missing critical implementation rules or patterns
|
|
269
|
+
โ Not optimizing content for agent readability
|
|
270
|
+
โ Not providing clear usage guidelines
|
|
271
|
+
โ Frontmatter not properly updated
|
|
272
|
+
โ Not validating file completion before ending
|
|
273
|
+
|
|
274
|
+
## WORKFLOW COMPLETE:
|
|
275
|
+
|
|
276
|
+
This is the final step of the Generate Project Context workflow. The user now has a comprehensive, optimized project context file that will ensure consistent, high-quality implementation across all AI agents working on the project.
|
|
277
|
+
|
|
278
|
+
The project context file serves as the critical "rules of the road" that agents need to implement code consistently with the project's standards and patterns.
|
|
279
|
+
|
|
280
|
+
## On Complete
|
|
281
|
+
|
|
282
|
+
Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete`
|
|
283
|
+
|
|
284
|
+
If the resolved `workflow.on_complete` is non-empty, follow it as the final terminal instruction before exiting.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: bmad-help
|
|
3
|
+
description: "Analyzes current state and user query to answer BMad questions or recommend the next skill(s) to use. Use when user asks for help, bmad help, what to do next, or what to start with in BMad."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# bmad-help ยท OpenCode edition
|
|
7
|
+
|
|
8
|
+
## Artifact storage
|
|
9
|
+
|
|
10
|
+
Use the **BMAD artifact storage** contract injected by the OpenCode BMAD plugin for this project. It names the selected backend, project root and exact artifact prefix. Call `bmad_storage` if the contract is missing or you need to refresh it. Read existing artifacts before editing, write complete Markdown, then read back and verify. Keep each artifact's logical name stable. Do not switch storage backends silently. The plugin is installed globally; project artifacts are scoped to the current repository. Source code changes remain in the repository. Bundled references may mention upstream project-local `_bmad` setup, config or scripts; use their methodology without requiring those files in the project. The selected storage contract overrides artifact paths in references.
|
|
11
|
+
|
|
12
|
+
## Workflow
|
|
13
|
+
|
|
14
|
+
1. Read the artifact catalog for this project and the user's question. Identify the current work and missing prerequisite documents.
|
|
15
|
+
2. Route to the smallest appropriate installed skill: brief โ `bmad-product-brief`; requirements โ `bmad-prd`; design โ `bmad-create-architecture`; decomposition โ `bmad-create-epics-and-stories`; sprint โ `bmad-sprint-planning`; detailed story โ `bmad-create-story`; implementation โ `bmad-dev-story` or `bmad-quick-dev`; review โ `bmad-code-review`; brownfield docs โ `bmad-document-project`; guidance โ `bmad-generate-project-context`.
|
|
16
|
+
3. Explain the recommendation with the relevant existing artifact paths. Answer help questions directly; do not launch another workflow without the user's request.
|
|
17
|
+
4. Update `method-index.md` only when project stage, artifact links or an agreed next action changed.
|
|
18
|
+
|
|
19
|
+
**Primary artifact:** `method-index.md`. Use a stable descriptive `<story-id>`, `<review-id>` or `<change-id>` where shown, and return its full verified artifact path.
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: bmad-help
|
|
3
|
+
description: 'Analyzes current state and user query to answer BMad questions or recommend the next skill(s) to use. Use when user asks for help, bmad help, what to do next, or what to start with in BMad.'
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# BMad Help
|
|
7
|
+
|
|
8
|
+
## Purpose
|
|
9
|
+
|
|
10
|
+
Help the user understand where they are in their BMad workflow and what to do next, and also answer broader questions when asked that could be augmented with remote sources such as module documentation sources.
|
|
11
|
+
|
|
12
|
+
## Desired Outcomes
|
|
13
|
+
|
|
14
|
+
When this skill completes, the user should:
|
|
15
|
+
|
|
16
|
+
1. **Know where they are** โ which module and phase they're in, what's already been completed
|
|
17
|
+
2. **Know what to do next** โ the next recommended and/or required step, with clear reasoning
|
|
18
|
+
3. **Know how to invoke it** โ skill name, menu code, action context, and any args that shortcut the conversation
|
|
19
|
+
4. **Get offered a quick start** โ when a single skill is the clear next step, offer to run it for the user right now rather than just listing it
|
|
20
|
+
5. **Feel oriented, not overwhelmed** โ surface only what's relevant to their current position; don't dump the entire catalog
|
|
21
|
+
6. **Get answers to general questions** โ when the question doesn't map to a specific skill, use the module's registered documentation to give a grounded answer
|
|
22
|
+
|
|
23
|
+
## Data Sources
|
|
24
|
+
|
|
25
|
+
- **Catalog**: `{project-root}/_bmad/_config/bmad-help.csv` โ assembled manifest of all installed module skills
|
|
26
|
+
- **Config**: `config.yaml` and `user-config.yaml` files in `{project-root}/_bmad/` and its subfolders โ resolve `output-location` variables, provide `communication_language` and `project_knowledge`
|
|
27
|
+
- **Artifacts**: Files matching `outputs` patterns at resolved `output-location` paths reveal which steps are possibly completed; their content may also provide grounding context for recommendations
|
|
28
|
+
- **Project knowledge**: If `project_knowledge` resolves to an existing path, read it for grounding context. Never fabricate project-specific details.
|
|
29
|
+
- **Module docs**: Rows with `_meta` in the `skill` column carry a URL or path in `output-location` pointing to the module's documentation (e.g., llms.txt). Fetch and use these to answer general questions about that module.
|
|
30
|
+
|
|
31
|
+
## CSV Interpretation
|
|
32
|
+
|
|
33
|
+
The catalog uses this format:
|
|
34
|
+
|
|
35
|
+
```
|
|
36
|
+
module,skill,display-name,menu-code,description,action,args,phase,preceded-by,followed-by,required,output-location,outputs
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
**Phases** determine the high-level flow:
|
|
40
|
+
- `anytime` โ available regardless of workflow state
|
|
41
|
+
- Numbered phases (`1-analysis`, `2-planning`, etc.) flow in order; naming varies by module
|
|
42
|
+
|
|
43
|
+
**Sequencing** determines recommended ordering within and across phases (these are soft suggestions, not hard gates โ see `required` for gating):
|
|
44
|
+
- `preceded-by` โ skills that should ideally complete before this one
|
|
45
|
+
- `followed-by` โ skills that should ideally run after this one
|
|
46
|
+
- Format: `skill-name` for single-action skills, `skill-name:action` for multi-action skills
|
|
47
|
+
|
|
48
|
+
**Required gates**:
|
|
49
|
+
- `required=true` items must complete before the user can meaningfully proceed to later phases
|
|
50
|
+
- A phase with no required items is entirely optional โ recommend it but be clear about what's actually required next
|
|
51
|
+
|
|
52
|
+
**Completion detection**:
|
|
53
|
+
- Search resolved output paths for `outputs` patterns
|
|
54
|
+
- Fuzzy-match found files to catalog rows
|
|
55
|
+
- User may also state completion explicitly, or it may be evident from the current conversation
|
|
56
|
+
|
|
57
|
+
**Descriptions carry routing context** โ some contain cycle info and alternate paths (e.g., "back to DS if fixes needed"). Read them as navigation hints, not just display text.
|
|
58
|
+
|
|
59
|
+
## Response Format
|
|
60
|
+
|
|
61
|
+
For each recommended item, present:
|
|
62
|
+
- `[menu-code]` **Display name** โ e.g., "[PR] PRD"
|
|
63
|
+
- Skill name in backticks โ e.g., `bmad-prd`
|
|
64
|
+
- For multi-action skills: action invocation context โ e.g., "tech-writer lets create a mermaid diagram!"
|
|
65
|
+
- Description if present in CSV; otherwise your existing knowledge of the skill suffices
|
|
66
|
+
- Args if available
|
|
67
|
+
|
|
68
|
+
**Ordering**: Show optional items first, then the next required item. Make it clear which is which.
|
|
69
|
+
|
|
70
|
+
## Constraints
|
|
71
|
+
|
|
72
|
+
- Present all output in `{communication_language}`
|
|
73
|
+
- Recommend running each skill in a **fresh context window**
|
|
74
|
+
- Match the user's tone โ conversational when they're casual, structured when they want specifics
|
|
75
|
+
- If the active module is ambiguous, retrieve all meta rows remote sources to find relevant info also to help answer their question
|