Skip to content

reform(workflow): adversarial verification, structured enforcement, production-grade gate#54

Merged
nullhack merged 1 commit intomainfrom
reform/workflow-adversarial-verification
Apr 15, 2026
Merged

reform(workflow): adversarial verification, structured enforcement, production-grade gate#54
nullhack merged 1 commit intomainfrom
reform/workflow-adversarial-verification

Conversation

@nullhack
Copy link
Copy Markdown
Owner

Summary

  • Adversarial verification — reviewer's default hypothesis is now "the code is broken despite green checks"; job is to find the failure mode, not confirm it works
  • Reordered verification — code review before automated commands (design problems found early avoid double re-runs); run app first as a binary production-grade gate
  • Production-grade gate — new step 3 in verification: app must exit cleanly AND output must change when input changes; static output regardless of input = REJECTED
  • All review sections converted to tables — Correctness, KISS, SOLID, ObjCal, Design Patterns, Tests, Versions/Build all have PASS/FAIL/Fix columns (commitment devices + elaborative encoding)
  • UUID Drift check — bash one-liner detects duplicate UUIDs across test functions; any duplicate = REJECTED with fix instructions
  • UUID Uniqueness rule updated — if only Given varies it is a property by definition; use Hypothesis @given + @example, not multiple test functions; if When/Then differs use extend-criteria
  • Production-grade self-check in implementation — developer must verify output changes with input before handoff; reviewer will verify the same claim
  • Semantic alignment + integration test requirement — tests must operate at same abstraction level as AC; multi-component features require at least one integration test through the public entry point
  • Design pattern decision table — added to developer.md and implementation/SKILL.md; any detected anti-pattern = REJECTED
  • Architecture contradiction check — developer must cross-check ADRs against ACs before writing production code
  • PO pre-mortem — added at scope step and acceptance step
  • docs/academic_research.md — 15 cognitive and social science mechanisms with full citations grounding every design decision in the workflow (pre-mortem, implementation intentions, adversarial collaboration, elaborative encoding, System 2 before System 1, and 10 more)

Files Changed

File Change
AGENTS.md Adversarial verification note, semantic alignment standard, integration test requirement, Verification Philosophy section, research foundations reference
.opencode/agents/developer.md Architecture contradiction check, pre-mortem requirement, manual verification, design pattern decision table
.opencode/agents/product-owner.md PO pre-mortem at scope, ADR review gate, live verification at Step 6
.opencode/agents/reviewer.md Full restructure: adversarial mandate, new verification order, all sections as PASS/FAIL/Fix tables, UUID Drift check, production-grade gate
.opencode/skills/code-quality/SKILL.md Syntax vs design quality distinction, structural quality checks, design anti-pattern recognition table
.opencode/skills/extend-criteria/SKILL.md Architecture contradiction as a trigger for escalation
.opencode/skills/implementation/SKILL.md Architecture contradiction check, refactor self-check gates, design pattern decision table, production-grade self-check, developer pre-mortem
.opencode/skills/scope/SKILL.md Observable = end user rule, interaction model declaration, PO pre-mortem
.opencode/skills/tdd/SKILL.md Integration test requirement, semantic alignment rule, UUID uniqueness rule (property-based), Hypothesis guidance, contract test rule
.opencode/skills/verify/SKILL.md Full restructure mirroring reviewer.md: production-grade gate, code review before commands, all sections as tables, UUID Drift check
docs/academic_research.md New file — 15 mechanisms with explanations and full bibliography

…roduction-grade gate

- Add adversarial mandate to reviewer and verify skill: default hypothesis
  is the code is broken despite green checks
- Reorder verification: code review before lint/test, run app first as
  production-grade gate (output must change when input changes)
- Convert all review sections to tables with PASS/FAIL/Fix columns:
  Correctness, KISS, SOLID, ObjCal, Design Patterns, Tests, Versions/Build
- Add UUID Drift bash check: duplicate UUIDs across test functions = REJECTED
- Update UUID Uniqueness rule: one function per UUID; if only Given varies
  it is a property — use Hypothesis @given + @example, not multiple functions
- Add production-grade self-check to implementation/SKILL.md: developer must
  verify output changes with input before handoff
- Add design pattern decision table to developer.md (principle #6)
- Add PO pre-mortem at scope, ADR review gate, live verification at Step 6
- Add semantic alignment rule and integration test requirement to tdd/SKILL.md
- Add architecture contradiction check to implementation/SKILL.md
- Add Verification Philosophy section to AGENTS.md
- Add docs/academic_research.md: 15 cognitive/social science mechanisms with
  full citations grounding each workflow design decision
- Delete template-report.md (pre-implementation planning doc, now superseded)
@nullhack nullhack merged commit f8cceb3 into main Apr 15, 2026
9 checks passed
@nullhack nullhack deleted the reform/workflow-adversarial-verification branch April 15, 2026 06:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant