@bhimudev/gnanai 0.4.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 (274) hide show
  1. package/README.md +270 -0
  2. package/dist/bin/cli.d.ts +3 -0
  3. package/dist/bin/cli.d.ts.map +1 -0
  4. package/dist/bin/cli.js +188 -0
  5. package/dist/bin/cli.js.map +1 -0
  6. package/dist/commands/cleanup.d.ts +21 -0
  7. package/dist/commands/cleanup.d.ts.map +1 -0
  8. package/dist/commands/cleanup.js +380 -0
  9. package/dist/commands/cleanup.js.map +1 -0
  10. package/dist/commands/dispatch.d.ts +13 -0
  11. package/dist/commands/dispatch.d.ts.map +1 -0
  12. package/dist/commands/dispatch.js +85 -0
  13. package/dist/commands/dispatch.js.map +1 -0
  14. package/dist/commands/doctor.d.ts +2 -0
  15. package/dist/commands/doctor.d.ts.map +1 -0
  16. package/dist/commands/doctor.js +155 -0
  17. package/dist/commands/doctor.js.map +1 -0
  18. package/dist/commands/generate.d.ts +3 -0
  19. package/dist/commands/generate.d.ts.map +1 -0
  20. package/dist/commands/generate.js +167 -0
  21. package/dist/commands/generate.js.map +1 -0
  22. package/dist/commands/init.d.ts +10 -0
  23. package/dist/commands/init.d.ts.map +1 -0
  24. package/dist/commands/init.js +711 -0
  25. package/dist/commands/init.js.map +1 -0
  26. package/dist/commands/knowledge-sync.d.ts +69 -0
  27. package/dist/commands/knowledge-sync.d.ts.map +1 -0
  28. package/dist/commands/knowledge-sync.js +661 -0
  29. package/dist/commands/knowledge-sync.js.map +1 -0
  30. package/dist/commands/knowledge.d.ts +35 -0
  31. package/dist/commands/knowledge.d.ts.map +1 -0
  32. package/dist/commands/knowledge.js +254 -0
  33. package/dist/commands/knowledge.js.map +1 -0
  34. package/dist/commands/rollback.d.ts +13 -0
  35. package/dist/commands/rollback.d.ts.map +1 -0
  36. package/dist/commands/rollback.js +186 -0
  37. package/dist/commands/rollback.js.map +1 -0
  38. package/dist/commands/setup-config.d.ts +6 -0
  39. package/dist/commands/setup-config.d.ts.map +1 -0
  40. package/dist/commands/setup-config.js +663 -0
  41. package/dist/commands/setup-config.js.map +1 -0
  42. package/dist/commands/setup-project.d.ts +6 -0
  43. package/dist/commands/setup-project.d.ts.map +1 -0
  44. package/dist/commands/setup-project.js +361 -0
  45. package/dist/commands/setup-project.js.map +1 -0
  46. package/dist/commands/setup.d.ts +3 -0
  47. package/dist/commands/setup.d.ts.map +1 -0
  48. package/dist/commands/setup.js +293 -0
  49. package/dist/commands/setup.js.map +1 -0
  50. package/dist/commands/status.d.ts +51 -0
  51. package/dist/commands/status.d.ts.map +1 -0
  52. package/dist/commands/status.js +182 -0
  53. package/dist/commands/status.js.map +1 -0
  54. package/dist/commands/uninstall.d.ts +3 -0
  55. package/dist/commands/uninstall.d.ts.map +1 -0
  56. package/dist/commands/uninstall.js +173 -0
  57. package/dist/commands/uninstall.js.map +1 -0
  58. package/dist/commands/update.d.ts +10 -0
  59. package/dist/commands/update.d.ts.map +1 -0
  60. package/dist/commands/update.js +435 -0
  61. package/dist/commands/update.js.map +1 -0
  62. package/dist/commands/worktree.d.ts +30 -0
  63. package/dist/commands/worktree.d.ts.map +1 -0
  64. package/dist/commands/worktree.js +262 -0
  65. package/dist/commands/worktree.js.map +1 -0
  66. package/dist/generator/claude-cli.d.ts +24 -0
  67. package/dist/generator/claude-cli.d.ts.map +1 -0
  68. package/dist/generator/claude-cli.js +239 -0
  69. package/dist/generator/claude-cli.js.map +1 -0
  70. package/dist/generator/prompt-builder.d.ts +7 -0
  71. package/dist/generator/prompt-builder.d.ts.map +1 -0
  72. package/dist/generator/prompt-builder.js +144 -0
  73. package/dist/generator/prompt-builder.js.map +1 -0
  74. package/dist/index.d.ts +36 -0
  75. package/dist/index.d.ts.map +1 -0
  76. package/dist/index.js +45 -0
  77. package/dist/index.js.map +1 -0
  78. package/dist/mcp/embeddings.d.ts +53 -0
  79. package/dist/mcp/embeddings.d.ts.map +1 -0
  80. package/dist/mcp/embeddings.js +68 -0
  81. package/dist/mcp/embeddings.js.map +1 -0
  82. package/dist/mcp/hybrid-search.d.ts +25 -0
  83. package/dist/mcp/hybrid-search.d.ts.map +1 -0
  84. package/dist/mcp/hybrid-search.js +72 -0
  85. package/dist/mcp/hybrid-search.js.map +1 -0
  86. package/dist/mcp/knowledge-server.d.ts +4 -0
  87. package/dist/mcp/knowledge-server.d.ts.map +1 -0
  88. package/dist/mcp/knowledge-server.js +294 -0
  89. package/dist/mcp/knowledge-server.js.map +1 -0
  90. package/dist/mcp/knowledge-utils.d.ts +65 -0
  91. package/dist/mcp/knowledge-utils.d.ts.map +1 -0
  92. package/dist/mcp/knowledge-utils.js +207 -0
  93. package/dist/mcp/knowledge-utils.js.map +1 -0
  94. package/dist/mcp/search-factory.d.ts +9 -0
  95. package/dist/mcp/search-factory.d.ts.map +1 -0
  96. package/dist/mcp/search-factory.js +23 -0
  97. package/dist/mcp/search-factory.js.map +1 -0
  98. package/dist/mcp/search-index.d.ts +45 -0
  99. package/dist/mcp/search-index.d.ts.map +1 -0
  100. package/dist/mcp/search-index.js +2 -0
  101. package/dist/mcp/search-index.js.map +1 -0
  102. package/dist/mcp/search-minisearch.d.ts +46 -0
  103. package/dist/mcp/search-minisearch.d.ts.map +1 -0
  104. package/dist/mcp/search-minisearch.js +99 -0
  105. package/dist/mcp/search-minisearch.js.map +1 -0
  106. package/dist/mcp/search-sqlite.d.ts +30 -0
  107. package/dist/mcp/search-sqlite.d.ts.map +1 -0
  108. package/dist/mcp/search-sqlite.js +188 -0
  109. package/dist/mcp/search-sqlite.js.map +1 -0
  110. package/dist/mcp/vector-store.d.ts +52 -0
  111. package/dist/mcp/vector-store.d.ts.map +1 -0
  112. package/dist/mcp/vector-store.js +183 -0
  113. package/dist/mcp/vector-store.js.map +1 -0
  114. package/dist/scaffold/copy-core-agents.d.ts +2 -0
  115. package/dist/scaffold/copy-core-agents.d.ts.map +1 -0
  116. package/dist/scaffold/copy-core-agents.js +90 -0
  117. package/dist/scaffold/copy-core-agents.js.map +1 -0
  118. package/dist/scaffold/create-claude-settings.d.ts +40 -0
  119. package/dist/scaffold/create-claude-settings.d.ts.map +1 -0
  120. package/dist/scaffold/create-claude-settings.js +422 -0
  121. package/dist/scaffold/create-claude-settings.js.map +1 -0
  122. package/dist/scaffold/create-config.d.ts +14 -0
  123. package/dist/scaffold/create-config.d.ts.map +1 -0
  124. package/dist/scaffold/create-config.js +199 -0
  125. package/dist/scaffold/create-config.js.map +1 -0
  126. package/dist/scaffold/create-project-description.d.ts +12 -0
  127. package/dist/scaffold/create-project-description.d.ts.map +1 -0
  128. package/dist/scaffold/create-project-description.js +104 -0
  129. package/dist/scaffold/create-project-description.js.map +1 -0
  130. package/dist/scaffold/create-structure.d.ts +2 -0
  131. package/dist/scaffold/create-structure.d.ts.map +1 -0
  132. package/dist/scaffold/create-structure.js +146 -0
  133. package/dist/scaffold/create-structure.js.map +1 -0
  134. package/dist/types/dependency-analysis.d.ts +11 -0
  135. package/dist/types/dependency-analysis.d.ts.map +1 -0
  136. package/dist/types/dependency-analysis.js +2 -0
  137. package/dist/types/dependency-analysis.js.map +1 -0
  138. package/dist/types/index.d.ts +526 -0
  139. package/dist/types/index.d.ts.map +1 -0
  140. package/dist/types/index.js +3 -0
  141. package/dist/types/index.js.map +1 -0
  142. package/dist/types/task.d.ts +25 -0
  143. package/dist/types/task.d.ts.map +1 -0
  144. package/dist/types/task.js +3 -0
  145. package/dist/types/task.js.map +1 -0
  146. package/dist/utils/analyze-files.d.ts +7 -0
  147. package/dist/utils/analyze-files.d.ts.map +1 -0
  148. package/dist/utils/analyze-files.js +27 -0
  149. package/dist/utils/analyze-files.js.map +1 -0
  150. package/dist/utils/backup.d.ts +102 -0
  151. package/dist/utils/backup.d.ts.map +1 -0
  152. package/dist/utils/backup.js +352 -0
  153. package/dist/utils/backup.js.map +1 -0
  154. package/dist/utils/ci-provider.d.ts +23 -0
  155. package/dist/utils/ci-provider.d.ts.map +1 -0
  156. package/dist/utils/ci-provider.js +525 -0
  157. package/dist/utils/ci-provider.js.map +1 -0
  158. package/dist/utils/ci-status.d.ts +57 -0
  159. package/dist/utils/ci-status.d.ts.map +1 -0
  160. package/dist/utils/ci-status.js +349 -0
  161. package/dist/utils/ci-status.js.map +1 -0
  162. package/dist/utils/dependency-analysis.d.ts +34 -0
  163. package/dist/utils/dependency-analysis.d.ts.map +1 -0
  164. package/dist/utils/dependency-analysis.js +298 -0
  165. package/dist/utils/dependency-analysis.js.map +1 -0
  166. package/dist/utils/detect-git.d.ts +57 -0
  167. package/dist/utils/detect-git.d.ts.map +1 -0
  168. package/dist/utils/detect-git.js +439 -0
  169. package/dist/utils/detect-git.js.map +1 -0
  170. package/dist/utils/detect-mcp.d.ts +32 -0
  171. package/dist/utils/detect-mcp.d.ts.map +1 -0
  172. package/dist/utils/detect-mcp.js +178 -0
  173. package/dist/utils/detect-mcp.js.map +1 -0
  174. package/dist/utils/detect-project.d.ts +3 -0
  175. package/dist/utils/detect-project.d.ts.map +1 -0
  176. package/dist/utils/detect-project.js +155 -0
  177. package/dist/utils/detect-project.js.map +1 -0
  178. package/dist/utils/file-comparison.d.ts +89 -0
  179. package/dist/utils/file-comparison.d.ts.map +1 -0
  180. package/dist/utils/file-comparison.js +301 -0
  181. package/dist/utils/file-comparison.js.map +1 -0
  182. package/dist/utils/file-merger.d.ts +74 -0
  183. package/dist/utils/file-merger.d.ts.map +1 -0
  184. package/dist/utils/file-merger.js +350 -0
  185. package/dist/utils/file-merger.js.map +1 -0
  186. package/dist/utils/logger.d.ts +26 -0
  187. package/dist/utils/logger.d.ts.map +1 -0
  188. package/dist/utils/logger.js +72 -0
  189. package/dist/utils/logger.js.map +1 -0
  190. package/dist/utils/managed-process.d.ts +109 -0
  191. package/dist/utils/managed-process.d.ts.map +1 -0
  192. package/dist/utils/managed-process.js +481 -0
  193. package/dist/utils/managed-process.js.map +1 -0
  194. package/dist/utils/merge-claude-settings.d.ts +65 -0
  195. package/dist/utils/merge-claude-settings.d.ts.map +1 -0
  196. package/dist/utils/merge-claude-settings.js +133 -0
  197. package/dist/utils/merge-claude-settings.js.map +1 -0
  198. package/dist/utils/migration.d.ts +74 -0
  199. package/dist/utils/migration.d.ts.map +1 -0
  200. package/dist/utils/migration.js +345 -0
  201. package/dist/utils/migration.js.map +1 -0
  202. package/dist/utils/process-health.d.ts +51 -0
  203. package/dist/utils/process-health.d.ts.map +1 -0
  204. package/dist/utils/process-health.js +123 -0
  205. package/dist/utils/process-health.js.map +1 -0
  206. package/dist/utils/process-registry.d.ts +20 -0
  207. package/dist/utils/process-registry.d.ts.map +1 -0
  208. package/dist/utils/process-registry.js +151 -0
  209. package/dist/utils/process-registry.js.map +1 -0
  210. package/dist/utils/process-tree.d.ts +51 -0
  211. package/dist/utils/process-tree.d.ts.map +1 -0
  212. package/dist/utils/process-tree.js +499 -0
  213. package/dist/utils/process-tree.js.map +1 -0
  214. package/dist/utils/repair-mcp-config.d.ts +15 -0
  215. package/dist/utils/repair-mcp-config.d.ts.map +1 -0
  216. package/dist/utils/repair-mcp-config.js +129 -0
  217. package/dist/utils/repair-mcp-config.js.map +1 -0
  218. package/dist/utils/task-lifecycle.d.ts +60 -0
  219. package/dist/utils/task-lifecycle.d.ts.map +1 -0
  220. package/dist/utils/task-lifecycle.js +310 -0
  221. package/dist/utils/task-lifecycle.js.map +1 -0
  222. package/dist/utils/update-agent-mcp.d.ts +7 -0
  223. package/dist/utils/update-agent-mcp.d.ts.map +1 -0
  224. package/dist/utils/update-agent-mcp.js +115 -0
  225. package/dist/utils/update-agent-mcp.js.map +1 -0
  226. package/dist/utils/update-agent-templates.d.ts +6 -0
  227. package/dist/utils/update-agent-templates.d.ts.map +1 -0
  228. package/dist/utils/update-agent-templates.js +56 -0
  229. package/dist/utils/update-agent-templates.js.map +1 -0
  230. package/dist/utils/update-config-ci.d.ts +7 -0
  231. package/dist/utils/update-config-ci.d.ts.map +1 -0
  232. package/dist/utils/update-config-ci.js +72 -0
  233. package/dist/utils/update-config-ci.js.map +1 -0
  234. package/dist/utils/update-config-git.d.ts +18 -0
  235. package/dist/utils/update-config-git.d.ts.map +1 -0
  236. package/dist/utils/update-config-git.js +146 -0
  237. package/dist/utils/update-config-git.js.map +1 -0
  238. package/dist/utils/update-config-mcp.d.ts +7 -0
  239. package/dist/utils/update-config-mcp.d.ts.map +1 -0
  240. package/dist/utils/update-config-mcp.js +98 -0
  241. package/dist/utils/update-config-mcp.js.map +1 -0
  242. package/dist/utils/validate-config.d.ts +3 -0
  243. package/dist/utils/validate-config.d.ts.map +1 -0
  244. package/dist/utils/validate-config.js +109 -0
  245. package/dist/utils/validate-config.js.map +1 -0
  246. package/dist/utils/version-tracker.d.ts +130 -0
  247. package/dist/utils/version-tracker.d.ts.map +1 -0
  248. package/dist/utils/version-tracker.js +298 -0
  249. package/dist/utils/version-tracker.js.map +1 -0
  250. package/dist/utils/worktree.d.ts +68 -0
  251. package/dist/utils/worktree.d.ts.map +1 -0
  252. package/dist/utils/worktree.js +446 -0
  253. package/dist/utils/worktree.js.map +1 -0
  254. package/package.json +77 -0
  255. package/templates/ARCHAI_README.md +329 -0
  256. package/templates/CLAUDE.md +67 -0
  257. package/templates/PROMPTS.md +506 -0
  258. package/templates/core-agents/boss-agent.md +671 -0
  259. package/templates/core-agents/cleanup-agent.md +145 -0
  260. package/templates/core-agents/code-reviewer.md +175 -0
  261. package/templates/core-agents/critical-reviewer.md +117 -0
  262. package/templates/core-agents/deep-analyst.md +216 -0
  263. package/templates/core-agents/finalization-agent.md +252 -0
  264. package/templates/core-agents/git-coordinator.md +240 -0
  265. package/templates/core-agents/implementation-agent.md +151 -0
  266. package/templates/core-agents/maestro-agent.md +413 -0
  267. package/templates/core-agents/maestro-headless-agent.md +422 -0
  268. package/templates/core-agents/plan-validator.md +198 -0
  269. package/templates/core-agents/quick-fix.md +56 -0
  270. package/templates/core-agents/routing-templates.md +338 -0
  271. package/templates/core-agents/task-orchestrator.md +143 -0
  272. package/templates/core-agents/task-prep.md +202 -0
  273. package/templates/core-agents/tdd-designer.md +143 -0
  274. package/templates/specialist-meta.md +275 -0
