experimental-ash 0.2.0-alpha.2 → 0.2.0-alpha.21

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 (585) hide show
  1. package/dist/src/channel/http-channel.d.ts +26 -0
  2. package/dist/src/channel/http-channel.d.ts.map +1 -0
  3. package/dist/src/channel/http-channel.js +24 -0
  4. package/dist/src/channel/http-channel.js.map +1 -0
  5. package/dist/src/channel/resolve-text.d.ts +20 -0
  6. package/dist/src/channel/resolve-text.d.ts.map +1 -0
  7. package/dist/src/channel/resolve-text.js +60 -0
  8. package/dist/src/channel/resolve-text.js.map +1 -0
  9. package/dist/src/channel/schedule-channel.d.ts +16 -0
  10. package/dist/src/channel/schedule-channel.d.ts.map +1 -0
  11. package/dist/src/channel/schedule-channel.js +20 -0
  12. package/dist/src/channel/schedule-channel.js.map +1 -0
  13. package/dist/src/channel/schedule.d.ts +4 -6
  14. package/dist/src/channel/schedule.d.ts.map +1 -1
  15. package/dist/src/channel/schedule.js +6 -9
  16. package/dist/src/channel/schedule.js.map +1 -1
  17. package/dist/src/channel/slack-channel.d.ts +125 -0
  18. package/dist/src/channel/slack-channel.d.ts.map +1 -0
  19. package/dist/src/channel/slack-channel.js +320 -0
  20. package/dist/src/channel/slack-channel.js.map +1 -0
  21. package/dist/src/channel/subagent-channel.d.ts +41 -0
  22. package/dist/src/channel/subagent-channel.d.ts.map +1 -0
  23. package/dist/src/channel/{subagent-emitter.js → subagent-channel.js} +15 -19
  24. package/dist/src/channel/subagent-channel.js.map +1 -0
  25. package/dist/src/channel/types.d.ts +157 -90
  26. package/dist/src/channel/types.d.ts.map +1 -1
  27. package/dist/src/channel/types.js +64 -1
  28. package/dist/src/channel/types.js.map +1 -1
  29. package/dist/src/cli/dev/input-requests.d.ts +4 -4
  30. package/dist/src/cli/dev/input-requests.d.ts.map +1 -1
  31. package/dist/src/cli/dev/input-requests.js +34 -65
  32. package/dist/src/cli/dev/input-requests.js.map +1 -1
  33. package/dist/src/cli/dev/repl.d.ts.map +1 -1
  34. package/dist/src/cli/dev/repl.js +41 -24
  35. package/dist/src/cli/dev/repl.js.map +1 -1
  36. package/dist/src/client/index.d.ts +3 -2
  37. package/dist/src/client/index.d.ts.map +1 -1
  38. package/dist/src/client/index.js +1 -0
  39. package/dist/src/client/index.js.map +1 -1
  40. package/dist/src/client/message-response.d.ts +5 -5
  41. package/dist/src/client/message-response.d.ts.map +1 -1
  42. package/dist/src/client/message-response.js +6 -6
  43. package/dist/src/client/message-response.js.map +1 -1
  44. package/dist/src/client/open-stream.d.ts +1 -1
  45. package/dist/src/client/open-stream.d.ts.map +1 -1
  46. package/dist/src/client/open-stream.js +1 -1
  47. package/dist/src/client/open-stream.js.map +1 -1
  48. package/dist/src/client/session-utils.d.ts +3 -3
  49. package/dist/src/client/session-utils.d.ts.map +1 -1
  50. package/dist/src/client/session-utils.js +4 -4
  51. package/dist/src/client/session-utils.js.map +1 -1
  52. package/dist/src/client/session.d.ts +5 -5
  53. package/dist/src/client/session.js +28 -28
  54. package/dist/src/client/session.js.map +1 -1
  55. package/dist/src/client/types.d.ts +8 -8
  56. package/dist/src/client/types.d.ts.map +1 -1
  57. package/dist/src/compiler/channel-url.d.ts +1 -1
  58. package/dist/src/compiler/channel-url.js +1 -1
  59. package/dist/src/compiler/manifest.d.ts +38 -5
  60. package/dist/src/compiler/manifest.d.ts.map +1 -1
  61. package/dist/src/compiler/manifest.js +15 -1
  62. package/dist/src/compiler/manifest.js.map +1 -1
  63. package/dist/src/compiler/module-map.js +8 -0
  64. package/dist/src/compiler/module-map.js.map +1 -1
  65. package/dist/src/compiler/normalize-channel.d.ts +1 -1
  66. package/dist/src/compiler/normalize-channel.js +3 -3
  67. package/dist/src/compiler/normalize-channel.js.map +1 -1
  68. package/dist/src/compiler/normalize-connection.d.ts +14 -0
  69. package/dist/src/compiler/normalize-connection.d.ts.map +1 -0
  70. package/dist/src/compiler/normalize-connection.js +29 -0
  71. package/dist/src/compiler/normalize-connection.js.map +1 -0
  72. package/dist/src/compiler/normalize-manifest.d.ts.map +1 -1
  73. package/dist/src/compiler/normalize-manifest.js +2 -0
  74. package/dist/src/compiler/normalize-manifest.js.map +1 -1
  75. package/dist/src/context/accessors.d.ts +13 -12
  76. package/dist/src/context/accessors.d.ts.map +1 -1
  77. package/dist/src/context/accessors.js +16 -17
  78. package/dist/src/context/accessors.js.map +1 -1
  79. package/dist/src/context/container.d.ts +17 -19
  80. package/dist/src/context/container.d.ts.map +1 -1
  81. package/dist/src/context/container.js +21 -14
  82. package/dist/src/context/container.js.map +1 -1
  83. package/dist/src/context/durable-context.d.ts +18 -0
  84. package/dist/src/context/durable-context.d.ts.map +1 -0
  85. package/dist/src/context/durable-context.js +49 -0
  86. package/dist/src/context/durable-context.js.map +1 -0
  87. package/dist/src/context/key.d.ts +43 -83
  88. package/dist/src/context/key.d.ts.map +1 -1
  89. package/dist/src/context/key.js +58 -80
  90. package/dist/src/context/key.js.map +1 -1
  91. package/dist/src/context/keys.d.ts +8 -20
  92. package/dist/src/context/keys.d.ts.map +1 -1
  93. package/dist/src/context/keys.js +20 -34
  94. package/dist/src/context/keys.js.map +1 -1
  95. package/dist/src/context/provider.d.ts +2 -2
  96. package/dist/src/context/provider.d.ts.map +1 -1
  97. package/dist/src/context/providers/connection.d.ts +4 -0
  98. package/dist/src/context/providers/connection.d.ts.map +1 -0
  99. package/dist/src/context/providers/connection.js +18 -0
  100. package/dist/src/context/providers/connection.js.map +1 -0
  101. package/dist/src/context/providers/session.d.ts.map +1 -1
  102. package/dist/src/context/providers/session.js +1 -2
  103. package/dist/src/context/providers/session.js.map +1 -1
  104. package/dist/src/context/providers/skill.d.ts.map +1 -1
  105. package/dist/src/context/providers/skill.js +2 -15
  106. package/dist/src/context/providers/skill.js.map +1 -1
  107. package/dist/src/context/run-step.d.ts +6 -8
  108. package/dist/src/context/run-step.d.ts.map +1 -1
  109. package/dist/src/context/run-step.js +15 -17
  110. package/dist/src/context/run-step.js.map +1 -1
  111. package/dist/src/context/seed-keys.d.ts +21 -0
  112. package/dist/src/context/seed-keys.d.ts.map +1 -0
  113. package/dist/src/context/seed-keys.js +31 -0
  114. package/dist/src/context/seed-keys.js.map +1 -0
  115. package/dist/src/context/serialize.d.ts +8 -9
  116. package/dist/src/context/serialize.d.ts.map +1 -1
  117. package/dist/src/context/serialize.js +38 -15
  118. package/dist/src/context/serialize.js.map +1 -1
  119. package/dist/src/discover/connections.d.ts +48 -0
  120. package/dist/src/discover/connections.d.ts.map +1 -0
  121. package/dist/src/discover/connections.js +169 -0
  122. package/dist/src/discover/connections.js.map +1 -0
  123. package/dist/src/discover/discover-agent.d.ts +1 -0
  124. package/dist/src/discover/discover-agent.d.ts.map +1 -1
  125. package/dist/src/discover/discover-agent.js +8 -0
  126. package/dist/src/discover/discover-agent.js.map +1 -1
  127. package/dist/src/discover/discover-subagent.js +7 -0
  128. package/dist/src/discover/discover-subagent.js.map +1 -1
  129. package/dist/src/discover/filesystem.d.ts +3 -3
  130. package/dist/src/discover/filesystem.d.ts.map +1 -1
  131. package/dist/src/discover/filesystem.js +7 -0
  132. package/dist/src/discover/filesystem.js.map +1 -1
  133. package/dist/src/discover/grammar.d.ts +20 -4
  134. package/dist/src/discover/grammar.d.ts.map +1 -1
  135. package/dist/src/discover/grammar.js +31 -5
  136. package/dist/src/discover/grammar.js.map +1 -1
  137. package/dist/src/discover/manifest.d.ts +28 -1
  138. package/dist/src/discover/manifest.d.ts.map +1 -1
  139. package/dist/src/discover/manifest.js +11 -1
  140. package/dist/src/discover/manifest.js.map +1 -1
  141. package/dist/src/evals/runner/artifacts.js +1 -1
  142. package/dist/src/evals/runner/artifacts.js.map +1 -1
  143. package/dist/src/evals/runner/derive-run-facts.js +5 -5
  144. package/dist/src/evals/runner/derive-run-facts.js.map +1 -1
  145. package/dist/src/evals/runner/execute-case.js +4 -4
  146. package/dist/src/evals/runner/execute-case.js.map +1 -1
  147. package/dist/src/evals/runner/execute-suite.js +1 -1
  148. package/dist/src/evals/runner/execute-suite.js.map +1 -1
  149. package/dist/src/evals/runner/reporters/braintrust.js +2 -2
  150. package/dist/src/evals/runner/reporters/braintrust.js.map +1 -1
  151. package/dist/src/evals/types.d.ts +4 -4
  152. package/dist/src/evals/types.d.ts.map +1 -1
  153. package/dist/src/execution/continuous-entry.d.ts +18 -9
  154. package/dist/src/execution/continuous-entry.d.ts.map +1 -1
  155. package/dist/src/execution/continuous-entry.js +62 -18
  156. package/dist/src/execution/continuous-entry.js.map +1 -1
  157. package/dist/src/execution/continuous-runtime.d.ts +1 -1
  158. package/dist/src/execution/continuous-runtime.d.ts.map +1 -1
  159. package/dist/src/execution/continuous-runtime.js +14 -10
  160. package/dist/src/execution/continuous-runtime.js.map +1 -1
  161. package/dist/src/execution/node-step.d.ts +1 -2
  162. package/dist/src/execution/node-step.d.ts.map +1 -1
  163. package/dist/src/execution/node-step.js +42 -55
  164. package/dist/src/execution/node-step.js.map +1 -1
  165. package/dist/src/execution/runtime-context.d.ts +3 -0
  166. package/dist/src/execution/runtime-context.d.ts.map +1 -1
  167. package/dist/src/execution/runtime-context.js +6 -4
  168. package/dist/src/execution/runtime-context.js.map +1 -1
  169. package/dist/src/execution/session.d.ts +2 -1
  170. package/dist/src/execution/session.d.ts.map +1 -1
  171. package/dist/src/execution/session.js +1 -0
  172. package/dist/src/execution/session.js.map +1 -1
  173. package/dist/src/execution/skills/access.d.ts.map +1 -1
  174. package/dist/src/execution/skills/instructions.d.ts +6 -6
  175. package/dist/src/execution/skills/instructions.d.ts.map +1 -1
  176. package/dist/src/execution/skills/instructions.js +15 -15
  177. package/dist/src/execution/skills/instructions.js.map +1 -1
  178. package/dist/src/execution/skills/types.d.ts +4 -4
  179. package/dist/src/execution/skills/types.d.ts.map +1 -1
  180. package/dist/src/execution/step-context.d.ts +27 -0
  181. package/dist/src/execution/step-context.d.ts.map +1 -0
  182. package/dist/src/execution/step-context.js +54 -0
  183. package/dist/src/execution/step-context.js.map +1 -0
  184. package/dist/src/execution/subagent-tool.d.ts +1 -1
  185. package/dist/src/execution/subagent-tool.d.ts.map +1 -1
  186. package/dist/src/execution/subagent-tool.js +3 -4
  187. package/dist/src/execution/subagent-tool.js.map +1 -1
  188. package/dist/src/execution/tool-compaction.d.ts +1 -3
  189. package/dist/src/execution/tool-compaction.d.ts.map +1 -1
  190. package/dist/src/execution/tool-compaction.js +6 -20
  191. package/dist/src/execution/tool-compaction.js.map +1 -1
  192. package/dist/src/execution/types.d.ts +1 -1
  193. package/dist/src/execution/types.d.ts.map +1 -1
  194. package/dist/src/execution/workflow-entry.d.ts +4 -5
  195. package/dist/src/execution/workflow-entry.d.ts.map +1 -1
  196. package/dist/src/execution/workflow-entry.js +7 -2
  197. package/dist/src/execution/workflow-entry.js.map +1 -1
  198. package/dist/src/execution/workflow-runtime.d.ts.map +1 -1
  199. package/dist/src/execution/workflow-runtime.js +10 -5
  200. package/dist/src/execution/workflow-runtime.js.map +1 -1
  201. package/dist/src/execution/workflow-steps.d.ts +13 -6
  202. package/dist/src/execution/workflow-steps.d.ts.map +1 -1
  203. package/dist/src/execution/workflow-steps.js +24 -19
  204. package/dist/src/execution/workflow-steps.js.map +1 -1
  205. package/dist/src/harness/emission.d.ts +36 -27
  206. package/dist/src/harness/emission.d.ts.map +1 -1
  207. package/dist/src/harness/emission.js +130 -84
  208. package/dist/src/harness/emission.js.map +1 -1
  209. package/dist/src/harness/execute-tool.d.ts +52 -0
  210. package/dist/src/harness/execute-tool.d.ts.map +1 -0
  211. package/dist/src/harness/execute-tool.js +59 -0
  212. package/dist/src/harness/execute-tool.js.map +1 -0
  213. package/dist/src/harness/input-extraction.d.ts +3 -3
  214. package/dist/src/harness/input-extraction.d.ts.map +1 -1
  215. package/dist/src/harness/input-extraction.js +15 -8
  216. package/dist/src/harness/input-extraction.js.map +1 -1
  217. package/dist/src/harness/input-requests.d.ts +46 -40
  218. package/dist/src/harness/input-requests.d.ts.map +1 -1
  219. package/dist/src/harness/input-requests.js +169 -245
  220. package/dist/src/harness/input-requests.js.map +1 -1
  221. package/dist/src/harness/messages.d.ts +10 -9
  222. package/dist/src/harness/messages.d.ts.map +1 -1
  223. package/dist/src/harness/messages.js +23 -20
  224. package/dist/src/harness/messages.js.map +1 -1
  225. package/dist/src/harness/provider-tools.d.ts +2 -2
  226. package/dist/src/harness/provider-tools.d.ts.map +1 -1
  227. package/dist/src/harness/provider-tools.js +7 -3
  228. package/dist/src/harness/provider-tools.js.map +1 -1
  229. package/dist/src/harness/step-hooks.d.ts +77 -0
  230. package/dist/src/harness/step-hooks.d.ts.map +1 -0
  231. package/dist/src/harness/step-hooks.js +192 -0
  232. package/dist/src/harness/step-hooks.js.map +1 -0
  233. package/dist/src/harness/tool-loop.d.ts +4 -2
  234. package/dist/src/harness/tool-loop.d.ts.map +1 -1
  235. package/dist/src/harness/tool-loop.js +130 -181
  236. package/dist/src/harness/tool-loop.js.map +1 -1
  237. package/dist/src/harness/tools.d.ts +12 -16
  238. package/dist/src/harness/tools.d.ts.map +1 -1
  239. package/dist/src/harness/tools.js +39 -33
  240. package/dist/src/harness/tools.js.map +1 -1
  241. package/dist/src/harness/types.d.ts +44 -28
  242. package/dist/src/harness/types.d.ts.map +1 -1
  243. package/dist/src/harness/types.js +6 -1
  244. package/dist/src/harness/types.js.map +1 -1
  245. package/dist/src/internal/application/compiled-artifacts.d.ts +5 -3
  246. package/dist/src/internal/application/compiled-artifacts.d.ts.map +1 -1
  247. package/dist/src/internal/application/compiled-artifacts.js +19 -40
  248. package/dist/src/internal/application/compiled-artifacts.js.map +1 -1
  249. package/dist/src/internal/application/package.js +1 -1
  250. package/dist/src/internal/authored-definition/channel.d.ts +3 -3
  251. package/dist/src/internal/authored-definition/channel.d.ts.map +1 -1
  252. package/dist/src/internal/authored-definition/channel.js +28 -4
  253. package/dist/src/internal/authored-definition/channel.js.map +1 -1
  254. package/dist/src/internal/authored-definition/connection.d.ts +10 -0
  255. package/dist/src/internal/authored-definition/connection.d.ts.map +1 -0
  256. package/dist/src/internal/authored-definition/connection.js +134 -0
  257. package/dist/src/internal/authored-definition/connection.js.map +1 -0
  258. package/dist/src/internal/authored-module.js +1 -1
  259. package/dist/src/internal/authored-module.js.map +1 -1
  260. package/dist/src/internal/message/builder.d.ts +1 -2
  261. package/dist/src/internal/message/builder.d.ts.map +1 -1
  262. package/dist/src/internal/message/builder.js +4 -12
  263. package/dist/src/internal/message/builder.js.map +1 -1
  264. package/dist/src/internal/nitro/host/configure-message-routes.d.ts +3 -1
  265. package/dist/src/internal/nitro/host/configure-message-routes.d.ts.map +1 -1
  266. package/dist/src/internal/nitro/host/configure-message-routes.js +124 -25
  267. package/dist/src/internal/nitro/host/configure-message-routes.js.map +1 -1
  268. package/dist/src/internal/nitro/host/create-application-nitro.d.ts.map +1 -1
  269. package/dist/src/internal/nitro/host/create-application-nitro.js +63 -21
  270. package/dist/src/internal/nitro/host/create-application-nitro.js.map +1 -1
  271. package/dist/src/internal/nitro/host/load-home-page-web-assets.d.ts +13 -0
  272. package/dist/src/internal/nitro/host/load-home-page-web-assets.d.ts.map +1 -0
  273. package/dist/src/internal/nitro/host/load-home-page-web-assets.js +35 -0
  274. package/dist/src/internal/nitro/host/load-home-page-web-assets.js.map +1 -0
  275. package/dist/src/internal/nitro/host/prepare-application-host.js +1 -1
  276. package/dist/src/internal/nitro/host/prepare-application-host.js.map +1 -1
  277. package/dist/src/internal/nitro/routes/channel-dispatch.d.ts +10 -18
  278. package/dist/src/internal/nitro/routes/channel-dispatch.d.ts.map +1 -1
  279. package/dist/src/internal/nitro/routes/channel-dispatch.js +16 -45
  280. package/dist/src/internal/nitro/routes/channel-dispatch.js.map +1 -1
  281. package/dist/src/internal/nitro/routes/home-page/build-home-page-response.d.ts +88 -0
  282. package/dist/src/internal/nitro/routes/home-page/build-home-page-response.d.ts.map +1 -0
  283. package/dist/src/internal/nitro/routes/home-page/build-home-page-response.js +175 -0
  284. package/dist/src/internal/nitro/routes/home-page/build-home-page-response.js.map +1 -0
  285. package/dist/src/internal/nitro/routes/home.d.ts +7 -0
  286. package/dist/src/internal/nitro/routes/home.d.ts.map +1 -0
  287. package/dist/src/internal/nitro/routes/home.js +22 -0
  288. package/dist/src/internal/nitro/routes/home.js.map +1 -0
  289. package/dist/src/internal/nitro/routes/index.d.ts +3 -8
  290. package/dist/src/internal/nitro/routes/index.d.ts.map +1 -1
  291. package/dist/src/internal/nitro/routes/index.js +18 -36
  292. package/dist/src/internal/nitro/routes/index.js.map +1 -1
  293. package/dist/src/internal/nitro/routes/runtime-artifacts.d.ts +10 -3
  294. package/dist/src/internal/nitro/routes/runtime-artifacts.d.ts.map +1 -1
  295. package/dist/src/internal/nitro/routes/runtime-artifacts.js +2 -9
  296. package/dist/src/internal/nitro/routes/runtime-artifacts.js.map +1 -1
  297. package/dist/src/internal/nitro/routes/runtime-stack.d.ts +8 -7
  298. package/dist/src/internal/nitro/routes/runtime-stack.d.ts.map +1 -1
  299. package/dist/src/internal/nitro/routes/runtime-stack.js +10 -10
  300. package/dist/src/internal/nitro/routes/runtime-stack.js.map +1 -1
  301. package/dist/src/internal/nitro/routes/schedule-task.d.ts +7 -7
  302. package/dist/src/internal/nitro/routes/schedule-task.d.ts.map +1 -1
  303. package/dist/src/internal/nitro/routes/schedule-task.js +22 -30
  304. package/dist/src/internal/nitro/routes/schedule-task.js.map +1 -1
  305. package/dist/src/internal/nitro/routes/web-ui/assets/index.js +10 -0
  306. package/dist/src/internal/nitro/routes/web-ui/assets/style.css +2 -0
  307. package/dist/src/internal/nitro/routes/web-ui/index.html +17 -0
  308. package/dist/src/internal/nitro/routes/workflow-data.d.ts +32 -0
  309. package/dist/src/internal/nitro/routes/workflow-data.d.ts.map +1 -0
  310. package/dist/src/internal/nitro/routes/workflow-data.js +142 -0
  311. package/dist/src/internal/nitro/routes/workflow-data.js.map +1 -0
  312. package/dist/src/internal/nitro/routes/workflow-route-helpers.d.ts +46 -0
  313. package/dist/src/internal/nitro/routes/workflow-route-helpers.d.ts.map +1 -0
  314. package/dist/src/internal/nitro/routes/workflow-route-helpers.js +137 -0
  315. package/dist/src/internal/nitro/routes/workflow-route-helpers.js.map +1 -0
  316. package/dist/src/internal/nitro/routes/workflow-run-events.d.ts +14 -0
  317. package/dist/src/internal/nitro/routes/workflow-run-events.d.ts.map +1 -0
  318. package/dist/src/internal/nitro/routes/workflow-run-events.js +42 -0
  319. package/dist/src/internal/nitro/routes/workflow-run-events.js.map +1 -0
  320. package/dist/src/internal/nitro/routes/workflow-run-steps.d.ts +14 -0
  321. package/dist/src/internal/nitro/routes/workflow-run-steps.d.ts.map +1 -0
  322. package/dist/src/internal/nitro/routes/workflow-run-steps.js +42 -0
  323. package/dist/src/internal/nitro/routes/workflow-run-steps.js.map +1 -0
  324. package/dist/src/internal/nitro/routes/workflow-run.d.ts +13 -0
  325. package/dist/src/internal/nitro/routes/workflow-run.d.ts.map +1 -0
  326. package/dist/src/internal/nitro/routes/workflow-run.js +35 -0
  327. package/dist/src/internal/nitro/routes/workflow-run.js.map +1 -0
  328. package/dist/src/internal/nitro/routes/workflow-runs.d.ts +11 -0
  329. package/dist/src/internal/nitro/routes/workflow-runs.d.ts.map +1 -0
  330. package/dist/src/internal/nitro/routes/workflow-runs.js +29 -0
  331. package/dist/src/internal/nitro/routes/workflow-runs.js.map +1 -0
  332. package/dist/src/protocol/message.d.ts +160 -76
  333. package/dist/src/protocol/message.d.ts.map +1 -1
  334. package/dist/src/protocol/message.js +92 -36
  335. package/dist/src/protocol/message.js.map +1 -1
  336. package/dist/src/protocol/routes.d.ts +11 -3
  337. package/dist/src/protocol/routes.d.ts.map +1 -1
  338. package/dist/src/protocol/routes.js +12 -4
  339. package/dist/src/protocol/routes.js.map +1 -1
  340. package/dist/src/public/channels/auth.d.ts +32 -81
  341. package/dist/src/public/channels/auth.d.ts.map +1 -1
  342. package/dist/src/public/channels/auth.js +23 -86
  343. package/dist/src/public/channels/auth.js.map +1 -1
  344. package/dist/src/public/channels/http.d.ts +66 -26
  345. package/dist/src/public/channels/http.d.ts.map +1 -1
  346. package/dist/src/public/channels/http.js +88 -78
  347. package/dist/src/public/channels/http.js.map +1 -1
  348. package/dist/src/public/channels/index.d.ts +9 -10
  349. package/dist/src/public/channels/index.d.ts.map +1 -1
  350. package/dist/src/public/channels/index.js +9 -9
  351. package/dist/src/public/channels/index.js.map +1 -1
  352. package/dist/src/public/channels/slack/index.d.ts +104 -37
  353. package/dist/src/public/channels/slack/index.d.ts.map +1 -1
  354. package/dist/src/public/channels/slack/index.js +168 -47
  355. package/dist/src/public/channels/slack/index.js.map +1 -1
  356. package/dist/src/public/channels/slack/lowlevel.d.ts +5 -5
  357. package/dist/src/public/channels/slack/lowlevel.d.ts.map +1 -1
  358. package/dist/src/public/channels/slack/lowlevel.js +4 -4
  359. package/dist/src/public/channels/slack/lowlevel.js.map +1 -1
  360. package/dist/src/public/connections/index.d.ts +25 -0
  361. package/dist/src/public/connections/index.d.ts.map +1 -0
  362. package/dist/src/public/connections/index.js +24 -0
  363. package/dist/src/public/connections/index.js.map +1 -0
  364. package/dist/src/public/definitions/channel.d.ts +89 -60
  365. package/dist/src/public/definitions/channel.d.ts.map +1 -1
  366. package/dist/src/public/definitions/channel.js +42 -24
  367. package/dist/src/public/definitions/channel.js.map +1 -1
  368. package/dist/src/public/definitions/connections/mcp.d.ts +60 -0
  369. package/dist/src/public/definitions/connections/mcp.d.ts.map +1 -0
  370. package/dist/src/public/definitions/connections/mcp.js +7 -0
  371. package/dist/src/public/definitions/connections/mcp.js.map +1 -0
  372. package/dist/src/public/definitions/tool.d.ts +14 -7
  373. package/dist/src/public/definitions/tool.d.ts.map +1 -1
  374. package/dist/src/public/definitions/tool.js.map +1 -1
  375. package/dist/src/public/index.d.ts +10 -9
  376. package/dist/src/public/index.d.ts.map +1 -1
  377. package/dist/src/public/index.js +7 -6
  378. package/dist/src/public/index.js.map +1 -1
  379. package/dist/src/public/sandboxes/internal.d.ts +1 -1
  380. package/dist/src/public/sandboxes/internal.js +1 -1
  381. package/dist/src/public/tools/defaults.d.ts +6 -6
  382. package/dist/src/public/tools/defaults.d.ts.map +1 -1
  383. package/dist/src/public/tools/defaults.js +6 -6
  384. package/dist/src/public/tools/defaults.js.map +1 -1
  385. package/dist/src/public/tools/internal.d.ts +1 -1
  386. package/dist/src/public/tools/internal.js +1 -1
  387. package/dist/src/runtime/actions/types.d.ts +21 -18
  388. package/dist/src/runtime/actions/types.d.ts.map +1 -1
  389. package/dist/src/runtime/actions/types.js +22 -19
  390. package/dist/src/runtime/actions/types.js.map +1 -1
  391. package/dist/src/runtime/agent/bootstrap-model-utils.d.ts +37 -0
  392. package/dist/src/runtime/agent/bootstrap-model-utils.d.ts.map +1 -0
  393. package/dist/src/runtime/agent/bootstrap-model-utils.js +149 -0
  394. package/dist/src/runtime/agent/bootstrap-model-utils.js.map +1 -0
  395. package/dist/src/runtime/agent/bootstrap-model.d.ts.map +1 -1
  396. package/dist/src/runtime/agent/bootstrap-model.js +11 -80
  397. package/dist/src/runtime/agent/bootstrap-model.js.map +1 -1
  398. package/dist/src/runtime/agent/bootstrap.d.ts.map +1 -1
  399. package/dist/src/runtime/agent/bootstrap.js +4 -1
  400. package/dist/src/runtime/agent/bootstrap.js.map +1 -1
  401. package/dist/src/runtime/agent/mock-model-adapter.d.ts.map +1 -1
  402. package/dist/src/runtime/agent/mock-model-adapter.js +72 -134
  403. package/dist/src/runtime/agent/mock-model-adapter.js.map +1 -1
  404. package/dist/src/runtime/channels/registry.d.ts +21 -0
  405. package/dist/src/runtime/channels/registry.d.ts.map +1 -0
  406. package/dist/src/runtime/channels/registry.js +65 -0
  407. package/dist/src/runtime/channels/registry.js.map +1 -0
  408. package/dist/src/runtime/connections/mcp-client.d.ts +48 -0
  409. package/dist/src/runtime/connections/mcp-client.d.ts.map +1 -0
  410. package/dist/src/runtime/connections/mcp-client.js +182 -0
  411. package/dist/src/runtime/connections/mcp-client.js.map +1 -0
  412. package/dist/src/runtime/connections/registry.d.ts +33 -0
  413. package/dist/src/runtime/connections/registry.d.ts.map +1 -0
  414. package/dist/src/runtime/connections/registry.js +54 -0
  415. package/dist/src/runtime/connections/registry.js.map +1 -0
  416. package/dist/src/runtime/connections/types.d.ts +75 -0
  417. package/dist/src/runtime/connections/types.d.ts.map +1 -0
  418. package/dist/src/runtime/connections/types.js +9 -0
  419. package/dist/src/runtime/connections/types.js.map +1 -0
  420. package/dist/src/runtime/framework-channels/index.d.ts +6 -6
  421. package/dist/src/runtime/framework-channels/index.d.ts.map +1 -1
  422. package/dist/src/runtime/framework-channels/index.js +16 -14
  423. package/dist/src/runtime/framework-channels/index.js.map +1 -1
  424. package/dist/src/runtime/framework-tools/ask-question.js +4 -4
  425. package/dist/src/runtime/framework-tools/ask-question.js.map +1 -1
  426. package/dist/src/runtime/framework-tools/connection-execute.d.ts +10 -0
  427. package/dist/src/runtime/framework-tools/connection-execute.d.ts.map +1 -0
  428. package/dist/src/runtime/framework-tools/connection-execute.js +50 -0
  429. package/dist/src/runtime/framework-tools/connection-execute.js.map +1 -0
  430. package/dist/src/runtime/framework-tools/connection-search.d.ts +43 -0
  431. package/dist/src/runtime/framework-tools/connection-search.d.ts.map +1 -0
  432. package/dist/src/runtime/framework-tools/connection-search.js +135 -0
  433. package/dist/src/runtime/framework-tools/connection-search.js.map +1 -0
  434. package/dist/src/runtime/framework-tools/file-state.d.ts +5 -5
  435. package/dist/src/runtime/framework-tools/file-state.d.ts.map +1 -1
  436. package/dist/src/runtime/framework-tools/file-state.js +6 -8
  437. package/dist/src/runtime/framework-tools/file-state.js.map +1 -1
  438. package/dist/src/runtime/framework-tools/index.d.ts +3 -1
  439. package/dist/src/runtime/framework-tools/index.d.ts.map +1 -1
  440. package/dist/src/runtime/framework-tools/index.js +10 -1
  441. package/dist/src/runtime/framework-tools/index.js.map +1 -1
  442. package/dist/src/runtime/framework-tools/skill.d.ts +4 -4
  443. package/dist/src/runtime/framework-tools/skill.d.ts.map +1 -1
  444. package/dist/src/runtime/framework-tools/skill.js +14 -11
  445. package/dist/src/runtime/framework-tools/skill.js.map +1 -1
  446. package/dist/src/runtime/framework-tools/todo.d.ts.map +1 -1
  447. package/dist/src/runtime/framework-tools/todo.js +2 -4
  448. package/dist/src/runtime/framework-tools/todo.js.map +1 -1
  449. package/dist/src/runtime/input/types.d.ts +40 -115
  450. package/dist/src/runtime/input/types.d.ts.map +1 -1
  451. package/dist/src/runtime/input/types.js +28 -66
  452. package/dist/src/runtime/input/types.js.map +1 -1
  453. package/dist/src/runtime/loaders/module-map.js +8 -0
  454. package/dist/src/runtime/loaders/module-map.js.map +1 -1
  455. package/dist/src/runtime/prompt/compose.d.ts +4 -1
  456. package/dist/src/runtime/prompt/compose.d.ts.map +1 -1
  457. package/dist/src/runtime/prompt/compose.js +18 -1
  458. package/dist/src/runtime/prompt/compose.js.map +1 -1
  459. package/dist/src/runtime/prompt/connections.d.ts +10 -0
  460. package/dist/src/runtime/prompt/connections.d.ts.map +1 -0
  461. package/dist/src/runtime/prompt/connections.js +25 -0
  462. package/dist/src/runtime/prompt/connections.js.map +1 -0
  463. package/dist/src/runtime/resolve-agent-graph.d.ts.map +1 -1
  464. package/dist/src/runtime/resolve-agent-graph.js +29 -7
  465. package/dist/src/runtime/resolve-agent-graph.js.map +1 -1
  466. package/dist/src/runtime/resolve-agent.d.ts.map +1 -1
  467. package/dist/src/runtime/resolve-agent.js +3 -0
  468. package/dist/src/runtime/resolve-agent.js.map +1 -1
  469. package/dist/src/runtime/resolve-channel.d.ts.map +1 -1
  470. package/dist/src/runtime/resolve-channel.js +1 -0
  471. package/dist/src/runtime/resolve-channel.js.map +1 -1
  472. package/dist/src/runtime/resolve-connection.d.ts +16 -0
  473. package/dist/src/runtime/resolve-connection.d.ts.map +1 -0
  474. package/dist/src/runtime/resolve-connection.js +69 -0
  475. package/dist/src/runtime/resolve-connection.js.map +1 -0
  476. package/dist/src/runtime/resolve-tool.d.ts.map +1 -1
  477. package/dist/src/runtime/resolve-tool.js +8 -0
  478. package/dist/src/runtime/resolve-tool.js.map +1 -1
  479. package/dist/src/runtime/sessions/auth.d.ts +1 -1
  480. package/dist/src/runtime/sessions/compiled-agent-cache.d.ts +2 -0
  481. package/dist/src/runtime/sessions/compiled-agent-cache.d.ts.map +1 -1
  482. package/dist/src/runtime/sessions/compiled-agent-cache.js +14 -0
  483. package/dist/src/runtime/sessions/compiled-agent-cache.js.map +1 -1
  484. package/dist/src/runtime/skills/fragment-context.d.ts +2 -2
  485. package/dist/src/runtime/skills/fragment-context.d.ts.map +1 -1
  486. package/dist/src/runtime/skills/fragment-context.js +2 -2
  487. package/dist/src/runtime/skills/fragment-context.js.map +1 -1
  488. package/dist/src/runtime/standard-schema.d.ts +28 -0
  489. package/dist/src/runtime/standard-schema.d.ts.map +1 -0
  490. package/dist/src/runtime/standard-schema.js +65 -0
  491. package/dist/src/runtime/standard-schema.js.map +1 -0
  492. package/dist/src/runtime/types.d.ts +29 -3
  493. package/dist/src/runtime/types.d.ts.map +1 -1
  494. package/dist/src/services/dev-client/send-message.d.ts +2 -2
  495. package/dist/src/services/dev-client/send-message.d.ts.map +1 -1
  496. package/dist/src/services/dev-client/send-message.js +21 -22
  497. package/dist/src/services/dev-client/send-message.js.map +1 -1
  498. package/dist/src/services/dev-client/session.d.ts +5 -5
  499. package/dist/src/services/dev-client/session.d.ts.map +1 -1
  500. package/dist/src/services/dev-client/session.js +2 -2
  501. package/dist/src/services/dev-client/session.js.map +1 -1
  502. package/dist/src/services/dev-client.d.ts +6 -6
  503. package/dist/src/services/dev-client.d.ts.map +1 -1
  504. package/dist/src/services/dev-client.js +3 -3
  505. package/dist/src/services/dev-client.js.map +1 -1
  506. package/docs/external-agent-protocol.md +37 -34
  507. package/docs/internals/channels.md +15 -12
  508. package/docs/internals/context.md +81 -161
  509. package/docs/internals/message-runtime.md +28 -26
  510. package/docs/public/README.md +22 -20
  511. package/docs/public/auth-and-route-protection.md +15 -12
  512. package/docs/public/channels/README.md +16 -11
  513. package/docs/public/cli-build-and-debugging.md +1 -1
  514. package/docs/public/context-control.md +7 -3
  515. package/docs/public/evals.md +3 -3
  516. package/docs/public/getting-started.md +15 -12
  517. package/docs/public/human-in-the-loop.md +45 -57
  518. package/docs/public/migration-guide.md +71 -0
  519. package/docs/public/project-layout.md +5 -0
  520. package/docs/public/runs-and-streaming.md +32 -25
  521. package/docs/public/schedules.md +4 -4
  522. package/docs/public/session-context.md +131 -15
  523. package/docs/public/skills.md +27 -3
  524. package/docs/public/subagents.md +2 -2
  525. package/docs/public/tools.md +23 -30
  526. package/docs/public/typescript-api.md +16 -12
  527. package/docs/public/vercel-deployment.md +3 -4
  528. package/docs/public/workspace.md +11 -11
  529. package/package.json +18 -11
  530. package/dist/src/channel/emitter-registry.d.ts +0 -34
  531. package/dist/src/channel/emitter-registry.d.ts.map +0 -1
  532. package/dist/src/channel/emitter-registry.js +0 -63
  533. package/dist/src/channel/emitter-registry.js.map +0 -1
  534. package/dist/src/channel/http-emitter.d.ts +0 -16
  535. package/dist/src/channel/http-emitter.d.ts.map +0 -1
  536. package/dist/src/channel/http-emitter.js +0 -22
  537. package/dist/src/channel/http-emitter.js.map +0 -1
  538. package/dist/src/channel/schedule-emitter.d.ts +0 -15
  539. package/dist/src/channel/schedule-emitter.d.ts.map +0 -1
  540. package/dist/src/channel/schedule-emitter.js +0 -21
  541. package/dist/src/channel/schedule-emitter.js.map +0 -1
  542. package/dist/src/channel/slack-emitter.d.ts +0 -56
  543. package/dist/src/channel/slack-emitter.d.ts.map +0 -1
  544. package/dist/src/channel/slack-emitter.js +0 -235
  545. package/dist/src/channel/slack-emitter.js.map +0 -1
  546. package/dist/src/channel/subagent-emitter.d.ts +0 -41
  547. package/dist/src/channel/subagent-emitter.d.ts.map +0 -1
  548. package/dist/src/channel/subagent-emitter.js.map +0 -1
  549. package/dist/src/context/state.d.ts +0 -27
  550. package/dist/src/context/state.d.ts.map +0 -1
  551. package/dist/src/context/state.js +0 -53
  552. package/dist/src/context/state.js.map +0 -1
  553. package/dist/src/internal/message/nitro-route-shims.d.ts +0 -6
  554. package/dist/src/internal/message/nitro-route-shims.d.ts.map +0 -1
  555. package/dist/src/internal/message/nitro-route-shims.js +0 -38
  556. package/dist/src/internal/message/nitro-route-shims.js.map +0 -1
  557. package/dist/src/internal/message/rewrite-generated-imports.d.ts +0 -15
  558. package/dist/src/internal/message/rewrite-generated-imports.d.ts.map +0 -1
  559. package/dist/src/internal/message/rewrite-generated-imports.js +0 -59
  560. package/dist/src/internal/message/rewrite-generated-imports.js.map +0 -1
  561. package/dist/src/internal/nitro/host/channel-url-matcher.d.ts +0 -35
  562. package/dist/src/internal/nitro/host/channel-url-matcher.d.ts.map +0 -1
  563. package/dist/src/internal/nitro/host/channel-url-matcher.js +0 -57
  564. package/dist/src/internal/nitro/host/channel-url-matcher.js.map +0 -1
  565. package/dist/src/internal/nitro/routes/home-page/build-home-page-view-model.d.ts +0 -11
  566. package/dist/src/internal/nitro/routes/home-page/build-home-page-view-model.d.ts.map +0 -1
  567. package/dist/src/internal/nitro/routes/home-page/build-home-page-view-model.js +0 -264
  568. package/dist/src/internal/nitro/routes/home-page/build-home-page-view-model.js.map +0 -1
  569. package/dist/src/internal/nitro/routes/home-page/render-home-page.d.ts +0 -9
  570. package/dist/src/internal/nitro/routes/home-page/render-home-page.d.ts.map +0 -1
  571. package/dist/src/internal/nitro/routes/home-page/render-home-page.js +0 -15
  572. package/dist/src/internal/nitro/routes/home-page/render-home-page.js.map +0 -1
  573. package/dist/src/internal/nitro/routes/index.html +0 -525
  574. package/dist/src/internal/nitro/runtime-configuration.d.ts +0 -16
  575. package/dist/src/internal/nitro/runtime-configuration.d.ts.map +0 -1
  576. package/dist/src/internal/nitro/runtime-configuration.js +0 -23
  577. package/dist/src/internal/nitro/runtime-configuration.js.map +0 -1
  578. package/dist/src/internal/nitro/shims/runtime-configuration-plugin.d.ts +0 -10
  579. package/dist/src/internal/nitro/shims/runtime-configuration-plugin.d.ts.map +0 -1
  580. package/dist/src/internal/nitro/shims/runtime-configuration-plugin.js +0 -17
  581. package/dist/src/internal/nitro/shims/runtime-configuration-plugin.js.map +0 -1
  582. package/dist/src/runtime/tools/execute-tool.d.ts +0 -20
  583. package/dist/src/runtime/tools/execute-tool.d.ts.map +0 -1
  584. package/dist/src/runtime/tools/execute-tool.js +0 -69
  585. package/dist/src/runtime/tools/execute-tool.js.map +0 -1
