oh-my-codex 0.13.2 → 0.14.1

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 (406) hide show
  1. package/Cargo.lock +5 -5
  2. package/Cargo.toml +1 -1
  3. package/README.md +14 -8
  4. package/crates/omx-explore/src/main.rs +94 -1
  5. package/crates/omx-sparkshell/src/codex_bridge.rs +59 -12
  6. package/crates/omx-sparkshell/tests/execution.rs +48 -0
  7. package/dist/autoresearch/__tests__/skill-validation.test.d.ts +2 -0
  8. package/dist/autoresearch/__tests__/skill-validation.test.d.ts.map +1 -0
  9. package/dist/autoresearch/__tests__/skill-validation.test.js +91 -0
  10. package/dist/autoresearch/__tests__/skill-validation.test.js.map +1 -0
  11. package/dist/autoresearch/skill-validation.d.ts +13 -0
  12. package/dist/autoresearch/skill-validation.d.ts.map +1 -0
  13. package/dist/autoresearch/skill-validation.js +165 -0
  14. package/dist/autoresearch/skill-validation.js.map +1 -0
  15. package/dist/catalog/__tests__/schema.test.js +6 -0
  16. package/dist/catalog/__tests__/schema.test.js.map +1 -1
  17. package/dist/cli/__tests__/autoresearch-guided.test.js +236 -273
  18. package/dist/cli/__tests__/autoresearch-guided.test.js.map +1 -1
  19. package/dist/cli/__tests__/autoresearch.test.js +64 -653
  20. package/dist/cli/__tests__/autoresearch.test.js.map +1 -1
  21. package/dist/cli/__tests__/explore.test.js +33 -1
  22. package/dist/cli/__tests__/explore.test.js.map +1 -1
  23. package/dist/cli/__tests__/index.test.js +18 -2
  24. package/dist/cli/__tests__/index.test.js.map +1 -1
  25. package/dist/cli/__tests__/nested-help-routing.test.js +2 -1
  26. package/dist/cli/__tests__/nested-help-routing.test.js.map +1 -1
  27. package/dist/cli/__tests__/package-bin-contract.test.js +5 -0
  28. package/dist/cli/__tests__/package-bin-contract.test.js.map +1 -1
  29. package/dist/cli/__tests__/question.test.d.ts +2 -0
  30. package/dist/cli/__tests__/question.test.d.ts.map +1 -0
  31. package/dist/cli/__tests__/question.test.js +166 -0
  32. package/dist/cli/__tests__/question.test.js.map +1 -0
  33. package/dist/cli/__tests__/session-search-help.test.js +1 -1
  34. package/dist/cli/__tests__/session-search-help.test.js.map +1 -1
  35. package/dist/cli/__tests__/setup-agents-overwrite.test.js +32 -7
  36. package/dist/cli/__tests__/setup-agents-overwrite.test.js.map +1 -1
  37. package/dist/cli/__tests__/setup-refresh.test.js +8 -6
  38. package/dist/cli/__tests__/setup-refresh.test.js.map +1 -1
  39. package/dist/cli/__tests__/setup-skills-overwrite.test.js +2 -0
  40. package/dist/cli/__tests__/setup-skills-overwrite.test.js.map +1 -1
  41. package/dist/cli/__tests__/sparkshell-cli.test.js +23 -0
  42. package/dist/cli/__tests__/sparkshell-cli.test.js.map +1 -1
  43. package/dist/cli/__tests__/uninstall.test.js +65 -5
  44. package/dist/cli/__tests__/uninstall.test.js.map +1 -1
  45. package/dist/cli/__tests__/update.test.js +360 -26
  46. package/dist/cli/__tests__/update.test.js.map +1 -1
  47. package/dist/cli/autoresearch-guided.d.ts +24 -7
  48. package/dist/cli/autoresearch-guided.d.ts.map +1 -1
  49. package/dist/cli/autoresearch-guided.js +189 -130
  50. package/dist/cli/autoresearch-guided.js.map +1 -1
  51. package/dist/cli/autoresearch.d.ts +3 -2
  52. package/dist/cli/autoresearch.d.ts.map +1 -1
  53. package/dist/cli/autoresearch.js +29 -305
  54. package/dist/cli/autoresearch.js.map +1 -1
  55. package/dist/cli/doctor.d.ts.map +1 -1
  56. package/dist/cli/doctor.js +43 -0
  57. package/dist/cli/doctor.js.map +1 -1
  58. package/dist/cli/explore.d.ts.map +1 -1
  59. package/dist/cli/explore.js +18 -3
  60. package/dist/cli/explore.js.map +1 -1
  61. package/dist/cli/index.d.ts +2 -1
  62. package/dist/cli/index.d.ts.map +1 -1
  63. package/dist/cli/index.js +15 -3
  64. package/dist/cli/index.js.map +1 -1
  65. package/dist/cli/question.d.ts +3 -0
  66. package/dist/cli/question.d.ts.map +1 -0
  67. package/dist/cli/question.js +182 -0
  68. package/dist/cli/question.js.map +1 -0
  69. package/dist/cli/setup.d.ts.map +1 -1
  70. package/dist/cli/setup.js +25 -3
  71. package/dist/cli/setup.js.map +1 -1
  72. package/dist/cli/sparkshell.d.ts.map +1 -1
  73. package/dist/cli/sparkshell.js +11 -1
  74. package/dist/cli/sparkshell.js.map +1 -1
  75. package/dist/cli/team.d.ts.map +1 -1
  76. package/dist/cli/team.js +159 -394
  77. package/dist/cli/team.js.map +1 -1
  78. package/dist/cli/uninstall.d.ts.map +1 -1
  79. package/dist/cli/uninstall.js +3 -1
  80. package/dist/cli/uninstall.js.map +1 -1
  81. package/dist/cli/update.d.ts +37 -9
  82. package/dist/cli/update.d.ts.map +1 -1
  83. package/dist/cli/update.js +204 -26
  84. package/dist/cli/update.js.map +1 -1
  85. package/dist/config/__tests__/generator-idempotent.test.js +51 -14
  86. package/dist/config/__tests__/generator-idempotent.test.js.map +1 -1
  87. package/dist/config/__tests__/generator-notify.test.js +35 -10
  88. package/dist/config/__tests__/generator-notify.test.js.map +1 -1
  89. package/dist/config/generator.d.ts +1 -0
  90. package/dist/config/generator.d.ts.map +1 -1
  91. package/dist/config/generator.js +61 -7
  92. package/dist/config/generator.js.map +1 -1
  93. package/dist/hooks/__tests__/analyze-routing-contract.test.js +22 -13
  94. package/dist/hooks/__tests__/analyze-routing-contract.test.js.map +1 -1
  95. package/dist/hooks/__tests__/anti-slop-workflow.test.js +3 -3
  96. package/dist/hooks/__tests__/anti-slop-workflow.test.js.map +1 -1
  97. package/dist/hooks/__tests__/code-review-skill-contract.test.d.ts +2 -0
  98. package/dist/hooks/__tests__/code-review-skill-contract.test.d.ts.map +1 -0
  99. package/dist/hooks/__tests__/code-review-skill-contract.test.js +56 -0
  100. package/dist/hooks/__tests__/code-review-skill-contract.test.js.map +1 -0
  101. package/dist/hooks/__tests__/debugger-log-recency-contract.test.js +2 -2
  102. package/dist/hooks/__tests__/debugger-log-recency-contract.test.js.map +1 -1
  103. package/dist/hooks/__tests__/deep-interview-contract.test.js +51 -5
  104. package/dist/hooks/__tests__/deep-interview-contract.test.js.map +1 -1
  105. package/dist/hooks/__tests__/explicit-terminal-stop-docs-contract.test.d.ts +2 -0
  106. package/dist/hooks/__tests__/explicit-terminal-stop-docs-contract.test.d.ts.map +1 -0
  107. package/dist/hooks/__tests__/explicit-terminal-stop-docs-contract.test.js +43 -0
  108. package/dist/hooks/__tests__/explicit-terminal-stop-docs-contract.test.js.map +1 -0
  109. package/dist/hooks/__tests__/explicit-terminal-stop-model-docs-contract.test.d.ts +2 -0
  110. package/dist/hooks/__tests__/explicit-terminal-stop-model-docs-contract.test.d.ts.map +1 -0
  111. package/dist/hooks/__tests__/explicit-terminal-stop-model-docs-contract.test.js +38 -0
  112. package/dist/hooks/__tests__/explicit-terminal-stop-model-docs-contract.test.js.map +1 -0
  113. package/dist/hooks/__tests__/explore-sparkshell-guidance-contract.test.js +2 -2
  114. package/dist/hooks/__tests__/explore-sparkshell-guidance-contract.test.js.map +1 -1
  115. package/dist/hooks/__tests__/keyword-detector.test.js +308 -17
  116. package/dist/hooks/__tests__/keyword-detector.test.js.map +1 -1
  117. package/dist/hooks/__tests__/notify-fallback-watcher.test.js +570 -2
  118. package/dist/hooks/__tests__/notify-fallback-watcher.test.js.map +1 -1
  119. package/dist/hooks/__tests__/notify-hook-auto-nudge.test.js +717 -16
  120. package/dist/hooks/__tests__/notify-hook-auto-nudge.test.js.map +1 -1
  121. package/dist/hooks/__tests__/notify-hook-cross-worktree-heartbeat.test.js +25 -0
  122. package/dist/hooks/__tests__/notify-hook-cross-worktree-heartbeat.test.js.map +1 -1
  123. package/dist/hooks/__tests__/notify-hook-managed-tmux.test.js +894 -1
  124. package/dist/hooks/__tests__/notify-hook-managed-tmux.test.js.map +1 -1
  125. package/dist/hooks/__tests__/notify-hook-ralph-resume.test.js +34 -0
  126. package/dist/hooks/__tests__/notify-hook-ralph-resume.test.js.map +1 -1
  127. package/dist/hooks/__tests__/notify-hook-tmux-heal.test.js +132 -0
  128. package/dist/hooks/__tests__/notify-hook-tmux-heal.test.js.map +1 -1
  129. package/dist/hooks/__tests__/prompt-guidance-contract.test.js +22 -4
  130. package/dist/hooks/__tests__/prompt-guidance-contract.test.js.map +1 -1
  131. package/dist/hooks/__tests__/prompt-guidance-fragments.test.js +4 -2
  132. package/dist/hooks/__tests__/prompt-guidance-fragments.test.js.map +1 -1
  133. package/dist/hooks/__tests__/prompt-guidance-test-helpers.d.ts +1 -0
  134. package/dist/hooks/__tests__/prompt-guidance-test-helpers.d.ts.map +1 -1
  135. package/dist/hooks/__tests__/prompt-guidance-test-helpers.js +19 -1
  136. package/dist/hooks/__tests__/prompt-guidance-test-helpers.js.map +1 -1
  137. package/dist/hooks/__tests__/prompt-guidance-wave-two.test.js +28 -0
  138. package/dist/hooks/__tests__/prompt-guidance-wave-two.test.js.map +1 -1
  139. package/dist/hooks/__tests__/prompt-orchestration-boundary.test.js +5 -4
  140. package/dist/hooks/__tests__/prompt-orchestration-boundary.test.js.map +1 -1
  141. package/dist/hooks/__tests__/prompt-team-routing.test.js +2 -2
  142. package/dist/hooks/__tests__/prompt-team-routing.test.js.map +1 -1
  143. package/dist/hooks/__tests__/triage-config.test.d.ts +2 -0
  144. package/dist/hooks/__tests__/triage-config.test.d.ts.map +1 -0
  145. package/dist/hooks/__tests__/triage-config.test.js +211 -0
  146. package/dist/hooks/__tests__/triage-config.test.js.map +1 -0
  147. package/dist/hooks/__tests__/triage-heuristic.test.d.ts +2 -0
  148. package/dist/hooks/__tests__/triage-heuristic.test.d.ts.map +1 -0
  149. package/dist/hooks/__tests__/triage-heuristic.test.js +230 -0
  150. package/dist/hooks/__tests__/triage-heuristic.test.js.map +1 -0
  151. package/dist/hooks/__tests__/triage-state.test.d.ts +2 -0
  152. package/dist/hooks/__tests__/triage-state.test.d.ts.map +1 -0
  153. package/dist/hooks/__tests__/triage-state.test.js +426 -0
  154. package/dist/hooks/__tests__/triage-state.test.js.map +1 -0
  155. package/dist/hooks/keyword-detector.d.ts +26 -7
  156. package/dist/hooks/keyword-detector.d.ts.map +1 -1
  157. package/dist/hooks/keyword-detector.js +97 -26
  158. package/dist/hooks/keyword-detector.js.map +1 -1
  159. package/dist/hooks/keyword-registry.d.ts.map +1 -1
  160. package/dist/hooks/keyword-registry.js +16 -9
  161. package/dist/hooks/keyword-registry.js.map +1 -1
  162. package/dist/hooks/prompt-guidance-contract.d.ts.map +1 -1
  163. package/dist/hooks/prompt-guidance-contract.js +28 -1
  164. package/dist/hooks/prompt-guidance-contract.js.map +1 -1
  165. package/dist/hooks/triage-config.d.ts +33 -0
  166. package/dist/hooks/triage-config.d.ts.map +1 -0
  167. package/dist/hooks/triage-config.js +87 -0
  168. package/dist/hooks/triage-config.js.map +1 -0
  169. package/dist/hooks/triage-heuristic.d.ts +20 -0
  170. package/dist/hooks/triage-heuristic.d.ts.map +1 -0
  171. package/dist/hooks/triage-heuristic.js +210 -0
  172. package/dist/hooks/triage-heuristic.js.map +1 -0
  173. package/dist/hooks/triage-state.d.ts +63 -0
  174. package/dist/hooks/triage-state.d.ts.map +1 -0
  175. package/dist/hooks/triage-state.js +138 -0
  176. package/dist/hooks/triage-state.js.map +1 -0
  177. package/dist/hud/__tests__/reconcile.test.js +20 -0
  178. package/dist/hud/__tests__/reconcile.test.js.map +1 -1
  179. package/dist/hud/reconcile.d.ts +1 -0
  180. package/dist/hud/reconcile.d.ts.map +1 -1
  181. package/dist/hud/reconcile.js +2 -1
  182. package/dist/hud/reconcile.js.map +1 -1
  183. package/dist/mcp/__tests__/bootstrap.test.js +5 -24
  184. package/dist/mcp/__tests__/bootstrap.test.js.map +1 -1
  185. package/dist/mcp/__tests__/state-server.test.js +127 -0
  186. package/dist/mcp/__tests__/state-server.test.js.map +1 -1
  187. package/dist/mcp/bootstrap.d.ts +1 -1
  188. package/dist/mcp/bootstrap.d.ts.map +1 -1
  189. package/dist/mcp/bootstrap.js +3 -11
  190. package/dist/mcp/bootstrap.js.map +1 -1
  191. package/dist/mcp/state-server.d.ts +25 -0
  192. package/dist/mcp/state-server.d.ts.map +1 -1
  193. package/dist/mcp/state-server.js +41 -0
  194. package/dist/mcp/state-server.js.map +1 -1
  195. package/dist/modes/__tests__/base-ralph-contract.test.js +15 -0
  196. package/dist/modes/__tests__/base-ralph-contract.test.js.map +1 -1
  197. package/dist/modes/base.d.ts +1 -0
  198. package/dist/modes/base.d.ts.map +1 -1
  199. package/dist/modes/base.js +22 -6
  200. package/dist/modes/base.js.map +1 -1
  201. package/dist/notifications/__tests__/index.test.js +75 -0
  202. package/dist/notifications/__tests__/index.test.js.map +1 -1
  203. package/dist/notifications/__tests__/session-status.test.js +90 -0
  204. package/dist/notifications/__tests__/session-status.test.js.map +1 -1
  205. package/dist/notifications/index.d.ts.map +1 -1
  206. package/dist/notifications/index.js +39 -22
  207. package/dist/notifications/index.js.map +1 -1
  208. package/dist/notifications/session-status.d.ts +2 -0
  209. package/dist/notifications/session-status.d.ts.map +1 -1
  210. package/dist/notifications/session-status.js +19 -4
  211. package/dist/notifications/session-status.js.map +1 -1
  212. package/dist/openclaw/index.d.ts +5 -3
  213. package/dist/openclaw/index.d.ts.map +1 -1
  214. package/dist/openclaw/index.js +5 -3
  215. package/dist/openclaw/index.js.map +1 -1
  216. package/dist/question/__tests__/client.test.d.ts +2 -0
  217. package/dist/question/__tests__/client.test.d.ts.map +1 -0
  218. package/dist/question/__tests__/client.test.js +70 -0
  219. package/dist/question/__tests__/client.test.js.map +1 -0
  220. package/dist/question/__tests__/deep-interview.test.d.ts +2 -0
  221. package/dist/question/__tests__/deep-interview.test.d.ts.map +1 -0
  222. package/dist/question/__tests__/deep-interview.test.js +118 -0
  223. package/dist/question/__tests__/deep-interview.test.js.map +1 -0
  224. package/dist/question/__tests__/policy.test.d.ts +2 -0
  225. package/dist/question/__tests__/policy.test.d.ts.map +1 -0
  226. package/dist/question/__tests__/policy.test.js +107 -0
  227. package/dist/question/__tests__/policy.test.js.map +1 -0
  228. package/dist/question/__tests__/renderer.test.d.ts +2 -0
  229. package/dist/question/__tests__/renderer.test.d.ts.map +1 -0
  230. package/dist/question/__tests__/renderer.test.js +238 -0
  231. package/dist/question/__tests__/renderer.test.js.map +1 -0
  232. package/dist/question/__tests__/state.test.d.ts +2 -0
  233. package/dist/question/__tests__/state.test.d.ts.map +1 -0
  234. package/dist/question/__tests__/state.test.js +75 -0
  235. package/dist/question/__tests__/state.test.js.map +1 -0
  236. package/dist/question/__tests__/types.test.d.ts +2 -0
  237. package/dist/question/__tests__/types.test.d.ts.map +1 -0
  238. package/dist/question/__tests__/types.test.js +44 -0
  239. package/dist/question/__tests__/types.test.js.map +1 -0
  240. package/dist/question/__tests__/ui.test.d.ts +2 -0
  241. package/dist/question/__tests__/ui.test.d.ts.map +1 -0
  242. package/dist/question/__tests__/ui.test.js +169 -0
  243. package/dist/question/__tests__/ui.test.js.map +1 -0
  244. package/dist/question/client.d.ts +54 -0
  245. package/dist/question/client.d.ts.map +1 -0
  246. package/dist/question/client.js +77 -0
  247. package/dist/question/client.js.map +1 -0
  248. package/dist/question/deep-interview.d.ts +30 -0
  249. package/dist/question/deep-interview.d.ts.map +1 -0
  250. package/dist/question/deep-interview.js +118 -0
  251. package/dist/question/deep-interview.js.map +1 -0
  252. package/dist/question/policy.d.ts +18 -0
  253. package/dist/question/policy.d.ts.map +1 -0
  254. package/dist/question/policy.js +77 -0
  255. package/dist/question/policy.js.map +1 -0
  256. package/dist/question/renderer.d.ts +20 -0
  257. package/dist/question/renderer.d.ts.map +1 -0
  258. package/dist/question/renderer.js +190 -0
  259. package/dist/question/renderer.js.map +1 -0
  260. package/dist/question/state.d.ts +19 -0
  261. package/dist/question/state.d.ts.map +1 -0
  262. package/dist/question/state.js +108 -0
  263. package/dist/question/state.js.map +1 -0
  264. package/dist/question/types.d.ts +66 -0
  265. package/dist/question/types.d.ts.map +1 -0
  266. package/dist/question/types.js +82 -0
  267. package/dist/question/types.js.map +1 -0
  268. package/dist/question/ui.d.ts +38 -0
  269. package/dist/question/ui.d.ts.map +1 -0
  270. package/dist/question/ui.js +321 -0
  271. package/dist/question/ui.js.map +1 -0
  272. package/dist/ralph/contract.d.ts +1 -1
  273. package/dist/ralph/contract.d.ts.map +1 -1
  274. package/dist/ralph/contract.js +4 -1
  275. package/dist/ralph/contract.js.map +1 -1
  276. package/dist/ralplan/runtime.js +1 -1
  277. package/dist/ralplan/runtime.js.map +1 -1
  278. package/dist/runtime/__tests__/run-loop.test.d.ts +2 -0
  279. package/dist/runtime/__tests__/run-loop.test.d.ts.map +1 -0
  280. package/dist/runtime/__tests__/run-loop.test.js +35 -0
  281. package/dist/runtime/__tests__/run-loop.test.js.map +1 -0
  282. package/dist/runtime/__tests__/run-outcome.test.d.ts +2 -0
  283. package/dist/runtime/__tests__/run-outcome.test.d.ts.map +1 -0
  284. package/dist/runtime/__tests__/run-outcome.test.js +102 -0
  285. package/dist/runtime/__tests__/run-outcome.test.js.map +1 -0
  286. package/dist/runtime/__tests__/run-state.test.d.ts +2 -0
  287. package/dist/runtime/__tests__/run-state.test.d.ts.map +1 -0
  288. package/dist/runtime/__tests__/run-state.test.js +37 -0
  289. package/dist/runtime/__tests__/run-state.test.js.map +1 -0
  290. package/dist/runtime/run-loop.d.ts +45 -0
  291. package/dist/runtime/run-loop.d.ts.map +1 -0
  292. package/dist/runtime/run-loop.js +51 -0
  293. package/dist/runtime/run-loop.js.map +1 -0
  294. package/dist/runtime/run-outcome.d.ts +46 -0
  295. package/dist/runtime/run-outcome.d.ts.map +1 -0
  296. package/dist/runtime/run-outcome.js +285 -0
  297. package/dist/runtime/run-outcome.js.map +1 -0
  298. package/dist/runtime/run-state.d.ts +40 -0
  299. package/dist/runtime/run-state.d.ts.map +1 -0
  300. package/dist/runtime/run-state.js +120 -0
  301. package/dist/runtime/run-state.js.map +1 -0
  302. package/dist/runtime/terminal-lifecycle.d.ts +11 -0
  303. package/dist/runtime/terminal-lifecycle.d.ts.map +1 -0
  304. package/dist/runtime/terminal-lifecycle.js +52 -0
  305. package/dist/runtime/terminal-lifecycle.js.map +1 -0
  306. package/dist/scripts/__tests__/codex-native-hook.test.js +1459 -126
  307. package/dist/scripts/__tests__/codex-native-hook.test.js.map +1 -1
  308. package/dist/scripts/__tests__/postinstall.test.d.ts +2 -0
  309. package/dist/scripts/__tests__/postinstall.test.d.ts.map +1 -0
  310. package/dist/scripts/__tests__/postinstall.test.js +178 -0
  311. package/dist/scripts/__tests__/postinstall.test.js.map +1 -0
  312. package/dist/scripts/codex-native-hook.d.ts +3 -0
  313. package/dist/scripts/codex-native-hook.d.ts.map +1 -1
  314. package/dist/scripts/codex-native-hook.js +308 -61
  315. package/dist/scripts/codex-native-hook.js.map +1 -1
  316. package/dist/scripts/notify-fallback-watcher.js +81 -2
  317. package/dist/scripts/notify-fallback-watcher.js.map +1 -1
  318. package/dist/scripts/notify-hook/auto-nudge.d.ts +27 -0
  319. package/dist/scripts/notify-hook/auto-nudge.d.ts.map +1 -1
  320. package/dist/scripts/notify-hook/auto-nudge.js +83 -20
  321. package/dist/scripts/notify-hook/auto-nudge.js.map +1 -1
  322. package/dist/scripts/notify-hook/managed-tmux.d.ts.map +1 -1
  323. package/dist/scripts/notify-hook/managed-tmux.js +64 -38
  324. package/dist/scripts/notify-hook/managed-tmux.js.map +1 -1
  325. package/dist/scripts/notify-hook/ralph-session-resume.js +1 -1
  326. package/dist/scripts/notify-hook/ralph-session-resume.js.map +1 -1
  327. package/dist/scripts/notify-hook.js +15 -5
  328. package/dist/scripts/notify-hook.js.map +1 -1
  329. package/dist/scripts/postinstall.d.ts +22 -0
  330. package/dist/scripts/postinstall.d.ts.map +1 -0
  331. package/dist/scripts/postinstall.js +105 -0
  332. package/dist/scripts/postinstall.js.map +1 -0
  333. package/dist/scripts/sync-prompt-guidance-fragments.js +5 -0
  334. package/dist/scripts/sync-prompt-guidance-fragments.js.map +1 -1
  335. package/dist/state/__tests__/operations-ralph-phase.test.js +21 -0
  336. package/dist/state/__tests__/operations-ralph-phase.test.js.map +1 -1
  337. package/dist/state/__tests__/operations.test.js +18 -0
  338. package/dist/state/__tests__/operations.test.js.map +1 -1
  339. package/dist/state/__tests__/workflow-transition.test.js +11 -0
  340. package/dist/state/__tests__/workflow-transition.test.js.map +1 -1
  341. package/dist/state/operations.d.ts.map +1 -1
  342. package/dist/state/operations.js +15 -0
  343. package/dist/state/operations.js.map +1 -1
  344. package/dist/state/workflow-transition-reconcile.d.ts.map +1 -1
  345. package/dist/state/workflow-transition-reconcile.js +14 -1
  346. package/dist/state/workflow-transition-reconcile.js.map +1 -1
  347. package/dist/state/workflow-transition.d.ts.map +1 -1
  348. package/dist/state/workflow-transition.js +3 -1
  349. package/dist/state/workflow-transition.js.map +1 -1
  350. package/dist/team/__tests__/followup-planner.test.js +15 -0
  351. package/dist/team/__tests__/followup-planner.test.js.map +1 -1
  352. package/dist/team/__tests__/role-router.test.js +47 -0
  353. package/dist/team/__tests__/role-router.test.js.map +1 -1
  354. package/dist/team/__tests__/runtime.test.js +108 -2
  355. package/dist/team/__tests__/runtime.test.js.map +1 -1
  356. package/dist/team/followup-planner.d.ts.map +1 -1
  357. package/dist/team/followup-planner.js +31 -9
  358. package/dist/team/followup-planner.js.map +1 -1
  359. package/dist/team/role-router.d.ts.map +1 -1
  360. package/dist/team/role-router.js +73 -0
  361. package/dist/team/role-router.js.map +1 -1
  362. package/dist/team/runtime.d.ts.map +1 -1
  363. package/dist/team/runtime.js +18 -4
  364. package/dist/team/runtime.js.map +1 -1
  365. package/dist/utils/__tests__/dep-versions.test.js +25 -8
  366. package/dist/utils/__tests__/dep-versions.test.js.map +1 -1
  367. package/dist/utils/__tests__/paths.test.js +45 -0
  368. package/dist/utils/__tests__/paths.test.js.map +1 -1
  369. package/dist/utils/paths.d.ts +2 -0
  370. package/dist/utils/paths.d.ts.map +1 -1
  371. package/dist/utils/paths.js +22 -7
  372. package/dist/utils/paths.js.map +1 -1
  373. package/dist/verification/__tests__/ci-rust-gates.test.js +1 -1
  374. package/dist/verification/__tests__/ci-rust-gates.test.js.map +1 -1
  375. package/package.json +4 -2
  376. package/prompts/architect.md +4 -0
  377. package/prompts/code-reviewer.md +3 -0
  378. package/prompts/dependency-expert.md +3 -0
  379. package/prompts/executor.md +5 -0
  380. package/prompts/explore.md +2 -0
  381. package/prompts/planner.md +5 -0
  382. package/prompts/product-analyst.md +8 -8
  383. package/prompts/researcher.md +78 -30
  384. package/prompts/verifier.md +4 -0
  385. package/skills/autoresearch/SKILL.md +68 -0
  386. package/skills/code-review/SKILL.md +94 -28
  387. package/skills/deep-interview/SKILL.md +100 -9
  388. package/skills/help/SKILL.md +3 -1
  389. package/skills/ralplan/SKILL.md +1 -0
  390. package/skills/team/SKILL.md +1 -0
  391. package/skills/ultrawork/SKILL.md +1 -0
  392. package/src/scripts/__tests__/codex-native-hook.test.ts +2373 -692
  393. package/src/scripts/__tests__/postinstall.test.ts +210 -0
  394. package/src/scripts/codex-native-hook.ts +365 -66
  395. package/src/scripts/notify-fallback-watcher.ts +92 -2
  396. package/src/scripts/notify-hook/auto-nudge.ts +89 -20
  397. package/src/scripts/notify-hook/managed-tmux.ts +70 -31
  398. package/src/scripts/notify-hook/ralph-session-resume.ts +1 -1
  399. package/src/scripts/notify-hook.ts +23 -5
  400. package/src/scripts/postinstall-bootstrap.js +23 -0
  401. package/src/scripts/postinstall.ts +161 -0
  402. package/src/scripts/sync-prompt-guidance-fragments.ts +4 -0
  403. package/templates/AGENTS.md +48 -37
  404. package/templates/catalog-manifest.json +7 -0
  405. package/templates/model-instructions/explore-lightweight-AGENTS.md +11 -0
  406. package/templates/model-instructions/sparkshell-lightweight-AGENTS.md +10 -0
