@bastani/atomic 0.10.18-alpha.1 → 0.10.19-alpha.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 (369) hide show
  1. package/CHANGELOG.md +79 -0
  2. package/README.md +27 -5
  3. package/dist/_shared/config-binary-install-SNFYFXWB.js +70 -0
  4. package/dist/_shared/config-binary-install-SNFYFXWB.js.map +1 -0
  5. package/dist/_shared/dist-KOELCESV.js +2 -2
  6. package/dist/_shared/fork-row-index-UAUAQRD5.js +2 -2
  7. package/dist/_shared/lib-4PES5P4V.js +2 -2
  8. package/dist/_shared/{mode-interactive-sdk-7KXUFI2F.js → mode-interactive-sdk-JXBZ3H27.js} +434 -11
  9. package/dist/_shared/mode-interactive-sdk-JXBZ3H27.js.map +1 -0
  10. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +21 -6
  11. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js.map +1 -1
  12. package/dist/_shared/mode-shared-2QJSCUM6.js +7 -6
  13. package/dist/_shared/mode-shared-2QJSCUM6.js.map +1 -1
  14. package/dist/_shared/p0-cli-BB45ZQY6.js +56 -3
  15. package/dist/_shared/p0-cli-BB45ZQY6.js.map +1 -1
  16. package/dist/_shared/p1a-prewarm-XIU57JHF.js +3 -3
  17. package/dist/_shared/runtime-O4KCSG4C.js +3 -3
  18. package/dist/_shared/{sdk-OHKMDJ74.js → sdk-BHX35EPK.js} +47 -17
  19. package/dist/_shared/sdk-BHX35EPK.js.map +1 -0
  20. package/dist/_shared/session-data-AHTU7IS6.js +2 -2
  21. package/dist/_shared/session-manager-list-2BLEEZVG.js +1 -1
  22. package/dist/_shared/{startup-0-0-OV6RAEAP.js → startup-0-0-4EDVBK5P.js} +464 -7
  23. package/dist/_shared/startup-0-0-4EDVBK5P.js.map +1 -0
  24. package/dist/_shared/{startup-0-1-EZAJI6RE.js → startup-0-1-H5IXVRXQ.js} +85 -7
  25. package/dist/_shared/startup-0-1-H5IXVRXQ.js.map +1 -0
  26. package/dist/_shared/startup-0-2-YZZOC22D.js +4 -4
  27. package/dist/_shared/startup-0-3-DE2NCS6A.js +4 -4
  28. package/dist/_shared/startup-0-4-ZMJV547D.js +6 -5
  29. package/dist/_shared/startup-0-4-ZMJV547D.js.map +1 -1
  30. package/dist/_shared/startup-0-5-HZX3ZPTP.js +44 -13
  31. package/dist/_shared/startup-0-5-HZX3ZPTP.js.map +1 -1
  32. package/dist/_shared/startup-10-0-TDQNBDDL.js +5 -5
  33. package/dist/_shared/startup-12-0-55AAXBJZ.js +2 -2
  34. package/dist/_shared/startup-14-0-MLX36RBG.js +3 -3
  35. package/dist/_shared/startup-15-0-YUKGAC63.js +3 -3
  36. package/dist/_shared/{startup-15-1-4S7FLMNG.js → startup-15-1-WQZBOTMZ.js} +70 -28
  37. package/dist/_shared/{startup-15-1-4S7FLMNG.js.map → startup-15-1-WQZBOTMZ.js.map} +1 -1
  38. package/dist/_shared/startup-8-0-34CBHPZH.js +4 -4
  39. package/dist/_shared/{startup-8-1-LZFXSD3Z.js → startup-8-1-QZMXUGHI.js} +242 -20
  40. package/dist/_shared/startup-8-1-QZMXUGHI.js.map +1 -0
  41. package/dist/_shared/storage-command-7MGXLJGZ.js +75 -11
  42. package/dist/_shared/storage-command-7MGXLJGZ.js.map +1 -1
  43. package/dist/_shared/storage-status-K7PX2RXA.js +3 -3
  44. package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
  45. package/dist/_shared/team-DOQKICG2.js +2 -2
  46. package/dist/_shared/tree-outline-MUEPK5B7.js +2 -2
  47. package/dist/binary-self-update.js +281 -0
  48. package/dist/binary-self-update.js.map +1 -0
  49. package/dist/builtin/intercom/broker/broker.bundle.mjs +158 -78
  50. package/dist/builtin/intercom/broker/multinode-router.ts +41 -8
  51. package/dist/builtin/intercom/broker/multinode-state-store.ts +6 -1
  52. package/dist/builtin/intercom/broker/sql-lease-store.ts +89 -80
  53. package/dist/builtin/intercom/broker/sql-pending-ask-store.ts +65 -6
  54. package/dist/builtin/intercom/index.bundle.mjs +2 -1
  55. package/dist/builtin/intercom/package.json +1 -1
  56. package/dist/builtin/mcp/index.bundle.mjs +1 -1
  57. package/dist/builtin/mcp/package.json +1 -1
  58. package/dist/builtin/subagents/CHANGELOG.md +15 -0
  59. package/dist/builtin/subagents/package.json +1 -1
  60. package/dist/builtin/subagents/skills/agent-browser/SKILL.md +1 -1
  61. package/dist/builtin/subagents/skills/impeccable/SKILL.md +3 -3
  62. package/dist/builtin/subagents/skills/impeccable/reference/audit.md +2 -2
  63. package/dist/builtin/subagents/skills/impeccable/reference/critique.md +3 -3
  64. package/dist/builtin/subagents/skills/impeccable/reference/generate.md +1 -1
  65. package/dist/builtin/subagents/skills/impeccable/reference/init.md +0 -2
  66. package/dist/builtin/subagents/skills/impeccable/reference/live.md +4 -2
  67. package/dist/builtin/subagents/skills/impeccable/reference/new-work-comp.md +1 -1
  68. package/dist/builtin/subagents/skills/impeccable/reference/new-work-world.md +1 -1
  69. package/dist/builtin/subagents/skills/impeccable/scripts/VERSION +1 -1
  70. package/dist/builtin/subagents/skills/impeccable/scripts/engine-checksums.txt +5 -5
  71. package/dist/builtin/subagents/skills/impeccable/scripts/impeccable +28 -5
  72. package/dist/builtin/subagents/skills/impeccable/scripts/impeccable.cmd +11 -2
  73. package/dist/builtin/subagents/skills/impeccable/scripts/live-browser.js +10 -6
  74. package/dist/builtin/subagents/skills/research-codebase/SKILL.md +13 -19
  75. package/dist/builtin/subagents/skills/skill-creator/SKILL.md +1 -1
  76. package/dist/builtin/subagents/skills/subagent/SKILL.md +7 -7
  77. package/dist/builtin/subagents/skills/workflow/SKILL.md +98 -0
  78. package/dist/builtin/subagents/src/extension/index.bundle.mjs +2 -1
  79. package/dist/builtin/web-access/index.bundle.mjs +2 -1
  80. package/dist/builtin/web-access/package.json +1 -1
  81. package/dist/cli/args.js +2 -2
  82. package/dist/cli/auth-cli.code.js +3 -3
  83. package/dist/cli/auth-cli.impl.js +3 -3
  84. package/dist/cli/auth-cli.js +3 -3
  85. package/dist/cli/blueprint-command.code.js +2 -2
  86. package/dist/cli/blueprint-command.impl.js +3 -3
  87. package/dist/cli/blueprint-command.js +3 -3
  88. package/dist/cli/intercom-command.code.js +2 -2
  89. package/dist/cli/intercom-command.impl.js +3 -3
  90. package/dist/cli/intercom-command.js +3 -3
  91. package/dist/cli/list-models.code.js +2 -2
  92. package/dist/cli/list-models.impl.js +3 -3
  93. package/dist/cli/list-models.js +3 -3
  94. package/dist/cli/session-picker.code.js +1 -1
  95. package/dist/cli/session-picker.impl.js +3 -3
  96. package/dist/cli/session-picker.js +3 -3
  97. package/dist/cli/startup-ui.code.js +1 -1
  98. package/dist/cli/startup-ui.impl.js +3 -3
  99. package/dist/cli/startup-ui.js +3 -3
  100. package/dist/cli/storage-command.impl.js +3 -3
  101. package/dist/cli/storage-command.js +3 -3
  102. package/dist/cli/storage-search-session.code.js +3 -3
  103. package/dist/cli/storage-search-session.impl.js +3 -3
  104. package/dist/cli/storage-search-session.js +3 -3
  105. package/dist/cli/team-command.code.js +1 -1
  106. package/dist/cli/team-command.impl.js +3 -3
  107. package/dist/cli/team-command.js +3 -3
  108. package/dist/cli/usage-command.js +22 -0
  109. package/dist/cli/usage-command.js.map +1 -0
  110. package/dist/cli.js +2 -2
  111. package/dist/config-binary-install.js +3 -0
  112. package/dist/config-binary-install.js.map +1 -0
  113. package/dist/core/agent-session-services.js +3 -0
  114. package/dist/core/agent-session-services.js.map +1 -0
  115. package/dist/core/debug.impl.js +3 -3
  116. package/dist/core/debug.js +3 -3
  117. package/dist/core/export-html/card-projection.impl.js +3 -3
  118. package/dist/core/export-html/card-projection.js +3 -3
  119. package/dist/core/export-html/index.code.js +2 -2
  120. package/dist/core/export-html/index.impl.js +3 -3
  121. package/dist/core/export-html/index.js +3 -3
  122. package/dist/core/export-html/json-spans.impl.js +3 -3
  123. package/dist/core/export-html/json-spans.js +3 -3
  124. package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
  125. package/dist/core/export-html/oversized-render-inputs.js +3 -3
  126. package/dist/core/export-html/tool-renderer.impl.js +3 -3
  127. package/dist/core/export-html/tool-renderer.js +3 -3
  128. package/dist/core/extensions/jiti-loader.impl.js +3 -3
  129. package/dist/core/extensions/jiti-loader.js +3 -3
  130. package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
  131. package/dist/core/extensions/jiti-static-loader.js +3 -3
  132. package/dist/core/extensions/loader-host-modules.code.js +1 -1
  133. package/dist/core/extensions/loader-host-modules.impl.js +3 -3
  134. package/dist/core/extensions/loader-host-modules.js +3 -3
  135. package/dist/core/extensions/loader-virtual-modules.js +1 -1
  136. package/dist/core/extensions/runner-context.js +2 -2
  137. package/dist/core/intercom-broker-control-host.code.js +1 -1
  138. package/dist/core/intercom-broker-control-host.impl.js +3 -3
  139. package/dist/core/intercom-broker-control-host.js +3 -3
  140. package/dist/core/intercom-broker-control.code.js +3 -3
  141. package/dist/core/intercom-broker-control.impl.js +3 -3
  142. package/dist/core/intercom-broker-control.js +3 -3
  143. package/dist/core/{legacy-workflow-files.d.ts → legacy-workflows.d.ts} +1 -1
  144. package/dist/core/model-runtime.d.ts +8 -2
  145. package/dist/core/package-manager-storage-adapters.code.js +1 -1
  146. package/dist/core/package-manager-storage-adapters.impl.js +3 -3
  147. package/dist/core/package-manager-storage-adapters.js +3 -3
  148. package/dist/core/resource-loader-core.d.ts +1 -1
  149. package/dist/core/resource-loader-internals.d.ts +1 -1
  150. package/dist/core/resource-loader-types.d.ts +1 -1
  151. package/dist/core/resource-loader-types.js.map +1 -1
  152. package/dist/core/sdk.code.js +4 -4
  153. package/dist/core/sdk.impl.js +3 -3
  154. package/dist/core/sdk.js +3 -3
  155. package/dist/core/session-manager-core.js +5 -5
  156. package/dist/core/session-manager-list.impl.js +3 -3
  157. package/dist/core/session-manager-list.js +3 -3
  158. package/dist/core/session-manager.code.js +1 -1
  159. package/dist/core/session-manager.impl.js +3 -3
  160. package/dist/core/session-manager.js +3 -3
  161. package/dist/core/session-storage.code.js +1 -1
  162. package/dist/core/session-storage.impl.js +3 -3
  163. package/dist/core/session-storage.js +3 -3
  164. package/dist/core/settings-manager.js +5 -0
  165. package/dist/core/settings-manager.js.map +1 -0
  166. package/dist/core/storage/database.d.ts +6 -2
  167. package/dist/core/storage/database.js.map +1 -1
  168. package/dist/core/storage/fenced-paths.d.ts +15 -0
  169. package/dist/core/storage/fenced-paths.js +25 -0
  170. package/dist/core/storage/fenced-paths.js.map +1 -1
  171. package/dist/core/storage/index.js +2 -2
  172. package/dist/core/storage/migrations.d.ts +2 -11
  173. package/dist/core/storage/migrations.js +2 -9
  174. package/dist/core/storage/migrations.js.map +1 -1
  175. package/dist/core/storage/node-sqlite-thread.js +2 -2
  176. package/dist/core/storage/node-sqlite.js +2 -2
  177. package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
  178. package/dist/core/storage/offline-snapshot-file.js +3 -3
  179. package/dist/core/storage/postgres-locks.d.ts +11 -0
  180. package/dist/core/storage/postgres-locks.js +9 -0
  181. package/dist/core/storage/postgres-locks.js.map +1 -0
  182. package/dist/core/storage/provider.js +2 -2
  183. package/dist/core/storage/selection.js +2 -2
  184. package/dist/core/storage/session/branch-fork-source.code.js +2 -2
  185. package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
  186. package/dist/core/storage/session/branch-fork-source.js +3 -3
  187. package/dist/core/storage/session/card-view.impl.js +3 -3
  188. package/dist/core/storage/session/card-view.js +3 -3
  189. package/dist/core/storage/session/child-reader.code.js +3 -3
  190. package/dist/core/storage/session/child-reader.impl.js +3 -3
  191. package/dist/core/storage/session/child-reader.js +3 -3
  192. package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
  193. package/dist/core/storage/session/chunked-resume-projection.js +3 -3
  194. package/dist/core/storage/session/expanded-child-details.code.js +2 -2
  195. package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
  196. package/dist/core/storage/session/expanded-child-details.js +3 -3
  197. package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
  198. package/dist/core/storage/session/fork-row-bytes.js +3 -3
  199. package/dist/core/storage/session/fork-row-index.impl.js +3 -3
  200. package/dist/core/storage/session/fork-row-index.js +3 -3
  201. package/dist/core/storage/session/fork-staging.code.js +2 -2
  202. package/dist/core/storage/session/fork-staging.impl.js +3 -3
  203. package/dist/core/storage/session/fork-staging.js +3 -3
  204. package/dist/core/storage/session/fork-window.code.js +3 -3
  205. package/dist/core/storage/session/fork-window.impl.js +3 -3
  206. package/dist/core/storage/session/fork-window.js +3 -3
  207. package/dist/core/storage/session/history-pages.impl.js +3 -3
  208. package/dist/core/storage/session/history-pages.js +3 -3
  209. package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
  210. package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
  211. package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
  212. package/dist/core/storage/session/jsonl-session-store.js +3 -3
  213. package/dist/core/storage/session/memory-session-store.impl.js +3 -3
  214. package/dist/core/storage/session/memory-session-store.js +3 -3
  215. package/dist/core/storage/session/pinned-branch-resume.code.js +3 -3
  216. package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
  217. package/dist/core/storage/session/pinned-branch-resume.js +3 -3
  218. package/dist/core/storage/session/released-history-files.code.js +2 -2
  219. package/dist/core/storage/session/released-history-files.impl.js +3 -3
  220. package/dist/core/storage/session/released-history-files.js +3 -3
  221. package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
  222. package/dist/core/storage/session/resident-fork-rows.js +3 -3
  223. package/dist/core/storage/session/session-resume.impl.js +3 -3
  224. package/dist/core/storage/session/session-resume.js +3 -3
  225. package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
  226. package/dist/core/storage/session/snapshot-cut.js +3 -3
  227. package/dist/core/storage/session/snapshot-history.code.js +3 -3
  228. package/dist/core/storage/session/snapshot-history.impl.js +3 -3
  229. package/dist/core/storage/session/snapshot-history.js +3 -3
  230. package/dist/core/storage/session/sql-session-store.code.js +1 -1
  231. package/dist/core/storage/session/sql-session-store.d.ts +1 -1
  232. package/dist/core/storage/session/sql-session-store.impl.js +3 -3
  233. package/dist/core/storage/session/sql-session-store.js +3 -3
  234. package/dist/core/storage/session/tree-outline.impl.js +3 -3
  235. package/dist/core/storage/session/tree-outline.js +3 -3
  236. package/dist/core/storage/session/tree-presentation.impl.js +3 -3
  237. package/dist/core/storage/session/tree-presentation.js +3 -3
  238. package/dist/core/storage/sqlite-facade.js +6 -4
  239. package/dist/core/storage/sqlite-facade.js.map +1 -1
  240. package/dist/core/storage/storage-status.impl.js +3 -3
  241. package/dist/core/storage/storage-status.js +3 -3
  242. package/dist/core/storage/team.impl.js +3 -3
  243. package/dist/core/storage/team.js +3 -3
  244. package/dist/core/structured-output/index.code.js +1 -1
  245. package/dist/core/structured-output/index.impl.js +3 -3
  246. package/dist/core/structured-output/index.js +3 -3
  247. package/dist/core/subscription-usage-credential.d.ts +2 -0
  248. package/dist/core/subscription-usage-endpoints.d.ts +54 -0
  249. package/dist/core/subscription-usage.d.ts +55 -0
  250. package/dist/core/subscription-usage.js +3 -0
  251. package/dist/core/subscription-usage.js.map +1 -0
  252. package/dist/core/tasks/heartbeat-notice.d.ts +0 -1
  253. package/dist/core/tasks/task-completion-entry.impl.js +3 -3
  254. package/dist/core/tasks/task-completion-entry.js +3 -3
  255. package/dist/core/tasks/task-file-history.code.js +3 -3
  256. package/dist/core/tasks/task-file-history.impl.js +3 -3
  257. package/dist/core/tasks/task-file-history.js +3 -3
  258. package/dist/core/tasks/task-reference-archive.code.js +4 -4
  259. package/dist/core/tasks/task-reference-archive.js +3 -3
  260. package/dist/core/tasks/task-reference-identity.js +3 -3
  261. package/dist/core/tasks/task-reference-stream.impl.js +3 -3
  262. package/dist/core/tasks/task-reference-stream.js +3 -3
  263. package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
  264. package/dist/core/tasks/task-unsaved-answer.js +3 -3
  265. package/dist/core/tasks/task-view-source.code.js +1 -1
  266. package/dist/core/tasks/task-view-source.impl.js +3 -3
  267. package/dist/core/tasks/task-view-source.js +3 -3
  268. package/dist/core/tools/edit-diff.d.ts +4 -6
  269. package/dist/core/tools/read-url.code.js +3 -3
  270. package/dist/core/tools/read-url.impl.js +3 -3
  271. package/dist/core/tools/read-url.js +3 -3
  272. package/dist/core/worktree-snapshot/blob-store.d.ts +14 -16
  273. package/dist/core/worktree-snapshot/blob-store.js +194 -81
  274. package/dist/core/worktree-snapshot/blob-store.js.map +1 -1
  275. package/dist/core/worktree-snapshot/collection-claim.js +8 -0
  276. package/dist/core/worktree-snapshot/collection-claim.js.map +1 -0
  277. package/dist/core/worktree-snapshot/errors.code.js +2 -2
  278. package/dist/core/worktree-snapshot/errors.impl.js +3 -3
  279. package/dist/core/worktree-snapshot/errors.js +3 -3
  280. package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
  281. package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
  282. package/dist/core/worktree-snapshot/snapshot-epoch-migration.js +209 -0
  283. package/dist/core/worktree-snapshot/snapshot-epoch-migration.js.map +1 -0
  284. package/dist/core/worktree-snapshot/snapshot-epoch.js +100 -0
  285. package/dist/core/worktree-snapshot/snapshot-epoch.js.map +1 -0
  286. package/dist/extensions/codemode/execute.code.js +1 -1
  287. package/dist/extensions/codemode/execute.impl.js +3 -3
  288. package/dist/extensions/codemode/execute.js +3 -3
  289. package/dist/extensions/codemode/renderer.code.js +2 -2
  290. package/dist/extensions/codemode/renderer.impl.js +3 -3
  291. package/dist/extensions/codemode/renderer.js +3 -3
  292. package/dist/extensions/mcp/cli.code.js +2 -2
  293. package/dist/extensions/mcp/cli.impl.js +3 -3
  294. package/dist/extensions/mcp/cli.js +3 -3
  295. package/dist/extensions/mcp/cli.lazy.code.js +2 -2
  296. package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
  297. package/dist/extensions/mcp/cli.lazy.js +3 -3
  298. package/dist/extensions/mcp/runtime.code.js +1 -1
  299. package/dist/extensions/mcp/runtime.impl.js +3 -3
  300. package/dist/extensions/mcp/runtime.js +3 -3
  301. package/dist/index.d.ts +3 -0
  302. package/dist/index.js +7 -7
  303. package/dist/main-first-time-setup.code.js +1 -1
  304. package/dist/main-first-time-setup.impl.js +3 -3
  305. package/dist/main-first-time-setup.js +3 -3
  306. package/dist/main.js +2 -2
  307. package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
  308. package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
  309. package/dist/modes/interactive/components/stored-tree-view.js +3 -3
  310. package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
  311. package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
  312. package/dist/modes/interactive/interactive-mode-surface.d.ts +1 -0
  313. package/dist/modes/interactive/interactive-mode-surface.js.map +1 -1
  314. package/dist/modes/interactive/interactive-mode.js +1 -1
  315. package/dist/modes/interactive-engine/isolated-runtime.d.ts +3 -0
  316. package/dist/modes/print-mode.js +1 -1
  317. package/dist/modes/rpc/rpc-client-api.d.ts +3 -0
  318. package/dist/modes/rpc/rpc-types.d.ts +25 -0
  319. package/dist/package-manager-cli.code.js +31 -8
  320. package/dist/package-manager-cli.code.js.map +1 -1
  321. package/dist/package-manager-cli.impl.js +3 -3
  322. package/dist/package-manager-cli.js +3 -3
  323. package/dist/rpc-entry.js +2 -2
  324. package/dist/startup-files.json +1 -1
  325. package/dist/startup-stages/12.js +1 -1
  326. package/dist/startup-stages/4.js +1 -1
  327. package/dist/startup-stages/6.js +1 -1
  328. package/dist/subscription-usage-sdk.d.ts +9 -0
  329. package/dist/utils/changelog.d.ts +1 -0
  330. package/dist/utils/startup-database-spare.code.js +2 -2
  331. package/dist/utils/startup-database-spare.impl.js +3 -3
  332. package/dist/utils/startup-database-spare.js +3 -3
  333. package/dist/utils/tools-manager.code.js +1 -1
  334. package/dist/utils/tools-manager.impl.js +3 -3
  335. package/dist/utils/tools-manager.js +3 -3
  336. package/docs/background-tasks/reference.md +1 -1
  337. package/docs/background-tasks.md +1 -1
  338. package/docs/changelog.mdx +53 -1
  339. package/docs/containerization.md +17 -15
  340. package/docs/docs.json +1 -0
  341. package/docs/getting-started/installation.md +132 -80
  342. package/docs/guides/subscription-usage.md +133 -0
  343. package/docs/guides/team-setup.md +14 -3
  344. package/docs/guides.md +3 -0
  345. package/docs/index.md +18 -6
  346. package/docs/intercom/operations.md +1 -1
  347. package/docs/orchestration/migrating-workflows.md +16 -10
  348. package/docs/orchestration/patterns.md +8 -2
  349. package/docs/orchestration.md +17 -8
  350. package/docs/quickstart.md +7 -15
  351. package/docs/reference/cli.md +32 -24
  352. package/docs/rpc/protocol.md +9 -1
  353. package/docs/rpc.md +1 -1
  354. package/docs/sdk/reference.md +5 -1
  355. package/docs/skills.md +20 -4
  356. package/docs/slash-commands.md +3 -2
  357. package/docs/storage/postgres/tuning.md +2 -0
  358. package/docs/storage/postgres.md +17 -0
  359. package/docs/tools.md +57 -12
  360. package/docs/usage.md +1 -0
  361. package/docs/windows.md +4 -4
  362. package/docs/worktree-snapshots/reference.md +1 -1
  363. package/package.json +9 -9
  364. package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js.map +0 -1
  365. package/dist/_shared/sdk-OHKMDJ74.js.map +0 -1
  366. package/dist/_shared/startup-0-0-OV6RAEAP.js.map +0 -1
  367. package/dist/_shared/startup-0-1-EZAJI6RE.js.map +0 -1
  368. package/dist/_shared/startup-8-1-LZFXSD3Z.js.map +0 -1
  369. package/dist/builtin/subagents/skills/workflow-files/SKILL.md +0 -28
