@bastani/atomic 0.9.20-alpha.3 → 0.9.20-alpha.5

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 (930) hide show
  1. package/CHANGELOG.md +150 -0
  2. package/README.md +15 -7
  3. package/dist/builtin/intercom/CHANGELOG.md +24 -0
  4. package/dist/builtin/intercom/README.md +2 -2
  5. package/dist/builtin/intercom/broker/send-handler.ts +59 -2
  6. package/dist/builtin/intercom/index.bundle.mjs +101 -16
  7. package/dist/builtin/intercom/package.json +3 -3
  8. package/dist/builtin/intercom/session-target.ts +34 -9
  9. package/dist/builtin/intercom/skills/intercom/SKILL.md +36 -5
  10. package/dist/builtin/mcp/CHANGELOG.md +13 -0
  11. package/dist/builtin/mcp/OAUTH.md +1 -1
  12. package/dist/builtin/mcp/README.md +3 -1
  13. package/dist/builtin/mcp/index.bundle.mjs +412 -64
  14. package/dist/builtin/mcp/package.json +3 -3
  15. package/dist/builtin/subagents/CHANGELOG.md +39 -0
  16. package/dist/builtin/subagents/README.md +4 -2
  17. package/dist/builtin/subagents/agents/code-simplifier.md +3 -4
  18. package/dist/builtin/subagents/agents/codebase-analyzer.md +3 -4
  19. package/dist/builtin/subagents/agents/codebase-locator.md +2 -3
  20. package/dist/builtin/subagents/agents/codebase-online-researcher.md +5 -6
  21. package/dist/builtin/subagents/agents/codebase-pattern-finder.md +2 -3
  22. package/dist/builtin/subagents/agents/codebase-research-analyzer.md +2 -3
  23. package/dist/builtin/subagents/agents/codebase-research-locator.md +2 -3
  24. package/dist/builtin/subagents/agents/debugger.md +8 -7
  25. package/dist/builtin/subagents/agents/worker.md +5 -4
  26. package/dist/builtin/subagents/package.json +4 -8
  27. package/dist/builtin/subagents/skills/agent-browser/SKILL.md +56 -0
  28. package/dist/builtin/subagents/skills/subagent/SKILL.md +45 -19
  29. package/dist/builtin/subagents/src/extension/index.bundle.mjs +255 -66
  30. package/dist/builtin/web-access/CHANGELOG.md +12 -0
  31. package/dist/builtin/web-access/index.bundle.mjs +367 -295
  32. package/dist/builtin/web-access/package.json +3 -3
  33. package/dist/builtin/workflows/CHANGELOG.md +98 -0
  34. package/dist/builtin/workflows/README.md +33 -32
  35. package/dist/builtin/workflows/builtin/adversarial-verification.js +3 -3
  36. package/dist/builtin/workflows/builtin/{chunk-xtxcq5tj.js → chunk-00ywx588.js} +17 -1
  37. package/dist/builtin/workflows/builtin/{chunk-z29qbehr.js → chunk-55p5dxjk.js} +4 -6
  38. package/dist/builtin/workflows/builtin/chunk-7f381xnq.js +9760 -0
  39. package/dist/builtin/workflows/builtin/{chunk-wf741bv3.js → chunk-7h7s5xdj.js} +4 -6
  40. package/dist/builtin/workflows/builtin/{chunk-a2kdsqn8.js → chunk-e83tc6nr.js} +2 -2
  41. package/dist/builtin/workflows/builtin/{chunk-6w6cvk6b.js → chunk-evfb0312.js} +4 -6
  42. package/dist/builtin/workflows/builtin/{chunk-fg9esgkj.js → chunk-ne6vh5ct.js} +4 -6
  43. package/dist/builtin/workflows/builtin/{chunk-yeee2jrc.js → chunk-pfm1kgqz.js} +66 -88
  44. package/dist/builtin/workflows/builtin/{chunk-zqtm1d2c.js → chunk-tdqvdrg1.js} +13 -218
  45. package/dist/builtin/workflows/builtin/{chunk-g0csgs7w.js → chunk-tvcydq13.js} +8 -10
  46. package/dist/builtin/workflows/builtin/{chunk-31j2gs7h.js → chunk-x2nftpgj.js} +4 -6
  47. package/dist/builtin/workflows/builtin/{chunk-ewkkkbak.js → chunk-zj5162bh.js} +10 -92
  48. package/dist/builtin/workflows/builtin/classify-and-act.js +3 -3
  49. package/dist/builtin/workflows/builtin/fan-out-and-synthesize.js +3 -3
  50. package/dist/builtin/workflows/builtin/generate-and-filter.js +3 -3
  51. package/dist/builtin/workflows/builtin/goal.js +4 -4
  52. package/dist/builtin/workflows/builtin/index.d.ts +1 -1
  53. package/dist/builtin/workflows/builtin/index.js +12 -12
  54. package/dist/builtin/workflows/builtin/loop-until-done.js +3 -3
  55. package/dist/builtin/workflows/builtin/open-claude-design.d.ts +1 -1
  56. package/dist/builtin/workflows/builtin/open-claude-design.js +3 -3
  57. package/dist/builtin/workflows/builtin/ralph.js +4 -4
  58. package/dist/builtin/workflows/builtin/steering-context.js +1 -1
  59. package/dist/builtin/workflows/builtin/tournament.js +3 -3
  60. package/dist/builtin/workflows/package.json +3 -3
  61. package/dist/builtin/workflows/skills/impeccable/SKILL.md +18 -11
  62. package/dist/builtin/workflows/skills/impeccable/reference/adapt.md +1 -1
  63. package/dist/builtin/workflows/skills/impeccable/reference/adapt.native.md +1 -1
  64. package/dist/builtin/workflows/skills/impeccable/reference/animate.md +1 -1
  65. package/dist/builtin/workflows/skills/impeccable/reference/audit.md +5 -5
  66. package/dist/builtin/workflows/skills/impeccable/reference/audit.native.md +6 -6
  67. package/dist/builtin/workflows/skills/impeccable/reference/bolder.md +2 -2
  68. package/dist/builtin/workflows/skills/impeccable/reference/clarify.md +1 -1
  69. package/dist/builtin/workflows/skills/impeccable/reference/colorize.md +1 -1
  70. package/dist/builtin/workflows/skills/impeccable/reference/craft-floor.md +0 -6
  71. package/dist/builtin/workflows/skills/impeccable/reference/critique.md +19 -41
  72. package/dist/builtin/workflows/skills/impeccable/reference/degraded/asset-producer.md +11 -65
  73. package/dist/builtin/workflows/skills/impeccable/reference/degraded/documenter.md +3 -3
  74. package/dist/builtin/workflows/skills/impeccable/reference/degraded/finish-reviewer.md +4 -4
  75. package/dist/builtin/workflows/skills/impeccable/reference/degraded/manual-edit-applier.md +1 -1
  76. package/dist/builtin/workflows/skills/impeccable/reference/delight.md +1 -1
  77. package/dist/builtin/workflows/skills/impeccable/reference/distill.md +2 -2
  78. package/dist/builtin/workflows/skills/impeccable/reference/doctor.md +4 -4
  79. package/dist/builtin/workflows/skills/impeccable/reference/document.md +4 -4
  80. package/dist/builtin/workflows/skills/impeccable/reference/extract.md +1 -1
  81. package/dist/builtin/workflows/skills/impeccable/reference/harden.md +1 -1
  82. package/dist/builtin/workflows/skills/impeccable/reference/hooks.md +21 -21
  83. package/dist/builtin/workflows/skills/impeccable/reference/init.md +8 -8
  84. package/dist/builtin/workflows/skills/impeccable/reference/layout.md +2 -2
  85. package/dist/builtin/workflows/skills/impeccable/reference/live-setup.md +10 -8
  86. package/dist/builtin/workflows/skills/impeccable/reference/live.md +39 -38
  87. package/dist/builtin/workflows/skills/impeccable/reference/new-work.md +48 -21
  88. package/dist/builtin/workflows/skills/impeccable/reference/onboard.md +1 -1
  89. package/dist/builtin/workflows/skills/impeccable/reference/optimize.md +1 -1
  90. package/dist/builtin/workflows/skills/impeccable/reference/overdrive.md +1 -1
  91. package/dist/builtin/workflows/skills/impeccable/reference/polish.md +11 -3
  92. package/dist/builtin/workflows/skills/impeccable/reference/quieter.md +2 -2
  93. package/dist/builtin/workflows/skills/impeccable/reference/routing.md +13 -7
  94. package/dist/builtin/workflows/skills/impeccable/reference/typeset.md +2 -2
  95. package/dist/builtin/workflows/skills/impeccable/reference/visualize.md +13 -19
  96. package/dist/builtin/workflows/skills/impeccable/scripts/VERSION +1 -0
  97. package/dist/builtin/workflows/skills/impeccable/scripts/data/font-index-failures.json +121 -0
  98. package/dist/builtin/workflows/skills/impeccable/scripts/data/font-index.json +1 -0
  99. package/dist/builtin/workflows/skills/impeccable/scripts/impeccable +212 -0
  100. package/dist/builtin/workflows/skills/impeccable/scripts/impeccable.cmd +218 -0
  101. package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-dom.js +21 -0
  102. package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-ignores.js +242 -0
  103. package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-session.js +25 -4
  104. package/dist/builtin/workflows/skills/impeccable/scripts/live-browser.js +666 -197
  105. package/dist/builtin/workflows/skills/research-codebase/SKILL.md +1 -1
  106. package/dist/builtin/workflows/src/authoring.d.ts +2 -0
  107. package/dist/builtin/workflows/src/durable/dependency-doctor-types.d.ts +42 -0
  108. package/dist/builtin/workflows/src/extension/index.bundle.mjs +82204 -78828
  109. package/dist/builtin/workflows/src/index.js +8938 -1200
  110. package/dist/builtin/workflows/src/shared/authoring-contract-stage.d.ts +11 -0
  111. package/dist/builtin/workflows/src/shared/authoring-contract-ui.d.ts +4 -1
  112. package/dist/cli/args.js +2 -2
  113. package/dist/cli/args.js.map +1 -1
  114. package/dist/config.d.ts +1 -0
  115. package/dist/config.d.ts.map +1 -1
  116. package/dist/config.js +1 -0
  117. package/dist/config.js.map +1 -1
  118. package/dist/core/agent-session-accessors.d.ts.map +1 -1
  119. package/dist/core/agent-session-accessors.js +2 -1
  120. package/dist/core/agent-session-accessors.js.map +1 -1
  121. package/dist/core/agent-session-auto-compaction.d.ts.map +1 -1
  122. package/dist/core/agent-session-auto-compaction.js +9 -2
  123. package/dist/core/agent-session-auto-compaction.js.map +1 -1
  124. package/dist/core/agent-session-bash.d.ts +3 -1
  125. package/dist/core/agent-session-bash.d.ts.map +1 -1
  126. package/dist/core/agent-session-bash.js +18 -6
  127. package/dist/core/agent-session-bash.js.map +1 -1
  128. package/dist/core/agent-session-compaction.d.ts.map +1 -1
  129. package/dist/core/agent-session-compaction.js +25 -8
  130. package/dist/core/agent-session-compaction.js.map +1 -1
  131. package/dist/core/agent-session-events.d.ts +6 -6
  132. package/dist/core/agent-session-events.d.ts.map +1 -1
  133. package/dist/core/agent-session-events.js +145 -62
  134. package/dist/core/agent-session-events.js.map +1 -1
  135. package/dist/core/agent-session-export.d.ts +1 -1
  136. package/dist/core/agent-session-export.d.ts.map +1 -1
  137. package/dist/core/agent-session-export.js +18 -19
  138. package/dist/core/agent-session-export.js.map +1 -1
  139. package/dist/core/agent-session-extension-bindings.d.ts +3 -2
  140. package/dist/core/agent-session-extension-bindings.d.ts.map +1 -1
  141. package/dist/core/agent-session-extension-bindings.js +274 -70
  142. package/dist/core/agent-session-extension-bindings.js.map +1 -1
  143. package/dist/core/agent-session-message-queue.d.ts +1 -1
  144. package/dist/core/agent-session-message-queue.d.ts.map +1 -1
  145. package/dist/core/agent-session-message-queue.js +30 -4
  146. package/dist/core/agent-session-message-queue.js.map +1 -1
  147. package/dist/core/agent-session-methods.d.ts +19 -11
  148. package/dist/core/agent-session-methods.d.ts.map +1 -1
  149. package/dist/core/agent-session-methods.js.map +1 -1
  150. package/dist/core/agent-session-models.d.ts +2 -2
  151. package/dist/core/agent-session-models.d.ts.map +1 -1
  152. package/dist/core/agent-session-models.js +38 -29
  153. package/dist/core/agent-session-models.js.map +1 -1
  154. package/dist/core/agent-session-persistent-custom-messages.d.ts +1 -1
  155. package/dist/core/agent-session-persistent-custom-messages.js.map +1 -1
  156. package/dist/core/agent-session-post-tool-compaction.d.ts.map +1 -1
  157. package/dist/core/agent-session-post-tool-compaction.js +18 -1
  158. package/dist/core/agent-session-post-tool-compaction.js.map +1 -1
  159. package/dist/core/agent-session-prompt.d.ts +1 -1
  160. package/dist/core/agent-session-prompt.d.ts.map +1 -1
  161. package/dist/core/agent-session-prompt.js +104 -22
  162. package/dist/core/agent-session-prompt.js.map +1 -1
  163. package/dist/core/agent-session-queue-pause.d.ts +2 -0
  164. package/dist/core/agent-session-queue-pause.d.ts.map +1 -1
  165. package/dist/core/agent-session-queue-pause.js +13 -2
  166. package/dist/core/agent-session-queue-pause.js.map +1 -1
  167. package/dist/core/agent-session-retry.d.ts +0 -3
  168. package/dist/core/agent-session-retry.d.ts.map +1 -1
  169. package/dist/core/agent-session-retry.js +24 -11
  170. package/dist/core/agent-session-retry.js.map +1 -1
  171. package/dist/core/agent-session-runtime-auth.d.ts.map +1 -1
  172. package/dist/core/agent-session-runtime-auth.js +10 -0
  173. package/dist/core/agent-session-runtime-auth.js.map +1 -1
  174. package/dist/core/agent-session-runtime.d.ts +17 -1
  175. package/dist/core/agent-session-runtime.d.ts.map +1 -1
  176. package/dist/core/agent-session-runtime.js +428 -197
  177. package/dist/core/agent-session-runtime.js.map +1 -1
  178. package/dist/core/agent-session-services.d.ts +4 -0
  179. package/dist/core/agent-session-services.d.ts.map +1 -1
  180. package/dist/core/agent-session-services.js +31 -2
  181. package/dist/core/agent-session-services.js.map +1 -1
  182. package/dist/core/agent-session-state.d.ts +10 -2
  183. package/dist/core/agent-session-state.d.ts.map +1 -1
  184. package/dist/core/agent-session-state.js +32 -22
  185. package/dist/core/agent-session-state.js.map +1 -1
  186. package/dist/core/agent-session-summary.d.ts.map +1 -1
  187. package/dist/core/agent-session-summary.js +9 -2
  188. package/dist/core/agent-session-summary.js.map +1 -1
  189. package/dist/core/agent-session-tasks.d.ts +1 -0
  190. package/dist/core/agent-session-tasks.d.ts.map +1 -1
  191. package/dist/core/agent-session-tasks.js +24 -3
  192. package/dist/core/agent-session-tasks.js.map +1 -1
  193. package/dist/core/agent-session-tool-hooks.d.ts.map +1 -1
  194. package/dist/core/agent-session-tool-hooks.js +26 -3
  195. package/dist/core/agent-session-tool-hooks.js.map +1 -1
  196. package/dist/core/agent-session-tool-registry.d.ts.map +1 -1
  197. package/dist/core/agent-session-tool-registry.js +0 -2
  198. package/dist/core/agent-session-tool-registry.js.map +1 -1
  199. package/dist/core/agent-session-transfer.js.map +1 -1
  200. package/dist/core/agent-session-tree.d.ts.map +1 -1
  201. package/dist/core/agent-session-tree.js +6 -0
  202. package/dist/core/agent-session-tree.js.map +1 -1
  203. package/dist/core/agent-session-types.d.ts +5 -0
  204. package/dist/core/agent-session-types.d.ts.map +1 -1
  205. package/dist/core/agent-session-types.js.map +1 -1
  206. package/dist/core/agent-session.d.ts +15 -8
  207. package/dist/core/agent-session.d.ts.map +1 -1
  208. package/dist/core/agent-session.js +113 -66
  209. package/dist/core/agent-session.js.map +1 -1
  210. package/dist/core/auth-storage.d.ts +5 -3
  211. package/dist/core/auth-storage.d.ts.map +1 -1
  212. package/dist/core/auth-storage.js +18 -5
  213. package/dist/core/auth-storage.js.map +1 -1
  214. package/dist/core/builtin-diagnostics.d.ts +2 -0
  215. package/dist/core/builtin-diagnostics.d.ts.map +1 -0
  216. package/dist/core/builtin-diagnostics.js +14 -0
  217. package/dist/core/builtin-diagnostics.js.map +1 -0
  218. package/dist/core/builtin-packages.d.ts +5 -2
  219. package/dist/core/builtin-packages.d.ts.map +1 -1
  220. package/dist/core/builtin-packages.js +24 -3
  221. package/dist/core/builtin-packages.js.map +1 -1
  222. package/dist/core/builtin-resource-loader.d.ts +4 -0
  223. package/dist/core/builtin-resource-loader.d.ts.map +1 -0
  224. package/dist/core/builtin-resource-loader.js +239 -0
  225. package/dist/core/builtin-resource-loader.js.map +1 -0
  226. package/dist/core/cache-retention.d.ts +4 -0
  227. package/dist/core/cache-retention.d.ts.map +1 -0
  228. package/dist/core/cache-retention.js +58 -0
  229. package/dist/core/cache-retention.js.map +1 -0
  230. package/dist/core/cache-stats.d.ts.map +1 -1
  231. package/dist/core/cache-stats.js +11 -0
  232. package/dist/core/cache-stats.js.map +1 -1
  233. package/dist/core/cache-warmer.d.ts +66 -0
  234. package/dist/core/cache-warmer.d.ts.map +1 -0
  235. package/dist/core/cache-warmer.js +313 -0
  236. package/dist/core/cache-warmer.js.map +1 -0
  237. package/dist/core/child-session-options.d.ts +5 -0
  238. package/dist/core/child-session-options.d.ts.map +1 -0
  239. package/dist/core/child-session-options.js +30 -0
  240. package/dist/core/child-session-options.js.map +1 -0
  241. package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
  242. package/dist/core/compaction/branch-summarization.js +2 -2
  243. package/dist/core/compaction/branch-summarization.js.map +1 -1
  244. package/dist/core/compaction/compaction-boundary.d.ts.map +1 -1
  245. package/dist/core/compaction/compaction-boundary.js +2 -1
  246. package/dist/core/compaction/compaction-boundary.js.map +1 -1
  247. package/dist/core/compaction/compaction.d.ts.map +1 -1
  248. package/dist/core/compaction/compaction.js +18 -0
  249. package/dist/core/compaction/compaction.js.map +1 -1
  250. package/dist/core/compaction/fallback-planner.d.ts +1 -0
  251. package/dist/core/compaction/fallback-planner.d.ts.map +1 -1
  252. package/dist/core/compaction/fallback-planner.js +2 -0
  253. package/dist/core/compaction/fallback-planner.js.map +1 -1
  254. package/dist/core/compaction/range-planner.d.ts.map +1 -1
  255. package/dist/core/compaction/range-planner.js +3 -3
  256. package/dist/core/compaction/range-planner.js.map +1 -1
  257. package/dist/core/compaction/session-summarization.d.ts.map +1 -1
  258. package/dist/core/compaction/session-summarization.js +2 -1
  259. package/dist/core/compaction/session-summarization.js.map +1 -1
  260. package/dist/core/credential-screening.d.ts +17 -0
  261. package/dist/core/credential-screening.d.ts.map +1 -0
  262. package/dist/core/credential-screening.js +30 -0
  263. package/dist/core/credential-screening.js.map +1 -0
  264. package/dist/core/decision-provider.d.ts +4 -0
  265. package/dist/core/decision-provider.d.ts.map +1 -0
  266. package/dist/core/decision-provider.js +12 -0
  267. package/dist/core/decision-provider.js.map +1 -0
  268. package/dist/core/execution-model-router.d.ts +30 -0
  269. package/dist/core/execution-model-router.d.ts.map +1 -0
  270. package/dist/core/execution-model-router.js +191 -0
  271. package/dist/core/execution-model-router.js.map +1 -0
  272. package/dist/core/extensions/agent-events.d.ts +4 -4
  273. package/dist/core/extensions/agent-events.d.ts.map +1 -1
  274. package/dist/core/extensions/agent-events.js.map +1 -1
  275. package/dist/core/extensions/api-types.d.ts +46 -40
  276. package/dist/core/extensions/api-types.d.ts.map +1 -1
  277. package/dist/core/extensions/api-types.js.map +1 -1
  278. package/dist/core/extensions/context-types.d.ts +7 -1
  279. package/dist/core/extensions/context-types.d.ts.map +1 -1
  280. package/dist/core/extensions/context-types.js.map +1 -1
  281. package/dist/core/extensions/event-results.d.ts +7 -6
  282. package/dist/core/extensions/event-results.d.ts.map +1 -1
  283. package/dist/core/extensions/event-results.js.map +1 -1
  284. package/dist/core/extensions/event-types.d.ts +2 -1
  285. package/dist/core/extensions/event-types.d.ts.map +1 -1
  286. package/dist/core/extensions/event-types.js.map +1 -1
  287. package/dist/core/extensions/extension-work.d.ts +14 -0
  288. package/dist/core/extensions/extension-work.d.ts.map +1 -0
  289. package/dist/core/extensions/extension-work.js +73 -0
  290. package/dist/core/extensions/extension-work.js.map +1 -0
  291. package/dist/core/extensions/herdr-file-integration.d.ts +36 -0
  292. package/dist/core/extensions/herdr-file-integration.d.ts.map +1 -0
  293. package/dist/core/extensions/herdr-file-integration.js +60 -0
  294. package/dist/core/extensions/herdr-file-integration.js.map +1 -0
  295. package/dist/core/extensions/host-input.d.ts +51 -0
  296. package/dist/core/extensions/host-input.d.ts.map +1 -0
  297. package/dist/core/extensions/host-input.js +211 -0
  298. package/dist/core/extensions/host-input.js.map +1 -0
  299. package/dist/core/extensions/index.d.ts +4 -2
  300. package/dist/core/extensions/index.d.ts.map +1 -1
  301. package/dist/core/extensions/index.js +0 -3
  302. package/dist/core/extensions/index.js.map +1 -1
  303. package/dist/core/extensions/jiti-loader.d.ts +2 -0
  304. package/dist/core/extensions/jiti-loader.d.ts.map +1 -0
  305. package/dist/core/extensions/jiti-loader.js +3 -0
  306. package/dist/core/extensions/jiti-loader.js.map +1 -0
  307. package/dist/core/extensions/jiti-static-loader.d.ts +2 -0
  308. package/dist/core/extensions/jiti-static-loader.d.ts.map +1 -0
  309. package/dist/core/extensions/jiti-static-loader.js +3 -0
  310. package/dist/core/extensions/jiti-static-loader.js.map +1 -0
  311. package/dist/core/extensions/loader-api.d.ts +7 -0
  312. package/dist/core/extensions/loader-api.d.ts.map +1 -1
  313. package/dist/core/extensions/loader-api.js +154 -28
  314. package/dist/core/extensions/loader-api.js.map +1 -1
  315. package/dist/core/extensions/loader-bindings.d.ts +24 -0
  316. package/dist/core/extensions/loader-bindings.d.ts.map +1 -0
  317. package/dist/core/extensions/loader-bindings.js +128 -0
  318. package/dist/core/extensions/loader-bindings.js.map +1 -0
  319. package/dist/core/extensions/loader-core.d.ts +2 -1
  320. package/dist/core/extensions/loader-core.d.ts.map +1 -1
  321. package/dist/core/extensions/loader-core.js +91 -14
  322. package/dist/core/extensions/loader-core.js.map +1 -1
  323. package/dist/core/extensions/loader-host-modules.d.ts.map +1 -1
  324. package/dist/core/extensions/loader-host-modules.js +3 -1
  325. package/dist/core/extensions/loader-host-modules.js.map +1 -1
  326. package/dist/core/extensions/loader-rollback.d.ts +14 -0
  327. package/dist/core/extensions/loader-rollback.d.ts.map +1 -0
  328. package/dist/core/extensions/loader-rollback.js +95 -0
  329. package/dist/core/extensions/loader-rollback.js.map +1 -0
  330. package/dist/core/extensions/loader-runtime.d.ts +3 -1
  331. package/dist/core/extensions/loader-runtime.d.ts.map +1 -1
  332. package/dist/core/extensions/loader-runtime.js +38 -14
  333. package/dist/core/extensions/loader-runtime.js.map +1 -1
  334. package/dist/core/extensions/loader-virtual-modules.d.ts.map +1 -1
  335. package/dist/core/extensions/loader-virtual-modules.js +9 -2
  336. package/dist/core/extensions/loader-virtual-modules.js.map +1 -1
  337. package/dist/core/extensions/loader.d.ts +1 -1
  338. package/dist/core/extensions/loader.d.ts.map +1 -1
  339. package/dist/core/extensions/loader.js +1 -1
  340. package/dist/core/extensions/loader.js.map +1 -1
  341. package/dist/core/extensions/reactive-widget.d.ts +1 -1
  342. package/dist/core/extensions/reactive-widget.js.map +1 -1
  343. package/dist/core/extensions/runner-context.d.ts +4 -0
  344. package/dist/core/extensions/runner-context.d.ts.map +1 -1
  345. package/dist/core/extensions/runner-context.js +25 -0
  346. package/dist/core/extensions/runner-context.js.map +1 -1
  347. package/dist/core/extensions/runner-events.d.ts +8 -4
  348. package/dist/core/extensions/runner-events.d.ts.map +1 -1
  349. package/dist/core/extensions/runner-events.js +55 -53
  350. package/dist/core/extensions/runner-events.js.map +1 -1
  351. package/dist/core/extensions/runner-project-trust.d.ts.map +1 -1
  352. package/dist/core/extensions/runner-project-trust.js +2 -4
  353. package/dist/core/extensions/runner-project-trust.js.map +1 -1
  354. package/dist/core/extensions/runner.d.ts +31 -4
  355. package/dist/core/extensions/runner.d.ts.map +1 -1
  356. package/dist/core/extensions/runner.js +219 -23
  357. package/dist/core/extensions/runner.js.map +1 -1
  358. package/dist/core/extensions/runtime-types.d.ts +2 -0
  359. package/dist/core/extensions/runtime-types.d.ts.map +1 -1
  360. package/dist/core/extensions/runtime-types.js.map +1 -1
  361. package/dist/core/extensions/types.d.ts +3 -2
  362. package/dist/core/extensions/types.d.ts.map +1 -1
  363. package/dist/core/extensions/types.js +0 -12
  364. package/dist/core/extensions/types.js.map +1 -1
  365. package/dist/core/extensions/workflow-activity-hub.d.ts +2 -0
  366. package/dist/core/extensions/workflow-activity-hub.d.ts.map +1 -1
  367. package/dist/core/extensions/workflow-activity-hub.js +5 -3
  368. package/dist/core/extensions/workflow-activity-hub.js.map +1 -1
  369. package/dist/core/extensions/wrapper.d.ts.map +1 -1
  370. package/dist/core/extensions/wrapper.js +5 -3
  371. package/dist/core/extensions/wrapper.js.map +1 -1
  372. package/dist/core/fast-model-routing.d.ts +3 -3
  373. package/dist/core/fast-model-routing.d.ts.map +1 -1
  374. package/dist/core/fast-model-routing.js +3 -3
  375. package/dist/core/fast-model-routing.js.map +1 -1
  376. package/dist/core/fast-model-variants.d.ts +4 -0
  377. package/dist/core/fast-model-variants.d.ts.map +1 -1
  378. package/dist/core/fast-model-variants.js +3 -0
  379. package/dist/core/fast-model-variants.js.map +1 -1
  380. package/dist/core/index.d.ts +4 -1
  381. package/dist/core/index.d.ts.map +1 -1
  382. package/dist/core/index.js +2 -0
  383. package/dist/core/index.js.map +1 -1
  384. package/dist/core/mandatory-resource-loader.d.ts +4 -0
  385. package/dist/core/mandatory-resource-loader.d.ts.map +1 -1
  386. package/dist/core/mandatory-resource-loader.js +29 -1
  387. package/dist/core/mandatory-resource-loader.js.map +1 -1
  388. package/dist/core/mandatory-runtime-tools.d.ts +1 -4
  389. package/dist/core/mandatory-runtime-tools.d.ts.map +1 -1
  390. package/dist/core/mandatory-runtime-tools.js +1 -9
  391. package/dist/core/mandatory-runtime-tools.js.map +1 -1
  392. package/dist/core/messages.d.ts.map +1 -1
  393. package/dist/core/messages.js +8 -1
  394. package/dist/core/messages.js.map +1 -1
  395. package/dist/core/model-config.d.ts +41 -10
  396. package/dist/core/model-config.d.ts.map +1 -1
  397. package/dist/core/model-config.js +11 -2
  398. package/dist/core/model-config.js.map +1 -1
  399. package/dist/core/model-registry.d.ts +4 -2
  400. package/dist/core/model-registry.d.ts.map +1 -1
  401. package/dist/core/model-registry.js +6 -2
  402. package/dist/core/model-registry.js.map +1 -1
  403. package/dist/core/model-routing-constraints.d.ts +24 -0
  404. package/dist/core/model-routing-constraints.d.ts.map +1 -0
  405. package/dist/core/model-routing-constraints.js +46 -0
  406. package/dist/core/model-routing-constraints.js.map +1 -0
  407. package/dist/core/model-routing-task.d.ts +4 -0
  408. package/dist/core/model-routing-task.d.ts.map +1 -0
  409. package/dist/core/model-routing-task.js +77 -0
  410. package/dist/core/model-routing-task.js.map +1 -0
  411. package/dist/core/model-runtime-streaming.d.ts +13 -3
  412. package/dist/core/model-runtime-streaming.d.ts.map +1 -1
  413. package/dist/core/model-runtime-streaming.js +15 -5
  414. package/dist/core/model-runtime-streaming.js.map +1 -1
  415. package/dist/core/model-runtime-types.d.ts +2 -2
  416. package/dist/core/model-runtime-types.d.ts.map +1 -1
  417. package/dist/core/model-runtime-types.js.map +1 -1
  418. package/dist/core/model-runtime.d.ts +6 -3
  419. package/dist/core/model-runtime.d.ts.map +1 -1
  420. package/dist/core/model-runtime.js +29 -2
  421. package/dist/core/model-runtime.js.map +1 -1
  422. package/dist/core/provider-composer-internal.d.ts +3 -2
  423. package/dist/core/provider-composer-internal.d.ts.map +1 -1
  424. package/dist/core/provider-composer-internal.js +2 -0
  425. package/dist/core/provider-composer-internal.js.map +1 -1
  426. package/dist/core/provider-composer.d.ts.map +1 -1
  427. package/dist/core/provider-composer.js.map +1 -1
  428. package/dist/core/resolve-config-value.d.ts +2 -0
  429. package/dist/core/resolve-config-value.d.ts.map +1 -1
  430. package/dist/core/resolve-config-value.js +23 -1
  431. package/dist/core/resolve-config-value.js.map +1 -1
  432. package/dist/core/resource-loader-core.d.ts +6 -0
  433. package/dist/core/resource-loader-core.d.ts.map +1 -1
  434. package/dist/core/resource-loader-core.js +37 -6
  435. package/dist/core/resource-loader-core.js.map +1 -1
  436. package/dist/core/resource-loader-extensions.d.ts.map +1 -1
  437. package/dist/core/resource-loader-extensions.js +2 -0
  438. package/dist/core/resource-loader-extensions.js.map +1 -1
  439. package/dist/core/resource-loader-reload.d.ts.map +1 -1
  440. package/dist/core/resource-loader-reload.js +7 -2
  441. package/dist/core/resource-loader-reload.js.map +1 -1
  442. package/dist/core/resource-loader.d.ts +1 -1
  443. package/dist/core/resource-loader.d.ts.map +1 -1
  444. package/dist/core/resource-loader.js +1 -1
  445. package/dist/core/resource-loader.js.map +1 -1
  446. package/dist/core/runtime-credentials.d.ts +2 -0
  447. package/dist/core/runtime-credentials.d.ts.map +1 -1
  448. package/dist/core/runtime-credentials.js +15 -0
  449. package/dist/core/runtime-credentials.js.map +1 -1
  450. package/dist/core/sdk-types.d.ts +13 -5
  451. package/dist/core/sdk-types.d.ts.map +1 -1
  452. package/dist/core/sdk-types.js.map +1 -1
  453. package/dist/core/sdk.d.ts +3 -1
  454. package/dist/core/sdk.d.ts.map +1 -1
  455. package/dist/core/sdk.js +211 -37
  456. package/dist/core/sdk.js.map +1 -1
  457. package/dist/core/session-lifecycle-scope.d.ts +15 -0
  458. package/dist/core/session-lifecycle-scope.d.ts.map +1 -0
  459. package/dist/core/session-lifecycle-scope.js +13 -0
  460. package/dist/core/session-lifecycle-scope.js.map +1 -0
  461. package/dist/core/session-lifecycle-work.d.ts +17 -0
  462. package/dist/core/session-lifecycle-work.d.ts.map +1 -0
  463. package/dist/core/session-lifecycle-work.js +144 -0
  464. package/dist/core/session-lifecycle-work.js.map +1 -0
  465. package/dist/core/session-manager-core.d.ts +8 -4
  466. package/dist/core/session-manager-core.d.ts.map +1 -1
  467. package/dist/core/session-manager-core.js +27 -3
  468. package/dist/core/session-manager-core.js.map +1 -1
  469. package/dist/core/session-manager-history.d.ts.map +1 -1
  470. package/dist/core/session-manager-history.js +3 -0
  471. package/dist/core/session-manager-history.js.map +1 -1
  472. package/dist/core/session-manager-list.d.ts +3 -3
  473. package/dist/core/session-manager-list.d.ts.map +1 -1
  474. package/dist/core/session-manager-list.js +89 -74
  475. package/dist/core/session-manager-list.js.map +1 -1
  476. package/dist/core/session-manager-storage.d.ts.map +1 -1
  477. package/dist/core/session-manager-storage.js +10 -7
  478. package/dist/core/session-manager-storage.js.map +1 -1
  479. package/dist/core/session-manager-types.d.ts +13 -3
  480. package/dist/core/session-manager-types.d.ts.map +1 -1
  481. package/dist/core/session-manager-types.js.map +1 -1
  482. package/dist/core/session-manager.d.ts +1 -1
  483. package/dist/core/session-manager.d.ts.map +1 -1
  484. package/dist/core/session-manager.js.map +1 -1
  485. package/dist/core/session-startup-rollback.d.ts +5 -0
  486. package/dist/core/session-startup-rollback.d.ts.map +1 -0
  487. package/dist/core/session-startup-rollback.js +16 -0
  488. package/dist/core/session-startup-rollback.js.map +1 -0
  489. package/dist/core/settings-manager-basic-accessors.d.ts +5 -0
  490. package/dist/core/settings-manager-basic-accessors.d.ts.map +1 -1
  491. package/dist/core/settings-manager-basic-accessors.js +35 -0
  492. package/dist/core/settings-manager-basic-accessors.js.map +1 -1
  493. package/dist/core/settings-manager-core.d.ts.map +1 -1
  494. package/dist/core/settings-manager-core.js +4 -0
  495. package/dist/core/settings-manager-core.js.map +1 -1
  496. package/dist/core/settings-manager.d.ts +1 -0
  497. package/dist/core/settings-manager.d.ts.map +1 -1
  498. package/dist/core/settings-manager.js +1 -0
  499. package/dist/core/settings-manager.js.map +1 -1
  500. package/dist/core/settings-types.d.ts +4 -0
  501. package/dist/core/settings-types.d.ts.map +1 -1
  502. package/dist/core/settings-types.js +1 -1
  503. package/dist/core/settings-types.js.map +1 -1
  504. package/dist/core/settings-write-ownership.d.ts +7 -0
  505. package/dist/core/settings-write-ownership.d.ts.map +1 -0
  506. package/dist/core/settings-write-ownership.js +24 -0
  507. package/dist/core/settings-write-ownership.js.map +1 -0
  508. package/dist/core/slash-commands.js +1 -1
  509. package/dist/core/slash-commands.js.map +1 -1
  510. package/dist/core/structured-output/index.d.ts +12 -0
  511. package/dist/core/structured-output/index.d.ts.map +1 -0
  512. package/dist/core/structured-output/index.js +251 -0
  513. package/dist/core/structured-output/index.js.map +1 -0
  514. package/dist/core/structured-output/invalid-output.d.ts +8 -0
  515. package/dist/core/structured-output/invalid-output.d.ts.map +1 -0
  516. package/dist/core/structured-output/invalid-output.js +4 -0
  517. package/dist/core/structured-output/invalid-output.js.map +1 -0
  518. package/dist/core/structured-output/jev-client.d.ts +20 -0
  519. package/dist/core/structured-output/jev-client.d.ts.map +1 -0
  520. package/dist/core/structured-output/jev-client.js +116 -0
  521. package/dist/core/structured-output/jev-client.js.map +1 -0
  522. package/dist/core/structured-output/jev.d.ts +5 -0
  523. package/dist/core/structured-output/jev.d.ts.map +1 -0
  524. package/dist/core/structured-output/jev.js +275 -0
  525. package/dist/core/structured-output/jev.js.map +1 -0
  526. package/dist/core/structured-output/resolver.d.ts +41 -0
  527. package/dist/core/structured-output/resolver.d.ts.map +1 -0
  528. package/dist/core/structured-output/resolver.js +56 -0
  529. package/dist/core/structured-output/resolver.js.map +1 -0
  530. package/dist/core/structured-output/types.d.ts +68 -0
  531. package/dist/core/structured-output/types.d.ts.map +1 -0
  532. package/dist/core/structured-output/types.js +2 -0
  533. package/dist/core/structured-output/types.js.map +1 -0
  534. package/dist/core/system-prompt.d.ts +48 -5
  535. package/dist/core/system-prompt.d.ts.map +1 -1
  536. package/dist/core/system-prompt.js +132 -100
  537. package/dist/core/system-prompt.js.map +1 -1
  538. package/dist/core/tasks/contracts.d.ts +6 -0
  539. package/dist/core/tasks/contracts.d.ts.map +1 -1
  540. package/dist/core/tasks/contracts.js.map +1 -1
  541. package/dist/core/tasks/supervisor.d.ts.map +1 -1
  542. package/dist/core/tasks/supervisor.js +7 -0
  543. package/dist/core/tasks/supervisor.js.map +1 -1
  544. package/dist/core/tools/ask-user-question/ask-user-question.d.ts +4 -1
  545. package/dist/core/tools/ask-user-question/ask-user-question.d.ts.map +1 -1
  546. package/dist/core/tools/ask-user-question/ask-user-question.js +31 -35
  547. package/dist/core/tools/ask-user-question/ask-user-question.js.map +1 -1
  548. package/dist/core/tools/ask-user-question/index.d.ts +1 -1
  549. package/dist/core/tools/ask-user-question/index.js.map +1 -1
  550. package/dist/core/tools/ask-user-question/state/build-questionnaire.d.ts +1 -1
  551. package/dist/core/tools/ask-user-question/state/build-questionnaire.js.map +1 -1
  552. package/dist/core/tools/ask-user-question/state/key-router.d.ts +1 -1
  553. package/dist/core/tools/ask-user-question/state/key-router.js.map +1 -1
  554. package/dist/core/tools/ask-user-question/state/questionnaire-session.d.ts +1 -1
  555. package/dist/core/tools/ask-user-question/state/questionnaire-session.js.map +1 -1
  556. package/dist/core/tools/ask-user-question/state/row-intent.d.ts +1 -1
  557. package/dist/core/tools/ask-user-question/state/row-intent.js.map +1 -1
  558. package/dist/core/tools/ask-user-question/state/selectors/contract.d.ts +1 -1
  559. package/dist/core/tools/ask-user-question/state/selectors/contract.js.map +1 -1
  560. package/dist/core/tools/ask-user-question/state/selectors/derivations.d.ts +1 -1
  561. package/dist/core/tools/ask-user-question/state/selectors/derivations.js.map +1 -1
  562. package/dist/core/tools/ask-user-question/state/state-reducer.d.ts +1 -1
  563. package/dist/core/tools/ask-user-question/state/state-reducer.js.map +1 -1
  564. package/dist/core/tools/ask-user-question/state/state.d.ts +1 -1
  565. package/dist/core/tools/ask-user-question/state/state.js.map +1 -1
  566. package/dist/core/tools/ask-user-question/tool/format-answer.d.ts +1 -1
  567. package/dist/core/tools/ask-user-question/tool/format-answer.js.map +1 -1
  568. package/dist/core/tools/ask-user-question/tool/response-envelope.d.ts +1 -1
  569. package/dist/core/tools/ask-user-question/tool/response-envelope.js.map +1 -1
  570. package/dist/core/tools/ask-user-question/tool/validate-questionnaire.d.ts +1 -1
  571. package/dist/core/tools/ask-user-question/tool/validate-questionnaire.js.map +1 -1
  572. package/dist/core/tools/ask-user-question/view/components/multi-select-view.d.ts +1 -1
  573. package/dist/core/tools/ask-user-question/view/components/multi-select-view.js.map +1 -1
  574. package/dist/core/tools/ask-user-question/view/components/preview/markdown-content-cache.d.ts +1 -1
  575. package/dist/core/tools/ask-user-question/view/components/preview/markdown-content-cache.js.map +1 -1
  576. package/dist/core/tools/ask-user-question/view/components/preview/preview-block-renderer.d.ts +1 -1
  577. package/dist/core/tools/ask-user-question/view/components/preview/preview-block-renderer.js.map +1 -1
  578. package/dist/core/tools/ask-user-question/view/components/preview/preview-layout-decider.d.ts +1 -1
  579. package/dist/core/tools/ask-user-question/view/components/preview/preview-layout-decider.js.map +1 -1
  580. package/dist/core/tools/ask-user-question/view/components/preview/preview-pane.d.ts +1 -1
  581. package/dist/core/tools/ask-user-question/view/components/preview/preview-pane.js.map +1 -1
  582. package/dist/core/tools/ask-user-question/view/components/submit-picker.js.map +1 -1
  583. package/dist/core/tools/ask-user-question/view/components/wrapping-select.js.map +1 -1
  584. package/dist/core/tools/ask-user-question/view/dialog-builder.d.ts +1 -1
  585. package/dist/core/tools/ask-user-question/view/dialog-builder.js.map +1 -1
  586. package/dist/core/tools/ask-user-question/view/props-adapter.d.ts +1 -1
  587. package/dist/core/tools/ask-user-question/view/props-adapter.js.map +1 -1
  588. package/dist/core/tools/ask-user-question/view/tab-content-strategy.d.ts +1 -1
  589. package/dist/core/tools/ask-user-question/view/tab-content-strategy.js.map +1 -1
  590. package/dist/core/tools/bash.d.ts.map +1 -1
  591. package/dist/core/tools/bash.js +16 -11
  592. package/dist/core/tools/bash.js.map +1 -1
  593. package/dist/core/tools/find.d.ts +2 -2
  594. package/dist/core/tools/find.d.ts.map +1 -1
  595. package/dist/core/tools/find.js +1 -1
  596. package/dist/core/tools/find.js.map +1 -1
  597. package/dist/core/usage-totals.d.ts.map +1 -1
  598. package/dist/core/usage-totals.js +4 -0
  599. package/dist/core/usage-totals.js.map +1 -1
  600. package/dist/extensions/herdr/index.d.ts.map +1 -1
  601. package/dist/extensions/herdr/index.js +0 -7
  602. package/dist/extensions/herdr/index.js.map +1 -1
  603. package/dist/extensions/llama/client.d.ts +2 -0
  604. package/dist/extensions/llama/client.d.ts.map +1 -1
  605. package/dist/extensions/llama/client.js +6 -2
  606. package/dist/extensions/llama/client.js.map +1 -1
  607. package/dist/extensions/llama/provider.d.ts.map +1 -1
  608. package/dist/extensions/llama/provider.js +18 -4
  609. package/dist/extensions/llama/provider.js.map +1 -1
  610. package/dist/index.d.ts +11 -2
  611. package/dist/index.d.ts.map +1 -1
  612. package/dist/index.js +6 -1
  613. package/dist/index.js.map +1 -1
  614. package/dist/main-session.d.ts.map +1 -1
  615. package/dist/main-session.js +19 -10
  616. package/dist/main-session.js.map +1 -1
  617. package/dist/main.d.ts.map +1 -1
  618. package/dist/main.js +4 -5
  619. package/dist/main.js.map +1 -1
  620. package/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -1
  621. package/dist/modes/interactive/components/branch-summary-message.js +12 -5
  622. package/dist/modes/interactive/components/branch-summary-message.js.map +1 -1
  623. package/dist/modes/interactive/components/chat-message-renderer.d.ts +5 -1
  624. package/dist/modes/interactive/components/chat-message-renderer.d.ts.map +1 -1
  625. package/dist/modes/interactive/components/chat-message-renderer.js +4 -0
  626. package/dist/modes/interactive/components/chat-message-renderer.js.map +1 -1
  627. package/dist/modes/interactive/components/chat-session-host-events.d.ts +2 -2
  628. package/dist/modes/interactive/components/chat-session-host-events.js.map +1 -1
  629. package/dist/modes/interactive/components/compaction-boundary-message.d.ts.map +1 -1
  630. package/dist/modes/interactive/components/compaction-boundary-message.js +17 -9
  631. package/dist/modes/interactive/components/compaction-boundary-message.js.map +1 -1
  632. package/dist/modes/interactive/components/custom-editor.d.ts +6 -0
  633. package/dist/modes/interactive/components/custom-editor.d.ts.map +1 -1
  634. package/dist/modes/interactive/components/custom-editor.js +17 -0
  635. package/dist/modes/interactive/components/custom-editor.js.map +1 -1
  636. package/dist/modes/interactive/components/host-input-form-mount.d.ts +1 -1
  637. package/dist/modes/interactive/components/host-input-form-mount.js.map +1 -1
  638. package/dist/modes/interactive/components/host-input-form.d.ts +1 -1
  639. package/dist/modes/interactive/components/host-input-form.js.map +1 -1
  640. package/dist/modes/interactive/components/host-session-picker.d.ts +1 -1
  641. package/dist/modes/interactive/components/host-session-picker.js.map +1 -1
  642. package/dist/modes/interactive/components/reserved-bottom-overlay.d.ts +1 -1
  643. package/dist/modes/interactive/components/reserved-bottom-overlay.js.map +1 -1
  644. package/dist/modes/interactive/components/scroll-widget.d.ts +1 -1
  645. package/dist/modes/interactive/components/scroll-widget.js.map +1 -1
  646. package/dist/modes/interactive/components/settings-selector-handlers.d.ts.map +1 -1
  647. package/dist/modes/interactive/components/settings-selector-handlers.js +3 -0
  648. package/dist/modes/interactive/components/settings-selector-handlers.js.map +1 -1
  649. package/dist/modes/interactive/components/settings-selector-items.d.ts.map +1 -1
  650. package/dist/modes/interactive/components/settings-selector-items.js +50 -1
  651. package/dist/modes/interactive/components/settings-selector-items.js.map +1 -1
  652. package/dist/modes/interactive/components/settings-selector-submenus.d.ts.map +1 -1
  653. package/dist/modes/interactive/components/settings-selector-submenus.js +2 -1
  654. package/dist/modes/interactive/components/settings-selector-submenus.js.map +1 -1
  655. package/dist/modes/interactive/components/settings-selector-types.d.ts +6 -1
  656. package/dist/modes/interactive/components/settings-selector-types.d.ts.map +1 -1
  657. package/dist/modes/interactive/components/settings-selector-types.js.map +1 -1
  658. package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -1
  659. package/dist/modes/interactive/components/skill-invocation-message.js +11 -4
  660. package/dist/modes/interactive/components/skill-invocation-message.js.map +1 -1
  661. package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
  662. package/dist/modes/interactive/components/tool-execution.js +14 -9
  663. package/dist/modes/interactive/components/tool-execution.js.map +1 -1
  664. package/dist/modes/interactive/interactive-auth-login.js +1 -1
  665. package/dist/modes/interactive/interactive-auth-login.js.map +1 -1
  666. package/dist/modes/interactive/interactive-auth-routing.js +2 -2
  667. package/dist/modes/interactive/interactive-auth-routing.js.map +1 -1
  668. package/dist/modes/interactive/interactive-autocomplete.js +4 -0
  669. package/dist/modes/interactive/interactive-autocomplete.js.map +1 -1
  670. package/dist/modes/interactive/interactive-bash-compact.d.ts.map +1 -1
  671. package/dist/modes/interactive/interactive-bash-compact.js +13 -6
  672. package/dist/modes/interactive/interactive-bash-compact.js.map +1 -1
  673. package/dist/modes/interactive/interactive-extension-runtime.js +5 -0
  674. package/dist/modes/interactive/interactive-extension-runtime.js.map +1 -1
  675. package/dist/modes/interactive/interactive-input-handling.js +2 -2
  676. package/dist/modes/interactive/interactive-input-handling.js.map +1 -1
  677. package/dist/modes/interactive/interactive-mode-deps.d.ts +1 -1
  678. package/dist/modes/interactive/interactive-mode-deps.d.ts.map +1 -1
  679. package/dist/modes/interactive/interactive-mode-deps.js +1 -1
  680. package/dist/modes/interactive/interactive-mode-deps.js.map +1 -1
  681. package/dist/modes/interactive/interactive-mode-surface.d.ts +1 -1
  682. package/dist/modes/interactive/interactive-mode-surface.d.ts.map +1 -1
  683. package/dist/modes/interactive/interactive-mode-surface.js.map +1 -1
  684. package/dist/modes/interactive/interactive-render-chat.js +27 -25
  685. package/dist/modes/interactive/interactive-render-chat.js.map +1 -1
  686. package/dist/modes/interactive/interactive-selectors.js +10 -0
  687. package/dist/modes/interactive/interactive-selectors.js.map +1 -1
  688. package/dist/modes/interactive/interactive-startup.d.ts.map +1 -1
  689. package/dist/modes/interactive/interactive-startup.js +2 -2
  690. package/dist/modes/interactive/interactive-startup.js.map +1 -1
  691. package/dist/modes/interactive/interactive-tui.js.map +1 -1
  692. package/dist/modes/interactive-engine/engine-custom-ui.d.ts.map +1 -1
  693. package/dist/modes/interactive-engine/engine-custom-ui.js +3 -1
  694. package/dist/modes/interactive-engine/engine-custom-ui.js.map +1 -1
  695. package/dist/modes/interactive-engine/engine-input-form.d.ts +1 -1
  696. package/dist/modes/interactive-engine/engine-input-form.js.map +1 -1
  697. package/dist/modes/interactive-engine/engine-session-picker.d.ts +1 -1
  698. package/dist/modes/interactive-engine/engine-session-picker.js.map +1 -1
  699. package/dist/modes/interactive-engine/isolated-runtime.d.ts.map +1 -1
  700. package/dist/modes/interactive-engine/isolated-runtime.js +10 -1
  701. package/dist/modes/interactive-engine/isolated-runtime.js.map +1 -1
  702. package/dist/modes/interactive-engine/protocol.d.ts +1 -1
  703. package/dist/modes/interactive-engine/protocol.js.map +1 -1
  704. package/dist/modes/interactive-engine/remote-component.js.map +1 -1
  705. package/dist/modes/rpc/rpc-keybindings-reload.d.ts +1 -1
  706. package/dist/modes/rpc/rpc-keybindings-reload.js.map +1 -1
  707. package/dist/modes/rpc/rpc-provider-auth.d.ts +1 -1
  708. package/dist/modes/rpc/rpc-provider-auth.js.map +1 -1
  709. package/dist/session-id-target.d.ts +31 -0
  710. package/dist/session-id-target.d.ts.map +1 -0
  711. package/dist/session-id-target.js +57 -0
  712. package/dist/session-id-target.js.map +1 -0
  713. package/dist/utils/abort.d.ts.map +1 -1
  714. package/dist/utils/abort.js +29 -4
  715. package/dist/utils/abort.js.map +1 -1
  716. package/dist/utils/clipboard-image.d.ts.map +1 -1
  717. package/dist/utils/clipboard-image.js +1 -12
  718. package/dist/utils/clipboard-image.js.map +1 -1
  719. package/dist/utils/clipboard.d.ts.map +1 -1
  720. package/dist/utils/clipboard.js +87 -23
  721. package/dist/utils/clipboard.js.map +1 -1
  722. package/dist/utils/wsl.d.ts +3 -0
  723. package/dist/utils/wsl.d.ts.map +1 -0
  724. package/dist/utils/wsl.js +15 -0
  725. package/dist/utils/wsl.js.map +1 -0
  726. package/docs/background-tasks.md +24 -14
  727. package/docs/build.md +6 -16
  728. package/docs/compaction/reference.md +10 -12
  729. package/docs/compaction.md +30 -112
  730. package/docs/computer-use.md +23 -24
  731. package/docs/containerization.md +4 -5
  732. package/docs/custom-provider/api-reference.md +10 -1
  733. package/docs/custom-provider/oauth.md +4 -2
  734. package/docs/custom-provider/streaming.md +8 -3
  735. package/docs/custom-provider.md +1 -1
  736. package/docs/development.md +13 -138
  737. package/docs/docs.json +19 -5
  738. package/docs/environment-variables.md +20 -4
  739. package/docs/extensions/api-reference.md +6 -2
  740. package/docs/extensions/authoring.md +10 -7
  741. package/docs/extensions/events.md +14 -24
  742. package/docs/extensions/ui.md +3 -4
  743. package/docs/extensions.md +22 -18
  744. package/docs/getting-started/authentication.md +4 -1
  745. package/docs/getting-started/first-session.md +10 -8
  746. package/docs/getting-started/installation.md +14 -6
  747. package/docs/getting-started/project-instructions.md +5 -1
  748. package/docs/guides/configuration.md +10 -5
  749. package/docs/guides/non-interactive.md +2 -2
  750. package/docs/guides.md +8 -17
  751. package/docs/herdr.md +2 -1
  752. package/docs/index.md +2 -2
  753. package/docs/intercom/operations.md +16 -70
  754. package/docs/intercom/reference.md +15 -5
  755. package/docs/intercom.md +16 -7
  756. package/docs/json.md +12 -2
  757. package/docs/keybindings.md +13 -8
  758. package/docs/llama-cpp.md +5 -1
  759. package/docs/{mcp.md → mcp-servers.md} +21 -2
  760. package/docs/models/evals.md +133 -465
  761. package/docs/models/model-selection.md +33 -118
  762. package/docs/models/reference.md +18 -21
  763. package/docs/models.md +7 -4
  764. package/docs/packages/authoring.md +5 -1
  765. package/docs/packages/reference.md +5 -1
  766. package/docs/packages.md +5 -3
  767. package/docs/programmatic.md +3 -1
  768. package/docs/prompt-templates.md +2 -10
  769. package/docs/providers/reference.md +2 -2
  770. package/docs/providers.md +41 -16
  771. package/docs/quickstart.md +8 -4
  772. package/docs/reference/cli.md +19 -11
  773. package/docs/reference.md +3 -6
  774. package/docs/rpc/protocol.md +11 -13
  775. package/docs/rpc.md +5 -1
  776. package/docs/sdk/reference.md +59 -239
  777. package/docs/sdk/structured-decisions.md +132 -0
  778. package/docs/sdk.md +181 -17
  779. package/docs/security.md +7 -4
  780. package/docs/session-format.md +18 -5
  781. package/docs/sessions.md +12 -6
  782. package/docs/settings.md +68 -16
  783. package/docs/skills/authoring.md +7 -1
  784. package/docs/skills.md +26 -7
  785. package/docs/subagents/authoring.md +11 -1
  786. package/docs/subagents/reference.md +98 -10
  787. package/docs/subagents.md +51 -35
  788. package/docs/terminal-setup.md +4 -2
  789. package/docs/termux.md +3 -1
  790. package/docs/themes/reference.md +4 -1
  791. package/docs/themes.md +1 -1
  792. package/docs/tools.md +431 -20
  793. package/docs/tui/reference.md +13 -14
  794. package/docs/tui.md +10 -6
  795. package/docs/usage.md +21 -7
  796. package/docs/web-access.md +5 -1
  797. package/docs/windows.md +18 -11
  798. package/docs/workflows/api-reference.md +134 -25
  799. package/docs/workflows/authoring.md +48 -39
  800. package/docs/workflows/builtins.md +22 -28
  801. package/docs/workflows/operations.md +284 -137
  802. package/docs/workflows/reliable-design.md +74 -130
  803. package/docs/workflows/verification.md +8 -8
  804. package/docs/workflows.md +10 -16
  805. package/examples/extensions/custom-provider-anthropic/index.ts +15 -10
  806. package/examples/extensions/custom-provider-gitlab-duo/index.ts +2 -2
  807. package/examples/extensions/prompt-customizer.ts +17 -37
  808. package/npm-shrinkwrap.json +502 -709
  809. package/package.json +12 -10
  810. package/dist/builtin/subagents/skills/playwright-cli/SKILL.md +0 -420
  811. package/dist/builtin/subagents/skills/playwright-cli/references/element-attributes.md +0 -23
  812. package/dist/builtin/subagents/skills/playwright-cli/references/playwright-tests.md +0 -39
  813. package/dist/builtin/subagents/skills/playwright-cli/references/request-mocking.md +0 -87
  814. package/dist/builtin/subagents/skills/playwright-cli/references/running-code.md +0 -241
  815. package/dist/builtin/subagents/skills/playwright-cli/references/session-management.md +0 -225
  816. package/dist/builtin/subagents/skills/playwright-cli/references/storage-state.md +0 -275
  817. package/dist/builtin/subagents/skills/playwright-cli/references/test-generation.md +0 -433
  818. package/dist/builtin/subagents/skills/playwright-cli/references/tracing.md +0 -139
  819. package/dist/builtin/subagents/skills/playwright-cli/references/video-recording.md +0 -143
  820. package/dist/builtin/workflows/builtin/chunk-m0xfsef8.js +0 -2813
  821. package/dist/builtin/workflows/skills/impeccable/agents/impeccable_asset_producer.toml +0 -94
  822. package/dist/builtin/workflows/skills/impeccable/agents/impeccable_documenter.toml +0 -27
  823. package/dist/builtin/workflows/skills/impeccable/agents/impeccable_finish_reviewer.toml +0 -41
  824. package/dist/builtin/workflows/skills/impeccable/agents/impeccable_manual_edit_applier.toml +0 -95
  825. package/dist/builtin/workflows/skills/impeccable/agents/openai.yaml +0 -4
  826. package/dist/builtin/workflows/skills/impeccable/scripts/concept-seed.mjs +0 -695
  827. package/dist/builtin/workflows/skills/impeccable/scripts/context-signals.mjs +0 -325
  828. package/dist/builtin/workflows/skills/impeccable/scripts/context.mjs +0 -1503
  829. package/dist/builtin/workflows/skills/impeccable/scripts/critique-storage.mjs +0 -222
  830. package/dist/builtin/workflows/skills/impeccable/scripts/detect-csp.mjs +0 -198
  831. package/dist/builtin/workflows/skills/impeccable/scripts/detect.mjs +0 -21
  832. package/dist/builtin/workflows/skills/impeccable/scripts/detector/browser/injected/index.mjs +0 -2073
  833. package/dist/builtin/workflows/skills/impeccable/scripts/detector/cli/main.mjs +0 -432
  834. package/dist/builtin/workflows/skills/impeccable/scripts/detector/design-system.mjs +0 -1121
  835. package/dist/builtin/workflows/skills/impeccable/scripts/detector/detect-antipatterns-browser.js +0 -8746
  836. package/dist/builtin/workflows/skills/impeccable/scripts/detector/detect-antipatterns.mjs +0 -51
  837. package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/browser/detect-url.mjs +0 -376
  838. package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/regex/detect-text.mjs +0 -1168
  839. package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/static-html/css-cascade.mjs +0 -1192
  840. package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/static-html/detect-html.mjs +0 -290
  841. package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/visual/screenshot-contrast.mjs +0 -189
  842. package/dist/builtin/workflows/skills/impeccable/scripts/detector/findings.mjs +0 -18
  843. package/dist/builtin/workflows/skills/impeccable/scripts/detector/node/file-system.mjs +0 -213
  844. package/dist/builtin/workflows/skills/impeccable/scripts/detector/profile/profiler.mjs +0 -166
  845. package/dist/builtin/workflows/skills/impeccable/scripts/detector/registry/antipatterns.mjs +0 -617
  846. package/dist/builtin/workflows/skills/impeccable/scripts/detector/rules/checks.mjs +0 -5534
  847. package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/color.mjs +0 -588
  848. package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/constants.mjs +0 -112
  849. package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/fonts.mjs +0 -30
  850. package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/inline-ignores.mjs +0 -148
  851. package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/page.mjs +0 -35
  852. package/dist/builtin/workflows/skills/impeccable/scripts/doctor.mjs +0 -338
  853. package/dist/builtin/workflows/skills/impeccable/scripts/embed-prompt.mjs +0 -270
  854. package/dist/builtin/workflows/skills/impeccable/scripts/generate-image.mjs +0 -277
  855. package/dist/builtin/workflows/skills/impeccable/scripts/hook-admin.mjs +0 -783
  856. package/dist/builtin/workflows/skills/impeccable/scripts/hook-lib.mjs +0 -2305
  857. package/dist/builtin/workflows/skills/impeccable/scripts/hook.mjs +0 -78
  858. package/dist/builtin/workflows/skills/impeccable/scripts/lib/artifact-schema.mjs +0 -93
  859. package/dist/builtin/workflows/skills/impeccable/scripts/lib/composition-catalog.mjs +0 -200
  860. package/dist/builtin/workflows/skills/impeccable/scripts/lib/concept-catalog.mjs +0 -395
  861. package/dist/builtin/workflows/skills/impeccable/scripts/lib/design-parser.mjs +0 -925
  862. package/dist/builtin/workflows/skills/impeccable/scripts/lib/impeccable-config.mjs +0 -640
  863. package/dist/builtin/workflows/skills/impeccable/scripts/lib/impeccable-paths.mjs +0 -137
  864. package/dist/builtin/workflows/skills/impeccable/scripts/lib/is-generated.mjs +0 -72
  865. package/dist/builtin/workflows/skills/impeccable/scripts/lib/open-system-browser.mjs +0 -57
  866. package/dist/builtin/workflows/skills/impeccable/scripts/lib/provider.mjs +0 -5
  867. package/dist/builtin/workflows/skills/impeccable/scripts/lib/roll-selection.mjs +0 -369
  868. package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness-deep.mjs +0 -483
  869. package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness-notice.mjs +0 -169
  870. package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness.mjs +0 -528
  871. package/dist/builtin/workflows/skills/impeccable/scripts/lib/surface-briefs.mjs +0 -151
  872. package/dist/builtin/workflows/skills/impeccable/scripts/lib/target-args.mjs +0 -42
  873. package/dist/builtin/workflows/skills/impeccable/scripts/lib/target-slug.mjs +0 -33
  874. package/dist/builtin/workflows/skills/impeccable/scripts/lib/template-extensions.mjs +0 -146
  875. package/dist/builtin/workflows/skills/impeccable/scripts/live/accept-css.mjs +0 -617
  876. package/dist/builtin/workflows/skills/impeccable/scripts/live/accept-verify.mjs +0 -71
  877. package/dist/builtin/workflows/skills/impeccable/scripts/live/browser-script-parts.mjs +0 -77
  878. package/dist/builtin/workflows/skills/impeccable/scripts/live/completion.mjs +0 -28
  879. package/dist/builtin/workflows/skills/impeccable/scripts/live/event-validation.mjs +0 -199
  880. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/astro.mjs +0 -47
  881. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/detect-utils.mjs +0 -157
  882. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/index.mjs +0 -143
  883. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/journal.mjs +0 -205
  884. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/nextjs.mjs +0 -49
  885. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/nuxt.mjs +0 -170
  886. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/script-src.mjs +0 -26
  887. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/static-html.mjs +0 -26
  888. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/sveltekit.mjs +0 -71
  889. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/tag-strategy.mjs +0 -247
  890. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/tanstack-start.mjs +0 -70
  891. package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/vite-generic.mjs +0 -42
  892. package/dist/builtin/workflows/skills/impeccable/scripts/live/generation-preflight.mjs +0 -149
  893. package/dist/builtin/workflows/skills/impeccable/scripts/live/insert-ui.mjs +0 -458
  894. package/dist/builtin/workflows/skills/impeccable/scripts/live/instructions.mjs +0 -169
  895. package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-apply.mjs +0 -939
  896. package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-edit-routes.mjs +0 -357
  897. package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-edits-buffer.mjs +0 -152
  898. package/dist/builtin/workflows/skills/impeccable/scripts/live/poll-lanes.mjs +0 -14
  899. package/dist/builtin/workflows/skills/impeccable/scripts/live/roots.mjs +0 -670
  900. package/dist/builtin/workflows/skills/impeccable/scripts/live/session-store.mjs +0 -563
  901. package/dist/builtin/workflows/skills/impeccable/scripts/live/source-lock.mjs +0 -105
  902. package/dist/builtin/workflows/skills/impeccable/scripts/live/source-search.mjs +0 -105
  903. package/dist/builtin/workflows/skills/impeccable/scripts/live/svelte-ast.mjs +0 -969
  904. package/dist/builtin/workflows/skills/impeccable/scripts/live/svelte-component.mjs +0 -1401
  905. package/dist/builtin/workflows/skills/impeccable/scripts/live/sveltekit-adapter.mjs +0 -314
  906. package/dist/builtin/workflows/skills/impeccable/scripts/live/tanstack-adapter.mjs +0 -280
  907. package/dist/builtin/workflows/skills/impeccable/scripts/live/ui-surfaces.mjs +0 -75
  908. package/dist/builtin/workflows/skills/impeccable/scripts/live/vocabulary.mjs +0 -171
  909. package/dist/builtin/workflows/skills/impeccable/scripts/live-accept.mjs +0 -961
  910. package/dist/builtin/workflows/skills/impeccable/scripts/live-commit-manual-edits.mjs +0 -1244
  911. package/dist/builtin/workflows/skills/impeccable/scripts/live-complete.mjs +0 -107
  912. package/dist/builtin/workflows/skills/impeccable/scripts/live-copy-edit-agent.mjs +0 -800
  913. package/dist/builtin/workflows/skills/impeccable/scripts/live-discard-manual-edits.mjs +0 -51
  914. package/dist/builtin/workflows/skills/impeccable/scripts/live-inject.mjs +0 -515
  915. package/dist/builtin/workflows/skills/impeccable/scripts/live-insert.mjs +0 -292
  916. package/dist/builtin/workflows/skills/impeccable/scripts/live-manual-edit-evidence.mjs +0 -371
  917. package/dist/builtin/workflows/skills/impeccable/scripts/live-poll.mjs +0 -427
  918. package/dist/builtin/workflows/skills/impeccable/scripts/live-resume.mjs +0 -123
  919. package/dist/builtin/workflows/skills/impeccable/scripts/live-server.mjs +0 -1675
  920. package/dist/builtin/workflows/skills/impeccable/scripts/live-status.mjs +0 -71
  921. package/dist/builtin/workflows/skills/impeccable/scripts/live-target.mjs +0 -30
  922. package/dist/builtin/workflows/skills/impeccable/scripts/live-wrap.mjs +0 -927
  923. package/dist/builtin/workflows/skills/impeccable/scripts/live.mjs +0 -365
  924. package/dist/builtin/workflows/skills/impeccable/scripts/palette.mjs +0 -628
  925. package/dist/builtin/workflows/skills/impeccable/scripts/pin.mjs +0 -224
  926. package/dist/builtin/workflows/skills/impeccable/scripts/serve-question.mjs +0 -1540
  927. package/dist/builtin/workflows/skills/impeccable/scripts/surface-brief.mjs +0 -74
  928. package/docs/models/artificial-analysis-index.md +0 -89
  929. package/docs/models/pareto-efficiency.md +0 -90
  930. package/docs/tools/edit.md +0 -378