@@ -3,48 +3,74 @@ description: "External Documentation & Reference Researcher"
3
3
  argument-hint: "task description"
4
4
  ---
5
5
  <identity>
6
- You are Researcher (Librarian). Find reliable external answers fast, prefer official sources, and cite every important claim.
6
+ You are Researcher (Librarian). Run a structured docs-first technical research workflow: identify the authoritative documentation set, establish version context, gather the smallest reliable evidence set, and return a reusable answer with citations.
7
+
8
+ You are responsible for external technical documentation research, API/reference lookup, version-aware evidence gathering, and source-backed clarification of external behavior.
9
+ You own external truth for an already chosen technology: what it does, how it works, which versions support it, and what the authoritative docs or release notes say. You are not the default dependency-comparison role.
10
+ You are not responsible for internal codebase analysis, implementation, or architecture decisions. If those become necessary, report that dependency upward to the leader.
7
11
  </identity>
8
12
 
9
13
  <constraints>
10
14
  <scope_guard>
11
15
  - Search external sources only.
12
- - Always include source URLs.
13
- - Prefer official documentation over third-party summaries.
14
- - Flag stale or version-mismatched information.
16
+ - Always include source URLs for important claims.
17
+ - Prefer official documentation, release notes, changelogs, and upstream source material over third-party summaries.
18
+ - Flag stale, undocumented, or version-mismatched information.
19
+ - Distinguish docs evidence from source-reference evidence; do not silently mix them.
20
+ - For technical questions, do docs-first discovery before chasing examples or blog posts.
21
+ - If the task becomes “whether / which dependency should we adopt, upgrade, replace, or migrate?”, report that boundary crossing upward for `dependency-expert` instead of doing candidate evaluation yourself.
22
+ - If the task needs current repo usage, call sites, or migration-surface mapping, report that dependency upward for `explore`.
15
23
  </scope_guard>
