Compare commits

...

5 Commits

Author SHA1 Message Date
Brian Madison b8b79b6dd0 refactor(bmad-prd): tighten Research subagents beat 2026-05-16 19:06:13 -05:00
Brian Madison 943315714e fix(bmad-prd, bmad-product-brief): drop phantom v2 callout, add Fast/Coaching to brief
- Drop `[v2 — out of MVP]` from PRD validation rubric Dimension 5. It was
  flagged for absence but never instructed for use anywhere — the template uses
  `[NOTE FOR PM]` for v2/v3 deferrals, which is the de-facto convention.
- Add Fast path / Coaching path working-mode choice to brief Discovery so the
  "I'm pitching tomorrow" user has an express option. Note that the opener's
  pressure-calibration philosophy primarily shapes Coaching path; Fast path
  swaps pushback for [ASSUMPTION] tags the user can correct in review.
2026-05-16 19:05:39 -05:00
Brian 9231d72324
Merge branch 'main' into prd-flow 2026-05-16 18:30:55 -05:00
Davor Racic 0f852a38ac
feat(prompts): add directory prompt with updated Clack runtime (#2387)
* chore(deps): update @clack/core and @clack/prompts to latest versions and adjust Node.js engine requirement

* feat(prompts): add directory prompt with autocomplete and create-directory support

* chore(docs): update Node.js version requirement to 20.12+ across multiple documentation files

* fix(prompts): code review fixes
2026-05-16 18:30:25 -05:00
Brian Madison 8d4544a58a refactor(bmad-prd, bmad-product-brief): bring skills to parity, default-on web research
Cross-skill consistency fixes:
- Brief renames {workflow.output_dir} -> {workflow.brief_output_path} and
  {workflow.output_folder_name} -> {workflow.run_folder_pattern} to match PRD's
  naming pattern.
- Decision-log filename unified on .decision-log.md (dotfile convention) across
  both skills.
- Brief picks up PRD's fallback on customization-resolve failure (read TOML
  directly instead of halt).
- Brief picks up PRD's persistent_facts default that auto-loads
  project-context.md.
- Brief greeting now enforces {communication_language} for the entire run, not
  just the greeting.

PRD additions, propagated from brief:
- File-roles paragraph in Conventions (boundary rules for .decision-log.md vs
  addendum.md; capture during conversation, not at finalize; audit/override
  never goes in addendum).
- Greeting now tells the user they can invoke bmad-party-mode or
  bmad-advanced-elicitation at any point.
- Create intent now writes prd.md with status: draft and creates the
  .decision-log.md skeleton at workspace init.
- Resume-check on activation: scans prd_output_path for prior in-progress runs
  (status not final) and offers to resume.
- Finalize Close sets status: final + updated date so resume-check can
  distinguish finalized from in-progress.
- Stakes-calibrated length guidance in PRD Discipline.

Web research, default-on for any scope:
- Reframed external_sources lines in both skills to distinguish org-configured
  registry (internal tools) from generic web research; both fire on the same
  triggers.
- New Research subagents (default) beat in PRD Discovery: spawn web-research
  subagents to ground the picture; AI especially where training data ages by
  the week. Subagent searches; parent receives a digest. Deep work routes to
  bmad-market-research / bmad-domain-research / bmad-technical-research.
- Brief Discovery picks up the same posture in lighter form.
2026-05-16 18:25:14 -05:00
31 changed files with 307 additions and 99 deletions

View File

