@heyai-rules/pilo-masterkit 1.2.2

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 (305) hide show
  1. package/.agent/agents/PILO_MASTER.md +77 -0
  2. package/.agent/agents/architect.md +211 -0
  3. package/.agent/agents/backend-specialist.md +263 -0
  4. package/.agent/agents/build-error-resolver.md +114 -0
  5. package/.agent/agents/chief-of-staff.md +151 -0
  6. package/.agent/agents/code-archaeologist.md +106 -0
  7. package/.agent/agents/code-reviewer.md +237 -0
  8. package/.agent/agents/cpp-build-resolver.md +90 -0
  9. package/.agent/agents/cpp-reviewer.md +72 -0
  10. package/.agent/agents/database-architect.md +226 -0
  11. package/.agent/agents/database-reviewer.md +91 -0
  12. package/.agent/agents/debugger.md +225 -0
  13. package/.agent/agents/devops-engineer.md +242 -0
  14. package/.agent/agents/doc-updater.md +107 -0
  15. package/.agent/agents/docs-lookup.md +68 -0
  16. package/.agent/agents/documentation-writer.md +104 -0
  17. package/.agent/agents/e2e-runner.md +107 -0
  18. package/.agent/agents/explorer-agent.md +73 -0
  19. package/.agent/agents/flutter-reviewer.md +243 -0
  20. package/.agent/agents/frontend-specialist.md +593 -0
  21. package/.agent/agents/game-developer.md +162 -0
  22. package/.agent/agents/go-build-resolver.md +94 -0
  23. package/.agent/agents/go-reviewer.md +76 -0
  24. package/.agent/agents/harness-optimizer.md +35 -0
  25. package/.agent/agents/java-build-resolver.md +153 -0
  26. package/.agent/agents/java-reviewer.md +92 -0
  27. package/.agent/agents/kotlin-build-resolver.md +118 -0
  28. package/.agent/agents/kotlin-reviewer.md +159 -0
  29. package/.agent/agents/loop-operator.md +36 -0
  30. package/.agent/agents/mobile-developer.md +377 -0
  31. package/.agent/agents/orchestrator.md +416 -0
  32. package/.agent/agents/penetration-tester.md +188 -0
  33. package/.agent/agents/performance-optimizer.md +187 -0
  34. package/.agent/agents/planner.md +212 -0
  35. package/.agent/agents/product-manager.md +112 -0
  36. package/.agent/agents/product-owner.md +95 -0
  37. package/.agent/agents/project-planner.md +406 -0
  38. package/.agent/agents/python-reviewer.md +98 -0
  39. package/.agent/agents/pytorch-build-resolver.md +120 -0
  40. package/.agent/agents/qa-automation-engineer.md +103 -0
  41. package/.agent/agents/refactor-cleaner.md +85 -0
  42. package/.agent/agents/rust-build-resolver.md +148 -0
  43. package/.agent/agents/rust-reviewer.md +94 -0
  44. package/.agent/agents/security-auditor.md +170 -0
  45. package/.agent/agents/security-reviewer.md +108 -0
  46. package/.agent/agents/seo-specialist.md +111 -0
  47. package/.agent/agents/tdd-guide.md +91 -0
  48. package/.agent/agents/test-engineer.md +158 -0
  49. package/.agent/agents/typescript-reviewer.md +112 -0
  50. package/.agent/rules/ARCHITECTURAL_BLUEPRINTS.md +62 -0
  51. package/.agent/rules/CODE_CRAFTSMANSHIP.md +69 -0
  52. package/.agent/rules/CORE_RULES.md +72 -0
  53. package/.agent/rules/PROJECT_MAP.md +58 -0
  54. package/.agent/rules/QUALITY_ASSURANCE.md +54 -0
  55. package/.agent/rules/SECURITY_ARMOR.md +44 -0
  56. package/.agent/rules/VERSION_ORCHESTRATION.md +64 -0
  57. package/.agent/rules/WORKFLOW_ORCHESTRATION.md +55 -0
  58. package/.agent/scripts/auto_preview.py +148 -0
  59. package/.agent/scripts/checklist.py +217 -0
  60. package/.agent/scripts/session_manager.py +120 -0
  61. package/.agent/scripts/verify_all.py +327 -0
  62. package/.agent/skills/api-patterns/SKILL.md +81 -0
  63. package/.agent/skills/api-patterns/api-style.md +42 -0
  64. package/.agent/skills/api-patterns/auth.md +24 -0
  65. package/.agent/skills/api-patterns/documentation.md +26 -0
  66. package/.agent/skills/api-patterns/graphql.md +41 -0
  67. package/.agent/skills/api-patterns/rate-limiting.md +31 -0
  68. package/.agent/skills/api-patterns/response.md +37 -0
  69. package/.agent/skills/api-patterns/rest.md +40 -0
  70. package/.agent/skills/api-patterns/scripts/api_validator.py +211 -0
  71. package/.agent/skills/api-patterns/security-testing.md +122 -0
  72. package/.agent/skills/api-patterns/trpc.md +41 -0
  73. package/.agent/skills/api-patterns/versioning.md +22 -0
  74. package/.agent/skills/app-builder/SKILL.md +75 -0
  75. package/.agent/skills/app-builder/agent-coordination.md +71 -0
  76. package/.agent/skills/app-builder/feature-building.md +53 -0
  77. package/.agent/skills/app-builder/project-detection.md +34 -0
  78. package/.agent/skills/app-builder/scaffolding.md +118 -0
  79. package/.agent/skills/app-builder/tech-stack.md +41 -0
  80. package/.agent/skills/app-builder/templates/SKILL.md +39 -0
  81. package/.agent/skills/app-builder/templates/astro-static/TEMPLATE.md +76 -0
  82. package/.agent/skills/app-builder/templates/chrome-extension/TEMPLATE.md +92 -0
  83. package/.agent/skills/app-builder/templates/cli-tool/TEMPLATE.md +88 -0
  84. package/.agent/skills/app-builder/templates/electron-desktop/TEMPLATE.md +88 -0
  85. package/.agent/skills/app-builder/templates/express-api/TEMPLATE.md +83 -0
  86. package/.agent/skills/app-builder/templates/flutter-app/TEMPLATE.md +90 -0
  87. package/.agent/skills/app-builder/templates/monorepo-turborepo/TEMPLATE.md +90 -0
  88. package/.agent/skills/app-builder/templates/nextjs-fullstack/TEMPLATE.md +122 -0
  89. package/.agent/skills/app-builder/templates/nextjs-saas/TEMPLATE.md +122 -0
  90. package/.agent/skills/app-builder/templates/nextjs-static/TEMPLATE.md +169 -0
  91. package/.agent/skills/app-builder/templates/nuxt-app/TEMPLATE.md +134 -0
  92. package/.agent/skills/app-builder/templates/python-fastapi/TEMPLATE.md +83 -0
  93. package/.agent/skills/app-builder/templates/react-native-app/TEMPLATE.md +119 -0
  94. package/.agent/skills/architecture/SKILL.md +55 -0
  95. package/.agent/skills/architecture/context-discovery.md +43 -0
  96. package/.agent/skills/architecture/examples.md +94 -0
  97. package/.agent/skills/architecture/pattern-selection.md +68 -0
  98. package/.agent/skills/architecture/patterns-reference.md +50 -0
  99. package/.agent/skills/architecture/trade-off-analysis.md +77 -0
  100. package/.agent/skills/bash-linux/SKILL.md +199 -0
  101. package/.agent/skills/behavioral-modes/SKILL.md +242 -0
  102. package/.agent/skills/brainstorming/SKILL.md +163 -0
  103. package/.agent/skills/brainstorming/dynamic-questioning.md +350 -0
  104. package/.agent/skills/clean-code/SKILL.md +201 -0
  105. package/.agent/skills/code-review-checklist/SKILL.md +109 -0
  106. package/.agent/skills/database-design/SKILL.md +52 -0
  107. package/.agent/skills/database-design/database-selection.md +43 -0
  108. package/.agent/skills/database-design/indexing.md +39 -0
  109. package/.agent/skills/database-design/migrations.md +48 -0
  110. package/.agent/skills/database-design/optimization.md +36 -0
  111. package/.agent/skills/database-design/orm-selection.md +30 -0
  112. package/.agent/skills/database-design/schema-design.md +56 -0
  113. package/.agent/skills/database-design/scripts/schema_validator.py +172 -0
  114. package/.agent/skills/deployment-procedures/SKILL.md +241 -0
  115. package/.agent/skills/doc.md +177 -0
  116. package/.agent/skills/documentation-templates/SKILL.md +194 -0
  117. package/.agent/skills/frontend-design/SKILL.md +452 -0
  118. package/.agent/skills/frontend-design/animation-guide.md +331 -0
  119. package/.agent/skills/frontend-design/color-system.md +311 -0
  120. package/.agent/skills/frontend-design/decision-trees.md +418 -0
  121. package/.agent/skills/frontend-design/motion-graphics.md +306 -0
  122. package/.agent/skills/frontend-design/scripts/accessibility_checker.py +183 -0
  123. package/.agent/skills/frontend-design/scripts/ux_audit.py +722 -0
  124. package/.agent/skills/frontend-design/typography-system.md +345 -0
  125. package/.agent/skills/frontend-design/ux-psychology.md +1116 -0
  126. package/.agent/skills/frontend-design/visual-effects.md +383 -0
  127. package/.agent/skills/game-development/2d-games/SKILL.md +119 -0
  128. package/.agent/skills/game-development/3d-games/SKILL.md +135 -0
  129. package/.agent/skills/game-development/SKILL.md +167 -0
  130. package/.agent/skills/game-development/game-art/SKILL.md +185 -0
  131. package/.agent/skills/game-development/game-audio/SKILL.md +190 -0
  132. package/.agent/skills/game-development/game-design/SKILL.md +129 -0
  133. package/.agent/skills/game-development/mobile-games/SKILL.md +108 -0
  134. package/.agent/skills/game-development/multiplayer/SKILL.md +132 -0
  135. package/.agent/skills/game-development/pc-games/SKILL.md +144 -0
  136. package/.agent/skills/game-development/vr-ar/SKILL.md +123 -0
  137. package/.agent/skills/game-development/web-games/SKILL.md +150 -0
  138. package/.agent/skills/geo-fundamentals/SKILL.md +156 -0
  139. package/.agent/skills/geo-fundamentals/scripts/geo_checker.py +289 -0
  140. package/.agent/skills/i18n-localization/SKILL.md +154 -0
  141. package/.agent/skills/i18n-localization/scripts/i18n_checker.py +241 -0
  142. package/.agent/skills/intelligent-routing/SKILL.md +335 -0
  143. package/.agent/skills/lint-and-validate/SKILL.md +45 -0
  144. package/.agent/skills/lint-and-validate/scripts/lint_runner.py +184 -0
  145. package/.agent/skills/lint-and-validate/scripts/type_coverage.py +173 -0
  146. package/.agent/skills/mcp-builder/SKILL.md +176 -0
  147. package/.agent/skills/mobile-design/SKILL.md +394 -0
  148. package/.agent/skills/mobile-design/decision-trees.md +516 -0
  149. package/.agent/skills/mobile-design/mobile-backend.md +491 -0
  150. package/.agent/skills/mobile-design/mobile-color-system.md +420 -0
  151. package/.agent/skills/mobile-design/mobile-debugging.md +122 -0
  152. package/.agent/skills/mobile-design/mobile-design-thinking.md +357 -0
  153. package/.agent/skills/mobile-design/mobile-navigation.md +458 -0
  154. package/.agent/skills/mobile-design/mobile-performance.md +767 -0
  155. package/.agent/skills/mobile-design/mobile-testing.md +356 -0
  156. package/.agent/skills/mobile-design/mobile-typography.md +433 -0
  157. package/.agent/skills/mobile-design/platform-android.md +666 -0
  158. package/.agent/skills/mobile-design/platform-ios.md +561 -0
  159. package/.agent/skills/mobile-design/scripts/mobile_audit.py +670 -0
  160. package/.agent/skills/mobile-design/touch-psychology.md +537 -0
  161. package/.agent/skills/nextjs-react-expert/1-async-eliminating-waterfalls.md +351 -0
  162. package/.agent/skills/nextjs-react-expert/2-bundle-bundle-size-optimization.md +240 -0
  163. package/.agent/skills/nextjs-react-expert/3-server-server-side-performance.md +490 -0
  164. package/.agent/skills/nextjs-react-expert/4-client-client-side-data-fetching.md +264 -0
  165. package/.agent/skills/nextjs-react-expert/5-rerender-re-render-optimization.md +581 -0
  166. package/.agent/skills/nextjs-react-expert/6-rendering-rendering-performance.md +432 -0
  167. package/.agent/skills/nextjs-react-expert/7-js-javascript-performance.md +684 -0
  168. package/.agent/skills/nextjs-react-expert/8-advanced-advanced-patterns.md +150 -0
  169. package/.agent/skills/nextjs-react-expert/9-cache-components.md +103 -0
  170. package/.agent/skills/nextjs-react-expert/SKILL.md +293 -0
  171. package/.agent/skills/nextjs-react-expert/scripts/convert_rules.py +222 -0
  172. package/.agent/skills/nextjs-react-expert/scripts/react_performance_checker.py +252 -0
  173. package/.agent/skills/nodejs-best-practices/SKILL.md +333 -0
  174. package/.agent/skills/parallel-agents/SKILL.md +175 -0
  175. package/.agent/skills/performance-profiling/SKILL.md +143 -0
  176. package/.agent/skills/performance-profiling/scripts/lighthouse_audit.py +76 -0
  177. package/.agent/skills/plan-writing/SKILL.md +152 -0
  178. package/.agent/skills/powershell-windows/SKILL.md +167 -0
  179. package/.agent/skills/python-patterns/SKILL.md +441 -0
  180. package/.agent/skills/red-team-tactics/SKILL.md +199 -0
  181. package/.agent/skills/rust-pro/SKILL.md +176 -0
  182. package/.agent/skills/seo-fundamentals/SKILL.md +129 -0
  183. package/.agent/skills/seo-fundamentals/scripts/seo_checker.py +219 -0
  184. package/.agent/skills/server-management/SKILL.md +161 -0
  185. package/.agent/skills/systematic-debugging/SKILL.md +109 -0
  186. package/.agent/skills/tailwind-patterns/SKILL.md +269 -0
  187. package/.agent/skills/tdd-workflow/SKILL.md +149 -0
  188. package/.agent/skills/testing-patterns/SKILL.md +178 -0
  189. package/.agent/skills/testing-patterns/scripts/test_runner.py +219 -0
  190. package/.agent/skills/ui-ux-pro-max/SKILL.md +292 -0
  191. package/.agent/skills/ui-ux-pro-max/data/charts.csv +26 -0
  192. package/.agent/skills/ui-ux-pro-max/data/colors.csv +97 -0
  193. package/.agent/skills/ui-ux-pro-max/data/icons.csv +101 -0
  194. package/.agent/skills/ui-ux-pro-max/data/landing.csv +31 -0
  195. package/.agent/skills/ui-ux-pro-max/data/products.csv +97 -0
  196. package/.agent/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
  197. package/.agent/skills/ui-ux-pro-max/data/stacks/astro.csv +54 -0
  198. package/.agent/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
  199. package/.agent/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
  200. package/.agent/skills/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
  201. package/.agent/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
  202. package/.agent/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
  203. package/.agent/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
  204. package/.agent/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
  205. package/.agent/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
  206. package/.agent/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
  207. package/.agent/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
  208. package/.agent/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
  209. package/.agent/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
  210. package/.agent/skills/ui-ux-pro-max/data/styles.csv +68 -0
  211. package/.agent/skills/ui-ux-pro-max/data/typography.csv +58 -0
  212. package/.agent/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
  213. package/.agent/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
  214. package/.agent/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
  215. package/.agent/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-314.pyc +0 -0
  216. package/.agent/skills/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-314.pyc +0 -0
  217. package/.agent/skills/ui-ux-pro-max/scripts/__pycache__/search.cpython-314.pyc +0 -0
  218. package/.agent/skills/ui-ux-pro-max/scripts/core.py +253 -0
  219. package/.agent/skills/ui-ux-pro-max/scripts/design_system.py +1067 -0
  220. package/.agent/skills/ui-ux-pro-max/scripts/search.py +114 -0
  221. package/.agent/skills/vulnerability-scanner/SKILL.md +276 -0
  222. package/.agent/skills/vulnerability-scanner/checklists.md +121 -0
  223. package/.agent/skills/vulnerability-scanner/scripts/security_scan.py +458 -0
  224. package/.agent/skills/web-design-guidelines/SKILL.md +57 -0
  225. package/.agent/skills/webapp-testing/SKILL.md +187 -0
  226. package/.agent/skills/webapp-testing/scripts/playwright_runner.py +173 -0
  227. package/.agent/tasks/lessons.md +40 -0
  228. package/.agent/tasks/todo.md +33 -0
  229. package/.agent/workflows/aside.md +164 -0
  230. package/.agent/workflows/brainstorm.md +113 -0
  231. package/.agent/workflows/build-fix.md +62 -0
  232. package/.agent/workflows/checkpoint.md +74 -0
  233. package/.agent/workflows/claw.md +51 -0
  234. package/.agent/workflows/code-review.md +40 -0
  235. package/.agent/workflows/context-budget.md +29 -0
  236. package/.agent/workflows/cpp-build.md +173 -0
  237. package/.agent/workflows/cpp-review.md +132 -0
  238. package/.agent/workflows/cpp-test.md +251 -0
  239. package/.agent/workflows/create.md +59 -0
  240. package/.agent/workflows/debug.md +103 -0
  241. package/.agent/workflows/deploy.md +176 -0
  242. package/.agent/workflows/devfleet.md +92 -0
  243. package/.agent/workflows/docs.md +31 -0
  244. package/.agent/workflows/e2e.md +365 -0
  245. package/.agent/workflows/enhance.md +63 -0
  246. package/.agent/workflows/eval.md +120 -0
  247. package/.agent/workflows/evolve.md +178 -0
  248. package/.agent/workflows/go-build.md +183 -0
  249. package/.agent/workflows/go-review.md +148 -0
  250. package/.agent/workflows/go-test.md +268 -0
  251. package/.agent/workflows/gradle-build.md +70 -0
  252. package/.agent/workflows/harness-audit.md +71 -0
  253. package/.agent/workflows/init-docs.md +46 -0
  254. package/.agent/workflows/instinct-export.md +66 -0
  255. package/.agent/workflows/instinct-import.md +114 -0
  256. package/.agent/workflows/instinct-status.md +59 -0
  257. package/.agent/workflows/kotlin-build.md +174 -0
  258. package/.agent/workflows/kotlin-review.md +140 -0
  259. package/.agent/workflows/kotlin-test.md +312 -0
  260. package/.agent/workflows/learn-eval.md +116 -0
  261. package/.agent/workflows/learn.md +70 -0
  262. package/.agent/workflows/loop-start.md +32 -0
  263. package/.agent/workflows/loop-status.md +24 -0
  264. package/.agent/workflows/model-route.md +26 -0
  265. package/.agent/workflows/multi-backend.md +158 -0
  266. package/.agent/workflows/multi-execute.md +315 -0
  267. package/.agent/workflows/multi-frontend.md +158 -0
  268. package/.agent/workflows/multi-plan.md +268 -0
  269. package/.agent/workflows/multi-workflow.md +191 -0
  270. package/.agent/workflows/orchestrate.md +231 -0
  271. package/.agent/workflows/plan.md +115 -0
  272. package/.agent/workflows/pm2.md +272 -0
  273. package/.agent/workflows/preview.md +81 -0
  274. package/.agent/workflows/projects.md +39 -0
  275. package/.agent/workflows/promote.md +41 -0
  276. package/.agent/workflows/prompt-optimize.md +38 -0
  277. package/.agent/workflows/prune.md +31 -0
  278. package/.agent/workflows/python-review.md +297 -0
  279. package/.agent/workflows/quality-gate.md +29 -0
  280. package/.agent/workflows/refactor-clean.md +80 -0
  281. package/.agent/workflows/resume-session.md +156 -0
  282. package/.agent/workflows/rules-distill.md +11 -0
  283. package/.agent/workflows/rust-build.md +187 -0
  284. package/.agent/workflows/rust-review.md +142 -0
  285. package/.agent/workflows/rust-test.md +308 -0
  286. package/.agent/workflows/save-session.md +275 -0
  287. package/.agent/workflows/sessions.md +333 -0
  288. package/.agent/workflows/setup-pm.md +80 -0
  289. package/.agent/workflows/skill-create.md +174 -0
  290. package/.agent/workflows/skill-health.md +54 -0
  291. package/.agent/workflows/status.md +86 -0
  292. package/.agent/workflows/tdd.md +328 -0
  293. package/.agent/workflows/test-coverage.md +69 -0
  294. package/.agent/workflows/test.md +144 -0
  295. package/.agent/workflows/ui-ux-pro-max.md +296 -0
  296. package/.agent/workflows/update-codemaps.md +72 -0
  297. package/.agent/workflows/update-docs.md +84 -0
  298. package/.agent/workflows/verify.md +59 -0
  299. package/LICENSE +176 -0
  300. package/README.md +136 -0
  301. package/RELEASE.md +36 -0
  302. package/package.json +79 -0
  303. package/scripts/release-check.js +55 -0
  304. package/src/bin/cli.js +78 -0
  305. package/src/lib/installer.js +140 -0
