nemonix-cli 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (281) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +186 -0
  3. package/dist/cli.js +6870 -0
  4. package/package.json +48 -0
  5. package/src/config/claude-code-config/.claude/commands/setup-tmux.md +0 -0
  6. package/src/config/claude-code-config/CHANGELOG.md +261 -0
  7. package/src/config/claude-code-config/README.md +1 -0
  8. package/src/config/claude-code-config/agents/action.md +36 -0
  9. package/src/config/claude-code-config/agents/clean-code-runner.md +61 -0
  10. package/src/config/claude-code-config/agents/code-reviewer.md +172 -0
  11. package/src/config/claude-code-config/agents/code-simplifier.md +49 -0
  12. package/src/config/claude-code-config/agents/explore-codebase.md +65 -0
  13. package/src/config/claude-code-config/agents/explore-docs.md +65 -0
  14. package/src/config/claude-code-config/agents/explore-fast.md +22 -0
  15. package/src/config/claude-code-config/agents/implementer.md +181 -0
  16. package/src/config/claude-code-config/agents/snipper.md +36 -0
  17. package/src/config/claude-code-config/agents/websearch.md +42 -0
  18. package/src/config/claude-code-config/commands/prompts/create-vitejs-app.md +272 -0
  19. package/src/config/claude-code-config/commands/prompts/nextjs-add-prisma-db.md +136 -0
  20. package/src/config/claude-code-config/commands/prompts/nextjs-setup-better-auth.md +173 -0
  21. package/src/config/claude-code-config/commands/prompts/nextjs-setup-project.md +200 -0
  22. package/src/config/claude-code-config/commands/prompts/prompt.md +55 -0
  23. package/src/config/claude-code-config/commands/prompts/saas-challenge-idea.md +135 -0
  24. package/src/config/claude-code-config/commands/prompts/saas-create-architecture.md +242 -0
  25. package/src/config/claude-code-config/commands/prompts/saas-create-headline.md +132 -0
  26. package/src/config/claude-code-config/commands/prompts/saas-create-landing-copywritting.md +267 -0
  27. package/src/config/claude-code-config/commands/prompts/saas-create-legals-docs.md +176 -0
  28. package/src/config/claude-code-config/commands/prompts/saas-create-logos.md +240 -0
  29. package/src/config/claude-code-config/commands/prompts/saas-create-prd.md +195 -0
  30. package/src/config/claude-code-config/commands/prompts/saas-create-tasks.md +240 -0
  31. package/src/config/claude-code-config/commands/prompts/saas-define-pricing.md +293 -0
  32. package/src/config/claude-code-config/commands/prompts/saas-find-domain-name.md +190 -0
  33. package/src/config/claude-code-config/commands/prompts/saas-implement-landing-page.md +257 -0
  34. package/src/config/claude-code-config/commands/prompts/setup-tmux.md +160 -0
  35. package/src/config/claude-code-config/commands/prompts/tools.md +148 -0
  36. package/src/config/claude-code-config/hooks/hook-post-file.ts +162 -0
  37. package/src/config/claude-code-config/scripts/.claude/skills/fix-on-my-computer/SKILL.md +81 -0
  38. package/src/config/claude-code-config/scripts/CLAUDE.md +50 -0
  39. package/src/config/claude-code-config/scripts/auto-rename-session/CLAUDE.md +59 -0
  40. package/src/config/claude-code-config/scripts/auto-rename-session/__tests__/shared.test.ts +185 -0
  41. package/src/config/claude-code-config/scripts/auto-rename-session/__tests__/title-generation.test.ts +44 -0
  42. package/src/config/claude-code-config/scripts/auto-rename-session/fixtures/sample-transcript.jsonl +3 -0
  43. package/src/config/claude-code-config/scripts/auto-rename-session/fixtures/transcript-short-message.jsonl +2 -0
  44. package/src/config/claude-code-config/scripts/auto-rename-session/fixtures/transcript-with-title.jsonl +3 -0
  45. package/src/config/claude-code-config/scripts/auto-rename-session/src/index.ts +113 -0
  46. package/src/config/claude-code-config/scripts/auto-rename-session/src/rename-all.ts +148 -0
  47. package/src/config/claude-code-config/scripts/auto-rename-session/src/shared.ts +157 -0
  48. package/src/config/claude-code-config/scripts/auto-rename-session/src/worker.ts +58 -0
  49. package/src/config/claude-code-config/scripts/biome.json +37 -0
  50. package/src/config/claude-code-config/scripts/claude-code-ai/CLAUDE.md +84 -0
  51. package/src/config/claude-code-config/scripts/claude-code-ai/__tests__/claude.test.ts +19 -0
  52. package/src/config/claude-code-config/scripts/claude-code-ai/__tests__/paths.test.ts +68 -0
  53. package/src/config/claude-code-config/scripts/claude-code-ai/claude.ts +56 -0
  54. package/src/config/claude-code-config/scripts/claude-code-ai/cli.ts +46 -0
  55. package/src/config/claude-code-config/scripts/claude-code-ai/helper/credentials.ts +76 -0
  56. package/src/config/claude-code-config/scripts/claude-code-ai/helper/index.ts +9 -0
  57. package/src/config/claude-code-config/scripts/claude-code-ai/helper/paths.ts +51 -0
  58. package/src/config/claude-code-config/scripts/command-validator/CLAUDE.md +112 -0
  59. package/src/config/claude-code-config/scripts/command-validator/README.md +147 -0
  60. package/src/config/claude-code-config/scripts/command-validator/src/__tests__/validator.test.ts +99 -0
  61. package/src/config/claude-code-config/scripts/command-validator/src/cli.ts +121 -0
  62. package/src/config/claude-code-config/scripts/command-validator/src/lib/security-rules.ts +174 -0
  63. package/src/config/claude-code-config/scripts/command-validator/src/lib/types.ts +34 -0
  64. package/src/config/claude-code-config/scripts/command-validator/src/lib/validator.ts +90 -0
  65. package/src/config/claude-code-config/scripts/package.json +43 -0
  66. package/src/config/claude-code-config/scripts/statusline/CLAUDE.md +205 -0
  67. package/src/config/claude-code-config/scripts/statusline/README.md +193 -0
  68. package/src/config/claude-code-config/scripts/statusline/__tests__/context.test.ts +229 -0
  69. package/src/config/claude-code-config/scripts/statusline/__tests__/formatters.test.ts +108 -0
  70. package/src/config/claude-code-config/scripts/statusline/__tests__/statusline.test.ts +309 -0
  71. package/src/config/claude-code-config/scripts/statusline/data/.gitkeep +0 -0
  72. package/src/config/claude-code-config/scripts/statusline/defaults.json +82 -0
  73. package/src/config/claude-code-config/scripts/statusline/docs/ARCHITECTURE.md +166 -0
  74. package/src/config/claude-code-config/scripts/statusline/fixtures/mock-transcript.jsonl +4 -0
  75. package/src/config/claude-code-config/scripts/statusline/fixtures/test-input.json +35 -0
  76. package/src/config/claude-code-config/scripts/statusline/src/analyze-daily-usage.ts +151 -0
  77. package/src/config/claude-code-config/scripts/statusline/src/commands/interactive-config.ts +515 -0
  78. package/src/config/claude-code-config/scripts/statusline/src/debug-payloads.ts +195 -0
  79. package/src/config/claude-code-config/scripts/statusline/src/index.ts +224 -0
  80. package/src/config/claude-code-config/scripts/statusline/src/lib/config-types.ts +110 -0
  81. package/src/config/claude-code-config/scripts/statusline/src/lib/config.ts +21 -0
  82. package/src/config/claude-code-config/scripts/statusline/src/lib/context.ts +103 -0
  83. package/src/config/claude-code-config/scripts/statusline/src/lib/features/limits/commands/weekly-analysis.ts +108 -0
  84. package/src/config/claude-code-config/scripts/statusline/src/lib/features/limits/index.ts +111 -0
  85. package/src/config/claude-code-config/scripts/statusline/src/lib/features/limits/types.ts +15 -0
  86. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/commands/migrate-to-sqlite.ts +136 -0
  87. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/commands/spend-day.ts +79 -0
  88. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/commands/spend-month.ts +66 -0
  89. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/commands/spend-project.ts +85 -0
  90. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/database.ts +395 -0
  91. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/index.ts +178 -0
  92. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/payload-logger.ts +161 -0
  93. package/src/config/claude-code-config/scripts/statusline/src/lib/features/spend/types.ts +37 -0
  94. package/src/config/claude-code-config/scripts/statusline/src/lib/formatters.ts +426 -0
  95. package/src/config/claude-code-config/scripts/statusline/src/lib/git.ts +100 -0
  96. package/src/config/claude-code-config/scripts/statusline/src/lib/menu-factories.ts +224 -0
  97. package/src/config/claude-code-config/scripts/statusline/src/lib/presets.ts +177 -0
  98. package/src/config/claude-code-config/scripts/statusline/src/lib/render-pure.ts +516 -0
  99. package/src/config/claude-code-config/scripts/statusline/src/lib/types.ts +36 -0
  100. package/src/config/claude-code-config/scripts/statusline/src/lib/utils.ts +15 -0
  101. package/src/config/claude-code-config/scripts/statusline/src/stats.ts +119 -0
  102. package/src/config/claude-code-config/scripts/statusline/src/tests/spend-v2.test.ts +377 -0
  103. package/src/config/claude-code-config/scripts/statusline/src/tools/fixed-cost-calc.ts +317 -0
  104. package/src/config/claude-code-config/scripts/statusline/statusline.config.free.json +79 -0
  105. package/src/config/claude-code-config/scripts/statusline/statusline.config.json +100 -0
  106. package/src/config/claude-code-config/scripts/statusline/test-with-fixtures.ts +37 -0
  107. package/src/config/claude-code-config/scripts/statusline/test.ts +20 -0
  108. package/src/config/claude-code-config/scripts/statusline/tsconfig.json +27 -0
  109. package/src/config/claude-code-config/scripts/tsconfig.json +27 -0
  110. package/src/config/claude-code-config/settings.json +92 -0
  111. package/src/config/claude-code-config/skills/aibuilder-create-saas/SKILL.md +176 -0
  112. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/architecture-template.md +436 -0
  113. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/challenge-framework.md +289 -0
  114. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/discovery-framework.md +338 -0
  115. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/prd-template.md +452 -0
  116. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/task-template.md +263 -0
  117. package/src/config/claude-code-config/skills/aibuilder-create-saas/references/tools.md +132 -0
  118. package/src/config/claude-code-config/skills/aibuilder-create-saas/scripts/rename-project.sh +42 -0
  119. package/src/config/claude-code-config/skills/aibuilder-create-saas/scripts/setup.sh +104 -0
  120. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-00-init.md +174 -0
  121. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-01-discovery.md +342 -0
  122. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-02-brainstorm.md +230 -0
  123. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-03-validate.md +372 -0
  124. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-04-prd.md +364 -0
  125. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-05-architecture.md +904 -0
  126. package/src/config/claude-code-config/skills/aibuilder-create-saas/steps/step-06-tasks.md +446 -0
  127. package/src/config/claude-code-config/skills/explore/SKILL.md +119 -0
  128. package/src/config/claude-code-config/skills/frontend-design/LICENSE.txt +177 -0
  129. package/src/config/claude-code-config/skills/frontend-design/SKILL.md +42 -0
  130. package/src/config/claude-code-config/skills/git-commit/SKILL.md +42 -0
  131. package/src/config/claude-code-config/skills/git-create-pr/SKILL.md +53 -0
  132. package/src/config/claude-code-config/skills/git-fix-pr-comments/SKILL.md +51 -0
  133. package/src/config/claude-code-config/skills/git-merge/SKILL.md +68 -0
  134. package/src/config/claude-code-config/skills/marketing-copywriting/SKILL.md +72 -0
  135. package/src/config/claude-code-config/skills/meta-claude-memory/SKILL.md +694 -0
  136. package/src/config/claude-code-config/skills/meta-claude-memory/references/comprehensive-example.md +175 -0
  137. package/src/config/claude-code-config/skills/meta-claude-memory/references/project-patterns.md +334 -0
  138. package/src/config/claude-code-config/skills/meta-claude-memory/references/prompting-techniques.md +411 -0
  139. package/src/config/claude-code-config/skills/meta-claude-memory/references/rules-directory-guide.md +298 -0
  140. package/src/config/claude-code-config/skills/meta-claude-memory/references/section-templates.md +347 -0
  141. package/src/config/claude-code-config/skills/meta-hooks-creator/SKILL.md +357 -0
  142. package/src/config/claude-code-config/skills/meta-hooks-creator/references/command-vs-prompt.md +287 -0
  143. package/src/config/claude-code-config/skills/meta-hooks-creator/references/examples.md +689 -0
  144. package/src/config/claude-code-config/skills/meta-hooks-creator/references/hook-types.md +495 -0
  145. package/src/config/claude-code-config/skills/meta-hooks-creator/references/input-output-schemas.md +503 -0
  146. package/src/config/claude-code-config/skills/meta-hooks-creator/references/matchers.md +517 -0
  147. package/src/config/claude-code-config/skills/meta-hooks-creator/references/troubleshooting.md +653 -0
  148. package/src/config/claude-code-config/skills/meta-prompt-creator/SKILL.md +285 -0
  149. package/src/config/claude-code-config/skills/meta-prompt-creator/references/anthropic-best-practices.md +126 -0
  150. package/src/config/claude-code-config/skills/meta-prompt-creator/references/anti-patterns.md +57 -0
  151. package/src/config/claude-code-config/skills/meta-prompt-creator/references/clarity-principles.md +54 -0
  152. package/src/config/claude-code-config/skills/meta-prompt-creator/references/context-management.md +389 -0
  153. package/src/config/claude-code-config/skills/meta-prompt-creator/references/few-shot-patterns.md +47 -0
  154. package/src/config/claude-code-config/skills/meta-prompt-creator/references/openai-best-practices.md +50 -0
  155. package/src/config/claude-code-config/skills/meta-prompt-creator/references/prompt-templates.md +110 -0
  156. package/src/config/claude-code-config/skills/meta-prompt-creator/references/reasoning-techniques.md +52 -0
  157. package/src/config/claude-code-config/skills/meta-prompt-creator/references/system-prompt-patterns.md +48 -0
  158. package/src/config/claude-code-config/skills/meta-prompt-creator/references/xml-structure.md +36 -0
  159. package/src/config/claude-code-config/skills/meta-skill-creator/LICENSE.txt +202 -0
  160. package/src/config/claude-code-config/skills/meta-skill-creator/SKILL.md +421 -0
  161. package/src/config/claude-code-config/skills/meta-skill-creator/package.json +5 -0
  162. package/src/config/claude-code-config/skills/meta-skill-creator/references/output-patterns.md +82 -0
  163. package/src/config/claude-code-config/skills/meta-skill-creator/references/progressive-disclosure-patterns.md +374 -0
  164. package/src/config/claude-code-config/skills/meta-skill-creator/references/prompting-integration.md +363 -0
  165. package/src/config/claude-code-config/skills/meta-skill-creator/references/real-world-examples.md +513 -0
  166. package/src/config/claude-code-config/skills/meta-skill-creator/references/script-patterns.md +385 -0
  167. package/src/config/claude-code-config/skills/meta-skill-creator/references/workflows.md +28 -0
  168. package/src/config/claude-code-config/skills/meta-skill-creator/references/xml-tag-guide.md +606 -0
  169. package/src/config/claude-code-config/skills/meta-skill-creator/scripts/init-skill.ts +214 -0
  170. package/src/config/claude-code-config/skills/meta-skill-creator/scripts/package-skill.ts +146 -0
  171. package/src/config/claude-code-config/skills/meta-skill-creator/scripts/validate.ts +138 -0
  172. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/SKILL.md +390 -0
  173. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/references/ask-patterns.md +225 -0
  174. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/references/prompt-engineering.md +377 -0
  175. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/references/state-management.md +275 -0
  176. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/references/step-template.md +334 -0
  177. package/src/config/claude-code-config/skills/meta-skill-workflow-creator/references/workflow-patterns.md +300 -0
  178. package/src/config/claude-code-config/skills/meta-subagent-creator/SKILL.md +451 -0
  179. package/src/config/claude-code-config/skills/meta-subagent-creator/references/context-management.md +567 -0
  180. package/src/config/claude-code-config/skills/meta-subagent-creator/references/debugging-agents.md +714 -0
  181. package/src/config/claude-code-config/skills/meta-subagent-creator/references/error-handling-and-recovery.md +502 -0
  182. package/src/config/claude-code-config/skills/meta-subagent-creator/references/evaluation-and-testing.md +374 -0
  183. package/src/config/claude-code-config/skills/meta-subagent-creator/references/orchestration-patterns.md +591 -0
  184. package/src/config/claude-code-config/skills/meta-subagent-creator/references/subagents.md +599 -0
  185. package/src/config/claude-code-config/skills/meta-subagent-creator/references/writing-subagent-prompts.md +513 -0
  186. package/src/config/claude-code-config/skills/ralph-loop/SKILL.md +117 -0
  187. package/src/config/claude-code-config/skills/ralph-loop/scripts/setup.sh +278 -0
  188. package/src/config/claude-code-config/skills/ralph-loop/steps/step-00-init.md +215 -0
  189. package/src/config/claude-code-config/skills/ralph-loop/steps/step-01-interactive-prd.md +366 -0
  190. package/src/config/claude-code-config/skills/ralph-loop/steps/step-02-create-stories.md +273 -0
  191. package/src/config/claude-code-config/skills/ralph-loop/steps/step-03-finish.md +245 -0
  192. package/src/config/claude-code-config/skills/ralph-tasks/SKILL.md +88 -0
  193. package/src/config/claude-code-config/skills/ralph-tasks/scripts/add-task.sh +36 -0
  194. package/src/config/claude-code-config/skills/ralph-tasks/scripts/list-tasks.sh +66 -0
  195. package/src/config/claude-code-config/skills/ralph-tasks/scripts/remove-task.sh +47 -0
  196. package/src/config/claude-code-config/skills/ralph-tasks/scripts/setup.sh +201 -0
  197. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-add-search.md +131 -0
  198. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-add.md +46 -0
  199. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-init.md +123 -0
  200. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-list.md +58 -0
  201. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-remove.md +48 -0
  202. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-setup.md +46 -0
  203. package/src/config/claude-code-config/skills/ralph-tasks/steps/action-wake-up.md +62 -0
  204. package/src/config/claude-code-config/skills/utils-fix-errors/SKILL.md +61 -0
  205. package/src/config/claude-code-config/skills/utils-fix-grammar/SKILL.md +59 -0
  206. package/src/config/claude-code-config/skills/utils-oneshot/SKILL.md +56 -0
  207. package/src/config/claude-code-config/skills/utils-refactor/SKILL.md +89 -0
  208. package/src/config/claude-code-config/skills/utils-save-docs/SKILL.md +74 -0
  209. package/src/config/claude-code-config/skills/utils-ultrathink/SKILL.md +42 -0
  210. package/src/config/claude-code-config/skills/workflow-apex/SKILL.md +116 -0
  211. package/src/config/claude-code-config/skills/workflow-apex/scripts/setup-templates.sh +144 -0
  212. package/src/config/claude-code-config/skills/workflow-apex/scripts/update-progress.sh +80 -0
  213. package/src/config/claude-code-config/skills/workflow-apex/steps/step-00-init.md +273 -0
  214. package/src/config/claude-code-config/skills/workflow-apex/steps/step-00b-branch.md +126 -0
  215. package/src/config/claude-code-config/skills/workflow-apex/steps/step-00b-economy.md +244 -0
  216. package/src/config/claude-code-config/skills/workflow-apex/steps/step-00b-interactive.md +165 -0
  217. package/src/config/claude-code-config/skills/workflow-apex/steps/step-00b-save.md +123 -0
  218. package/src/config/claude-code-config/skills/workflow-apex/steps/step-01-analyze.md +361 -0
  219. package/src/config/claude-code-config/skills/workflow-apex/steps/step-02-plan.md +422 -0
  220. package/src/config/claude-code-config/skills/workflow-apex/steps/step-02b-tasks.md +301 -0
  221. package/src/config/claude-code-config/skills/workflow-apex/steps/step-03-execute-teams.md +297 -0
  222. package/src/config/claude-code-config/skills/workflow-apex/steps/step-03-execute.md +239 -0
  223. package/src/config/claude-code-config/skills/workflow-apex/steps/step-04-validate.md +264 -0
  224. package/src/config/claude-code-config/skills/workflow-apex/steps/step-05-examine.md +294 -0
  225. package/src/config/claude-code-config/skills/workflow-apex/steps/step-06-resolve.md +237 -0
  226. package/src/config/claude-code-config/skills/workflow-apex/steps/step-07-tests.md +250 -0
  227. package/src/config/claude-code-config/skills/workflow-apex/steps/step-08-run-tests.md +308 -0
  228. package/src/config/claude-code-config/skills/workflow-apex/steps/step-09-finish.md +193 -0
  229. package/src/config/claude-code-config/skills/workflow-apex/templates/00-context.md +53 -0
  230. package/src/config/claude-code-config/skills/workflow-apex/templates/01-analyze.md +10 -0
  231. package/src/config/claude-code-config/skills/workflow-apex/templates/02-plan.md +10 -0
  232. package/src/config/claude-code-config/skills/workflow-apex/templates/03-execute.md +10 -0
  233. package/src/config/claude-code-config/skills/workflow-apex/templates/04-validate.md +10 -0
  234. package/src/config/claude-code-config/skills/workflow-apex/templates/05-examine.md +10 -0
  235. package/src/config/claude-code-config/skills/workflow-apex/templates/06-resolve.md +10 -0
  236. package/src/config/claude-code-config/skills/workflow-apex/templates/07-tests.md +10 -0
  237. package/src/config/claude-code-config/skills/workflow-apex/templates/08-run-tests.md +10 -0
  238. package/src/config/claude-code-config/skills/workflow-apex/templates/09-finish.md +10 -0
  239. package/src/config/claude-code-config/skills/workflow-apex/templates/README.md +195 -0
  240. package/src/config/claude-code-config/skills/workflow-apex/templates/step-complete.md +7 -0
  241. package/src/config/claude-code-config/skills/workflow-brainstorm/SKILL.md +127 -0
  242. package/src/config/claude-code-config/skills/workflow-brainstorm/steps/step-01-explore.md +230 -0
  243. package/src/config/claude-code-config/skills/workflow-brainstorm/steps/step-02-challenge.md +238 -0
  244. package/src/config/claude-code-config/skills/workflow-brainstorm/steps/step-03-synthesize.md +337 -0
  245. package/src/config/claude-code-config/skills/workflow-brainstorm/steps/step-04-action.md +285 -0
  246. package/src/config/claude-code-config/skills/workflow-ci-fixer/SKILL.md +150 -0
  247. package/src/config/claude-code-config/skills/workflow-ci-fixer/references/cli-commands.md +122 -0
  248. package/src/config/claude-code-config/skills/workflow-ci-fixer/references/github-cli.md +243 -0
  249. package/src/config/claude-code-config/skills/workflow-ci-fixer/references/troubleshooting.md +362 -0
  250. package/src/config/claude-code-config/skills/workflow-ci-fixer/references/vercel-cli.md +192 -0
  251. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-00-init.md +157 -0
  252. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-01-watch-ci.md +192 -0
  253. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-02-analyze-errors.md +263 -0
  254. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-03-fix-locally.md +312 -0
  255. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-04-commit-push.md +206 -0
  256. package/src/config/claude-code-config/skills/workflow-ci-fixer/steps/step-05-cleanup.md +196 -0
  257. package/src/config/claude-code-config/skills/workflow-clean-code/SKILL.md +129 -0
  258. package/src/config/claude-code-config/skills/workflow-clean-code/references/general-clean-code.md +347 -0
  259. package/src/config/claude-code-config/skills/workflow-clean-code/references/nextjs-clean-code.md +458 -0
  260. package/src/config/claude-code-config/skills/workflow-clean-code/references/react-clean-code.md +406 -0
  261. package/src/config/claude-code-config/skills/workflow-clean-code/references/tanstack-query-best-practices.md +516 -0
  262. package/src/config/claude-code-config/skills/workflow-clean-code/references/zustand-best-practices.md +491 -0
  263. package/src/config/claude-code-config/skills/workflow-clean-code/steps/step-01-scan.md +137 -0
  264. package/src/config/claude-code-config/skills/workflow-clean-code/steps/step-02-apply.md +152 -0
  265. package/src/config/claude-code-config/skills/workflow-clean-code/steps/step-03-verify.md +143 -0
  266. package/src/config/claude-code-config/skills/workflow-debug/SKILL.md +126 -0
  267. package/src/config/claude-code-config/skills/workflow-debug/references/log-technique.md +285 -0
  268. package/src/config/claude-code-config/skills/workflow-debug/steps/step-00-init.md +94 -0
  269. package/src/config/claude-code-config/skills/workflow-debug/steps/step-01-analyze.md +180 -0
  270. package/src/config/claude-code-config/skills/workflow-debug/steps/step-01b-log-instrumentation.md +271 -0
  271. package/src/config/claude-code-config/skills/workflow-debug/steps/step-02-find-solutions.md +141 -0
  272. package/src/config/claude-code-config/skills/workflow-debug/steps/step-03-propose.md +142 -0
  273. package/src/config/claude-code-config/skills/workflow-debug/steps/step-04-fix.md +176 -0
  274. package/src/config/claude-code-config/skills/workflow-debug/steps/step-05-verify.md +279 -0
  275. package/src/config/claude-code-config/skills/workflow-review-code/SKILL.md +219 -0
  276. package/src/config/claude-code-config/skills/workflow-review-code/references/clean-code-principles.md +140 -0
  277. package/src/config/claude-code-config/skills/workflow-review-code/references/code-quality-metrics.md +174 -0
  278. package/src/config/claude-code-config/skills/workflow-review-code/references/feedback-patterns.md +149 -0
  279. package/src/config/claude-code-config/skills/workflow-review-code/references/security-checklist.md +127 -0
  280. package/src/config/claude-code-config/song/finish.mp3 +0 -0
  281. package/src/config/claude-code-config/song/need-human.mp3 +0 -0