@@ -1,82 +1,36 @@
1
1
  import { z } from "zod";
2
2
  /**
3
- * One selectable option presented by the `ask_question` framework tool.
3
+ * One selectable option presented to the user in an input request.
4
4
  */
5
- export type RuntimeQuestionOption = z.infer<typeof runtimeQuestionOptionSchema>;
5
+ export type InputOption = z.infer<typeof inputOptionSchema>;
6
6
  /**
7
- * Zod schema for one runtime question option.
7
+ * Zod schema for one input option.
8
8
  *
9
- * Descriptions are included as this schema is used in the `ask_question` tool input,
10
- * which is surfaced directly to the model.
9
+ * Descriptions are included as this schema is used in the `ask_question` tool
10
+ * input, which is surfaced directly to the model.
11
11
  */
12
- export declare const runtimeQuestionOptionSchema: z.ZodObject<{
12
+ export declare const inputOptionSchema: z.ZodObject<{
13
13
  description: z.ZodOptional<z.ZodString>;
14
14
  id: z.ZodString;
15
15
  label: z.ZodString;
16
+ style: z.ZodOptional<z.ZodEnum<{
17
+ default: "default";
18
+ primary: "primary";
19
+ danger: "danger";
20
+ }>>;
16
21
  }, z.core.$strict>;
17
22
  /**
18
- * Runtime-owned tool approval request surfaced to the client.
19
- */
20
- export type RuntimeToolApprovalInputRequest = z.infer<typeof runtimeToolApprovalInputRequestSchema>;
21
- /**
22
- * Zod schema for one runtime tool approval request.
23
- */
24
- export declare const runtimeToolApprovalInputRequestSchema: z.ZodObject<{
25
- action: z.ZodObject<{
26
- callId: z.ZodString;
27
- input: z.ZodType<import("../json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("../json.js").JsonObject, unknown>>;
28
- kind: z.ZodLiteral<"tool-call">;
29
- toolName: z.ZodString;
30
- }, z.core.$strict>;
31
- approvalId: z.ZodString;
32
- kind: z.ZodLiteral<"tool-approval">;
33
- toolName: z.ZodString;
34
- }, z.core.$strict>;
35
- /**
36
- * Runtime-owned question request surfaced to the client.
37
- */
38
- export type RuntimeQuestionInputRequest = z.infer<typeof runtimeQuestionInputRequestSchema>;
39
- /**
40
- * Zod schema for one runtime question request.
23
+ * Unified input request surfaced to the client when the agent needs
24
+ * user input before continuing.
41
25
  *
42
- * Descriptions are included as this schema is used in the `ask_question` tool input,
43
- * which is surfaced directly to the model.
26
+ * Tool approvals and questions share this shape. Approvals are requests
27
+ * with two options (`"approve"` / `"deny"`) and `display: "confirmation"`.
44
28
  */
45
- export declare const runtimeQuestionInputRequestSchema: z.ZodObject<{
46
- action: z.ZodObject<{
47
- callId: z.ZodString;
48
- input: z.ZodType<import("../json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("../json.js").JsonObject, unknown>>;
49
- kind: z.ZodLiteral<"tool-call">;
50
- toolName: z.ZodString;
51
- }, z.core.$strict>;
52
- allowFreeform: z.ZodOptional<z.ZodBoolean>;
53
- kind: z.ZodLiteral<"question">;
54
- options: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
55
- description: z.ZodOptional<z.ZodString>;
56
- id: z.ZodString;
57
- label: z.ZodString;
58
- }, z.core.$strict>>>>;
59
- prompt: z.ZodString;
60
- toolName: z.ZodString;
61
- }, z.core.$strict>;
62
- /**
63
- * Runtime-owned input request surfaced to the client.
64
- */
65
- export type RuntimeInputRequest = RuntimeQuestionInputRequest | RuntimeToolApprovalInputRequest;
29
+ export type InputRequest = z.infer<typeof inputRequestSchema>;
66
30
  /**
67
- * Zod schema for one runtime input request.
31
+ * Zod schema for one input request.
68
32
  */
69
- export declare const runtimeInputRequestSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
70
- action: z.ZodObject<{
71
- callId: z.ZodString;
72
- input: z.ZodType<import("../json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("../json.js").JsonObject, unknown>>;
73
- kind: z.ZodLiteral<"tool-call">;
74
- toolName: z.ZodString;
75
- }, z.core.$strict>;
76
- approvalId: z.ZodString;
77
- kind: z.ZodLiteral<"tool-approval">;
78
- toolName: z.ZodString;
79
- }, z.core.$strict>, z.ZodObject<{
33
+ export declare const inputRequestSchema: z.ZodObject<{
80
34
  action: z.ZodObject<{
81
35
  callId: z.ZodString;
82
36
  input: z.ZodType<import("../json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("../json.js").JsonObject, unknown>>;
@@ -84,71 +38,42 @@ export declare const runtimeInputRequestSchema: z.ZodDiscriminatedUnion<[z.ZodOb
84
38
  toolName: z.ZodString;
85
39
  }, z.core.$strict>;
86
40
  allowFreeform: z.ZodOptional<z.ZodBoolean>;
87
- kind: z.ZodLiteral<"question">;
41
+ display: z.ZodOptional<z.ZodEnum<{
42
+ confirmation: "confirmation";
43
+ select: "select";
44
+ text: "text";
45
+ }>>;
88
46
  options: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodObject<{
89
47
  description: z.ZodOptional<z.ZodString>;
90
48
  id: z.ZodString;
91
49
  label: z.ZodString;
50
+ style: z.ZodOptional<z.ZodEnum<{
51
+ default: "default";
52
+ primary: "primary";
53
+ danger: "danger";
54
+ }>>;
92
55
  }, z.core.$strict>>>>;
93
56
  prompt: z.ZodString;
94
- toolName: z.ZodString;
95
- }, z.core.$strict>], "kind">;
96
- /**
97
- * Runtime-owned tool approval result submitted by the client.
98
- */
99
- export type RuntimeToolApprovalInputResult = z.infer<typeof runtimeToolApprovalInputResultSchema>;
100
- /**
101
- * Zod schema for one runtime tool approval result.
102
- */
103
- export declare const runtimeToolApprovalInputResultSchema: z.ZodObject<{
104
- approvalId: z.ZodString;
105
- approved: z.ZodBoolean;
106
- kind: z.ZodLiteral<"tool-approval-result">;
107
- reason: z.ZodOptional<z.ZodString>;
57
+ requestId: z.ZodString;
108
58
  }, z.core.$strict>;
109
59
  /**
110
- * Runtime-owned question result submitted by the client.
60
+ * Unified input response submitted by the client for a pending request.
111
61
  */
112
- export type RuntimeQuestionInputResult = z.infer<typeof runtimeQuestionInputResultSchema>;
62
+ export type InputResponse = z.infer<typeof inputResponseSchema>;
113
63
  /**
114
- * Zod schema for one runtime question result.
64
+ * Zod schema for one input response.
115
65
  */
116
- export declare const runtimeQuestionInputResultSchema: z.ZodObject<{
117
- callId: z.ZodString;
118
- kind: z.ZodLiteral<"question-result">;
119
- output: z.ZodObject<{
120
- optionId: z.ZodOptional<z.ZodString>;
121
- status: z.ZodUnion<readonly [z.ZodLiteral<"answered">, z.ZodLiteral<"ignored">]>;
122
- text: z.ZodOptional<z.ZodString>;
123
- }, z.core.$strict>;
66
+ export declare const inputResponseSchema: z.ZodObject<{
67
+ optionId: z.ZodOptional<z.ZodString>;
68
+ requestId: z.ZodString;
69
+ text: z.ZodOptional<z.ZodString>;
124
70
  }, z.core.$strict>;
125
71
  /**
126
- * Runtime-owned input result submitted by the client.
127
- */
128
- export type RuntimeInputResult = RuntimeQuestionInputResult | RuntimeToolApprovalInputResult;
129
- /**
130
- * Zod schema for one runtime input result.
131
- */
132
- export declare const runtimeInputResultSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
133
- approvalId: z.ZodString;
134
- approved: z.ZodBoolean;
135
- kind: z.ZodLiteral<"tool-approval-result">;
136
- reason: z.ZodOptional<z.ZodString>;
137
- }, z.core.$strict>, z.ZodObject<{
138
- callId: z.ZodString;
139
- kind: z.ZodLiteral<"question-result">;
140
- output: z.ZodObject<{
141
- optionId: z.ZodOptional<z.ZodString>;
142
- status: z.ZodUnion<readonly [z.ZodLiteral<"answered">, z.ZodLiteral<"ignored">]>;
143
- text: z.ZodOptional<z.ZodString>;
144
- }, z.core.$strict>;
145
- }, z.core.$strict>], "kind">;
146
- /**
147
- * Returns true when a value matches the runtime input-request contract.
72
+ * Returns true when a value matches the input request contract.
148
73
  */
149
- export declare function isRuntimeInputRequest(value: unknown): value is RuntimeInputRequest;
74
+ export declare function isInputRequest(value: unknown): value is InputRequest;
150
75
  /**
151
- * Returns true when a value matches the runtime input-result contract.
76
+ * Returns true when a value matches the input response contract.
152
77
  */
153
- export declare function isRuntimeInputResult(value: unknown): value is RuntimeInputResult;
78
+ export declare function isInputResponse(value: unknown): value is InputResponse;
154
79
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/runtime/input/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF;;;;;GAKG;AACH,eAAO,MAAM,2BAA2B;;;;kBAM7B,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,+BAA+B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qCAAqC,CAAC,CAAC;AAEpG;;GAEG;AACH,eAAO,MAAM,qCAAqC;;;;;;;;;;kBAOvC,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iCAAiC,CAAC,CAAC;AAE5F;;;;;GAKG;AACH,eAAO,MAAM,iCAAiC;;;;;;;;;;;;;;;;kBAkBnC,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,2BAA2B,GAAG,+BAA+B,CAAC;AAEhG;;GAEG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;4BAGpC,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,8BAA8B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oCAAoC,CAAC,CAAC;AAElG;;GAEG;AACH,eAAO,MAAM,oCAAoC;;;;;kBAOtC,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAE1F;;GAEG;AACH,eAAO,MAAM,gCAAgC;;;;;;;;kBAYlC,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,0BAA0B,GAAG,8BAA8B,CAAC;AAE7F;;GAEG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;4BAGnC,CAAC;AAEH;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,mBAAmB,CAElF;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,kBAAkB,CAEhF"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/runtime/input/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAE5D;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;kBAUnB,CAAC;AAEZ;;;;;;GAMG;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE9D;;GAEG;AACH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;kBAqBpB,CAAC;AAEZ;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;kBAMrB,CAAC;AAEZ;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,YAAY,CAEpE;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,aAAa,CAEtE"}
@@ -1,103 +1,65 @@
1
1
  import { z } from "zod";
2
2
  import { runtimeToolCallActionRequestSchema } from "../actions/types.js";
3
3
  /**
4
- * Zod schema for one runtime question option.
4
+ * Zod schema for one input option.
5
5
  *
6
- * Descriptions are included as this schema is used in the `ask_question` tool input,
7
- * which is surfaced directly to the model.
6
+ * Descriptions are included as this schema is used in the `ask_question` tool
7
+ * input, which is surfaced directly to the model.
8
8
  */
9
- export const runtimeQuestionOptionSchema = z
9
+ export const inputOptionSchema = z
10
10
  .object({
11
11
  description: z.string().describe("Optional additional context for this option.").optional(),
12
12
  id: z.string().describe("Stable identifier for the option."),
13
13
  label: z.string().describe("User-facing label for the option."),
14
+ style: z
15
+ .enum(["primary", "danger", "default"])
16
+ .describe("Visual treatment hint for the option.")
17
+ .optional(),
14
18
  })
15
19
  .strict();
16
20
  /**
17
- * Zod schema for one runtime tool approval request.
18
- */
19
- export const runtimeToolApprovalInputRequestSchema = z
20
- .object({
21
- action: runtimeToolCallActionRequestSchema,
22
- approvalId: z.string(),
23
- kind: z.literal("tool-approval"),
24
- toolName: z.string(),
25
- })
26
- .strict();
27
- /**
28
- * Zod schema for one runtime question request.
29
- *
30
- * Descriptions are included as this schema is used in the `ask_question` tool input,
31
- * which is surfaced directly to the model.
21
+ * Zod schema for one input request.
32
22
  */
33
- export const runtimeQuestionInputRequestSchema = z
23
+ export const inputRequestSchema = z
34
24
  .object({
35
25
  action: runtimeToolCallActionRequestSchema,
36
26
  allowFreeform: z
37
27
  .boolean()
38
28
  .describe("Whether the user may answer with freeform text instead of selecting one of the provided options.")
39
29
  .optional(),
40
- kind: z.literal("question"),
30
+ display: z
31
+ .enum(["confirmation", "select", "text"])
32
+ .describe("Rendering hint — the channel uses this to pick a UX treatment.")
33
+ .optional(),
41
34
  options: z
42
- .array(runtimeQuestionOptionSchema)
35
+ .array(inputOptionSchema)
43
36
  .readonly()
44
37
  .describe("Selectable answer options to present to the user.")
45
38
  .optional(),
46
- prompt: z.string().describe("The question to present to the user."),
47
- toolName: z.string(),
39
+ prompt: z.string().describe("The prompt to present to the user."),
40
+ requestId: z.string().describe("Stable identifier for this request."),
48
41
  })
49
42
  .strict();
50
43
  /**
51
- * Zod schema for one runtime input request.
44
+ * Zod schema for one input response.
52
45
  */
53
- export const runtimeInputRequestSchema = z.discriminatedUnion("kind", [
54
- runtimeToolApprovalInputRequestSchema,
55
- runtimeQuestionInputRequestSchema,
56
- ]);
57
- /**
58
- * Zod schema for one runtime tool approval result.
59
- */
60
- export const runtimeToolApprovalInputResultSchema = z
46
+ export const inputResponseSchema = z
61
47
  .object({
62
- approvalId: z.string(),
63
- approved: z.boolean(),
64
- kind: z.literal("tool-approval-result"),
65
- reason: z.string().optional(),
48
+ optionId: z.string().optional(),
49
+ requestId: z.string(),
50
+ text: z.string().optional(),
66
51
  })
67
52
  .strict();
68
53
  /**
69
- * Zod schema for one runtime question result.
70
- */
71
- export const runtimeQuestionInputResultSchema = z
72
- .object({
73
- callId: z.string(),
74
- kind: z.literal("question-result"),
75
- output: z
76
- .object({
77
- optionId: z.string().optional(),
78
- status: z.union([z.literal("answered"), z.literal("ignored")]),
79
- text: z.string().optional(),
80
- })
81
- .strict(),
82
- })
83
- .strict();
84
- /**
85
- * Zod schema for one runtime input result.
86
- */
87
- export const runtimeInputResultSchema = z.discriminatedUnion("kind", [
88
- runtimeToolApprovalInputResultSchema,
89
- runtimeQuestionInputResultSchema,
90
- ]);
91
- /**
92
- * Returns true when a value matches the runtime input-request contract.
54
+ * Returns true when a value matches the input request contract.
93
55
  */
94
- export function isRuntimeInputRequest(value) {
95
- return runtimeInputRequestSchema.safeParse(value).success;
56
+ export function isInputRequest(value) {
57
+ return inputRequestSchema.safeParse(value).success;
96
58
  }
97
59
  /**
98
- * Returns true when a value matches the runtime input-result contract.
60
+ * Returns true when a value matches the input response contract.
99
61
  */
100
- export function isRuntimeInputResult(value) {
101
- return runtimeInputResultSchema.safeParse(value).success;
62
+ export function isInputResponse(value) {
63
+ return inputResponseSchema.safeParse(value).success;
102
64
  }
103
65
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources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AAC;SAC1E,QAAQ,EAAE;IACb,OAAO,EAAE,CAAC;SACP,KAAK,CAAC,iBAAiB,CAAC;SACxB,QAAQ,EAAE;SACV,QAAQ,CAAC,mDAAmD,CAAC;SAC7D,QAAQ,EAAE;IACb,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,oCAAoC,CAAC;IACjE,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,qCAAqC,CAAC;CACtE,CAAC;KACD,MAAM,EAAE,CAAC;AAOZ;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC;KACjC,MAAM,CAAC;IACN,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC5B,CAAC;KACD,MAAM,EAAE,CAAC;AAEZ;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,KAAc;IAC3C,OAAO,kBAAkB,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC;AACrD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,eAAe,CAAC,KAAc;IAC5C,OAAO,mBAAmB,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC;AACtD,CAAC"}
@@ -136,6 +136,14 @@ function collectModuleRefsForManifest(manifest) {
136
136
  sourceId: channel.sourceId,
137
137
  });
138
138
  }
139
+ for (const connection of manifest.connections) {
140
+ moduleSourceRefs.set(connection.sourceId, {
141
+ exportName: connection.exportName,
142
+ kind: "module",
143
+ logicalPath: connection.logicalPath,
144
+ sourceId: connection.sourceId,
145
+ });
146
+ }
139
147
  for (const tool of manifest.tools) {
140
148
  moduleSourceRefs.set(tool.sourceId, {
141
149
  exportName: tool.exportName,
@@ -1 +1 @@
1
- {"version":3,"file":"module-map.js","sourceRoot":"","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C,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE;YAClC,UAAU,EAAE,IAAI,CAAC,UAAU;YAC3B,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,QAAQ,EAAE,IAAI,CAAC,QAAQ;SACxB,CAAC,CAAC;IACL,CAAC;IAED,KAAK,MAAM,OAAO,IAAI,QAAQ,CAAC,SAAS,EAAE,CAAC;QACzC,gBAAgB,CAAC,GAAG,CAAC,OAAO,CAAC,QAAQ,EAAE;YACrC,UAAU,EAAE,OAAO,CAAC,UAAU;YAC9B,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,OAAO,CAAC,WAAW;YAChC,QAAQ,EAAE,OAAO,CAAC,QAAQ;SAC3B,CAAC,CAAC;IACL,CAAC;IAED,OAAO,CAAC,GAAG,gBAAgB,CAAC,MAAM,EAAE,CAAC,CAAC;AACxC,CAAC;AAED,SAAS,sBAAsB,CAAC,KAAc;IAC5C,IAAI,KAAK,YAAY,KAAK,EAAE,CAAC;QAC3B,OAAO,KAAK,CAAC,OAAO,CAAC;IACvB,CAAC;IAED,OAAO,kCAAkC,CAAC;AAC5C,CAAC;AAED,SAAS,yBAAyB,CAAC,aAAqB;IACtD,MAAM,cAAc,GAAG,aAAa,CAAC,UAAU,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;IAE3D,IAAI,cAAc,CAAC,IAAI,CAAC,cAAc,CAAC,EAAE,CAAC;QACxC,OAAO,WAAW,SAAS,CAAC,cAAc,CAAC,EAAE,CAAC;IAChD,CAAC;IAED,IAAI,cAAc,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;QACnC,OAAO,UAAU,SAAS,CAAC,cAAc,CAAC,EAAE,CAAC;IAC/C,CAAC;IAED,OAAO,cAAc,CAAC;AACxB,CAAC"}
@@ -1,10 +1,13 @@
1
- import type { ResolvedPromptLayer } from "../types.js";
1
+ import type { RuntimeSkillSource } from "../skills/source.js";
2
+ import type { ResolvedConnectionDefinition, ResolvedPromptLayer } from "../types.js";
2
3
  import type { WorkspaceSpec } from "../workspace/types.js";
3
4
  /**
4
5
  * Input for composing the base authored prompt layers for one resolved agent.
5
6
  */
6
7
  export interface ComposeRuntimeBasePromptInput {
8
+ connections?: readonly ResolvedConnectionDefinition[];
7
9
  promptLayers: readonly ResolvedPromptLayer[];
10
+ skills?: readonly RuntimeSkillSource[];
8
11
  toolsAvailable?: boolean;
9
12
  workspaceSpec?: WorkspaceSpec;
10
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"compose.d.ts","sourceRoot":"","sources":["../../../../src/runtime/prompt/compose.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAEvD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAK3D;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC5C,YAAY,EAAE,SAAS,mBAAmB,EAAE,CAAC;IAC7C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,6BAA6B,GAAG,SAAS,MAAM,EAAE,CAchG"}
1
+ {"version":3,"file":"compose.d.ts","sourceRoot":"","sources":["../../../../src/runtime/prompt/compose.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,KAAK,EAAE,4BAA4B,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAErF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAM3D;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC5C,WAAW,CAAC,EAAE,SAAS,4BAA4B,EAAE,CAAC;IACtD,YAAY,EAAE,SAAS,mBAAmB,EAAE,CAAC;IAC7C,MAAM,CAAC,EAAE,SAAS,kBAAkB,EAAE,CAAC;IACvC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,6BAA6B,GAAG,SAAS,MAAM,EAAE,CAgBhG"}
@@ -1,5 +1,7 @@
1
+ import { formatAvailableSkillsSection } from "../../execution/skills/instructions.js";
1
2
  import { createWorkspacePromptSection } from "../workspace/spec.js";
2
- const PARALLEL_ACTION_INSTRUCTION = "Tool execution\nIf you call multiple tools or subagents in one response, Ash executes them in parallel. Only batch work that is independent and does not rely on another call in the same response.";
3
+ import { formatConnectionsSection } from "./connections.js";
4
+ const PARALLEL_ACTION_INSTRUCTION = "Tool execution\nA single tool or subagent call runs as one serial action. If you call multiple independent tools or subagents in one response, Ash treats that batch as parallel work. Only batch work that is independent and does not rely on another call in the same response.";
3
5
  /**
4
6
  * Composes the authored base prompt from resolved `system`
5
7
  * without flattening skills into always-on instructions.
@@ -15,6 +17,8 @@ export function composeRuntimeBasePrompt(input) {
15
17
  }),
16
18
  ...createWorkspacePromptBlocks(input.workspaceSpec),
17
19
  ...(input.toolsAvailable ? [PARALLEL_ACTION_INSTRUCTION] : []),
20
+ ...createConnectionsPromptBlocks(input.connections),
21
+ ...createSkillsPromptBlocks(input.skills),
18
22
  ];
19
23
  }
20
24
  function normalizePromptLayerMarkdown(markdown) {
@@ -28,4 +32,17 @@ function createWorkspacePromptBlocks(workspaceSpec) {
28
32
  const workspaceSection = createWorkspacePromptSection(workspaceSpec);
29
33
  return workspaceSection === undefined ? [] : [workspaceSection];
30
34
  }
35
+ function createConnectionsPromptBlocks(connections) {
36
+ if (!connections || connections.length === 0)
37
+ return [];
38
+ return [formatConnectionsSection(connections)];
39
+ }
40
+ function createSkillsPromptBlocks(skills) {
41
+ if (!skills || skills.length === 0)
42
+ return [];
43
+ const section = formatAvailableSkillsSection(skills);
44
+ if (section === null)
45
+ return [];
46
+ return [section];
47
+ }
31
48
  //# sourceMappingUR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AO,EAAE,CAAC;IACZ,CAAC;IAED,MAAM,gBAAgB,GAAG,4BAA4B,CAAC,aAAa,CAAC,CAAC;IACrE,OAAO,gBAAgB,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,CAAC;AAClE,CAAC;AAED,SAAS,6BAA6B,CACpC,WAAgE;IAEhE,IAAI,CAAC,WAAW,IAAI,WAAW,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IACxD,OAAO,CAAC,wBAAwB,CAAC,WAAW,CAAC,CAAC,CAAC;AACjD,CAAC;AAED,SAAS,wBAAwB,CAC/B,MAAiD;IAEjD,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAC9C,MAAM,OAAO,GAAG,4BAA4B,CAAC,MAAM,CAAC,CAAC;IACrD,IAAI,OAAO,KAAK,IAAI;QAAE,OAAO,EAAE,CAAC;IAChC,OAAO,CAAC,OAAO,CAAC,CAAC;AACnB,CAAC"}
@@ -0,0 +1,10 @@
1
+ import type { ResolvedConnectionDefinition } from "../types.js";
2
+ /**
3
+ * Formats the "Connections" system prompt section listing all available
4
+ * connections and their descriptions.
5
+ *
6
+ * Called at graph resolution time so the section is part of the turn
7
+ * agent's static instructions rather than injected per-step.
8
+ */
9
+ export declare function formatConnectionsSection(connections: readonly ResolvedConnectionDefinition[]): string;
10
+ //# sourceMappingURL=connections.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"connections.d.ts","sourceRoot":"","sources":["../../../../src/runtime/prompt/connections.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,aAAa,CAAC;AAKhE;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,WAAW,EAAE,SAAS,4BAA4B,EAAE,GACnD,MAAM,CAaR"}
@@ -0,0 +1,25 @@
1
+ import { CONNECTION_EXECUTE_TOOL_DEFINITION } from "../framework-tools/connection-execute.js";
2
+ import { CONNECTION_SEARCH_TOOL_DEFINITION } from "../framework-tools/connection-search.js";
3
+ const SEARCH = CONNECTION_SEARCH_TOOL_DEFINITION.name;
4
+ const EXECUTE = CONNECTION_EXECUTE_TOOL_DEFINITION.name;
5
+ /**
6
+ * Formats the "Connections" system prompt section listing all available
7
+ * connections and their descriptions.
8
+ *
9
+ * Called at graph resolution time so the section is part of the turn
10
+ * agent's static instructions rather than injected per-step.
11
+ */
12
+ export function formatConnectionsSection(connections) {
13
+ const connectionList = connections.map((c) => `- ${c.connectionName}: ${c.description}`);
14
+ return [
15
+ "## Connections",
16
+ "",
17
+ `You have access to connections through the ${SEARCH} and ${EXECUTE} tools.`,
18
+ "",
19
+ "Available connections:",
20
+ ...connectionList,
21
+ "",
22
+ `Always call ${SEARCH} before ${EXECUTE}. Copy identifiers from the search result verbatim and never guess tool names.`,
23
+ ].join("\n");
24
+ }
25
+ //# sourceMappingURL=connections.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"connections.js","sourceRoot":"","sources":["../../../../src/runtime/prompt/connections.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kCAAkC,EAAE,MAAM,0CAA0C,CAAC;AAC9F,OAAO,EAAE,iCAAiC,EAAE,MAAM,yCAAyC,CAAC;AAG5F,MAAM,MAAM,GAAG,iCAAiC,CAAC,IAAI,CAAC;AACtD,MAAM,OAAO,GAAG,kCAAkC,CAAC,IAAI,CAAC;AAExD;;;;;;GAMG;AACH,MAAM,UAAU,wBAAwB,CACtC,WAAoD;IAEpD,MAAM,cAAc,GAAG,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,KAAK,CAAC,CAAC,cAAc,KAAK,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC;IAEzF,OAAO;QACL,gBAAgB;QAChB,EAAE;QACF,8CAA8C,MAAM,QAAQ,OAAO,SAAS;QAC5E,EAAE;QACF,wBAAwB;QACxB,GAAG,cAAc;QACjB,EAAE;QACF,eAAe,MAAM,WAAW,OAAO,gFAAgF;KACxH,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"resolve-agent-graph.d.ts","sourceRoot":"","sources":["../../../src/runtime/resolve-agent-graph.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EAGtB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAQnE,OAAO,EAAE,KAAK,wBAAwB,EAA+B,MAAM,YAAY,CAAC;AAaxF;;;GAGG;AACH,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,EAAE,qBAAqB,CAAC;IAChC,SAAS,EAAE,iBAAiB,CAAC;CAC9B;AAED;;;GAGG;AACH,qBAAa,6BAA8B,SAAQ,KAAK;IACtD,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;gBAGzB,OAAO,EAAE,MAAM,EACf,KAAK,GAAE;QACL,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;KACd;CAiBT;AAED;;;GAGG;AACH,wBAAsB,wBAAwB,CAC5C,KAAK,EAAE,6BAA6B,GACnC,OAAO,CAAC,wBAAwB,CAAC,CAoBnC"}
1
+ {"version":3,"file":"resolve-agent-graph.d.ts","sourceRoot":"","sources":["../../../src/runtime/resolve-agent-graph.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,qBAAqB,EAGtB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AASnE,OAAO,EAAE,KAAK,wBAAwB,EAA+B,MAAM,YAAY,CAAC;AAexF;;;GAGG;AACH,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,EAAE,qBAAqB,CAAC;IAChC,SAAS,EAAE,iBAAiB,CAAC;CAC9B;AAED;;;GAGG;AACH,qBAAa,6BAA8B,SAAQ,KAAK;IACtD,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;gBAGzB,OAAO,EAAE,MAAM,EACf,KAAK,GAAE;QACL,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;KACd;CAiBT;AAED;;;GAGG;AACH,wBAAsB,wBAAwB,CAC5C,KAAK,EAAE,6BAA6B,GACnC,OAAO,CAAC,wBAAwB,CAAC,CAoBnC"}
@@ -2,11 +2,12 @@ import { ROOT_COMPILED_AGENT_NODE_ID } from "../compiler/manifest.js";
2
2
  import { createResolvedRuntimeTurnAgent } from "./agent/bootstrap.js";
3
3
  import { getAllFrameworkChannelNames, getFrameworkChannelDefinitions, } from "./framework-channels/index.js";
4
4
  import { createDefaultSandboxDefinition } from "./framework-sandboxes/default.js";
5
+ import { CONNECTION_SEARCH_TOOL_DEFINITION } from "./framework-tools/connection-search.js";
5
6
  import { getAllFrameworkToolNames, getFrameworkToolDefinitions } from "./framework-tools/index.js";
6
7
  import { ROOT_RUNTIME_AGENT_SELECTOR } from "./graph.js";
7
8
  import { resolveAgent } from "./resolve-agent.js";
8
9
  import { createRuntimeSandboxRegistry } from "./sandboxes/registry.js";
9
- import { ACTIVATE_SKILL_TOOL_NAME } from "./skills/fragment-context.js";
10
+ import { LOAD_SKILL_TOOL_NAME } from "./skills/fragment-context.js";
10
11
  import { createRuntimeSubagentRegistry } from "./subagents/registry.js";
11
12
  import { createRuntimeToolRegistry } from "./tools/registry.js";
12
13
  /**
@@ -67,11 +68,16 @@ async function resolveRuntimeAgentNode(input) {
67
68
  moduleMap: input.moduleMap,
68
69
  nodeId: input.nodeId,
69
70
  });
71
+ const hasConnections = agent.connections.length > 0;
70
72
  const hasSkills = agent.skills.length > 0;
71
- const frameworkTools = getFrameworkToolDefinitions({
73
+ const baseFrameworkTools = getFrameworkToolDefinitions({
74
+ hasConnections,
72
75
  hasSkills,
73
76
  isRoot: input.nodeId === ROOT_COMPILED_AGENT_NODE_ID,
74
77
  });
78
+ const frameworkTools = hasConnections
79
+ ? enrichConnectionSearchDescription(baseFrameworkTools, agent.connections)
80
+ : baseFrameworkTools;
75
81
  const frameworkToolNames = new Set(frameworkTools.map((t) => t.name));
76
82
  const allFrameworkToolNames = getAllFrameworkToolNames();
77
83
  // Authored tools whose filename slug matches a framework default replace
@@ -95,10 +101,9 @@ async function resolveRuntimeAgentNode(input) {
95
101
  const toolRegistry = await createRuntimeToolRegistry({
96
102
  tools: [...activeFrameworkTools, ...agent.tools],
97
103
  }, {
98
- reservedToolNames: frameworkToolNames.has(ACTIVATE_SKILL_TOOL_NAME) ||
99
- authoredToolNames.has(ACTIVATE_SKILL_TOOL_NAME)
104
+ reservedToolNames: frameworkToolNames.has(LOAD_SKILL_TOOL_NAME) || authoredToolNames.has(LOAD_SKILL_TOOL_NAME)
100
105
  ? []
101
- : [ACTIVATE_SKILL_TOOL_NAME],
106
+ : [LOAD_SKILL_TOOL_NAME],
102
107
  });
103
108
  // Channel override + disable resolution. The compiled manifest's
104
109
  // channels list contains both authored channel entries and disable
@@ -115,7 +120,7 @@ async function resolveRuntimeAgentNode(input) {
115
120
  const allFrameworkChannelNames = getAllFrameworkChannelNames();
116
121
  for (const disabledName of agent.disabledFrameworkChannels) {
117
122
  if (!allFrameworkChannelNames.has(disabledName)) {
118
- throw new ResolveRuntimeAgentGraphError(`agent/channels/${disabledName}.ts exports disableChannel() but "${disabledName}" is not a framework channel. ` +
123
+ throw new ResolveRuntimeAgentGraphError(`agent/channels/${disabledName}.ts exports disableRoute() but "${disabledName}" is not a framework channel. ` +
119
124
  `Rename the file to one of: ${[...allFrameworkChannelNames].sort().join(", ")}.`, {
120
125
  selector,
121
126
  sourceId: input.sourceId,
@@ -134,7 +139,7 @@ async function resolveRuntimeAgentNode(input) {
134
139
  });
135
140
  const subagentRegistry = createRuntimeSubagentRegistry({
136
141
  reservedToolNames: [
137
- ACTIVATE_SKILL_TOOL_NAME,
142
+ LOAD_SKILL_TOOL_NAME,
138
143
  ...toolRegistry.preparedTools.map((tool) => tool.name),
139
144
  ],
140
145
  subagents: await resolveRuntimeSubagents({
@@ -235,4 +240,21 @@ function collectInheritedPromptLayers(promptLayers) {
235
240
  ...promptLayer,
236
241
  }));
237
242
  }
243
+ const CONNECTION_SEARCH_NAME = CONNECTION_SEARCH_TOOL_DEFINITION.name;
244
+ /**
245
+ * Returns a copy of `tools` where the `connection_search` tool's description
246
+ * is enriched with the list of available connection names so the model sees
247
+ * them directly in the tool definition.
248
+ */
249
+ function enrichConnectionSearchDescription(tools, connections) {
250
+ const names = connections.map((c) => c.connectionName).join(", ");
251
+ return tools.map((tool) => {
252
+ if (tool.name !== CONNECTION_SEARCH_NAME)
253
+ return tool;
254
+ return {
255
+ ...tool,
256
+ description: `${tool.description} Available connections: ${names}.`,
257
+ };
258
+ });
259
+ }
238
260
  //# sourceMappingURL=resolve-agent-graph.js.map