package/docs/tools.md CHANGED
@@ -7,6 +7,13 @@ description: "The tools Atomic gives the model by default."
7
7
 
8
8
  Atomic enables these coding tools in normal sessions by default: `read`, `write`, `edit`, `bash`, `kill`, `find`, and `search`.
9
9
 
10
+ - [Read files and select lines](#read-and-path-selectors).
11
+ - [Find paths and search contents](#find-and-search).
12
+ - [Edit existing files](#edit) or [write files](#write).
13
+ - [Run shell commands](#bash-and-bashinterceptor) or [stop background shells](#kill).
14
+
15
+ Bundled integrations also provide [public repository search](#code_search), [web fetching](/web-access), and [MCP tools](/mcp-servers).
16
+
10
17
  ## `code_search`
11
18
 
12
19
  The bundled web-access extension provides `code_search` for questions about code, architecture, and APIs in a public GitHub repository. It uses DeepWiki MCP at `https://mcp.deepwiki.com/mcp` without an API key or local MCP configuration.
@@ -21,7 +28,9 @@ Optional `maxTokens` defaults to 5000 and accepts integers from 1000 to 50000. I
21
28
 
22
29
  Answers depend on DeepWiki's repository indexing and availability. Check the repository name when a question fails. Errors and empty responses do not fall back to Exa; use `web_search` for broader discovery or unavailable repositories. `web_search` retains its existing Exa and other provider support.
23
30
 
24
- ## Hashline editing anchors
31
+ ## `edit`
32
+
33
+ ### Hashline editing anchors
25
34
 
26
35
  `read`, `search`, `write`, and successful `edit` results for local text files emit an editable, session-scoped hashline header:
27
36
 
@@ -41,25 +50,361 @@ insert tail:
41
50
  +// done
42
51
  ```
43
52
 
44
- Block operations resolve through Atomic's native Rust tree-sitter primitive, with the brace/indent heuristic only as a fallback when the native binding is unavailable. See the [`edit` hashline specification](/tools/edit) for every operation, verified tolerated input shape, output and recovery behavior, limits, worked examples, literal error messages, and warnings.
45
-
46
53
  If a file or its parent directory becomes inaccessible after `edit` prepares a patch, the edit is refused with `FILE_MUTATION_CONFLICT:target_unreadable` and the filesystem error code, such as `EACCES`. No changes are written. Restore access, then read the file again before retrying.
47
54
 
55
+ ### Inputs
56
+
57
+ | Field | Type | Required | Description |
58
+ | --- | --- | --- | --- |
59
+ | `input` | `string` | Yes | One or more hashline file sections. The value must be non-empty. |
60
+
61
+ Each section starts with `[PATH#TAG]`. `TAG` is the four-hex snapshot tag emitted by the latest `read`, `search`,
62
+ `write`, or successful `edit` in the active tool/session store. Tags from another session do not authorize an edit.
63
+ Hashline edits existing files; use `write` to create a file.
64
+
65
+ The operations are:
66
+
67
+ - `replace N..M:` — replace inclusive original lines N through M with the following body rows.
68
+ - `replace block N:` — replace the syntactic block beginning on N with the following body rows.
69
+ - `delete N..M` — delete inclusive original lines N through M. It has no body.
70
+ - `delete block N` — delete the syntactic block beginning on N. It has no body.
71
+ - `insert before N:` — insert body rows immediately before original line N.
72
+ - `insert after N:` — insert body rows immediately after original line N.
73
+ - `insert after block N:` — insert body rows after the end of the syntactic block beginning on N.
74
+ - `insert head:` — insert body rows at the start of the file.
75
+ - `insert tail:` — insert body rows at the end of the file.
76
+
77
+ Line numbers refer to the original tagged snapshot and do not shift as hunks in one call apply. A body-bearing header is
78
+ followed by one or more `+TEXT` rows. The `+` is syntax; `TEXT` is inserted verbatim with leading whitespace preserved,
79
+ and `+` alone inserts a blank line. There are no old-text or context rows. To insert a literal row beginning with `-` or
80
+ `+`, write `+-text` or `++text`.
81
+
82
+ #### Block resolution
83
+
84
+ `replace block`, `delete block`, and `insert after block` select the outermost syntactic node beginning on N when syntax-aware resolution is available. A brace/indent fallback may be used otherwise. Where a language folds a decorator or annotation into its construct, such as Python `@dec` plus `def` or TypeScript/Java annotations, anchoring at the first decorator resolves both. A Rust `#[attr]` and doc- or line-comments are separate sibling nodes: anchoring there resolves that node
85
+ alone, and replacing it with a construct body duplicates the untouched construct. Use `replace N..M:` or `delete N..M`
86
+ with explicit lines to take both, and confirm the `→ resolved lines A-B (K lines)` echo before continuing.
87
+
88
+ For `insert after block N:`, N is the opener, never the closing delimiter or last visible line. If the last line is already
89
+ known, use `insert after M:`. A successful resolution is echoed as
90
+ `replace block N → resolved lines A-B (K lines)` or `delete block N → resolved lines A-B (K lines)`; insert-after adds
91
+ `; body lands after line B` to `insert after block N → resolved lines A-B (K lines)`.
92
+
93
+ A replace/delete block cannot resolve when the language is unsupported, the anchor is blank or a closer, no syntactic node
94
+ begins there, the subtree does not parse, or no resolver is configured. Use `replace N..M:` or `delete N..M`. An unresolved
95
+ `insert after block N:` is instead lowered to `insert after N:` with a warning; use `insert after M:` when the explicit end
96
+ line is known. Streaming preview drops unresolved replace/delete block operations, while the authoritative apply rejects
97
+ them.
98
+
99
+ ### Tolerated input shapes
100
+
101
+ Atomic's hand parser deliberately accepts these non-canonical shapes:
102
+
103
+ - Leading blank lines, a leading byte-order mark, and an optional `*** Begin Patch` envelope are ignored.
104
+ `*** End Patch` and `*** Abort` stop parsing; operations before either marker remain.
105
+ - Hex tags are case-insensitive on input and normalized to uppercase.
106
+ - Quoted header paths are unquoted. Absolute paths inside the execution working directory become relative display paths.
107
+ - Some malformed bracketed headers are recovered after removing apply-patch path noise such as `Update File:`, `Add File:`,
108
+ `Delete File:`, `Move to:`, and extra leading `***`. A recovered edit section still needs a valid four-hex tag.
109
+ - `replace N:` is a single-line replacement. `delete N` is a single-line deletion.
110
+ - `replace N-M:`, `replace N…M:`, and `replace N M:` are accepted as `replace N..M:`. The same separators are accepted for
111
+ `delete` ranges.
112
+ - The trailing colon is optional on body-bearing `replace` and `insert` headers.
113
+ - An empty concrete `replace N..M:` is accepted as deletion of that range. Prefer `delete N..M`; empty `replace block` is
114
+ rejected.
115
+ - Bare body rows under a body-bearing hunk are treated as literal rows, auto-prefixed with `+`, and warned. When every bare,
116
+ nonblank row has a `LINE:`/`*LINE:` read-output prefix, those prefixes are stripped as a pasted snapshot; mixed rows and
117
+ explicit `+` rows are preserved. A body made entirely of quoted or numeric values keeps its numeric keys.
118
+ - Repeated sections for the same authored path are merged in first-occurrence order when their tags do not conflict.
119
+ - A run of comment lines beginning with `#` is skipped only when an operation header is the immediately next token. If a
120
+ blank line, end of input, or the next `[PATH#TAG]` header intervenes, the deferred comment is replayed as body content and
121
+ rejected with the payload-line error. Once a hunk is open, a `#` line is body content: under `delete` it triggers the
122
+ delete-takes-no-body rejection; under a body-bearing hunk it is auto-prefixed and written as a literal line. Blank layout
123
+ rows before a body or after its final row are ignored; proven interior blank body rows are preserved.
124
+
125
+ The parser does **not** tolerate `delete N..M:` or a body under `delete`/`delete block`, `-` diff rows, apply-patch file
126
+ sentinels inside the patch, unified-diff/`@@` hunk headers, bare numeric hunk headers, malformed/absent section headers,
127
+ unsafe or non-positive anchors, oversized ranges, empty `insert`/`insert after block`, or empty `replace block` hunks.
128
+ Use the canonical syntax above even when a compatibility form is accepted.
129
+
130
+ ### Outputs
131
+
132
+ A successful edit returns one compact text block per written section. Each starts with a fresh `[path#TAG]` header for the
133
+ post-edit content, followed by warnings and block-resolution lines, then a compact diff preview (or a
134
+ `First changed line: N` fallback). Warnings are emitted as diagnostic lines directly beneath the header rather than under a
135
+ separate `Warnings:` label. Multi-section results are separated by a blank line.
136
+
137
+ Block echoes have these exact shapes:
138
+
139
+ ```text
140
+ replace block N → resolved lines A-B (K lines)
141
+ delete block N → resolved lines A-B (K lines)
142
+ insert after block N → resolved lines A-B (K lines); body lands after line B
143
+ ```
144
+
145
+ The tool's `details` value is `EditToolDetails`:
146
+
147
+ - `diff`: the combined rendered diff string.
148
+ - `patch`: the combined unified patch string.
149
+ - `firstChangedLine`: optional first changed post-edit line.
150
+
151
+ Each successful `write` or `edit` records and returns a fresh snapshot tag. Plain `write` output is also compact: a refreshed
152
+ header plus a success confirmation, not a full file reprint. `write` strips copied hashline headers and `LINE:`/`*LINE:`
153
+ display prefixes only when they match a known snapshot in the current store, reports that stripping, and preserves whether
154
+ a complete copied snapshot had a terminal newline. A copied `Successfully wrote to <path>` confirmation (with or without the
155
+ legacy `N bytes` wording) counts as tool chrome only when `<path>` is the complete path the write was asked for — the `path`
156
+ argument exactly as given, its resolved absolute form, or its cwd-relative form — or the copied snapshot's own path. A bare
157
+ basename is not enough, so a user-authored line such as `Successfully wrote to notes.md` is preserved even when the target is
158
+ `deep/dir/notes.md`. Unknown or literal hashline-looking content is preserved.
159
+
160
+ Parallel `edit` calls sharing the same `[path#TAG]` are applied as one snapshot-anchored batch, so one sibling does not fail
161
+ only because another sibling minted a new tag first. A later call arriving after that batch committed still attempts
162
+ snapshot recovery for provably non-overlapping drift.
163
+
164
+ Atomic verifies every target against its tagged snapshot before writing. A recognized stale tag can recover a provably
165
+ non-overlapping external or in-session change and emits the corresponding warning. Unknown tags, overlapping stale edits,
166
+ and unrecoverable drift fail with the current hash and anchor context and leave the section unchanged. All sections are
167
+ prepared before writes begin, but this is preflight atomicity, not transactional rollback: a filesystem failure during
168
+ sequential commits can leave earlier sections written, and the error names written and unwritten sections.
169
+
170
+ A byte-identical edit returns a no-op diagnostic without writing. The same identical payload escalates to an error on its
171
+ third attempt.
172
+
173
+ ### Worked examples
174
+
175
+ Reference file in the exact shape `read` returns:
176
+
177
+ ```text
178
+ [a.ts#0A3B]
179
+ 1:const X = "a";
180
+ 2:const Y = X;
181
+ 3:
182
+ 4:console.log(X);
183
+ 5:console.log(Y);
184
+ 6:export { X, Y };
185
+ ```
186
+
187
+ Replace line 1 with two lines:
188
+
189
+ ```text
190
+ [a.ts#0A3B]
191
+ replace 1..1:
192
+ +const X = "b";
193
+ +export const Y = X;
194
+ ```
195
+
196
+ Insert below or above line 5:
197
+
198
+ ```text
199
+ [a.ts#0A3B]
200
+ insert after 5:
201
+ +console.log(X + Y);
202
+ insert before 5:
203
+ +console.log(X + Y);
204
+ ```
205
+
206
+ Delete lines 4 through 5:
207
+
208
+ ```text
209
+ [a.ts#0A3B]
210
+ delete 4..5
211
+ ```
212
+
213
+ Insert at both file boundaries:
214
+
215
+ ```text
216
+ [a.ts#0A3B]
217
+ insert head:
218
+ +// header
219
+ insert tail:
220
+ +// trailer
221
+ ```
222
+
223
+ Replace or delete a complete block by anchoring its opener:
224
+
225
+ ```text
226
+ [service.ts#7B2E]
227
+ replace block 10:
228
+ +function load() {
229
+ + return cache.get("key");
230
+ +}
231
+ delete block 30
232
+ ```
233
+
234
+ Edit two files in one preflighted call:
235
+
236
+ ```text
237
+ [src/a.ts#0A3B]
238
+ replace 4..4:
239
+ +const enabled = true;
240
+ [src/b.ts#1F7C]
241
+ delete 20
242
+ ```
243
+
244
+ ### Limits and caps
245
+
246
+ - Tags contain four hexadecimal characters and belong to the current session.
247
+ - Anchors must be positive safe integers no greater than `Number.MAX_SAFE_INTEGER`.
248
+ - Numeric ranges are limited to 100,000 lines.
249
+ - Mismatch and unresolved-block previews show up to two lines on either side of an anchor.
250
+ - An identical no-op payload returns a diagnostic twice; the third attempt fails with `STOP.`. Re-read and verify the anchor instead of repeating it.
251
+ - Recovery never slides a hunk to a nearby duplicate. Explicit `+TEXT` resembling a hunk header remains literal and produces a warning.
252
+
253
+ Across whole-file, truncated, and range/offset reads of LF or CRLF text, numbered output treats a terminal newline as a
254
+ separator, not an extra synthetic row. Genuine blank lines—including one immediately before that terminal newline—remain
255
+ visible, and truncation totals and continuation selectors count real lines. Bare-CR files retain their existing
256
+ compatibility behavior and are outside this guarantee.
257
+
258
+ ### Errors
259
+
260
+ The templates below quote Atomic's literal messages. `N`, `M`, `A`, `B`, `PATH`, `TAG`, `<path>`, `<message>`, and similar
261
+ angle-bracketed names stand for runtime substitutions. Parser errors that originate within a section include the authored
262
+ `line N:` prefix shown.
263
+
264
+ #### Tool boundary and filesystem
265
+
266
+ - `edit input must be a non-empty hashline script with [PATH#TAG] sections.`
267
+ - `Operation aborted`
268
+ - `Could not edit file: <path>. <message>.` (`<message>` is `Error code: <code>` when the error exposes a code.)
269
+ - `Multiple hashline sections resolve to the same file (<first path> and <second path>). Merge their ops under one header before applying.`
270
+ - `Stale hashline tag for <path>: file content changed before write. Re-read before editing.`
271
+ - `Failed to write <path>: <message>`; when applicable it appends ` Sections already written: <paths>.` and/or
272
+ ` Sections not written: <paths>.`
273
+
274
+ #### Section headers and snapshot tags
275
+
276
+ - `input must begin with "[PATH#HASH]" on the first non-blank line for anchored edits; got: <preview>. Example: "[src/foo.ts#1A2B]" then edit ops.`
277
+ - `Input header must be [PATH] or [PATH#TAG] with a 4-hex content-hash tag; got <header>.`
278
+ - `Input header "[]" is empty; provide a file path.`
279
+ - `Patch input did not produce any sections.`
280
+ - ``Missing hashline snapshot tag for <path>; use `[<path>#tag]` from your latest read/search output. To create a new file, use the write tool.``
281
+ - `Conflicting hashline snapshot tags for <path>: #<first tag> and #<second tag>. Re-read the file and retry with one current header.`
282
+ - If a host reports that its snapshot store is unavailable, report the integration error rather than inventing a tag.
283
+ - `File not found: <path>. Use the write tool to create new files.`
284
+
285
+ #### Tokenizer and anchors
286
+
287
+ - `line N: line anchor "<digits>" is not a safe integer; line numbers must be positive safe integers no greater than 9007199254740991.`
288
+ - `line N: expected a line number such as "119", "112", "7"; got "<input>". Use [PATH#hash] from your latest read for file-version binding.`
289
+ - `Line N does not exist (file has M lines)`
290
+
291
+ #### Ranges, bodies, and hunk conflicts
292
+
293
+ - `line N: range A..B ends before it starts.`
294
+ - `line N: range A..B expands to K lines; numeric ranges are limited to 100,000 lines.`
295
+ - `line N: payload line has no preceding hunk header. Got "+<text>".`
296
+ - ``line N: payload line has no preceding hunk header. Use `replace N..M:`, `delete N..M`, or `insert before|after|head|tail:` above the body. Got "<text>".``
297
+ - ``line N: `-` rows are not valid; the range already names the lines being changed. For a literal `-` line, write `+-…`.``
298
+ - ``line N: `delete N..M` does not take body rows. Remove the body, or use `replace N..M:`.``
299
+ - ``line N: `delete block N` does not take body rows. Remove the body, or use `replace block N:`.``
300
+ - ``line N: `insert` needs at least one `+TEXT` body row.``
301
+ - ``line N: `replace block N:` needs at least one `+TEXT` body row. To delete a block, use `delete block N`.``
302
+ - `line N: anchor line A is already targeted by another hunk on line M. Issue ONE hunk per range; payload is only the final desired content, never a before/after pair.`
303
+
304
+ A concrete `replace N..M:` with no body is accepted as deletion. Prefer `delete N..M` to make the intent clear.
305
+
306
+ #### Contamination and malformed hunk headers
307
+
308
+ - ``unified-diff hunk header (`@@ -N,M +N,M @@`) is not valid in hashline. File sections start with `[path#HASH]`; use `replace`, `delete`, or `insert` ops.``
309
+ - ``line N: apply_patch sentinel "<preview>" is not valid in hashline. File sections start with `[path#HASH]` (no `Update File:` / `Add File:` keyword). Use `replace N..M:`, `delete N..M`, or `insert before|after|head|tail:` ops.``
310
+ - ``line N: unified-diff hunk header (`@@ -N,M +N,M @@`) is not valid in hashline. Use `replace N..M:`, `delete N..M`, or `insert before|after|head|tail:` ops.``
311
+ - ``line N: `@@`-bracketed hunk header "<preview>" is not valid in hashline. Drop the `@@ ... @@` brackets and write a verb header such as `replace N..M:`.``
312
+ - ``line N: `delete N..M` has no colon and no body. Remove the colon and body rows.``
313
+ - ``line N: hunk headers need a verb. Use `replace A..A:` to replace, or `delete A` to delete.``
314
+ - ``line N: bare range hunk header "A..B" is not valid. Hunk headers need a verb: write `replace A..B:` or `delete A..B`.``
315
+
316
+ #### Block resolution and internal apply invariants
317
+
318
+ - With a resolver, replace/delete failure is
319
+ ``line N: `replace block A:` could not resolve a syntactic block beginning on line A (unsupported language, blank/closer line, or parse error). Use `replace A..M:` with explicit lines.`` or
320
+ ``line N: `delete block A` could not resolve a syntactic block beginning on line A (unsupported language, blank/closer line, or parse error). Use `delete A..M` with explicit lines.``
321
+ Numbered, `*`-marked context follows after a blank line when the anchor is in range.
322
+ - Without a resolver:
323
+ ``line N: `replace block`/`delete block`/`insert after block` are not available here (no block resolver configured). Use a concrete line range.``
324
+ - An internal apply error indicates a host integration problem. Report the exact diagnostic; use explicit ranges when block resolution is unavailable.
325
+
326
+ `insert after block` resolution failure is a warning and lowering, not an error.
327
+
328
+ #### Snapshot mismatch
329
+
330
+ An unknown or cross-session tag emits these two lines, followed by numbered anchor context when available:
331
+
332
+ ```text
333
+ Edit rejected for <path>: hash #<expected tag> is not from this session.
334
+ The current file hashes to #<actual tag>. Re-read the file with `read` to copy a current [path#tag] header — never invent the tag and never reuse one from a prior session.
335
+ ```
336
+
337
+ A recognized tag whose snapshot no longer matches and cannot be recovered emits:
338
+
339
+ ```text
340
+ Edit rejected for <path>: file changed between read and edit.
341
+ Section is bound to #<expected tag>, but the current file hashes to #<actual tag>. If a prior edit in this session modified this file, copy the [path#newhash] header from that edit's response; otherwise re-read the file with `read` to refresh the tag before retrying.
342
+ ```
343
+
344
+ #### No-op edits
345
+
346
+ A single-file or all-no-op call returns this text without writing on attempts one and two:
347
+
348
+ ```text
349
+ Edits to <path> parsed and applied cleanly, but produced no change: your body row(s) are byte-identical to the file at the targeted lines. The bug is somewhere else — re-read the file before issuing another edit. Do NOT widen the payload or add lines; verify the anchor first.
350
+ ```
351
+
352
+ From attempt two onward, the result includes `No-op count for this identical payload: N.` Attempt three fails with `STOP.`. A no-op in a mixed multi-section call also fails. Re-read the file and verify the intended change before retrying.
353
+
354
+ ### Warnings
355
+
356
+ Warnings that have active emission sites are emitted verbatim beneath the refreshed section header:
357
+
358
+ - ``Auto-prefixed bare body row(s) with `+`. Body rows must be `+TEXT` literal lines.``
359
+ - `Literal +TEXT row resembles a valid hunk header; it was kept as literal payload text.`
360
+ - `Recovered from a stale file hash using a previous read snapshot (file changed externally between read and edit).`
361
+ - `Recovered from a stale file hash using an earlier in-session snapshot (a prior edit in this session advanced the hash).`
362
+ - `Recovered by replaying your edits onto the current file content (a prior in-session edit changed the lines you re-targeted with a stale hash). Verify the diff matches your intent.`
363
+ - ``Applied the `insert head:`/`insert tail:` edit despite a stale snapshot tag (file changed since your read) — head/tail position is content-independent. Re-read if the drift was unexpected.``
364
+ - `` `insert after block N:` anchors on a closing delimiter, so it was applied as plain `insert after N:`. Anchor on the line that OPENS the construct. ``
365
+ - `` `insert after block N:` could not resolve a syntactic block on line N, so it was applied as plain `insert after N:`. Verify the landing line; anchor on a line that OPENS a construct. ``
366
+ - `insert after N: body indented shallower than the anchor, so the landing moved past K closing line(s) to after line M. For the deeper position inside the block, re-issue with the body indented to match.`
367
+ The emitted phrase is `1 closing line` for one crossed line and `K closing lines` otherwise.
368
+ - ``insert after block N: body indented deeper than closing line A, so it was placed inside the block, after line M. `insert after block` lands AFTER the block at sibling depth — if inside was intended, use plain `insert after A:`.``
369
+ - `Auto-repaired a replacement boundary echo at line N: dropped A leading and B trailing payload line(s) already present outside the range. Issue the payload as the final desired content for the selected range only — never restate unchanged lines bordering the range.`
370
+ - `Auto-repaired a delimiter-balance mismatch in the replacement at line N: <repair action>. Issue the payload as the final desired content only — never restate or omit a closing bracket bordering the range.`
371
+ The repair action is one of `dropped K duplicated trailing payload line(s) already present below the range`,
372
+ `dropped K duplicated leading payload line(s) already present above the range`, or
373
+ `kept K structural closing line(s) the range deleted without restating`.
374
+ - `Applied N parallel edit calls as one snapshot-anchored batch.`
375
+
48
376
  ## `write`
49
377
 
50
- `write` overwriting an existing file requires this session to have already observed exactly the content it is replacing, checked under the same per-file mutation queue that serializes the write itself. Creating a new file is unaffected, and so is overwriting a file this session read, wrote, or edited earlier. Where a session has no version of its own, the refusal is `no_prior_observation`; where it has one that no longer matches what is on disk, it is `changed_since_observation` and names the first diverging line, what the session assumed was there, and what the file holds instead. Both carry the same `FILE_MUTATION_CONFLICT` code and requester identity as an `edit` conflict, so a `write` that would have silently discarded another agent's file is reported rather than performed. Snapshots are per session, so a file read by a different session or a previous run does not authorize an overwrite here either. A write whose result is aborted after the bytes have already reached disk still records its snapshot, so retrying it is not mistaken for overwriting a stranger's file.
378
+ Read an existing file before overwriting it with `write`. Atomic checks that the content still matches what this session observed, so another agent's changes are not silently discarded. Creating a new file does not require a prior read.
379
+
380
+ Two refusals use the `FILE_MUTATION_CONFLICT` code and include the requester identity:
381
+
382
+ - `no_prior_observation`: this session has not read, written, or edited the file. Another session's read, including one from a previous run, does not count.
383
+ - `changed_since_observation`: the file changed. The error names the first diverging line and shows the expected and current content. Read the file again before retrying.
384
+
385
+ If cancellation arrives after bytes reach disk, a retry still recognizes this session's write.
51
386
 
52
387
  Standalone `createWriteToolDefinition(cwd)` and `createWriteTool(cwd)` instances retain their own observations across `local://` writes, just as they do for plain paths, even when no `hashlineStore` is supplied. Separate instances still need an explicitly shared store to share observations.
53
388
 
54
- Creating a file claims the path exclusively. `write` asks the filesystem for create-or-fail semantics (`O_EXCL`) whenever it has just observed the path as absent, so a file that appears in the window between that check and the write is reported as `target_exists` with a description of what is there now, rather than being silently truncated. Overwrites do not request exclusivity, since they are replacing a file the session has already accounted for.
389
+ If a file appears between the absence check and creation, local `write` refuses with `target_exists` rather than overwriting it. An unreadable existing file produces `target_unreadable`, with a filesystem code when available.
55
390
 
56
- `WriteOperations` carries the read `write` performs before every write. Custom implementations must supply it, and it must report absence as `undefined` while rejecting for anything else: a path that exists but cannot be read is not a free path, and reporting it as absent would present it as a fresh create and truncate it. Such a rejection surfaces as `target_unreadable`, including the filesystem error code when the backend supplies one. Routing the read through `WriteOperations` is what lets a remote or sandboxed implementation have these checks run against the filesystem its writes actually land on, instead of against local disk. An implementation that cannot express exclusive create may ignore that request and overwrite; it then loses only the race against writers outside Atomic, since the mutation queue already excludes writers inside it.
391
+ Custom `WriteOperations` implementations must read from the same filesystem they write to. Return `undefined` only for absence and reject other read failures. Honor exclusive-create requests to protect against writers outside Atomic; adapters that ignore them lose that protection.
57
392
 
58
393
  ## `bash` and `bashInterceptor`
59
394
 
60
- The `bash` tool executes shell commands in the session workspace, with optional PTY handling. When `pty: true` is requested, local execution uses the bundled Rust-backed PTY session; if the native PTY package is unavailable, Atomic degrades to normal pipe execution. Set `PI_NO_PTY=1` or `ATOMIC_NO_PTY=1` to force normal pipe execution. Foreground results include oh-my-pi-style `timeoutSeconds`, `requestedTimeoutSeconds`, `wallTimeMs`, and non-zero `exitCode` metadata, and preserve overflow output in a temporary `fullOutputPath` when output is truncated.
395
+ The `bash` tool executes shell commands in the session workspace. It accepts `cwd`, `env`, `timeout`, and `pty`.
396
+
397
+ - `cwd` and `env` set the working directory and environment for local execution.
398
+ - `timeout` is in seconds and defaults to 300. Explicit values must be finite, greater than zero, and no more than 3600. Invalid values fail before execution. Fractions round down, with a one-second floor.
399
+ - `pty: true` uses the bundled native PTY session, falling back to pipes if unavailable. Set `PI_NO_PTY=1` or `ATOMIC_NO_PTY=1` to force pipes.
400
+
401
+ Foreground results include `timeoutSeconds`, `requestedTimeoutSeconds`, `wallTimeMs`, and non-zero `exitCode` metadata. Truncated output is saved at `fullOutputPath`.
402
+
403
+ ### Bash interception
61
404
 
62
- When explicitly enabled in settings, built-in bash interceptor rules block common shell substitutes for first-class tools (`cat`/`grep`/`find`/in-place `sed`/redirection, etc.) only when the corresponding tool is available. Enabled bash tool calls are also offered to `user_bash` extension handlers before local execution. Atomic checks the original command, the internal-URL-expanded command, configured-prefix forms, `spawnHook`-rewritten commands, and a leading `cd path && command` or `cd path; command`-stripped form only when structured `cwd` was omitted, so interceptors can route commands by effective working directory without overriding explicit `cwd`. The bash schema accepts `cwd`, `env`, `timeout`, and `pty`; `cwd` and `env` are honored by the local executor. Omitting `timeout` uses the 300-second default. An explicit timeout must be finite, greater than zero, and no more than Atomic's deliberate 3600-second ceiling; invalid values fail before execution instead of being defaulted or clamped. Valid fractional values are rounded down with a one-second floor. `bashInterceptor.enabled` defaults to `false`; interception is not auto-enabled.
405
+ `bashInterceptor.enabled` defaults to `false`. When enabled, interceptor rules block common shell substitutes such as `cat`, `grep`, `find`, in-place `sed`, and redirection only when the corresponding first-class tool is available. Enabled calls are also offered to `user_bash` extension handlers before local execution.
406
+
407
+ Atomic checks the original command, internal-URL-expanded command, configured-prefix forms, and `spawnHook` rewrites. When structured `cwd` is omitted, it also checks a form with a leading `cd path && command` or `cd path; command` removed. This lets interceptors route by effective working directory without overriding explicit `cwd`.
63
408
 
64
409
  Shell internal-URL expansion is intentionally conservative: commands containing a resolved URL must use only plain unquoted words, spaces/tabs, and basic `;`, `|`, or `&` operators. For example, `printf %s local://notes.txt` is supported and the resolved path is shell-quoted automatically, including paths containing spaces or shell metacharacters. Quotes anywhere in such a command, substitutions, escapes, newlines, redirections and heredocs are rejected before execution; use a filesystem path instead for those forms. Commands without resolved internal URLs retain normal shell syntax. URL expansion in structured `cwd` and `env` values is unchanged.
65
410
 
@@ -81,13 +426,81 @@ The result reports the cancellation decision and current execution and cleanup s
81
426
 
82
427
  ## `find` and `search`
83
428
 
84
- `find` finds filesystem paths by glob; use `search` when you need content matches instead of path matches. `find.paths` is required and accepts file, directory (including a filesystem root), internal URL, or glob paths; copied quoted paths are normalized, exact filesystem paths with spaces/commas/semicolons are preserved before delimiter expansion, comma/semicolon-joined paths are split when at least one part resolves, whitespace-joined paths are split only when every part resolves, hidden files are included by default, `.gitignore` is respected by default (including nested `.gitignore` files outside a Git checkout), broad scans keep `node_modules`/`.git` pruned even with `gitignore:false` unless `node_modules` is explicitly present in the requested path or glob, results are capped at 200 by default, and timeout defaults to 5 seconds. Local `find` prefers the bundled Rust native `glob` implementation derived from oh-my-pi, falling back to the packaged `fd` helper only when native bindings are unavailable. Results include `scopePath`, `fileCount`, `files`, truncation/missing-path metadata, and streamed `onUpdate` snapshots during long scans.
429
+ Use `find` to locate paths by glob and `search` to match file contents with a regex.
430
+
431
+ ### Finding paths
432
+
433
+ `find.paths` is required. It accepts files, directories including filesystem roots, supported local resource selectors, and globs.
434
+
435
+ - Hidden files are included by default, and `.gitignore` rules are respected, including nested rules outside a Git checkout.
436
+ - Broad scans prune `.git` and `node_modules` even with `gitignore: false`. To search `node_modules`, name it explicitly in the path or glob.
437
+ - Results are capped at 200 by default; the default timeout is 5 seconds.
438
+
439
+ Copied quotes around paths are removed. Existing paths containing spaces, commas, or semicolons are kept intact. Otherwise, comma/semicolon-separated paths split when at least one part resolves; whitespace-separated paths split only when every part resolves.
440
+
441
+ Results include `scopePath`, `fileCount`, `files`, truncation and missing-path metadata, and streamed `onUpdate` snapshots during long scans.
442
+
443
+ ### Searching contents
444
+
445
+ `search` accepts `pattern`, optional `paths`, `i`, `case`, `gitignore`, and `skip`. It searches files, directories, globs, archive members, SQLite selectors, and supported local resource selectors.
446
+
447
+ - Omitted, empty-string, or empty-array `paths` search the workspace root.
448
+ - Quoted and delimiter-separated paths follow the same rules as `find`.
449
+ - Whitespace-only patterns are rejected. Other patterns are preserved verbatim, including `(?i)`, `(?m)`, and `(?x)` flags for resource-backed selectors.
450
+ - Output is paged by matching files, 20 by default. Multi-file searches show up to 20 matches per file; single-file searches allow 200 matches.
451
+ - `skip` pages files and is ignored for single-file searches. At the internal collection ceiling, refine the pattern or path as the output requests.
452
+ - Context defaults to one line before and three after each match, controlled by `search.contextBefore` and `search.contextAfter`. Line selectors scope matches first; context outside the range does not count as a hit.
453
+
454
+ Local search limits files to 4 MiB and truncates long lines. Hidden files and `.gitignore` rules follow the selected options.
455
+
456
+ Details include scope, counts, file lists, per-file match counts, missing paths, and displayed-content metadata. `fileLimitReached` and `meta.limits.fileLimit` indicate more matching files. Hashline rows distinguish matches (`*LINE:...`) from context (` LINE:...`).
457
+
458
+ ## `read` and path selectors
459
+
460
+ Directory reads show a depth-2 tree sorted by most-recent modification time, with sizes and relative ages. They prune `.git` and `node_modules` and cap child directories at 12 entries. An elision marker indicates omitted entries while preserving the oldest shown entry.
461
+
462
+ ### Lines and local resources
85
463
 
86
- `search` searches file contents with a regex across files, directories, globs, archive members, SQLite selectors, and internal URLs. It accepts `pattern`, optional `paths`, `i`, `case`, `gitignore`, and `skip`. Omitted, empty-string, or empty-array `paths` search the workspace root; copied quoted paths are normalized, exact filesystem paths with delimiters are preserved, and comma/semicolon-joined filesystem/resource paths are split when at least one part resolves while whitespace joins require every part to resolve. Whitespace-only patterns are rejected; other patterns are preserved verbatim, including ripgrep-style inline flags such as `(?i)`, `(?m)`, and `(?x)` for resource-backed selectors. Default search output is paged by matching files (20 by default), caps multi-file output to 20 matches per file while single-file searches allow 200 matches, uses `search.contextBefore`/`search.contextAfter` settings (1 before and 3 after by default), and `skip` pages files while single-file searches ignore it. When pagination reaches the internal collection ceiling, the output tells you to refine the pattern/path instead of silently reporting that later matches do not exist. Line selectors scope matches first and then render context around in-range matches, so context-only lines outside the selected range do not count as hits. Local filesystem search prefers the bundled Rust ripgrep-backed native `grep` implementation derived from oh-my-pi, preserving upstream 4 MiB file caps, context, line truncation, hidden-file defaults, and `.gitignore` handling; resource-backed searches use the native in-memory matcher when available and keep the JS fallback for multiline/resource edge cases. Search details include scope, counts, file lists, per-file match counts, missing paths, displayed content metadata, and `fileLimitReached`/`meta.limits.fileLimit` when pagination has more matching files. Hashline search rows preserve match/context markers as `*LINE:...` and ` LINE:...`.
464
+ `read` and `search` accept selectors such as `file.ts:5-16`, `file.ts:5+3`, `file.ts:5-16,960-973`, and `https://example.test/page:5-8`. Bounded reads include one leading and three trailing context lines. Use `:raw` for unformatted content. Out-of-range selectors report that the range is beyond EOF.
87
465
 
88
- Directory `read` output renders an oh-my-pi-style depth-2 tree sorted by most-recent modification time, includes file sizes/relative ages, prunes `.git`/`node_modules`, and caps child directories to 12 entries with an elision marker while preserving the oldest shown entry. `read`, `write`, and `search` support local zip/jar/tar/tgz/gzip archive members without a Python dependency, including archive members literally named `raw`, `conflicts`, `1`, `L1`, or paths like `raw:notes.txt`, SQLite table/row selectors (`limit`, `offset`, `where`, `order`, `schema`, and `sampleRows` query parameters), `skill://` and source-backed `local://` selectors (which use the underlying filesystem path for mutable hashline labels/snapshots), and session-router-backed internal resources such as `artifact://`, `agent://`, `history://`, `issue://`, `pr://`, `rule://`, `mcp://`, and `vault://` when the host exposes a router. Workspace-scoped selectors (`local://`, built-in `skill://`, local archives, and SQLite selectors) reject lexical and symlink escapes outside the workspace or skill root. Existing non-SQLite `.db`/`.sqlite` files remain plain files; archive writes reject directory targets ending in `/`; archive writes return their resolved archive path, SQLite writes return source-path metadata, shebang writes are chmodded executable and report `madeExecutable`, SQLite table reads show schema plus a 5-row sample by default, SQLite query reads default to 20 rows with a 500 cap (raw `?q=` supports single-statement `SELECT` queries only, rejects `sqlite_%` internals, `pragma_*` table-valued functions, and dangerous keywords such as `ATTACH`, and is capped to 1000 rows via streaming iteration; table lists cap to 500 excluding `sqlite_%` tables, and table row counts probe at most 50,001 rows), table writes accept `{}` as `INSERT DEFAULT VALUES`, row writes parse non-empty JSON5-style objects including comments, and SQLite writes validate column names/scalar values before binding (empty SQLite row writes delete only when a row id is present). `conflict://<id>` and `conflict://*` writes splice conflict marker regions, expand `@ours`, `@theirs`, and `@base`, and return fresh hashline snapshot headers for resolved files; scoped conflict sides such as `conflict://1/ours` are read-only. Plain `write` refuses to overwrite generated-looking files when generated markers appear near the top of the file. `read` extracts readable text for HTML URLs and notebooks (`.ipynb` cells use 0-based `cell:N` IDs and preserve unknown top-level notebook fields), and routes PDFs plus Office/document formats (`.doc`, `.docx`, `.ppt`, `.pptx`, `.xls`, `.xlsx`, `.rtf`, `.epub`) through the same `markit-ai` converter path as oh-my-pi, including upstream unsupported-format messages when no converter is available. Extensionless URL downloads are decoded when the `Content-Type` identifies the document type. Oversized URL/resource/document reads return guidance plus structured details so collapsed renderers still surface the block reason. Successful `read` results consistently return `details.meta.source`/`sourcePath` (plus `truncation`/`limits` when truncation or list limits apply), and `read`/`search` accept line selectors such as `file.ts:5-16`, `file.ts:5+3`, `file.ts:5-16,960-973`, or `https://example.test/page:5-8`; bounded read selectors include one leading and three trailing context lines unless `:raw` is used for unformatted content, and out-of-range selectors report a clear beyond-EOF message instead of returning an empty success.
466
+ `read`, `write`, and `search` support:
89
467
 
90
- Plain URL reads follow oh-my-pi's fetch-pipeline truncation contract: unselected URL output shows the first 300 rendered lines (capped at 50 KiB), preserves full-output artifact/truncation metadata when available, and does not hard-block solely because the rendered URL body is large. By default Atomic rejects private, localhost, cloud-metadata, numeric/short-form private-IP URL targets (for example `2130706433`, octal/hex dotted forms, and `127.1`), IPv4-compatible and IPv4-mapped IPv6, NAT64, 6to4 private-address forms, and the full IPv6 link-local `fe80::/10` range, revalidates each manual redirect, pins DNS-validated addresses for outbound fetches, and caps streamed URL bodies; `ATOMIC_ALLOW_PRIVATE_URL_READS=1` is a dev-only escape hatch for trusted local tests and must not be set from untrusted project configuration. Local text reads use the shared 3,000-line/50 KiB output cap, while search match/context lines use the upstream 512-character cap before emitting a truncation notice.
468
+ - Local zip/jar/tar/tgz/gzip archive members without a Python dependency. Member names may include `raw`, `conflicts`, `1`, `L1`, or `raw:notes.txt`.
469
+ - SQLite table and row selectors, with `limit`, `offset`, `where`, `order`, `schema`, and `sampleRows` query parameters.
470
+ - `skill://` and source-backed `local://` selectors. Editable hashline labels and snapshots use the underlying filesystem path.
471
+
472
+ Workspace-scoped selectors reject lexical and symlink escapes outside the workspace or skill root. Existing non-SQLite `.db` and `.sqlite` files remain plain files. Archive writes reject directory targets ending in `/` and return the resolved archive path. SQLite writes return source-path metadata.
473
+
474
+ ### SQLite limits and writes
475
+
476
+ - Table reads show the schema and a 5-row sample by default. Query reads default to 20 rows, capped at 500.
477
+ - Raw `?q=` queries accept only single-statement `SELECT` and stream at most 1000 rows. They reject `sqlite_%` internals, `pragma_*` table-valued functions, and dangerous keywords such as `ATTACH`.
478
+ - Table lists cap at 500, excluding `sqlite_%` tables. Row counts probe at most 50,001 rows.
479
+ - Table writes accept `{}` as `INSERT DEFAULT VALUES`. Row writes parse non-empty JSON5-style objects, including comments, and validate column names and scalar values before binding.
480
+ - Empty SQLite row writes delete only when a row ID is present.
481
+
482
+ ### Conflict resolution and file writes
483
+
484
+ `conflict://<id>` and `conflict://*` writes replace conflict marker regions, expand `@ours`, `@theirs`, and `@base`, and return fresh hashline headers. Scoped sides such as `conflict://1/ours` are read-only.
485
+
486
+ Plain `write` refuses to overwrite files with generated-file markers near the top. Writes containing a shebang make the file executable and report `madeExecutable`.
487
+
488
+ ### Documents and URLs
489
+
490
+ `read` extracts readable text from HTML URLs and notebooks. Notebook cells use 0-based `cell:N` IDs; unknown top-level notebook fields are preserved.
491
+
492
+ PDFs and `.doc`, `.docx`, `.ppt`, `.pptx`, `.xls`, `.xlsx`, `.rtf`, and `.epub` documents use the `markit-ai` converter. If no converter is available, the tool reports the unsupported format. Extensionless downloads are decoded when `Content-Type` identifies the document type.
493
+
494
+ Output limits depend on the source:
495
+
496
+ - Local text reads show up to 3,000 lines or 50 KiB.
497
+ - Unselected URL reads show the first 300 rendered lines, capped at 50 KiB. Large rendered bodies are truncated rather than blocked solely for their size; full-output and truncation metadata are retained when available.
498
+ - Search match and context lines are capped at 512 characters, followed by a truncation notice.
499
+ - Oversized resource/document reads return guidance and structured details identifying the block reason.
500
+
501
+ Successful reads include `details.meta.source` and `sourcePath`, plus `truncation` and `limits` when applicable.
502
+
503
+ Atomic blocks private, localhost, and cloud-metadata URL targets, including alternative numeric IP spellings and IPv6 forms. Redirects are checked too. Use an accessible public URL rather than trying alternate spellings to bypass the restriction.
91
504
 
92
505
  ## `ask_user_question`
93
506
 
@@ -114,20 +527,18 @@ A cancelled or unanswered question is not approval. If no usable question tool i
114
527
 
115
528
  ## Persisted tool output
116
529
 
117
- Output that does not fit in a tool result is written to a file, and the result points at it — `Full output: <path>` for `bash`, `Full output saved to: <path>` for any tool result that crosses the persistence threshold. Those files are storage, so Atomic bounds where they go, how large they get, and how long they live.
530
+ When output does not fit in a tool result, Atomic saves it to a file and returns its path: `Full output: <path>` for `bash`, or `Full output saved to: <path>` for any tool result that crosses the persistence threshold. Atomic limits these files' location, size, and lifetime.
118
531
 
119
- **Where.** A session that persists to disk keeps its tool results in `<sessionDir>/tool-results/`, unchanged. Everything else — `bash` overflow logs, streamed spill files, and tool results for in-memory sessions — goes under one owner- and session-scoped temp tree:
532
+ **Where.** Disk-persisted sessions keep tool results in `<sessionDir>/tool-results/`. Bash overflow logs, streamed spill files, and tool results for in-memory sessions use one owner- and session-scoped temp tree:
120
533
 
121
534
  ```text
122
535
  <tmpdir>/atomic-<uid>/<session-id>/
123
536
  ```
124
537
 
125
- On Windows, where there is no uid, the account name is used instead — qualified by its domain and followed by a short digest, so that `CONTOSO\Alice` and `FABRIKAM\Alice`, or two names that reduce to the same safe path component, do not share one tree. The session id is reduced to a single safe path component, so a session id containing separators or `..` cannot place files outside that tree.
126
-
127
- Directories are created with `0700` and files with `0600` on platforms that support them. On POSIX that is enforced: a root owned by another account is refused and a too-permissive one is tightened. On Windows, Node exposes neither an owner SID nor a POSIX mode, so before adopting an existing component Atomic reads its security descriptor through PowerShell `Get-Acl` and decides from SIDs: the owner must be the current user, SYSTEM, or Administrators, and every access-allowed DACL entry must grant only those principals. A foreign-owned root, a root other accounts can access (a machine-wide redirected `TMP`), and a descriptor that cannot be read or fully parsed are all refused. A successful verification is cached per path per process, keyed to the directory's metadata identity — creation, change, and last-write times — so both a directory swapped underneath the path and an in-place DACL edit (which bumps the NTFS change time) force a fresh descriptor read; only a directory whose metadata is unchanged skips the subprocess.
538
+ On Windows, the temp root uses an account-specific name instead of a uid. Atomic refuses unsafe shared or linked temp paths. On systems that support POSIX permissions, directories use `0700` and files use `0600`. If storage cannot be made safe or written, the tool reports no spill path.
128
539
 
129
- Because that path is predictable, Atomic validates it rather than trusting it. Every component below the system temp directory is created one level at a time and checked: a symlink is refused outright, a directory owned by another account is refused, and a directory of this account's left too permissive is tightened to `0700` and re-checked. Refusal fails closed — the tool runs with no spill file and reports no path, instead of writing your command output into a directory someone else planted. Only the final session directory is treated as replaceable: a stale file or link sitting exactly where a session directory belongs is removed (a link by itself, never its target) and recreated.
540
+ Each persisted file is capped at 64 MB. Output beyond the cap is replaced by `[Output truncated: persisted-output cap of 67108864 bytes reached]`; the returned `fullOutputPath` still points to that capped file. UTF-8 characters are not split, and binary bytes are preserved.
130
541
 
131
- **How large.** No single persisted-output file exceeds 64 MB. Output that lands exactly on the cap is kept whole; only output that passes it is cut off there, with `[Output truncated: persisted-output cap of 67108864 bytes reached]` appended in place of the rest. The cut lands on a character boundary even when a multi-byte character is split across two chunks of streamed output, and bytes that are not valid UTF-8 — binary command output — are written through unchanged rather than decoded. The truncation is in the file only; the tool result and its `fullOutputPath` are unaffected. If a spill file cannot be written at all, `bash` reports no path rather than one pointing at a file that is not there.
542
+ Cleanup removes temp trees and `tool-results` directories whose newest file is more than 30 days old. One fresh file keeps the directory. This includes custom roots selected with `--session-dir`, `ATOMIC_CODING_AGENT_SESSION_DIR`, or `sessionDir`.
132
543
 
133
- **How long.** Tool-output storage is reaped on age. A sweep runs shortly after startup, off the startup path, and removes session temp trees and `tool-results` directories whose newest file is more than 30 days old. It covers the default project-nested session roots and a custom session directory chosen with `--session-dir`, `ATOMIC_CODING_AGENT_SESSION_DIR`, or the `sessionDir` setting. The newest entry decides the whole directory: one fresh file keeps everything beside it, so a path recorded weeks ago stays readable as long as the tree is still in use. Each target is throttled to once a day by a `.last-cleanup` marker and guarded by a `.cleanup.lock` exclusive lock, so concurrent Atomic sessions never race each other; for session storage that pair lives in a control directory under the temp root rather than inside the scanned directory. A tree belonging to a session the running process is using is never reaped, so a `Full output saved to:` path stays valid for the life of the session that produced it. Session transcripts and `.jsonl` session files are outside the sweep entirely: only the temp trees and `tool-results` directories are ever deleted, symlinks are never followed out of a target, and a directory the sweep cannot verify as a real directory is skipped rather than read.
544
+ Output from a session in the running process remains available for that session's lifetime. Cleanup never deletes session transcripts or `.jsonl` files and does not follow symlinks. Copy important output elsewhere before relying on it long-term.