@bastani/atomic 0.10.19 → 0.10.20-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 (328) hide show
  1. package/CHANGELOG.md +37 -0
  2. package/dist/_shared/adapter-open-DXXV6ATH.js +22 -0
  3. package/dist/_shared/adapter-open-DXXV6ATH.js.map +1 -0
  4. package/dist/_shared/dist-KOELCESV.js +2 -2
  5. package/dist/_shared/fork-row-index-UAUAQRD5.js +2 -2
  6. package/dist/_shared/lib-4PES5P4V.js +2 -2
  7. package/dist/_shared/mode-interactive-sdk-JXBZ3H27.js +439 -217
  8. package/dist/_shared/mode-interactive-sdk-JXBZ3H27.js.map +1 -1
  9. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +19 -11
  10. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js.map +1 -1
  11. package/dist/_shared/mode-shared-2QJSCUM6.js +9 -9
  12. package/dist/_shared/p0-cli-BB45ZQY6.js +2 -2
  13. package/dist/_shared/p1a-prewarm-XIU57JHF.js +3 -3
  14. package/dist/_shared/runtime-O4KCSG4C.js +5 -5
  15. package/dist/_shared/{sdk-BHX35EPK.js → sdk-5ZFNDXUJ.js} +119 -40
  16. package/dist/_shared/sdk-5ZFNDXUJ.js.map +1 -0
  17. package/dist/_shared/session-data-AHTU7IS6.js +5 -4
  18. package/dist/_shared/session-data-AHTU7IS6.js.map +1 -1
  19. package/dist/_shared/session-manager-list-2BLEEZVG.js +1 -1
  20. package/dist/_shared/settings-startup-HXQLSUWM.js.map +1 -1
  21. package/dist/_shared/{startup-0-0-4EDVBK5P.js → startup-0-0-FPPQF42L.js} +69 -26
  22. package/dist/_shared/startup-0-0-FPPQF42L.js.map +1 -0
  23. package/dist/_shared/{startup-0-1-H5IXVRXQ.js → startup-0-1-Q7GBLBEL.js} +158 -37
  24. package/dist/_shared/startup-0-1-Q7GBLBEL.js.map +1 -0
  25. package/dist/_shared/{startup-0-2-YZZOC22D.js → startup-0-2-JNYN24UI.js} +40 -6
  26. package/dist/_shared/startup-0-2-JNYN24UI.js.map +1 -0
  27. package/dist/_shared/startup-0-3-DE2NCS6A.js +26 -41
  28. package/dist/_shared/startup-0-3-DE2NCS6A.js.map +1 -1
  29. package/dist/_shared/{startup-0-4-ZMJV547D.js → startup-0-4-ZZXFKE55.js} +85 -19
  30. package/dist/_shared/startup-0-4-ZZXFKE55.js.map +1 -0
  31. package/dist/_shared/{startup-0-5-HZX3ZPTP.js → startup-0-5-WN2IYA25.js} +112 -15
  32. package/dist/_shared/startup-0-5-WN2IYA25.js.map +1 -0
  33. package/dist/_shared/{startup-10-0-TDQNBDDL.js → startup-10-0-O6DAT7U4.js} +65 -117
  34. package/dist/_shared/startup-10-0-O6DAT7U4.js.map +1 -0
  35. package/dist/_shared/startup-12-0-55AAXBJZ.js +2 -2
  36. package/dist/_shared/startup-14-0-MLX36RBG.js +8 -5
  37. package/dist/_shared/startup-14-0-MLX36RBG.js.map +1 -1
  38. package/dist/_shared/{startup-15-0-YUKGAC63.js → startup-15-0-E7RYG5YF.js} +8 -8
  39. package/dist/_shared/{startup-15-0-YUKGAC63.js.map → startup-15-0-E7RYG5YF.js.map} +1 -1
  40. package/dist/_shared/startup-15-1-WQZBOTMZ.js +73 -28
  41. package/dist/_shared/startup-15-1-WQZBOTMZ.js.map +1 -1
  42. package/dist/_shared/startup-8-0-34CBHPZH.js +31 -21
  43. package/dist/_shared/startup-8-0-34CBHPZH.js.map +1 -1
  44. package/dist/_shared/startup-8-1-QZMXUGHI.js +34 -24
  45. package/dist/_shared/startup-8-1-QZMXUGHI.js.map +1 -1
  46. package/dist/_shared/storage-command-7MGXLJGZ.js +9 -5
  47. package/dist/_shared/storage-command-7MGXLJGZ.js.map +1 -1
  48. package/dist/_shared/{storage-status-K7PX2RXA.js → storage-status-T6FUXRIM.js} +7 -23
  49. package/dist/_shared/{storage-status-K7PX2RXA.js.map → storage-status-T6FUXRIM.js.map} +1 -1
  50. package/dist/_shared/task-reference-stream-JWMUZSJX.js +1 -1
  51. package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
  52. package/dist/_shared/team-DOQKICG2.js +3 -2
  53. package/dist/_shared/team-DOQKICG2.js.map +1 -1
  54. package/dist/_shared/tree-outline-MUEPK5B7.js +2 -2
  55. package/dist/binary-self-update.js +3 -3
  56. package/dist/builtin/intercom/index.bundle.mjs +1 -1
  57. package/dist/builtin/intercom/package.json +1 -1
  58. package/dist/builtin/mcp/index.bundle.mjs +1 -1
  59. package/dist/builtin/mcp/package.json +1 -1
  60. package/dist/builtin/subagents/package.json +1 -1
  61. package/dist/builtin/subagents/src/extension/index.bundle.mjs +1 -1
  62. package/dist/builtin/web-access/index.bundle.mjs +1 -1
  63. package/dist/builtin/web-access/package.json +1 -1
  64. package/dist/cli/args.js +2 -2
  65. package/dist/cli/auth-cli.code.js +5 -5
  66. package/dist/cli/auth-cli.impl.js +3 -3
  67. package/dist/cli/auth-cli.js +3 -3
  68. package/dist/cli/blueprint-command.code.js +3 -3
  69. package/dist/cli/blueprint-command.impl.js +3 -3
  70. package/dist/cli/blueprint-command.js +3 -3
  71. package/dist/cli/intercom-command.code.js +3 -3
  72. package/dist/cli/intercom-command.impl.js +3 -3
  73. package/dist/cli/intercom-command.js +3 -3
  74. package/dist/cli/list-models.code.js +3 -3
  75. package/dist/cli/list-models.impl.js +3 -3
  76. package/dist/cli/list-models.js +3 -3
  77. package/dist/cli/session-picker.code.js +2 -2
  78. package/dist/cli/session-picker.impl.js +3 -3
  79. package/dist/cli/session-picker.js +3 -3
  80. package/dist/cli/startup-ui.code.js +2 -2
  81. package/dist/cli/startup-ui.impl.js +3 -3
  82. package/dist/cli/startup-ui.js +3 -3
  83. package/dist/cli/storage-command.impl.js +3 -3
  84. package/dist/cli/storage-command.js +3 -3
  85. package/dist/cli/storage-search-session.code.js +2 -2
  86. package/dist/cli/storage-search-session.impl.js +3 -3
  87. package/dist/cli/storage-search-session.js +3 -3
  88. package/dist/cli/team-command.code.js +3 -3
  89. package/dist/cli/team-command.impl.js +3 -3
  90. package/dist/cli/team-command.js +3 -3
  91. package/dist/cli.js +2 -2
  92. package/dist/core/agent-session-runtime.d.ts +2 -1
  93. package/dist/core/debug.impl.js +3 -3
  94. package/dist/core/debug.js +3 -3
  95. package/dist/core/export-html/card-projection.code.js +1 -1
  96. package/dist/core/export-html/card-projection.impl.js +3 -3
  97. package/dist/core/export-html/card-projection.js +3 -3
  98. package/dist/core/export-html/index.code.js +44 -41
  99. package/dist/core/export-html/index.code.js.map +1 -1
  100. package/dist/core/export-html/index.impl.js +3 -3
  101. package/dist/core/export-html/index.js +3 -3
  102. package/dist/core/export-html/json-spans.impl.js +3 -3
  103. package/dist/core/export-html/json-spans.js +3 -3
  104. package/dist/core/export-html/oversized-render-inputs.code.js +1 -1
  105. package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
  106. package/dist/core/export-html/oversized-render-inputs.js +3 -3
  107. package/dist/core/export-html/template.js +12 -25
  108. package/dist/core/export-html/tool-renderer.code.js +1 -1
  109. package/dist/core/export-html/tool-renderer.impl.js +3 -3
  110. package/dist/core/export-html/tool-renderer.js +3 -3
  111. package/dist/core/extensions/context-types.d.ts +3 -0
  112. package/dist/core/extensions/context-types.js.map +1 -1
  113. package/dist/core/extensions/jiti-loader.impl.js +3 -3
  114. package/dist/core/extensions/jiti-loader.js +3 -3
  115. package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
  116. package/dist/core/extensions/jiti-static-loader.js +3 -3
  117. package/dist/core/extensions/loader-host-modules.code.js +1 -1
  118. package/dist/core/extensions/loader-host-modules.impl.js +3 -3
  119. package/dist/core/extensions/loader-host-modules.js +3 -3
  120. package/dist/core/extensions/loader-virtual-modules.js +2 -2
  121. package/dist/core/extensions/runner-context.d.ts +1 -0
  122. package/dist/core/extensions/runner-context.js +17 -1
  123. package/dist/core/extensions/runner-context.js.map +1 -1
  124. package/dist/core/extensions/runner.d.ts +1 -0
  125. package/dist/core/extensions/runtime-types.d.ts +1 -0
  126. package/dist/core/extensions/runtime-types.js.map +1 -1
  127. package/dist/core/intercom-broker-control-host.code.js +1 -1
  128. package/dist/core/intercom-broker-control-host.impl.js +3 -3
  129. package/dist/core/intercom-broker-control-host.js +3 -3
  130. package/dist/core/intercom-broker-control.code.js +3 -3
  131. package/dist/core/intercom-broker-control.impl.js +3 -3
  132. package/dist/core/intercom-broker-control.js +3 -3
  133. package/dist/core/model-registry.js +2 -2
  134. package/dist/core/model-runtime-streaming.d.ts +3 -1
  135. package/dist/core/model-runtime.d.ts +2 -0
  136. package/dist/core/package-manager-storage-adapters.impl.js +3 -3
  137. package/dist/core/package-manager-storage-adapters.js +3 -3
  138. package/dist/core/sdk.code.js +3 -3
  139. package/dist/core/sdk.impl.js +3 -3
  140. package/dist/core/sdk.js +3 -3
  141. package/dist/core/session-manager-core.d.ts +4 -0
  142. package/dist/core/session-manager-core.js +46 -18
  143. package/dist/core/session-manager-core.js.map +1 -1
  144. package/dist/core/session-manager-history.d.ts +1 -1
  145. package/dist/core/session-manager-list.impl.js +3 -3
  146. package/dist/core/session-manager-list.js +3 -3
  147. package/dist/core/session-manager.code.js +2 -2
  148. package/dist/core/session-manager.impl.js +3 -3
  149. package/dist/core/session-manager.js +3 -3
  150. package/dist/core/session-storage.impl.js +3 -3
  151. package/dist/core/session-storage.js +3 -3
  152. package/dist/core/settings-manager.js +1 -1
  153. package/dist/core/storage/adapter-open.js +3 -0
  154. package/dist/core/storage/adapter-open.js.map +1 -0
  155. package/dist/core/storage/index.js +2 -2
  156. package/dist/core/storage/node-sqlite-thread.js +2 -2
  157. package/dist/core/storage/node-sqlite.js +2 -2
  158. package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
  159. package/dist/core/storage/offline-snapshot-file.js +3 -3
  160. package/dist/core/storage/prefix.js +1 -0
  161. package/dist/core/storage/prefix.js.map +1 -1
  162. package/dist/core/storage/provider.js +2 -2
  163. package/dist/core/storage/selection.js +2 -2
  164. package/dist/core/storage/session/branch-fork-source.code.js +2 -2
  165. package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
  166. package/dist/core/storage/session/branch-fork-source.js +3 -3
  167. package/dist/core/storage/session/card-view.impl.js +3 -3
  168. package/dist/core/storage/session/card-view.js +3 -3
  169. package/dist/core/storage/session/child-reader.code.js +7 -7
  170. package/dist/core/storage/session/child-reader.code.js.map +1 -1
  171. package/dist/core/storage/session/child-reader.d.ts +1 -0
  172. package/dist/core/storage/session/child-reader.impl.js +3 -3
  173. package/dist/core/storage/session/child-reader.js +3 -3
  174. package/dist/core/storage/session/chunked-resume-projection.code.js +1 -1
  175. package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
  176. package/dist/core/storage/session/chunked-resume-projection.js +3 -3
  177. package/dist/core/storage/session/expanded-child-details.code.js +3 -3
  178. package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
  179. package/dist/core/storage/session/expanded-child-details.js +3 -3
  180. package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
  181. package/dist/core/storage/session/fork-row-bytes.js +3 -3
  182. package/dist/core/storage/session/fork-row-index.impl.js +3 -3
  183. package/dist/core/storage/session/fork-row-index.js +3 -3
  184. package/dist/core/storage/session/fork-staging.code.js +2 -2
  185. package/dist/core/storage/session/fork-staging.impl.js +3 -3
  186. package/dist/core/storage/session/fork-staging.js +3 -3
  187. package/dist/core/storage/session/fork-window.code.js +5 -4
  188. package/dist/core/storage/session/fork-window.code.js.map +1 -1
  189. package/dist/core/storage/session/fork-window.impl.js +3 -3
  190. package/dist/core/storage/session/fork-window.js +3 -3
  191. package/dist/core/storage/session/history-pages.impl.js +3 -3
  192. package/dist/core/storage/session/history-pages.js +3 -3
  193. package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
  194. package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
  195. package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
  196. package/dist/core/storage/session/jsonl-session-store.js +3 -3
  197. package/dist/core/storage/session/memory-session-store.impl.js +3 -3
  198. package/dist/core/storage/session/memory-session-store.js +3 -3
  199. package/dist/core/storage/session/pinned-branch-resume.code.js +3 -3
  200. package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
  201. package/dist/core/storage/session/pinned-branch-resume.js +3 -3
  202. package/dist/core/storage/session/released-history-files.code.js +3 -3
  203. package/dist/core/storage/session/released-history-files.impl.js +3 -3
  204. package/dist/core/storage/session/released-history-files.js +3 -3
  205. package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
  206. package/dist/core/storage/session/resident-fork-rows.js +3 -3
  207. package/dist/core/storage/session/session-resume.impl.js +3 -3
  208. package/dist/core/storage/session/session-resume.js +3 -3
  209. package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
  210. package/dist/core/storage/session/snapshot-cut.js +3 -3
  211. package/dist/core/storage/session/snapshot-history.code.js +3 -3
  212. package/dist/core/storage/session/snapshot-history.impl.js +3 -3
  213. package/dist/core/storage/session/snapshot-history.js +3 -3
  214. package/dist/core/storage/session/sql-session-store.code.js +1 -1
  215. package/dist/core/storage/session/sql-session-store.d.ts +3 -17
  216. package/dist/core/storage/session/sql-session-store.impl.js +3 -3
  217. package/dist/core/storage/session/sql-session-store.js +3 -3
  218. package/dist/core/storage/session/tree-outline.impl.js +3 -3
  219. package/dist/core/storage/session/tree-outline.js +3 -3
  220. package/dist/core/storage/session/tree-presentation.code.js +1 -1
  221. package/dist/core/storage/session/tree-presentation.impl.js +3 -3
  222. package/dist/core/storage/session/tree-presentation.js +3 -3
  223. package/dist/core/storage/session/types.d.ts +2 -0
  224. package/dist/core/storage/session/usage-observations.d.ts +27 -0
  225. package/dist/core/storage/session/usage-observations.js +3 -0
  226. package/dist/core/storage/session/usage-observations.js.map +1 -0
  227. package/dist/core/storage/storage-status.code.js +1 -1
  228. package/dist/core/storage/storage-status.impl.js +3 -3
  229. package/dist/core/storage/storage-status.js +3 -3
  230. package/dist/core/storage/team.impl.js +3 -3
  231. package/dist/core/storage/team.js +3 -3
  232. package/dist/core/structured-output/index.code.js +1 -1
  233. package/dist/core/structured-output/index.impl.js +3 -3
  234. package/dist/core/structured-output/index.js +3 -3
  235. package/dist/core/subscription-usage-identity.d.ts +9 -0
  236. package/dist/core/subscription-usage-observations.d.ts +15 -0
  237. package/dist/core/subscription-usage-storage.js +3 -0
  238. package/dist/core/subscription-usage-storage.js.map +1 -0
  239. package/dist/core/subscription-usage.d.ts +20 -3
  240. package/dist/core/tasks/task-completion-entry.code.js +1 -1
  241. package/dist/core/tasks/task-completion-entry.impl.js +3 -3
  242. package/dist/core/tasks/task-completion-entry.js +3 -3
  243. package/dist/core/tasks/task-file-history.code.js +3 -3
  244. package/dist/core/tasks/task-file-history.impl.js +3 -3
  245. package/dist/core/tasks/task-file-history.js +3 -3
  246. package/dist/core/tasks/task-reference-archive.code.js +4 -4
  247. package/dist/core/tasks/task-reference-archive.js +3 -3
  248. package/dist/core/tasks/task-reference-identity.code.js +1 -1
  249. package/dist/core/tasks/task-reference-identity.js +3 -3
  250. package/dist/core/tasks/task-reference-stream.impl.js +3 -3
  251. package/dist/core/tasks/task-reference-stream.js +3 -3
  252. package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
  253. package/dist/core/tasks/task-unsaved-answer.js +3 -3
  254. package/dist/core/tasks/task-view-source.impl.js +3 -3
  255. package/dist/core/tasks/task-view-source.js +3 -3
  256. package/dist/core/tools/read-url.code.js +2 -2
  257. package/dist/core/tools/read-url.impl.js +3 -3
  258. package/dist/core/tools/read-url.js +3 -3
  259. package/dist/core/worktree-snapshot/blob-store.js +2 -2
  260. package/dist/core/worktree-snapshot/errors.code.js +3 -3
  261. package/dist/core/worktree-snapshot/errors.impl.js +3 -3
  262. package/dist/core/worktree-snapshot/errors.js +3 -3
  263. package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
  264. package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
  265. package/dist/extensions/codemode/execute.code.js +2 -2
  266. package/dist/extensions/codemode/execute.impl.js +3 -3
  267. package/dist/extensions/codemode/execute.js +3 -3
  268. package/dist/extensions/codemode/renderer.code.js +2 -2
  269. package/dist/extensions/codemode/renderer.impl.js +3 -3
  270. package/dist/extensions/codemode/renderer.js +3 -3
  271. package/dist/extensions/mcp/cli.code.js +3 -3
  272. package/dist/extensions/mcp/cli.impl.js +3 -3
  273. package/dist/extensions/mcp/cli.js +3 -3
  274. package/dist/extensions/mcp/cli.lazy.code.js +2 -2
  275. package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
  276. package/dist/extensions/mcp/cli.lazy.js +3 -3
  277. package/dist/extensions/mcp/runtime.code.js +1 -1
  278. package/dist/extensions/mcp/runtime.impl.js +3 -3
  279. package/dist/extensions/mcp/runtime.js +3 -3
  280. package/dist/index.d.ts +1 -1
  281. package/dist/index.js +8 -8
  282. package/dist/main-first-time-setup.code.js +2 -2
  283. package/dist/main-first-time-setup.impl.js +3 -3
  284. package/dist/main-first-time-setup.js +3 -3
  285. package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
  286. package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
  287. package/dist/modes/interactive/components/stored-tree-view.js +3 -3
  288. package/dist/modes/interactive/components/user-message-selector-archive.code.js +1 -1
  289. package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
  290. package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
  291. package/dist/modes/interactive-engine/isolated-runtime.d.ts +1 -0
  292. package/dist/modes/interactive-engine/protocol.d.ts +4 -0
  293. package/dist/modes/print-mode.js +1 -1
  294. package/dist/modes/rpc/rpc-client.d.ts +1 -1
  295. package/dist/modes/rpc/rpc-types.d.ts +5 -0
  296. package/dist/package-manager-cli.code.js +6 -6
  297. package/dist/package-manager-cli.impl.js +3 -3
  298. package/dist/package-manager-cli.js +3 -3
  299. package/dist/rpc-entry.js +1 -1
  300. package/dist/startup-files.json +1 -1
  301. package/dist/startup-stages/10.js +1 -1
  302. package/dist/startup-stages/4.js +1 -1
  303. package/dist/startup-stages/6.js +1 -1
  304. package/dist/startup-stages/7.js +1 -1
  305. package/dist/startup-stages/8.js +1 -1
  306. package/dist/utils/startup-database-spare.code.js +3 -3
  307. package/dist/utils/startup-database-spare.impl.js +3 -3
  308. package/dist/utils/startup-database-spare.js +3 -3
  309. package/dist/utils/tools-manager.code.js +1 -1
  310. package/dist/utils/tools-manager.impl.js +3 -3
  311. package/dist/utils/tools-manager.js +3 -3
  312. package/docs/changelog.mdx +23 -0
  313. package/docs/extensions/api-reference.md +6 -0
  314. package/docs/guides/subscription-usage.md +28 -82
  315. package/docs/reference/cli.md +3 -1
  316. package/docs/rpc/protocol.md +30 -2
  317. package/docs/sdk/reference.md +26 -1
  318. package/docs/sessions.md +3 -1
  319. package/docs/slash-commands.md +1 -1
  320. package/docs/usage.md +1 -1
  321. package/package.json +8 -8
  322. package/dist/_shared/sdk-BHX35EPK.js.map +0 -1
  323. package/dist/_shared/startup-0-0-4EDVBK5P.js.map +0 -1
  324. package/dist/_shared/startup-0-1-H5IXVRXQ.js.map +0 -1
  325. package/dist/_shared/startup-0-2-YZZOC22D.js.map +0 -1
  326. package/dist/_shared/startup-0-4-ZMJV547D.js.map +0 -1
  327. package/dist/_shared/startup-0-5-HZX3ZPTP.js.map +0 -1
  328. package/dist/_shared/startup-10-0-TDQNBDDL.js.map +0 -1
