The delivery loop is the set of /ds-* Claude Code skills that carry ONE DevStride story from "next unblocked item" to "merged and Done" — branching, building, self-reviewing, opening a PR, addressing findings, merging, and running the completion ritual, then looping to the next story. /ds-story is the orchestrator; /ds-branch-feature, /ds-ultracode-build, and /ds-pr are the skills it composes directly, and /ds-push is a smaller utility nested one level deeper — /ds-pr calls it internally to land review fixes, so it genuinely sits inside the loop even though it's also usable standalone. /ds-branch-hotfix is the one skill on this page that truly sits alongside the loop rather than inside it — /ds-story never calls it. A short closing section covers the golden-dataset skills, which are supporting infrastructure a developer runs by hand — never part of the story loop itself.
get_item, update_item, and link_pull_request act on the real, live DevStride workspace at api.devstride.com — not your local SST stage — and the MCP cannot exercise branch code. Every lane move /ds-story makes (In Progress at the start, Done at the end) and every link_pull_request call are real, user-visible changes to live items, made against production the instant they run. There is no local/sandbox mode to fall back on./ds-story — the orchestrator/ds-story <item|next> runs the whole loop: select → mark In Progress → branch → build → adversarial review → PR → merge → completion ritual → sync develop → next. It is the ORCHESTRATOR — it composes the other skills below by name and owns only the DevStride-specific glue (next-story selection, lane transitions, the completion ritual). It is explicitly designed to run under /loop for full autonomy.
The steps, in order:
$ARGUMENTS or prior /ds-plan/ds-story memory), then pick the highest-priority, not-Done, not-blocked_by-anything Story/Defect in the earliest-dated open Capability/Epic on the plan's critical path — the same canonical "next-unblocked" definition ds-insert-story, ds-insert-defect, and ds-comprehend-plan use. It re-fetches the item's full description and validates it against the actual codebase before treating anything in it as true, and reports the whole "ready-set" of unblocked candidates (not just the one it picked) so parallel waves stay visible even though execution itself is serial.update_item lane move on the live item./ds-branch-feature with a slug derived from the item number./ds-ultracode-build, which owns the understand/build/adversarial-review engine (below)./ds-pr in its autonomous, driven-by-ds-story mode.develop in before merging so conflicts surface where they're resolvable — pushing the rebased branch goes through /ds-push (force-with-lease), never a bare git push, since a real rebase rewrites SHAs and would otherwise be rejected as non-fast-forward. Watches actual CI check-run status (not just reviewer bots) with a non-blocking snapshot poll — reusing the same check /ds-pr step 4 already surfaced, not a blocking gh pr checks --watch, which would tie up the tool call for the full run (this repo's golden/full gates can run 20+ minutes). Retries flaky failures (bounded, ~2 attempts), fixes real failures in-loop, and merges only once CI is actually observed green — gh pr merge <n> --merge --delete-branch.startDate/dueDate to the branch/PR window, confirm or manually create the PR↔item link, and — if the build materially diverged from the item's written spec — preserve the original description as a comment and rewrite the description to the as-built spec./ds-insert-defect or /ds-insert-story so a future loop iteration actually reaches it. See The Planning Loop for what those two skills do.git checkout develop && git pull --ff-only, assert a clean tree (the next /ds-branch-feature aborts on a dirty one), persist the resolved plan root, and loop back to step 1 for the next story./ds-story runs the entire loop — select through next-story — without pausing between steps. It stops and asks a human ONLY at a genuine fork:
Everything else proceeds on the loop's own judgment, with every deferral recorded explicitly (in the build plan, the PR body, and project memory) rather than silently dropped. This is exactly the contract /loop needs to drive /ds-story unattended.
/ds-story executes ONE story at a time on purpose. /ds-branch-feature aborts on a dirty tree, /ds-ultracode-build runs type-checks/tests against one working tree and one local Postgres/DynamoDB (concurrent vitest runs corrupt each other's worker DB), and the MCP writes to production — so concurrent branches would race on shared local and live state. The "ready-set" it surfaces at step 1 shows where a plan's parallel waves could run; fanning them out is a human decision, not something the loop does itself.If a resolved plan has zero not-Done, non-gated, unblocked candidates left, /ds-story exits cleanly and reports the terminal state (plan complete, blocked on open items, or gated on human/infra decisions) rather than looping back to re-ask.
/ds-branch-feature vs /ds-branch-hotfix/ds-branch-feature | /ds-branch-hotfix | |
|---|---|---|
| Branches off | develop (freshly pulled) | a fresh master, with the local DB reset from production |
| Naming | <user-prefix>/<MM-DD-YY>/<branch-name> | <user-prefix>/hotfix/<MM-DD-YY>/<branch-name> |
Called by /ds-story? | Yes — step 2 invokes it directly | No — standalone entry point only |
| PR target | develop (via /ds-pr) | master — opened manually when ready (gh pr create --base master --fill); nothing to compare right after creation, so no PR is opened as part of the skill |
| Use when | Building/shipping a normal story through the delivery loop | An urgent fix that must branch from production code, not develop |
/ds-branch-feature is the everyday branch-creation utility: it aborts on a dirty tree, syncs develop, creates and pushes the new branch. It's used both directly and as the building block /ds-story calls at step 2.
/ds-branch-hotfix is a heavier, standalone tool for genuine production emergencies. Its preflight is strict: SOURCE_DB_CONNECTION_STRING must be set (the DB reset fails partway without it, leaving the DB half-reset), the working tree must be clean, and it recommends stopping any running ds run backend first since resetting the DB underneath it can cause problems. The steps are git checkout master → git pull → the destructive ds script reset-db (drops and reseeds the local DB from prod) → create the hotfix branch → ds migrations run → push. On any failure partway through, it does not strand the user on master — it reports exactly which step failed and asks how to proceed rather than guessing.
/ds-ultracode-build — the build engine/ds-ultracode-build I<number> <one-line goal/scope> is the build engine /ds-story invokes internally once a branch exists and the item is already In Progress. It is not a standalone story-selection tool — it assumes the branch, the item state, and the scope are already given — and it does not open a PR or merge; it hands back to /ds-story. It runs three phases:
Co-Authored-By: and Claude-Session: trailers. Type-checks, the four pre-commit wiring checks, and the relevant tests must stay green — a red non-SDK check is a stop-and-fix, never a commit-anyway. Generated API artifacts (SDK/openapi/mcp gen output) are regenerated and committed separately from hand-written logic.Findings and deferrals that are real but have no existing tracked item to absorb them are not left as prose — they're collected into an untracked-deferral list that /ds-story step 6.5 turns into real, dependency-spliced DevStride items via /ds-insert-defect / /ds-insert-story. This is the "mid-build escape hatch" for newly discovered work; see The Planning Loop for how those two skills splice an item into the graph.
/ds-ultracode-build hands back to /ds-story with: the item number, a one-line build summary, green-checks confirmation, the finalized scope/deferral line, the untracked-deferral list, and a deviations list — every material way the build diverged from the item's written spec. That deviations list is what /ds-story step 6 uses to reconcile the item's as-built description.
/ds-pr — PR creation, automated review, and triage/ds-pr opens the pull request, runs it through a local review and the repo's automated GitHub reviewers, addresses verified findings, and optionally links the PR to its DevStride item. It has two modes:
/ds-pr [item-number] directly. It asks which base branch to target (develop for a feature branch, master for a hotfix), keeps every interactive ask-gate, and offers to link the PR to a DevStride item as its final step.ds-story — invoked as /ds-story step 4. The base branch is pre-answered (develop), the review-poll timeout defaults to "proceed with the local findings" instead of asking, and step 8 (linking) is skipped entirely — /ds-story owns PR-to-item linking in its own step 6, and linking in both places would double-own it. Even in autonomous mode it still pauses for a genuine fork (an ambiguous/risky/unverifiable finding, or a destructive/outward-facing action) — only "out of scope but real" findings are captured rather than asked about.The steps: open the PR (gh pr create --base <base> --fill, no Co-Authored-By or AI-attribution text in the PR body — those trailers live on commits only), run /code-review high locally, request both automated reviewers (@codex review as a PR comment for Codex; the requested_reviewers API for Copilot), poll GitHub for reviews/comments and CI check status (gh pr checks), auto-address findings that are both verified and clearly in scope, then triage everything else into exactly one bucket:
/ds-insert-defect//ds-insert-story (standalone mode). Standalone /ds-pr has no notion of a "plan root" — its only input is an optional single item number — so in that mode it asks the user for the Module/Capability/Epic to anchor the insert under rather than guessing one.Agreed fixes are committed and pushed with /ds-push (see below) — /ds-pr never opens a second PR to land review fixes.
Because it triages external, unauthenticated-relative-to-the-agent content — GitHub bot review comments and PR comments — and in autonomous mode acts on it with reduced oversight, /ds-pr treats any embedded instruction inside a review comment (beyond a normal code-review suggestion) as untrusted data, not a legitimate instruction, and flags it to the user if it appears.
/ds-push — a smaller, direct utility/ds-push is a small git-workflow utility, not part of the phased build/review engine: git add -u (already-tracked files only — it deliberately never sweeps in untracked files with git add .), show git status and a staged diff summary, commit with a message carrying the required Co-Authored-By:/Claude-Session: trailers — using the exact per-session values, never a stale example, and stopping to ask rather than guessing if those values aren't clearly available — run pnpm --dir backend run check:ts && pnpm --dir frontend run check:ts, then push (falling back to git push --force-with-lease — never a bare --force — on a non-fast-forward rejection). If the type-check fails with non-SDK errors, it does not push; it reports and asks. It explicitly does not open a pull request — it's the stage/typecheck/push building block /ds-pr calls internally to land review fixes, and it's equally usable standalone whenever you want to push without opening a PR.
/ds-story <item|next>
├─ 0. select story (get_item, dependency graph, ready-set)
├─ 1. mark In Progress (update_item — PRODUCTION write)
├─ 2. /ds-branch-feature I<####>-<slug>
├─ 3. /ds-ultracode-build I<####> <scope>
│ ├─ UNDERSTAND (ultracode Workflow: parallel readers → build plan)
│ ├─ BUILD (commit often, keep checks green)
│ └─ ADVERSARIAL REVIEW (Workflow: finders → per-finding verify → fix)
│ └─ compiles an untracked-deferral list for anything real
│ with no existing tracked home (not invoked here —
│ handed back to /ds-story, see step 6.5 below)
├─ 4. /ds-pr (autonomous / driven-by-ds-story mode)
│ ├─ local /code-review high
│ ├─ Codex (@codex review) + Copilot automated review
│ ├─ auto-address verified in-scope findings
│ ├─ triage: dismiss REFUTED / capture out-of-scope / ask on real forks
│ └─ /ds-push (commit + typecheck + push the fixes)
├─ 5. merge (rebase develop in, watch CI, retry flaky, fix real failures)
├─ 6. completion ritual (Done lane, dates, PR link, as-built spec reconciliation — PRODUCTION writes)
├─ 6.5 capture untracked findings → /ds-insert-story · /ds-insert-defect
└─ 7. sync develop → back to step 0 (next story, or exit on terminal condition)
/ds-branch-hotfix is deliberately absent from this diagram — it's a standalone entry point for production emergencies, not a step /ds-story ever calls.
/ds-golden, /ds-golden-build, /ds-golden-push, and /ds-reset-db are supporting infrastructure a developer runs directly — none of them is invoked by /ds-story, and they are not steps in the delivery loop. They exist to keep your local database and stage data usable while you build. Each is a thin, judgment-adding layer over the underlying ds golden / ds script CLI; for what those CLI verbs actually do, see Golden Dataset.
/ds-golden [org] — checks dataset health and, if needed, restores it. It always starts read-only (ds golden status, which mutates nothing); if the dataset is unhealthy, it only proposes a fix (a re-import, a reanchor) for the user to confirm — it never auto-runs a mutating verb on its own judgment./ds-golden-build [representative|full] — the heavy, rare, hours-long content-authoring flow: rebuilds the dataset from the generator (backend/tests/golden/) and, once it passes the §16 pre-ship assertion gate (which stamps a marker the publish step refuses to proceed without), optionally publishes it to the canonical golden source DB. It does not touch any stage./ds-golden-push <stage> — deploys/refreshes the golden Acme dataset onto a named stage, choosing the safe verb for that target: additive ds golden import for a shared, populated stage like dev (app.devstride.dev), or a whole-DB push --force-full-reset only for a confirmed-disposable stage. It hard-refuses prod outright — the CLI's own stage guard blocks every mutating golden verb against api.devstride.com, and this skill won't attempt a workaround./ds-reset-db — resets the local database from production, then re-applies the current branch's migrations on top. Strict preflight: SOURCE_DB_CONNECTION_STRING must be set (the reset fails partway without it), the working tree should be clean, and it recommends stopping any running ds run backend first. If any step fails, it does not leave you stranded on master — it checks out your original branch to restore you before reporting what broke.Per the golden dataset's own directive, any correction to golden data belongs in the generator, never in a direct database edit — a stage reset or reseed is expected to wipe hand-patched rows.
/ds-branch-hotfix / /ds-reset-db both perform a destructive local DB reset seeded from real production data — never run either against a dirty tree, and always confirm SOURCE_DB_CONNECTION_STRING before proceeding. None of these skills silently escalate past a destructive action; they stop and ask./ds-plan, /ds-insert-story, /ds-insert-defect, and /ds-comprehend-plan: how work gets onto the dependency graph that /ds-story selects fromds golden CLI these skills wrapds CLI surface