Loading...
Loading...
Validate Business Requirements Documents (BRD) against Layer 1 MVP schema standards
npx skill4agent add vladm3105/aidoc-flow-framework doc-brd-validator| Item | Value |
|---|---|
| Schema | |
| Template | |
| Creation Rules | |
| Validation Rules | |
| Layer | 1 |
| Artifact Type | BRD |
Required custom_fields:
document_type: ["brd", "template"]
artifact_type: "BRD"
layer: 1
architecture_approaches: [array format]
priority: ["primary", "shared", "fallback"]
development_status: ["active", "draft", "deprecated", "reference"]
Required tags:
- brd (or brd-template)
- layer-1-artifact
Forbidden tag patterns:
- "^business-requirements$"
- "^brd-\\d{3}$"| Section | Title | Required |
|---|---|---|
| 0 | Document Control | MANDATORY |
| 1 | Executive Summary | MANDATORY |
| 2 | Business Context | MANDATORY |
| 3 | Stakeholder Analysis | MANDATORY |
| 4 | Business Requirements | MANDATORY |
| 5 | Success Criteria | MANDATORY |
| 6 | Constraints and Assumptions | MANDATORY |
| 7 | Architecture Decision Requirements | MANDATORY |
| 8 | Risk Assessment | MANDATORY |
| 9 | Traceability | MANDATORY |
| 10-18 | Additional sections | Per template |
## N. Title| Field | Description | Required |
|---|---|---|
| Project Name | Project identifier | MANDATORY |
| Document Version | Semantic versioning (X.Y.Z) | MANDATORY |
| Date Created | YYYY-MM-DD format | MANDATORY |
| Last Updated | YYYY-MM-DD format | MANDATORY |
| Document Owner | Owner name | MANDATORY |
| Prepared By | Author name | MANDATORY |
| Status | Draft/In Review/Approved/Superseded | MANDATORY |
| PRD-Ready Score | | MANDATORY |
BRD.NN.23.SSBRD.NN.01.SS| # | Category | Element ID | Status Values |
|---|---|---|---|
| 1 | Infrastructure | BRD.NN.32.01 | Selected/Pending/N/A |
| 2 | Data Architecture | BRD.NN.32.02 | Selected/Pending/N/A |
| 3 | Integration | BRD.NN.32.03 | Selected/Pending/N/A |
| 4 | Security | BRD.NN.32.04 | Selected/Pending/N/A |
| 5 | Observability | BRD.NN.32.05 | Selected/Pending/N/A |
| 6 | AI/ML | BRD.NN.32.06 | Selected/Pending/N/A |
| 7 | Technology Selection | BRD.NN.32.07 | Selected/Pending/N/A |
32doc-namingBRD.NN.TT.SSBRD-NN_{descriptive_slug}.mdNNdescriptive_slugdocs/01_BRD/BRD-NN_{slug}/BRD-NN.S_{section}.md@related-brd: BRD-NN@supersedes-brd: BRD-NN@depends-brd: BRD-NN| Code | Severity | Description |
|---|---|---|
| BRD-E001 | ERROR | Missing required tag 'brd' |
| BRD-E002 | ERROR | Missing required tag 'layer-1-artifact' |
| BRD-E003 | ERROR | Invalid document_type value |
| BRD-E004 | ERROR | Invalid architecture_approaches format (must be array) |
| BRD-E005 | ERROR | Forbidden tag pattern detected |
| BRD-E006 | ERROR | Missing required section |
| BRD-E007 | ERROR | Multiple H1 headings detected |
| BRD-E008 | ERROR | Section numbering not sequential |
| BRD-E009 | ERROR | Document Control missing required fields |
| BRD-E010 | ERROR | Missing Business Objectives (Section 3) |
| BRD-E011 | ERROR | Missing Business Requirements (Section 4) |
| BRD-E012 | ERROR | Missing Traceability (Section 9) |
| BRD-E013 | ERROR | Missing Section 7.2 (Architecture Decision Requirements) |
| BRD-E014 | ERROR | Missing mandatory ADR topic category |
| BRD-E015 | ERROR | ADR topic missing required Status field |
| BRD-E016 | ERROR | Selected ADR topic missing Alternatives Overview table |
| BRD-E017 | ERROR | Selected ADR topic missing Cloud Provider Comparison table |
| BRD-E018 | ERROR | N/A ADR topic missing explicit reason |
| BRD-E019 | ERROR | Invalid element ID format (not BRD.NN.TT.SS) |
| BRD-E020 | ERROR | Element type code not valid for BRD (see doc-naming) |
| BRD-E021 | ERROR | Deprecated ID pattern used (BO-XXX, FR-XXX, etc.) |
| BRD-W001 | WARNING | Objectives not using BRD.NN.23.SS format |
| BRD-W002 | WARNING | Requirements not using BRD.NN.01.SS format |
| BRD-W003 | WARNING | Missing Success Metrics (Section 5) |
| BRD-W004 | WARNING | PRD-Ready Score below 90% |
| BRD-W005 | WARNING | Missing Stakeholder Analysis |
| BRD-W006 | WARNING | File name does not match format BRD-NN_{slug}.md |
| BRD-W007 | WARNING | ADR topic missing cost estimates in Alternatives Overview |
| BRD-W008 | WARNING | ADR topic missing PRD Requirements field |
| BRD-W009 | WARNING | Missing Document Revision History table |
| BRD-I001 | INFO | Consider adding regulatory compliance requirements |
| BRD-I002 | INFO | Consider adding market analysis context |
| BRD-I003 | INFO | Consider completing Pending ADR topics before PRD creation |
# Validate single BRD document
python ai_dev_flow/scripts/validate_brd.py docs/01_BRD/BRD-01_example.md
# Validate all BRD documents in directory
python ai_dev_flow/scripts/validate_brd.py docs/01_BRD/
# Validate with verbose output
python ai_dev_flow/scripts/validate_brd.py docs/01_BRD/ --verbose
# Validate with auto-fix
python ai_dev_flow/scripts/validate_brd.py docs/01_BRD/ --auto-fix
# Cross-document validation
python ai_dev_flow/scripts/validate_cross_document.py --document docs/01_BRD/BRD-01.md --auto-fix| Issue | Auto-Fix Action |
|---|---|
| Invalid element ID format | Convert to BRD.NN.TT.SS format |
| Missing traceability section | Insert from template |
| Missing Document Control fields | Add placeholder fields |
| Deprecated ID patterns | Convert to unified format |
| Missing PRD-Ready Score | Calculate and insert |
BRD Validation Report
=====================
Document: BRD-01_platform_architecture.md
Status: PASS/FAIL
PRD-Ready Score: 92% (Target: ≥90%) ✓
Errors: 0
Warnings: 2
Info: 1
[BRD-W006] WARNING: File name should use lowercase slug
[BRD-W009] WARNING: Missing Document Revision History table
[BRD-I001] INFO: Consider adding regulatory compliance requirements.claude/skills/doc-naming/SKILL.md.claude/skills/doc-brd/SKILL.mdai_dev_flow/01_BRD/BRD-MVP-TEMPLATE.mdai_dev_flow/01_BRD/BRD_MVP_SCHEMA.yamlai_dev_flow/01_BRD/BRD_CREATION_RULES.mdai_dev_flow/01_BRD/BRD_VALIDATION_RULES.md.claude/skills/doc-flow/SHARED_CONTENT.md| Version | Date | Changes |
|---|---|---|
| 2.1 | 2026-02-10 | Added element type code 33 (Benefit Statement) to valid BRD codes per doc-naming v1.5 |
| 2.0 | 2026-02-08 | Complete rewrite: Added YAML frontmatter, doc-naming integration (BRD-E019/E020/E021), updated section structure to 18 sections, fixed file paths with numbered prefixes, added PRD-Ready score validation |
| 1.0 | 2025-01-06 | Initial version (outdated 12-section structure) |