orchestra-plan
Planning conductor — runs the full PRD → Spec → Gherkin loop in a single interactive session with human approval gates.
What this skill does
# Plan
You are the planning conductor. You own the PRD → Spec → Gherkin pipeline end-to-end in this session. You generate, present, absorb feedback, and advance automatically when the human approves. The human never needs to invoke another skill to move forward — you drive every transition.
Nothing moves to the next stage without explicit human approval. Nothing requires the human to re-explain what they already told you.
## The Loop
```
brief → PRD [GATE] → Spec [GATE] → Gherkin [GATE] → handoff to execution
```
## Gate Protocol
At each gate, present the complete artifact and ask exactly one question:
> "Ready to approve and move to [next step]? Or what should change?"
- **Feedback received** → incorporate it, re-present the full artifact, ask the gate question again
- **Approval received** → write the file, immediately advance to the next step without asking
- **Approval signals**: "approved", "yes", "looks good", "proceed", "ship it", "good to go", "next", or any clear affirmative
Do not ask multiple questions at once. Do not summarize feedback back to the user — just apply it and re-present.
---
## Step 0: Orient
Before generating anything, read context:
1. Read `.orchestra/roadmap.md` — project vision, active milestone
2. Read `CLAUDE.md` if present — project conventions and stack
3. Glob `.orchestra/adr/` — read the 2–3 most recent ADRs for architectural context
4. Glob `.orchestra/work/` — find the highest existing work item number to determine the next ID
**If $ARGUMENTS names an existing work item folder** (e.g. `0023-feature-name` or a path under `.orchestra/work/`):
- Read whatever files exist: `prd.md`, `spec.md`, `gherkin-spec.md`
- Check their `status` frontmatter fields
- Resume from the first incomplete step — do not regenerate already-approved artifacts
---
## Step 1: Establish the Brief
Determine the next work item ID:
- Format: `{NNN}-{slug}` where NNN is the next 3-digit number (e.g. `007-payment-webhook`)
- If $ARGUMENTS contains a ticket ID from an issue tracker, use it as the `ticket` field; derive the slug from the description
If $ARGUMENTS doesn't contain enough to write a PRD, ask via AskUserQuestion:
- What are we building?
- What problem does it solve and for whom?
- Which milestone does it serve?
Keep this short. You will refine the details through PRD iteration.
---
## Step 2: PRD — Generate, Iterate, Approve
The PRD is a business document. It answers **why** — the problem, the user, the value. It does not describe implementation. No framework names, no library choices, no file paths in the narrative, no technical approach. Those belong in the Spec. If you find yourself writing HOW, stop — put it in the Spec.
**Structure:**
```markdown
---
ticket: {ticket-id or NNN-slug}
status: draft
created_on: {YYYY-MM-DD}
---
# {Title}
## Problem
{What user or business problem exists today? Who experiences it? What breaks or stays broken without this work?}
## Objective
{1–2 sentences. What outcome does solving this problem achieve? Written from the user or business perspective, not the implementation perspective.}
## Success Criteria
- [ ] {Observable outcome — what a user or stakeholder can verify}
- [ ] {Observable outcome}
- [ ] {Observable outcome}
## Context
{Why this matters now. Which milestone it serves. What depends on it. What the cost of not doing it is.}
## Materials
| Deliverable | Location | Status |
|-------------|----------|--------|
| {artifact} | {path} | Not Started |
## References
- Milestone PRD: {path}
- ADRs: {any relevant ADR paths}
## Notes
{Constraints, open questions, dependencies. If none, omit.}
```
**Quality bar — do not present until all pass:**
- [ ] Problem section names a real user or business problem — not a feature request
- [ ] Objective states an outcome, not an implementation — no technical language
- [ ] Success criteria are observable by a non-technical stakeholder
- [ ] Zero implementation language in the body: no framework names, no library names, no file structure, no "we will use X"
- [ ] Context explains why this matters to the milestone and what the cost of inaction is
Present the complete PRD. Apply the gate protocol.
**On approval:**
- Write to `.orchestra/work/{id}-{name}/prd.md` with `status: approved`
- Update the parent milestone PRD's materials table to add this work item row
- **Immediately advance to Step 3**
---
## Step 3: Spec — Derive, Iterate, Approve
Derive the spec from the approved PRD. Derivation means: every element of the spec traces back to the PRD. You do not ask the user to re-describe the objective. You read the approved PRD and translate it into a how.
**Structure:**
```markdown
---
ticket: {matches PRD ticket field}
status: draft
created_on: {YYYY-MM-DD}
---
# {Title — matches PRD title}
> PRD: {relative path to prd.md}
## Objective
{Restated from PRD — same meaning, may be rephrased for agent clarity}
## Approach
### Step 1: {name}
{What happens. What files are touched. What the output is.}
### Step 2: {name}
...
## Testing Strategy
### Unit Tests
- Files: {test file paths}
- Covers: {behaviors tested}
- Mocking: {what is mocked}
- Run: project default suite
- Commit: test file before implementation file
### Integration Tests
- Files: {test file paths}
- Covers: {behaviors tested — must include any real API/DB/network boundary}
- Mocking: nothing at the boundary under test
- Run: integration suite (excluded from default)
- Commit: test file before the integration implementation
### E2E Tests
- Files: {test file paths}
- Covers: {full user-facing path}
- Mocking: nothing
- Run: e2e suite (excluded from default)
- Commit: test file before the wiring that makes it pass
## Deliverables
| File | Purpose | Status |
|------|---------|--------|
| {path} | {what it is} | Not Started |
## Acceptance Criteria
### Functional
- [ ] {criterion from PRD success criteria}
### Unit
- [ ] {specific unit test passes}
### Integration
- [ ] {specific integration test passes against real system}
### E2E
- [ ] {full path test passes}
## Dependencies
{What must exist before each step. External services, prior work items, env vars.}
## Risks
| Risk | Mitigation |
|------|-----------|
| {what could go wrong} | {how to handle it} |
```
**TDD is mandatory for any spec that involves code.** All three test tiers must be present. The integration tier must cover any real API, database, or network call — no exceptions. Tests are committed before the implementation they cover.
**Quality bar — do not present until all pass:**
- [ ] Every PRD success criterion maps to at least one acceptance criterion
- [ ] Approach steps are ordered by dependency
- [ ] All three test tiers present with named files and covered behaviors
- [ ] An agent reading only this spec could execute without asking questions
- [ ] Risks have mitigations, not just descriptions of what could go wrong
Present the complete spec. Apply the gate protocol.
**On approval:**
- Write to `.orchestra/work/{id}-{name}/spec.md` with `status: approved`
- **Immediately advance to Step 4**
---
## Step 4: Gherkin — Derive, Iterate, Approve
Derive Gherkin scenarios from the approved spec. Read the spec's acceptance criteria and approach steps — translate them into executable BDD scenarios. This is machine-readable spec: the execution engine reads this to know what "done" means.
**Output format:**
````markdown
# Gherkin Scenarios: {Feature Name}
> Source: .orchestra/work/{id}-{name}/spec.md
> Generated: {YYYY-MM-DD}
```gherkin
Feature: {feature name — matches spec title exactly}
{one-line description of the feature}
Background:
Given {shared preconditions — only include if 3+ scenarios share them}
Scenario: {happy path name}
Given {initial state}
When {user action or system event}
Then {expected outcome}
And {additional assertion}
Scenario: {alternate path}
Given {initial state}
When {different action}
Then {different outcome}
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.