src/bmm-skills/2-plan-workflows/bmad-edit-prd/steps-e/step-e-01-discovery.md
Understand what the user wants to edit in the PRD, detect PRD format/type, check for validation report guidance, and route appropriately.
{communication_language}{document_output_language}CRITICAL: Follow this sequence exactly. Do not skip, reorder, or improvise unless user explicitly requests a change.
Load and read the complete file at:
{prdPurpose} (data/prd-purpose.md)
This file defines what makes a great BMAD PRD. Internalize this understanding - it will guide improvement recommendations.
"PRD Edit Workflow
Which PRD would you like to edit?
Please provide the path to the PRD file you want to edit."
Wait for user to provide PRD path.
Once PRD path is provided:
Check if validation report exists in the PRD folder:
# Look for most recent validation report in the PRD folder
ls -t {prd_folder_path}/validation-report-*.md 2>/dev/null | head -1
If validation report found:
Display: "📋 Found Validation Report
I found a validation report from {validation_date} in the PRD folder.
This report contains findings from previous validation checks and can help guide our edits to fix known issues.
Would you like to:
Wait for user input.
IF U (Use validation report):
IF S (Skip) or no validation report found:
If no validation report found:
"Do you have a validation report to guide edits?
If you've run the validation workflow on this PRD, I can use that report to guide improvements and prioritize changes.
Validation report path (or type 'none'):"
Wait for user input.
If validation report path provided:
If no validation report:
"What would you like to edit in this PRD?
Please describe the changes you want to make. For example:
Describe your edit goals:"
Wait for user to describe their requirements.
Analyze the loaded PRD:
Extract all ## Level 2 headers from PRD
Check for BMAD PRD core sections:
Classify format:
IF validation report provided OR PRD is BMAD Standard/Variant:
Display: "Edit Requirements Understood
PRD Format: {classification} {If validation report: "Validation Guide: Yes - will use validation report findings"} Edit Goals: {summary of user's requirements}
Proceeding to deep review and analysis..."
Read fully and follow: ./step-e-02-review.md
IF PRD is Legacy (Non-Standard) AND no validation report:
Display: "Format Detected: Legacy PRD
This PRD does not follow BMAD standard structure (only {count}/6 core sections present).
Your edit goals: {user's requirements}
How would you like to proceed?"
Present MENU OPTIONS below for user selection
[C] Convert to BMAD Format - Convert PRD to BMAD standard structure, then apply your edits [E] Edit As-Is - Apply your edits without converting the format [X] Exit - Exit and review conversion options
./step-e-01b-legacy-conversion.mdMaster Rule: Understand before editing. Detect format early so we can guide users appropriately. Auto-detect and use validation reports for prioritized improvements.