Skip to content

docs(baseline): make CLAUDE.md enforce the SDD flow instead of suggesting it#31

Merged
protonspy merged 4 commits into
mainfrom
docs/claude-md-flow-guardrails
Jun 9, 2026
Merged

docs(baseline): make CLAUDE.md enforce the SDD flow instead of suggesting it#31
protonspy merged 4 commits into
mainfrom
docs/claude-md-flow-guardrails

Conversation

@protonspy

Copy link
Copy Markdown
Owner

What

The shipped CLAUDE.md template (internal/templater/templates/root/CLAUDE.md.tmpl) treated read csdd.md as a soft suggestion and omitted the load-bearing guardrails. An agent that skipped csdd.md lost every hard rule — and would hand-edit spec.json, skip phase gates, and author managed files directly.

This moves the guardrails into the always-loaded CLAUDE.md itself:

  • STOP gate making "read csdd.md" a precondition for touching any artifact.
  • Hard rules — enforced, not advisory: csdd is the only author of managed files; never hand-edit spec.json / frontmatter / annotations / .mcp.json; never skip a phase gate; surface blocks instead of routing around them.
  • Explicit ordered development cycle: generate → human approve → next phase, and only csdd flips ready_for_implementation.
  • Reinforced Non-negotiables with the spec.json / csdd spec approve rules at the top.

Docs/template-only change (no Go code, no logic). The steering managed-block markers are preserved.

Verification

  • go test -race ./... (pre-push gate) ✅ all packages pass
  • go test ./internal/templater/ ✅ template still renders, mentions csdd

🤖 Generated with Claude Code

protonspy and others added 4 commits June 8, 2026 18:49
…ting it

The shipped CLAUDE.md treated "read csdd.md" as a soft suggestion and
omitted the load-bearing guardrails, so an agent that skipped csdd.md
lost every hard rule — hand-editing spec.json, skipping phase gates,
authoring managed files directly.

Move the guardrails into the always-loaded CLAUDE.md itself:
- STOP gate that makes reading csdd.md a precondition for any artifact
- Hard rules: csdd is the only author; never hand-edit spec.json /
  frontmatter / annotations / .mcp.json; never skip a phase gate;
  surface blocks instead of routing around them
- Explicit ordered development cycle with generate -> human approve ->
  next phase, and that only csdd flips ready_for_implementation
- Reinforced Non-negotiables with the spec.json / approve rules

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@protonspy protonspy merged commit 69ba0bc into main Jun 9, 2026
3 checks passed
@protonspy protonspy deleted the docs/claude-md-flow-guardrails branch June 9, 2026 15:05
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