@@ -0,0 +1,506 @@
1
+ # archai Prompt Templates
2
+
3
+ Complete reference for using the agent system. Copy and customize these prompts.
4
+
5
+ ---
6
+
7
+ ## Full Orchestration Prompt (Recommended)
8
+
9
+ Copy this to start the full three-phase workflow:
10
+
11
+ ```
12
+ Follow the orchestration guide in .claude/agents/maestro-agent.md to create an
13
+ implementation plan for: {YOUR TASK DESCRIPTION}
14
+
15
+ PHASE 1 INSTRUCTIONS (Planning - requires approval):
16
+ 1. Read each agent's full instruction file from .claude/agents/ BEFORE spawning
17
+ 2. Pass the COMPLETE instructions to each subagent in the Task prompt
18
+ 3. Save ALL agent outputs to .claude/state/ directory
19
+ 4. Run at least 2 planning iterations (THINK → VALIDATE → TEST DESIGN → VALIDATE TESTS → RETHINK)
20
+ 5. After planning complete, write final plan to .claude/plans/{task-name}.md
21
+ 6. STOP and present the plan summary - do NOT implement until I say "APPROVE"
22
+
23
+ PHASE 2 INSTRUCTIONS (Implementation - AUTONOMOUS after approval):
24
+ When I say "APPROVE", execute Phase 2 AUTONOMOUSLY:
25
+ - Implement ALL steps without stopping to ask
26
+ - Run tests after each step
27
+ - Fix failures automatically (up to 5 attempts per step)
28
+ - Only report back when ALL DONE or truly BLOCKED
29
+ - DO NOT ask "should I proceed?" - just execute the full loop
30
+ - When Phase 2 complete, present summary and wait for FINAL APPROVAL
31
+
32
+ PHASE 3 INSTRUCTIONS (Finalization - after implementation approved):
33
+ When I say "APPROVE" on implementation:
34
+ - Read .claude/agents/finalization-agent.md
35
+ - Spawn finalization-agent to verify, cleanup, commit, push, wait for CI/CD
36
+ - Report final status
37
+
38
+ Start with Phase 1, Iteration 1: Read .claude/agents/deep-analyst.md and
39
+ spawn a deep-analyst subagent to analyze the task.
40
+ ```
41
+
42
+ ---
43
+
44
+ ## Task Preparation Prompt (Recommended First Step)
45
+
46
+ Use this to structure a vague or complex task before execution:
47
+
48
+ ```
49
+ Use task-prep for: {YOUR RAW TASK DESCRIPTION}
50
+ ```
51
+
52
+ After approval, feed the result to the execution loop:
53
+
54
+ ```
55
+ Use maestro-agent for: the prepared task in .claude/state/prepared-task.md
56
+ ```
57
+
58
+ ---
59
+
60
+ ## Phase 2 Only Prompt (After Plan is Approved)
61
+
62
+ Use this when resuming after approval:
63
+
64
+ ```
65
+ The plan in .claude/plans/{task-name}.md has been APPROVED.
66
+
67
+ Execute Phase 2 AUTONOMOUSLY:
68
+ 1. Read .claude/agents/implementation-agent.md
69
+ 2. Spawn implementation-agent with FULL instructions
70
+ 3. The agent must execute ALL steps WITHOUT stopping to ask
71
+ 4. Loop: implement → test → fix failures → next step → repeat
72
+ 5. Only report back when COMPLETELY DONE or truly BLOCKED
73
+ 6. When done, present summary and wait for FINAL APPROVAL
74
+
75
+ DO NOT ask for permission between steps. Just execute until done.
76
+ ```
77
+
78
+ ---
79
+
80
+ ## Phase 3 Only Prompt (After Implementation is Approved)
81
+
82
+ Use this when implementation is done and you've approved it:
83
+
84
+ ```
85
+ The implementation is complete and APPROVED.
86
+
87
+ Execute Phase 3 (Finalization):
88
+ 1. Read .claude/agents/finalization-agent.md
89
+ 2. Spawn finalization-agent with FULL instructions
90
+ 3. The agent will:
91
+ - Verify all acceptance criteria against original task
92
+ - Run local quality checks (typecheck, lint)
93
+ - Clean up temp files
94
+ - Commit with proper message
95
+ - Push to remote (triggers CI/CD)
96
+ - Wait for CI/CD to pass
97
+ 4. Report final status when complete
98
+
99
+ Branch: {branch-name}
100
+ Task file: {.tasks/epics/TASK-XXX/epic.md or original task}
101
+ ```
102
+
103
+ ---
104
+
105
+ ## Planning Phase Only
106
+
107
+ ### Deep Analysis
108
+
109
+ ```
110
+ Read .claude/agents/deep-analyst.md and spawn a deep-analyst to analyze:
111
+ {WHAT TO ANALYZE}
112
+
113
+ Focus on:
114
+ - What is the REAL problem we're solving?
115
+ - What are the dependencies?
116
+ - What could go wrong?
117
+
118
+ DO NOT create an implementation plan yet - just analysis.
119
+ Output to .claude/state/analysis-{topic}.md
120
+ ```
121
+
122
+ **Examples:**
123
+ ```
124
+ Read .claude/agents/deep-analyst.md and spawn a deep-analyst to analyze
125
+ our current authentication flow.
126
+
127
+ Trace:
128
+ 1. How users log in
129
+ 2. How tokens are validated
130
+ 3. How sessions are managed
131
+
132
+ DO NOT create an implementation plan yet - just analysis.
133
+ Output to .claude/state/auth-flow-analysis.md
134
+ ```
135
+
136
+ ### Plan Validation
137
+
138
+ ```
139
+ Read .claude/agents/plan-validator.md and spawn a plan-validator to
140
+ challenge the plan in .claude/state/{plan-file}.md
141
+
142
+ Your job is to FIND PROBLEMS, not approve the plan.
143
+ Look for:
144
+ - Vague steps ("handle edge cases")
145
+ - Missing error handling
146
+ - Untested assumptions
147
+ - Performance concerns
148
+
149
+ Output critique to .claude/state/plan-validation.md
150
+ ```
151
+
152
+ ### Test Design (TDD)
153
+
154
+ ```
155
+ Read .claude/agents/tdd-designer.md and spawn a tdd-designer to create
156
+ test designs for: {FEATURE DESCRIPTION}
157
+
158
+ Focus on:
159
+ - Real user workflows, not implementation details
160
+ - Concrete values (not "test with valid input")
161
+ - Tests that would FAIL if code is broken
162
+ - Edge cases and boundary conditions
163
+
164
+ Output to .claude/state/test-design-{feature}.md
165
+ ```
166
+
167
+ **Examples:**
168
+ ```
169
+ Read .claude/agents/tdd-designer.md and spawn a tdd-designer to create
170
+ test designs for the user registration flow.
171
+
172
+ Focus on:
173
+ - Valid registration with all fields
174
+ - Missing required fields (each field separately)
175
+ - Invalid email formats
176
+ - Password strength requirements
177
+ - Duplicate email handling
178
+
179
+ Use concrete values like:
180
+ - email: "test@example.com"
181
+ - password: "SecureP@ss123"
182
+
183
+ Output to .claude/state/test-design-registration.md
184
+ ```
185
+
186
+ ---
187
+
188
+ ## Implementation Phase Only
189
+
190
+ ### Direct Implementation (Skip Planning)
191
+
192
+ Use only for simple, well-defined tasks:
193
+
194
+ ```
195
+ Read .claude/agents/implementation-agent.md and spawn an implementation-agent to:
196
+ {SPECIFIC TASK}
197
+
198
+ Execute WITHOUT stopping to ask. Just implement and test.
199
+ Report back when DONE or truly BLOCKED.
200
+ ```
201
+
202
+ **Examples:**
203
+ ```
204
+ Read .claude/agents/implementation-agent.md and spawn an implementation-agent to:
205
+ Fix the typo in src/components/Header.tsx - change "Welcom" to "Welcome"
206
+
207
+ Execute WITHOUT stopping to ask. Report back when done.
208
+ ```
209
+
210
+ ```
211
+ Read .claude/agents/implementation-agent.md and spawn an implementation-agent to:
212
+ Add a loading spinner to the submit button in LoginForm.tsx
213
+
214
+ Requirements:
215
+ - Show spinner when form is submitting
216
+ - Disable button during submission
217
+ - Hide spinner when complete
218
+
219
+ Execute WITHOUT stopping to ask. Run tests after changes.
220
+ ```
221
+
222
+ ### Code Review
223
+
224
+ ```
225
+ Read .claude/agents/code-reviewer.md and spawn a code-reviewer to
226
+ review the changes in: {LOCATION}
227
+
228
+ Focus on:
229
+ - Does it match the approved plan?
230
+ - Are there bugs or edge cases missed?
231
+ - Is error handling complete?
232
+ - Are tests adequate?
233
+
234
+ Output review to .claude/state/code-review-{feature}.md
235
+ ```
236
+
237
+ **Examples:**
238
+ ```
239
+ Read .claude/agents/code-reviewer.md and spawn a code-reviewer to
240
+ review the changes in src/api/auth/
241
+
242
+ Focus on:
243
+ - Security vulnerabilities
244
+ - Error handling completeness
245
+ - Test coverage
246
+ - API contract compliance
247
+
248
+ Output review to .claude/state/code-review-auth-api.md
249
+ ```
250
+
251
+ ---
252
+
253
+ ## Finalization Phase
254
+
255
+ ### Cleanup Before Commit
256
+
257
+ ```
258
+ Read .claude/agents/cleanup-agent.md and spawn a cleanup-agent for task: {TASK}
259
+
260
+ Clean up:
261
+ - .claude/state/ (except archived)
262
+ - .agents/scratch/
263
+ - .agents/thoughts/
264
+ - Any temporary files
265
+
266
+ Preserve:
267
+ - .knowledge/ (all of it)
268
+ - .claude/plans/ (approved plans)
269
+ - Actual source code changes
270
+ ```
271
+
272
+ ### Full Finalization
273
+
274
+ ```
275
+ Read .claude/agents/finalization-agent.md and spawn a finalization-agent.
276
+
277
+ Task: {TASK DESCRIPTION}
278
+ Branch: {BRANCH NAME}
279
+
280
+ The agent will:
281
+ 1. Verify all acceptance criteria
282
+ 2. Run quality checks (typecheck, lint)
283
+ 3. Clean temporary files
284
+ 4. Commit with proper message
285
+ 5. Push to remote
286
+ 6. Wait for CI/CD
287
+ 7. Report final status
288
+ ```
289
+
290
+ ---
291
+
292
+ ## Task Management
293
+
294
+ ### Pick Up Next Task
295
+
296
+ ```
297
+ Read .claude/agents/task-orchestrator.md and spawn a task-orchestrator to:
298
+ Pick up the next task from .tasks/inbox/
299
+
300
+ The agent will:
301
+ 1. Scan inbox for available tasks
302
+ 2. Select highest priority task
303
+ 3. Move to .tasks/epics/
304
+ 4. Create branch
305
+ 5. Begin Phase 1 planning
306
+ ```
307
+
308
+ ### Create New Epic
309
+
310
+ ```
311
+ Read .claude/agents/task-orchestrator.md and spawn a task-orchestrator to:
312
+ Create an epic for: {FEATURE DESCRIPTION}
313
+
314
+ Include:
315
+ - Clear acceptance criteria
316
+ - Priority level
317
+ - Estimated complexity
318
+ - Dependencies (if any)
319
+
320
+ Save to .tasks/inbox/TASK-{XXX}/epic.md
321
+ ```
322
+
323
+ ---
324
+
325
+ ## Specialist Agents
326
+
327
+ After running `archai generate`, use your project-specific specialists:
328
+
329
+ ### Template: Invoke Any Specialist
330
+
331
+ ```
332
+ Read .claude/agents/{specialist-name}.md and spawn a {specialist-name} to:
333
+ {SPECIFIC TASK}
334
+
335
+ Context:
336
+ - {relevant context}
337
+
338
+ Output to .claude/state/{output-file}.md
339
+ ```
340
+
341
+ ### Common Specialist Prompts
342
+
343
+ ```
344
+ # Frontend work
345
+ Read .claude/agents/frontend-specialist.md and spawn a frontend-specialist to:
346
+ Create a reusable modal component with:
347
+ - Backdrop click to close
348
+ - ESC key to close
349
+ - Focus trap
350
+ - Smooth animations
351
+
352
+ Output to .claude/state/modal-component-design.md
353
+ ```
354
+
355
+ ```
356
+ # Backend work
357
+ Read .claude/agents/backend-specialist.md and spawn a backend-specialist to:
358
+ Add rate limiting to the API endpoints in src/api/
359
+
360
+ Requirements:
361
+ - 100 requests per minute per IP
362
+ - Return 429 with Retry-After header
363
+ - Whitelist internal services
364
+
365
+ Output to .claude/state/rate-limiting-design.md
366
+ ```
367
+
368
+ ```
369
+ # Database work
370
+ Read .claude/agents/database-specialist.md and spawn a database-specialist to:
371
+ Optimize the slow query in getUserOrders()
372
+
373
+ Current query takes 2+ seconds with 10k orders.
374
+ Target: under 100ms
375
+
376
+ Output to .claude/state/query-optimization.md
377
+ ```
378
+
379
+ ---
380
+
381
+ ## Quick Reference Card
382
+
383
+ | I want to... | Use this prompt... |
384
+ |--------------|-------------------|
385
+ | Prepare a task spec | `Use task-prep for: [description]` |
386
+ | Implement a feature | `Use maestro-agent for: X. Run Phase 1, wait for APPROVE.` |
387
+ | Analyze code first | `Read deep-analyst.md, spawn deep-analyst to analyze: X` |
388
+ | Design tests only | `Read tdd-designer.md, spawn tdd-designer to design tests for: X` |
389
+ | Get specialist help | `Read {name}-specialist.md, spawn {name}-specialist for: X` |
390
+ | Resume implementation | `The plan in .claude/plans/X.md has been APPROVED. Execute Phase 2 AUTONOMOUSLY.` |
391
+ | Finalize (commit/push) | `Implementation APPROVED. Execute Phase 3 with finalization-agent.` |
392
+ | Clean up before commit | `Read cleanup-agent.md, spawn cleanup-agent for task: X` |
393
+ | Approve a plan | `APPROVE` |
394
+ | Approve implementation | `APPROVE` (triggers Phase 3 finalization) |
395
+ | Request changes | `REVISE: [specific changes]` |
396
+ | Stop workflow | `REJECT: [reason]` |
397
+
398
+ ---
399
+
400
+ ## Step-by-Step Examples
401
+
402
+ ### Example 1: Implement a New Feature
403
+
404
+ **Task:** "Add user authentication with JWT"
405
+
406
+ **Step 1: Prepare the task spec (recommended)**
407
+ ```
408
+ Use task-prep for: add user authentication with JWT
409
+ ```
410
+
411
+ The agent will:
412
+ 1. Read project context and codebase structure
413
+ 2. Classify as Task or Epic
414
+ 3. Ask 1-2 targeted clarifying questions (scope, constraints)
415
+ 4. Write structured spec to `.claude/state/prepared-task.md`
416
+ 5. Present for your approval
417
+
418
+ ```
419
+ APPROVE
420
+ ```
421
+
422
+ **Step 2: Start the orchestrated workflow**
423
+ ```
424
+ Use maestro-agent for: the prepared task in .claude/state/prepared-task.md
425
+ ```
426
+
427
+ The agent will:
428
+ 1. Spawn `deep-analyst` → Creates analysis in `.claude/state/phase1_analysis.md`
429
+ 2. Spawn `plan-validator` → Challenges plan in `.claude/state/phase1_validation.md`
430
+ 3. Spawn `tdd-designer` → Designs tests in `.claude/state/phase1_test_design.md`
431
+ 4. Iterate 2-4 times until plan is solid
432
+ 5. Write final plan to `.claude/plans/jwt-auth.md`
433
+ 6. **STOP and present summary**
434
+
435
+ **Step 3: Review and approve**
436
+ ```
437
+ # Review the plan
438
+ Read .claude/plans/jwt-auth.md
439
+
440
+ # If satisfied:
441
+ APPROVE
442
+
443
+ # If changes needed:
444
+ REVISE: Add support for refresh token rotation, also consider session invalidation on password change
445
+ ```
446
+
447
+ **Step 4: Autonomous implementation**
448
+
449
+ After APPROVE, Phase 2 runs without stopping:
450
+ - Implements each step
451
+ - Runs tests after each step
452
+ - Fixes failures automatically
453
+ - Reports only when DONE or BLOCKED
454
+
455
+ ---
456
+
457
+ ### Example 2: Quick Bug Fix
458
+
459
+ **Task:** "Fix the broken date formatting in user profiles"
460
+
461
+ ```
462
+ Read .claude/agents/implementation-agent.md and spawn an implementation-agent to:
463
+ Fix the date formatting bug in src/components/UserProfile.tsx
464
+
465
+ The issue: Dates show as "Invalid Date" for users with null birthdates.
466
+
467
+ Fix: Add null check before formatting.
468
+ Test: Verify with null, valid date, and edge cases.
469
+
470
+ Execute WITHOUT stopping. Report when done.
471
+ ```
472
+
473
+ ---
474
+
475
+ ### Example 3: Analysis Without Implementation
476
+
477
+ **Task:** "Understand how the caching layer works before optimizing"
478
+
479
+ ```
480
+ Read .claude/agents/deep-analyst.md and spawn a deep-analyst to analyze
481
+ the caching implementation in src/services/cache/.
482
+
483
+ Trace:
484
+ 1. What gets cached and for how long
485
+ 2. Cache invalidation strategy
486
+ 3. Memory usage patterns
487
+ 4. Performance bottlenecks
488
+
489
+ DO NOT create an implementation plan - just analysis.
490
+ Output to .claude/state/cache-analysis.md
491
+ ```
492
+
493
+ ---
494
+
495
+ ## Tips for Best Results
496
+
497
+ 1. **Be specific** - More detail = better results
498
+ 2. **Include context** - Mention relevant files, constraints, or requirements
499
+ 3. **Start with maestro-agent** - For any non-trivial task
500
+ 4. **Use specialists** - They know your project's patterns
501
+ 5. **Let Phase 2 run** - Don't interrupt unless truly necessary
502
+ 6. **Review plans carefully** - Reject vague steps
503
+
504
+ ---
505
+
506
+ *Generated by archai. See README.md for full documentation.*