@@ -151,11 +151,14 @@ export type RpcCommand = {
151
151
  } | {
152
152
  id?: string;
153
153
  type: "list_usage_accounts";
154
+ subscriptionsOnly?: boolean;
154
155
  } | {
155
156
  id?: string;
156
157
  type: "get_usage";
157
158
  provider?: string;
158
159
  refresh?: boolean;
160
+ observedOnly?: boolean;
161
+ subscriptionsOnly?: boolean;
159
162
  } | {
160
163
  id?: string;
161
164
  type: "get_session_summary";
@@ -341,6 +344,8 @@ export type RpcCommand = {
341
344
  * peer's value is ignored.
342
345
  */
343
346
  startedSession?: boolean;
347
+ /** Requests correlated phase messages on the interactive engine's private channel. */
348
+ reportLoadProgress?: true;
344
349
  } | {
345
350
  id?: string;
346
351
  type: "import_session";
@@ -6,12 +6,12 @@ import chalk from "chalk";
6
6
  import { Container, Input, Markdown, ProcessTerminal, Spacer, TuiMainScreen, getKeybindings, matchesKey, setCapabilityOverrides, setKeybindings, truncateToWidth, visibleWidth } from "@bastani/atomic-tui";
7
7
  import { KeybindingsManager as KeybindingsManager$1, getMarkdownTheme, initTheme, navActionText, renderNavHintLine, stopThemeWatcher, theme } from "./_shared/p2-shell-main-B2WIALFD.js";
8
8
  import { APP_NAME, CONFIG_DIR_NAME, ENV_PACKAGE_DIR, ENV_SELF_UPDATE_COMMAND, PACKAGE_NAME, VERSION, detectInstallChange, detectInstallMethod, getAgentConfigPaths, getAgentDir, getConfiguredSelfUpdateArgv, getEnvNames, getPackageDir, getSelfUpdateCommand, getSelfUpdateUnavailableInstruction, isLocalPath, makeConfiguredSelfUpdateCommand, processLaunch, processLaunchAsync, resolvePath, shortenHomePath, spawnLaunchedProcess, spawnLaunchedProcessSync } from "./_shared/p0-cli-BB45ZQY6.js";
9
- import { DynamicBorder, cleanupWindowsSelfUpdateQuarantine, handlePackageCommandParseOutcome, isWindowsInstallDirectoryLockError, parsePackageCommand, quarantineWindowsNativeDependencies } from "./_shared/startup-0-0-4EDVBK5P.js";
9
+ import { DynamicBorder, cleanupWindowsSelfUpdateQuarantine, handlePackageCommandParseOutcome, isWindowsInstallDirectoryLockError, parsePackageCommand, quarantineWindowsNativeDependencies } from "./_shared/startup-0-0-FPPQF42L.js";
10
10
  import { createProjectTrustContext } from "./_shared/startup-0-3-DE2NCS6A.js";
11
11
  import { parseConfigCommand } from "./_shared/config-command-parser-XRBNVMBV.js";
12
- import { AuthStorage } from "./_shared/startup-0-4-ZMJV547D.js";
13
- import { DefaultPackageManager, ModelRuntime } from "./_shared/startup-0-5-HZX3ZPTP.js";
14
- import { formatPackageInstallWarning, isOfflineModeEnabled } from "./_shared/startup-0-1-H5IXVRXQ.js";
12
+ import { AuthStorage } from "./_shared/startup-0-4-ZZXFKE55.js";
13
+ import { DefaultPackageManager, ModelRuntime } from "./_shared/startup-0-5-WN2IYA25.js";
14
+ import { formatPackageInstallWarning, isOfflineModeEnabled } from "./_shared/startup-0-1-Q7GBLBEL.js";
15
15
  import { DefaultResourceLoader, resolveProjectTrusted } from "./_shared/startup-14-0-MLX36RBG.js";
16
16
  import { SettingsManager } from "./_shared/startup-8-1-QZMXUGHI.js";
17
17
  import { ProjectTrustStore, hasProjectTrustInputs } from "./_shared/p1b-elig-BY2G5BUE.js";
@@ -1122,7 +1122,7 @@ function __atomicOnDemandFailed(error, feature) {
1122
1122
  return (async () => {
1123
1123
  const root = new URL("./", import.meta.url);
1124
1124
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
1125
- const key = `${root.href}#0.10.19`;
1125
+ const key = `${root.href}#0.10.20-alpha.1`;
1126
1126
  let release = releases.get(key);
1127
1127
  if (release === undefined) {
1128
1128
  const current = (async () => {
@@ -1150,7 +1150,7 @@ function __atomicOnDemandFailed(error, feature) {
1150
1150
  } catch {
1151
1151
  // No installation to read, as in a bundle of the package: the release the process runs decides.
1152
1152
  }
1153
- const updatedTo = typeof installed === "string" && installed !== "0.10.19" ? installed : running !== undefined && running.version !== "0.10.19" ? "0.10.19" : undefined;
1153
+ const updatedTo = typeof installed === "string" && installed !== "0.10.20-alpha.1" ? installed : running !== undefined && running.version !== "0.10.20-alpha.1" ? "0.10.20-alpha.1" : undefined;
1154
1154
  if (updatedTo === undefined) throw error;
1155
1155
  const application = typeof running?.name === "string" ? running.name : "atomic";
1156
1156
  const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("./", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("./", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
package/dist/rpc-entry.js CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import "./_shared/rolldown-runtime-BGM3D5V3.js";
3
- import { insertForcedOptionsBeforeTerminator } from "./_shared/startup-0-1-H5IXVRXQ.js";
3
+ import { insertForcedOptionsBeforeTerminator } from "./_shared/startup-0-1-Q7GBLBEL.js";
4
4
  import { exitOnDecisionConfigError } from "./_shared/settings-startup-8-DNZ2RIHM.js";
5
5
  import { APP_NAME, ATOMIC_AI_AGENT } from "./_shared/p0-cli-BB45ZQY6.js";
6
6
  import { configureHttpDispatcher } from "./_shared/http-YFAPTIZD.js";
@@ -1 +1 @@
1
- {"version":2,"self":"@bastani/atomic","packages":[["@bastani/atomic",-1],["@bastani/atomic-tui",0],["@bastani/atomic-codemode",0],["proper-lockfile",0],["graceful-fs",3],["retry",3],["signal-exit",3],["get-east-asian-width",1],["marked",1],["marked-cjk-friendly",1],["chalk",0],["@bastani/atomic-ai",0],["@bastani/atomic-schema",11],["@bastani/atomic-agent-core",0],["glob",0]],"files":[[0,"dist/modes/interactive-engine/engine-prewarm.js"],[0,"dist/_shared/rolldown-runtime-BGM3D5V3.js"],[0,"dist/_shared/p1a-prewarm-XIU57JHF.js"],[0,"dist/__atomic_timers/index.js"],[0,"dist/_shared/p0-cli-BB45ZQY6.js"],[1,"dist/helper-programs/index.js"],[1,"dist/_main-ea49a2e6.js"],[1,"dist/_rolldown-runtime-e937a250.js"],[1,"dist/_lazy-eb232bf4.js"],[0,"dist/utils/canonical-path.js"],[0,"dist/utils/path-exists.js"],[0,"dist/utils/worker-threads.js"],[2,"dist/node-options.js"],[0,"dist/_shared/p1-shared-RG5I5LJ6.js"],[0,"dist/core/storage/node-sqlite-thread.js"],[0,"dist/core/storage/dialect.js"],[0,"dist/modes/interactive/startup-shell-eligibility.js"],[0,"dist/_shared/p1b-elig-BY2G5BUE.js"],[3,"index.js"],[0,"dist/_shared/p1-elig-shell-WWRO3L2R.js"],[3,"lib/lockfile.js"],[4,"graceful-fs.js"],[4,"polyfills.js"],[4,"legacy-streams.js"],[4,"clone.js"],[5,"index.js"],[5,"lib/retry.js"],[5,"lib/retry_operation.js"],[6,"index.js"],[6,"signals.js"],[3,"lib/mtime-precision.js"],[3,"lib/adapter.js"],[0,"dist/modes/interactive/startup-shell.js"],[0,"dist/_shared/p2-shell-TJBYQMCJ.js"],[1,"dist/index.js"],[1,"dist/_main-e4228e6a.js"],[1,"dist/_main-e85c88b3.js"],[7,"index.js"],[7,"lookup.js"],[7,"lookup-data.js"],[7,"utilities.js"],[1,"dist/_main-edb90e85.js"],[1,"dist/_main-edf509ab.js"],[1,"dist/_main-e9d2ce9e.js"],[1,"dist/__atomic_timers/index.js"],[1,"dist/_main-e881e236.js"],[1,"dist/_main-ec15befe.js"],[1,"dist/_main-e101663a.js"],[8,"lib/marked.esm.js"],[9,"dist/index.js"],[1,"dist/_main-e4a71c51.js"],[1,"dist/_main-ec8edda6.js"],[1,"dist/native-modifiers.js"],[1,"dist/native-platform.js"],[1,"dist/native-module-path.js"],[1,"dist/_main-e41da700.js"],[0,"dist/_shared/p2-shell-main-B2WIALFD.js"],[10,"source/index.js"],[10,"source/utilities.js"],[10,"source/vendor/ansi-styles/index.js"],[10,"source/vendor/supports-color/index.js"],[0,"dist/utils/memoize-async.js"],[0,"dist/_shared/p2-common-YLSYXMDQ.js"],[0,"dist/utils/startup-stages.js"],[0,"dist/_shared/p3a-stages-66VAGJL3.js"],[0,"dist/core/http-dispatcher.js"],[0,"dist/_shared/http-undici-FVPTZA4G.js"],[0,"dist/_shared/http-YFAPTIZD.js"],[11,"dist/utils/node-http-proxy.js"],[11,"dist/_main-e8763182.js"],[11,"dist/_rolldown-runtime-ee51c298.js"],[11,"dist/utils/tls-certificate.js"],[11,"dist/_main-e5c68afc.js"],[11,"dist/_main-e6f8289d.js"],[11,"dist/__atomic_timers/index.js"],[11,"dist/utils/request-admission.js"],[0,"dist/main.js"],[0,"dist/_shared/startup-8-1-QZMXUGHI.js"],[0,"dist/_shared/startup-0-0-4EDVBK5P.js"],[0,"dist/_shared/settings-startup-HXQLSUWM.js"],[0,"dist/core/storage/errors.js"],[1,"dist/builtin-command-names.js"],[0,"dist/core/storage/creation-time.js"],[0,"dist/_shared/startup-0-1-H5IXVRXQ.js"],[11,"dist/index.js"],[11,"dist/_main-ebebe042.js"],[11,"dist/_main-efb2d8b1.js"],[11,"dist/_main-e1febd93.js"],[11,"dist/_main-e19a4fd4.js"],[11,"dist/_main-e97fa51d.js"],[11,"dist/_main-e86630a4.js"],[12,"dist/index.js"],[12,"dist/_main-ed41ae74.js"],[12,"dist/formats/index.js"],[11,"dist/_main-eb65c8f3.js"],[0,"dist/core/storage/prefix.js"],[11,"dist/compat.js"],[11,"dist/_main-ee6805ed.js"],[11,"dist/_main-eadc2e89.js"],[11,"dist/_main-e8d81d97.js"],[11,"dist/_main-e25ab4c1.js"],[11,"dist/_main-ea0cfdb0.js"],[11,"dist/_main-e9cb1a9b.js"],[11,"dist/_main-efc5648c.js"],[11,"dist/_main-e5609ac9.js"],[11,"dist/_main-e671b45b.js"],[11,"dist/_main-eeae834d.js"],[11,"dist/_main-e4600357.js"],[11,"dist/_main-e980bcd9.js"],[11,"dist/_main-e6029ab4.js"],[11,"dist/_main-e9cd87bf.js"],[11,"dist/providers/github-copilot.js"],[11,"dist/utils/responses-errors/codes.js"],[11,"dist/api/azure-openai-config.js"],[11,"dist/utils/provider-env.js"],[11,"dist/utils/typebox/index.js"],[11,"dist/_lazy-e29165e9.js"],[0,"dist/core/storage/added-exports.js"],[0,"dist/core/storage/migrations.js"],[0,"dist/core/storage/added-exports-0-10-11.js"],[0,"dist/core/storage/schema-catalog.js"],[0,"dist/core/storage/statement-sequence.js"],[0,"dist/core/storage/fenced-paths.js"],[0,"dist/core/storage/postgres-locks.js"],[0,"dist/core/storage/sqlite-open-batch.js"],[11,"dist/providers/model-schema.js"],[11,"dist/api/transform-messages.js"],[0,"dist/_shared/startup-0-2-YZZOC22D.js"],[11,"dist/utils/provider-retry.js"],[11,"dist/utils/retry-hints.js"],[13,"dist/index.js"],[13,"dist/_main-e21a102a.js"],[13,"dist/_rolldown-runtime-e937a250.js"],[13,"dist/_main-e35ec52a.js"],[0,"dist/core/storage/file-identity.js"],[11,"dist/api/llama-cpp-classify.lazy.js"],[11,"dist/_lazy-e5876bb5.js"],[11,"dist/api/typesafe-system-one.lazy.js"],[11,"dist/providers/compat-schema.js"],[11,"dist/utils/typebox/compile.js"],[11,"dist/utils/models-dev-catalog.js"],[11,"dist/_lazy-e268270f.js"],[11,"dist/api/anthropic-assistant-content.js"],[11,"dist/utils/typebox/value.js"],[0,"dist/core/storage/libsql-removed.js"],[0,"dist/core/storage/selection.js"],[0,"dist/_shared/startup-0-3-DE2NCS6A.js"],[11,"dist/utils/provider-waits/timeout.js"],[2,"dist/declarations.js"],[2,"dist/identifier.js"],[2,"dist/source.js"],[11,"dist/utils/retry-sleep.js"],[0,"dist/_shared/startup-8-0-34CBHPZH.js"],[0,"dist/core/storage/session/errors.js"],[0,"dist/core/storage/node-sqlite.js"],[0,"dist/core/storage/node-sqlite-file-gate.js"],[0,"dist/core/storage/write-ahead-log.js"],[0,"dist/_shared/startup-0-5-HZX3ZPTP.js"],[0,"dist/_shared/startup-0-4-ZMJV547D.js"],[0,"dist/core/worktree-snapshot/blob-store.js"],[0,"dist/core/storage/statement-batches.js"],[0,"dist/core/worktree-snapshot/collection-claim.js"],[0,"dist/core/worktree-snapshot/fork-blob-guard.js"],[0,"dist/core/worktree-snapshot/fork-snapshot-index.js"],[0,"dist/core/storage/session/fork-schema.js"],[0,"dist/core/worktree-snapshot/snapshot-epoch.js"],[0,"dist/core/worktree-snapshot/snapshot-epoch-migration.js"],[0,"dist/core/storage/provider.js"],[14,"dist/esm/index.min.js"],[11,"dist/providers/all.js"],[11,"dist/providers/openrouter.js"],[11,"dist/api/openai-codex-responses.js"],[11,"dist/_lazy-e13281be.js"],[11,"dist/_lazy-e753c87a.js"],[11,"dist/providers/github-copilot-env.js"],[0,"dist/_shared/startup-15-1-WQZBOTMZ.js"],[0,"dist/_shared/startup-15-0-YUKGAC63.js"],[0,"dist/_shared/startup-14-0-MLX36RBG.js"],[0,"dist/_shared/startup-10-0-TDQNBDDL.js"],[0,"dist/core/session-manager-core.js"],[11,"dist/api/strict-tool-limits.js"],[0,"dist/_shared/session-manager-list-2BLEEZVG.js"],[0,"dist/_shared/startup-12-0-55AAXBJZ.js"],[0,"dist/core/extensions/runner-context.js"],[0,"dist/core/model-registry.js"],[11,"dist/api/anthropic-serialized-body.js"],[0,"dist/cli/settings-startup.js"],[0,"dist/_shared/settings-startup-8-DNZ2RIHM.js"],[0,"dist/modes/interactive/interactive-mode.js"],[0,"dist/_shared/mode-shared-2QJSCUM6.js"],[0,"dist/_shared/mode-interactive-sdk-JXBZ3H27.js"],[1,"dist/layout-node.js"],[0,"dist/modes/rpc/rpc-mode.js"],[0,"dist/_shared/mode-rpc-sdk-IOPGDYR4.js"],[0,"dist/index.js"],[0,"dist/_shared/sdk-BHX35EPK.js"],[0,"dist/core/storage/schema.js"],[11,"dist/api/cloudflare-gateway-binding.js"],[0,"dist/core/storage/sqlite-facade.js"],[11,"dist/utils/oauth-page.js"],[0,"dist/core/storage/index.js"],[0,"dist/core/extensions/loader-virtual-modules.js"],[0,"dist/builtin/intercom/index.bundle.mjs"],[0,"dist/builtin/subagents/src/extension/index.bundle.mjs"],[0,"dist/builtin/mcp/index.bundle.mjs"],[0,"dist/builtin/web-access/index.bundle.mjs"]]}
1
+ {"version":2,"self":"@bastani/atomic","packages":[["@bastani/atomic",-1],["@bastani/atomic-tui",0],["@bastani/atomic-codemode",0],["proper-lockfile",0],["graceful-fs",3],["retry",3],["signal-exit",3],["get-east-asian-width",1],["marked",1],["marked-cjk-friendly",1],["chalk",0],["@bastani/atomic-ai",0],["@bastani/atomic-schema",11],["@bastani/atomic-agent-core",0],["glob",0]],"files":[[0,"dist/modes/interactive-engine/engine-prewarm.js"],[0,"dist/_shared/rolldown-runtime-BGM3D5V3.js"],[0,"dist/_shared/p1a-prewarm-XIU57JHF.js"],[0,"dist/__atomic_timers/index.js"],[0,"dist/_shared/p0-cli-BB45ZQY6.js"],[1,"dist/helper-programs/index.js"],[1,"dist/_main-ea49a2e6.js"],[1,"dist/_rolldown-runtime-e937a250.js"],[1,"dist/_lazy-eb232bf4.js"],[0,"dist/utils/canonical-path.js"],[0,"dist/utils/path-exists.js"],[0,"dist/utils/worker-threads.js"],[2,"dist/node-options.js"],[0,"dist/_shared/p1-shared-RG5I5LJ6.js"],[0,"dist/core/storage/node-sqlite-thread.js"],[0,"dist/core/storage/dialect.js"],[0,"dist/modes/interactive/startup-shell-eligibility.js"],[0,"dist/_shared/p1b-elig-BY2G5BUE.js"],[3,"index.js"],[0,"dist/_shared/p1-elig-shell-WWRO3L2R.js"],[3,"lib/lockfile.js"],[4,"graceful-fs.js"],[4,"polyfills.js"],[4,"legacy-streams.js"],[4,"clone.js"],[5,"index.js"],[5,"lib/retry.js"],[5,"lib/retry_operation.js"],[6,"index.js"],[6,"signals.js"],[3,"lib/mtime-precision.js"],[3,"lib/adapter.js"],[0,"dist/modes/interactive/startup-shell.js"],[0,"dist/_shared/p2-shell-TJBYQMCJ.js"],[1,"dist/index.js"],[1,"dist/_main-e4228e6a.js"],[1,"dist/_main-e85c88b3.js"],[7,"index.js"],[7,"lookup.js"],[7,"lookup-data.js"],[7,"utilities.js"],[1,"dist/_main-edb90e85.js"],[1,"dist/_main-edf509ab.js"],[1,"dist/_main-e9d2ce9e.js"],[1,"dist/__atomic_timers/index.js"],[1,"dist/_main-e881e236.js"],[1,"dist/_main-ec15befe.js"],[1,"dist/_main-e101663a.js"],[8,"lib/marked.esm.js"],[9,"dist/index.js"],[1,"dist/_main-e4a71c51.js"],[1,"dist/_main-ec8edda6.js"],[1,"dist/native-modifiers.js"],[1,"dist/native-platform.js"],[1,"dist/native-module-path.js"],[1,"dist/_main-e41da700.js"],[0,"dist/_shared/p2-shell-main-B2WIALFD.js"],[10,"source/index.js"],[10,"source/utilities.js"],[10,"source/vendor/ansi-styles/index.js"],[10,"source/vendor/supports-color/index.js"],[0,"dist/utils/memoize-async.js"],[0,"dist/_shared/p2-common-YLSYXMDQ.js"],[0,"dist/utils/startup-stages.js"],[0,"dist/_shared/p3a-stages-66VAGJL3.js"],[0,"dist/core/http-dispatcher.js"],[0,"dist/_shared/http-undici-FVPTZA4G.js"],[0,"dist/_shared/http-YFAPTIZD.js"],[11,"dist/utils/node-http-proxy.js"],[11,"dist/_main-e25f9883.js"],[11,"dist/_rolldown-runtime-ee51c298.js"],[11,"dist/utils/tls-certificate.js"],[11,"dist/_main-ee338024.js"],[11,"dist/_main-e6f8289d.js"],[11,"dist/__atomic_timers/index.js"],[11,"dist/utils/request-admission.js"],[0,"dist/main.js"],[0,"dist/_shared/startup-8-1-QZMXUGHI.js"],[0,"dist/_shared/startup-0-0-FPPQF42L.js"],[0,"dist/_shared/settings-startup-HXQLSUWM.js"],[0,"dist/core/storage/errors.js"],[1,"dist/builtin-command-names.js"],[0,"dist/core/storage/creation-time.js"],[0,"dist/_shared/startup-0-1-Q7GBLBEL.js"],[11,"dist/index.js"],[11,"dist/_main-ebebe042.js"],[11,"dist/_main-efb2d8b1.js"],[11,"dist/_main-e1febd93.js"],[11,"dist/_main-e19a4fd4.js"],[11,"dist/_main-ebd8ef17.js"],[11,"dist/_main-e86630a4.js"],[12,"dist/index.js"],[12,"dist/_main-ed41ae74.js"],[12,"dist/formats/index.js"],[11,"dist/_main-e47cd2cb.js"],[0,"dist/core/storage/prefix.js"],[11,"dist/compat.js"],[11,"dist/_main-eeae5f76.js"],[11,"dist/_main-ea63adcc.js"],[11,"dist/_main-ef7e00b0.js"],[11,"dist/_main-e2767acc.js"],[11,"dist/_main-e8dca082.js"],[11,"dist/_main-ef44fc21.js"],[11,"dist/_main-e1f98913.js"],[11,"dist/_main-ecad4dcf.js"],[11,"dist/_main-ed949a21.js"],[11,"dist/_main-eb02ee9d.js"],[11,"dist/_main-ea8fff80.js"],[11,"dist/_main-e980bcd9.js"],[11,"dist/_main-e43e618b.js"],[11,"dist/_main-e3317d05.js"],[11,"dist/providers/github-copilot.js"],[11,"dist/utils/responses-errors/codes.js"],[11,"dist/api/azure-openai-config.js"],[11,"dist/utils/provider-env.js"],[11,"dist/utils/typebox/index.js"],[11,"dist/_lazy-e29165e9.js"],[0,"dist/core/storage/added-exports.js"],[0,"dist/core/storage/migrations.js"],[0,"dist/core/storage/added-exports-0-10-11.js"],[0,"dist/core/storage/schema-catalog.js"],[0,"dist/core/storage/statement-sequence.js"],[0,"dist/core/storage/fenced-paths.js"],[0,"dist/core/storage/postgres-locks.js"],[0,"dist/core/storage/sqlite-open-batch.js"],[11,"dist/providers/model-schema.js"],[11,"dist/api/transform-messages.js"],[0,"dist/_shared/startup-0-2-JNYN24UI.js"],[11,"dist/utils/provider-retry.js"],[11,"dist/utils/retry-hints.js"],[13,"dist/index.js"],[13,"dist/_main-e21a102a.js"],[13,"dist/_rolldown-runtime-e937a250.js"],[13,"dist/_main-e35ec52a.js"],[0,"dist/core/storage/file-identity.js"],[11,"dist/api/llama-cpp-classify.lazy.js"],[11,"dist/_lazy-e5876bb5.js"],[11,"dist/api/typesafe-system-one.lazy.js"],[11,"dist/providers/compat-schema.js"],[11,"dist/utils/typebox/compile.js"],[11,"dist/utils/models-dev-catalog.js"],[11,"dist/_lazy-ef8fa05f.js"],[11,"dist/api/anthropic-assistant-content.js"],[11,"dist/utils/typebox/value.js"],[0,"dist/core/storage/libsql-removed.js"],[0,"dist/core/storage/selection.js"],[0,"dist/_shared/startup-0-3-DE2NCS6A.js"],[11,"dist/utils/provider-waits/timeout.js"],[2,"dist/declarations.js"],[2,"dist/identifier.js"],[2,"dist/source.js"],[11,"dist/utils/retry-sleep.js"],[0,"dist/_shared/startup-8-0-34CBHPZH.js"],[0,"dist/core/storage/session/errors.js"],[0,"dist/core/storage/node-sqlite.js"],[0,"dist/core/storage/node-sqlite-file-gate.js"],[0,"dist/core/storage/write-ahead-log.js"],[0,"dist/_shared/startup-0-5-WN2IYA25.js"],[0,"dist/_shared/startup-0-4-ZZXFKE55.js"],[0,"dist/core/worktree-snapshot/blob-store.js"],[0,"dist/core/storage/statement-batches.js"],[0,"dist/core/worktree-snapshot/collection-claim.js"],[0,"dist/core/worktree-snapshot/fork-blob-guard.js"],[0,"dist/core/worktree-snapshot/fork-snapshot-index.js"],[0,"dist/core/storage/session/fork-schema.js"],[0,"dist/core/worktree-snapshot/snapshot-epoch.js"],[0,"dist/core/worktree-snapshot/snapshot-epoch-migration.js"],[0,"dist/core/storage/provider.js"],[14,"dist/esm/index.min.js"],[11,"dist/providers/all.js"],[11,"dist/providers/openrouter.js"],[11,"dist/api/openai-codex-responses.js"],[11,"dist/_lazy-efef7863.js"],[11,"dist/_lazy-ed51826a.js"],[11,"dist/providers/github-copilot-env.js"],[0,"dist/_shared/startup-15-1-WQZBOTMZ.js"],[0,"dist/_shared/startup-15-0-E7RYG5YF.js"],[0,"dist/_shared/startup-14-0-MLX36RBG.js"],[0,"dist/_shared/startup-10-0-O6DAT7U4.js"],[0,"dist/core/session-manager-core.js"],[11,"dist/api/strict-tool-limits.js"],[0,"dist/_shared/session-manager-list-2BLEEZVG.js"],[0,"dist/_shared/startup-12-0-55AAXBJZ.js"],[0,"dist/core/extensions/runner-context.js"],[0,"dist/core/model-registry.js"],[11,"dist/api/anthropic-serialized-body.js"],[0,"dist/cli/settings-startup.js"],[0,"dist/_shared/settings-startup-8-DNZ2RIHM.js"],[0,"dist/modes/interactive/interactive-mode.js"],[0,"dist/_shared/mode-shared-2QJSCUM6.js"],[0,"dist/_shared/mode-interactive-sdk-JXBZ3H27.js"],[1,"dist/layout-node.js"],[1,"dist/layout.js"],[0,"dist/modes/rpc/rpc-mode.js"],[0,"dist/_shared/mode-rpc-sdk-IOPGDYR4.js"],[0,"dist/index.js"],[0,"dist/_shared/sdk-5ZFNDXUJ.js"],[0,"dist/core/storage/schema.js"],[11,"dist/api/cloudflare-gateway-binding.js"],[0,"dist/core/storage/sqlite-facade.js"],[11,"dist/utils/oauth-page.js"],[0,"dist/core/storage/index.js"],[0,"dist/core/extensions/loader-virtual-modules.js"],[0,"dist/builtin/intercom/index.bundle.mjs"],[0,"dist/builtin/subagents/src/extension/index.bundle.mjs"],[0,"dist/builtin/mcp/index.bundle.mjs"],[0,"dist/builtin/web-access/index.bundle.mjs"]]}
@@ -1 +1 @@
1
- import "../_shared/startup-0-5-HZX3ZPTP.js";
1
+ import "../_shared/startup-0-5-WN2IYA25.js";
@@ -1 +1 @@
1
- import "../_shared/startup-0-0-4EDVBK5P.js";
1
+ import "../_shared/startup-0-0-FPPQF42L.js";
@@ -1,4 +1,4 @@
1
- import "../_shared/startup-0-1-H5IXVRXQ.js";
1
+ import "../_shared/startup-0-1-Q7GBLBEL.js";
2
2
  import "@bastani/atomic-ai/utils/provider-retry";
3
3
  import "@bastani/atomic-ai/utils/retry-hints";
4
4
  import "@bastani/atomic-agent-core";
@@ -1,4 +1,4 @@
1
- import "../_shared/startup-0-2-YZZOC22D.js";
1
+ import "../_shared/startup-0-2-JNYN24UI.js";
2
2
  import "../_shared/startup-0-3-DE2NCS6A.js";
3
3
  import "../core/storage/node-sqlite-file-gate.js";
4
4
  import "../core/storage/write-ahead-log.js";
@@ -1,3 +1,3 @@
1
1
  import "../_shared/startup-8-0-34CBHPZH.js";
2
- import "../_shared/startup-0-4-ZMJV547D.js";
2
+ import "../_shared/startup-0-4-ZZXFKE55.js";
3
3
  import "../core/storage/provider.js";
@@ -1,11 +1,11 @@
1
1
  import "../_shared/rolldown-runtime-BGM3D5V3.js";
2
2
  import { readFileSync } from "node:fs";
3
3
  import { join } from "node:path";
4
- import { parseArgs } from "../_shared/startup-0-1-H5IXVRXQ.js";
4
+ import { parseArgs } from "../_shared/startup-0-1-Q7GBLBEL.js";
5
5
  import { CONFIG_DIR_NAME, ENV_AGENT_DIR, INTERACTIVE_ENGINE_PREWARM_NO_DATABASE, getEnvNames, isPlainInteractiveSessionInvocation, normalizePath, stripBom } from "../_shared/p0-cli-BB45ZQY6.js";
6
6
  import { parseConfigCommand } from "../_shared/config-command-parser-XRBNVMBV.js";
7
- import { previewProcessStorageSelection, previewSessionSettingSelection } from "../_shared/startup-0-2-YZZOC22D.js";
8
- import { parsePackageCommand } from "../_shared/startup-0-0-4EDVBK5P.js";
7
+ import { previewProcessStorageSelection, previewSessionSettingSelection } from "../_shared/startup-0-2-JNYN24UI.js";
8
+ import { parsePackageCommand } from "../_shared/startup-0-0-FPPQF42L.js";
9
9
  // dist/utils/startup-database-spare.js
10
10
  const DIRECT_SUBCOMMANDS = /* @__PURE__ */ new Set([
11
11
  "auth",
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("../", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("../", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
@@ -1,3 +1,3 @@
1
1
  import "../_shared/rolldown-runtime-BGM3D5V3.js";
2
- export { GIT_RELEASE, detectLinuxLibc, ensureTool, getGitDistributionTarget, getGitInstallDir, getGitReleaseMarker, getGitShellEnvironment, getGitShellEnvironmentAsync, getGitStatus, getGitStatusAsync, getLatestVersion, getToolEnv, getToolPath, parseGitVersion, plainStatMtimeMs, resetGitProvisionStateForTest, resolveGit, resolveGitSync, resolveInstalledGit, withGitProvisionSettingsForTest } from "../_shared/startup-0-1-H5IXVRXQ.js";
2
+ export { GIT_RELEASE, detectLinuxLibc, ensureTool, getGitDistributionTarget, getGitInstallDir, getGitReleaseMarker, getGitShellEnvironment, getGitShellEnvironmentAsync, getGitStatus, getGitStatusAsync, getLatestVersion, getToolEnv, getToolPath, parseGitVersion, plainStatMtimeMs, resetGitProvisionStateForTest, resolveGit, resolveGitSync, resolveInstalledGit, withGitProvisionSettingsForTest } from "../_shared/startup-0-1-Q7GBLBEL.js";
3
3
  //# sourceMappingURL=tools-manager.code.js.map
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("../", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
@@ -6,7 +6,7 @@ try {
6
6
  } catch (error) {
7
7
  const root = new URL("../", import.meta.url);
8
8
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
9
- const key = `${root.href}#0.10.19`;
9
+ const key = `${root.href}#0.10.20-alpha.1`;
10
10
  let release = releases.get(key);
11
11
  if (release === undefined) {
12
12
  const current = (async () => {
@@ -27,8 +27,8 @@ try {
27
27
  release = current;
28
28
  }
29
29
  const running = await release;
30
- if (running === undefined || running.version === "0.10.19") throw error;
31
- throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.19 while this session was running; restart it to keep using this feature.", {
30
+ if (running === undefined || running.version === "0.10.20-alpha.1") throw error;
31
+ throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.20-alpha.1 while this session was running; restart it to keep using this feature.", {
32
32
  cause: error,
33
33
  });
34
34
  }
@@ -10,6 +10,29 @@ description: "What's new in Atomic"
10
10
  The publish-release skill regenerates this page as part of preparing the release PR.
11
11
  */}
12
12
 
13
+ <Update label="November 28, 2026" description="0.10.20-alpha.1">
14
+
15
+ Atomic remembers your subscription usage across sessions and makes long conversations faster and easier to reopen.
16
+
17
+ **Subscription usage**
18
+
19
+ - **See your subscriptions together.** `/usage` shows signed-in subscription accounts in one panel without interrupting your reply. With SQLite or PostgreSQL, Atomic remembers the latest figures across sessions and restarts, and shows `0% used` after a window resets until fresh figures arrive ([#6865](https://github.com/bastani-inc/atomic/pull/6865)).
20
+ - **Know when a usage figure is missing.** CLI JSON, RPC, and SDK reports say whether each account has figures and when Atomic last saw them. The [usage guide](/guides/subscription-usage) shows how to read the reports from a script ([#6865](https://github.com/bastani-inc/atomic/pull/6865), [#6876](https://github.com/bastani-inc/atomic/pull/6876)).
21
+ - **Keep saved usage through a slow sign-in refresh.** Atomic no longer loses your last figures if a refresh finishes after its timeout, and startup no longer overwrites sign-in changes another process just saved ([#6872](https://github.com/bastani-inc/atomic/pull/6872)).
22
+
23
+ **Sessions and background work**
24
+
25
+ - **Resume long sessions faster.** Atomic reads archived history in fewer batches, especially on shared PostgreSQL, while keeping earlier messages available and restoring interrupted subagents ([#6866](https://github.com/bastani-inc/atomic/pull/6866)).
26
+ - **See progress while a session opens.** Slow opens, switches, forks, and reloads show a loading line that matches your theme. Fast loads stay quiet ([#6867](https://github.com/bastani-inc/atomic/pull/6867)).
27
+ - **Open sessions with damaged history.** Atomic warns and starts a separate branch instead of hanging on a broken link. The original entries stay in saved history ([#6868](https://github.com/bastani-inc/atomic/pull/6868)).
28
+ - **Quit without losing background results.** `/quit` closes cleanly even when a finished task is waiting to report back. Its result is available when you reopen the session ([#6870](https://github.com/bastani-inc/atomic/pull/6870)).
29
+
30
+ **Model options**
31
+
32
+ - **Use Low thinking on more Qwen Token Plan models.** Select Low for DeepSeek V4 Flash 0731 or DeepSeek V4 Pro 0813 ([#6864](https://github.com/bastani-inc/atomic/pull/6864)).
33
+
34
+ </Update>
35
+
13
36
  <Update label="November 28, 2026" description="0.10.19">
14
37
 
15
38
  Atomic makes subscription limits easier to check, native installs easier to update or roll back, and edits and model replies more reliable.
@@ -204,6 +204,12 @@ if (usage && usage.tokens !== null && usage.tokens > 100_000) {
204
204
  }
205
205
  ```
206
206
 
207
+ ### ctx.getSubscriptionUsage(options?)
208
+
209
+ Returns the [usage report](/guides/subscription-usage#json-and-sdk-contract) for the session’s configured accounts. By default it checks every account. Pass `accounts` for specific provider IDs, `maxAgeMs: 0` to check again, or `signal` to cancel.
210
+
211
+ Each account has `availability`, either `"available"` or `"unavailable"`. For example, `{ availability: "available", observedAt: "2026-11-28T16:30:00.000Z" }` says figures were available at that time. The existing `status` describes the outcome of the check.
212
+
207
213
  ### ctx.compact()
208
214
 
209
215
  Trigger compaction without awaiting completion. By default it clears the active context window so the agent recovers details from session history; when a compactor model is configured, the compactor's output replaces the context.
@@ -4,60 +4,32 @@ sidebarTitle: "Subscription usage"
4
4
  description: "See how much of your AI subscriptions you have used and when the limits reset."
5
5
  ---
6
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.
7
+ Type `/usage` to see your signed-in subscription accounts while a reply keeps running. API-key accounts do not appear. Each account shows how much of its allowance you have used and when it resets. If Atomic has no figures yet, the account says **Not available**.
8
8
 
9
9
  ```text
10
10
  Subscription usage
11
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.
12
+ Anthropic account 2 · anthropic-2
13
+ Weekly (7 d) ████░░░░░░░░ 37% used Resets in 3 d 20 h · Wed 1:00 PM
19
14
 
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. |
15
+ OpenAI Codex · openai-codex
16
+ Not available
32
17
 
33
- ### If an account has no usage numbers
18
+ Esc close r refresh
19
+ ```
34
20
 
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.
21
+ New figures can appear while the panel is open. Atomic remembers the last figures it received. If a window has reset since then, it shows `0% used` without guessing the next reset time. Times are local.
36
22
 
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. |
23
+ Press `r` to check again or `Esc` to close. When the panel shows `↑ ↓ scroll`, use the arrow keys or mouse wheel. The **Fullscreen scrollbar** setting applies to the panel and the chat. Checking usage never spends reset credits. For this chat’s token counts and costs, use `/session` instead.
48
24
 
49
25
  ## Check from a script
50
26
 
51
- Use the text report in a terminal and the JSON report in scripts. Neither starts a chat.
52
-
53
27
  ```bash
54
28
  atomic usage
55
29
  atomic usage --json
56
30
  ```
57
31
 
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).
32
+ The first command prints a readable report. The second prints one JSON object. Both list all configured accounts, including API keys, without starting a chat. Add `--offline` to check without contacting providers. If there are no accounts, the JSON report is `{"accounts":[]}`. An [RPC client](/rpc/protocol#get_usage) can read the same report from an open session.
61
33
 
62
34
  ```json
63
35
  {
@@ -67,20 +39,12 @@ Add `--offline` to list accounts without contacting providers. If you have not s
67
39
  "name": "OpenAI Codex",
68
40
  "current": true,
69
41
  "status": "ready",
70
- "source": "live",
42
+ "availability": "available",
43
+ "source": "stored",
44
+ "observedAt": "2026-11-28T16:30:00.000Z",
71
45
  "windows": [
72
- { "label": "Session", "usedPercent": 42.5, "durationSeconds": 18000, "resetsAt": "2026-11-28T16:30:00.000Z" },
73
46
  { "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."
47
+ ]
84
48
  }
85
49
  ]
86
50
  }
@@ -88,46 +52,28 @@ Add `--offline` to list accounts without contacting providers. If you have not s
88
52
 
89
53
  ### JSON and SDK contract
90
54
 
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.
55
+ The CLI, RPC, SDK, and extension reports use the same account fields. They never include credentials or raw provider replies.
92
56
 
93
57
  | Field | Meaning |
94
58
  | --- | --- |
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.
59
+ | `provider`, `name`, `current` | The account ID, display name, and whether it is selected. |
60
+ | `availability` | `"available"` or `"unavailable"`. An API-key account can be available without any subscription windows. |
61
+ | `status` | The outcome of the check: `"ready"`, `"unavailable"`, or `"failed"`. A report can contain all three. |
62
+ | `observedAt` | When Atomic learned these figures, in UTC. Check it if you need to know how old the figures are. |
63
+ | `source` | `"live"` for a provider check, `"recent_response"` for a reply used as a fallback, `"last_request"` for figures from the last OpenAI API request, or `"stored"` for the last saved figures. |
64
+ | `windows` | The limits the provider reported. An unknown length (`durationSeconds`) or reset time (`resetsAt`) is `null`. |
65
+ | `plan`, `credits`, `resetCredits`, `extraUsage`, `creditCap`, `unlimitedWindows`, `rateLimits` | More details when the provider reports them. `rateLimits` are request or token limits, not subscription windows. |
66
+ | `reason`, `message` | Additional details for scripts that need them. |
107
67
 
108
68
  ## Check from the SDK
109
69
 
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
70
  ```typescript
113
71
  import { getSubscriptionUsage } from "@bastani/atomic";
114
72
 
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.");
73
+ const { accounts } = await getSubscriptionUsage({ accounts: ["openai-codex"] });
74
+ for (const account of accounts) {
75
+ if (account.status === "ready") console.log(account.name, account.windows);
76
+ }
129
77
  ```
130
78
 
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.
79
+ Omit `accounts` to check all configured accounts. Pass `maxAgeMs: 0` to check again instead of reusing a recent provider check. Extensions can call `ctx.getSubscriptionUsage()` for the accounts in their session.
@@ -368,7 +368,9 @@ The credential print commands emit one configured credential for an external cli
368
368
 
369
369
  ## Subscription usage
370
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.
371
+ Run `atomic usage` for a readable report or `atomic usage --json` for the same report as one JSON object. Neither starts a chat. Both include configured API-key accounts. Add `--offline` to see the last known figures without contacting providers.
372
+
373
+ Each account has `availability`, either `"available"` or `"unavailable"`. For example, `{"availability":"available","observedAt":"2026-11-28T16:30:00.000Z"}` says figures were available at that time. The existing `status` still describes the outcome of the check. See [Check subscription usage](/guides/subscription-usage) for a full example.
372
374
 
373
375
  ## MCP commands
374
376
 
@@ -258,12 +258,40 @@ Key fields on `data`:
258
258
 
259
259
  #### get_usage
260
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.
261
+ Use `get_usage` to show account usage in an app connected to Atomic, without interrupting a reply. Omit `provider` to check all configured accounts, including API keys. Set `refresh` to `true` to check again instead of reusing a recent check.
262
+
263
+ For example, check Codex usage in an offline session that uses Codex:
262
264
 
263
265
  ```json
264
- {"type":"get_usage","id":"report","refresh":true}
266
+ {"id":"report","type":"get_usage","provider":"openai-codex"}
265
267
  ```
266
268
 
269
+ If Atomic has not saved any figures for this account, the reply looks like this:
270
+
271
+ ```json
272
+ {
273
+ "id": "report",
274
+ "type": "response",
275
+ "command": "get_usage",
276
+ "success": true,
277
+ "data": {
278
+ "accounts": [
279
+ {
280
+ "provider": "openai-codex",
281
+ "name": "OpenAI Codex",
282
+ "current": true,
283
+ "status": "unavailable",
284
+ "availability": "unavailable",
285
+ "reason": "offline",
286
+ "message": "Usage checks are off in offline mode."
287
+ }
288
+ ]
289
+ }
290
+ }
291
+ ```
292
+
293
+ `data` has the same [report fields](/guides/subscription-usage#json-and-sdk-contract) as `atomic usage --json`. Each account's `availability` is `"available"` or `"unavailable"`; an API-key account can be available without subscription windows. `success: true` means Atomic returned a report, even when an account has no figures or its check failed. Read the account's `reason` or `message` for details. An error of `Could not read subscription accounts.` with `success: false` means Atomic could not make the report at all.
294
+
267
295
  #### get_messages
268
296
 
269
297
  Return all messages in the active conversation branch.