@@ -0,0 +1,513 @@
1
+ <key_insight>
2
+ Subagent prompts should be task-specific, not generic. They define a specialized role with clear focus areas, workflows, and constraints.
3
+
4
+ **Critical**: Subagent.md files use pure XML structure (no markdown headings). Like skills and slash commands, this improves parsing and token efficiency.
5
+ </key_insight>
6
+
7
+ <xml_structure_rule>
8
+ **Remove ALL markdown headings (##, ###) from subagent body.** Use semantic XML tags instead.
9
+
10
+ Keep markdown formatting WITHIN content (bold, italic, lists, code blocks, links).
11
+
12
+ See @skills/create-agent-skills/references/use-xml-tags.md for XML structure principles - they apply to subagents too.
13
+ </xml_structure_rule>
14
+
15
+ <core_principles>
16
+ <principle name="specificity">
17
+ Define exactly what the subagent does and how it approaches tasks.
18
+
19
+ ❌ Bad: "You are a helpful coding assistant"
20
+ ✅ Good: "You are a React performance optimizer. Analyze components for hooks best practices, unnecessary re-renders, and memoization opportunities."
21
+ </principle>
22
+
23
+ <principle name="clarity">
24
+ State the role, focus areas, and approach explicitly.
25
+
26
+ ❌ Bad: "Help with tests"
27
+ ✅ Good: "You are a test automation specialist. Write comprehensive test suites using the project's testing framework. Focus on edge cases and error conditions."
28
+ </principle>
29
+
30
+ <principle name="constraints">
31
+ Include what the subagent should NOT do. Use strong modal verbs (MUST, SHOULD, NEVER, ALWAYS) to reinforce behavioral guidelines.
32
+
33
+ Example:
34
+ ```markdown
35
+ <constraints>
36
+ - NEVER modify production code, ONLY test files
37
+ - MUST verify tests pass before completing
38
+ - ALWAYS include edge case coverage
39
+ - DO NOT run tests without explicit user request
40
+ </constraints>
41
+ ```
42
+
43
+ **Why strong modals matter**: Reinforces critical boundaries, reduces ambiguity, improves constraint adherence.
44
+ </principle>
45
+ </core_principles>
46
+
47
+ <structure_with_xml>
48
+ Use XML tags to structure subagent prompts for clarity:
49
+
50
+ <example type="security_reviewer">
51
+ ```markdown
52
+ ---
53
+ name: security-reviewer
54
+ description: Reviews code for security vulnerabilities. Use proactively after any code changes involving authentication, data access, or user input.
55
+ tools: Read, Grep, Glob, Bash
56
+ model: sonnet
57
+ ---
58
+
59
+ <role>
60
+ You are a senior security engineer specializing in web application security.
61
+ </role>
62
+
63
+ <focus_areas>
64
+ - SQL injection vulnerabilities
65
+ - XSS (Cross-Site Scripting) attack vectors
66
+ - Authentication and authorization flaws
67
+ - Sensitive data exposure
68
+ - CSRF (Cross-Site Request Forgery)
69
+ - Insecure deserialization
70
+ </focus_areas>
71
+
72
+ <workflow>
73
+ 1. Run git diff to identify recent changes
74
+ 2. Read modified files focusing on data flow
75
+ 3. Identify security risks with severity ratings
76
+ 4. Provide specific remediation steps
77
+ </workflow>
78
+
79
+ <severity_ratings>
80
+ - **Critical**: Immediate exploitation possible, high impact
81
+ - **High**: Exploitation likely, significant impact
82
+ - **Medium**: Exploitation requires conditions, moderate impact
83
+ - **Low**: Limited exploitability or impact
84
+ </severity_ratings>
85
+
86
+ <output_format>
87
+ For each issue found:
88
+ 1. **Severity**: [Critical/High/Medium/Low]
89
+ 2. **Location**: [File:LineNumber]
90
+ 3. **Vulnerability**: [Type and description]
91
+ 4. **Risk**: [What could happen]
92
+ 5. **Fix**: [Specific code changes needed]
93
+ </output_format>
94
+
95
+ <constraints>
96
+ - Focus only on security issues, not code style
97
+ - Provide actionable fixes, not vague warnings
98
+ - If no issues found, confirm the review was completed
99
+ </constraints>
100
+ ```
101
+ </example>
102
+
103
+ <example type="test_writer">
104
+ ```markdown
105
+ ---
106
+ name: test-writer
107
+ description: Creates comprehensive test suites. Use when new code needs tests or test coverage is insufficient.
108
+ tools: Read, Write, Grep, Glob, Bash
109
+ model: sonnet
110
+ ---
111
+
112
+ <role>
113
+ You are a test automation specialist creating thorough, maintainable test suites.
114
+ </role>
115
+
116
+ <testing_philosophy>
117
+ - Test behavior, not implementation
118
+ - One assertion per test when possible
119
+ - Tests should be readable documentation
120
+ - Cover happy path, edge cases, and error conditions
121
+ </testing_philosophy>
122
+
123
+ <workflow>
124
+ 1. Analyze the code to understand functionality
125
+ 2. Identify test cases:
126
+ - Happy path (expected usage)
127
+ - Edge cases (boundary conditions)
128
+ - Error conditions (invalid inputs, failures)
129
+ 3. Write tests using the project's testing framework
130
+ 4. Run tests to verify they pass
131
+ 5. Ensure tests are independent (no shared state)
132
+ </workflow>
133
+
134
+ <test_structure>
135
+ Follow AAA pattern:
136
+ - **Arrange**: Set up test data and conditions
137
+ - **Act**: Execute the functionality being tested
138
+ - **Assert**: Verify the expected outcome
139
+ </test_structure>
140
+
141
+ <quality_criteria>
142
+ - Descriptive test names that explain what's being tested
143
+ - Clear failure messages
144
+ - No test interdependencies
145
+ - Fast execution (mock external dependencies)
146
+ - Clean up after tests (no side effects)
147
+ </quality_criteria>
148
+
149
+ <constraints>
150
+ - Do not modify production code
151
+ - Do not run tests without confirming setup is complete
152
+ - Do not create tests that depend on external services without mocking
153
+ </constraints>
154
+ ```
155
+ </example>
156
+
157
+ <example type="debugger">
158
+ ```markdown
159
+ ---
160
+ name: debugger
161
+ description: Investigates and fixes bugs. Use when errors occur or behavior is unexpected.
162
+ tools: Read, Edit, Bash, Grep, Glob
163
+ model: sonnet
164
+ ---
165
+
166
+ <role>
167
+ You are a debugging specialist skilled at root cause analysis and systematic problem-solving.
168
+ </role>
169
+
170
+ <debugging_methodology>
171
+ 1. **Reproduce**: Understand and reproduce the issue
172
+ 2. **Isolate**: Identify the failing component or function
173
+ 3. **Analyze**: Examine code, logs, error messages, and stack traces
174
+ 4. **Hypothesize**: Form theories about the root cause
175
+ 5. **Test**: Verify hypotheses systematically
176
+ 6. **Fix**: Implement the solution
177
+ 7. **Verify**: Confirm the fix resolves the issue without side effects
178
+ </debugging_methodology>
179
+
180
+ <debugging_techniques>
181
+ - Add logging to trace execution flow
182
+ - Use binary search to isolate the problem (comment out code sections)
183
+ - Check assumptions about inputs, state, and environment
184
+ - Review recent changes that might have introduced the bug
185
+ - Look for similar patterns in the codebase that work correctly
186
+ - Test edge cases and boundary conditions
187
+ </debugging_techniques>
188
+
189
+ <common_bug_patterns>
190
+ - Off-by-one errors in loops
191
+ - Null/undefined reference errors
192
+ - Race conditions in async code
193
+ - Incorrect variable scope
194
+ - Type coercion issues
195
+ - Missing error handling
196
+ </common_bug_patterns>
197
+
198
+ <output_format>
199
+ 1. **Root cause**: Clear explanation of what's wrong
200
+ 2. **Why it happens**: The underlying reason
201
+ 3. **Fix**: Specific code changes
202
+ 4. **Verification**: How to confirm it's fixed
203
+ 5. **Prevention**: How to avoid similar bugs
204
+ </output_format>
205
+
206
+ <constraints>
207
+ - Make minimal changes to fix the issue
208
+ - Preserve existing functionality
209
+ - Add tests to prevent regression
210
+ - Document non-obvious fixes
211
+ </constraints>
212
+ ```
213
+ </example>
214
+ </structure_with_xml>
215
+
216
+ <anti_patterns>
217
+ <anti_pattern name="too_generic">
218
+ ❌ Bad:
219
+ ```markdown
220
+ You are a helpful assistant that helps with code.
221
+ ```
222
+
223
+ This provides no specialization. The subagent won't know what to focus on or how to approach tasks.
224
+ </anti_pattern>
225
+
226
+ <anti_pattern name="no_workflow">
227
+ ❌ Bad:
228
+ ```markdown
229
+ You are a code reviewer. Review code for issues.
230
+ ```
231
+
232
+ Without a workflow, the subagent may skip important steps or review inconsistently.
233
+
234
+ ✅ Good:
235
+ ```markdown
236
+ <workflow>
237
+ 1. Run git diff to see changes
238
+ 2. Read modified files
239
+ 3. Check for: security issues, performance problems, code quality
240
+ 4. Provide specific feedback with examples
241
+ </workflow>
242
+ ```
243
+ </anti_pattern>
244
+
245
+ <anti_pattern name="unclear_trigger">
246
+ The `description` field is critical for automatic invocation. LLM agents use descriptions to make routing decisions.
247
+
248
+ **Description must be specific enough to differentiate from peer agents.**
249
+
250
+ ❌ Bad (too vague):
251
+ ```yaml
252
+ description: Helps with testing
253
+ ```
254
+
255
+ ❌ Bad (not differentiated):
256
+ ```yaml
257
+ description: Billing agent
258
+ ```
259
+
260
+ ✅ Good (specific triggers + differentiation):
261
+ ```yaml
262
+ description: Creates comprehensive test suites. Use when new code needs tests or test coverage is insufficient. Proactively use after implementing new features.
263
+ ```
264
+
265
+ ✅ Good (clear scope):
266
+ ```yaml
267
+ description: Handles current billing statements and payment processing. Use when user asks about invoices, payments, or billing history (not for subscription changes).
268
+ ```
269
+
270
+ **Optimization tips**:
271
+ - Include **trigger keywords** that match common user requests
272
+ - Specify **when to use** (not just what it does)
273
+ - **Differentiate** from similar agents (what this one does vs others)
274
+ - Include **proactive triggers** if agent should be invoked automatically
275
+ </anti_pattern>
276
+
277
+ <anti_pattern name="missing_constraints">
278
+ ❌ Bad: No constraints specified
279
+
280
+ Without constraints, subagents might:
281
+ - Modify code they shouldn't touch
282
+ - Run dangerous commands
283
+ - Skip important steps
284
+
285
+ ✅ Good:
286
+ ```markdown
287
+ <constraints>
288
+ - Only modify test files, never production code
289
+ - Always run tests after writing them
290
+ - Do not commit changes automatically
291
+ </constraints>
292
+ ```
293
+ </anti_pattern>
294
+
295
+ <anti_pattern name="requires_user_interaction">
296
+ ❌ **Critical**: Subagents cannot interact with users.
297
+
298
+ **Bad example:**
299
+ ```markdown
300
+ ---
301
+ name: intake-agent
302
+ description: Gathers requirements from user
303
+ tools: AskUserQuestion
304
+ ---
305
+
306
+ <workflow>
307
+ 1. Ask user about their requirements using AskUserQuestion
308
+ 2. Follow up with clarifying questions
309
+ 3. Return finalized requirements
310
+ </workflow>
311
+ ```
312
+
313
+ **Why this fails:**
314
+ Subagents execute in isolated contexts ("black boxes"). They cannot use AskUserQuestion or any tool requiring user interaction. The user never sees intermediate steps.
315
+
316
+ **Correct approach:**
317
+ ```markdown
318
+ # Main chat handles user interaction
319
+ 1. Main chat: Use AskUserQuestion to gather requirements
320
+ 2. Launch subagent: Research based on requirements (no user interaction)
321
+ 3. Main chat: Present research to user, get confirmation
322
+ 4. Launch subagent: Generate code based on confirmed plan
323
+ 5. Main chat: Present results to user
324
+ ```
325
+
326
+ **Tools that require user interaction (cannot use in subagents):**
327
+ - AskUserQuestion
328
+ - Any workflow expecting user to respond mid-execution
329
+ - Presenting options and waiting for selection
330
+
331
+ **Design principle:**
332
+ If your subagent prompt includes "ask user", "present options", or "wait for confirmation", it's designed incorrectly. Move user interaction to main chat.
333
+ </anti_pattern>
334
+ </anti_patterns>
335
+
336
+ <best_practices>
337
+ <practice name="start_with_role">
338
+ Begin with a clear role statement:
339
+
340
+ ```markdown
341
+ <role>
342
+ You are a [specific expertise] specializing in [specific domain].
343
+ </role>
344
+ ```
345
+ </practice>
346
+
347
+ <practice name="define_focus">
348
+ List specific focus areas to guide attention:
349
+
350
+ ```markdown
351
+ <focus_areas>
352
+ - Specific concern 1
353
+ - Specific concern 2
354
+ - Specific concern 3
355
+ </focus_areas>
356
+ ```
357
+ </practice>
358
+
359
+ <practice name="provide_workflow">
360
+ Give step-by-step workflow for consistency:
361
+
362
+ ```markdown
363
+ <workflow>
364
+ 1. First step
365
+ 2. Second step
366
+ 3. Third step
367
+ </workflow>
368
+ ```
369
+ </practice>
370
+
371
+ <practice name="specify_output">
372
+ Define expected output format:
373
+
374
+ ```markdown
375
+ <output_format>
376
+ Structure:
377
+ 1. Component 1
378
+ 2. Component 2
379
+ 3. Component 3
380
+ </output_format>
381
+ ```
382
+ </practice>
383
+
384
+ <practice name="set_boundaries">
385
+ Clearly state constraints with strong modal verbs:
386
+
387
+ ```markdown
388
+ <constraints>
389
+ - NEVER modify X
390
+ - ALWAYS verify Y before Z
391
+ - MUST include edge case testing
392
+ - DO NOT proceed without validation
393
+ </constraints>
394
+ ```
395
+
396
+ **Security constraints** (when relevant):
397
+ - Environment awareness (production vs development)
398
+ - Safe operation boundaries (what commands are allowed)
399
+ - Data handling rules (sensitive information)
400
+ </practice>
401
+
402
+ <practice name="use_examples">
403
+ Include examples for complex behaviors:
404
+
405
+ ```markdown
406
+ <example>
407
+ Input: [scenario]
408
+ Expected action: [what the subagent should do]
409
+ Output: [what the subagent should produce]
410
+ </example>
411
+ ```
412
+ </practice>
413
+
414
+ <practice name="extended_thinking">
415
+ For complex reasoning tasks, leverage extended thinking:
416
+
417
+ ```markdown
418
+ <thinking_approach>
419
+ Use extended thinking for:
420
+ - Root cause analysis of complex bugs
421
+ - Security vulnerability assessment
422
+ - Architectural design decisions
423
+ - Multi-step logical reasoning
424
+
425
+ Provide high-level guidance rather than prescriptive steps:
426
+ "Analyze the authentication flow for security vulnerabilities, considering common attack vectors and edge cases."
427
+
428
+ Rather than:
429
+ "Step 1: Check for SQL injection. Step 2: Check for XSS. Step 3: ..."
430
+ </thinking_approach>
431
+ ```
432
+
433
+ **When to use extended thinking**:
434
+ - Debugging complex issues
435
+ - Security analysis
436
+ - Code architecture review
437
+ - Performance optimization requiring deep analysis
438
+
439
+ **Minimum thinking budget**: 1024 tokens (increase for more complex tasks)
440
+ </practice>
441
+
442
+ <practice name="success_criteria">
443
+ Define what successful completion looks like:
444
+
445
+ ```markdown
446
+ <success_criteria>
447
+ Task is complete when:
448
+ - All modified files have been reviewed
449
+ - Each issue has severity rating and specific fix
450
+ - Output format is valid JSON
451
+ - No vulnerabilities were missed (cross-check against OWASP Top 10)
452
+ </success_criteria>
453
+ ```
454
+
455
+ **Benefit**: Clear completion criteria reduce ambiguity and partial outputs.
456
+ </practice>
457
+ </best_practices>
458
+
459
+ <testing_subagents>
460
+ <test_checklist>
461
+ 1. **Invoke the subagent** with a representative task
462
+ 2. **Check if it follows the workflow** specified in the prompt
463
+ 3. **Verify output format** matches what you defined
464
+ 4. **Test edge cases** - does it handle unusual inputs well?
465
+ 5. **Check constraints** - does it respect boundaries?
466
+ 6. **Iterate** - refine the prompt based on observed behavior
467
+ </test_checklist>
468
+
469
+ <common_issues>
470
+ - **Subagent too broad**: Narrow the focus areas
471
+ - **Skipping steps**: Make workflow more explicit
472
+ - **Inconsistent output**: Define output format more clearly
473
+ - **Overstepping bounds**: Add or clarify constraints
474
+ - **Not automatically invoked**: Improve description field with trigger keywords
475
+ </common_issues>
476
+ </testing_subagents>
477
+
478
+ <quick_reference>
479
+ ```markdown
480
+ ---
481
+ name: subagent-name
482
+ description: What it does and when to use it. Include trigger keywords.
483
+ tools: Tool1, Tool2, Tool3
484
+ model: sonnet
485
+ ---
486
+
487
+ <role>
488
+ You are a [specific role] specializing in [domain].
489
+ </role>
490
+
491
+ <focus_areas>
492
+ - Focus 1
493
+ - Focus 2
494
+ - Focus 3
495
+ </focus_areas>
496
+
497
+ <workflow>
498
+ 1. Step 1
499
+ 2. Step 2
500
+ 3. Step 3
501
+ </workflow>
502
+
503
+ <output_format>
504
+ Expected output structure
505
+ </output_format>
506
+
507
+ <constraints>
508
+ - Do not X
509
+ - Always Y
510
+ - Never Z
511
+ </constraints>
512
+ ```
513
+ </quick_reference>
@@ -0,0 +1,117 @@
1
+ ---
2
+ name: ralph-loop
3
+ description: Setup the Ralph autonomous AI coding loop - ships features while you sleep
4
+ argument-hint: "<project-path> [-i/--interactive] [-f/--feature <name>]"
5
+ ---
6
+
7
+ <objective>
8
+ Set up the Ralph autonomous coding loop in any project. Ralph runs AI agents in a loop, picking tasks from a PRD, implementing one at a time, committing after each, and accumulating learnings until all tasks are complete.
9
+
10
+ **This skill ONLY sets up Ralph - you run the commands yourself.**
11
+ </objective>
12
+
13
+ <quick_start>
14
+ **Setup Ralph interactively (recommended):**
15
+ ```bash
16
+ /setup-ralph -i
17
+ ```
18
+
19
+ **Setup for specific feature:**
20
+ ```bash
21
+ /setup-ralph -f 01-add-authentication
22
+ ```
23
+
24
+ **What this does:**
25
+ 1. Creates `.claude/ralph/` structure in your project
26
+ 2. Runs setup script to create all Ralph files
27
+ 3. (If -i): Brainstorms PRD with you interactively
28
+ 4. Transforms PRD into user stories (prd.json)
29
+ 5. Shows you the command to run Ralph (you run it yourself)
30
+
31
+ **After setup, you run:**
32
+ ```bash
33
+ bun run .claude/ralph/ralph.sh -f <feature-name>
34
+ ```
35
+ </quick_start>
36
+
37
+ <critical_rule>
38
+ 🛑 NEVER run ralph.sh or any execution commands automatically
39
+ 🛑 NEVER execute the loop - only set up files and show instructions
40
+ ✅ ALWAYS let the user copy and run commands themselves
41
+ ✅ ALWAYS end by showing the exact command to run
42
+ </critical_rule>
43
+
44
+ <when_to_use>
45
+ **Use this skill when:**
46
+ - Starting a new feature that can be broken into small stories
47
+ - Setting up Ralph in a new project
48
+ - Creating a new feature PRD interactively
49
+
50
+ **Don't use for:**
51
+ - Simple single-file changes
52
+ - Exploratory work without clear requirements
53
+ - Major refactors without acceptance criteria
54
+ </when_to_use>
55
+
56
+ <parameters>
57
+ | Flag | Description |
58
+ |------|-------------|
59
+ | `<project-path>` | Path to the project (defaults to current directory) |
60
+ | `-i, --interactive` | Interactive mode: brainstorm PRD with AI assistance |
61
+ | `-f, --feature <name>` | Feature folder name (e.g., `01-add-auth`) |
62
+
63
+ **Examples:**
64
+ ```bash
65
+ /setup-ralph /path/to/project -i # Interactive PRD creation
66
+ /setup-ralph . -f 01-add-auth # Setup for specific feature
67
+ /setup-ralph -i -f 02-user-dashboard # Interactive with specific name
68
+ ```
69
+ </parameters>
70
+
71
+ <state_variables>
72
+ | Variable | Type | Description |
73
+ |----------|------|-------------|
74
+ | `{project_path}` | string | Absolute path to target project |
75
+ | `{ralph_dir}` | string | Path to .claude/ralph in project |
76
+ | `{feature_name}` | string | Feature folder name (e.g., `01-add-auth`) |
77
+ | `{feature_dir}` | string | Path to task folder |
78
+ | `{interactive_mode}` | boolean | Whether to brainstorm PRD interactively |
79
+ | `{prd_content}` | string | PRD markdown content |
80
+ | `{user_stories}` | array | User stories extracted from PRD |
81
+ | `{branch_name}` | string | Git branch for the feature |
82
+ </state_variables>
83
+
84
+ <entry_point>
85
+ Load `steps/step-00-init.md`
86
+ </entry_point>
87
+
88
+ <step_files>
89
+ | Step | File | Purpose |
90
+ |------|------|---------|
91
+ | 00 | `step-00-init.md` | Parse flags, run setup script, create structure |
92
+ | 01 | `step-01-interactive-prd.md` | Interactive PRD brainstorming and creation |
93
+ | 02 | `step-02-create-stories.md` | Transform PRD into user stories (prd.json) |
94
+ | 03 | `step-03-finish.md` | Show run command (user runs it themselves) |
95
+ </step_files>
96
+
97
+ <scripts>
98
+ | Script | Purpose |
99
+ |--------|---------|
100
+ | `scripts/setup.sh` | Creates all Ralph files in the project |
101
+ </scripts>
102
+
103
+ <execution_rules>
104
+ 1. **Progressive Loading**: Load one step at a time
105
+ 2. **Script Execution**: Use scripts/setup.sh to create files atomically
106
+ 3. **Interactive Mode**: If -i flag, run brainstorming conversation
107
+ 4. **State Persistence**: Track progress in feature_dir/progress.txt
108
+ 5. **Resume Support**: Detect existing PRD.md and resume from there
109
+ 6. **NEVER RUN RALPH**: Only setup and show commands - user runs them
110
+ </execution_rules>
111
+
112
+ <success_criteria>
113
+ ✅ Ralph structure created at {project_path}/.claude/ralph
114
+ ✅ Feature folder created with PRD.md, prd.json, progress.txt
115
+ ✅ User stories properly formatted in prd.json
116
+ ✅ Clear run command provided to user (they run it themselves)
117
+ </success_criteria>