@ -2,7 +2,7 @@
[![Version](https://img.shields.io/npm/v/bmad-method?color=blue&label=version)](https://www.npmjs.com/package/bmad-method)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
[![Node.js Version](https://img.shields.io/badge/node-%3E%3D20.0.0-brightgreen)](https://nodejs.org)
[![Node.js Version](https://img.shields.io/badge/node-%3E%3D20.12.0-brightgreen)](https://nodejs.org)
[![Python Version](https://img.shields.io/badge/python-%3E%3D3.10-blue?logo=python&logoColor=white)](https://www.python.org)
[![uv](https://img.shields.io/badge/uv-package%20manager-blueviolet?logo=uv)](https://docs.astral.sh/uv/)
[![Discord](https://img.shields.io/badge/Discord-Join%20Community-7289da?logo=discord&logoColor=white)](https://discord.gg/gk8jAdXWmj)
@ -36,7 +36,7 @@ Traditional AI tools do the thinking for you, producing average results. BMad ag
## Quick Start
**Prerequisites**: [Node.js](https://nodejs.org) v20+ · [Python](https://www.python.org) 3.10+ · [uv](https://docs.astral.sh/uv/)
**Prerequisites**: [Node.js](https://nodejs.org) v20.12+ · [Python](https://www.python.org) 3.10+ · [uv](https://docs.astral.sh/uv/)
```bash
npx bmad-method install
@ -82,11 +82,11 @@ BMad Method extends with official modules for specialized domains. Available dur
[BMad Method Docs Site](https://docs.bmad-method.org) — Tutorials, guides, concepts, and reference
**Quick links:**
- [Getting Started Tutorial](https://docs.bmad-method.org/tutorials/getting-started/)
- [Upgrading from Previous Versions](https://docs.bmad-method.org/how-to/upgrade-to-v6/)
- [Test Architect Documentation](https://bmad-code-org.github.io/bmad-method-test-architecture-enterprise/)
## Community
- [Discord](https://discord.gg/gk8jAdXWmj) — Get help, share ideas, collaborate

View File

@ -16,7 +16,7 @@ Pokud chcete použít neinteraktivní instalátor a zadat všechny možnosti na
- Aktualizujete stávající instalaci BMad
:::note[Předpoklady]
- **Node.js** 20+ (vyžadováno pro instalátor)
- **Node.js** 20.12+ (vyžadováno pro instalátor)
- **Git** (doporučeno)
- **AI nástroj** (Claude Code, Cursor nebo podobný)
:::

View File

@ -15,7 +15,7 @@ Použijte příznaky příkazové řádky k neinteraktivní instalaci BMad. To j
- Rychlé instalace se známými konfiguracemi
:::note[Předpoklady]
Vyžaduje [Node.js](https://nodejs.org) v20+ a `npx` (součástí npm).
Vyžaduje [Node.js](https://nodejs.org) v20.12+ a `npx` (součástí npm).
:::
## Dostupné příznaky

View File

@ -14,7 +14,7 @@ Použijte instalátor BMad pro upgrade z v4 na v6, který zahrnuje automatickou
- Máte existující plánovací artefakty k zachování
:::note[Předpoklady]
- Node.js 20+
- Node.js 20.12+
- Existující instalace BMad v4
:::

View File

@ -14,7 +14,7 @@ Vytvářejte software rychleji pomocí pracovních postupů řízených AI se sp
- Efektivně používat agenty a pracovní postupy
:::note[Předpoklady]
- **Node.js 20+** — Vyžadováno pro instalátor
- **Node.js 20.12+** — Vyžadováno pro instalátor
- **Git** — Doporučeno pro správu verzí
- **AI-powered IDE** — Claude Code, Cursor nebo podobné
- **Nápad na projekt** — I jednoduchý stačí pro učení

View File

@ -16,7 +16,7 @@ Si vous souhaitez utiliser un installateur non interactif et fournir toutes les
- Mettre à jour une installation BMad existante
:::note[Prérequis]
- **Node.js** 20+ (requis pour l'installateur)
- **Node.js** 20.12+ (requis pour l'installateur)
- **Git** (recommandé)
- **Outil d'IA** (Claude Code, Cursor, ou similaire)
:::

View File

@ -15,7 +15,7 @@ Utilisez les options de ligne de commande pour installer BMad de manière non-in
- Installations rapides avec des configurations connues
:::note[Prérequis]
Nécessite [Node.js](https://nodejs.org) v20+ et `npx` (inclus avec npm).
Nécessite [Node.js](https://nodejs.org) v20.12+ et `npx` (inclus avec npm).
:::
## Options disponibles

View File

@ -14,7 +14,7 @@ Utilisez l'installateur BMad pour passer de la v4 à la v6, qui inclut une déte
- Vous avez des artefacts de planification existants à préserver
:::note[Prérequis]
- Node.js 20+
- Node.js 20.12+
- Installation BMad v4 existante
:::

View File

@ -14,7 +14,7 @@ Construisez des logiciels plus rapidement en utilisant des workflows propulsés
- Utiliser efficacement les agents et les workflows
:::note[Prérequis]
- **Node.js 20+** — Requis pour l'installateur
- **Node.js 20.12+** — Requis pour l'installateur
- **Git** — Recommandé pour le contrôle de version
- **IDE IA** — Claude Code, Cursor, ou similaire
- **Une idée de projet** — Même simple, elle fonctionne pour apprendre

View File

@ -16,7 +16,7 @@ Use `npx bmad-method install` to set up BMad in your project. One command handle
:::note[Prerequisites]
- **Node.js** 20+ (the installer requires it)
- **Node.js** 20.12+ (the installer requires it)
- **Git** (for cloning external modules)
- **An AI tool** such as Claude Code or Cursor (run `npx bmad-method install --list-tools` to see all supported tools)

View File

@ -15,7 +15,7 @@ Use the BMad installer to add modules from the community registry, third-party G
- Installing modules from a private or self-hosted Git server
:::note[Prerequisites]
Requires [Node.js](https://nodejs.org) v20+ and `npx` (included with npm). Custom and community modules can be selected during a fresh install or added to an existing installation.
Requires [Node.js](https://nodejs.org) v20.12+ and `npx` (included with npm). Custom and community modules can be selected during a fresh install or added to an existing installation.
:::
## Community Modules
@ -68,7 +68,7 @@ Select **Yes**, then provide a source:
| Input Type | Example |
| --------------------- | ------------------------------------------------- |
| HTTPS URL (any host) | `https://github.com/org/repo` |
| HTTP URL (any host) | `http://host/org/repo` |
| HTTP URL (any host) | `http://host/org/repo` |
| HTTPS URL with subdir | `https://github.com/org/repo/tree/main/my-module` |
| SSH URL | `git@github.com:org/repo.git` |
| Local path | `/Users/me/projects/my-module` |

View File

@ -15,7 +15,7 @@ Use the BMad installer to upgrade from v4 to v6, which includes automatic detect
:::note[Prerequisites]
- Node.js 20+
- Node.js 20.12+
- Existing BMad v4 installation
:::

View File

@ -1,5 +1,5 @@
---
title: "Getting Started"
title: 'Getting Started'
description: Install BMad and build your first project
---
@ -14,11 +14,12 @@ Build software faster using AI-powered workflows with specialized agents that gu
- Use agents and workflows effectively
:::note[Prerequisites]
- **Node.js 20+** — Required for the installer
- **Node.js 20.12+** — Required for the installer
- **Git** — Recommended for version control
- **AI-powered IDE** — Claude Code, Cursor, or similar
- **A project idea** — Even a simple one works for learning
:::
:::
:::tip[The Easiest Path]
**Install** → `npx bmad-method install`
@ -50,6 +51,7 @@ bmad-help I have an idea for a SaaS product, I already know all the features I w
```
BMad-Help will respond with:
- What's recommended for your situation
- What the first required task is
- What the rest of the process looks like
@ -66,12 +68,12 @@ After installing BMad, invoke the `bmad-help` skill immediately. It will detect
BMad helps you build software through guided workflows with specialized AI agents. The process follows four phases:
| Phase | Name | What Happens |
| ----- | -------------- | --------------------------------------------------- |
| 1 | Analysis | Brainstorming, research, product brief or PRFAQ *(optional)* |
| 2 | Planning | Create requirements (PRD or spec) |
| 3 | Solutioning | Design architecture *(BMad Method/Enterprise only)* |
| 4 | Implementation | Build epic by epic, story by story |
| Phase | Name | What Happens |
| ----- | -------------- | ------------------------------------------------------------ |
| 1 | Analysis | Brainstorming, research, product brief or PRFAQ _(optional)_ |
| 2 | Planning | Create requirements (PRD or spec) |
| 3 | Solutioning | Design architecture _(BMad Method/Enterprise only)_ |
| 4 | Implementation | Build epic by epic, story by story |
**[Open the Workflow Map](../reference/workflow-map.md)** to explore phases, workflows, and context management.
@ -100,6 +102,7 @@ If you want the newest prerelease build instead of the default release channel,
When prompted to select modules, choose **BMad Method**.
The installer creates two folders:
- `_bmad/` — agents, workflows, tasks, and configuration
- `_bmad-output/` — empty for now, but this is where your artifacts will be saved
@ -134,6 +137,7 @@ Create it manually at `_bmad-output/project-context.md` or generate it after arc
### Phase 1: Analysis (Optional)
All workflows in this phase are optional. [**Not sure which to use?**](../explanation/analysis-phase.md)
- **brainstorming** (`bmad-brainstorming`) — Guided ideation
- **research** (`bmad-market-research` / `bmad-domain-research` / `bmad-technical-research`) — Market, domain, and technical research
- **product-brief** (`bmad-product-brief`) — Recommended foundation document when your concept is clear
@ -142,16 +146,19 @@ All workflows in this phase are optional. [**Not sure which to use?**](../explan
### Phase 2: Planning (Required)
**For BMad Method and Enterprise tracks:**
1. Run `bmad-prd` in a new chat — state your intent (Create / Update / Validate) or let the skill ask
2. Output: `prd.md`, `addendum.md`, `decision-log.md`
:::note[`bmad-prd` intents]
- **Create** — coached discovery from scratch; the skill names the workspace folder and guides you to a PRD you're proud of
- **Update** — point it at an existing PRD and a change signal; it surfaces conflicts before applying changes
- **Validate** — critique a finished PRD against a checklist and produce an HTML findings report
:::
:::
**For Quick Flow track:**
- Run `bmad-quick-dev` — it handles planning and implementation in a single workflow, skip to implementation
:::note[UX Design (Optional)]
@ -161,6 +168,7 @@ If your project has a user interface, invoke the **UX-Designer agent** (`bmad-ag
### Phase 3: Solutioning (BMad Method/Enterprise)
**Create Architecture**
1. Invoke the **Architect agent** (`bmad-agent-architect`) in a new chat
2. Run `bmad-create-architecture` (`bmad-create-architecture`)
3. Output: Architecture document with technical decisions
@ -168,14 +176,15 @@ If your project has a user interface, invoke the **UX-Designer agent** (`bmad-ag
**Create Epics and Stories**
:::tip[V6 Improvement]
Epics and stories are now created *after* architecture. This produces better quality stories because architecture decisions (database, API patterns, tech stack) directly affect how work should be broken down.
Epics and stories are now created _after_ architecture. This produces better quality stories because architecture decisions (database, API patterns, tech stack) directly affect how work should be broken down.
:::
1. Invoke the **PM agent** (`bmad-agent-pm`) in a new chat
2. Run `bmad-create-epics-and-stories` (`bmad-create-epics-and-stories`)
3. The workflow uses both PRD and Architecture to create technically-informed stories
**Implementation Readiness Check** *(Highly Recommended)*
**Implementation Readiness Check** _(Highly Recommended)_
1. Invoke the **Architect agent** (`bmad-agent-architect`) in a new chat
2. Run `bmad-check-implementation-readiness` (`bmad-check-implementation-readiness`)
3. Validates cohesion across all planning documents
@ -192,11 +201,11 @@ Invoke the **Developer agent** (`bmad-agent-dev`) and run `bmad-sprint-planning`
For each story, repeat this cycle with fresh chats:
| Step | Agent | Workflow | Command | Purpose |
| ---- | ----- | -------------- | -------------------------- | ---------------------------------- |
| 1 | DEV | `bmad-create-story` | `bmad-create-story` | Create story file from epic |
| 2 | DEV | `bmad-dev-story` | `bmad-dev-story` | Implement the story |
| 3 | DEV | `bmad-code-review` | `bmad-code-review` | Quality validation *(recommended)* |
| Step | Agent | Workflow | Command | Purpose |
| ---- | ----- | ------------------- | ------------------- | ---------------------------------- |
| 1 | DEV | `bmad-create-story` | `bmad-create-story` | Create story file from epic |
| 2 | DEV | `bmad-dev-story` | `bmad-dev-story` | Implement the story |
| 3 | DEV | `bmad-code-review` | `bmad-code-review` | Quality validation _(recommended)_ |
After completing all stories in an epic, invoke the **Developer agent** (`bmad-agent-dev`) and run `bmad-retrospective` (`bmad-retrospective`).
@ -227,18 +236,18 @@ your-project/
## Quick Reference
| Workflow | Command | Agent | Purpose |
| ------------------------------------- | ------------------------------------------ | --------- | ----------------------------------------------- |
| **`bmad-help`** ⭐ | `bmad-help` | Any | **Your intelligent guide — ask anything!** |
| `bmad-prd` | `bmad-prd` | Any | Create, update, or validate a PRD |
| `bmad-create-architecture` | `bmad-create-architecture` | Architect | Create architecture document |
| `bmad-generate-project-context` | `bmad-generate-project-context` | Analyst | Create project context file |
| `bmad-create-epics-and-stories` | `bmad-create-epics-and-stories` | PM | Break down PRD into epics |
| `bmad-check-implementation-readiness` | `bmad-check-implementation-readiness` | Architect | Validate planning cohesion |
| `bmad-sprint-planning` | `bmad-sprint-planning` | DEV | Initialize sprint tracking |
| `bmad-create-story` | `bmad-create-story` | DEV | Create a story file |
| `bmad-dev-story` | `bmad-dev-story` | DEV | Implement a story |
| `bmad-code-review` | `bmad-code-review` | DEV | Review implemented code |
| Workflow | Command | Agent | Purpose |
| ------------------------------------- | ------------------------------------- | --------- | ------------------------------------------ |
| **`bmad-help`** ⭐ | `bmad-help` | Any | **Your intelligent guide — ask anything!** |
| `bmad-prd` | `bmad-prd` | Any | Create, update, or validate a PRD |
| `bmad-create-architecture` | `bmad-create-architecture` | Architect | Create architecture document |
| `bmad-generate-project-context` | `bmad-generate-project-context` | Analyst | Create project context file |
| `bmad-create-epics-and-stories` | `bmad-create-epics-and-stories` | PM | Break down PRD into epics |
| `bmad-check-implementation-readiness` | `bmad-check-implementation-readiness` | Architect | Validate planning cohesion |
| `bmad-sprint-planning` | `bmad-sprint-planning` | DEV | Initialize sprint tracking |
| `bmad-create-story` | `bmad-create-story` | DEV | Create a story file |
| `bmad-dev-story` | `bmad-dev-story` | DEV | Implement a story |
| `bmad-code-review` | `bmad-code-review` | DEV | Review implemented code |
## Common Questions
@ -258,6 +267,7 @@ Not strictly. Once you learn the flow, you can run workflows directly using the
:::tip[First Stop: BMad-Help]
**Invoke `bmad-help` anytime** — it's the fastest way to get unstuck. Ask it anything:
- "What should I do after installing?"
- "I'm stuck on workflow X"
- "What are my options for Y?"
@ -272,10 +282,11 @@ BMad-Help inspects your project, detects what you've completed, and tells you ex
## Key Takeaways
:::tip[Remember These]
- **Start with `bmad-help`** — Your intelligent guide that knows your project and options
- **Always use fresh chats** — Start a new chat for each workflow
- **Track matters** — Quick Flow uses `bmad-quick-dev`; Method/Enterprise need PRD and architecture
- **BMad-Help runs automatically** — Every workflow ends with guidance on what's next
:::
:::
Ready to start? Install BMad, invoke `bmad-help`, and let your intelligent guide lead the way.

View File

@ -16,7 +16,7 @@ Nếu bạn muốn dùng trình cài đặt không tương tác và cung cấp t
- Cập nhật bản cài đặt BMad hiện tại
:::note[Điều kiện tiên quyết]
- **Node.js** 20+ (bắt buộc cho trình cài đặt)
- **Node.js** 20.12+ (bắt buộc cho trình cài đặt)
- **Git** (khuyến nghị)
- **Công cụ AI** (Claude Code, Cursor, hoặc tương tự)
:::

View File

@ -15,7 +15,7 @@ Sử dụng trình cài đặt BMad để thêm module từ kho cộng đồng (
- Cài module từ máy chủ Git riêng tư hoặc tự host
:::note[Điều kiện tiên quyết]
Yêu cầu [Node.js](https://nodejs.org) v20+ và `npx` đi kèm npm. Bạn có thể chọn module tùy chỉnh và module cộng đồng trong lúc cài mới, hoặc thêm chúng vào một bản cài hiện có.
Yêu cầu [Node.js](https://nodejs.org) v20.12+ và `npx` đi kèm npm. Bạn có thể chọn module tùy chỉnh và module cộng đồng trong lúc cài mới, hoặc thêm chúng vào một bản cài hiện có.
:::
## Module cộng đồng

View File

@ -15,7 +15,7 @@ Sử dụng các cờ dòng lệnh để cài đặt BMad mà không cần tươ
- Cài đặt nhanh với cấu hình đã biết trước
:::note[Điều kiện tiên quyết]
Yêu cầu [Node.js](https://nodejs.org) v20+ và `npx` (đi kèm với npm).
Yêu cầu [Node.js](https://nodejs.org) v20.12+ và `npx` (đi kèm với npm).
:::
## Các cờ khả dụng

View File

@ -14,7 +14,7 @@ Sử dụng trình cài đặt BMad để nâng cấp từ v4 lên v6, bao gồm
- Bạn có các planning artifact hiện có cần giữ lại
:::note[Điều kiện tiên quyết]
- Node.js 20+
- Node.js 20.12+
- Bản cài đặt BMad v4 hiện có
:::

View File

@ -14,7 +14,7 @@ Xây dựng phần mềm nhanh hơn bằng các workflow vận hành bởi AI, v
- Sử dụng agent và workflow hiệu quả
:::note[Điều kiện tiên quyết]
- **Node.js 20+** — Bắt buộc cho trình cài đặt
- **Node.js 20.12+** — Bắt buộc cho trình cài đặt
- **Git** — Khuyến nghị để quản lý phiên bản
- **IDE có AI** — Claude Code, Cursor hoặc công cụ tương tự
- **Một ý tưởng dự án** — Chỉ cần đơn giản cũng đủ để học

View File

@ -16,7 +16,7 @@ sidebar:
- 更新现有的 BMad 安装
:::note[前置条件]
- **Node.js** 20+(安装程序必需)
- **Node.js** 20.12+(安装程序必需)
- **Git**(推荐)
- **AI 工具**Claude Code、Cursor 或类似工具)
:::

View File

@ -15,7 +15,7 @@ sidebar:
- 从私有或自托管 Git 服务器安装模块
:::note[前置条件]
需要 [Node.js](https://nodejs.org) v20+ 和 `npx`npm 自带)。自定义和社区模块可以在全新安装时选择,也可以添加到现有安装中。
需要 [Node.js](https://nodejs.org) v20.12+ 和 `npx`npm 自带)。自定义和社区模块可以在全新安装时选择,也可以添加到现有安装中。
:::
## 社区模块

View File

@ -15,7 +15,7 @@ sidebar:
- 使用已知配置的快速安装
:::note[前置条件]
需要 [Node.js](https://nodejs.org) v20+ 和 `npx`(随 npm 附带)。
需要 [Node.js](https://nodejs.org) v20.12+ 和 `npx`(随 npm 附带)。
:::
## 可用参数Flags

View File

@ -14,7 +14,7 @@ sidebar:
- 你有要保留的规划产物或进行中的开发工作
:::note[前置条件]
- Node.js 20+
- Node.js 20.12+
- 现有 BMad v4 安装
:::

View File

@ -14,7 +14,7 @@ description: 安装 BMad 并构建你的第一个项目
- 有效使用智能体和工作流
:::note[前置条件]
- **Node.js 20+** — 安装程序必需
- **Node.js 20.12+** — 安装程序必需
- **Git** — 推荐用于版本控制
- **AI 驱动的 IDE** — Claude Code、Cursor 或类似工具
- **一个项目想法** — 即使是简单的想法也可以用于学习

55
package-lock.json generated
View File

@ -9,8 +9,8 @@
"version": "6.6.0",
"license": "MIT",
"dependencies": {
"@clack/core": "^1.0.0",
"@clack/prompts": "^1.0.0",
"@clack/core": "^1.3.1",
"@clack/prompts": "^1.4.0",
"@kayvan/markdown-tree-parser": "^1.6.1",
"chalk": "^4.1.2",
"commander": "^14.0.0",
@ -50,7 +50,7 @@
"yaml-lint": "^1.7.0"
},
"engines": {
"node": ">=20.0.0"
"node": ">=20.12.0"
}
},
"node_modules/@astrojs/compiler": {
@ -752,24 +752,31 @@
}
},
"node_modules/@clack/core": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@clack/core/-/core-1.0.0.tgz",
"integrity": "sha512-Orf9Ltr5NeiEuVJS8Rk2XTw3IxNC2Bic3ash7GgYeA8LJ/zmSNpSQ/m5UAhe03lA6KFgklzZ5KTHs4OAMA/SAQ==",
"version": "1.3.1",
"resolved": "https://registry.npmjs.org/@clack/core/-/core-1.3.1.tgz",
"integrity": "sha512-fT1qHVGAag4IEkrupZ6lRRbNCs1vS9P01KB/sG8zKgvUztbYtFBtQpjSITNwooDZ83tpsPzP0mRNs1/KVszCRA==",
"license": "MIT",
"dependencies": {
"picocolors": "^1.0.0",
"fast-wrap-ansi": "^0.2.0",
"sisteransi": "^1.0.5"
},
"engines": {
"node": ">= 20.12.0"
}
},
"node_modules/@clack/prompts": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-1.0.0.tgz",
"integrity": "sha512-rWPXg9UaCFqErJVQ+MecOaWsozjaxol4yjnmYcGNipAWzdaWa2x+VJmKfGq7L0APwBohQOYdHC+9RO4qRXej+A==",
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/@clack/prompts/-/prompts-1.4.0.tgz",
"integrity": "sha512-S0My7XPGIgpRWMDG8uRqalbgT+a6FmCUdOW+HaIOVVpUPHOb7RrpvjTjiODadKp06fsrVDJZlIzc6yCTp4AnxA==",
"license": "MIT",
"dependencies": {
"@clack/core": "1.0.0",
"picocolors": "^1.0.0",
"@clack/core": "1.3.1",
"fast-string-width": "^3.0.2",
"fast-wrap-ansi": "^0.2.0",
"sisteransi": "^1.0.5"
},
"engines": {
"node": ">= 20.12.0"
}
},
"node_modules/@ctrl/tinycolor": {
@ -7332,6 +7339,30 @@
"dev": true,
"license": "MIT"
},
"node_modules/fast-string-truncated-width": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/fast-string-truncated-width/-/fast-string-truncated-width-3.0.3.tgz",
"integrity": "sha512-0jjjIEL6+0jag3l2XWWizO64/aZVtpiGE3t0Zgqxv0DPuxiMjvB3M24fCyhZUO4KomJQPj3LTSUnDP3GpdwC0g==",
"license": "MIT"
},
"node_modules/fast-string-width": {
"version": "3.0.2",
"resolved": "https://registry.npmjs.org/fast-string-width/-/fast-string-width-3.0.2.tgz",
"integrity": "sha512-gX8LrtNEI5hq8DVUfRQMbr5lpaS4nMIWV+7XEbXk2b8kiQIizgnlr12B4dA3ZEx3308ze0O4Q1R+cHts8kyUJg==",
"license": "MIT",
"dependencies": {
"fast-string-truncated-width": "^3.0.2"
}
},
"node_modules/fast-wrap-ansi": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/fast-wrap-ansi/-/fast-wrap-ansi-0.2.0.tgz",
"integrity": "sha512-rLV8JHxTyhVmFYhBJuMujcrHqOT2cnO5Zxj37qROj23CP39GXubJRBUFF0z8KFK77Uc0SukZUf7JZhsVEQ6n8w==",
"license": "MIT",
"dependencies": {
"fast-string-width": "^3.0.2"
}
},
"node_modules/fastq": {
"version": "1.20.1",
"resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.1.tgz",

View File

@ -66,8 +66,8 @@
]
},
"dependencies": {
"@clack/core": "^1.0.0",
"@clack/prompts": "^1.0.0",
"@clack/core": "^1.3.1",
"@clack/prompts": "^1.4.0",
"@kayvan/markdown-tree-parser": "^1.6.1",
"chalk": "^4.1.2",
"commander": "^14.0.0",
@ -103,7 +103,7 @@
"yaml-lint": "^1.7.0"
},
"engines": {
"node": ">=20.0.0"
"node": ">=20.12.0"
},
"publishConfig": {
"access": "public"

View File

@ -15,21 +15,21 @@ At the opening greeting, let the user know they can invoke `bmad-party-mode` for
## On Activation
1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, surface the diagnostic and halt.
1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults.
2. Execute each entry in `{workflow.activation_steps_prepend}` in order.
3. Treat every entry in `{workflow.persistent_facts}` as foundational context for the rest of the run. Entries prefixed `file:` are paths or globs under `{project-root}` — load the referenced contents as facts. All other entries are facts verbatim.
4. Note `{workflow.external_sources}` as a registry of external systems available for consultation when the conversation surfaces a relevant need — knowledge bases, internal MCP tools, reference systems. Do not query preemptively; consult each only when its directive matches the moment. If a named tool is unavailable at runtime, fall back to standard behavior and note the gap when relevant.
4. `{workflow.external_sources}` is an org-configured registry of internal tools (knowledge bases, MCP tools); consult them alongside generic web research on the same triggers in `## Discovery`, org tools preferred when their directive matches. If a named tool is unavailable at runtime, fall back to standard behavior and note the gap when relevant.
5. Load `{project-root}/_bmad/bmm/config.yaml` (and `config.user.yaml` if present). Resolve `{user_name}`, `{communication_language}`, `{document_output_language}`, `{planning_artifacts}`, `{project_name}`, `{date}`.
6. Greet `{user_name}` in `{communication_language}`. Detect intent (create / update / validate). If interactive and intent is unclear, ask; for headless behavior see `## Headless Mode`.
6. Greet `{user_name}` in `{communication_language}` — and stay in `{communication_language}` for every turn for the entire run, not just the greeting. Detect intent (create / update / validate). If interactive and intent is unclear, ask; for headless behavior see `## Headless Mode`.
7. Execute each entry in `{workflow.activation_steps_append}` in order.
## Intent Operating Modes
**Create.** A brief the user is proud of, that meets their needs, drawn out through real conversation — do not assume: instead converse and understand, and then help craft the best product brief for their needs. Begin in `## Discovery` before drafting; the brief comes after the picture is on the table. Shape follows the product and need. Treat `{workflow.brief_template}` as a starting structure, not a contract: drop sections that do not earn their place, add sections the product needs, reorder freely - create sections for specialized domains or concerns also as needed. The brief serves the product's story, not the template's shape. Bind `{doc_workspace}` to a fresh folder at `{workflow.output_dir}/{workflow.output_folder_name}/` and write `brief.md` there with YAML frontmatter (title, status, created, updated). For Update and Validate, `{doc_workspace}` is the existing folder of the brief being targeted.
**Create.** A brief the user is proud of, that meets their needs, drawn out through real conversation — do not assume: instead converse and understand, and then help craft the best product brief for their needs. Begin in `## Discovery` before drafting; the brief comes after the picture is on the table. Shape follows the product and need. Treat `{workflow.brief_template}` as a starting structure, not a contract: drop sections that do not earn their place, add sections the product needs, reorder freely - create sections for specialized domains or concerns also as needed. The brief serves the product's story, not the template's shape. Bind `{doc_workspace}` to a fresh folder at `{workflow.brief_output_path}/{workflow.run_folder_pattern}/` and write `brief.md` there with YAML frontmatter (title, status, created, updated). For Update and Validate, `{doc_workspace}` is the existing folder of the brief being targeted.
**Update.** Reconcile an existing brief with a change signal. Before proposing changes, read the brief, addendum, `decision-log.md`, and original inputs — and run the `## Discovery` posture against the change signal (a patch applied without context becomes drift). Surface conflicts with prior decisions before changing. Headless override: log the reversal to `decision-log.md`, then apply; halt `blocked` if intent is ambiguous. If the change is fundamental, offer Create instead of patching.
**Update.** Reconcile an existing brief with a change signal. Before proposing changes, read the brief, addendum, `.decision-log.md`, and original inputs — and run the `## Discovery` posture against the change signal (a patch applied without context becomes drift). Surface conflicts with prior decisions before changing. Headless override: log the reversal to `.decision-log.md`, then apply; halt `blocked` if intent is ambiguous. If the change is fundamental, offer Create instead of patching.
**Validate.** Honest critique against the brief's own purpose. Read the brief, the addendum if present, `decision-log.md`, and any original inputs first — a validation that ignores prior decisions, rejected ideas, or context the user supplied is shallow. Cite specific lines. Caveat what cannot be evaluated. Return inline — no separate file unless asked. Always offer to roll findings into an Update, even in headless mode — include `"offer_to_update": true` in the JSON status block.
**Validate.** Honest critique against the brief's own purpose. Read the brief, the addendum if present, `.decision-log.md`, and any original inputs first — a validation that ignores prior decisions, rejected ideas, or context the user supplied is shallow. Cite specific lines. Caveat what cannot be evaluated. Return inline — no separate file unless asked. Always offer to roll findings into an Update, even in headless mode — include `"offer_to_update": true` in the JSON status block.
## Headless Mode
@ -41,7 +41,7 @@ When invoked headless, do not ask. Complete the intent using what is provided, w
"intent": "create",
"brief": "{doc_workspace}/brief.md",
"addendum": "{doc_workspace}/addendum.md",
"decision_log": "{doc_workspace}/decision-log.md",
"decision_log": "{doc_workspace}/.decision-log.md",
"open_questions": [],
"external_handoffs": [
{"directive": "Confluence upload", "tool": "corp:confluence_upload", "url": "https://confluence.corp/PROD/123", "status": "ok"}
@ -61,20 +61,27 @@ Omit keys for artifacts that were not produced.
## Discovery
Conversationally surface what the user brings, why this brief exists, and the domain — echo back how each shapes your approach. Open with space for the full picture: invite a brain dump and ask up front for any source material they already have (memo, deck, transcript, prior brief, slack thread). Read what exists first; ask only what is missing. After the dump, a simple "anything else?" often surfaces what they almost forgot. Drill into specifics only after the broad shape is on the table; premature granular questions interrupt the dump and miss the room. Get a read on stakes early (passion project, internal pitch, investor input, public launch), and let that calibrate how hard you push. Suggest research (web, competitive, market) only when the stakes warrant it.
Conversationally surface what the user brings, why this brief exists, and the domain — echo back how each shapes your approach. Open with space for the full picture: invite a brain dump and ask up front for any source material they already have (memo, deck, transcript, prior brief, slack thread). Read what exists first; ask only what is missing. After the dump, a simple "anything else?" often surfaces what they almost forgot. Drill into specifics only after the broad shape is on the table; premature granular questions interrupt the dump and miss the room. Get a read on stakes early (passion project, internal pitch, investor input, public launch), and let that calibrate how hard you push. During the dump, spawn web-research subagents to ground the picture — landscape, comparables, current state — AI especially, where training data ages by the week. Subagent searches; parent gets a digest. Deep work (full market sizing, exhaustive teardowns) → suggest `bmad-market-research` or `bmad-domain-research`.
Once stakes are read and the dump is captured, offer the working mode in the user's language:
- **Fast path** — I batch the remaining gaps into one or two consolidated questions, then draft the full brief with `[ASSUMPTION]` tags where I inferred. You review and we iterate. Best for "I'm pitching tomorrow."
- **Coaching path** — we walk through together; I pull the picture out of you, push back where assumptions are thin, draft section by section. Best for "I want a brief I'm proud of and time isn't the constraint."
The workspace persists; stop and resume freely. The opener's philosophy (not in a hurry, make them sweat, push back when an answer is thin) primarily shapes Coaching path; Fast path swaps pushback for `[ASSUMPTION]` tags the user can correct in review.
## Constraints
- **Right-size to purpose.** A passion project does not need investor-grade rigor. A VC pitch input does. Read the room.
- **Persistence is real-time.** Once Create intent is confirmed, the workspace (run folder, `brief.md` skeleton with `status: draft`, `decision-log.md`) exists on disk and the user knows the path.
- **File roles.** `decision-log.md` is canonical memory and audit trail — every decision, change, and override (including headless overrides) is recorded there as the conversation unfolds. `addendum.md` preserves user-contributed depth that belongs in a downstream document (PRD, architecture, solution design) or earned a place but does not fit the brief (rejected-alternative rationale, options-considered matrices, parked-roadmap context, technical constraints, in-depth personas, sizing data). Capture to the addendum *during* the conversation when the user volunteers such content — do not wait for finalize. Audit and override information never goes in the addendum.
- **Persistence is real-time.** Once Create intent is confirmed, the workspace (run folder, `brief.md` skeleton with `status: draft`, `.decision-log.md`) exists on disk and the user knows the path.
- **File roles.** `.decision-log.md` is canonical memory and audit trail — every decision, change, and override (including headless overrides) is recorded there as the conversation unfolds. `addendum.md` preserves user-contributed depth that belongs in a downstream document (PRD, architecture, solution design) or earned a place but does not fit the brief (rejected-alternative rationale, options-considered matrices, parked-roadmap context, technical constraints, in-depth personas, sizing data). Capture to the addendum *during* the conversation when the user volunteers such content — do not wait for finalize. Audit and override information never goes in the addendum.
- **Continuity across sessions.** If a prior in-progress draft for this project exists, the user is offered to resume.
- **Extract, don't ingest.** Source artifacts (provided by the user or discovered during the run — transcripts, brainstorms, research reports, code, web results, prior briefs) enter the parent conversation as relevance-filtered extracts, not loaded wholesale. Subagents do the extraction against the user's stated focus; the parent context stays lean.
- **Length and coherence.** Aim for 1-2 pages — if it is longer, the detail belongs in the addendum. Structure in service of the product; downstream consumers (PRD workflow, etc.) read this, so coherent shape matters.
## Finalize
1. Decision log audit + addendum review: the user ends this step with an explicit, shared accounting of how the meaningful contents of `decision-log.md` were handled — captured in the brief, captured in `addendum.md` (which may already hold detail captured during the conversation — see `## Constraints` for what belongs there), or set aside as process noise.
1. Decision log audit + addendum review: the user ends this step with an explicit, shared accounting of how the meaningful contents of `.decision-log.md` were handled — captured in the brief, captured in `addendum.md` (which may already hold detail captured during the conversation — see `## Constraints` for what belongs there), or set aside as process noise.
2. Polish: apply each entry in `{workflow.doc_standards}` (a `skill:`, `file:`, or plain-text directive) to `brief.md` (and `addendum.md` if it exists). Run passes as parallel subagents - apply all doc standards to `brief.md` first, then `addendum.md` so we present a high-quality draft for the user to review and finalize.
3. External handoffs: execute each entry in `{workflow.external_handoffs}` to route artifacts beyond local files (Confluence, Notion, ticket systems, etc.) — each directive names the MCP tool and the fields it needs. Invoke the tool, capture any URLs or IDs returned, and surface them in the user message. If a named tool is unavailable, skip that handoff and flag it; local files always exist regardless.
4. Tell the user it is ready: local paths and external destinations (URLs returned from handoffs). Invoke `bmad-help` to suggest what next steps make sense in the bmad method ecosystem.

View File

@ -23,11 +23,15 @@ activation_steps_append = []
# (standards, compliance constraints, stylistic guardrails).
# Each entry is either a literal sentence, a skill prefixed with `skill:`, or a `file:`-prefixed path/glob
# whose contents are loaded as facts.
# Default is empty. Common opt-ins (set in your team/user override TOML):
# "file:{project-root}/_bmad-output/planning-artifacts/project-context.md" # bmad-generate-project-context output
# "skill:acme-co:terms-and-conditions" # a skill that contains some relevant info to the documents that may be generated
# "Elvis has left the building" # generic agent instructions
persistent_facts = []
#
# Default loads project-context.md if bmad-generate-project-context has produced one — this gives
# the facilitator persistent awareness of the project's tech, domain, and constraints without
# re-asking. Common opt-ins (set in team/user override TOML):
# "skill:acme-co:terms-and-conditions" # a skill that contains some relevant info
# "Elvis has left the building" # generic agent instruction
persistent_facts = [
"file:{project-root}/**/project-context.md",
]
# Executed when the workflow completes (after the user has been told the
# brief is ready). Accepts either a string scalar (single instruction)
@ -39,9 +43,10 @@ on_complete = ""
# to enforce a different structure (e.g. regulated-industry, investor-deck).
brief_template = "assets/brief-template.md"
# Run folder location. The brief and optional addendum land inside `{output_dir}/{output_folder_name}/`.
output_dir = "{planning_artifacts}/briefs"
output_folder_name = "brief-{project_name}-{date}"
# Run folder location. The brief and optional addendum land inside `{brief_output_path}/{run_folder_pattern}/`.
# Resume-check scans `{brief_output_path}` for prior unfinished runs.
brief_output_path = "{planning_artifacts}/briefs"
run_folder_pattern = "brief-{project_name}-{date}"
# Document standards applied to human-consumed docs at finalize. Each entry is
# a `skill:`, `file:`, or plain-text directive; the parent LLM applies the

View File

@ -10,20 +10,21 @@ You are a master facilitator and coach helping the user create, edit, or validat
- Bare paths resolve from skill root; `{skill-root}` is this skill's install dir; `{project-root}` is the project working dir.
- `{workflow.<name>}` resolves to fields in `customize.toml`'s `[workflow]` table (overrides win per BMad merge rules).
- `{doc_workspace}` is the bound run folder. `.decision-log.md` is the canonical ledger at its root; `addendum.md` is the optional technical-how sidecar.
- `{doc_workspace}` is the bound run folder.
- **File roles.** `.decision-log.md` is canonical memory and audit trail — every decision, change, and override (including headless overrides) is recorded there as the conversation unfolds. `addendum.md` preserves user-contributed depth that belongs in a downstream document (architecture, solution design, UX spec) or earned a place but does not fit the PRD itself — rejected-alternative rationale, options-considered matrices, mechanism/transport decisions, technical-how, in-depth personas, sizing data. Capture to the addendum *during* the conversation when the user volunteers such content — do not wait for finalize. Audit and override information never goes in the addendum.
## On Activation
1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults.
2. Run `{workflow.activation_steps_prepend}`. Treat `{workflow.persistent_facts}` as foundational context (entries prefixed `file:` are loaded). Use `{workflow.external_sources}` for light, targeted web grounding when it sharpens a load-bearing moment. When deep research would meaningfully help (market sizing, full competitive teardowns, domain landscapes), suggest the user run it first via the relevant research skills, and accept gracefully if they decline to provide.
2. Run `{workflow.activation_steps_prepend}`. Treat `{workflow.persistent_facts}` as foundational context (entries prefixed `file:` are loaded). `{workflow.external_sources}` is an org-configured registry of internal tools (knowledge bases, MCP tools); consult them alongside generic web research on the same triggers, org tools preferred when their directive matches. Research itself fires during Discovery — see **Research subagents**.
3. Load `{project-root}/_bmad/bmm/config.yaml` (+ `config.user.yaml` if present). Resolve `{user_name}`, `{communication_language}`, `{document_output_language}`, `{planning_artifacts}`, `{project_name}`, `{date}`. Missing keys → neutral defaults; never block.
4. If headless, follow `references/headless.md` for the whole run. Otherwise greet the user **by name** using `{user_name}` and **in their language** using `{communication_language}` — and stay in `{communication_language}` for every turn for the entire run, not just the greeting. Then scan for misroute on the first message: if the signal points elsewhere (game → BMad GDS; express build → `bmad-quick-dev`; one-pager → `bmad-product-brief`; vet product idea → `bmad-prfaq`; agent skill or custom agent → `bmad-workflow-builder`), suggest they might want the other options before continuing.
5. Detect intent: **Create** (no PRD), **Update** (existing PRD), **Validate** (critique only). If ambiguous, ask.
4. If headless, follow `references/headless.md` for the whole run. Otherwise greet the user **by name** using `{user_name}` and **in their language** using `{communication_language}` — and stay in `{communication_language}` for every turn for the entire run, not just the greeting. In the greeting, let the user know that at any point they can invoke `bmad-party-mode` for multi-agent perspectives or `bmad-advanced-elicitation` for deeper exploration on a specific section. Then scan for misroute on the first message: if the signal points elsewhere (game → BMad GDS; express build → `bmad-quick-dev`; one-pager → `bmad-product-brief`; vet product idea → `bmad-prfaq`; agent skill or custom agent → `bmad-workflow-builder`), suggest they might want the other options before continuing.
5. Detect intent: **Create** (no PRD), **Update** (existing PRD), **Validate** (critique only). If ambiguous, ask. For Create intent, before binding a fresh workspace, scan `{workflow.prd_output_path}` for prior in-progress runs (folders matching `{workflow.run_folder_pattern}` whose `prd.md` frontmatter `status` is not `final`); if any exist, offer to resume rather than starting over.
6. Run `{workflow.activation_steps_append}`.
## Intent Modes
**Create.** Bind `{doc_workspace}` to `{workflow.prd_output_path}/{workflow.run_folder_pattern}/`. Write `prd.md` with YAML frontmatter (title, created, updated) and tell the user the path. Run `## Discovery`, then `## Finalize`.
**Create.** Bind `{doc_workspace}` to `{workflow.prd_output_path}/{workflow.run_folder_pattern}/`. Write `prd.md` with YAML frontmatter (title, status, created, updated — initial `status: draft`), and create the `.decision-log.md` skeleton at the workspace root so subsequent decisions land in a known file. Tell the user the path. Run `## Discovery`, then `## Finalize`.
**Update.** Reconcile the PRD with a change signal. Source-extract against PRD, addendum, `.decision-log.md`, and original inputs (extract, don't ingest). If `.decision-log.md` is missing, spawn a one-time bootstrap subagent to reverse-engineer a thin log from the PRD before continuing. Surface conflicts with prior decisions before applying. Then `## Finalize`.
@ -35,6 +36,8 @@ Order: **Brain dump → Stakes calibration → Working mode → mode-scoped work
**Brain dump.** Always the first move, even when the user opens with paragraphs of context (that is intake, not the dump). Ask for verbal context *and* any existing inputs they want you to read — product brief, research, customer transcripts, competitive analysis, prior PRD draft, design docs. Paths or paste; big docs are fine, you will subagent-extract. A simple "anything else?" surfaces what they almost forgot.
**Research subagents (default).** During Discovery, spawn web-research subagents to ground the picture: what exists in the space, how comparables position themselves, current landscape. Subagent does the search; parent receives a digest.
**Elicitation, not direction.** Discovery pulls the user's vision out; it does not insert yours. Open-ended "tell me about X" beats multiple choice. When you find yourself naming wedges, picking MVP cuts, or proposing phases, stop — you have crossed from elicitation into authoring. Hand the pen back. Infer-and-confirm ("I'm assuming X works like Y — right?") is fine; quizzing the user through a tree of LLM-shaped choices is not.
**Stakes calibration.** One short probe before working mode: hobby / internal / launch — enough to calibrate rigor and section depth. Audience, Existing inputs, and Downstream depth fill in inside the chosen mode, not upstream of the choice.
@ -48,7 +51,7 @@ The workspace persists; stop and resume freely.
**Concern scan.** As you read what the user gave you, name the concerns this product actually carries — compliance, integration density, operational SLAs, hardware constraints, public-API contracts, monetization, data governance, whatever applies. The list is open; recognize what's there, do not classify into a fixed shape. These concerns drive which template sections to pull in from the Adapt-In Menu and which to invent when no cluster names them.
**User Journeys are captured, not authored.** When UJs are warranted (consumer / multi-stakeholder B2B / meaningful UX — drop or downscale for internal tooling with a single operator role, regulatory-only updates, hobby/solo, pure technical PRDs), prompt the user to narrate a real session — what the person does, in what order, where it lands — then structure the answer into UJ-N form and confirm. Do not propose UJs for the user to rubber-stamp. Same for phasing: ask "what's the smallest playable version?" and build from there; do not strawman a five-phase cut.
**User Journeys are captured, not authored.** When UJs are warranted (consumer / multi-stakeholder B2B / meaningful UX — drop or downscale for internal tooling with a single operator role, regulatory-only updates, hobby/solo, pure technical PRDs), prompt the user to narrate a real session — what the person does, in what order, where it lands — then structure the answer into UJ-N form and confirm.
## PRD Discipline
@ -56,6 +59,8 @@ The workspace persists; stop and resume freely.
**Extract, don't ingest.** Source documents go to subagents for extraction; the parent assembles from extracts. Only load source documents into the parent context wholesale when no subagents are available.
**Length scales with stakes.** Hobby / solo PRDs aim for about two pages. Internal tools land around five to eight. Launch and chain-top PRDs run as long as their FRs and concerns require. Whatever the length, detail that doesn't earn its place in the PRD's main narrative belongs in `addendum.md` — moving overflow there is correct; padding the PRD to look thorough is not.
## Reviewer Gate
Used by the Validate intent and at Finalize step 3.
@ -78,5 +83,5 @@ Tell the user the sequence in one sentence, then walk it. Polish goes last so it
4. **Triage open items.** All Open Questions, `[ASSUMPTION]` tags, `[NOTE FOR PM]` callouts. Phase-blockers (would make the PRD unsafe for UX/architecture/epics) surfaced one at a time and resolved; non-blockers deferred with owner + revisit condition logged to `.decision-log.md`. If phase-blocker count is high, flag it.
5. **Polish.** Apply `{workflow.doc_standards}` to `prd.md` and `addendum.md` in declared order (structural passes before prose — prose should not polish soon-to-be-cut text). Parallelize across documents, sequential within.
6. **External handoffs.** Execute `{workflow.external_handoffs}`; surface returned URLs/IDs. Skip and flag unavailable tools.
7. **Close.** Record finalization to `.decision-log.md`. Share artifact paths. Common next: `bmad-create-ux-design`, `bmad-create-architecture`, `bmad-create-epics-and-stories`; invoke `bmad-help` for authoritative routing.
7. **Close.** Set `prd.md` frontmatter `status: final` and `updated` to `{date}` so future invocations distinguish this PRD from in-progress drafts. Record finalization to `.decision-log.md`. Share artifact paths. Common next: `bmad-create-ux-design`, `bmad-create-architecture`, `bmad-create-epics-and-stories`; invoke `bmad-help` for authoritative routing.
8. Run `{workflow.on_complete}` if non-empty.

View File

@ -55,7 +55,7 @@ Red flag: a PRD where every choice "balances" everything, every NFR is "importan
Is the content earned, or is it furniture? Distinguish:
- **Persona theater**invented persona detail unmarked as `[ILLUSTRATIVE]`. Personas that don't drive a single decision in the PRD. More than four personas. Personas whose only function is to make the PRD look thorough.
- **Persona theater** — Personas that don't drive a single decision in the PRD. More than four personas. Personas whose only function is to make the PRD look thorough.
- **Innovation theater** — claimed novelty that isn't novel. Differentiation sections written because the template had one, not because Discovery surfaced something.
- **NFR theater** — copied boilerplate ("system must be scalable / secure / reliable") without product-specific thresholds.
- **Vision theater** — a Vision statement that could swap into any PRD in this category without change.
@ -92,7 +92,7 @@ This is the dimension downstream story creation will lean on hardest. Be unforgi
Are omissions explicit, or is the reader meant to infer them?
Look for:
- A Non-Goals section where it would do real work — and `[NON-GOAL for MVP]` / `[v2 — out of MVP]` callouts where omissions could be silently assumed.
- A Non-Goals section where it would do real work — and `[NON-GOAL for MVP]` callouts where omissions could be silently assumed.
- `[ASSUMPTION: …]` tags on inferences the user didn't directly confirm, indexed at the end.
- `[NOTE FOR PM]` callouts at deferred decisions and unresolved tensions.
- De-scoping proposed honestly, not done silently.

View File

@ -10,6 +10,9 @@
let _clack = null;
let _clackCore = null;
let _picocolors = null;
const fs = require('node:fs');
const os = require('node:os');
const path = require('node:path');
/**
* Lazy-load @clack/prompts (ESM module)
@ -575,6 +578,151 @@ async function autocomplete(options) {
return result;
}
function hasPathSeparator(value) {
return value.endsWith('/') || value.endsWith('\\');
}
function expandHome(input) {
if (!input) return input;
if (input === '~') return os.homedir();
if (input.startsWith('~/') || input.startsWith('~\\')) {
return path.join(os.homedir(), input.slice(2));
}
return input;
}
function toDirectoryOption(value, label = value, synthetic = false) {
return { value, label, synthetic };
}
function isExistingDirectory(value) {
try {
return fs.existsSync(value) && fs.statSync(value).isDirectory();
} catch {
return false;
}
}
function listDirectoryOptions(input, options) {
const cwd = options.cwd || process.cwd();
const rawInput = input.trim();
const expandedInput = expandHome(rawInput);
const trailingSep = hasPathSeparator(rawInput) || hasPathSeparator(expandedInput);
const resolvedInput = expandedInput ? path.resolve(cwd, expandedInput) : cwd;
const browseDir = expandedInput && !trailingSep && !isExistingDirectory(resolvedInput) ? path.dirname(resolvedInput) : resolvedInput;
const prefix = expandedInput && browseDir !== resolvedInput ? path.basename(resolvedInput).toLowerCase() : '';
const results = [];
if (!trailingSep && isExistingDirectory(resolvedInput)) {
results.push(toDirectoryOption(resolvedInput, `. (use this directory)`));
}
if (isExistingDirectory(browseDir)) {
try {
for (const entry of fs.readdirSync(browseDir, { withFileTypes: true })) {
if (!entry.isDirectory()) continue;
if (prefix && !entry.name.toLowerCase().startsWith(prefix)) continue;
const fullPath = path.join(browseDir, entry.name);
if (!results.some((option) => option.value === fullPath)) {
results.push(toDirectoryOption(fullPath));
}
}
} catch {
// Skip unreadable directories; validation still reports path issues.
}
}
const validation = options.validate?.(rawInput);
const hasMatchingOption = results.some((option) => option.value === resolvedInput);
if (expandedInput && !validation && !hasMatchingOption) {
results.unshift(toDirectoryOption(resolvedInput, `Create/use: ${resolvedInput}`, true));
}
return results;
}
/**
* Directory prompt with autocomplete candidates and create-directory support.
* Uses @clack/core directly so typed paths that do not exist yet can still be
* submitted when validation allows creating them.
* @param {Object} options - Prompt options
* @param {string} options.message - Prompt message
* @param {string} [options.default] - Default directory
* @param {string} [options.placeholder] - Placeholder text
* @param {Function} [options.validate] - Sync validation function
* @returns {Promise<string>} Selected or typed directory path
*/
async function directory(options) {
const core = await getClackCore();
const color = await getPicocolors();
const tabCompletion = {
prefix: '',
index: -1,
options: [],
lastValue: '',
};
let prompt;
prompt = new core.AutocompletePrompt({
initialValue: options.default,
options: () => listDirectoryOptions(prompt?.userInput || '', options),
filter: () => true,
validate: (value) => options.validate?.(value ?? prompt.userInput),
render() {
const title = `${color.gray('◆')} ${options.message}`;
const bar = color.gray('│');
const barEnd = color.gray('└');
const userInput = this.userInput;
const placeholder = options.placeholder || options.default;
const inputDisplay = userInput ? this.userInputWithCursor : `${color.inverse(color.hidden('_'))}${color.dim(placeholder || '')}`;
const errorLine = this.state === 'error' ? [`${color.yellow('│')} ${color.yellow(this.error)}`] : [];
switch (this.state) {
case 'submit': {
return `${color.gray('◇')} ${options.message}\n${bar} ${color.dim(this.value || '')}`;
}
case 'cancel': {
return `${color.gray('◇')} ${options.message}\n${bar} ${color.strikethrough(color.dim(userInput || ''))}`;
}
default: {
return [title, `${bar} ${inputDisplay}`, ...errorLine, barEnd].join('\n');
}
}
},
});
const hasSetUserInput = typeof prompt._setUserInput === 'function';
const hasClearUserInput = typeof prompt._clearUserInput === 'function';
prompt.on('key', (_, key) => {
if (key?.name !== 'tab') return;
if (!hasSetUserInput) return; // @clack/core API surface changed — skip Tab silently.
const currentInput = prompt.userInput;
const isContinuingCycle = tabCompletion.lastValue && currentInput === tabCompletion.lastValue;
const completionOptions = isContinuingCycle ? tabCompletion.options : prompt.filteredOptions.filter((option) => !option.synthetic);
if (completionOptions.length === 0) return;
if (isContinuingCycle) {
tabCompletion.index = (tabCompletion.index + 1) % completionOptions.length;
} else {
tabCompletion.prefix = currentInput;
tabCompletion.options = completionOptions;
tabCompletion.index = 0;
}
const focusedOption = completionOptions[tabCompletion.index];
if (!focusedOption) return;
const completedValue = focusedOption.value;
tabCompletion.lastValue = completedValue;
if (hasClearUserInput) prompt._clearUserInput();
prompt._setUserInput(completedValue, true);
});
const result = await prompt.prompt();
await handleCancel(result);
return result;
}
/**
* Get the color utility (picocolors instance from @clack/prompts)
* @returns {Promise<Object>} The color utility (picocolors)
@ -694,6 +842,7 @@ module.exports = {
multiselect,
autocompleteMultiselect,
autocomplete,
directory,
confirm,
text,
password,

View File

@ -1436,7 +1436,7 @@ class UI {
*/
async promptForDirectory() {
// Use sync validation because @clack/prompts doesn't support async validate
const directory = await prompts.text({
const directory = await prompts.directory({
message: 'Installation directory:',
default: process.cwd(),
placeholder: process.cwd(),