This spec defines the engineering operating model for high-risk changes in Blueprint.
- Detect regressions before merge with targeted harnesses.
- Minimize silent downgrades and fail-open behavior in security-sensitive paths.
- Preserve velocity by matching verification depth to risk tier.
- Make code review evidence-based instead of preference-based.
- Harnesses are product infrastructure, not temporary test code.
- Evals and harnesses are a first-class competency.
- Optimize for entropy: code, metadata, and environments drift over time.
- Favor explicit contracts over implied behavior.
- Prefer fail-closed semantics for security and policy constraints.
- Declare behavior contract in PR.
- Add or update reproducer harnesses.
- Provide negative-path coverage.
- Document compatibility and migration outcomes.
- Validate behavior contract against implementation and tests.
- Reject silent downgrade paths.
- Require evidence for compatibility assumptions.
- Classify audit findings with explicit disposition.
- Validate runtime assumptions and observability.
- Confirm rollback or containment path exists.
- Ensure operational docs remain accurate.
Use one class per PR:
Class A: docs/tooling only, no runtime or API behavior change.Class B: single-crate behavior changes with local blast radius.Class C: cross-crate/runtime behavior changes (manager/source/runtime/protocol glue).Class D: protocol, security, on-chain metadata semantics, or policy enforcement changes.
| Requirement | Class A | Class B | Class C | Class D |
|---|---|---|---|---|
| Behavior contract in PR | Optional | Required | Required | Required |
| Reproducer test/harness | Optional | Required | Required | Required |
| Negative-path assertions | Optional | Required | Required | Required |
| Compatibility/migration analysis | Optional | Recommended | Required | Required |
| Rollback/containment notes | Optional | Recommended | Required | Required |
| Targeted crate tests listed | Optional | Required | Required | Required |
Quality gates are enforced automatically in CI:
- PR body/checklist + class validation:
.github/scripts/validate_pr_body.py - Classification policy config:
.github/pr-quality-gate.toml - Workflow and PR summary comment:
.github/workflows/pr-quality-gate.yml
Every non-draft PR should include:
- Summary.
- Change class.
- Behavior contract.
- Risk and scope.
- Verification commands and outcomes.
- Harness evidence.
- Checklist completion.
- Start with minimal crate-scoped checks that exercise changed behavior.
- Add cross-crate checks when behavior crosses boundaries.
- Promote to workspace checks for broad or high-risk refactors.
- Explicitly state skipped checks and why.
When parsing or semantics change:
- Define legacy payload behavior explicitly.
- Avoid silent defaulting that weakens security or policy.
- If behavior is breaking, surface it as intentional and documented.
- Tie migration plan to concrete code paths and owners.
For each human/AI audit finding:
- Categorize as
bug,tradeoff, ornoise. - Provide evidence (file reference, test, or reproducer).
- Record resolution:
fixed,accepted-with-rationale, orrejected-with-evidence.
A PR meets this spec when:
- Required matrix evidence exists for its class.
- Reviewer can validate claims without reverse engineering intent.
- Risks and migration paths are explicit and test-backed.