ralph
This skill should be used when the user wants to set up an autonomous coding loop, plan a Ralph loop, prepare for headless Claude execution, create a spec and implementation plan for autonomous coding, or run an autonomous development workflow. Trigger phrases include "ralph", "autonomous loop", "coding loop", "ralph prep", "set up ralph", "headless loop", "autonomous coding", "ralph plan".
What this skill does
# Ralph — Autonomous Coding Loop An autonomous coding loop where Claude executes one task per iteration with a fresh context window. The spec and implementation plan are the single source of truth — not conversation history. Context rot is structurally impossible. ## Core Principle Each loop iteration is a clean `claude -p` invocation. The loop script dynamically assembles each iteration's prompt from ONLY the spec sections and codebase files that task declares it needs. Context waste is zero. ## Planning Phase Workflow You are in the planning phase. Your job is to help the user go from an idea to a complete spec and implementation plan, ready for autonomous execution. ### Step 0: Load Planning Framework Load the planning questions framework: @references/planning-questions.md ### Step 1: Brain-Dump Capture Ask questions from the framework ONE AT A TIME. Skip questions the user already answered. Use multiple choice when possible. Goal: understand what they're building, current codebase state, what "done" looks like, constraints. ### Step 2: Bidirectional Questioning After you understand the project, share your assumptions as a numbered list. Explicitly invite the user to correct them AND to ask you questions back. This surfaces hidden assumptions — the #1 source of bugs in autonomous execution. Say: "Now I'll share what I'm assuming. Tell me where I'm wrong, and then ask ME any questions about what I'll be building." ### Step 3: Generate Spec Load the spec template: @references/spec-template.md Generate `docs/ralph/SPEC.md` following the template. Present it to the user section by section. The user MUST review and approve every section. They own this file. Rules: - Section names are lowercase kebab-style (used as identifiers in task frontmatter) - Each section under 50 lines - `goal` and `constraints` are almost always needed - Domain sections are project-specific — use what fits Create the directory structure: ```bash mkdir -p docs/ralph/tasks docs/ralph/logs ``` Write the spec file to `docs/ralph/SPEC.md`. ### Step 4: Generate Plan Load the plan template: @references/plan-template.md Generate `docs/ralph/PLAN.md` (lightweight checkbox index) and individual task files in `docs/ralph/tasks/NN-kebab-title.md`. For each task file, include YAML frontmatter with: - `spec-sections`: Which SPEC.md sections this task needs (array of section heading names) - `codebase-files`: Which existing project files Claude needs to see (array of paths) Present the plan to the user. They must approve the task list, ordering, and per-task context declarations. ### Step 5: Context-Aware Validation The iteration protocol that Claude reads each loop iteration is defined in: @references/iteration-protocol.md For each task, estimate context load: - Sum the line counts of declared spec sections + declared codebase files + task body + iteration protocol (~60 lines) - Flag any task estimated to exceed ~1500 lines of combined input - Suggest decomposition for oversized tasks ### Step 6: Handoff Tell the user: > "Your spec and plan are ready in `docs/ralph/`. To launch the autonomous loop, run `/ralph start`." Do NOT launch the loop yourself. The `/ralph start` command handles that. ## Important Constraints - **Human owns the spec.** Draft it, present it, let them edit. Never auto-finalize. - **One question at a time.** Don't overwhelm during brain-dump capture. - **Lean artifacts.** Every byte in the spec and plan is read every iteration. Bloat degrades performance. - **Tasks must be atomic.** Each task completable in one context window. When in doubt, split. - **Filesystem-first state.** All state persists through files. Nothing relies on conversation history.
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.