Port / repeat
A finished feature is a close template. Use one direct prompt.
A practical, cost-aware way to ship repeatable work, build new features, and review PRs without wasting context, agent runs, or verification cycles.
A finished feature is a close template. Use one direct prompt.
New behavior, API contract, schema, or multiple folders.
Tenancy, billing, authentication, or cross-cutting behavior.
Several similar ports on one branch; review once at the end.
No plan and no agents. Use the closest finished feature as the implementation template.
/clear
Port <feature> from <source path> to store-admin/src/app/features/<x>/. Follow the pattern in features/<finished-feature>/. Wire route, nav item and reports hub if relevant. Then run: .claude/compound/qa.sh store-admin
git diff --stat and inspect the changed files yourself./compound-review; batch review later in Lane D.Ask a focused question without creating files: /compound-ask how does <area> work today? The plan step can reuse the conversation.
/compound-plan <feature, constraints, known file paths>. Give precise paths to focus the maximum two research agents. Read plans/<name>.md and trim scope yourself.
Run /clear, then /compound-work plans/<name>.md. Five files or fewer: Solo mode. Fan out only when more than five files span several areas. Split large work into 2–3 plans.
Use /compound-verify tests only store-admin (or the relevant area). Avoid the expensive full union unless needed.
/compound-review --task <slug> writes reports to reports/<slug>/ and keeps the main context small.
Run /compound-learnings <topic hint> only when the fix or discovery is non-obvious. Skip routine work.
Follow Lane B, with two deliberate changes:
Switch to Opus (/model) only for /compound-plan.
Switch back to Sonnet for /compound-work.
/compound-verify unscoped once, just before the PR. Security, billing, and tenancy decisions still require human judgment and review.One commit per port, with qa.sh <area> run for each area.
/compound-verify tests only
/compound-review --task <branch-slug>
Use /compound-fix <exact finding> — no teams and no new plans.
When a feature is split across dependent pull requests, review the stack as one delivery sequence while keeping each PR independently understandable.
Document the order and dependency of each PR (for example, PR 1 → PR 2 → PR 3). Each PR description should state its parent/base branch, what it adds, and what is intentionally deferred.
Start with the foundational PR, then review its child PRs in dependency order. Do not approve a child before the parent behavior and contract are understood.
For each stacked PR, inspect only the changes introduced by that PR relative to its parent branch — not the entire accumulated stack. Confirm the PR base is correct.
After individual reviews, verify shared API contracts, migrations, types, and caller updates across the complete stack. Run the relevant tests against the integrated head.
When a parent changes, rebase or update child branches in order, resolve conflicts, and re-run affected checks. Keep each PR description and review status current.
Merge the base PR first, then retarget or update the next PR to the new base, continuing until the stack is complete. Avoid merging dependent PRs out of order.
| Rule | Practical effect |
|---|---|
/clear between phases | Plan, work, and review start with clean context; files preserve the work. |
| Scope every verify | Prefer store-admin only or tests only. |
| Give plan file paths | Specific inputs reduce unnecessary research reads. |
| Do not rerun all QA manually | Use qa.sh <area> --failed; run --arch once at the end. |
| Fix findings directly | Use /compound-fix instead of re-planning. |
| Sonnet by default | Use Opus for planning only; low effort for mechanical work. |
Keep CLAUDE.md short | Agents re-read these files on cold starts. |
Check /usage | Before Lane B/C. Near the limit, do Lane A or write plans; verify and review after reset. |
/compound-ask /compound-fix /compound-plan /compound-work /compound-verify /compound-review --task <slug> /compound-learnings
Unsure how it works? /compound-ask
Bug or polish? /compound-fix
Template exists? Direct prompt + qa.sh
New contract? Plan → clear → work → scoped verify → review once
PR ready? Tests-only verify → task review → fix → learnings if novel
Spend about ten minutes on human judgment before starting code generation. This is usually cheaper than asking an agent to discover the basics.
Read the issue or requirement (for example, the analysis in ecom-fullstack#137).
api/, storefront/, store-admin/, platform-admin/. An API contract change means updating the API and its callers together.
Use git log --oneline and the matching features/ folder.
Open the feature's CLAUDE.md; search docs/solutions/ with grep -ri <keyword> docs/solutions.
Note the source implementation path. Check git status and confirm the correct branch.
Inspect the running app or design yourself and write observable acceptance checks.
/compound-ask.dotnet ef migrations add.grep.0 of 8 completed
Fill in the specifics before handing the task to Claude. Keep the scope explicit.
Goal: <one sentence> Folders: <store-admin | api | ...> Template to follow: <path to a finished similar feature> Source to port from: <path> Acceptance: <2–3 observable checks> Constraints: <e.g. raw SQL via DbUp, no EF migrations; update API and caller together> Run when done: .claude/compound/qa.sh <area> Do not: explore unrelated folders, refactor beyond this task.
Savings are reasoned estimates, except Solo mode and qa.sh, which are based on measurements recorded in .claude/compound/qa.sh and compound-work.md.
Note /usage before starting a task.
Complete one task with the old workflow and a similar task with this workflow.
Measure the difference, then keep the steps that actually help.
docs/solutions/ search. If the area has known pitfalls, run /compound-ask first.