16
24
 
17
25
  <ask_gate>
18
26
  - Default to quality-first, information-dense research summaries with source URLs; add as much detail as needed for a strong answer without padding.
19
27
  - Treat newer user task updates as local overrides for the active research thread while preserving earlier non-conflicting research goals.
20
- - If correctness depends on more validation or version checks, keep researching until the answer is grounded.
28
+ - If correctness depends on more validation, version checks, documentation reads, or source-reference review, keep researching until the answer is grounded.
21
29
  </ask_gate>
22
30
  </constraints>
23
31
 
32
+ <request_classification>
33
+ Before searching, classify the request and let that classification drive the search plan:
34
+ - Conceptual docs question -- explain concepts, guarantees, lifecycle, configuration model, or official guidance.
35
+ - Implementation reference lookup -- find concrete APIs, options, signatures, examples, limits, or migration steps.
36
+ - Context/history lookup -- find release notes, changelog entries, deprecations, or when/why behavior changed.
37
+ - Comprehensive research -- combine conceptual docs, implementation reference, and context/history into one grounded answer.
38
+ </request_classification>
39
+
24
40
  <execution_loop>
25
- 1. Clarify the exact question.
26
- 2. Search official docs first.
27
- 3. Cross-check with supporting sources when needed.
28
- 4. Synthesize the answer with version notes and source URLs.
41
+ 1. Clarify the exact technical question and classify it.
42
+ 2. Identify the official documentation set or authoritative upstream source for the technology in question.
43
+ 3. Check the relevant version, release channel, or dated documentation context before relying on page details.
44
+ 4. Discover the documentation structure before page-level fetches: landing page, reference section, guides, migration notes, release notes, or API index.
45
+ 5. Fetch the minimum set of targeted pages needed to answer the question.
46
+ 6. Pull supporting examples only after the docs baseline is grounded.
47
+ 7. If the docs answer the question, stop at docs.
48
+ 8. If the docs are incomplete and behavior proof is required, explicitly escalate to source-reference evidence such as upstream source, changelog, release notes, or issue discussion, and label that evidence separately.
49
+ 9. Synthesize the answer with direct guidance, version notes, caveats, and source URLs.
29
50
 
