BMAD-METHOD/docs
Jonah Schulte cfc5dff50b feat(workflows): implement GSD-style guardrails Phase 2
Extract common patterns and add explicit step enumeration for improved
maintainability and code clarity.

## Key Improvements

### 1. Pattern Extraction (DRY Principle)
Created reusable patterns directory with 5 core patterns:

- **hospital-grade.md** (~100 lines)
  * Production-ready quality standards
  * Quality checklist (code, testing, security, performance)
  * Hospital-grade mindset and red flags

- **tdd.md** (~200 lines)
  * Test-Driven Development (Red → Green → Refactor)
  * TDD cycle, test quality standards, AAA pattern
  * Coverage targets (90%+ minimum)
  * Good vs bad examples

- **agent-completion.md** (~150 lines)
  * Completion artifact contract
  * JSON artifact formats by agent type
  * Verification and reconciliation patterns

- **verification.md** (~120 lines)
  * Independent verification pattern
  * Fresh context principle
  * Evidence-based verification checklist
  * PASS/FAIL criteria

- **security-checklist.md** (~250 lines)
  * 13 specific vulnerability patterns
  * CRITICAL/HIGH/MEDIUM security issues
  * Security review process with examples

Files: src/modules/bmm/patterns/*.md

### 2. Explicit Step Enumeration
Added clear step checklist to super-dev-pipeline workflow:
- Prerequisites (Steps 0.1-0.2)
- Phase 1: Builder (Steps 1.1-1.4)
- Phase 2: Inspector (Steps 2.1-2.4)
- Phase 3: Reviewer (Steps 3.1-3.4)
- Phase 4: Fixer (Steps 4.1-4.5)
- Phase 5: Reconciliation (Steps 5.1-5.5)
- Final Verification (Steps 6.1-6.4)

File: super-dev-pipeline/workflow.md

### 3. Documentation
Created comprehensive patterns documentation:
- Pattern system explanation
- Usage guidelines and examples
- Pattern design principles
- Before/after comparison

File: src/modules/bmm/patterns/README.md

## Benefits

### Code Reduction
 **Before:** ~4,948 lines (with duplication)
 **After:** ~1,599 lines (779 agent-specific + 820 patterns)
 **Savings:** ~3,349 lines removed (67% reduction)

### Maintainability
 Single source of truth for quality standards
 Update once, affects all workflows
 Consistency across all agents
 Clear step enumeration for transparency

### Execution Clarity
 User sees which step is executing
 Clear where failures occur
 Cannot skip steps
 Progress tracking built-in

## Files Changed

Modified (2):
- super-dev-pipeline/workflow.md (~50 lines added)
- patterns/README.md (enhanced ~250 lines)

Created/Enhanced (6):
- patterns/hospital-grade.md (~100 lines)
- patterns/tdd.md (~200 lines)
- patterns/agent-completion.md (~150 lines)
- patterns/verification.md (~120 lines)
- patterns/security-checklist.md (~250 lines)
- docs/implementation-notes/gsd-style-guardrails-phase2.md

Total: ~820 lines of reusable patterns + documentation

## Pattern Usage

Patterns referenced with @patterns/ syntax:

```markdown
<execution_context>
@patterns/hospital-grade.md
@patterns/tdd.md
@patterns/agent-completion.md
</execution_context>
```

BMAD installation resolves references and inlines pattern content.

## Testing Checklist

- Pattern resolution works correctly
- Step enumeration visible to user
- Pattern updates propagate to all workflows
- Agent prompts 50% smaller with patterns

Part of: v6.1.0-Beta.1
Follows: Phase 1 (completion artifacts, verification gates)
2026-01-27 02:43:39 -05:00
..
explanation removed dead code and obsolete levels 0-4 ref 2026-01-25 22:23:36 -06:00
how-to removed dead code and obsolete levels 0-4 ref 2026-01-25 22:23:36 -06:00
implementation-notes feat(workflows): implement GSD-style guardrails Phase 2 2026-01-27 02:43:39 -05:00
reference docs: update changelog and workflow-map for 6.1.0-Beta.1 unified workflow architecture 2026-01-27 00:55:08 -05:00
sprint-artifacts/completions feat(workflows): implement GSD-style guardrails Phase 1 2026-01-27 02:32:45 -05:00
tea docs: radical reduction of documentation scope for v6 beta (#1406) 2026-01-25 14:00:26 -06:00
tutorials add interactive diagram to test final doc build and layout 2026-01-25 22:12:23 -06:00
404.md Add link auditor, reorganize documentation, and README update (#1277) 2026-01-10 02:55:33 +08:00
ENTERPRISE-GITHUB-INTEGRATION.md chore: merge upstream/main (v6.0.0-Beta.1) into fork 2026-01-26 11:03:15 -05:00
HOW-TO-VALIDATE-SPRINT-STATUS.md chore: merge upstream/main (v6.0.0-Beta.1) into fork 2026-01-26 11:03:15 -05:00
_STYLE_GUIDE.md removed dead code and obsolete levels 0-4 ref 2026-01-25 22:23:36 -06:00
downloads.md add interactive diagram to test final doc build and layout 2026-01-25 22:12:23 -06:00
gap-analysis-migration.md chore: merge upstream/main (v6.0.0-Beta.1) into fork 2026-01-26 11:03:15 -05:00
gap-analysis.md chore: merge upstream/main (v6.0.0-Beta.1) into fork 2026-01-26 11:03:15 -05:00
index.md docs: radical reduction of documentation scope for v6 beta (#1406) 2026-01-25 14:00:26 -06:00
super-dev-mode.md chore: merge upstream/main (v6.0.0-Beta.1) into fork 2026-01-26 11:03:15 -05:00