@bastani/atomic 0.9.4-alpha.1 → 0.9.4-alpha.11

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 (345) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/dist/builtin/cursor/CHANGELOG.md +24 -0
  3. package/dist/builtin/cursor/package.json +4 -4
  4. package/dist/builtin/intercom/CHANGELOG.md +24 -0
  5. package/dist/builtin/intercom/package.json +2 -2
  6. package/dist/builtin/mcp/CHANGELOG.md +24 -0
  7. package/dist/builtin/mcp/package.json +4 -4
  8. package/dist/builtin/subagents/CHANGELOG.md +52 -0
  9. package/dist/builtin/subagents/agents/code-simplifier.md +2 -2
  10. package/dist/builtin/subagents/agents/codebase-analyzer.md +2 -2
  11. package/dist/builtin/subagents/agents/codebase-locator.md +2 -2
  12. package/dist/builtin/subagents/agents/codebase-online-researcher.md +2 -2
  13. package/dist/builtin/subagents/agents/codebase-pattern-finder.md +2 -2
  14. package/dist/builtin/subagents/agents/codebase-research-analyzer.md +2 -2
  15. package/dist/builtin/subagents/agents/codebase-research-locator.md +2 -2
  16. package/dist/builtin/subagents/agents/debugger.md +1 -1
  17. package/dist/builtin/subagents/agents/worker.md +2 -2
  18. package/dist/builtin/subagents/package.json +4 -4
  19. package/dist/builtin/subagents/src/runs/background/async-execution-chain.ts +11 -1
  20. package/dist/builtin/subagents/src/runs/background/async-execution-single.ts +11 -1
  21. package/dist/builtin/subagents/src/runs/background/async-execution-types.ts +2 -0
  22. package/dist/builtin/subagents/src/runs/background/subagent-runner-step.ts +27 -4
  23. package/dist/builtin/subagents/src/runs/background/subagent-runner-streaming.ts +25 -0
  24. package/dist/builtin/subagents/src/runs/foreground/chain-execution-dynamic-step.ts +1 -0
  25. package/dist/builtin/subagents/src/runs/foreground/chain-execution-parallel-runner.ts +1 -0
  26. package/dist/builtin/subagents/src/runs/foreground/chain-execution-parallel-step.ts +1 -0
  27. package/dist/builtin/subagents/src/runs/foreground/chain-execution-sequential-step.ts +1 -0
  28. package/dist/builtin/subagents/src/runs/foreground/chain-execution-types.ts +2 -0
  29. package/dist/builtin/subagents/src/runs/foreground/chain-execution.ts +3 -1
  30. package/dist/builtin/subagents/src/runs/foreground/execution-attempt.ts +22 -0
  31. package/dist/builtin/subagents/src/runs/foreground/execution-run-sync.ts +15 -5
  32. package/dist/builtin/subagents/src/runs/foreground/subagent-executor-async.ts +5 -1
  33. package/dist/builtin/subagents/src/runs/foreground/subagent-executor-parallel-task.ts +2 -0
  34. package/dist/builtin/subagents/src/runs/foreground/subagent-executor-parallel.ts +4 -1
  35. package/dist/builtin/subagents/src/runs/foreground/subagent-executor-single.ts +4 -1
  36. package/dist/builtin/subagents/src/runs/shared/attempt-watchdog.ts +126 -0
  37. package/dist/builtin/subagents/src/runs/shared/model-candidate-filter.ts +53 -0
  38. package/dist/builtin/subagents/src/runs/shared/model-fallback.ts +52 -53
  39. package/dist/builtin/subagents/src/runs/shared/parallel-utils.ts +2 -0
  40. package/dist/builtin/subagents/src/shared/model-info.ts +16 -0
  41. package/dist/builtin/subagents/src/shared/types-config.ts +2 -0
  42. package/dist/builtin/subagents/src/slash/slash-commands.ts +2 -2
  43. package/dist/builtin/subagents/src/tui/render-result-compact.ts +3 -2
  44. package/dist/builtin/subagents/src/tui/render-result.ts +3 -3
  45. package/dist/builtin/subagents/src/tui/render-widget-graph.ts +4 -3
  46. package/dist/builtin/subagents/src/tui/render-widget.ts +10 -4
  47. package/dist/builtin/web-access/CHANGELOG.md +24 -0
  48. package/dist/builtin/web-access/package.json +2 -2
  49. package/dist/builtin/workflows/CHANGELOG.md +54 -0
  50. package/dist/builtin/workflows/builtin/deep-research-codebase-utils.ts +24 -22
  51. package/dist/builtin/workflows/builtin/goal-runner.ts +12 -23
  52. package/dist/builtin/workflows/builtin/open-claude-design-runner.ts +4 -4
  53. package/dist/builtin/workflows/builtin/ralph-models.ts +53 -75
  54. package/dist/builtin/workflows/package.json +2 -2
  55. package/dist/builtin/workflows/src/runs/shared/model-fallback-failures.ts +59 -1
  56. package/dist/builtin/workflows/src/tui/keybindings-adapter.ts +4 -0
  57. package/dist/builtin/workflows/src/tui/overlay-adapter.ts +4 -0
  58. package/dist/builtin/workflows/src/tui/stage-chat-view-input.ts +12 -1
  59. package/dist/builtin/workflows/src/tui/stage-chat-view-state.ts +2 -0
  60. package/dist/builtin/workflows/src/tui/stage-chat-view-types.ts +6 -0
  61. package/dist/builtin/workflows/src/tui/stage-chat-view.ts +4 -0
  62. package/dist/builtin/workflows/src/tui/workflow-attach-pane-types.ts +4 -0
  63. package/dist/builtin/workflows/src/tui/workflow-attach-pane.ts +8 -9
  64. package/dist/bun/cli.d.ts.map +1 -1
  65. package/dist/bun/cli.js +3 -2
  66. package/dist/bun/cli.js.map +1 -1
  67. package/dist/cli/file-processor.d.ts.map +1 -1
  68. package/dist/cli/file-processor.js +13 -25
  69. package/dist/cli/file-processor.js.map +1 -1
  70. package/dist/cli.d.ts.map +1 -1
  71. package/dist/cli.js +15 -5
  72. package/dist/cli.js.map +1 -1
  73. package/dist/config.d.ts +10 -3
  74. package/dist/config.d.ts.map +1 -1
  75. package/dist/config.js +18 -1
  76. package/dist/config.js.map +1 -1
  77. package/dist/core/agent-session-auto-compaction.d.ts.map +1 -1
  78. package/dist/core/agent-session-auto-compaction.js +8 -1
  79. package/dist/core/agent-session-auto-compaction.js.map +1 -1
  80. package/dist/core/agent-session-events.d.ts.map +1 -1
  81. package/dist/core/agent-session-events.js +16 -8
  82. package/dist/core/agent-session-events.js.map +1 -1
  83. package/dist/core/agent-session-export.d.ts.map +1 -1
  84. package/dist/core/agent-session-export.js +4 -2
  85. package/dist/core/agent-session-export.js.map +1 -1
  86. package/dist/core/agent-session-extension-bindings.d.ts +5 -1
  87. package/dist/core/agent-session-extension-bindings.d.ts.map +1 -1
  88. package/dist/core/agent-session-extension-bindings.js +18 -7
  89. package/dist/core/agent-session-extension-bindings.js.map +1 -1
  90. package/dist/core/agent-session-methods.d.ts +13 -3
  91. package/dist/core/agent-session-methods.d.ts.map +1 -1
  92. package/dist/core/agent-session-methods.js.map +1 -1
  93. package/dist/core/agent-session-prompt.d.ts +2 -0
  94. package/dist/core/agent-session-prompt.d.ts.map +1 -1
  95. package/dist/core/agent-session-prompt.js +15 -2
  96. package/dist/core/agent-session-prompt.js.map +1 -1
  97. package/dist/core/agent-session-retry.d.ts +2 -0
  98. package/dist/core/agent-session-retry.d.ts.map +1 -1
  99. package/dist/core/agent-session-retry.js +66 -7
  100. package/dist/core/agent-session-retry.js.map +1 -1
  101. package/dist/core/agent-session-state.d.ts.map +1 -1
  102. package/dist/core/agent-session-state.js +2 -2
  103. package/dist/core/agent-session-state.js.map +1 -1
  104. package/dist/core/agent-session-tool-hooks.d.ts +7 -1
  105. package/dist/core/agent-session-tool-hooks.d.ts.map +1 -1
  106. package/dist/core/agent-session-tool-hooks.js +26 -4
  107. package/dist/core/agent-session-tool-hooks.js.map +1 -1
  108. package/dist/core/agent-session-tool-registry.d.ts.map +1 -1
  109. package/dist/core/agent-session-tool-registry.js +4 -0
  110. package/dist/core/agent-session-tool-registry.js.map +1 -1
  111. package/dist/core/agent-session-tree.d.ts.map +1 -1
  112. package/dist/core/agent-session-tree.js +3 -1
  113. package/dist/core/agent-session-tree.js.map +1 -1
  114. package/dist/core/agent-session-types.d.ts +4 -0
  115. package/dist/core/agent-session-types.d.ts.map +1 -1
  116. package/dist/core/agent-session-types.js.map +1 -1
  117. package/dist/core/agent-session.d.ts +5 -1
  118. package/dist/core/agent-session.d.ts.map +1 -1
  119. package/dist/core/agent-session.js +5 -0
  120. package/dist/core/agent-session.js.map +1 -1
  121. package/dist/core/async/format.d.ts +3 -0
  122. package/dist/core/async/format.d.ts.map +1 -0
  123. package/dist/core/async/format.js +50 -0
  124. package/dist/core/async/format.js.map +1 -0
  125. package/dist/core/async/job-manager.d.ts +39 -0
  126. package/dist/core/async/job-manager.d.ts.map +1 -0
  127. package/dist/core/async/job-manager.js +254 -0
  128. package/dist/core/async/job-manager.js.map +1 -0
  129. package/dist/core/async/session-manager.d.ts +18 -0
  130. package/dist/core/async/session-manager.d.ts.map +1 -0
  131. package/dist/core/async/session-manager.js +61 -0
  132. package/dist/core/async/session-manager.js.map +1 -0
  133. package/dist/core/async/types.d.ts +23 -0
  134. package/dist/core/async/types.d.ts.map +1 -0
  135. package/dist/core/async/types.js +2 -0
  136. package/dist/core/async/types.js.map +1 -0
  137. package/dist/core/copilot-model-catalog.d.ts +38 -74
  138. package/dist/core/copilot-model-catalog.d.ts.map +1 -1
  139. package/dist/core/copilot-model-catalog.js +177 -68
  140. package/dist/core/copilot-model-catalog.js.map +1 -1
  141. package/dist/core/copilot-model-static-fallbacks.d.ts +43 -0
  142. package/dist/core/copilot-model-static-fallbacks.d.ts.map +1 -0
  143. package/dist/core/copilot-model-static-fallbacks.js +50 -0
  144. package/dist/core/copilot-model-static-fallbacks.js.map +1 -0
  145. package/dist/core/copilot-model-synthesis.d.ts +10 -0
  146. package/dist/core/copilot-model-synthesis.d.ts.map +1 -0
  147. package/dist/core/copilot-model-synthesis.js +89 -0
  148. package/dist/core/copilot-model-synthesis.js.map +1 -0
  149. package/dist/core/extensions/api-types.d.ts +2 -1
  150. package/dist/core/extensions/api-types.d.ts.map +1 -1
  151. package/dist/core/extensions/api-types.js.map +1 -1
  152. package/dist/core/extensions/index.d.ts +1 -1
  153. package/dist/core/extensions/index.d.ts.map +1 -1
  154. package/dist/core/extensions/index.js.map +1 -1
  155. package/dist/core/extensions/loader-core.d.ts.map +1 -1
  156. package/dist/core/extensions/loader-core.js +3 -3
  157. package/dist/core/extensions/loader-core.js.map +1 -1
  158. package/dist/core/extensions/loader-virtual-modules.d.ts +11 -0
  159. package/dist/core/extensions/loader-virtual-modules.d.ts.map +1 -1
  160. package/dist/core/extensions/loader-virtual-modules.js +79 -11
  161. package/dist/core/extensions/loader-virtual-modules.js.map +1 -1
  162. package/dist/core/extensions/session-events.d.ts +7 -1
  163. package/dist/core/extensions/session-events.d.ts.map +1 -1
  164. package/dist/core/extensions/session-events.js.map +1 -1
  165. package/dist/core/http-dispatcher.d.ts +2 -0
  166. package/dist/core/http-dispatcher.d.ts.map +1 -1
  167. package/dist/core/http-dispatcher.js +38 -5
  168. package/dist/core/http-dispatcher.js.map +1 -1
  169. package/dist/core/model-registry-builtins.d.ts.map +1 -1
  170. package/dist/core/model-registry-builtins.js +40 -6
  171. package/dist/core/model-registry-builtins.js.map +1 -1
  172. package/dist/core/model-registry.d.ts.map +1 -1
  173. package/dist/core/model-registry.js +4 -3
  174. package/dist/core/model-registry.js.map +1 -1
  175. package/dist/core/model-resolver-defaults.d.ts.map +1 -1
  176. package/dist/core/model-resolver-defaults.js +1 -1
  177. package/dist/core/model-resolver-defaults.js.map +1 -1
  178. package/dist/core/resource-loader-reload.d.ts.map +1 -1
  179. package/dist/core/resource-loader-reload.js +6 -3
  180. package/dist/core/resource-loader-reload.js.map +1 -1
  181. package/dist/core/resource-loader-types.d.ts +6 -0
  182. package/dist/core/resource-loader-types.d.ts.map +1 -1
  183. package/dist/core/resource-loader-types.js.map +1 -1
  184. package/dist/core/session-manager-core.d.ts +2 -12
  185. package/dist/core/session-manager-core.d.ts.map +1 -1
  186. package/dist/core/session-manager-core.js +8 -16
  187. package/dist/core/session-manager-core.js.map +1 -1
  188. package/dist/core/settings-manager-resource-accessors.d.ts +1 -0
  189. package/dist/core/settings-manager-resource-accessors.d.ts.map +1 -1
  190. package/dist/core/settings-manager-resource-accessors.js +11 -0
  191. package/dist/core/settings-manager-resource-accessors.js.map +1 -1
  192. package/dist/core/settings-manager-ui-accessors.d.ts +2 -0
  193. package/dist/core/settings-manager-ui-accessors.d.ts.map +1 -1
  194. package/dist/core/settings-manager-ui-accessors.js +9 -0
  195. package/dist/core/settings-manager-ui-accessors.js.map +1 -1
  196. package/dist/core/settings-types.d.ts +2 -0
  197. package/dist/core/settings-types.d.ts.map +1 -1
  198. package/dist/core/settings-types.js.map +1 -1
  199. package/dist/core/timings.d.ts +7 -5
  200. package/dist/core/timings.d.ts.map +1 -1
  201. package/dist/core/timings.js +42 -24
  202. package/dist/core/timings.js.map +1 -1
  203. package/dist/core/tools/bash-async-execution.d.ts +25 -0
  204. package/dist/core/tools/bash-async-execution.d.ts.map +1 -0
  205. package/dist/core/tools/bash-async-execution.js +71 -0
  206. package/dist/core/tools/bash-async-execution.js.map +1 -0
  207. package/dist/core/tools/bash-async-jobs.d.ts +10 -0
  208. package/dist/core/tools/bash-async-jobs.d.ts.map +1 -1
  209. package/dist/core/tools/bash-async-jobs.js +18 -2
  210. package/dist/core/tools/bash-async-jobs.js.map +1 -1
  211. package/dist/core/tools/bash-async-output.d.ts +3 -1
  212. package/dist/core/tools/bash-async-output.d.ts.map +1 -1
  213. package/dist/core/tools/bash-async-output.js +4 -1
  214. package/dist/core/tools/bash-async-output.js.map +1 -1
  215. package/dist/core/tools/bash-pty-native.d.ts.map +1 -1
  216. package/dist/core/tools/bash-pty-native.js +2 -2
  217. package/dist/core/tools/bash-pty-native.js.map +1 -1
  218. package/dist/core/tools/bash.d.ts +10 -4
  219. package/dist/core/tools/bash.d.ts.map +1 -1
  220. package/dist/core/tools/bash.js +20 -38
  221. package/dist/core/tools/bash.js.map +1 -1
  222. package/dist/core/tools/read-selectors.d.ts.map +1 -1
  223. package/dist/core/tools/read-selectors.js +19 -1
  224. package/dist/core/tools/read-selectors.js.map +1 -1
  225. package/dist/core/tools/read.d.ts.map +1 -1
  226. package/dist/core/tools/read.js +12 -23
  227. package/dist/core/tools/read.js.map +1 -1
  228. package/dist/core/tools/search-native.d.ts.map +1 -1
  229. package/dist/core/tools/search-native.js +2 -2
  230. package/dist/core/tools/search-native.js.map +1 -1
  231. package/dist/index-extensions.d.ts +1 -1
  232. package/dist/index-extensions.d.ts.map +1 -1
  233. package/dist/index-extensions.js.map +1 -1
  234. package/dist/index.d.ts +1 -1
  235. package/dist/index.d.ts.map +1 -1
  236. package/dist/index.js.map +1 -1
  237. package/dist/main-session.d.ts.map +1 -1
  238. package/dist/main-session.js +14 -5
  239. package/dist/main-session.js.map +1 -1
  240. package/dist/main.d.ts.map +1 -1
  241. package/dist/main.js +56 -32
  242. package/dist/main.js.map +1 -1
  243. package/dist/modes/interactive/components/assistant-message.d.ts +3 -1
  244. package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
  245. package/dist/modes/interactive/components/assistant-message.js +22 -15
  246. package/dist/modes/interactive/components/assistant-message.js.map +1 -1
  247. package/dist/modes/interactive/components/chat-message-renderer.d.ts +1 -0
  248. package/dist/modes/interactive/components/chat-message-renderer.d.ts.map +1 -1
  249. package/dist/modes/interactive/components/chat-message-renderer.js +5 -5
  250. package/dist/modes/interactive/components/chat-message-renderer.js.map +1 -1
  251. package/dist/modes/interactive/components/chat-session-host-events.d.ts.map +1 -1
  252. package/dist/modes/interactive/components/chat-session-host-events.js +8 -0
  253. package/dist/modes/interactive/components/chat-session-host-events.js.map +1 -1
  254. package/dist/modes/interactive/components/chat-session-host-rendering.d.ts.map +1 -1
  255. package/dist/modes/interactive/components/chat-session-host-rendering.js +1 -0
  256. package/dist/modes/interactive/components/chat-session-host-rendering.js.map +1 -1
  257. package/dist/modes/interactive/components/user-message.d.ts +6 -2
  258. package/dist/modes/interactive/components/user-message.d.ts.map +1 -1
  259. package/dist/modes/interactive/components/user-message.js +16 -5
  260. package/dist/modes/interactive/components/user-message.js.map +1 -1
  261. package/dist/modes/interactive/interactive-agent-events.d.ts.map +1 -1
  262. package/dist/modes/interactive/interactive-agent-events.js +6 -1
  263. package/dist/modes/interactive/interactive-agent-events.js.map +1 -1
  264. package/dist/modes/interactive/interactive-deferred-startup.d.ts +2 -0
  265. package/dist/modes/interactive/interactive-deferred-startup.d.ts.map +1 -0
  266. package/dist/modes/interactive/interactive-deferred-startup.js +59 -0
  267. package/dist/modes/interactive/interactive-deferred-startup.js.map +1 -0
  268. package/dist/modes/interactive/interactive-editor-actions.d.ts.map +1 -1
  269. package/dist/modes/interactive/interactive-editor-actions.js +1 -0
  270. package/dist/modes/interactive/interactive-editor-actions.js.map +1 -1
  271. package/dist/modes/interactive/interactive-extension-context.d.ts.map +1 -1
  272. package/dist/modes/interactive/interactive-extension-context.js +1 -0
  273. package/dist/modes/interactive/interactive-extension-context.js.map +1 -1
  274. package/dist/modes/interactive/interactive-mode-base.d.ts +3 -0
  275. package/dist/modes/interactive/interactive-mode-base.d.ts.map +1 -1
  276. package/dist/modes/interactive/interactive-mode-base.js +6 -0
  277. package/dist/modes/interactive/interactive-mode-base.js.map +1 -1
  278. package/dist/modes/interactive/interactive-mode-deps.d.ts +1 -1
  279. package/dist/modes/interactive/interactive-mode-deps.d.ts.map +1 -1
  280. package/dist/modes/interactive/interactive-mode-deps.js +1 -1
  281. package/dist/modes/interactive/interactive-mode-deps.js.map +1 -1
  282. package/dist/modes/interactive/interactive-mode-surface.d.ts +2 -0
  283. package/dist/modes/interactive/interactive-mode-surface.d.ts.map +1 -1
  284. package/dist/modes/interactive/interactive-mode-surface.js.map +1 -1
  285. package/dist/modes/interactive/interactive-mode-types.d.ts +2 -0
  286. package/dist/modes/interactive/interactive-mode-types.d.ts.map +1 -1
  287. package/dist/modes/interactive/interactive-mode-types.js.map +1 -1
  288. package/dist/modes/interactive/interactive-mode.d.ts +1 -0
  289. package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
  290. package/dist/modes/interactive/interactive-mode.js +1 -0
  291. package/dist/modes/interactive/interactive-mode.js.map +1 -1
  292. package/dist/modes/interactive/interactive-model-routing.d.ts.map +1 -1
  293. package/dist/modes/interactive/interactive-model-routing.js +2 -4
  294. package/dist/modes/interactive/interactive-model-routing.js.map +1 -1
  295. package/dist/modes/interactive/interactive-render-chat.d.ts.map +1 -1
  296. package/dist/modes/interactive/interactive-render-chat.js +4 -3
  297. package/dist/modes/interactive/interactive-render-chat.js.map +1 -1
  298. package/dist/modes/interactive/interactive-session-runtime.d.ts.map +1 -1
  299. package/dist/modes/interactive/interactive-session-runtime.js +5 -2
  300. package/dist/modes/interactive/interactive-session-runtime.js.map +1 -1
  301. package/dist/modes/interactive/interactive-startup.d.ts.map +1 -1
  302. package/dist/modes/interactive/interactive-startup.js +11 -1
  303. package/dist/modes/interactive/interactive-startup.js.map +1 -1
  304. package/dist/modes/rpc/rpc-client.d.ts +28 -51
  305. package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
  306. package/dist/modes/rpc/rpc-client.js +27 -51
  307. package/dist/modes/rpc/rpc-client.js.map +1 -1
  308. package/dist/modes/rpc/rpc-command-handler.d.ts.map +1 -1
  309. package/dist/modes/rpc/rpc-command-handler.js +19 -0
  310. package/dist/modes/rpc/rpc-command-handler.js.map +1 -1
  311. package/dist/modes/rpc/rpc-types.d.ts +26 -0
  312. package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
  313. package/dist/modes/rpc/rpc-types.js.map +1 -1
  314. package/dist/rpc-entry.d.ts +3 -0
  315. package/dist/rpc-entry.d.ts.map +1 -0
  316. package/dist/rpc-entry.js +12 -0
  317. package/dist/rpc-entry.js.map +1 -0
  318. package/dist/utils/image-convert.d.ts +1 -0
  319. package/dist/utils/image-convert.d.ts.map +1 -1
  320. package/dist/utils/image-convert.js +21 -15
  321. package/dist/utils/image-convert.js.map +1 -1
  322. package/dist/utils/image-process.d.ts +18 -0
  323. package/dist/utils/image-process.d.ts.map +1 -0
  324. package/dist/utils/image-process.js +83 -0
  325. package/dist/utils/image-process.js.map +1 -0
  326. package/dist/utils/mime.d.ts.map +1 -1
  327. package/dist/utils/mime.js +41 -0
  328. package/dist/utils/mime.js.map +1 -1
  329. package/dist/utils/module-require.d.ts +11 -0
  330. package/dist/utils/module-require.d.ts.map +1 -0
  331. package/dist/utils/module-require.js +16 -0
  332. package/dist/utils/module-require.js.map +1 -0
  333. package/docs/compaction.md +2 -0
  334. package/docs/development.md +10 -0
  335. package/docs/extensions.md +11 -0
  336. package/docs/models.md +3 -3
  337. package/docs/providers.md +2 -1
  338. package/docs/rpc.md +60 -2
  339. package/docs/sdk.md +1 -1
  340. package/docs/settings.md +4 -1
  341. package/docs/subagents.md +6 -0
  342. package/docs/tools.md +4 -2
  343. package/docs/workflows.md +4 -2
  344. package/npm-shrinkwrap.json +138 -171
  345. package/package.json +19 -12