30
51
  <success_criteria>
31
- - Every answer includes source URLs.
52
+ - The request type is explicit and the search path matches it.
32
53
  - Official docs are primary when available.
33
- - Version compatibility is noted when relevant.
34
- - The caller can act without extra lookups.
54
+ - Version compatibility or version uncertainty is noted when relevant.
55
+ - Documentation-structure discovery happens before deep page fetches.
56
+ - Examples appear only after the docs baseline is grounded.
57
+ - Docs evidence and source-reference evidence are clearly separated.
58
+ - The caller can reuse the answer without extra lookup.
35
59
  </success_criteria>
36
60
 
37
61
  <verification_loop>
38
62
  - Match effort to question complexity.
39
- - Stop when the answer is grounded in cited sources.
40
- - Keep validating if the current evidence is thin or conflicting.
63
+ - Stop when the answer is grounded in cited, version-aware evidence.
64
+ - Keep validating if the current evidence is thin, conflicting, stale, or example-led without docs grounding.
65
+ - Never stop at a plausible example when the official docs or version context still need confirmation.
66
+ - When source-reference evidence is required, say why the docs were insufficient.
41
67
  </verification_loop>
42
68
  </execution_loop>
43
69
 
44
70
  <tools>
45
- - Use WebSearch to find official references.
46
- - Use WebFetch to extract details.
47
- - Use Read only when local context helps formulate better searches.
71
+ - Use WebSearch to identify the official docs entry point, versioned documentation, release notes, and authoritative upstream references.
72
+ - Use WebFetch to inspect docs structure, targeted reference pages, migration notes, changelog entries, and upstream source references when needed.
73
+ - Use Read only when local context helps formulate better external searches.
48
74
  </tools>
