ralph-hats
Ralph Hats
Use this skill to operate the full Ralph hat lifecycle for user-authored hat collections.
Use This Skill For
- Creating a new hat collection in
.ralph/hats/ - Inspecting an existing hat collection and explaining its topology
- Validating trigger routing, event flow, and completion behavior
- Improving or refactoring hats for clearer roles and safer routing
- Recommending better orchestration patterns for a Ralph workflow
Core Assumptions
- Core runtime config already lives in
ralph.ymlor another-csource. - User-authored hats are stored separately and passed with
-H. - This skill operates public hat collections, not Ralph built-in presets.
Workflow
- If a hats file already exists, read it first and explain the current topology before proposing changes.
- If creating a new workflow, write it to
.ralph/hats/<name>.yml. - Keep the hats file focused on hats-only data. Leave runtime limits and other core config in the main config file.
- Validate with
ralph hats validate. - Visualize topology with
ralph hats graphwhen the event flow is not trivial. - Use
ralph hats show <hat>when you need to inspect one hat's effective configuration. - When the user wants stronger confidence, run a targeted
ralph run -c ... -H ... -p "..."exercise or provide the exact test command.
Guardrails
- Only use hats-file top-level keys that Ralph accepts today:
name,description,events,event_loop,hats. - In a hats file,
event_loopis only for hats overlay keys such asstarting_eventandcompletion_promise. - Never use
task.startortask.resumeas hat triggers. Ralph reserves those for coordination. Use semantic delegated events likework.start,review.start, orresearch.start. - Each trigger must route to exactly one hat.
- Keep
descriptionpopulated on every hat. - Prefer
events:metadata when custom event names would otherwise be opaque. - Do not write user workflows into
presets/from this skill.
Output Expectations
- When editing or creating hats, produce the file changes and the validation result.
- When only inspecting, produce a concise topology summary, the main risks, and concrete improvement options.
Read These References When Needed
- For current hats schema and supported fields:
references/schema.md - For command recipes and validation workflow:
references/commands.md - For pattern and file examples:
references/examples.md
More from mikeyobrien/ralph-orchestrator
ralph-loop
Run, monitor, resume, merge, and debug Ralph loops. Use this skill whenever the user asks to operate `ralph run` or `ralph loops`, inspect loop state, recover suspended loops, analyze diagnostics, or unblock merge queue issues.
84pdd
Transforms a rough idea into a detailed design document with implementation plan. Follows Prompt-Driven Development — iterative requirements clarification, research, design, and planning.
52tui-validate
Validates Terminal User Interface (TUI) output using freeze for screenshot capture and LLM-as-judge for semantic validation. Supports both visual (PNG/SVG) and text-based validation modes.
44code-assist
Guides implementation of code tasks using test-driven development in an Explore, Plan, Code, Commit workflow. Acts as a Technical Implementation Partner and TDD Coach — following existing patterns, avoiding over-engineering, and producing idiomatic, modern code.
42tmux-terminal
Interactive terminal control via tmux for TUI apps, prompts, and long-running CLI workflows.
38code-task-generator
Generates structured .code-task.md files from descriptions or PDD implementation plans. Auto-detects input type, creates properly formatted tasks with Given-When-Then acceptance criteria.
37