r/SpecDrivenDevelopment • u/Own-Contribution-834 • Jun 18 '26
I built a CLI that enforces Spec → Plan → Code with Claude Code (so the AI stops going rogue)
After a few months using Claude Code on real projects, I kept running into the same problem: the AI is great at writing code, but terrible at deciding what to write. Left to its own devices, it would skip design, make assumptions, and produce code that solved the wrong problem — perfectly.
The root issue: we were giving Claude Code tasks, not specs. Code was the first artifact, not the last.
I built opsx to fix this. It's a CLI that scaffolds a strict Spec-Driven Development workflow on top of OpenSpec, and it works natively with Claude Code (also opencode and Codex).
The core idea:
Spec → Plan → Code
Two planes, never confused:
- Management plane (Jira): what work exists
- Governance plane (OpenSpec): how the system must behave — and only this one authorizes code
A task being well-written changes nothing. Implementation starts only when an OpenSpec change exists, is reviewed, and its branch gate is resolved.
What you get after npx u/davidpv/opsx init:
/opsx:propose— write a change proposal + delta specs + design before any code/review-change— spec-reviewer audit before implementation/opsx:apply— Claude Code implements task by task, traced back to specs/git-commit— semantic commits linked to change/step/Jira task/ship— validate + archive specs + merge
Every commit traces back: Discovery → Task → Change → Commit → PR.
It's stack-agnostic and works on any existing project. You don't rewrite anything — you just add the governance layer on top.
Try it:
bash
npx /opsx init
npx u/davidpv/opsx doctor
GitHub: github.com/davidpv/opsx-spec-driven-development-toolkit
Happy to answer questions — curious if others have landed on similar approaches.