49
75
 
50
76
  <style>
@@ -53,30 +79,52 @@ Default final-output shape: quality-first and evidence-dense; add as much detail
53
79
 
54
80
  ## Research: [Query]
55
81
 
56
- ### Findings
57
- **Answer**: [Direct answer]
58
- **Source**: [URL]
59
- **Version**: [applicable version]
82
+ ### Request Type
83
+ [Conceptual docs question | Implementation reference lookup | Context/history lookup | Comprehensive research]
84
+
85
+ ### Direct Answer
86
+ [Direct answer the caller can act on]
87
+
88
+ ### Official Docs Evidence
89
+ - [Title](URL) - [what it establishes]
90
+ - [Title](URL) - [what it establishes]
91
+
92
+ ### Version Note
93
+ - [Relevant version / release channel / dated-doc context]
94
+ - [Mismatch, uncertainty, or compatibility caveat if any]
60
95
 
61
- ### Additional Sources
62
- - [Title](URL) - [brief description]
96
+ ### Supporting Examples (only if needed)
97
+ - [Title](URL) - [why this example helps after docs grounding]
63
98
 
64
- ### Version Notes
65
- [Compatibility information if relevant]
99
+ ### Source-Reference Evidence (only if needed)
100
+ - [Title](URL) - [what docs did not prove and what this source adds]
101
+
102
+ ### Caveats / Ambiguity Flags
103
+ - [Any unresolved ambiguity, undocumented behavior, or likely version drift]
104
+
105
+ ### Reusable Takeaway
106
+ - [Short takeaway the leader can reuse directly]
66
107
  </output_contract>
67
108
 
68
109
  <scenario_handling>
69
- **Good:** The user says `continue` after one promising source. Keep validating against official docs and version details before finalizing.
110
+ **Good:** The user asks how a framework feature works. Classify it as a conceptual docs question, identify the official docs, confirm the relevant version, inspect the docs structure, then answer from the guide/reference pages before adding examples.
111
+
112
+ **Good:** The user asks for the exact parameters of an SDK method. Classify it as an implementation reference lookup, find the versioned API reference first, then add supporting examples only after the reference page is grounded.
113
+
114
+ **Good:** The user says `continue` after one promising source. Keep validating against official docs, version details, and source-reference evidence when needed before finalizing.
70
115
 
71
116
  **Good:** The user changes only the output format. Preserve the research goal and source requirements while adjusting the report locally.
72
117
 
73
- **Bad:** The user says `continue`, and you stop at a single unverified source.
118
+ **Bad:** The user says `continue`, and you stop at a single unverified source or a blog example without first grounding the answer in official docs.
74
119
  </scenario_handling>
75
120
 
76
121
  <final_checklist>
77
- - Does every answer include a source URL?
78
- - Did I prefer official docs?
79
- - Did I note version compatibility?
122
+ - Did I classify the request before searching?
123
+ - Did I identify the official docs and check the relevant version?
124
+ - Did I inspect docs structure before drilling into page-level fetches?
125
+ - Did I keep examples secondary to the docs baseline?
126
+ - Did I separate docs evidence from source-reference evidence?
127
+ - Did I include caveats or ambiguity flags when certainty is limited?
80
128
  - Can the caller act without further lookup?
81
129
  </final_checklist>
82
130
  </style>
@@ -17,6 +17,10 @@ You are Verifier. Your job is to prove or disprove completion with concrete evid
17
17
  <ask_gate>
18
18
  <!-- OMX:GUIDANCE:VERIFIER:CONSTRAINTS:START -->
19
19
  - Default reports to quality-first, evidence-dense summaries; think one more step before declaring PASS/FAIL/INCOMPLETE, but never omit the proof needed to justify the verdict.
20
+ - AUTO-CONTINUE for clear, already-requested, low-risk, reversible, local inspect-test-verify work; keep inspecting, testing, and verifying without permission handoff.
21
+ - ASK only for destructive, irreversible, credential-gated, external-production, or materially scope-changing actions, or when missing authority blocks progress.
22
+ - On AUTO-CONTINUE branches, do not use permission-handoff phrasing; state the next verification action or evidence-backed verdict.
23
+ - Keep gathering evidence until the verdict is grounded or blocked by a missing acceptance target or unavailable proof source.
20
24
  - If correctness depends on additional tests, diagnostics, or inspection, keep using those tools until the verdict is grounded.
21
25
  - More verification effort does not mean unrelated tool churn; gather the proof that matters, not every possible artifact.
22
26
  <!-- OMX:GUIDANCE:VERIFIER:CONSTRAINTS:END -->
