Skip to content

Commit ee89ef0

Browse files
Brian MadisonBrian Madison
authored andcommitted
docs: clarify module requirements (no package.json needed)
- Modules only require module.yaml to function - module-help.csv is optional but highly suggested for BMad help system - package.json is only needed for npm publishing, not module functionality - Add note about future auto-generation of module-help.csv from metadata - Update all module structure examples to clarify optional vs required files
1 parent 4731aff commit ee89ef0

4 files changed

Lines changed: 56 additions & 13 deletions

File tree

docs/explanation/module-building-architecture.md

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,18 +58,23 @@ The brief is exploratory and creative. You're discovering what your module shoul
5858
your-module/
5959
├── src/
6060
│ ├── module.yaml # Module metadata and config
61-
│ ├── module-help.csv # Feature registry (auto-generated)
61+
│ ├── module-help.csv # Feature registry (optional but powerful)
6262
│ ├── agents/ # Agent directory
6363
│ │ └── your-agent.agent.yaml # Agent SPEC files (stubs)
6464
│ ├── workflows/ # Workflow directory
6565
│ │ └── your-workflow/ # Workflow SPEC files (stubs)
6666
│ │ └── workflow.md
6767
│ └── _module-installer/ # Custom install prompts (if needed)
68-
├── package.json # NPM package config
6968
├── README.md # Documentation template
7069
└── TODO.md # Implementation checklist
7170
```
7271

72+
For npm publishing, add:
73+
```
74+
├── package.json # NPM package config (publishing only)
75+
└── .npmignore # Excludes dev files from npm package
76+
```
77+
7378
**What these SPEC files contain:**
7479
- **Agent specs** — Persona definitions (name, role, voice) as references for workflows
7580
- **Workflow specs** — Outline of steps, goals, structure (not finished workflows)
@@ -157,11 +162,16 @@ wedding-planner/
157162
│ │ │ └── workflow.md # SPEC
158163
│ │ └── day-of-schedule/
159164
│ │ └── workflow.md # SPEC
160-
├── package.json
161165
├── README.md
162166
└── TODO.md
163167
```
164168

169+
For npm publishing, add:
170+
```
171+
├── package.json
172+
└── .npmignore
173+
```
174+
165175
**What the SPEC files contain:**
166176

167177
`budget-specialist.agent.yaml` (spec):
@@ -239,7 +249,7 @@ After Phase 3, your module is complete and functional:
239249
wedding-planner/
240250
├── src/
241251
│ ├── module.yaml # ✅ Complete
242-
│ ├── module-help.csv # ✅ Complete
252+
│ ├── module-help.csv # ✅ Complete (optional but powerful)
243253
│ ├── agents/
244254
│ │ ├── budget-specialist.agent.yaml # ✅ Built by Bond
245255
│ │ ├── vendor-coordinator.agent.yaml # ✅ Built by Bond
@@ -248,11 +258,16 @@ wedding-planner/
248258
│ │ ├── budget-workshop/ # ✅ Built by Wendy
249259
│ │ ├── vendor-vetting/ # ✅ Built by Wendy
250260
│ │ └── day-of-schedule/ # ✅ Built by Wendy
251-
├── package.json # ✅ Complete
252261
├── README.md # ✅ Complete
253262
└── TODO.md # ✅ All items checked
254263
```
255264

265+
For npm publishing, add:
266+
```
267+
├── package.json # For npm distribution
268+
└── .npmignore
269+
```
270+
256271
## Why This Architecture Works
257272

258273
| Benefit | Explanation |

docs/how-to/validate-agents-and-workflows.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,10 +174,10 @@ Use Morgan's validation workflow:
174174
| Category | Checks |
175175
|----------|--------|
176176
| **module.yaml** | Metadata, install questions, config valid |
177+
| **module-help.csv** | Proper CSV format and required columns (if present) |
177178
| **Structure** | Agents, workflows, tools folders present |
178179
| **Agents** | All agent files valid |
179180
| **Workflows** | All workflow files valid |
180-
| **Package** | package.json configured correctly |
181181

182182
## Common Validation Issues
183183

docs/reference/builder-commands.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,10 @@ Validates a module.
193193

194194
**Checks:**
195195
- `module.yaml` validity
196+
- `module-help.csv` format (if present)
196197
- Folder structure
197198
- Agent file compliance
198199
- Workflow file compliance
199-
- `package.json` configuration
200200

201201
## Command Quick Reference
202202

docs/tutorials/create-your-first-module.md

Lines changed: 34 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ This tutorial uses the **BMad Builder (BMB)** module. Make sure you have BMad in
1313
- What a BMad module is and what it contains
1414
- How to create a module brief with Morgan (module-builder)
1515
- How to build a complete module from your brief
16-
- How to configure module.yaml and package.json
16+
- How to configure module.yaml and module-help.csv
1717
- How to publish your module to npm
1818

1919
:::note[Prerequisites]
@@ -39,11 +39,16 @@ Every BMad module follows a standard structure:
3939
your-module/
4040
├── src/
4141
│ ├── module.yaml # Module metadata and install config
42+
│ ├── module-help.csv # Feature registry for BMad help system
4243
│ ├── agents/ # Agent definitions (.agent.yaml)
4344
│ ├── workflows/ # Workflow files
4445
│ └── tools/ # Small reusable tools
45-
├── package.json # NPM package info
4646
├── README.md # Module documentation
47+
```
48+
49+
For npm publishing, add:
50+
```
51+
├── package.json # NPM package info (for publishing only)
4752
└── .npmignore # Excludes dev files from npm package
4853
```
4954

