.claude/skills/feature-dev/SKILL.md
Template-driven full-stack feature development from user stories. Orchestrates the complete pipeline: issue template reading, duplication check, GitHub issue creation, branch/worktree setup, PRD generation with agent-browser verification, Ralph JSON conversion, commit/push, and Ralph execution. Use when you have user stories ready to implement. Triggers on: feature dev, implement story, build feature from story, story to feature, template-driven, agent-browser verification.
npx skillsauth add ruska-ai/orchestra feature-devInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Converts one or more user stories into a fully implemented feature by orchestrating the complete development pipeline: issue creation, branch setup, PRD generation, Ralph conversion, and autonomous execution.
STORY: $ARGUMENTS.story (optional if url is provided)
URL: $ARGUMENTS.url (optional if story is provided)
ORCHESTRA_PROJECT_ROOT: The orchestra project root — the git repository root where .claude/, .worktrees/, and Makefile live. Resolve via git rev-parse --show-toplevel. All paths in this skill are anchored to this variable. Always cd $ORCHESTRA_PROJECT_ROOT before running commands to ensure worktrees are created in the correct location.
PLAN_TEMPLATE_PATH: .github/ISSUE_TEMPLATE/feature_request.md
WORKSPACE_DOCS: orchestra/wiki
Exactly one of story or url must be provided.
storySingle story:
story="As a user, I want to export chat history as PDF so that I can share conversations offline."
Multiple stories (newline-separated or numbered):
story="1. As a developer, I want tool inputs collapsed by default so that chat is less noisy.
2. As a user, I want to expand tool inputs on click so that I can inspect them.
3. As a user, I want a toggle to show/hide all tool inputs at once."
All input stories are grouped into a single feature — one GitHub issue, one PRD, one Ralph run.
urlurl="https://github.com/ruska-ai/orchestra/issues/810"
When url is provided the skill extracts all context from the existing issue:
gh issue view <URL> --json number,title,body,labelsCommit after every phase that produces artifacts. Each phase's output should be committed and pushed immediately so that:
The pattern at the end of each artifact-producing phase:
cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>
git add <phase artifacts>
git commit -s -m "<phase commit message>"
git push
MANDATORY first step. Read the issue template to extract conventions before any other work.
$ORCHESTRA_PROJECT_ROOT/.github/ISSUE_TEMPLATE/feature_request.mdfeat/[issue#]-[shortdesc])FROM feat/[issue#]-[shortdesc] TO development)$WORKSPACE/.worktrees/feat-[issue#])agent-browser for E2E)$ORCHESTRA_PROJECT_ROOT/wiki for feature context and documentationurl was provided:https://github.com/<owner>/<repo>/issues/<number>)gh issue view <URL> --json number,title,body,labels## Feature Scope (from Issue #<number>)
**Issue**: #<number> - <title>
**Feature name**: <feature-name>
**Stories** (<N> total):
- US-001: <story 1>
- US-002: <story 2>
...
Does this look correct? (y/n)
story was provided:export-chat-pdf)## Feature Scope
**Feature name**: <feature-name>
**Stories** (<N> total):
- US-001: <story 1>
- US-002: <story 2>
...
Does this look correct? (y/n)
Skipped when
urlis provided — the issue already exists on GitHub.
Check for existing work that overlaps with this feature:
gh issue list --search "<feature keywords>" --state open --json number,title,urlgh issue list --search "<feature keywords>" --state closed --json number,title,urlgit branch -a | grep -i "<feature keywords>" (case-insensitive search)git worktree listSkipped when
urlis provided — the issue already exists on GitHub.
## User Stories
- As a **[role]**, I want **[capability]** so that **[benefit]**.
- ...
## Summary
<Brief description synthesized from the stories>
## Acceptance Criteria
- [ ] All user stories implemented and verified
- [ ] Typecheck passes
- [ ] Tests pass (if applicable)
gh issue create --title "feat: <feature-name>" --body "<body>" --label "enhancement"feat/<issue#>-<feature-name>$ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>git fetch origin developmentgit worktree add $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> -b feat/<issue#>-<feature-name> origin/developmentcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && bash $ORCHESTRA_PROJECT_ROOT/backend/scripts/changelog.shcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git add Changelog.md && git commit -s -m "init feat/<issue#>-<feature-name>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git push -u origin feat/<issue#>-<feature-name>gh issue comment <issue#> --body "$(cat <<'EOF'
## Implementation Started
**Branch**: `feat/<issue#>-<feature-name>`
**Worktree**: `$ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>`
**PR title**: `FROM feat/<issue#>-<feature-name> TO development`
EOF
)"
cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && gh pr create \
--draft \
--base development \
--title "FROM feat/<issue#>-<feature-name> TO development" \
--body "$(cat <<'EOF'
## Summary
Resolves #<issue#>
## Status
Pipeline in progress — this PR will be marked ready for review when Ralph completes.
Generated by `/feature-dev` skill.
EOF
)"
MANDATORY before PRD generation. Enter plan mode to research the codebase and triage the best implementation approach. This prevents the PRD from being generated blindly.
cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>$ORCHESTRA_PROJECT_ROOT/wiki for feature context.claude/plans/feat-<issue#>/plan-0.md:
mkdir -p $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.claude/plans/feat-<issue#>.claude/plans/feat-<issue#>/plan-0.md — this file becomes the input for PRD generation in Phase 5## Implementation Plan for #<issue#>: <feature-name>
### Affected Areas
- <file/module 1>: <what changes>
- <file/module 2>: <what changes>
...
### Proposed Story Breakdown
1. <story 1> (schema/backend/frontend)
2. <story 2>
...
### Risks & Open Questions
- <any blockers or decisions needed>
### Approach
<brief summary of implementation strategy>
Plan stored at: `.claude/plans/feat-<issue#>/plan-0.md`
This phase produces two artifacts in sequence: the PRD markdown file (via /prd), then the Ralph JSON config (via /ralph). The output of /prd is the direct input to /ralph.
/prd skill with the approved plan and stories:
Load the prd skill and create a PRD for:
Feature: <feature-name> (Issue #<issue#>)
## Approved Implementation Plan
<plan from Phase 4>
## User Stories
<all stories from STORY variable or extracted from issue>
IMPORTANT sizing rules for Ralph compatibility:
- Each user story must be completable in ONE iteration (one context window)
- One story should touch 1-3 files max
- Backend and frontend changes are SEPARATE stories
- Schema/migration changes are SEPARATE from logic that uses them
- If a task spans >3 files, SPLIT into multiple stories
- Dependency order: Schema -> Backend -> Frontend -> Integration
- Add "Typecheck passes" to every story
- Add "Verify in browser using agent-browser skill" to UI stories
tasks/prd-<feature-name>.mdcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git add tasks/prd-<feature-name>.mdcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git commit -s -m "docs: add PRD for #<issue#>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git pushFeed tasks/prd-<feature-name>.md from Step 1 directly into the /ralph skill.
/ralph skill with the PRD file as input (archiving already handled in Phase 4):
Load the ralph skill and convert tasks/prd-<feature-name>.md to .ralph/prd.json
CRITICAL: Set branchName to "feat/<issue#>-<feature-name>" (must match the worktree branch exactly). Do NOT use the "ralph/" prefix.
.ralph/prd.json exists and contains valid JSONfeat/<issue#>-<feature-name>:
jq -r '.branchName' .ralph/prd.jsoncd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git add .ralph/prd.json .ralph/progress.txtcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git commit -s -m "chore: add Ralph config for #<issue#>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git pushOnly applies to features with UI changes. Skip if the feature is backend-only.
For features that modify UI:
agent-browser screenshot:
tasks/screenshots/feat-<issue#>-before.pngcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git add tasks/screenshots/cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git commit -s -m "docs: add before screenshots for #<issue#>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git pushAll artifacts have been committed and pushed incrementally in previous phases. This phase archives Ralph artifacts, catches any stragglers, generates a reviewer report, and marks the draft PR as ready for review.
archive/feat-<issue#>/:
mkdir -p $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/archive/feat-<issue#>cp $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/prd.json $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/archive/feat-<issue#>/prd.jsoncp $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/progress.txt $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/archive/feat-<issue#>/progress.txtrm $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/prd.json $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/progress.txtcd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git add .ralph/archive/feat-<issue#>/ && git add -A && git commit -s -m "chore: archive Ralph artifacts for #<issue#>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git push.ralph/archive/feat-<issue#>/progress.txt and tasks/prd-<feature-name>.md to summarize what was implemented## Summary
Resolves #<issue#>
## What Changed
- <bullet summary of implemented stories and key changes>
## Stories Completed
- [x] US-001: <title>
- [x] US-002: <title>
...
## Testing
- <how to verify the changes>
- <any agent-browser screenshots or evidence>
## Notes
- <any caveats, follow-ups, or reviewer callouts>
Generated by `/feature-dev` skill.
cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && gh pr edit --body "<reviewer report>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && gh pr readytmux new-session -d -s feat-<issue#> -c $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> "make -C $ORCHESTRA_PROJECT_ROOT ralph"# Attach to Ralph session
tmux attach -t feat-<issue#>
# Check progress
cat $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/progress.txt
## Feature Dev Complete
**Issue**: #<issue#> - feat: <feature-name>
**Branch**: feat/<issue#>-<feature-name>
**Worktree**: $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>
**PR**: <PR URL> (draft → ready for review)
**PRD**: tasks/prd-<feature-name>.md
**Ralph config**: .ralph/prd.json (<N> user stories)
**Tmux session**: feat-<issue#>
### Stories
- US-001: <title>
- US-002: <title>
...
### Next Steps
- Monitor: `tmux attach -t feat-<issue#>`
- Progress: `cat $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#>/.ralph/progress.txt`
When the feature involves an embeddable widget, iframe component, or any asset served outside the main SPA:
npm run build:embed (runs vite.embed.config.ts)outDir must be ../backend/src/public/embed/ — NOT frontend/dist/embed/vite.embed.config.ts outDir is set to ../backend/src/public/embed//embed via StaticFiles pointing at src/public/embed/os.path.isfile() guard before serving index.htmlapiBase from new URL(document.currentScript.src).origin, NOT window.location.origin. Include this as an acceptance criterion for any embed widget story.integration-qa agent to validate build ↔ serve alignment before marking the PR ready.Known build targets:
| Command | Config | Output | Served at |
|---------|--------|--------|-----------|
| npm run build | vite.config.ts | frontend/dist/ | SPA root / |
| npm run build:embed | vite.embed.config.ts | backend/src/public/embed/ | /embed/ |
.claude/plans/feat-<issue#>/plan-0.md — these become PRD inputorchestra/wiki — consult for feature context and documentationfeat/ prefix, NOT ralph/ — it must match the worktree branch exactly-s flag) per repository guidelinesnpm run build:embed — the standard npm run build does NOT produce embed assetsintegration-qa agent after Ralph completes any feature touching build configs, API routes, or static file servingstory nor url provided: REPORT "You must provide either story or url. See examples below."gh auth status"story argument."git worktree remove $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> first."/prd manually."/ralph manually."feat/<issue#>-<feature-name>cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && git push -u origin feat/<issue#>-<feature-name>"cd $ORCHESTRA_PROJECT_ROOT/.worktrees/feat-<issue#> && make -C $ORCHESTRA_PROJECT_ROOT ralph"/feature-dev url="https://github.com/ruska-ai/orchestra/issues/810"
Extracts stories from issue #810, skips duplication check and issue creation, then:
feat/810-<slugified-title>$ORCHESTRA_PROJECT_ROOT/.worktrees/feat-810/feature-dev story="As a user, I want to export chat history as PDF so that I can share conversations offline."
Creates:
feat: export-chat-pdffeat/801-export-chat-pdf./.worktrees/feat-801feat-801/feature-dev story="1. As a developer, I want tool inputs collapsed by default so that chat is less noisy.
2. As a user, I want to expand tool inputs on click so that I can inspect them.
3. As a user, I want a toggle to show/hide all tool inputs at once."
Creates:
feat: collapsible-tool-inputsfeat/802-collapsible-tool-inputs./.worktrees/feat-802feat-802tools
Apply coordinated changes across multiple files efficiently using parallel Edit tool calls. Use when making systematic changes like renaming variables, updating imports, applying pattern changes, or refactoring across files. Triggers on: rename across files, update all imports, change pattern in multiple files, refactor across codebase, batch edit files.
testing
Record browser workflows as video and convert to high-quality GIFs using agent-browser and ffmpeg. Use when users ask to record workflow, create gif, record demo, browser recording, workflow gif, or screen recording.
development
Run and verify frontend tests for the React/Vite application.
development
Run and verify backend tests for the FastAPI/Python application.