@@ -0,0 +1,68 @@
1
+ ---
2
+ name: autoresearch
3
+ description: Stateful validator-gated research loop with native-hook persistence
4
+ ---
5
+
6
+ # Autoresearch
7
+
8
+ Autoresearch is the skill-first replacement for the deprecated `omx autoresearch` command.
9
+ It keeps the useful measured-research loop, but it now runs as a native-hook stateful workflow instead of a direct CLI or tmux launch surface.
10
+
11
+ ## Use when
12
+ - You want a Ralph-ish persistent research loop
13
+ - The task should keep nudging until explicit validation evidence exists
14
+ - You want init-time choice between script validation and prompt+architect validation
15
+
16
+ ## Do not use when
17
+ - You want the old `omx autoresearch` command surface (hard-deprecated)
18
+ - You want detached tmux or split-pane launch parity
19
+ - You have not decided the validation regime yet
20
+
21
+ ## Core contract
22
+ 1. **Init chooses validation mode.** Pick exactly one:
23
+ - `mission-validator-script`
24
+ - `prompt-architect-artifact`
25
+ 2. **Persist mode state** in `.omx/state/.../autoresearch-state.json` including:
26
+ - `validation_mode`
27
+ - `completion_artifact_path`
28
+ - `mission_validator_command` **or** `validator_prompt`
29
+ - optional `output_artifact_path`
30
+ 3. **Completion is artifact-gated.** The loop does not stop because the model says “done”, because a stop hook fired once, or because several turns were no-ops.
31
+ 4. **Direct CLI launch is gone.** Use `$deep-interview --autoresearch` for intake and `$autoresearch` for execution.
32
+
33
+ ## Completion artifact contract
34
+
35
+ ### `mission-validator-script`
36
+ The completion artifact must exist and record a passing validator result, for example:
37
+
38
+ ```json
39
+ {
40
+ "status": "passed",
41
+ "passed": true,
42
+ "summary": "metric improved beyond baseline"
43
+ }
44
+ ```
45
+
46
+ ### `prompt-architect-artifact`
47
+ The completion artifact must include both an architect approval verdict and an output artifact path, for example:
48
+
49
+ ```json
50
+ {
51
+ "validator_prompt": "Review the research output against the mission.",
52
+ "architect_review": { "verdict": "approved" },
53
+ "output_artifact_path": ".omx/specs/autoresearch-demo/report.md"
54
+ }
55
+ ```
56
+
57
+ ## Recommended flow
58
+ 1. Run `$deep-interview --autoresearch` to clarify mission + evaluator.
59
+ 2. Materialize `.omx/specs/autoresearch-{slug}/mission.md`, `sandbox.md`, and `result.json`.
60
+ 3. Start `$autoresearch` with the chosen validation mode stored in mode state.
61
+ 4. Let stop-hook / auto-nudge continue until the completion artifact satisfies the chosen validation mode.
62
+ 5. Finish only after the validator artifact is complete.
63
+
64
+ ## Migration note
65
+ - `omx autoresearch` is hard-deprecated.
66
+ - No direct CLI launch.
67
+ - No tmux split-pane launch.
68
+ - No noop-count completion gate.
@@ -15,8 +15,6 @@ This skill activates when:
15
15
  - After implementing a major feature
16
16
  - User wants quality assessment
17
17
 
18
- ## What It Does
19
-
20
18
  ## GPT-5.4 Guidance Alignment
21
19
 
22
20
  - Default to concise, evidence-dense progress and completion reporting unless the user or risk level requires more detail.
@@ -24,30 +22,49 @@ This skill activates when:
24
22
  - If correctness depends on additional inspection, retrieval, execution, or verification, keep using the relevant tools until the review is grounded.
25
23
  - Continue through clear, low-risk, reversible next steps automatically; ask only when the next step is materially branching, destructive, or preference-dependent.
26
24
 
27
- Delegates to the `code-reviewer` agent (THOROUGH tier) for deep analysis:
25
+ Delegates to the `code-reviewer` and `architect` agents in parallel for a two-lane review:
28
26
 
29
27
  1. **Identify Changes**
30
28
  - Run `git diff` to find changed files
31
29
  - Determine scope of review (specific files or entire PR)
32
30
 
33
- 2. **Review Categories**
31
+ 2. **Launch Parallel Review Lanes**
32
+ - **`code-reviewer` lane** - owns spec compliance, security, code quality, performance, and maintainability findings
33
+ - **`architect` lane** - owns the devil's-advocate / design-tradeoff perspective
34
+ - Both lanes run in parallel and produce distinct outputs before final synthesis
35
+
36
+ 3. **Review Categories**
34
37
  - **Security** - Hardcoded secrets, injection risks, XSS, CSRF
35
38
  - **Code Quality** - Function size, complexity, nesting depth
36
39
  - **Performance** - Algorithm efficiency, N+1 queries, caching
37
40
  - **Best Practices** - Naming, documentation, error handling
38
41
  - **Maintainability** - Duplication, coupling, testability
39
42
 
40
- 3. **Severity Rating**
43
+ 4. **Severity Rating**
41
44
  - **CRITICAL** - Security vulnerability (must fix before merge)
42
45
  - **HIGH** - Bug or major code smell (should fix before merge)
43
46
  - **MEDIUM** - Minor issue (fix when possible)
44
47
  - **LOW** - Style/suggestion (consider fixing)
45
48
 
46
- 4. **Specific Recommendations**
49
+ 5. **Architectural Status Contract**
50
+ - **CLEAR** - No unresolved architectural blocker was found
51
+ - **WATCH** - Non-blocking design/tradeoff concern that must appear in the final synthesis
52
+ - **BLOCK** - Unresolved design concern that prevents a merge-ready verdict
53
+
54
+ 6. **Specific Recommendations**
47
55
  - File:line locations for each issue
48
56
  - Concrete fix suggestions
49
57
  - Code examples where applicable
50
58
 
59
+ 7. **Final Synthesis**
60
+ - Combine the `code-reviewer` recommendation and the architect status into one final verdict
61
+ - Deterministic merge gating rules:
62
+ - If architect status is **BLOCK**, final recommendation is **REQUEST CHANGES**
63
+ - Else if `code-reviewer` recommendation is **REQUEST CHANGES**, final recommendation is **REQUEST CHANGES**
64
+ - Else if architect status is **WATCH**, final recommendation is **COMMENT**
65
+ - Else final recommendation follows the `code-reviewer` lane
66
+ - The final report must make architect blockers impossible to miss
67
+
51
68
  ## Agent Delegation
52
69
 
53
70
  ```
@@ -58,6 +75,8 @@ delegate(
58
75
 
59
76
  Review code changes for quality, security, and maintainability.
60
77
 
78
+ This is the code/spec/security lane. Do not absorb architectural ownership.
79
+
61
80
  Scope: [git diff or specific files]
62
81
 
63
82
  Review Checklist:
@@ -74,6 +93,29 @@ Output: Code review report with:
74
93
  - Fix recommendations
75
94
  - Approval recommendation (APPROVE / REQUEST CHANGES / COMMENT)"
76
95
  )
96
+
97
+ delegate(
98
+ role="architect",
99
+ tier="THOROUGH",
100
+ prompt="ARCHITECTURE / DEVIL'S-ADVOCATE REVIEW TASK
101
+
102
+ Review the same code changes from the architecture/tradeoff perspective.
103
+
104
+ Scope: [git diff or specific files]
105
+
106
+ Focus:
107
+ - System boundaries and interfaces
108
+ - Hidden coupling or long-term maintainability risks
109
+ - Tradeoff tension the main reviewer might miss
110
+ - Strongest counterargument against approving as-is
111
+
112
+ Output:
113
+ - Architectural Status: CLEAR / WATCH / BLOCK
114
+ - File:line evidence for each concern
115
+ - Concrete tradeoff or design recommendation"
116
+ )
117
+
118
+ Run both lanes in parallel, then synthesize them with the deterministic rules above.
77
119
  ```
78
120
 
79
121
  ## External Model Consultation (Preferred)
@@ -112,45 +154,59 @@ CODE REVIEW REPORT
112
154
  ==================
113
155
 
114
156
  Files Reviewed: 8
115
- Total Issues: 15
157
+ Total Issues: 12
158
+ Architectural Status: WATCH
116
159
 
117
160
  CRITICAL (0)
118
161
  -----------
119
162
  (none)
120
163
 
121
- HIGH (3)
164
+ HIGH (0)
122
165
  --------
166
+ (none)
167
+
168
+ MEDIUM (7)
169
+ ----------
123
170
  1. src/api/auth.ts:42
124
- Issue: User input not sanitized before SQL query
125
- Risk: SQL injection vulnerability
126
- Fix: Use parameterized queries or ORM
171
+ Issue: Email normalization logic is duplicated instead of reusing the shared helper
172
+ Risk: Validation rules can drift between authentication paths
173
+ Fix: Route both paths through the shared normalization helper
127
174
 
128
175
  2. src/components/UserProfile.tsx:89
129
- Issue: Password displayed in plain text in logs
130
- Risk: Credential exposure
131
- Fix: Remove password from log statements
176
+ Issue: Derived permissions are recalculated on every render
177
+ Risk: Avoidable work during profile refreshes
178
+ Fix: Memoize the derived permissions list or compute it upstream
132
179
 
133
180
  3. src/utils/validation.ts:15
134
- Issue: Email regex allows invalid formats
135
- Risk: Accepts malformed emails
136
- Fix: Use proven email validation library
137
-
138
- MEDIUM (7)
139
- ----------
140
- ...
181
+ Issue: Form-layer and server-layer validation messages are defined separately
182
+ Risk: User-facing validation guidance can become inconsistent
183
+ Fix: Share one validation message helper across both call sites
141
184
 
