OFTR-008: Requirements Governance
Synced from
outfitter/docs/requirements/OFTR-008-requirements-governance.md. The repository is the source of truth.
Overview
Section titled “Overview”Outfitter requirements define reviewable project obligations. Each requirement should be traceable to TypeScript implementation, tests, DeepSchemas, or DeepReview rules depending on the appropriate validation mechanism.
Requirements
Section titled “Requirements”OFTR-008.1: Requirement File Format
Section titled “OFTR-008.1: Requirement File Format”- Requirement files MUST live under
requirements/and use filenames matchingOFTR-NNN-<topic>.md. - Requirement files MUST begin with a top-level heading matching
# OFTR-NNN: Title. - Requirement files MUST include an
## Overviewsection before requirements. - Requirement files MUST include an
## Requirementssection. - Requirement section headings MUST use the format
### OFTR-NNN.M: Title. - Requirement statements MUST use RFC 2119 keywords such as MUST, MUST NOT, SHOULD, SHOULD NOT, MAY, REQUIRED, RECOMMENDED, or OPTIONAL.
- Requirement section ID numbering within each file MUST be sequential without gaps.
- Each requirement MUST be specific enough to verify by automated test, DeepSchema, DeepReview rule, or direct reviewer judgment.
OFTR-008.2: Validation Mechanism Selection
Section titled “OFTR-008.2: Validation Mechanism Selection”- Machine-verifiable requirements MUST be validated by automated TypeScript tests when the implementation exists.
- Single-file semantic requirements SHOULD be validated by anonymous DeepSchemas placed next to the governed file.
- Broad judgment-based requirements SHOULD be validated by
.deepreviewrules. - Tests MUST NOT use fragile keyword checks to pretend to validate judgment-based requirements.
- Review rules SHOULD NOT ask reviewers to verify exact values, paths, or schema shapes that an automated test or JSON Schema can verify deterministically.
OFTR-008.3: Test Traceability Comments
Section titled “OFTR-008.3: Test Traceability Comments”- Tests that validate a formal requirement MUST include a traceability comment immediately before the test case or test block.
- Traceability comments MUST identify at least one requirement ID using the pattern
OFTR-NNN.M. - Traceability comments MUST state that the test validates a hard requirement and MUST NOT be modified unless the requirement changes.
- Test comments MUST describe durable behavior or policy intent rather than transient line numbers, pull request numbers, or current-diff context.
- Test comments MUST be updated or removed when the tested behavior changes.
OFTR-008.4: Traceability Reviews
Section titled “OFTR-008.4: Traceability Reviews”- Changes to requirement files MUST trigger review of requirement formatting and traceability.
- Changes to TypeScript source or tests SHOULD trigger review for missing requirement coverage when they introduce or change product behavior.
- Changes to DeepSchemas or
.deepreviewpolicies MUST preserve references to the requirement IDs they enforce when applicable. - The requirements DeepSchema MUST include a filename regex that matches the
OFTR-NNN-<topic>.mdnaming style.