thoughtsre Claude Code Workflows
thoughtsre/thoughtsre-claudecode-workflowThree phases from an MVP idea to the default branch, after a one-time setup — click any step to jump.
/feature-sprint <specs#> — runs the Implement flow, delivering an already-broken-down milestone's sub-issues onto a milestone branch./bug-fix-sprint — bugs are already issues, so it skips Design and drops each straight into the Implement loop, squash-merging into the default branch.Setup
once per repo⚙ Configure
Teach the workflows about your project.
- Run
/init-workflows. It fingerprints the repo and writes.claude/project-profile.json— test commands, infra, GitHub labels, docs, models. - The sprints hard-fail until this file exists — there are no silent defaults.
- Commit the profile so your whole team shares one configuration.
Design
per MVP / phase1 Spec the MVP
Write the MVP or phase as a single GitHub specs issue.
- Capture the scope, deliverables, and acceptance criteria — this issue is the source of truth the whole phase is built from.
- Use the
/thinkskill to reason through scope, tradeoffs, and acceptance criteria with Claude before writing the issue — it's a read-only discussion mode, so nothing gets changed while you shape the spec. - Titled so the milestone is clear, e.g.
[MVP 1] ….
2 Break down into sub-issues
Split the spec into small, dependency-ordered pieces.
- The
spec-breakdownagent reads the specs issue and your design docs, then proposes granular sub-issues (each ~a single focused session). - It also specifies the dependencies between issues — which sub-issue is blocked by which — and, on your approval, records them on GitHub as sub-issue links and blocked-by relationships. Together these form the dependency graph the Implement phase schedules against.
- Shallow trees are preferred, so more independent sub-issues can be delivered in parallel.
3 Update docs — optional
Capture any design upgrades or ADRs in main before implementation starts.
- Spec'ing and breaking down the MVP often surfaces decisions worth recording — new or revised architecture, conventions, or trade-offs.
- Write these up and merge them into
mainbefore implementation begins, so every sub-issue — and the milestone worktree, cut fresh frommain— starts from the same up-to-date source of truth. - See the docs structure guide for what belongs where — project guide, decision records, or user docs.
Implement
several sub-issues in flight at once — merge is linear🌳 Create the milestone worktree
A one-time, manual step per milestone — before the delivery loop can start.
/feature-sprintnever creates this worktree itself — it hard-requires running from inside one, on a non-default branch with a clean tree.- From the main repo checkout:
git worktree add ../repo-mvp1 -b mvp1 main— creates a sibling checkout on a freshmvp1branch offmain. cdinto it, then run/feature-sprint <specs#>from there — every sub-issue's per-issue worktree, and the final milestone branch, build on top of this one.
1 Plan
A planner and an architect negotiate an approved plan for the sub-issue.
- Planner drafts → architect approves or returns revisions, up to 6 rounds. Ambiguity is decided autonomously.
- Grounded in your project guide and decision records; written to
.claude/plans/issue-N.md.
Names files and interfaces, and tests that prove the sub-issue's acceptance criteria.
Finds the root cause and a regression test that fails before the fix, passes after.
2 Implement
Build strictly to the plan — no redesign, no scope creep.
- Works on an isolated branch, cut fresh off the up-to-date base, and runs the unit suite to green before committing.
- Never pushes, opens a PR, or merges — the workflow owns delivery.
Runs from inside the milestone worktree you create beforehand (see Create the milestone worktree) — each sub-issue then gets its own per-issue worktree off the milestone HEAD, so several build in parallel.
Branch fix/N-… off the freshly-pulled default branch. Strictly sequential — one bug at a time.
3 Review
The /code-review rubric, applied to the diff.
- Checks correctness, security, faithfulness to the design, and reuse/simplification.
- HIGH + MEDIUM findings block the merge and are fixed in up to 3 passes. LOW is reported, not blocking.
4 Test
The authoritative gate before merge.
- The unit suite runs always. The full / integration suite runs when the change needs it and the profile enables infra.
- Up to 3 fix-and-retest attempts before the sub-issue is handed to Escalate.
5 Merge
Deliver the change and close the issue — then the loop pulls the next one.
Serial merge (one writer) into the milestone branch, fast re-test, close the sub-issue — which instantly unblocks its dependents.
Push, open a PR with Fixes #N, squash-merge into the default branch — the issue auto-closes. Sync the default branch for the next bug.
⚠ Escalate — fail-soft
A failure never stops the run.
- Any failure at review, test, or merge gets one max-effort fixer pass — rebase a conflict, or fix the root cause — then re-enters at Test.
- If it still fails, the sub-issue is stranded (a diagnosis comment + a best-effort label) and the sprint keeps delivering everything else.
- Stranded work returns on the next run. (Feature: the stranded issue's dependent subtree waits with it.)
Ship
human-driven — the one gate before the default branch1 Open the PR
Raise the milestone → default branch pull request.
- By now every sub-issue has merged and the sprint's automated whole-diff milestone review is clean — the milestone branch is “ready.”
- Run the
/prskill to open the PR; it links and auto-closes the related issues.
2 Manual UAT
Put on the user's hat and exercise the MVP end-to-end.
- Clear the context first — start fresh so the review isn't coloured by the implementation session.
- Run manual user-acceptance testing against the running app: walk the MVP's flows as a real user would and confirm the acceptance criteria hold.
3 PR review
A human-gated code review of the whole PR.
- Review the PR with the
/reviewskill; fix any issues it surfaces before merging.
4 Bug-fix sprint — optional
Clear anything UAT or review turned up.
- If UAT or the PR review filed bugs as GitHub issues, run
/bug-fix-sprintto deliver them through the Implement loop. - Once the PR is clean, merge it — the MVP is shipped, and it's back to Design for the next MVP / phase.
▶ The bug-fix sprint — a leaner variant Optional
Bugs are already issues, so they skip Design and Ship entirely. /bug-fix-sprint selects open bug issues (ascending, skipping any with an open linked PR) and delivers them one at a time — the same delivery loop, but each is squash-merged straight into the default branch, which closes the issue and ships the fix. No milestone branch, no human PR gate.