142
185
  LOW (5)
143
186
  -------
144
187
  ...
145
188
 
146
- RECOMMENDATION: REQUEST CHANGES
189
+ ARCHITECTURE WATCHLIST
190
+ ----------------------
191
+ - src/review/orchestrator.ts:88
192
+ Concern: Review result synthesis relies on implicit ordering rather than an explicit blocker contract
193
+ Status: WATCH
194
+ Recommendation: Define deterministic merge gating before expanding reviewers
195
+
196
+ SYNTHESIS
197
+ ---------
198
+ - code-reviewer recommendation: COMMENT
199
+ - architect status: WATCH
200
+ - final recommendation: COMMENT
201
+
202
+ RECOMMENDATION: COMMENT
147
203
 
148
- Critical security issues must be addressed before merge.
204
+ Address any WATCH concerns before treating the change as merge-ready.
149
205
  ```
150
206
 
151
207
  ## Review Checklist
152
208
 
153
- The code-reviewer agent checks:
209
+ The `code-reviewer` lane checks:
154
210
 
155
211
  ### Security
156
212
  - [ ] No hardcoded secrets (API keys, passwords, tokens)
@@ -180,11 +236,21 @@ The code-reviewer agent checks:
180
236
  - [ ] Tests for critical paths
181
237
  - [ ] No commented-out code
182
238
 
239
+ ## Architect Lane Checklist
240
+
241
+ The `architect` lane checks:
242
+
243
+ - [ ] Boundary or interface changes are explicit
244
+ - [ ] New coupling/tradeoff risks are surfaced
245
+ - [ ] Long-horizon maintainability concerns are evidence-backed
246
+ - [ ] Architectural status is one of `CLEAR`, `WATCH`, or `BLOCK`
247
+ - [ ] Any `BLOCK` concern cites the reason merge-ready status should be withheld
248
+
183
249
  ## Approval Criteria
184
250
 
185
- **APPROVE** - No CRITICAL or HIGH issues, minor improvements only
186
- **REQUEST CHANGES** - CRITICAL or HIGH issues present
187
- **COMMENT** - Only LOW/MEDIUM issues, no blocking concerns
251
+ **APPROVE** - `code-reviewer` returns APPROVE and architect status is `CLEAR`
252
+ **REQUEST CHANGES** - `code-reviewer` returns REQUEST CHANGES or architect status is `BLOCK`
253
+ **COMMENT** - `code-reviewer` returns COMMENT with architect status `CLEAR`, architect status is `WATCH`, or only LOW/MEDIUM improvements remain
188
254
 
189
255
 
190
256
  ## Scenario Examples
@@ -207,7 +273,7 @@ Includes coordinated review execution across specialized agents.
207
273
  ```
208
274
  /ralph code-review then fix all issues
209
275
  ```
210
- Review code, get feedback, fix until approved.
276
+ On the explicit Ralph path, review findings should flow into automatic fix follow-up without another permission prompt. Plain `code-review` itself remains read-only and does **not** promise auto-fix.
211
277
 
212
278
  **With Ultrawork:**
213
279
  ```
@@ -30,12 +30,12 @@ Execution quality is usually bottlenecked by intent clarity, not just missing im
30
30
  - **Quick (`--quick`)**: fast pre-PRD pass; target threshold `<= 0.30`; max rounds 5
31
31
  - **Standard (`--standard`, default)**: full requirement interview; target threshold `<= 0.20`; max rounds 12
32
32
  - **Deep (`--deep`)**: high-rigor exploration; target threshold `<= 0.15`; max rounds 20
33
- - **Autoresearch (`--autoresearch`)**: same interview rigor as Standard, but specialized for `omx autoresearch` launch readiness and `.omx/specs/` mission/sandbox artifact handoff
33
+ - **Autoresearch (`--autoresearch`)**: same interview rigor as Standard, but specialized for `$autoresearch` mission readiness and `.omx/specs/` artifact handoff
34
34
 
35
35
  If no flag is provided, use **Standard**.
36
36
 
37
37
  <Mode_Flags>
38
- - **`--autoresearch`**: switch the interview into autoresearch-intake mode for `omx autoresearch` handoff. In this mode, the interview should converge on a launch-ready research mission, write canonical artifacts under `.omx/specs/`, and preserve the explicit `refine further` vs `launch` boundary for downstream CLI intake.
38
+ - **`--autoresearch`**: switch the interview into autoresearch-intake mode for `$autoresearch` handoff. In this mode, the interview should converge on a validator-ready research mission, write canonical artifacts under `.omx/specs/`, and preserve the explicit `refine further` vs `launch` boundary for downstream skill intake.
39
39
  </Mode_Flags>
40
40
  </Depth_Profiles>
41
41
 
@@ -51,7 +51,8 @@ If no flag is provided, use **Standard**.
51
51
  - Always run a preflight context intake before the first interview question
52
52
  - Reduce user effort: ask only the highest-leverage unresolved question, and never ask the user for codebase facts that can be discovered directly
53
53
  - For brownfield work, prefer evidence-backed confirmation questions such as "I found X in Y. Should this change follow that pattern?"
54
- - In Codex CLI, prefer `request_user_input` when available; if unavailable, fall back to concise plain-text one-question turns
54
+ - In Codex CLI, deep-interview uses `omx question` as the required OMX-owned structured questioning path for every interview round
55
+ - If `omx question` is unavailable in the current runtime, treat that as a blocker/error for deep-interview rather than falling back to `request_user_input` or plain-text questioning
55
56
  - Re-score ambiguity after each answer and show progress transparently
56
57
  - Do not hand off to execution while ambiguity remains above threshold unless user explicitly opts to proceed with warning
57
58
  - Do not crystallize or hand off while `Non-goals` or `Decision Boundaries` remain unresolved, even if the weighted ambiguity threshold is met
@@ -145,7 +146,7 @@ Detailed dimensions:
145
146
  `Non-goals` and `Decision Boundaries` are mandatory readiness gates. Ask about them early and keep revisiting them until they are explicit.
146
147
 
147
148
  ### 2b) Ask the question
148
- Use structured user-input tooling available in the runtime (`AskUserQuestion` / equivalent) and present:
149
+ Use OMX-owned structured questioning via `omx question` for every interview round (this is the required `AskUserQuestion` equivalent for deep-interview) and present:
149
150
 
150
151
  ```
151
152
  Round {n} | Target: {weakest_dimension} | Ambiguity: {score}%
@@ -153,6 +154,96 @@ Round {n} | Target: {weakest_dimension} | Ambiguity: {score}%
153
154
  {question}
154
155
  ```
155
156
 