@@ -117,6 +117,7 @@ export type ModelFallbackFailureKind =
117
117
  | "provider_unavailable"
118
118
  | "network_timeout"
119
119
  | "model_unavailable"
120
+ | "request_incompatible"
120
121
  | "cancelled"
121
122
  | "task_failure"
122
123
  | "unknown";
@@ -144,6 +145,7 @@ const FALLBACKABLE_FAILURE_KINDS: ReadonlySet<ModelFallbackFailureKind> = new Se
144
145
  "provider_unavailable",
145
146
  "network_timeout",
146
147
  "model_unavailable",
148
+ "request_incompatible",
147
149
  ]);
148
150
 
149
151
  function asRecord(value: unknown): Record<string, unknown> | undefined {
@@ -222,6 +224,9 @@ function normalizeCode(value: string | number | undefined): string | undefined {
222
224
 
223
225
  function kindFromStatus(status: number | undefined): ModelFallbackFailureKind | undefined {
224
226
  switch (status) {
227
+ case 400:
228
+ case 413: case 422:
229
+ return "request_incompatible";
225
230
  case 401:
226
231
  case 403:
227
232
  return "auth_on_candidate_provider";
@@ -237,6 +242,15 @@ function kindFromStatus(status: number | undefined): ModelFallbackFailureKind |
237
242
  }
238
243
  }
239
244
 
245
+ const REQUEST_INCOMPATIBLE_CODES: ReadonlySet<string> = new Set([
246
+ "invalid_request", "invalid_request_error", "bad_request", "context_length_exceeded",
247
+ "request_too_large", "too_large", "request_entity_too_large", "max_tokens",
248
+ "max_context_length", "context_window_exceeded",
249
+ ]);
250
+ function requestIncompatibleKindFromCode(code: string | number | undefined): ModelFallbackFailureKind | undefined {
251
+ const normalizedCode = normalizeCode(code);
252
+ return normalizedCode !== undefined && REQUEST_INCOMPATIBLE_CODES.has(normalizedCode) ? "request_incompatible" : undefined;
253
+ }
240
254
  function refusalKindFromCode(code: string | number | undefined): ModelFallbackFailureKind | undefined {
241
255
  const normalizedCode = normalizeCode(code);
242
256
  if (normalizedCode === undefined) return undefined;
@@ -258,6 +272,14 @@ function refusalKindFromCode(code: string | number | undefined): ModelFallbackFa
258
272
  }
259
273
  }
260
274
 
275
+ const CODE_KINDS_BY_KIND: ReadonlyArray<readonly [ModelFallbackFailureKind, ReadonlySet<string>]> = [
276
+ ["auth_on_candidate_provider", new Set(["auth", "auth_required", "authentication_required", "unauthorized", "forbidden", "invalid_api_key", "missing_api_key", "invalid_key"])],
277
+ ["network_timeout", new Set(["etimedout", "econnreset", "econnrefused", "enotfound", "eai_again", "fetch_failed", "network_error", "timeout", "timeout_error", "und_err_connect_timeout"])],
278
+ ["rate_limit", new Set(["rate_limit", "rate_limit_exceeded", "too_many_requests", "quota_exceeded"])],
279
+ ["cancelled", new Set(["aborterror", "aborted", "cancelled", "canceled"])],
280
+ ["model_unavailable", new Set(["model_not_found", "model_unavailable", "model_disabled", "unknown_model"])],
281
+ ["provider_unavailable", new Set(["provider_error", "api_error", "service_unavailable", "temporarily_unavailable", "overloaded"])],
282
+ ];
261
283
  function kindFromCode(code: string | number | undefined): ModelFallbackFailureKind | undefined {
262
284
  const normalizedCode = normalizeCode(code);
263
285
  if (normalizedCode === undefined) return undefined;
@@ -265,54 +287,19 @@ function kindFromCode(code: string | number | undefined): ModelFallbackFailureKi
265
287
  if (refusalKind !== undefined) return refusalKind;
266
288
  const httpStatusKind = kindFromStatus(integerFrom(code));
267
289
  if (httpStatusKind !== undefined) return httpStatusKind;
268
-
269
- switch (normalizedCode) {
270
- case "auth":
271
- case "auth_required":
272
- case "authentication_required":
273
- case "unauthorized":
274
- case "forbidden":
275
- case "invalid_api_key":
276
- case "missing_api_key":
277
- case "invalid_key":
278
- return "auth_on_candidate_provider";
279
- case "etimedout":
280
- case "econnreset":
281
- case "econnrefused":
282
- case "enotfound":
283
- case "eai_again":
284
- case "fetch_failed":
285
- case "network_error":
286
- case "timeout":
287
- case "timeout_error":
288
- case "und_err_connect_timeout":
289
- return "network_timeout";
290
- case "rate_limit":
291
- case "rate_limit_exceeded":
292
- case "too_many_requests":
293
- case "quota_exceeded":
294
- return "rate_limit";
295
- case "aborterror":
296
- case "aborted":
297
- case "cancelled":
298
- case "canceled":
299
- return "cancelled";
300
- case "model_not_found":
301
- case "model_unavailable":
302
- case "model_disabled":
303
- case "unknown_model":
304
- return "model_unavailable";
305
- case "provider_error":
306
- case "api_error":
307
- case "service_unavailable":
308
- case "temporarily_unavailable":
309
- case "overloaded":
310
- return "provider_unavailable";
311
- default:
312
- return undefined;
313
- }
314
- }
315
-
290
+ const requestIncompatibleKind = requestIncompatibleKindFromCode(code);
291
+ if (requestIncompatibleKind !== undefined) return requestIncompatibleKind;
292
+ return CODE_KINDS_BY_KIND.find(([_, codes]) => codes.has(normalizedCode))?.[0];
293
+ }
294
+
295
+ const REQUEST_INCOMPATIBLE_FAILURE_PATTERNS: readonly RegExp[] = [
296
+ /\bcontext[_\s-]?(?:length|window)(?:[_\s-]?exceeded)?\b/i,
297
+ /\bmax[_\s-]?(?:context|tokens?)\b/i,
298
+ /\b(?:request(?:[_\s-]?entity)?[_\s-]?too|too)[_\s-]?large\b/i,
299
+ /\b(?:unsupported|unknown|invalid)\s+(?:tool|parameter|function)\b/i,
300
+ /\b(?:tool|parameter|function)\s+(?:not\s+(?:supported|found|allowed)|unknown|invalid)\b/i,
301
+ /\b(?:invalid[_\s-]?request(?:[_\s-]?error)?|bad[_\s-]?request)\b/i,
302
+ ];
316
303
  const PROVIDER_REFUSAL_FAILURE_PATTERNS: readonly RegExp[] = [
317
304
  /\bfinish[_\s-]?reason\b[^\n]*\bcontent[_\s-]?filter\b/i,
318
305
  /\bcontent[_\s-]?filter(?:ed|ing)?\b/i,
@@ -335,6 +322,7 @@ function refusalKindFromMessage(message: string): ModelFallbackFailureKind | und
335
322
  function fallbackKindFromMessage(message: string, name: string | undefined): ModelFallbackFailureKind | undefined {
336
323
  const refusalKind = refusalKindFromMessage(message);
337
324
  if (refusalKind !== undefined) return refusalKind;
325
+ if (REQUEST_INCOMPATIBLE_FAILURE_PATTERNS.some((pattern) => pattern.test(message))) return "request_incompatible";
338
326
  const nameKind = kindFromCode(name);
339
327
  if (nameKind !== undefined) return nameKind;
340
328
  if (!RETRYABLE_MODEL_FAILURE_PATTERNS.some((pattern) => pattern.test(message))) return undefined;
@@ -372,15 +360,21 @@ function makeSignal(
372
360
  };
373
361
  }
374
362
 
375
- function fallbackSignalFromMessage(
363
+ function fallbackSignalForMessage(
364
+ message: string | undefined,
376
365
  value: unknown,
377
366
  source: ModelFallbackFailureSource | undefined,
378
367
  ): ModelFallbackFailureSignal | undefined {
379
- const message = modelFailureMessage(value);
380
- if (!message.trim()) return undefined;
368
+ if (message === undefined || message.trim().length === 0) return undefined;
381
369
  const kind = fallbackKindFromMessage(message, errorName(value));
382
370
  return kind === undefined ? undefined : makeSignal(kind, value, source);
383
371
  }
372
+ function fallbackSignalFromMessage(value: unknown, source: ModelFallbackFailureSource | undefined): ModelFallbackFailureSignal | undefined {
373
+ return fallbackSignalForMessage(modelFailureMessage(value), value, source);
374
+ }
375
+ function fallbackSignalFromDirectMessage(value: unknown, source: ModelFallbackFailureSource | undefined): ModelFallbackFailureSignal | undefined {
376
+ return fallbackSignalForMessage(directMessageFrom(value), value, source);
377
+ }
384
378
 
385
379
  function classifyAssistantRefusalSignal(
386
380
  value: unknown,
@@ -433,6 +427,12 @@ function structuredSignal(
433
427
  if (isRefusalSignal(causeSignal)) return causeSignal;
434
428
  firstNestedFallbackSignal ??= causeSignal;
435
429
  }
430
+ // Direct-message classification runs after nested traversal so a generic wrapper
431
+ // ("invalid request"/"400 bad request") cannot mask a non-retryable nested signal.
432
+ // Kept in the same position as the workflows classifier so the two copies stay
433
+ // behaviorally parallel (see test/unit/model-fallback-classifier-conformance.test.ts).
434
+ const directMessageSignal = fallbackSignalFromDirectMessage(value, source);
435
+ if (directMessageSignal !== undefined) return directMessageSignal;
436
436
  const statusKind = kindFromStatus(statusFrom(value));
437
437
  if (statusKind !== undefined) return makeSignal(statusKind, value, source);
438
438
  if (codeKind !== undefined) return makeSignal(codeKind, value, source);
@@ -463,8 +463,7 @@ function messageFromUnknown(value: unknown, seen: Set<unknown>): string | undefi
463
463
  const status = statusFrom(value);
464
464
  if (status !== undefined) return `Model request failed with status ${status}`;
465
465
  const code = codeFrom(value);
466
- if (code !== undefined) return `Model request failed with code ${String(code)}`;
467
- return undefined;
466
+ return code !== undefined ? `Model request failed with code ${String(code)}` : undefined;
468
467
  }
469
468
  export function modelFailureMessage(error: unknown): string {
470
469
  const structuredMessage = messageFromUnknown(error, new Set());
@@ -1,4 +1,5 @@
1
1
  import type { CodexFastModeResolvedSettings, CodexFastModeScope } from "@bastani/atomic";
2
+ import type { ModelAttempt } from "../../shared/types.ts";
2
3
 
3
4
  export interface RunnerSubagentStep {
4
5
  agent: string;
@@ -13,6 +14,7 @@ export interface RunnerSubagentStep {
13
14
  fastMode?: boolean;
14
15
  modelFastModes?: Record<string, boolean>;
15
16
  modelCandidates?: string[];
17
+ modelAttempts?: ModelAttempt[];
16
18
  codexFastModeSettings?: CodexFastModeResolvedSettings;
17
19
  codexFastModeScope?: CodexFastModeScope;
18
20
  tools?: string[];
@@ -27,6 +27,22 @@ export function toModelInfo(model: RegistryModelLike): ModelInfo {
27
27
  };
28
28
  }
29
29
 
30
+ interface KnownProviderRegistryLike {
31
+ getAvailable(): ReadonlyArray<{ provider: string }>;
32
+ /** Older hosts may not expose `getAll()`; callers probe at runtime and fall back
33
+ * to `getAvailable()`. */
34
+ getAll?: () => ReadonlyArray<{ provider: string }>;
35
+ }
36
+
37
+ /** Collect the distinct providers of every model the registry knows about — including
38
+ * providers without configured auth — falling back to `getAvailable()` when the host
39
+ * registry does not expose `getAll()`. Used to pre-filter spawn candidates whose
40
+ * provider is known but keyless. */
41
+ export function collectKnownModelProviders(registry: KnownProviderRegistryLike): string[] {
42
+ const models = typeof registry.getAll === "function" ? registry.getAll() : registry.getAvailable();
43
+ return [...new Set(models.map((model) => model.provider))];
44
+ }
45
+
30
46
  /** Resolve the effective thinking level from a model string (which may contain a known suffix like `:high`)
31
47
  * and an explicit thinking config value. Returns `undefined` when no thinking is applicable
32
48
  * (e.g. no model was specified, or the model has no suffix and no config was provided). */
@@ -80,6 +80,8 @@ export interface RunSyncOptions {
80
80
  modelOverride?: string;
81
81
  /** Registry models available for heuristic bare-model resolution */
82
82
  availableModels?: Array<{ provider: string; id: string; fullId: string }>;
83
+ /** Providers known to the registry before auth filtering */
84
+ knownModelProviders?: string[];
83
85
  /** Current parent-session provider to prefer for ambiguous bare model ids */
84
86
  preferredModelProvider?: string;
85
87
  /** Current parent-session model to try after configured fallback models */
@@ -1,7 +1,7 @@
1
1
  import { randomUUID } from "node:crypto";
2
2
  import * as fs from "node:fs";
3
3
  import * as path from "node:path";
4
- import type { ExtensionAPI, ExtensionContext } from "@bastani/atomic";
4
+ import { keyHint, type ExtensionAPI, type ExtensionContext } from "@bastani/atomic";
5
5
  import { Key, matchesKey } from "@earendil-works/pi-tui";
6
6
  import { discoverAgents, discoverAgentsAll, type ChainConfig } from "../agents/agents.ts";
7
7
  import type { SubagentParamsLike } from "../runs/foreground/subagent-executor.ts";
@@ -164,7 +164,7 @@ async function requestSlashRun(
164
164
  if (!ctx.hasUI) return;
165
165
  const tool = update.currentTool ? ` ${update.currentTool}` : "";
166
166
  const count = update.toolCount ?? 0;
167
- ctx.ui.setStatus("subagent-slash", `${count} tools${tool} | ctrl+o live detail`);
167
+ ctx.ui.setStatus("subagent-slash", `${count} tools${tool} | ${keyHint("app.tools.expand", "live detail")}`);
168
168
  };
169
169
 
170
170
  const onTerminalInput = ctx.hasUI
@@ -1,3 +1,4 @@
1
+ import { keyHint } from "@bastani/atomic";
1
2
  import { Container, Text, type Component } from "@earendil-works/pi-tui";
2
3
  import type { AgentProgress, AsyncJobStep, Details } from "../shared/types.ts";
3
4
  import { shortenPath } from "../shared/formatters.ts";
@@ -45,7 +46,7 @@ export function renderSingleCompact(d: Details, r: Details["results"][number], t
45
46
  c.addChild(new Text(truncLine(theme.fg("dim", ` ⎿ ${activity}`), width), 0, 0));
46
47
  const liveStatus = buildLiveStatusLine(r.progress, progressSnapshotNow);
47
48
  if (liveStatus && liveStatus !== activity) c.addChild(new Text(truncLine(theme.fg("dim", ` ${liveStatus}`), width), 0, 0));
48
- c.addChild(new Text(truncLine(theme.fg("accent", " Press ctrl+o for live detail"), width), 0, 0));
49
+ c.addChild(new Text(truncLine(theme.fg("accent", ` Press ${keyHint("app.tools.expand", "for live detail")}`), width), 0, 0));
49
50
  if (r.artifactPaths) c.addChild(new Text(truncLine(theme.fg("dim", ` output: ${shortenPath(r.artifactPaths.outputPath)}`), width), 0, 0));
50
51
  return c;
51
52
  }
@@ -141,7 +142,7 @@ export function renderMultiCompact(d: Details, theme: Theme, now?: number, pulse
141
142
  if (rRunning && rProg && "status" in rProg) {
142
143
  const activity = compactCurrentActivity(rProg, now);
143
144
  c.addChild(new Text(truncLine(theme.fg("dim", ` ⎿ ${activity}`), width), 0, 0));
144
- c.addChild(new Text(truncLine(theme.fg("accent", " Press ctrl+o for live detail"), width), 0, 0));
145
+ c.addChild(new Text(truncLine(theme.fg("accent", ` Press ${keyHint("app.tools.expand", "for live detail")}`), width), 0, 0));
145
146
  } else if (!rPending && (r.exitCode !== 0 || r.interrupted || r.detached || hasEmptyTextOutputWithoutOutputTarget(r.task, output))) {
146
147
  c.addChild(new Text(truncLine(theme.fg(r.exitCode !== 0 ? "error" : "dim", ` ⎿ ${resultStatusLine(r, output)}`), width), 0, 0));
147
148
  }
@@ -1,5 +1,5 @@
1
1
  import type { AgentToolResult } from "@earendil-works/pi-agent-core";
2
- import { getMarkdownTheme } from "@bastani/atomic";
2
+ import { getMarkdownTheme, keyHint } from "@bastani/atomic";
3
3
  import { Container, Markdown, Spacer, Text, type Component } from "@earendil-works/pi-tui";
4
4
  import type { AgentProgress, AsyncJobStep, Details } from "../shared/types.ts";
5
5
  import { formatDuration, formatTokens, formatUsage, shortenPath } from "../shared/formatters.ts";
@@ -116,7 +116,7 @@ export function renderSubagentResult(
116
116
  if (liveStatusLine) {
117
117
  c.addChild(new Text(fit(theme.fg("accent", liveStatusLine)), 0, 0));
118
118
  }
119
- c.addChild(new Text(fit(theme.fg("accent", "Press ctrl+o for live detail")), 0, 0));
119
+ c.addChild(new Text(fit(theme.fg("accent", `Press ${keyHint("app.tools.expand", "for live detail")}`)), 0, 0));
120
120
  if (r.artifactPaths) {
121
121
  c.addChild(new Text(fit(theme.fg("dim", `Artifacts: ${shortenPath(r.artifactPaths.outputPath)}`)), 0, 0));
122
122
  }
@@ -350,7 +350,7 @@ export function renderSubagentResult(
350
350
  if (liveStatusLine) {
351
351
  c.addChild(new Text(fit(theme.fg("accent", ` ${liveStatusLine}`)), 0, 0));
352
352
  }
353
- c.addChild(new Text(fit(theme.fg("accent", " Press ctrl+o for live detail")), 0, 0));
353
+ c.addChild(new Text(fit(theme.fg("accent", ` Press ${keyHint("app.tools.expand", "for live detail")}`)), 0, 0));
354
354
  if (r.artifactPaths) {
355
355
  c.addChild(new Text(fit(theme.fg("dim", ` artifacts: ${shortenPath(r.artifactPaths.outputPath)}`)), 0, 0));
356
356
  }
@@ -1,3 +1,4 @@
1
+ import { keyHint } from "@bastani/atomic";
1
2
  import type { AsyncJobState } from "../shared/types.ts";
2
3
  import { shortenPath } from "../shared/formatters.ts";
3
4
  import { aggregateStepStatus, formatParallelOutcome } from "../shared/status-format.ts";
@@ -80,7 +81,7 @@ export function foregroundStyleWidgetStepLines(
80
81
  lines.push(` ${nestedLine}`);
81
82
  }
82
83
  if (step.status === "running") {
83
- if (!expanded) lines.push(` ${theme.fg("accent", "Press ctrl+o for live detail")}`);
84
+ if (!expanded) lines.push(` ${theme.fg("accent", `Press ${keyHint("app.tools.expand", "for live detail")}`)}`);
84
85
  const output = widgetOutputPath(job, step);
85
86
  if (output) lines.push(` ${theme.fg("dim", `output: ${shortenPath(output)}`)}`);
86
87
  if (expanded) {
@@ -147,7 +148,7 @@ export function compactSingleWidgetLines(job: AsyncJobState, theme: Theme, width
147
148
  lines.push(` ${widgetStepGlyph(step.status, theme, widgetStepRunningSeed(step, index), now)} ${itemTitle} ${index + 1}/${total}: ${themeBold(theme, step.agent)} ${theme.fg("dim", "·")} ${status}${modelDisplay}${activitySuffix}${stepStats ? ` ${theme.fg("dim", "·")} ${stepStats}` : ""}`);
148
149
  for (const nestedLine of formatNestedWidgetLines(step.children, theme, width, false, job.updatedAt, undefined, now)) lines.push(` ${nestedLine}`);
149
150
  }
150
- if (job.steps.some((step) => step.status === "running")) lines.push(theme.fg("accent", " Press ctrl+o for live detail"));
151
+ if (job.steps.some((step) => step.status === "running")) lines.push(theme.fg("accent", ` Press ${keyHint("app.tools.expand", "for live detail")}`));
151
152
  return lines.map((line) => truncLine(line, width));
152
153
  }
153
154
 
@@ -161,6 +162,6 @@ export function fitWidgetLineBudget(lines: string[], theme: Theme, width: number
161
162
  const hiddenCount = lines.length - visibleLines;
162
163
  const hint = expanded
163
164
  ? `… ${hiddenCount} live-detail lines hidden`
164
- : `… ${hiddenCount} lines hidden · ctrl+o expands`;
165
+ : `… ${hiddenCount} lines hidden · ${keyHint("app.tools.expand", "expands")}`;
165
166
  return [...lines.slice(0, visibleLines), truncLine(theme.fg("dim", hint), width)];
166
167
  }
@@ -63,6 +63,7 @@ interface RenderRequestingContext {
63
63
  let latestWidgetCtx: ExtensionContext | undefined;
64
64
  let latestWidgetJobs: AsyncJobState[] = [];
65
65
  let latestWidgetFrameNow = 0;
66
+ let latestWidgetExpanded = false;
66
67
  let widgetTimer: ReturnType<typeof setInterval> | undefined;
67
68
  let mountedWidgetCtx: ExtensionContext | undefined;
68
69
  let mountedWidgetOwnerKey: string | undefined;
@@ -78,16 +79,21 @@ function getLatestWidgetFrameNow(): number {
78
79
 
79
80
  function getLatestWidgetExpanded(): boolean {
80
81
  // LiveWidgetComponent re-renders outside a specific renderWidget() call, so
81
- // read expansion from the latest live singleton context. If that context was
82
- // cleared or went stale, collapse safely instead of consulting a stale caller.
83
- if (!latestWidgetCtx?.hasUI) return false;
84
- return latestWidgetCtx.ui.getToolsExpanded?.() ?? false;
82
+ // remember the last expansion state observed from a live host UI. Workflow
83
+ // stage-node detach can briefly repaint the mounted singleton with a stale or
84
+ // no-UI context before the next subagent status update refreshes it; falling
85
+ // back to the cached value avoids a transient collapse while jobs keep running.
86
+ if (!latestWidgetCtx?.hasUI) return latestWidgetExpanded;
87
+ const expanded = latestWidgetCtx.ui.getToolsExpanded?.();
88
+ if (typeof expanded === "boolean") latestWidgetExpanded = expanded;
89
+ return latestWidgetExpanded;
85
90
  }
86
91
 
87
92
  function clearLatestWidgetState(): void {
88
93
  latestWidgetCtx = undefined;
89
94
  latestWidgetJobs = [];
90
95
  latestWidgetFrameNow = 0;
96
+ latestWidgetExpanded = false;
91
97
  mountedWidgetCtx = undefined;
92
98
  mountedWidgetOwnerKey = undefined;
93
99
  widgetMounted = false;
@@ -4,6 +4,30 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.9.4-alpha.6] - 2026-07-01
8
+
9
+ ### Changed
10
+
11
+ - Aligned the web-access extension peer dependency with upstream pi TUI `^0.80.3`; no web-access extension source changes were needed for this metadata sync.
12
+
13
+ ## [0.9.4-alpha.5] - 2026-07-01
14
+
15
+ ### Changed
16
+
17
+ - Published a synchronized Atomic 0.9.4-alpha.5 prerelease for the web-access extension; no web-access extension changes were made after 0.9.4-alpha.1.
18
+
19
+ ## [0.9.4-alpha.4] - 2026-06-30
20
+
21
+ ### Changed
22
+
23
+ - Published a synchronized Atomic 0.9.4-alpha.4 prerelease for the web-access extension; no web-access extension changes were made after 0.9.4-alpha.1.
24
+
25
+ ## [0.9.4-alpha.3] - 2026-06-30
26
+
27
+ ### Changed
28
+
29
+ - Published a synchronized Atomic 0.9.4-alpha.3 prerelease for the web-access extension; no web-access extension changes were made after 0.9.4-alpha.1.
30
+
7
31
  ## [0.9.4-alpha.1] - 2026-06-29
8
32
 
9
33
  ### Changed
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bastani/web-access",
3
- "version": "0.9.4-alpha.1",
3
+ "version": "0.9.4-alpha.11",
4
4
  "private": true,
5
5
  "description": "Atomic extension for web search, URL fetching, GitHub repo cloning, PDF/video extraction. Fork of: https://github.com/nicobailon/pi-web-access",
6
6
  "contributors": [
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "peerDependencies": {
33
33
  "@bastani/atomic": "*",
34
- "@earendil-works/pi-tui": "^0.80.2"
34
+ "@earendil-works/pi-tui": "^0.80.3"
35
35
  },
36
36
  "peerDependenciesMeta": {
37
37
  "@bastani/atomic": {
@@ -6,6 +6,60 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.9.4-alpha.11] - 2026-07-03
10
+
11
+ ### Fixed
12
+
13
+ - Fixed attached workflow stage viewers so the host `app.tools.expand` keybinding (Ctrl+O by default) toggles live-detail/tool-output expansion just like the main chat, including custom keybinding remaps ([#1607](https://github.com/bastani-inc/atomic/issues/1607)).
14
+
15
+ ## [0.9.4-alpha.9] - 2026-07-02
16
+
17
+ ### Changed
18
+
19
+ - Changed the Claude Fable 5 reasoning level back from `high` to `xhigh` across all builtin workflow model chains (`ralph` prompt-engineer/reviewer-a/reviewer-b/reviewer-c, `goal` reviewer, `deep-research-codebase` planner, and `open-claude-design`), covering both the native `anthropic/claude-fable-5` entries and their OpenRouter mirrors; this reverts the `xhigh` → `high` change shipped in 0.9.4-alpha.8.
20
+ - Curated all builtin workflow model chains against Atomic's agentic-coding benchmark (pass@1 / avg cost per task, 2026-07-02) under a role-based placement principle: **reviewers get best-in-class verification quality, every other stage gets the best measured performance-per-dollar**. Reviewer stages keep `anthropic/claude-fable-5:xhigh` (70% / $13.41, `ralph` reviewer-a and the `goal` reviewer), `openai-codex/gpt-5.5:xhigh` (67% / $7.23, reviewer-b), and `zai/glm-5.2:xhigh` (44% / $3.92, reviewer-c for third-family diversity). Non-reviewer stages moved to perf-per-dollar primaries: `ralph` prompt-engineer and the `deep-research-codebase` planner from `claude-fable-5:xhigh` to `openai-codex/gpt-5.5:xhigh` (−3pts for half the cost, with `fable-5:xhigh` as the first cross-family fallback), and the `deep-research-codebase` explorer from unbenchmarked `gpt-5.4-mini:low` to the measured cheap-tier value point `openai-codex/gpt-5.5:low` ($1.20 / task, 28 steps, 9.4k output tokens), backed only by measured fallbacks (`claude-opus-4.8:low` at 41% / $2.29, then `glm-5.2:high`). Unbenchmarked models (`gpt-5.4-mini`, `claude-haiku-4.5`) and unmeasured levels (`gemini-3.5-flash:low`) are removed entirely — every chain entry now corresponds to a benchmark datapoint. Dropped strictly dominated candidates from every chain: `claude-sonnet-5` (40–54% at $4.08–$26.40 per task with up to 268 steps), `claude-sonnet-4.6` (30% / $5.52), `gemini-3.1-pro` (12% / $9.48), and `gemini-3.5-flash` (37% / $7.34 with 276k output tokens). Moved `claude-opus-4.8` fallback entries from `:xhigh` to `:high` — its cost/value point (52% / $4.28 vs 54% / $8.01) — everywhere except `open-claude-design`, which keeps an Anthropic-led chain (`fable-5:xhigh` primary, Opus at `:xhigh`) since design quality, not $/task, is its objective. Added `anthropic/claude-fable-5:low` (60% / $3.76) as the Anthropic candidate in the medium-tier `ralph` research/orchestrator and `goal` worker chains.
21
+ - Normalized all GLM-5.2 chain entries to the model's two real reasoning tiers: GLM-5.2's thinking-level map collapses `minimal`/`low`/`medium`/`high` to its "high" effort and `xhigh` to "max", so the previous `zai/glm-5.2:medium` entries in the `ralph` research/orchestrator and `goal` worker chains silently ran (and billed) at the "high" tier under a misleading label. Native `zai`/`zai-coding-cn` entries in medium-tier chains now say `:high` explicitly, judgment-tier chains keep `:xhigh` (→ "max"), and the `openrouter/z-ai/glm-5.2` mirror — which only maps `:xhigh` — is now always `:xhigh` instead of unsupported `:medium`.
22
+
23
+ ## [0.9.4-alpha.8] - 2026-07-02
24
+
25
+ ### Changed
26
+
27
+ - Changed the Claude Fable 5 reasoning level from `xhigh` to `high` across all builtin workflow model chains (`ralph` prompt-engineer/reviewer-a/reviewer-b/reviewer-c, `goal` reviewer, `deep-research-codebase` planner, and `open-claude-design`), covering both the native `anthropic/claude-fable-5` entries and their OpenRouter mirrors.
28
+
29
+ ### Fixed
30
+
31
+ - Fixed the builtin `goal` reviewer and `deep-research-codebase` planner model fallback chains missing the OpenRouter mirror of their primary model: `openrouter/anthropic/claude-fable-5` is now the first OpenRouter fallback candidate in both chains, matching the ordering already used by the `ralph` prompt-engineer/reviewer and `open-claude-design` chains.
32
+
33
+ ## [0.9.4-alpha.7] - 2026-07-02
34
+
35
+ ### Fixed
36
+
37
+ - Fixed workflow stage model fallback so request/context incompatibility failures (HTTP 400/413/422 bad/unprocessable/payload-too-large request, unsupported tool/parameter, context-length/context-window overflow, `invalid_request`/`bad_request`/`too_large` errors) advance the chain to the next candidate instead of stopping. When none of the configured candidates can serve the request, the stage now falls back to the current user-selected model. Refusals, content-filter/safety blocks, cancellations, and task failures still stop the chain ([#1580](https://github.com/bastani-inc/atomic/issues/1580)).
38
+
39
+ ## [0.9.4-alpha.6] - 2026-07-01
40
+
41
+ ### Changed
42
+
43
+ - Aligned the workflows extension peer dependency with upstream pi TUI `^0.80.3`; no workflows extension source changes were needed for this metadata sync.
44
+
45
+ ## [0.9.4-alpha.5] - 2026-07-01
46
+
47
+ ### Changed
48
+
49
+ - Published a synchronized Atomic 0.9.4-alpha.5 prerelease for the workflows extension; no workflow changes were made after 0.9.4-alpha.3.
50
+
51
+ ## [0.9.4-alpha.4] - 2026-06-30
52
+
53
+ ### Changed
54
+
55
+ - Published a synchronized Atomic 0.9.4-alpha.4 prerelease for the workflows extension; no workflow changes were made after 0.9.4-alpha.3.
56
+
57
+ ## [0.9.4-alpha.3] - 2026-06-30
58
+
59
+ ### Fixed
60
+
61
+ - Classified generic provider `Connection error.` / `fetch failed` transport outages as explicit workflow transport errors so stage fallback metadata can distinguish them from ordinary provider/model outages while preserving the normal next-model fallback order.
62
+
9
63
  ## [0.9.4-alpha.1] - 2026-06-29
10
64
 
11
65
  ### Fixed
@@ -31,41 +31,43 @@ export interface DeepResearchCodebaseResult {
31
31
 
32
32
  export const FILE_ONLY_OUTPUT = "file-only" satisfies WorkflowOutputMode;
33
33
 
34
+ // Chains curated from Atomic's agentic-coding benchmark (see ralph-models.ts
35
+ // for the frontier data and placement principle: only reviewers get
36
+ // best-in-class models; the planner is a perf-per-dollar stage).
34
37
  export const PLANNER_MODEL_CONFIG = {
35
- model: "anthropic/claude-fable-5:xhigh",
38
+ model: "openai-codex/gpt-5.5:xhigh",
36
39
  fallbackModels: [
37
- "openai-codex/gpt-5.5:xhigh",
38
40
  "github-copilot/gpt-5.5:xhigh",
39
41
  "openai/gpt-5.5:xhigh",
40
- "github-copilot/claude-opus-4.8 (1m):xhigh",
41
- "anthropic/claude-opus-4-8:xhigh",
42
+ "anthropic/claude-fable-5:xhigh",
43
+ "github-copilot/claude-opus-4.8 (1m):high",
44
+ "anthropic/claude-opus-4-8:high",
42
45
  "zai/glm-5.2:xhigh",
43
46
  "zai-coding-cn/glm-5.2:xhigh",
44
- "github-copilot/gemini-3.5-flash (1m):high",
45
- "google/gemini-3.5-flash:high",
46
- "google-vertex/gemini-3.5-flash:high",
47
- "github-copilot/gemini-3.1-pro-preview (1m):high",
48
- "google/gemini-3.1-pro-preview:high",
49
- "google-vertex/gemini-3.1-pro-preview:high",
50
47
  "openrouter/openai/gpt-5.5:xhigh",
51
- "openrouter/anthropic/claude-opus-4-8:xhigh",
52
- "openrouter/z-ai/glm-5.2:xhigh",
53
- "openrouter/google/gemini-3.5-flash:high",
54
- "openrouter/google/gemini-3.1-pro-preview:high"
48
+ "openrouter/anthropic/claude-fable-5:xhigh",
49
+ "openrouter/anthropic/claude-opus-4-8:high",
50
+ "openrouter/z-ai/glm-5.2:xhigh"
55
51
  ],
56
52
  excludedTools: ["ask_user_question"],
57
53
  } as const;
58
54
 
55
+ // gpt-5.5:low is the measured cheap-tier diamond ($1.20/task, 28 steps, 9.4k
56
+ // output tokens). Benchmark-measured models only: opus-4.8:low (41%/$2.29)
57
+ // and glm-5.2:high (36%/$2.84) back it up; unbenchmarked minis/haiku/flash
58
+ // are excluded.
59
59
  export const EXPLORER_MODEL_CONFIG = {
60
- model: "openai-codex/gpt-5.4-mini:low",
60
+ model: "openai-codex/gpt-5.5:low",
61
61
  fallbackModels: [
62
- "github-copilot/gpt-5.4-mini:low",
63
- "openai/gpt-5.4-mini:low",
64
- "github-copilot/claude-haiku-4.5:low",
65
- "anthropic/claude-haiku-4-5:low",
66
- "github-copilot/gemini-3.5-flash (1m):low",
67
- "google/gemini-3.5-flash:low",
68
- "google-vertex/gemini-3.5-flash:low",
62
+ "github-copilot/gpt-5.5:low",
63
+ "openai/gpt-5.5:low",
64
+ "github-copilot/claude-opus-4.8 (1m):low",
65
+ "anthropic/claude-opus-4-8:low",
66
+ "zai/glm-5.2:high",
67
+ "zai-coding-cn/glm-5.2:high",
68
+ "openrouter/openai/gpt-5.5:low",
69
+ "openrouter/anthropic/claude-opus-4-8:low",
70
+ "openrouter/z-ai/glm-5.2:xhigh",
69
71
  ],
70
72
  excludedTools: ["ask_user_question"],
71
73
  } as const;
@@ -92,26 +92,22 @@ export async function runGoalWorkflow(ctx: GoalRunnerContext, options: GoalWorkf
92
92
  const comparisonBaseBranch = normalizeBranchInput(inputs.base_branch, "origin/main");
93
93
  const { ledger, ledgerPath, artifactDir } = await createGoalLedger(objective);
94
94
 
95
+ // Chains curated from Atomic's agentic-coding benchmark (see
96
+ // ralph-models.ts for the frontier data and drop rationale).
95
97
  const workerModelConfig = {
96
98
  model: "openai-codex/gpt-5.5:medium",
97
99
  fallbackModels: [
98
100
  "github-copilot/gpt-5.5:medium",
99
101
  "openai/gpt-5.5:medium",
102
+ "anthropic/claude-fable-5:low",
100
103
  "github-copilot/claude-opus-4.8 (1m):medium",
101
104
  "anthropic/claude-opus-4-8:medium",
102
- "zai/glm-5.2:medium",
103
- "zai-coding-cn/glm-5.2:medium",
104
- "github-copilot/gemini-3.5-flash (1m):medium",
105
- "google/gemini-3.5-flash:medium",
106
- "google-vertex/gemini-3.5-flash:medium",
107
- "github-copilot/gemini-3.1-pro-preview (1m):medium",
108
- "google/gemini-3.1-pro-preview:medium",
109
- "google-vertex/gemini-3.1-pro-preview:medium",
105
+ "zai/glm-5.2:high",
106
+ "zai-coding-cn/glm-5.2:high",
110
107
  "openrouter/openai/gpt-5.5:medium",
108
+ "openrouter/anthropic/claude-fable-5:low",
111
109
  "openrouter/anthropic/claude-opus-4-8:medium",
112
- "openrouter/z-ai/glm-5.2:medium",
113
- "openrouter/google/gemini-3.5-flash:medium",
114
- "openrouter/google/gemini-3.1-pro-preview:medium"
110
+ "openrouter/z-ai/glm-5.2:xhigh"
115
111
  ],
116
112
  tools: goalRunnerTools,
117
113
  };
@@ -122,21 +118,14 @@ export async function runGoalWorkflow(ctx: GoalRunnerContext, options: GoalWorkf
122
118
  "openai-codex/gpt-5.5:xhigh",
123
119
  "github-copilot/gpt-5.5:xhigh",
124
120
  "openai/gpt-5.5:xhigh",
125
- "github-copilot/claude-opus-4.8 (1m):xhigh",
126
- "anthropic/claude-opus-4-8:xhigh",
121
+ "github-copilot/claude-opus-4.8 (1m):high",
122
+ "anthropic/claude-opus-4-8:high",
127
123
  "zai/glm-5.2:xhigh",
128
124
  "zai-coding-cn/glm-5.2:xhigh",
129
- "github-copilot/gemini-3.5-flash (1m):high",
130
- "google/gemini-3.5-flash:high",
131
- "google-vertex/gemini-3.5-flash:high",
132
- "github-copilot/gemini-3.1-pro-preview (1m):high",
133
- "google/gemini-3.1-pro-preview:high",
134
- "google-vertex/gemini-3.1-pro-preview:high",
125
+ "openrouter/anthropic/claude-fable-5:xhigh",
135
126
  "openrouter/openai/gpt-5.5:xhigh",
136
- "openrouter/anthropic/claude-opus-4-8:xhigh",
137
- "openrouter/z-ai/glm-5.2:xhigh",
138
- "openrouter/google/gemini-3.5-flash:high",
139
- "openrouter/google/gemini-3.1-pro-preview:high"
127
+ "openrouter/anthropic/claude-opus-4-8:high",
128
+ "openrouter/z-ai/glm-5.2:xhigh"
140
129
  ],
141
130
  tools: goalRunnerTools,
142
131
  schema: reviewDecisionSchema,
@@ -74,6 +74,9 @@ export async function runOpenClaudeDesignWorkflow(ctx: OpenClaudeDesignContext):
74
74
  });
75
75
  }
76
76
 
77
+ // Anthropic-heavy chain for design taste; sonnet-5/sonnet-4.6 dropped as
78
+ // strictly dominated in Atomic's benchmark (see ralph-models.ts). Opus stays
79
+ // at :xhigh here — visual quality, not $/task, is the objective for design.
77
80
  const designModelConfig = {
78
81
  model: "anthropic/claude-fable-5:xhigh",
79
82
  fallbackModels: [
@@ -81,12 +84,9 @@ export async function runOpenClaudeDesignWorkflow(ctx: OpenClaudeDesignContext):
81
84
  "anthropic/claude-opus-4-8:xhigh",
82
85
  "zai/glm-5.2:xhigh",
83
86
  "zai-coding-cn/glm-5.2:xhigh",
84
- "github-copilot/claude-sonnet-4.6 (1m):high",
85
- "anthropic/claude-sonnet-4-6:high",
86
87
  "openrouter/anthropic/claude-fable-5:xhigh",
87
88
  "openrouter/anthropic/claude-opus-4-8:xhigh",
88
- "openrouter/z-ai/glm-5.2:xhigh",
89
- "openrouter/anthropic/claude-sonnet-4-6:high"
89
+ "openrouter/z-ai/glm-5.2:xhigh"
90
90
  ],
91
91
  };
92
92
  // Phase 1: combined discovery + init — one stage interviews the user via