@@ -52,10 +57,11 @@ your-module/
5257
| Component | Purpose | Required |
5358
|-----------|---------|----------|
5459
| **module.yaml** | Metadata, install questions, config | ✅ Yes |
55-
| **package.json** | NPM publishing, version info | ✅ Yes |
60+
| **module-help.csv** | Feature registry for BMad help system | ⭐ Highly suggested |
5661
| **Agents** | AI assistants with specific roles | ⚪ Optional |
5762
| **Workflows** | Step-by-step processes | ⚪ Optional |
5863
| **Tools** | Reusable prompt files | ⚪ Optional |
64+
| **package.json** | NPM publishing, version info | 📦 For publishing only |
5965

6066
## Why Build Modules?
6167

@@ -177,9 +183,26 @@ config:
177183
# Add your config keys here
178184
```
179185

180-
### package.json
186+
### module-help.csv (Optional but Powerful)
187+
188+
The `module-help.csv` file registers your module's agents and workflows with BMad's intelligent help system. This enables contextual recommendations and smart workflow chaining.
181189

182-
Configure `package.json` for npm publishing:
190+
:::tip[Why module-help.csv Matters]
191+
The BMad help system uses this file to suggest the right workflows at the right time. Without it, your module's features remain hidden. With it, they become part of the intelligent BMad ecosystem.
192+
:::
193+
194+
```csv
195+
module,phase,name,code,sequence,workflow-file,command,required,agent,options,description,output-location,outputs
196+
your-module,discovery,"Your Workflow Name",your-workflow,10,workflows/your-workflow/workflow.md,your-workflow,false,workflow-builder,,"Brief description of what this workflow does",_your-module-output/,
197+
```
198+
199+
:::note[Future Changes]
200+
In a future release, `module-help.csv` will be auto-generated from workflow and agent metadata. For now, it's the manual way to tap into the power of the BMad help system.
201+
:::
202+
203+
### package.json (For npm Publishing Only)
204+
205+
If you plan to publish your module to npm, create `package.json`:
183206

184207
```json
185208
{
@@ -196,6 +219,10 @@ Configure `package.json` for npm publishing:
196219
Use scoped naming (`@username/module-name` or `@bmad-code-org/` for official modules).
197220
:::
198221

222+
:::note[Local Modules Don't Need package.json]
223+
If you're only using your module locally or sharing it directly (folder, git repo), you can skip `package.json` entirely. It's only required for npm publishing.
224+
:::
225+
199226
## Step 4: Implement Your Agents and Workflows
200227

201228
Morgan created spec files during the build step. Now implement your agents and workflows:
@@ -218,9 +245,10 @@ Before publishing, validate your module:
218245

219246
Morgan checks:
220247
- `module.yaml` is complete and valid
248+
- `module-help.csv` is properly formatted (if present)
221249
- Agent files follow BMad standards
222250
- Workflows have proper structure
223-
- Package.json is configured correctly
251+
- Folder structure is correct
224252

225253
Fix any issues Morgan identifies, then re-validate.
226254

0 commit comments

Comments
 (0)