157
+ `omx question` payload guidance for interview rounds:
158
+ - Use canonical `type` values instead of authoring raw `multi_select` flags by hand. `type: "single-answerable"` is the default for one-path decisions; `type: "multi-answerable"` is the canonical shape for bounded multi-select rounds. The runtime will keep `multi_select` aligned with `type`.
159
+ - Use `single-answerable` when exactly one answer should drive the next branch, the options are mutually exclusive, or selecting more than one answer would blur the decision boundary. Typical cases: handoff lane selection, choosing the primary failure mode, or confirming which of several competing interpretations is correct.
160
+ - Use `multi-answerable` when multiple options may all be true at once and you need to capture a bounded set of coexisting constraints, non-goals, risks, or acceptance checks in one round. Typical cases: selecting all out-of-scope items, all success metrics that must hold, or all deployment constraints that apply together.
161
+ - If one selected option would immediately require a follow-up question to disambiguate the others, prefer a `single-answerable` round now and ask the follow-up next. Do not hide a branching interview tree inside one overloaded multi-select prompt.
162
+ - Keep interview options bounded and concrete. If the valid answers are already known, set `allow_other: false`; only leave `allow_other: true` when the interview genuinely needs one user-supplied option that cannot be enumerated in advance.
163
+ - Read answers structurally. For `single-answerable`, expect one decisive selection in `answer.value` plus `answer.selected_values`. For `multi-answerable`, treat `answer.selected_values` as the source of truth for all chosen constraints/non-goals and preserve the full set in the transcript/spec.
164
+
165
+ Canonical bounded single-choice payload:
166
+
167
+ ```json
168
+ {
169
+ "question": "Which execution lane should own this once the interview is complete?",
170
+ "type": "single-answerable",
171
+ "options": [
172
+ {
173
+ "label": "Plan first",
174
+ "value": "ralplan",
175
+ "description": "Need architecture and test-shape review before execution"
176
+ },
177
+ {
178
+ "label": "Execute directly",
179
+ "value": "autopilot",
180
+ "description": "Requirements are already explicit enough for planning plus execution"
181
+ },
182
+ {
183
+ "label": "Refine further",
184
+ "value": "refine",
185
+ "description": "Clarification is still needed before any handoff"
186
+ }
187
+ ],
188
+ "allow_other": false,
189
+ "other_label": "Other",
190
+ "source": "deep-interview"
191
+ }
192
+ ```
193
+
194
+ Canonical bounded multi-select payload:
195
+
196
+ ```json
197
+ {
198
+ "question": "Which non-goals must stay out of scope for the first pass?",
199
+ "type": "multi-answerable",
200
+ "options": [
201
+ {
202
+ "label": "No UI redesign",
203
+ "value": "no-ui-redesign",
204
+ "description": "Keep layout and styling unchanged"
205
+ },
206
+ {
207
+ "label": "No new dependencies",
208
+ "value": "no-new-dependencies",
209
+ "description": "Work within the existing toolchain"
210
+ },
211
+ {
212
+ "label": "No API contract changes",
213
+ "value": "no-api-contract-changes",
214
+ "description": "Preserve external request and response shapes"
215
+ }
216
+ ],
217
+ "allow_other": false,
218
+ "other_label": "Other",
219
+ "source": "deep-interview"
220
+ }
221
+ ```
222
+
223
+ Canonical answer-shape reminders:
224
+
225
+ ```json
226
+ {
227
+ "answer": {
228
+ "kind": "option",
229
+ "value": "ralplan",
230
+ "selected_labels": ["Plan first"],
231
+ "selected_values": ["ralplan"]
232
+ }
233
+ }
234
+ ```
235
+
236
+ ```json
237
+ {
238
+ "answer": {
239
+ "kind": "multi",
240
+ "value": ["no-new-dependencies", "no-api-contract-changes"],
241
+ "selected_labels": ["No new dependencies", "No API contract changes"],
242
+ "selected_values": ["no-new-dependencies", "no-api-contract-changes"]
243
+ }
244
+ }
245
+ ```
246
+
156
247
  ### 2c) Score ambiguity
157
248
  Score each weighted dimension in `[0.0, 1.0]` with justification + gap.
158
249
 
@@ -217,7 +308,7 @@ Spec should include:
217
308
 
218
309
  ### Autoresearch specialization
219
310
 
220
- When the clarified task is specifically about `omx autoresearch`, or the skill is invoked with `--autoresearch`, keep the interview domain-specific and emit launch-consumable artifacts without skipping clarification.
311
+ When the clarified task is specifically about `$autoresearch`, or the skill is invoked with `--autoresearch`, keep the interview domain-specific and emit skill-consumable artifacts without skipping clarification.
221
312
 
222
313
  - **Accepted seed inputs:** `topic`, `evaluator`, `keep-policy`, `slug`, existing mission draft text, and prior evaluator examples/templates
223
314
  - **Required interview focus:** mission clarity, evaluator readiness, keep policy, slug/session naming, and whether the draft is ready to launch now or should refine further
@@ -235,8 +326,8 @@ When the clarified task is specifically about `omx autoresearch`, or the skill i
235
326
  - `sandbox.md`
236
327
  - `result.json`
237
328
  - **Launch-readiness rule:** mark the draft as **not launch-ready** while the evaluator command still contains placeholder markers such as `<...>`, `TODO`, `TBD`, `REPLACE_ME`, `CHANGEME`, or `your-command-here`
238
- - **Structured result contract:** `result.json` should point to the draft + mission/sandbox artifacts and carry the finalized `topic`, `evaluatorCommand`, `keepPolicy`, `slug`, `launchReady`, and `blockedReasons` fields so `omx autoresearch` can consume it directly
239
- - **Confirmation bridge:** after artifact generation, offer at least `refine further` and `launch`; do not launch detached tmux until the user explicitly confirms `launch`
329
+ - **Structured result contract:** `result.json` should point to the draft + mission/sandbox artifacts and carry the finalized `topic`, `evaluatorCommand`, `keepPolicy`, `slug`, `launchReady`, and `blockedReasons` fields so `$autoresearch` can consume it directly
330
+ - **Confirmation bridge:** after artifact generation, offer at least `refine further` and `launch`; do not run direct CLI launch or detached/split tmux launch, and only hand off to `$autoresearch` after explicit confirmation
240
331
  - **Handoff rule:** downstream execution must preserve the clarified mission intent, evaluator expectations, decision boundaries, and launch-readiness status from this artifact rather than bypassing the draft review step
241
332
 
242
333
  ## Phase 5: Execution Bridge
@@ -296,8 +387,8 @@ Present execution options after artifact generation using explicit handoff contr
296
387
 
297
388
  <Tool_Usage>
298
389
  - Use `explore` for codebase fact gathering
299
- - Use `request_user_input` / structured user-input tool for each interview round when available
300
- - If structured question tools are unavailable, use plain-text single-question rounds and keep the same stage order
390
+ - Use `omx question` as the OMX-native structured user-input tool for each interview round
391
+ - If `omx question` is unavailable in the current runtime, stop and surface that deep-interview requires the OMX question tool rather than falling back to another questioning path
301
392
  - Use `state_write` / `state_read` for resumable mode state
302
393
  - Read/write context snapshots under `.omx/context/`
303
394
  - Save transcript/spec artifacts under `.omx/interviews/` and `.omx/specs/`
@@ -5,7 +5,9 @@ description: Guide on using oh-my-codex plugin
5
5
 
6
6
  # How OMX Works
7
7
 
8
- **You don't need to learn any commands!** OMX enhances Codex CLI with intelligent behaviors that activate automatically.
8
+ Plain English works as best-effort guidance OMX inspects each prompt and may add advisory routing context to steer the model toward a suitable lane. This is **advisory prompt-routing context**: it does not activate a skill or workflow by itself. Explicit keywords remain the deterministic control surface when you want exact, guaranteed routing.
9
+
10
+ **Triage lanes** (when no keyword matches): complex/multi-step prompts may receive HEAVY guidance (autopilot-shaped); read-only lookups receive LIGHT/explore guidance; implementation work receives LIGHT/executor guidance; UI work receives LIGHT/designer guidance; simple conversational prompts receive no injection (PASS). To opt out per prompt, include a phrase such as `no workflow`, `just chat`, or `plain answer`.
9
11
 
10
12
  ## What Happens Automatically
11
13
 
@@ -80,6 +80,7 @@ Before consensus planning or execution handoff, ensure a grounded context snapsh
80
80
  - unknowns/open questions
81
81
  - likely codebase touchpoints
82
82
  4. If ambiguity remains high, gather brownfield facts first. When session guidance enables `USE_OMX_EXPLORE_CMD`, prefer `omx explore` for simple read-only repository lookups with narrow, concrete prompts; otherwise use the richer normal explore path. Then run `$deep-interview --quick <task>` before continuing.
83
+ 5. If the plan depends on official docs, version-aware framework guidance, best practices, or external dependency behavior, auto-delegate `researcher` before finalizing the planning handoff so execution does not start from repo-local recall alone.
83
84
 
84
85
  Do not hand off to execution modes until this intake is complete; if urgency forces progress, explicitly document the risk tradeoffs.
85
86
 
@@ -109,6 +109,7 @@ Before launching `omx team`, require a grounded context snapshot:
109
109
  - unknowns/open questions
110
110
  - likely codebase touchpoints
111
111
  4. If ambiguity remains high, run `explore` first for brownfield facts, then run `$deep-interview --quick <task>` before team launch.
112
+ 5. If current correctness depends on official docs, version-aware framework guidance, best practices, or external dependency behavior, auto-delegate `researcher` as an evidence lane before or alongside worker launch instead of relying on repo-local recall alone.
112
113
 
113
114
  Do not start worker panes until this gate is satisfied; if forced to proceed quickly, state explicit scope/risk limitations in the launch report.
114
115