@@ -0,0 +1,115 @@
1
+ ---
2
+ description: Restate requirements, assess risks, and create step-by-step implementation plan. WAIT for user CONFIRM before touching any code.
3
+ ---
4
+
5
+ # Plan Command
6
+
7
+ This command invokes the **planner** agent to create a comprehensive implementation plan before writing any code.
8
+
9
+ ## What This Command Does
10
+
11
+ 1. **Restate Requirements** - Clarify what needs to be built
12
+ 2. **Identify Risks** - Surface potential issues and blockers
13
+ 3. **Create Step Plan** - Break down implementation into phases
14
+ 4. **Wait for Confirmation** - MUST receive user approval before proceeding
15
+
16
+ ## When to Use
17
+
18
+ Use `/plan` when:
19
+ - Starting a new feature
20
+ - Making significant architectural changes
21
+ - Working on complex refactoring
22
+ - Multiple files/components will be affected
23
+ - Requirements are unclear or ambiguous
24
+
25
+ ## How It Works
26
+
27
+ The planner agent will:
28
+
29
+ 1. **Analyze the request** and restate requirements in clear terms
30
+ 2. **Break down into phases** with specific, actionable steps
31
+ 3. **Identify dependencies** between components
32
+ 4. **Assess risks** and potential blockers
33
+ 5. **Estimate complexity** (High/Medium/Low)
34
+ 6. **Present the plan** and WAIT for your explicit confirmation
35
+
36
+ ## Example Usage
37
+
38
+ ```
39
+ User: /plan I need to add real-time notifications when markets resolve
40
+
41
+ Agent (planner):
42
+ # Implementation Plan: Real-Time Market Resolution Notifications
43
+
44
+ ## Requirements Restatement
45
+ - Send notifications to users when markets they're watching resolve
46
+ - Support multiple notification channels (in-app, email, webhook)
47
+ - Ensure notifications are delivered reliably
48
+ - Include market outcome and user's position result
49
+
50
+ ## Implementation Phases
51
+
52
+ ### Phase 1: Database Schema
53
+ - Add notifications table with columns: id, user_id, market_id, type, status, created_at
54
+ - Add user_notification_preferences table for channel preferences
55
+ - Create indexes on user_id and market_id for performance
56
+
57
+ ### Phase 2: Notification Service
58
+ - Create notification service in lib/notifications.ts
59
+ - Implement notification queue using BullMQ/Redis
60
+ - Add retry logic for failed deliveries
61
+ - Create notification templates
62
+
63
+ ### Phase 3: Integration Points
64
+ - Hook into market resolution logic (when status changes to "resolved")
65
+ - Query all users with positions in market
66
+ - Enqueue notifications for each user
67
+
68
+ ### Phase 4: Frontend Components
69
+ - Create NotificationBell component in header
70
+ - Add NotificationList modal
71
+ - Implement real-time updates via Supabase subscriptions
72
+ - Add notification preferences page
73
+
74
+ ## Dependencies
75
+ - Redis (for queue)
76
+ - Email service (SendGrid/Resend)
77
+ - Supabase real-time subscriptions
78
+
79
+ ## Risks
80
+ - HIGH: Email deliverability (SPF/DKIM required)
81
+ - MEDIUM: Performance with 1000+ users per market
82
+ - MEDIUM: Notification spam if markets resolve frequently
83
+ - LOW: Real-time subscription overhead
84
+
85
+ ## Estimated Complexity: MEDIUM
86
+ - Backend: 4-6 hours
87
+ - Frontend: 3-4 hours
88
+ - Testing: 2-3 hours
89
+ - Total: 9-13 hours
90
+
91
+ **WAITING FOR CONFIRMATION**: Proceed with this plan? (yes/no/modify)
92
+ ```
93
+
94
+ ## Important Notes
95
+
96
+ **CRITICAL**: The planner agent will **NOT** write any code until you explicitly confirm the plan with "yes" or "proceed" or similar affirmative response.
97
+
98
+ If you want changes, respond with:
99
+ - "modify: [your changes]"
100
+ - "different approach: [alternative]"
101
+ - "skip phase 2 and do phase 3 first"
102
+
103
+ ## Integration with Other Commands
104
+
105
+ After planning:
106
+ - Use `/tdd` to implement with test-driven development
107
+ - Use `/build-fix` if build errors occur
108
+ - Use `/code-review` to review completed implementation
109
+
110
+ ## Related Agents
111
+
112
+ This command invokes the `planner` agent provided by ECC.
113
+
114
+ For manual installs, the source file lives at:
115
+ `agents/planner.md`
@@ -0,0 +1,272 @@
1
+ # PM2 Init
2
+
3
+ Auto-analyze project and generate PM2 service commands.
4
+
5
+ **Command**: `$ARGUMENTS`
6
+
7
+ ---
8
+
9
+ ## Workflow
10
+
11
+ 1. Check PM2 (install via `npm install -g pm2` if missing)
12
+ 2. Scan project to identify services (frontend/backend/database)
13
+ 3. Generate config files and individual command files
14
+
15
+ ---
16
+
17
+ ## Service Detection
18
+
19
+ | Type | Detection | Default Port |
20
+ |------|-----------|--------------|
21
+ | Vite | vite.config.* | 5173 |
22
+ | Next.js | next.config.* | 3000 |
23
+ | Nuxt | nuxt.config.* | 3000 |
24
+ | CRA | react-scripts in package.json | 3000 |
25
+ | Express/Node | server/backend/api directory + package.json | 3000 |
26
+ | FastAPI/Flask | requirements.txt / pyproject.toml | 8000 |
27
+ | Go | go.mod / main.go | 8080 |
28
+
29
+ **Port Detection Priority**: User specified > .env > config file > scripts args > default port
30
+
31
+ ---
32
+
33
+ ## Generated Files
34
+
35
+ ```
36
+ project/
37
+ ├── ecosystem.config.cjs # PM2 config
38
+ ├── {backend}/start.cjs # Python wrapper (if applicable)
39
+ └── .claude/
40
+ ├── commands/
41
+ │ ├── pm2-all.md # Start all + monit
42
+ │ ├── pm2-all-stop.md # Stop all
43
+ │ ├── pm2-all-restart.md # Restart all
44
+ │ ├── pm2-{port}.md # Start single + logs
45
+ │ ├── pm2-{port}-stop.md # Stop single
46
+ │ ├── pm2-{port}-restart.md # Restart single
47
+ │ ├── pm2-logs.md # View all logs
48
+ │ └── pm2-status.md # View status
49
+ └── scripts/
50
+ ├── pm2-logs-{port}.ps1 # Single service logs
51
+ └── pm2-monit.ps1 # PM2 monitor
52
+ ```
53
+
54
+ ---
55
+
56
+ ## Windows Configuration (IMPORTANT)
57
+
58
+ ### ecosystem.config.cjs
59
+
60
+ **Must use `.cjs` extension**
61
+
62
+ ```javascript
63
+ module.exports = {
64
+ apps: [
65
+ // Node.js (Vite/Next/Nuxt)
66
+ {
67
+ name: 'project-3000',
68
+ cwd: './packages/web',
69
+ script: 'node_modules/vite/bin/vite.js',
70
+ args: '--port 3000',
71
+ interpreter: 'C:/Program Files/nodejs/node.exe',
72
+ env: { NODE_ENV: 'development' }
73
+ },
74
+ // Python
75
+ {
76
+ name: 'project-8000',
77
+ cwd: './backend',
78
+ script: 'start.cjs',
79
+ interpreter: 'C:/Program Files/nodejs/node.exe',
80
+ env: { PYTHONUNBUFFERED: '1' }
81
+ }
82
+ ]
83
+ }
84
+ ```
85
+
86
+ **Framework script paths:**
87
+
88
+ | Framework | script | args |
89
+ |-----------|--------|------|
90
+ | Vite | `node_modules/vite/bin/vite.js` | `--port {port}` |
91
+ | Next.js | `node_modules/next/dist/bin/next` | `dev -p {port}` |
92
+ | Nuxt | `node_modules/nuxt/bin/nuxt.mjs` | `dev --port {port}` |
93
+ | Express | `src/index.js` or `server.js` | - |
94
+
95
+ ### Python Wrapper Script (start.cjs)
96
+
97
+ ```javascript
98
+ const { spawn } = require('child_process');
99
+ const proc = spawn('python', ['-m', 'uvicorn', 'app.main:app', '--host', '0.0.0.0', '--port', '8000', '--reload'], {
100
+ cwd: __dirname, stdio: 'inherit', windowsHide: true
101
+ });
102
+ proc.on('close', (code) => process.exit(code));
103
+ ```
104
+
105
+ ---
106
+
107
+ ## Command File Templates (Minimal Content)
108
+
109
+ ### pm2-all.md (Start all + monit)
110
+ ````markdown
111
+ Start all services and open PM2 monitor.
112
+ ```bash
113
+ cd "{PROJECT_ROOT}" && pm2 start ecosystem.config.cjs && start wt.exe -d "{PROJECT_ROOT}" pwsh -NoExit -c "pm2 monit"
114
+ ```
115
+ ````
116
+
117
+ ### pm2-all-stop.md
118
+ ````markdown
119
+ Stop all services.
120
+ ```bash
121
+ cd "{PROJECT_ROOT}" && pm2 stop all
122
+ ```
123
+ ````
124
+
125
+ ### pm2-all-restart.md
126
+ ````markdown
127
+ Restart all services.
128
+ ```bash
129
+ cd "{PROJECT_ROOT}" && pm2 restart all
130
+ ```
131
+ ````
132
+
133
+ ### pm2-{port}.md (Start single + logs)
134
+ ````markdown
135
+ Start {name} ({port}) and open logs.
136
+ ```bash
137
+ cd "{PROJECT_ROOT}" && pm2 start ecosystem.config.cjs --only {name} && start wt.exe -d "{PROJECT_ROOT}" pwsh -NoExit -c "pm2 logs {name}"
138
+ ```
139
+ ````
140
+
141
+ ### pm2-{port}-stop.md
142
+ ````markdown
143
+ Stop {name} ({port}).
144
+ ```bash
145
+ cd "{PROJECT_ROOT}" && pm2 stop {name}
146
+ ```
147
+ ````
148
+
149
+ ### pm2-{port}-restart.md
150
+ ````markdown
151
+ Restart {name} ({port}).
152
+ ```bash
153
+ cd "{PROJECT_ROOT}" && pm2 restart {name}
154
+ ```
155
+ ````
156
+
157
+ ### pm2-logs.md
158
+ ````markdown
159
+ View all PM2 logs.
160
+ ```bash
161
+ cd "{PROJECT_ROOT}" && pm2 logs
162
+ ```
163
+ ````
164
+
165
+ ### pm2-status.md
166
+ ````markdown
167
+ View PM2 status.
168
+ ```bash
169
+ cd "{PROJECT_ROOT}" && pm2 status
170
+ ```
171
+ ````
172
+
173
+ ### PowerShell Scripts (pm2-logs-{port}.ps1)
174
+ ```powershell
175
+ Set-Location "{PROJECT_ROOT}"
176
+ pm2 logs {name}
177
+ ```
178
+
179
+ ### PowerShell Scripts (pm2-monit.ps1)
180
+ ```powershell
181
+ Set-Location "{PROJECT_ROOT}"
182
+ pm2 monit
183
+ ```
184
+
185
+ ---
186
+
187
+ ## Key Rules
188
+
189
+ 1. **Config file**: `ecosystem.config.cjs` (not .js)
190
+ 2. **Node.js**: Specify bin path directly + interpreter
191
+ 3. **Python**: Node.js wrapper script + `windowsHide: true`
192
+ 4. **Open new window**: `start wt.exe -d "{path}" pwsh -NoExit -c "command"`
193
+ 5. **Minimal content**: Each command file has only 1-2 lines description + bash block
194
+ 6. **Direct execution**: No AI parsing needed, just run the bash command
195
+
196
+ ---
197
+
198
+ ## Execute
199
+
200
+ Based on `$ARGUMENTS`, execute init:
201
+
202
+ 1. Scan project for services
203
+ 2. Generate `ecosystem.config.cjs`
204
+ 3. Generate `{backend}/start.cjs` for Python services (if applicable)
205
+ 4. Generate command files in `.claude/commands/`
206
+ 5. Generate script files in `.claude/scripts/`
207
+ 6. **Update project CLAUDE.md** with PM2 info (see below)
208
+ 7. **Display completion summary** with terminal commands
209
+
210
+ ---
211
+
212
+ ## Post-Init: Update CLAUDE.md
213
+
214
+ After generating files, append PM2 section to project's `CLAUDE.md` (create if not exists):
215
+
216
+ ````markdown
217
+ ## PM2 Services
218
+
219
+ | Port | Name | Type |
220
+ |------|------|------|
221
+ | {port} | {name} | {type} |
222
+
223
+ **Terminal Commands:**
224
+ ```bash
225
+ pm2 start ecosystem.config.cjs # First time
226
+ pm2 start all # After first time
227
+ pm2 stop all / pm2 restart all
228
+ pm2 start {name} / pm2 stop {name}
229
+ pm2 logs / pm2 status / pm2 monit
230
+ pm2 save # Save process list
231
+ pm2 resurrect # Restore saved list
232
+ ```
233
+ ````
234
+
235
+ **Rules for CLAUDE.md update:**
236
+ - If PM2 section exists, replace it
237
+ - If not exists, append to end
238
+ - Keep content minimal and essential
239
+
240
+ ---
241
+
242
+ ## Post-Init: Display Summary
243
+
244
+ After all files generated, output:
245
+
246
+ ```
247
+ ## PM2 Init Complete
248
+
249
+ **Services:**
250
+
251
+ | Port | Name | Type |
252
+ |------|------|------|
253
+ | {port} | {name} | {type} |
254
+
255
+ **Claude Commands:** /pm2-all, /pm2-all-stop, /pm2-{port}, /pm2-{port}-stop, /pm2-logs, /pm2-status
256
+
257
+ **Terminal Commands:**
258
+ ## First time (with config file)
259
+ pm2 start ecosystem.config.cjs && pm2 save
260
+
261
+ ## After first time (simplified)
262
+ pm2 start all # Start all
263
+ pm2 stop all # Stop all
264
+ pm2 restart all # Restart all
265
+ pm2 start {name} # Start single
266
+ pm2 stop {name} # Stop single
267
+ pm2 logs # View logs
268
+ pm2 monit # Monitor panel
269
+ pm2 resurrect # Restore saved processes
270
+
271
+ **Tip:** Run `pm2 save` after first start to enable simplified commands.
272
+ ```
@@ -0,0 +1,81 @@
1
+ ---
2
+ description: Preview server start, stop, and status check. Local development server management.
3
+ ---
4
+
5
+ # /preview - Preview Management
6
+
7
+ $ARGUMENTS
8
+
9
+ ---
10
+
11
+ ## Task
12
+
13
+ Manage preview server: start, stop, status check.
14
+
15
+ ### Commands
16
+
17
+ ```
18
+ /preview - Show current status
19
+ /preview start - Start server
20
+ /preview stop - Stop server
21
+ /preview restart - Restart
22
+ /preview check - Health check
23
+ ```
24
+
25
+ ---
26
+
27
+ ## Usage Examples
28
+
29
+ ### Start Server
30
+ ```
31
+ /preview start
32
+
33
+ Response:
34
+ 🚀 Starting preview...
35
+ Port: 3000
36
+ Type: Next.js
37
+
38
+ ✅ Preview ready!
39
+ URL: http://localhost:3000
40
+ ```
41
+
42
+ ### Status Check
43
+ ```
44
+ /preview
45
+
46
+ Response:
47
+ === Preview Status ===
48
+
49
+ 🌐 URL: http://localhost:3000
50
+ 📁 Project: C:/projects/my-app
51
+ 🏷️ Type: nextjs
52
+ 💚 Health: OK
53
+ ```
54
+
55
+ ### Port Conflict
56
+ ```
57
+ /preview start
58
+
59
+ Response:
60
+ ⚠️ Port 3000 is in use.
61
+
62
+ Options:
63
+ 1. Start on port 3001
64
+ 2. Close app on 3000
65
+ 3. Specify different port
66
+
67
+ Which one? (default: 1)
68
+ ```
69
+
70
+ ---
71
+
72
+ ## Technical
73
+
74
+ Auto preview uses `auto_preview.py` script:
75
+
76
+ ```bash
77
+ python .agent/scripts/auto_preview.py start [port]
78
+ python .agent/scripts/auto_preview.py stop
79
+ python .agent/scripts/auto_preview.py status
80
+ ```
81
+
@@ -0,0 +1,39 @@
1
+ ---
2
+ name: projects
3
+ description: List known projects and their instinct statistics
4
+ command: true
5
+ ---
6
+
7
+ # Projects Command
8
+
9
+ List project registry entries and per-project instinct/observation counts for continuous-learning-v2.
10
+
11
+ ## Implementation
12
+
13
+ Run the instinct CLI using the plugin root path:
14
+
15
+ ```bash
16
+ python3 "${CLAUDE_PLUGIN_ROOT}/skills/continuous-learning-v2/scripts/instinct-cli.py" projects
17
+ ```
18
+
19
+ Or if `CLAUDE_PLUGIN_ROOT` is not set (manual installation):
20
+
21
+ ```bash
22
+ python3 ~/.claude/skills/continuous-learning-v2/scripts/instinct-cli.py projects
23
+ ```
24
+
25
+ ## Usage
26
+
27
+ ```bash
28
+ /projects
29
+ ```
30
+
31
+ ## What to Do
32
+
33
+ 1. Read `~/.claude/homunculus/projects.json`
34
+ 2. For each project, display:
35
+ - Project name, id, root, remote
36
+ - Personal and inherited instinct counts
37
+ - Observation event count
38
+ - Last seen timestamp
39
+ 3. Also display global instinct totals
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: promote
3
+ description: Promote project-scoped instincts to global scope
4
+ command: true
5
+ ---
6
+
7
+ # Promote Command
8
+
9
+ Promote instincts from project scope to global scope in continuous-learning-v2.
10
+
11
+ ## Implementation
12
+
13
+ Run the instinct CLI using the plugin root path:
14
+
15
+ ```bash
16
+ python3 "${CLAUDE_PLUGIN_ROOT}/skills/continuous-learning-v2/scripts/instinct-cli.py" promote [instinct-id] [--force] [--dry-run]
17
+ ```
18
+
19
+ Or if `CLAUDE_PLUGIN_ROOT` is not set (manual installation):
20
+
21
+ ```bash
22
+ python3 ~/.claude/skills/continuous-learning-v2/scripts/instinct-cli.py promote [instinct-id] [--force] [--dry-run]
23
+ ```
24
+
25
+ ## Usage
26
+
27
+ ```bash
28
+ /promote # Auto-detect promotion candidates
29
+ /promote --dry-run # Preview auto-promotion candidates
30
+ /promote --force # Promote all qualified candidates without prompt
31
+ /promote grep-before-edit # Promote one specific instinct from current project
32
+ ```
33
+
34
+ ## What to Do
35
+
36
+ 1. Detect current project
37
+ 2. If `instinct-id` is provided, promote only that instinct (if present in current project)
38
+ 3. Otherwise, find cross-project candidates that:
39
+ - Appear in at least 2 projects
40
+ - Meet confidence threshold
41
+ 4. Write promoted instincts to `~/.claude/homunculus/instincts/personal/` with `scope: global`
@@ -0,0 +1,38 @@
1
+ ---
2
+ description: Analyze a draft prompt and output an optimized, ECC-enriched version ready to paste and run. Does NOT execute the task — outputs advisory analysis only.
3
+ ---
4
+
5
+ # /prompt-optimize
6
+
7
+ Analyze and optimize the following prompt for maximum ECC leverage.
8
+
9
+ ## Your Task
10
+
11
+ Apply the **prompt-optimizer** skill to the user's input below. Follow the 6-phase analysis pipeline:
12
+
13
+ 0. **Project Detection** — Read CLAUDE.md, detect tech stack from project files (package.json, go.mod, pyproject.toml, etc.)
14
+ 1. **Intent Detection** — Classify the task type (new feature, bug fix, refactor, research, testing, review, documentation, infrastructure, design)
15
+ 2. **Scope Assessment** — Evaluate complexity (TRIVIAL / LOW / MEDIUM / HIGH / EPIC), using codebase size as signal if detected
16
+ 3. **ECC Component Matching** — Map to specific skills, commands, agents, and model tier
17
+ 4. **Missing Context Detection** — Identify gaps. If 3+ critical items missing, ask the user to clarify before generating
18
+ 5. **Workflow & Model** — Determine lifecycle position, recommend model tier, and split into multiple prompts if HIGH/EPIC
19
+
20
+ ## Output Requirements
21
+
22
+ - Present diagnosis, recommended ECC components, and an optimized prompt using the Output Format from the prompt-optimizer skill
23
+ - Provide both **Full Version** (detailed) and **Quick Version** (compact, varied by intent type)
24
+ - Respond in the same language as the user's input
25
+ - The optimized prompt must be complete and ready to copy-paste into a new session
26
+ - End with a footer offering adjustment or a clear next step for starting a separate execution request
27
+
28
+ ## CRITICAL
29
+
30
+ Do NOT execute the user's task. Output ONLY the analysis and optimized prompt.
31
+ If the user asks for direct execution, explain that `/prompt-optimize` only produces advisory output and tell them to start a normal task request instead.
32
+
33
+ Note: `blueprint` is a **skill**, not a slash command. Write "Use the blueprint skill"
34
+ instead of presenting it as a `/...` command.
35
+
36
+ ## User Input
37
+
38
+ $ARGUMENTS
@@ -0,0 +1,31 @@
1
+ ---
2
+ name: prune
3
+ description: Delete pending instincts older than 30 days that were never promoted
4
+ command: true
5
+ ---
6
+
7
+ # Prune Pending Instincts
8
+
9
+ Remove expired pending instincts that were auto-generated but never reviewed or promoted.
10
+
11
+ ## Implementation
12
+
13
+ Run the instinct CLI using the plugin root path:
14
+
15
+ ```bash
16
+ python3 "${CLAUDE_PLUGIN_ROOT}/skills/continuous-learning-v2/scripts/instinct-cli.py" prune
17
+ ```
18
+
19
+ Or if `CLAUDE_PLUGIN_ROOT` is not set (manual installation):
20
+
21
+ ```bash
22
+ python3 ~/.claude/skills/continuous-learning-v2/scripts/instinct-cli.py prune
23
+ ```
24
+
25
+ ## Usage
26
+
27
+ ```
28
+ /prune # Delete instincts older than 30 days
29
+ /prune --max-age 60 # Custom age threshold (days)
30
+ /prune --dry-run # Preview without deleting
31
+ ```