@@ -0,0 +1,133 @@
1
+ ---
2
+ title: "Check subscription usage"
3
+ sidebarTitle: "Subscription usage"
4
+ description: "See how much of your AI subscriptions you have used and when the limits reset."
5
+ ---
6
+
7
+ Type `/usage` in Atomic to see how much of your subscription allowance is left and when it resets. You can check without interrupting a reply. **Current** marks the account selected in this session. Press `r` to check again, the arrow keys to scroll, or `Esc` to close.
8
+
9
+ ```text
10
+ Subscription usage
11
+
12
+ OpenAI Codex · Current · openai-codex
13
+ Session (5 h) █████░░░░░░░ 42.5% used Resets in 2 h 14 min · Sat 4:30 PM
14
+ Weekly (7 d) ██████████░░ 87% used Resets in 2 d 3 h · Mon 5:16 PM
15
+ Reset credits: 1 available
16
+ ```
17
+
18
+ A usage window is the period a provider's limit covers. In this example, `Session (5 h)` is the provider's five-hour window, not the current Atomic chat. The weekly bar shows 87% used, so 13% is left until the Monday reset. Atomic shows reset times in your terminal's local time.
19
+
20
+ Atomic shows only the windows your provider reports for your plan. A full bar means the account has reached that limit. If the provider offers reset credits, the report shows how many are available. Checking usage does not spend them or change settings. For token counts and costs for this Atomic session, use `/session` instead.
21
+
22
+ | Sign-in | What you can see |
23
+ | --- | --- |
24
+ | **OpenAI Codex** (`openai-codex`) | The short and weekly windows, extra model limits, plan, usage credits, and reset credits when reported. |
25
+ | **Anthropic Claude** (`anthropic`) | The five-hour and weekly windows, model-specific weekly windows such as Sonnet and Opus, and whether extra usage is on. Anthropic can bill use from tools like Atomic separately from what the Claude plan includes. |
26
+ | **Grok** (`xai`) | Weekly credits, per-product use, and monthly use on accounts with monthly billing. |
27
+ | **GitHub Copilot** (`github-copilot`) | Premium requests, chat, and completions if your plan reports them. Some of these may be unlimited. |
28
+ | **Kimi Code** (`kimi-coding`) | The short and longer limits Kimi reports for your plan, including separate code use when available. |
29
+ | **OpenRouter sign-in** (`openrouter`) | The sign-in’s credit cap, amount left, and spending in USD, not a subscription window. |
30
+ | **Sign in with ChatGPT for the OpenAI API** (`openai`) | Figures from the account’s last model response. If it did not report subscription windows, Atomic shows the request and token limits instead. For full plan windows, sign in through OpenAI Codex (`openai-codex`). |
31
+ | **Meta** | This sign-in does not report subscription usage. |
32
+
33
+ ### If an account has no usage numbers
34
+
35
+ Read the message below the account name. If a provider’s check fails, other accounts can still show their usage. Where possible, Atomic shows figures from a recent reply and marks them as older.
36
+
37
+ | What the report says | What it means and what to do |
38
+ | --- | --- |
39
+ | API key (`api_key`) | You pay for API use instead of using a subscription allowance. Check the provider’s billing dashboard. |
40
+ | No subscription figures (`unsupported`, `no_subscription`) | That provider or account does not make plan figures available to Atomic. Check its own usage page. |
41
+ | Not signed in (`not_signed_in`) or sign in again (`sign_in_again`) | There’s no saved sign-in for this account, or the provider rejected it. Use `/login` or `atomic auth login <provider>`. |
42
+ | Claude login lacks usage access (`needs_profile_scope`) | A setup token can run models but can’t read usage. Use `/login anthropic` or `atomic auth login anthropic` and complete the full Claude sign-in instead. If you set a setup token in your environment, remove it when switching. |
43
+ | No access (`forbidden`) | The provider did not grant this login permission to read its usage. Check the account’s permissions or its usage page. |
44
+ | No usage observed yet (`not_observed`) | Send a normal prompt with that ChatGPT sign-in, then reopen `/usage` or press `r`. The standalone CLI can’t read figures from an open session’s last reply; use RPC to check that session from a script. |
45
+ | Offline (`offline`) | Atomic did not contact the provider. Turn off offline mode and try again if you want a live check. |
46
+ | Too many checks (`rate_limited`) | Wait a little before trying again. |
47
+ | Timeout, connection, or provider error (`timeout`, `request_failed`, `http_error`, `malformed`) | The provider was unreachable, too slow, or returned a report Atomic could not read. Press `r` to retry; if it persists, check the provider’s own usage page. |
48
+
49
+ ## Check from a script
50
+
51
+ Use the text report in a terminal and the JSON report in scripts. Neither starts a chat.
52
+
53
+ ```bash
54
+ atomic usage
55
+ atomic usage --json
56
+ ```
57
+
58
+ Add `--offline` to list accounts without contacting providers. If you have not signed in, the text report tells you to run `atomic auth login`. The JSON report is `{"accounts":[]}`.
59
+
60
+ `--json` prints one JSON object. The command can succeed even if one account has no figures or a check fails. Read each account's `status` before using its data. To check an open session from an RPC client, send [`get_usage`](/rpc/protocol#get_usage).
61
+
62
+ ```json
63
+ {
64
+ "accounts": [
65
+ {
66
+ "provider": "openai-codex",
67
+ "name": "OpenAI Codex",
68
+ "current": true,
69
+ "status": "ready",
70
+ "source": "live",
71
+ "windows": [
72
+ { "label": "Session", "usedPercent": 42.5, "durationSeconds": 18000, "resetsAt": "2026-11-28T16:30:00.000Z" },
73
+ { "label": "Weekly", "usedPercent": 87, "durationSeconds": 604800, "resetsAt": "2026-11-30T17:16:00.000Z" }
74
+ ],
75
+ "resetCredits": 1
76
+ },
77
+ {
78
+ "provider": "anthropic",
79
+ "name": "Anthropic",
80
+ "current": false,
81
+ "status": "unavailable",
82
+ "reason": "needs_profile_scope",
83
+ "message": "This login lacks usage access (user:profile). Sign in to Claude again without a setup token."
84
+ }
85
+ ]
86
+ }
87
+ ```
88
+
89
+ ### JSON and SDK contract
90
+
91
+ `atomic usage --json` and the SDK return the same stable `SubscriptionUsageReport` structure. Credentials, tokens and raw provider responses are never part of the report. Fields described as optional are omitted when not reported; missing values do not mean zero. Consumers can ignore new fields or reason codes if added in the future.
92
+
93
+ | Field | Meaning |
94
+ | --- | --- |
95
+ | `accounts` | An array of results. It is empty if there are no accounts to check. |
96
+ | `provider`, `name`, `current` | `provider` is the account ID, such as `openai-codex`. `name` is the display name. `current` is `true` for the selected account in an open session or the configured default in a standalone report, if known. |
97
+ | `status` | `ready` means figures are available. `unavailable` explains why there are no figures. `failed` means the check did not complete. |
98
+ | `source`, `observedAt` | For a `ready` account, `live` means a provider usage check supplied the figures. Atomic can reuse those figures briefly. `recent_response` means a live check did not supply figures, so Atomic used a recent reply. `last_request` means the figures came from an ordinary reply without a separate usage check. `observedAt` on `last_request` is when Atomic saw those figures, in UTC. |
99
+ | `windows` | The limits the provider reported. Each has a `label` such as `Weekly`, a `usedPercent`, a length in seconds (`durationSeconds`), and a reset time in UTC (`resetsAt`). A percentage of `0` means unused, `100` means full, and some providers report more than `100`. Unknown lengths and reset times are `null`. |
100
+ | `rateLimits` | Optional limits from the last OpenAI API request, distinct from subscription windows. Each entry says whether it covers `requests` or `tokens` (`kind`), plus any `limit`, `remaining`, or `resetsAt` the provider reported. |
101
+ | `plan`, `resetCredits` | Optional. The provider’s plan name and the number of reset credits still available. |
102
+ | `credits`, `extraUsage` | Optional. `credits` describes ordinary usage credits: whether you have any (`available`), whether they’re unlimited (`unlimited`), and how many remain (`balance`). `extraUsage` says whether Claude’s paid extra use is on (`enabled`) and how much of it has been used (`usedPercent`), if known. |
103
+ | `creditCap`, `unlimitedWindows` | Optional. The OpenRouter cap (`limit`, or `null` if uncapped), dollars left (`remaining`), how often it resets (`reset`), and dollars used this day, week, or month (`dailyUsed`, `weeklyUsed`, `monthlyUsed`). `unlimitedWindows` lists any limits the provider reports as unlimited. |
104
+ | `reason`, `message` | On `unavailable`, `failed`, or `recent_response` results, a code for scripts and a plain explanation for people. |
105
+
106
+ The [account message table](#if-an-account-has-no-usage-numbers) explains the codes. If Atomic shows figures from a recent reply, `reason` still explains why the latest check did not return figures.
107
+
108
+ ## Check from the SDK
109
+
110
+ Install `@bastani/atomic` and import `getSubscriptionUsage`. It checks all configured accounts by default. Pass `accounts` to check selected IDs, `maxAgeMs: 0` to skip the cache (normally one minute), or `signal` to cancel the whole check. To include accounts registered only on an SDK session, pass `modelRuntime: session.modelRuntime`.
111
+
112
+ ```typescript
113
+ import { getSubscriptionUsage } from "@bastani/atomic";
114
+
115
+ const { accounts } = await getSubscriptionUsage({
116
+ accounts: ["openai-codex", "anthropic"],
117
+ signal: AbortSignal.timeout(10_000),
118
+ });
119
+
120
+ const byWeeklyCapacity = accounts.flatMap((account) => {
121
+ if (account.status !== "ready" || account.source !== "live") return [];
122
+ const weekly = account.windows.find((window) => window.label === "Weekly");
123
+ if (!weekly) return [];
124
+ return [{ provider: account.provider, remainingPercent: Math.max(0, 100 - weekly.usedPercent) }];
125
+ }).sort((a, b) => b.remainingPercent - a.remainingPercent);
126
+
127
+ if (byWeeklyCapacity.length) console.table(byWeeklyCapacity);
128
+ else console.log("No current weekly usage was reported.");
129
+ ```
130
+
131
+ This example compares weekly limits only. If OpenAI Codex reports 87% used, its row shows `13` under `remainingPercent`. It skips figures from earlier model replies.
132
+
133
+ The SDK call rejects if you cancel it or Atomic can't read the saved accounts. A problem with one provider appears in that account's result without rejecting the whole report.
@@ -95,6 +95,8 @@ Atomic validates `ATOMIC_STORAGE` at startup before opening a session and never
95
95
 
96
96
  ### GitHub Actions
97
97
 
98
+ Install Atomic with the native installer and add its launcher directory to `GITHUB_PATH` for later steps:
99
+
98
100
  ```yaml
99
101
  jobs:
100
102
  agent:
@@ -104,7 +106,10 @@ jobs:
104
106
  ATOMIC_DB_PASSWORD: ${{ secrets.ATOMIC_DB_PASSWORD }}
105
107
  steps:
106
108
  - uses: actions/checkout@v5
107
- - run: npm install -g @bastani/atomic
109
+ - name: Install Atomic
110
+ run: |
111
+ curl -fsSL https://raw.githubusercontent.com/bastani-inc/atomic/main/install.sh | sh
112
+ echo "$HOME/.local/bin" >> "$GITHUB_PATH"
108
113
  - run: atomic install npm:@bastani/atomic-storage-postgres
109
114
  - run: atomic -p "Fix the failing test in the checkout"
110
115
  ```
@@ -132,7 +137,10 @@ jobs:
132
137
  runs-on: ubuntu-latest
133
138
  steps:
134
139
  - uses: actions/checkout@v5
135
- - run: npm install -g @bastani/atomic
140
+ - name: Install Atomic
141
+ run: |
142
+ curl -fsSL https://raw.githubusercontent.com/bastani-inc/atomic/main/install.sh | sh
143
+ echo "$HOME/.local/bin" >> "$GITHUB_PATH"
136
144
  - id: keys
137
145
  run: atomic blueprint cache-key --format github-output >> "$GITHUB_OUTPUT"
138
146
  - run: atomic blueprint prebuild --park --approve # Runs blueprints to populate stores; trust only the default branch
@@ -160,7 +168,10 @@ In the agent job, restore those cache entries before launching Atomic:
160
168
 
161
169
  ```yaml
162
170
  - uses: actions/checkout@v5
163
- - run: npm install -g @bastani/atomic
171
+ - name: Install Atomic
172
+ run: |
173
+ curl -fsSL https://raw.githubusercontent.com/bastani-inc/atomic/main/install.sh | sh
174
+ echo "$HOME/.local/bin" >> "$GITHUB_PATH"
164
175
  - id: keys
165
176
  run: atomic blueprint cache-key --format github-output >> "$GITHUB_OUTPUT"
166
177
  - uses: actions/cache/restore@v4
package/docs/guides.md CHANGED
@@ -67,6 +67,9 @@ New to Atomic? Start with the [Quickstart](/quickstart) to install, authenticate
67
67
  <Card title="Choose a model" href="/models/choose-a-model">
68
68
  Decide between subscriptions, API keys, local models, and custom endpoints, and configure model cycling.
69
69
  </Card>
70
+ <Card title="Check subscription usage" href="/guides/subscription-usage">
71
+ Check limits and resets in the terminal, from a script, or with the SDK.
72
+ </Card>
70
73
  <Card title="Model providers" href="/providers">
71
74
  Connect subscription logins, API keys, and cloud gateways (Bedrock, Vertex AI, Azure, NIM).
72
75
  </Card>
package/docs/index.md CHANGED
@@ -12,14 +12,26 @@ Atomic is an extensible coding agent that runs in your terminal. Give it a goal
12
12
 
13
13
  ## Quick start
14
14
 
15
- Install with a package manager (requires [Node.js 24.20.0 or newer](/getting-started/installation#nodejs-version) at runtime) or use the self-contained [release archive](/getting-started/installation#release-archive) with no Node.js required:
15
+ ### Native install (recommended)
16
16
 
17
- ```bash
18
- npm install -g @bastani/atomic
19
- atomic
20
- ```
17
+ Run the command for your system:
21
18
 
22
- Sign in inside Atomic with `/login`, from your shell with `atomic auth login <provider>`, or by exporting an API key such as `ANTHROPIC_API_KEY`. Follow the [Quickstart](/quickstart) for the complete four-step walkthrough, or see [Install Atomic](/getting-started/installation) for pnpm, Bun, macOS/Linux/Windows archives, and troubleshooting.
19
+ <Tabs>
20
+ <Tab title="macOS, Linux, WSL">
21
+ ```bash
22
+ curl -fsSL https://raw.githubusercontent.com/bastani-inc/atomic/main/install.sh | sh
23
+ ```
24
+ </Tab>
25
+ <Tab title="Windows PowerShell">
26
+ ```powershell
27
+ irm https://raw.githubusercontent.com/bastani-inc/atomic/main/install.ps1 | iex
28
+ ```
29
+ </Tab>
30
+ </Tabs>
31
+
32
+ Open a new terminal, run `atomic`, then sign in with `/login`. Follow the [Quickstart](/quickstart) to run your first session.
33
+
34
+ If you installed with npm, pnpm, or Bun, see [Switch to the native installer](/getting-started/installation#switch-to-the-native-installer). If you still need a package manager, see [Advanced installation options](/getting-started/installation#advanced-installation-options).
23
35
 
24
36
  ## Start here
25
37
 
@@ -41,7 +41,7 @@ Sessions on one machine share a single local broker that keeps running after you
41
41
 
42
42
  - **Automatic handover.** When a session on a newer Atomic version finds an older compatible broker, it asks that broker to shut down, waits up to 1 minute for exit (older Windows brokers can take around 30 seconds with active sessions), and starts the new broker. Existing sessions reconnect automatically, keep their session IDs, and continue exchanging messages.
43
43
  - **When replacement fails.** If the older broker does not stop, uses a different shared storage selection, or speaks an incompatible protocol, the session leaves it running. Without multi-node storage, the session warns once and runs locally on the existing broker, failing only requests that require newer protocol features (`IntercomBrokerProtocolError`). With multi-node storage configured, the session refuses to register (`IntercomRoutingUnavailableError`) until you run `atomic intercom restart`.
44
- - **Installer and update hook.** Installers and `atomic update` finish by running `atomic intercom upgrade`, which stops an idle older broker immediately and leaves an active one for smooth handover by the next newer session. You can run `atomic intercom upgrade` manually after `npm install -g`.
44
+ - **Installer and update hook.** The [native installer](/getting-started/installation#release-archive) and `atomic update` run `atomic intercom upgrade`. This stops an idle older broker immediately. An active broker keeps running until the next session on the new version takes over. If you update directly with a package manager, run `atomic intercom upgrade` yourself.
45
45
 
46
46
  <Note>
47
47
  **Upgrading from Atomic 0.10.4 or earlier on Windows.** If `npm install -g @bastani/atomic` fails with `EBUSY` on `dist\builtin\intercom`, an older broker is holding that directory open. Close running Atomic sessions, wait 5 seconds (or run `atomic intercom restart`), and re-run the install. From 0.10.5 onward, the broker runs outside the installation directory and does not block npm updates or uninstalls.
@@ -4,31 +4,33 @@ sidebarTitle: "Migrate workflows"
4
4
  description: "Convert legacy Atomic workflow files into reusable skills without executing or modifying the originals."
5
5
  ---
6
6
 
7
- Convert legacy `.ts`, `.js`, `.mjs`, or `.cjs` workflow files into reusable [skills](/skills#skills-as-workflows) without importing, running, or modifying the original files.
7
+ Use the bundled `workflow` skill to turn an earlier Atomic workflow file into a reusable [skill](/skills#skills-as-workflows), or to replace a removed built-in. Atomic reads the old files without running or changing them. For new workflows, start with [Orchestration](/orchestration) instead of writing a legacy workflow file.
8
8
 
9
9
  <Steps>
10
10
  <Step title="Start the conversion">
11
- Ask Atomic in chat or invoke `/skill:workflow-files` with the workflow path:
11
+ Ask Atomic in chat or invoke `/skill:workflow` with the workflow path:
12
12
 
13
13
  ```text
14
14
  Convert .atomic/workflows/triage.ts into a skill
15
15
  ```
16
16
 
17
17
  ```text
18
- /skill:workflow-files .atomic/workflows/triage.ts
18
+ /skill:workflow .atomic/workflows/triage.ts
19
19
  ```
20
20
 
21
- To convert and run immediately, include your inputs (for example, "Run the triage workflow on these reports").
21
+ If you want Atomic to run the result, say so and include the inputs. For example: `Convert .atomic/workflows/triage.ts and run the new skill on reports/april`.
22
22
  </Step>
23
23
  <Step title="Review the generated skill and scripts">
24
- Atomic reads the workflow file and any local helpers as plain text and generates a new `SKILL.md` plus deterministic helper scripts under `scripts/`. It never imports, executes, edits, or deletes the original workflow file, and never overwrites an existing skill directory or follows symlinks into an occupied target path.
24
+ Review the instructions in the new `SKILL.md`. If a step needs a script to run it the same way every time, Atomic places a new helper in `scripts/`. Atomic leaves the earlier files untouched and does not replace an existing skill. If the name is taken, use a different name.
25
25
  </Step>
26
26
  <Step title="Reload and invoke">
27
- Run `/reload`, then invoke `/skill:<name>` with your inputs.
27
+ Run `/reload` in the same Atomic session. Then run the new skill, for example `/skill:triage reports/april`. If the command is missing, compare its name with the `name` at the top of `SKILL.md` and check that Atomic [looks in the folder where you saved it](/skills#locations). If a run is interrupted, check `/tasks` in the original chat before starting it again.
28
28
  </Step>
29
29
  </Steps>
30
30
 
31
- At startup, Atomic scans directly inside `workflows/` directories for legacy `.ts`, `.js`, `.mjs`, and `.cjs` files (excluding `.d.ts` files and subdirectories) and notes up to 20 discovered files (`+N more` if additional files exist). Nothing is converted or written automatically.
31
+ At startup, Atomic can point out old `.ts`, `.js`, `.mjs`, and `.cjs` workflow files. It doesn't convert anything automatically. If your file isn't in the notice, give Atomic its path directly.
32
+
33
+ If you saved `/skill:workflow-files` in a prompt, replace it with `/skill:workflow`. The bundled skill no longer uses the old name.
32
34
 
33
35
  Workflow files in untrusted projects are never offered for conversion, and Atomic never writes into an untrusted project directory. Global workflows still convert; for an explicitly supplied trusted external source inside an untrusted project, Atomic asks before saving globally.
34
36
 
@@ -40,7 +42,9 @@ Workflow files in untrusted projects are never offered for conversion, and Atomi
40
42
 
41
43
  ## What conversion preserves
42
44
 
43
- | Earlier workflow API | Equivalent in the converted skill |
45
+ Use this table to check that the new skill still does what you need. A stage in the old workflow was a named job, such as reviewing one report. You do not need to write or run the old API to migrate it.
46
+
47
+ | Earlier workflow | Equivalent in the converted skill |
44
48
  | --- | --- |
45
49
  | `ctx.stage`, `ctx.task`, model and thinking | Codemode `tools.subagent()` launches in the main chat that keep prompts, inputs, and model pins. |
46
50
  | Stage `fallbackModels`, `tools`, `mcp` | Named [custom subagent](/subagents/authoring) launched without per-call `model` ([Pinned stages](#pinned-stages)). |
@@ -74,9 +78,11 @@ Both comma-separated strings and YAML lists work for `fallbackModels` and `tools
74
78
  const launch = await tools.subagent({ agent: "triage-reviewer", task: report });
75
79
  ```
76
80
 
77
- Package maintainers can ask Atomic to place the skill and agents directly in the package's [`agents` manifest field](/packages/authoring#subagents), where they run as `<namespace>.<name>` (derived from `package.json` `name`, so `@acme/triage` becomes `acme.triage.triage-reviewer`).
81
+ If you maintain an Atomic package, ask Atomic to update the source package, not the installed copy. List the skill under `skills` and the companion agent under [`agents`](/packages/authoring#subagents). Packaged agents use their full name, for example `acme.triage.triage-reviewer` for `triage-reviewer` in `@acme/triage`.
82
+
83
+ ## Replace a removed built-in workflow
78
84
 
79
- ## Replacing removed built-in workflows
85
+ For example, ask `/skill:workflow Help me replace tournament with a skill that compares two approaches on the same tests`. There is no old file to convert. Review the scoring rules and isolation in the new skill before you run it.
80
86
 
81
87
  - `classify-and-act`, `fan-out-and-synthesize`, `adversarial-verification`, `generate-and-filter`, `tournament`, and `loop-until-done` map to the matching [orchestration patterns](/orchestration/patterns).
82
88
  - `ralph` maps to a research, implementation, and review loop in the main chat with an explicit round limit.
@@ -4,7 +4,13 @@ sidebarTitle: "Orchestration patterns"
4
4
  description: "Seven reusable patterns for splitting work across subagents, isolating edits, and verifying results."
5
5
  ---
6
6
 
7
- Give each subagent one concrete deliverable, explicit inputs, clear edit rules, and a verification check. Put conflicting edits in separate worktrees, and run final verification in your main session — a subagent claiming "done" is not proof.
7
+ Use these patterns to decide what can happen in parallel, what needs an earlier result, and what counts as done. Ask for a pattern in chat for a one-off task, or use `/skill:workflow` to turn it into a reusable skill. For example:
8
+
9
+ ```text
10
+ /skill:workflow Draft a skill that reviews the Linux and Windows install guides in parallel and verifies both reviews before reporting. Don't launch it yet.
11
+ ```
12
+
13
+ Give each subagent one deliverable, its inputs, what it can edit, and a check. If subagents might edit the same files, give each writer a separate Git working copy, called a worktree. Run the final checks in your main session. If a result is missing, check `/tasks` in the original chat before starting the job again.
8
14
 
9
15
  ## Choose a pattern
10
16
 
@@ -107,7 +113,7 @@ return r.tasks;
107
113
  `worker` defaults to `context: "fork"`, so pass `context: "fresh"` when you want independent attempts without the main chat's prior reasoning ([Fresh vs. forked context](/subagents#fresh-vs-forked-context)). Named worktrees (`worktree: { branch }`) are permanent and do not symlink `node_modules` — have competitors install dependencies if needed and remove unused branches/worktrees when the tournament ends.
108
114
  </Tip>
109
115
 
110
- Record scores, commit SHAs, and round numbers so restarts never double-advance a candidate. Never pick a winner that fails a required check.
116
+ Record the task IDs, commit SHAs, scores, and which round each candidate finished. If interrupted, match those records against `/tasks` in the original chat before starting a new round. If both candidates fail a required check, report that neither won. If you used the former tournament built-in, ask `/skill:workflow` to save this pattern and your scoring rules as a skill.
111
117
 
112
118
  ## Loop-until-done
113
119
 
@@ -4,7 +4,7 @@ sidebarTitle: "Orchestrate multi-step work"
4
4
  description: "Delegate multi-step work in plain language or codemode scripts, handle background results as they settle, and recover cleanly after interruptions."
5
5
  ---
6
6
 
7
- Give Atomic a goal, how to verify completion, and any limits on edits, cost, or time. You do not need to write JavaScript to split work across agents — describe the work in plain language and your main session decides whether to answer directly, run checks in [codemode](/codemode), or split work across [subagents](/subagents):
7
+ Give Atomic a goal, a way to check the result, and any limits on edits, cost, or time. Describe the work in plain language. Atomic can answer directly, run checks in [codemode](/codemode), or give separate jobs to [subagents](/subagents).
8
8
 
9
9
  ```text
10
10
  Review the installation guide for Linux and Windows. Give each platform to a separate read-only subagent. Check disputed commands against the CLI, then report discrepancies by platform. Do not edit files.
@@ -14,8 +14,9 @@ Review the installation guide for Linux and Windows. Give each platform to a sep
14
14
  | --- | --- |
15
15
  | One-off multi-step task or parallel review | Ask in plain language; Atomic coordinates the subagents for you |
16
16
  | Monitor, steer, or answer running subagents | Open `/tasks` or focus the [agent panel](/background-tasks#the-agent-panel) (`↓` on an empty prompt) |
17
- | Save a repeatable multi-step procedure | Write a [skill](/skills#skills-as-workflows) describing the steps (optionally with codemode snippets) |
17
+ | Save a repeatable multi-step procedure | Ask `/skill:workflow` to help turn it into a [skill](/skills#skills-as-workflows) with inputs, steps, and checks |
18
18
  | Pick a proven coordination structure | Start from the seven [orchestration patterns](/orchestration/patterns) |
19
+ | Convert an earlier workflow file or replace a removed built-in | Use `/skill:workflow` and follow the [migration guide](/orchestration/migrating-workflows) |
19
20
 
20
21
  <Note>
21
22
  **Who writes codemode JavaScript?** During ordinary chat, Atomic writes and runs the [codemode](/codemode) JavaScript below automatically when coordinating parallel subagents. You only write `tools.subagent(...)` snippets yourself when authoring a custom [skill](/skills#skills-as-workflows) or prompt template that encodes a repeatable workflow.
@@ -23,7 +24,9 @@ Review the installation guide for Linux and Windows. Give each platform to a sep
23
24
 
24
25
  ## Launch now, use the result later
25
26
 
26
- When your main session coordinates subagents through [codemode](/codemode) (confirm both `codemode` and `subagent` are enabled with `/tools`), `tools.subagent()` launches background subagents and returns immediately:
27
+ Your **main session** decides what to run next and verifies the result. A **subagent** is a separate session with one job, such as checking Linux installation steps. **Codemode** runs short JavaScript steps that can call Atomic tools; the main session can use one step to launch checks and another to act on their results. Check `/tools` if `codemode` or `subagent` is unavailable.
28
+
29
+ For example, start two independent reviews in one batch, then let Atomic continue when both results arrive:
27
30
 
28
31
  ```js
29
32
  const launch = await tools.subagent({
@@ -36,7 +39,7 @@ store("guide-review", launch.tasks);
36
39
  return launch.tasks;
37
40
  ```
38
41
 
39
- Example `launch.tasks` output:
42
+ The launch result looks like this:
40
43
 
41
44
  ```json
42
45
  [
@@ -45,7 +48,12 @@ Example `launch.tasks` output:
45
48
  ]
46
49
  ```
47
50
 
48
- - **Launch, not completion.** `await` resolves as soon as subagents start (`"admitted"`), queue (`"queued"`), or fail validation (`"refused"` with `reason`). Your main session can keep working or end its turn while completion notices deliver results automatically. Inspect live progress anytime in `/tasks` or the agent panel ([Manage background tasks](/background-tasks)).
51
+ - `agent` is the role assigned to the job. `state` tells you whether it started (`admitted`), is waiting to start (`queued`), or was rejected (`refused`). A rejected launch includes a `reason`.
52
+ - `taskId` identifies the job in `/tasks` and lets a script wait for its result.
53
+ - `childId` identifies the subagent session. Use it to pause, stop, or resume the session, including after reopening the main session.
54
+ - `intercomTarget` is the address to use if another session needs to message this subagent.
55
+
56
+ The launch result does not tell you whether a job succeeded. Look for its completion notice or check `/tasks` or the [agent panel](/background-tasks#the-agent-panel).
49
57
  - **Explicit parallel batches.** Separate `tools.subagent()` calls inside one script are not merged automatically; pass `tasks: [...]` to launch a parallel batch.
50
58
  - **Explicit wait.** When a later step depends on a result immediately, wait on the existing task ID instead of launching a duplicate. The `// @options` comment sets per-script [codemode options](/codemode) such as `timeout_ms`:
51
59
 
@@ -57,9 +65,10 @@ return await tools.subagent({ action: "wait", id: task.taskId, budgetMs: 2000 })
57
65
  ```
58
66
 
59
67
  In codemode, always pass `id` (passing `runId` is rejected), pass a non-negative integer for `budgetMs` (defaults to `30000` ms even when a host configures unlimited foreground waits), and note that `pause` and `quit` stops both report `result.status: "paused"`.
60
- - **Cancellation and evidence.** Hitting `budgetMs`, returning early, or timing out the script never stops already-launched subagents; call `tools.subagent({ action: "quit", id: childId })` to stop one. Treat settled results and real verification output — never launch receipts — as evidence.
68
+ - **Stopping a subagent.** Ending a wait or timing out a script leaves a launched subagent running. Use `tools.subagent({ action: "quit", id: childId })` to stop it. Verify completed work with the result and your checks, not the launch response.
61
69
  - **One-level delegation.** Only the main session launches subagents. If a subagent discovers follow-up work, it reports back so the main session can launch the next batch.
62
- - **Peer messaging.** Pass `group: true` to create a unique shared [Intercom](/intercom) group for a batch, or pass a shared named `group`. Address subagents using their exact `intercomTarget` ([Intercom from codemode](/intercom/reference#from-codemode-scripts)); `contact_supervisor` still reaches the main session across groups.
70
+ - **Peer messaging.** Use a shared [Intercom](/intercom) group when subagents need to coordinate, for example to agree which guide covers a shared prerequisite. Pass `group: true` for a new group shared by a batch, or reuse a named `group` across launches. Address each agent by the exact `intercomTarget` from the launch result, not its task ID. Keep independent reviews separate until each reviewer has reached a conclusion.
71
+ - **Progress files.** Ask a long-running writer to note its latest check, blocker, and next step in its own progress file. Pass `progress: true` to give it an isolated `progress.md` outside the checkout. Progress notes help you pick up the work; they don't replace the completion notice or the final check.
63
72
 
64
73
  ## What survives interruption
65
74
 
@@ -99,4 +108,4 @@ Subagents are persisted sessions; codemode scripts are not checkpointed programs
99
108
  </Card>
100
109
  </Columns>
101
110
 
102
- Have an earlier `.atomic/workflows/*.ts` file or removed built-in workflow name? Follow [Migrate an earlier workflow to a skill](/orchestration/migrating-workflows).
111
+ Ask `/skill:workflow` to explain these patterns, draft a repeatable skill, or [migrate an older workflow](/orchestration/migrating-workflows). For one quick job, just ask in chat.
@@ -8,43 +8,35 @@ description: "Install Atomic, authenticate a model provider, run your first sess
8
8
 
9
9
  ## Prerequisites
10
10
 
11
- - **Package-manager install:** [Node.js 24 LTS, version 24.20.0 or newer](/getting-started/installation#nodejs-version). Package-manager installs—including `bun add -g`—run on Node.js by default unless you explicitly invoke Atomic with Bun (`bun --bun`, requiring Bun 1.4.5+).
12
- - **Release archive install:** macOS and Linux need `tar` and either `curl` or `wget`; Windows uses built-in PowerShell. No Node.js or package manager is required.
11
+ - **Native installer:** On macOS, Linux, or WSL, have `curl` and `tar` available. On Windows, use PowerShell.
13
12
  - **Model provider:** A supported subscription or account login (`/login`), an API key, or a local `llama.cpp` server.
14
13
 
15
14
  ## Get up and running
16
15
 
17
16
  <Steps>
18
- <Step title="Install Atomic">
19
- Choose a package manager or the self-contained release archive:
17
+ <Step title="Native install (recommended)">
18
+ Run the command for your system. If you use WSL, run the macOS/Linux/WSL command inside your WSL terminal.
20
19
 
21
20
  <Tabs>
22
- <Tab title="Package manager">
23
- ```bash
24
- npm install -g @bastani/atomic
25
- # or: pnpm add -g @bastani/atomic
26
- # or: bun add -g @bastani/atomic
27
- ```
28
- </Tab>
29
- <Tab title="macOS / Linux archive">
21
+ <Tab title="macOS, Linux, WSL">
30
22
  ```bash
31
23
  curl -fsSL https://raw.githubusercontent.com/bastani-inc/atomic/main/install.sh | sh
32
24
  ```
33
25
  </Tab>
34
- <Tab title="Windows PowerShell archive">
26
+ <Tab title="Windows PowerShell">
35
27
  ```powershell
36
28
  irm https://raw.githubusercontent.com/bastani-inc/atomic/main/install.ps1 | iex
37
29
  ```
38
30
  </Tab>
39
31
  </Tabs>
40
32
 
41
- Verify the install:
33
+ Open a new terminal and verify the install:
42
34
 
43
35
  ```bash
44
36
  atomic --version
45
37
  ```
46
38
 
47
- See [Install Atomic](/getting-started/installation) for [package manager details](/getting-started/installation#package-managers), [release archive options](/getting-started/installation#release-archive), Git setup, and [uninstalling](/getting-started/installation#uninstall).
39
+ If you installed Atomic with npm, pnpm, or Bun, [switch to the native installer](/getting-started/installation#switch-to-the-native-installer). See [Advanced installation options](/getting-started/installation#advanced-installation-options) if you need to use a package manager.
48
40
  </Step>
49
41
 
50
42
  <Step title="Authenticate a provider">
@@ -227,33 +227,36 @@ atomic --tools read,search,find,ls -p "Review the code"
227
227
 
228
228
  ## Package commands
229
229
 
230
+ Use these commands to manage [Atomic packages](/packages), such as extensions and skills. To remove Atomic itself, see [Uninstall](/getting-started/installation#uninstall).
231
+
230
232
  ```bash
231
- atomic install <source> [-l|--local] [-a|-na] # Install package (-l/--local for project-local)
232
- atomic remove <source> [-l|--local] [-a|-na] # Remove package
233
- atomic uninstall <source> [-l|--local] [-a|-na] # Alias for remove
234
- atomic update [source|self|atomic] [-a|-na] # Update Atomic only, or one package source
235
- atomic update --all # Update Atomic and packages; reconcile pinned git refs
236
- atomic update --extensions # Update packages only; reconcile pinned git refs
237
- atomic update --models # Force-refresh authenticated provider model catalogs (15s timeout)
238
- atomic update --self # Update Atomic only
239
- atomic update --force # Reinstall Atomic even if the current version is latest
240
- atomic update --extension <src> # Update one package (can be passed only once)
241
- atomic list [-a|-na] # List installed packages
242
- atomic config [-l|--local] [-a|-na] # Open resource TUI (-l/--local starts in project settings)
233
+ atomic install <source> # Install a package
234
+ atomic remove <source> # Remove a package (uninstall is an alias)
235
+ atomic list # List installed packages
236
+ atomic config # Choose which resources to use
243
237
  ```
244
238
 
245
- These commands manage Atomic packages, and `atomic update` updates the Atomic CLI installation. To uninstall Atomic itself, see [Uninstall](/getting-started/installation#uninstall).
239
+ Use `--local` (`-l`) with `install` or `remove` to change only this project's packages, or with `config` to open project settings first. Package commands ask whether to trust an untrusted project's settings when run in an interactive terminal and the project has settings that require trust. Pass `--approve` (`-a`) to trust them for the command or `--no-approve` (`-na`) to ignore them. `install --local`, `remove --local`, and `config --local` exit `1` if the project is not trusted.
240
+
241
+ ### Update Atomic and packages
242
+
243
+ Run `atomic update` to update Atomic itself. It prints a reminder that it didn't update any packages. Use `atomic --version` afterward to check which version new sessions will use.
244
+
245
+ | Command | What it updates |
246
+ | --- | --- |
247
+ | `atomic update` or `atomic update --self` | Atomic only. `atomic update self` and `atomic update atomic` also work. |
248
+ | `atomic update --extensions` | All installed packages. A Git package pinned to a branch, tag, or commit is updated to that reference, not to a different one. |
249
+ | `atomic update --all` | Atomic and all installed packages. |
250
+ | `atomic update <source>` or `atomic update --extension <source>` | One installed package. Use the source shown by `atomic list`. |
251
+ | `atomic update --models` | The list of models available from configured providers. It doesn't update Atomic or packages. |
246
252
 
247
- - **Project trust:** All package commands (including `atomic update`, `atomic list`, and `atomic config`) resolve project trust and accept `--approve` (`-a`) and `--no-approve` (`-na`). On an interactive TTY in an untrusted project with local trust inputs, they prompt for project trust. `atomic config -l`, `atomic install <src> -l`, and `atomic remove <src> -l` exit `1` in untrusted projects unless `--approve` is passed or the project is already trusted.
248
- - **Update targets and constraints:**
249
- - Running bare `atomic update` updates Atomic only and prints a note that extensions were skipped (`Run atomic update --extensions to update extensions`).
250
- - Passing both `--self` and `--extensions` behaves like `--all`.
251
- - `--all` and `--models` cannot be combined with other update targets or a positional source, and `--extension` can be passed only once.
252
- - On Windows, built-in self-update supports only `npm` and `pnpm` installs; other install methods exit `1` unless [`ATOMIC_SELF_UPDATE_COMMAND` or global `selfUpdateCommand`](#custom-update-command) is configured.
253
- - **Intercom broker upgrade:** After updating the Atomic CLI, `atomic update` runs the new version's [`atomic intercom upgrade`](#intercom-commands) when `atomic` on `PATH` reports the installed version and lists that command. Otherwise it prints a note and leaves the broker alone. A failed broker upgrade prints a warning and keeps exit code `0`. If you upgrade Atomic in place while a session is running and see a restart notice, restart that session (for example with `atomic -r`).
254
- - **Model catalog refresh (`atomic update --models`):** Refreshes configured provider catalogs (15-second total timeout) without updating packages. Built-in catalogs do not refresh your provider login. Account-specific catalogs still need valid credentials; if an OAuth refresh fails, the command warns with `atomic auth login <provider>` and continues refreshing other catalogs. Other failures, such as a network error, exit nonzero.
253
+ `--all` and `--models` each select what to update on their own. Passing `--self` and `--extensions` together is the same as `--all`. Pass `--extension` only once.
255
254
 
256
- See [Atomic packages](/packages) for package sources and security notes.
255
+ When updating Atomic itself, add `--force` to reinstall even if you're already on the selected version. For [release archive installs](/getting-started/installation#update-a-release-archive-install), add `--version <release>` to install an exact version or `--prerelease` to include prereleases. Use only one of these two options. Exit and resume any open sessions to use the new version.
256
+
257
+ On Windows, `atomic update` supports release archive, npm, and pnpm installs. For other Windows installs, use the tool that installed Atomic or [configure a custom update command](#custom-update-command). If the update warns about Intercom, see [Updating while Intercom is running](/getting-started/installation#updating-while-intercom-is-running).
258
+
259
+ `atomic update --models` has 15 seconds to refresh the lists. If it asks you to sign in again, run `atomic auth login <provider>` with the provider name from the warning and retry. Atomic continues refreshing other providers when one login expires. Other failures, such as a network error, return a nonzero exit status.
257
260
 
258
261
  ### Custom update command
259
262
 
@@ -363,6 +366,10 @@ The credential print commands emit one configured credential for an external cli
363
366
 
364
367
  `auth check --credentials --json` may write a credential-free JSON status object on a nonzero check result. Review [Credential export security](/security#credential-export) before wiring credential export into scripts.
365
368
 
369
+ ## Subscription usage
370
+
371
+ Run `atomic usage` for a plain-text report of your signed-in accounts and `atomic usage --json` for the same report as one JSON object. Neither starts a session. A report can contain an unavailable or failed account without failing the command. `atomic usage --offline` lists accounts without contacting providers. See [Check subscription usage](/guides/subscription-usage) for supported accounts, an example, and the JSON fields.
372
+
366
373
  ## MCP commands
367
374
 
368
375
  ```bash
@@ -408,7 +415,7 @@ Passing `--help` or `-h` after `--` (for example `atomic mcp add srv -- cmd --he
408
415
  ```bash
409
416
  atomic storage status [--json] # Selection, source, adapter, and connection per domain
410
417
  atomic storage join <postgres-url> --password-file <path>|--token-file <path>|--auth azure|aws|gcp [--prefix <prefix>]
411
- atomic storage migrate [--db <url> [--password-file <path> | --token-file <path> | --auth azure|aws|gcp]] [--prefix <prefix>]
418
+ atomic storage migrate [--db <url> [--password-file <path> | --token-file <path> | --auth azure|aws|gcp]] [--prefix <prefix>] [--snapshot-cleanup status|enable|disable]
412
419
  atomic storage move-snapshot-chunks <sqlite-file> [--prefix <prefix>]
413
420
  atomic storage search-session <sqlite-file> <session-id> <pattern> [cursor]
414
421
  atomic storage export <dir> [--sessions] [--limit <n>] [--since <time>] [--storage <json> | --storage-file <path>]
@@ -425,7 +432,8 @@ atomic intercom upgrade # Replace a
425
432
  - **`atomic storage join <postgres-url> ...`:** Verifies the credential and connection (`SELECT 1` with a 15-second timeout) using `@bastani/atomic-storage-postgres` (for `postgres://` or `postgresql://` URLs), writes only the global `storage` setting, and reports any environment variables or settings that override it. Creates no tables and prints the install command if the adapter package is missing. Pass exactly one of `--password-file` (copied to a mode `600` `storage-token.<id>` file), `--token-file` (referenced in place and re-read on every new connection), or `--auth azure|aws|gcp`. Passwords in the URL are rejected.
426
433
  - **`atomic storage migrate ...`:** Creates or upgrades session and Intercom tables in the selected shared database (or `--db`). Run it as the database owner after joining or upgrading Atomic so runtime roles do not need schema-creation privileges (DDL).
427
434
  - `--password-file`, `--token-file`, `--auth`, and `--prefix` are rejected unless `--db` is also passed.
428
- - When no shared adapter storage is configured (or local SQLite/JSONL is selected), `migrate` exits `0` with a no-op message.
435
+ - `--snapshot-cleanup status` reports whether faster worktree snapshot cleanup is on. After upgrading and restarting all clients, the PostgreSQL database owner can turn it on with `enable` or switch back with `disable`. See [Enable faster worktree snapshot cleanup](/storage/postgres#enable-faster-worktree-snapshot-cleanup).
436
+ - When no shared adapter storage is configured (or local SQLite/JSONL is selected), ordinary `migrate` exits `0` with a no-op message. The cleanup option applies only to shared PostgreSQL storage.
429
437
  - On PostgreSQL (when no explicit `schema` option is set), `migrate` moves legacy tables from `public` into schema `atomic` (older Atomic processes still using `public` are refused until upgraded), rebuilds the worktree snapshot-links index concurrently without blocking writes (6-hour statement timeout), creates lazy fork/chat/Intercom tables, tunes autovacuum and `lz4` compression, warns if `pg_trgm` is unavailable, and **exits `1`** if stray Atomic tables are found in `public` after the move.
430
438
  - **`atomic storage move-snapshot-chunks <sqlite-file> [--prefix <prefix>]`:** Migrates the snapshot chunk table in a closed local SQLite file using exclusive access, checkpointing after each batch so the write-ahead log does not need space for the entire copy.
431
439
  - **`atomic storage search-session <sqlite-file> <session-id> <pattern> [cursor]`:** Searches entries of a stored session in an existing local SQLite database by regex pattern. Rejects `:memory:` and URLs, restricts `<session-id>` to ASCII letters, digits, `-`, and `_`, accepts a numeric entry cursor (`seq`, `seq.match`, or `seq.match.line`), and fails if the session changes during the search. See [Recalling earlier work](/sessions#recalling-earlier-work).
@@ -11,7 +11,7 @@ Ordinary commands execute sequentially in FIFO order, while interrupts, `extensi
11
11
  | Category | Commands |
12
12
  | --- | --- |
13
13
  | **Prompting & queue** | [`prompt`](#prompt), [`steer`](#steer), [`follow_up`](#follow_up), [`abort`](#abort), [`clear_queue`](#clear_queue), [`pause_queued_messages`](#pause_queued_messages), [`resume_queued_messages`](#resume_queued_messages), [`set_steering_mode`](#set_steering_mode), [`set_follow_up_mode`](#set_follow_up_mode) |
14
- | **State & tasks** | [`get_state`](#get_state), [`get_messages`](#get_messages), [`get_tools`](#get_tools), [`stop_all_background`](#stop_all_background) |
14
+ | **State & tasks** | [`get_state`](#get_state), [`get_usage`](#get_usage), [`get_messages`](#get_messages), [`get_tools`](#get_tools), [`stop_all_background`](#stop_all_background) |
15
15
  | **Models & auth** | [`set_model`](#set_model), [`cycle_model`](#cycle_model), [`set_scoped_models`](#set_scoped_models), [`get_available_models`](#get_available_models), [`login_provider`](#login_provider), [`cancel_login_provider`](#cancel_login_provider), [`save_provider_credential`](#save_provider_credential), [`logout_provider`](#logout_provider), [`refresh_models`](#refresh_models) |
16
16
  | **Thinking** | [`set_thinking_level`](#set_thinking_level), [`cycle_thinking_level`](#cycle_thinking_level), [`get_available_thinking_levels`](#get_available_thinking_levels) |
17
17
  | **Compaction & retry** | [`compact`](#compact), [`set_auto_compaction`](#set_auto_compaction), [`set_compaction_model`](#set_compaction_model), [`set_decision_model`](#set_decision_model), [`abort_compaction`](#abort_compaction), [`abort_branch_summary`](#abort_branch_summary), [`set_auto_retry`](#set_auto_retry), [`abort_retry`](#abort_retry) |
@@ -256,6 +256,14 @@ Key fields on `data`:
256
256
  `get_state` reports the session path as `sessionLocation`, whereas `get_session_stats` reports it as `sessionFile`. Neither field is a `switch_session` target — pass `sessionId` to `switch_session`.
257
257
  </Note>
258
258
 
259
+ #### get_usage
260
+
261
+ Read subscription usage without interrupting the current turn. The response `data` is the same [usage report](/guides/subscription-usage#json-and-sdk-contract) as `atomic usage --json`. An optional `provider` selects an account by its Atomic ID. Set `refresh` to `true` to skip the cache.
262
+
263
+ ```json
264
+ {"type":"get_usage","id":"report","refresh":true}
265
+ ```
266
+
259
267
  #### get_messages
260
268
 
261
269
  Return all messages in the active conversation branch.
package/docs/rpc.md CHANGED
@@ -79,7 +79,7 @@ Atomic dispatches stdin frames across two lanes so cancellations and extension U
79
79
  | Lane | Commands | Behavior |
80
80
  | --- | --- | --- |
81
81
  | **Sequential (FIFO) lane** | Ordinary commands (`get_state`, `set_model`, `switch_session`, `compact`, `prompt`, etc.) | Executed strictly one at a time in arrival order. `prompt` responds once preflight completes and detaches immediately so later commands run while the turn streams. In standalone RPC mode, `compact` holds this lane until compaction completes. |
82
- | **Concurrent / control lane** | Interrupts (`abort`, `cancel_login_provider`, `abort_compaction`, `abort_branch_summary`, `abort_retry`, `abort_bash`, `pause_queued_messages`, `resume_queued_messages`, `clear_queue`), `extension_ui_response`, and concurrent commands (`bash`, `user_bash`, `refresh_models`, `set_compaction_model`, `set_decision_model`, `start_pending_recovery`, `stop_all_background`) | Bypass the sequential queue and run immediately even while an ordinary command (such as `compact` or a slow `switch_session`) is in flight. |
82
+ | **Concurrent / control lane** | Interrupts (`abort`, `cancel_login_provider`, `abort_compaction`, `abort_branch_summary`, `abort_retry`, `abort_bash`, `pause_queued_messages`, `resume_queued_messages`, `clear_queue`), `extension_ui_response`, and concurrent commands (`bash`, `user_bash`, `refresh_models`, `get_usage`, `set_compaction_model`, `set_decision_model`, `start_pending_recovery`, `stop_all_background`) | Bypass the sequential queue and run immediately even while an ordinary command (such as `compact` or a slow `switch_session`) is in flight. |
83
83
 
84
84
  Because the first sequential frame starts synchronously before the next line is read, a follow-up interrupt sent immediately after a command cannot overtake the command's initialization.
85
85