eve 0.44.4 → 0.45.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (827) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/README.md +13 -12
  3. package/dist/src/acp/adapter.d.ts +1 -1
  4. package/dist/src/approval/definition.d.ts +84 -0
  5. package/dist/src/approval/definition.js +1 -0
  6. package/dist/src/{runtime/governance → channel}/auth/http-basic.d.ts +1 -1
  7. package/dist/src/{runtime/governance → channel}/auth/jwt-ecdsa.d.ts +1 -1
  8. package/dist/src/channel/auth/jwt-ecdsa.js +1 -0
  9. package/dist/src/{runtime/governance → channel}/auth/jwt-hmac.d.ts +1 -1
  10. package/dist/src/channel/auth/jwt-hmac.js +1 -0
  11. package/dist/src/{runtime/governance → channel}/auth/oidc.d.ts +1 -1
  12. package/dist/src/channel/auth/oidc.js +1 -0
  13. package/dist/src/{runtime/governance → channel}/auth/token-claims.d.ts +1 -1
  14. package/dist/src/{runtime/governance → channel}/auth/types.d.ts +1 -1
  15. package/dist/src/{runtime/governance → channel}/auth/vercel-oidc-project.d.ts +1 -1
  16. package/dist/src/channel/channel-operations.d.ts +1 -1
  17. package/dist/src/channel/channel-operations.js +1 -1
  18. package/dist/src/channel/instrumentation.d.ts +1 -0
  19. package/dist/src/channel/instrumentation.js +1 -1
  20. package/dist/src/channel/resolve-text.d.ts +1 -1
  21. package/dist/src/channel/routes.d.ts +1 -1
  22. package/dist/src/channel/session.d.ts +1 -1
  23. package/dist/src/channel/session.js +1 -1
  24. package/dist/src/channel/types.d.ts +2 -2
  25. package/dist/src/chunks/{use-eve-agent-BtsOXv3s.js → use-eve-agent-BH7Z6SDu.js} +397 -106
  26. package/dist/src/chunks/{use-eve-agent-BJwaMe5k.js → use-eve-agent-DI2j5XK8.js} +397 -106
  27. package/dist/src/cli/banner.js +1 -1
  28. package/dist/src/cli/commands/agent-instructions.js +2 -2
  29. package/dist/src/cli/commands/channel-add-conflicts.js +1 -1
  30. package/dist/src/cli/commands/extension-build.js +1 -1
  31. package/dist/src/cli/commands/extension-init.js +1 -1
  32. package/dist/src/cli/commands/info.js +1 -1
  33. package/dist/src/cli/commands/init.js +1 -1
  34. package/dist/src/cli/commands/integration-connect.d.ts +2 -0
  35. package/dist/src/cli/commands/integration-connect.js +1 -1
  36. package/dist/src/cli/commands/register-integration-commands.js +1 -1
  37. package/dist/src/cli/commands/trace.js +1 -1
  38. package/dist/src/cli/dev/tui/remote-auth.js +1 -1
  39. package/dist/src/cli/dev/tui/setup-selection-input.d.ts +3 -1
  40. package/dist/src/cli/dev/tui/setup-selection-input.js +2 -2
  41. package/dist/src/cli/dev/tui/terminal-renderer.js +2 -2
  42. package/dist/src/cli/dev/tui/traces/trace-conversation.d.ts +1 -1
  43. package/dist/src/cli/dev/tui/traces/trace-conversation.js +1 -1
  44. package/dist/src/cli/dev/tui/traces/trace-viewer-state.js +1 -1
  45. package/dist/src/cli/invoke/result.d.ts +1 -1
  46. package/dist/src/cli/ui/live-row.js +1 -1
  47. package/dist/src/cli/ui/output.js +1 -1
  48. package/dist/src/client/agent-info-schema.d.ts +1946 -302
  49. package/dist/src/client/agent-info-schema.js +1 -1
  50. package/dist/src/client/client.js +1 -1
  51. package/dist/src/client/eve-agent-store.d.ts +6 -5
  52. package/dist/src/client/eve-agent-store.js +1 -1
  53. package/dist/src/client/health-response-error.d.ts +5 -0
  54. package/dist/src/client/health-response-error.js +1 -0
  55. package/dist/src/client/health-schema.d.ts +7 -0
  56. package/dist/src/client/health-schema.js +1 -0
  57. package/dist/src/client/index.d.ts +6 -3
  58. package/dist/src/client/index.js +1 -1
  59. package/dist/src/client/message-action-parts.d.ts +2 -2
  60. package/dist/src/client/message-reducer-types.d.ts +1 -1
  61. package/dist/src/client/reducer.d.ts +1 -1
  62. package/dist/src/client/session-utils.d.ts +1 -1
  63. package/dist/src/client/session.d.ts +1 -1
  64. package/dist/src/client/session.js +1 -1
  65. package/dist/src/client/types.d.ts +3 -7
  66. package/dist/src/compiler/artifacts.d.ts +37 -11
  67. package/dist/src/compiler/artifacts.js +1 -1
  68. package/dist/src/compiler/channel-route-plan.d.ts +10 -0
  69. package/dist/src/compiler/channel-route-plan.js +1 -0
  70. package/dist/src/compiler/compile-agent.d.ts +2 -2
  71. package/dist/src/compiler/compile-agent.js +2 -2
  72. package/dist/src/compiler/compile-from-memory.d.ts +13 -52
  73. package/dist/src/compiler/compile-from-memory.js +1 -1
  74. package/dist/src/compiler/diagnostics.d.ts +38 -0
  75. package/dist/src/compiler/diagnostics.js +1 -0
  76. package/dist/src/compiler/extension-compatibility.d.ts +14 -11
  77. package/dist/src/compiler/extension-compatibility.js +1 -1
  78. package/dist/src/compiler/load-binding-namespace.d.ts +9 -0
  79. package/dist/src/compiler/load-binding-namespace.js +1 -0
  80. package/dist/src/compiler/manifest.d.ts +182 -51
  81. package/dist/src/compiler/manifest.js +1 -1
  82. package/dist/src/compiler/module-map.d.ts +12 -30
  83. package/dist/src/compiler/module-map.js +3 -3
  84. package/dist/src/compiler/node-source-state.d.ts +24 -0
  85. package/dist/src/compiler/node-source-state.js +1 -0
  86. package/dist/src/compiler/normalize-agent-config.d.ts +5 -1
  87. package/dist/src/compiler/normalize-agent-config.js +1 -1
  88. package/dist/src/compiler/normalize-channel.d.ts +8 -2
  89. package/dist/src/compiler/normalize-channel.js +1 -1
  90. package/dist/src/compiler/normalize-connection.d.ts +1 -1
  91. package/dist/src/compiler/normalize-connection.js +1 -1
  92. package/dist/src/compiler/normalize-helpers.d.ts +14 -4
  93. package/dist/src/compiler/normalize-helpers.js +1 -1
  94. package/dist/src/compiler/normalize-hook.d.ts +4 -11
  95. package/dist/src/compiler/normalize-hook.js +1 -1
  96. package/dist/src/compiler/normalize-instructions.d.ts +3 -3
  97. package/dist/src/compiler/normalize-instructions.js +1 -1
  98. package/dist/src/compiler/normalize-manifest-helpers.d.ts +29 -0
  99. package/dist/src/compiler/normalize-manifest-helpers.js +1 -0
  100. package/dist/src/compiler/normalize-manifest.d.ts +8 -4
  101. package/dist/src/compiler/normalize-manifest.js +1 -1
  102. package/dist/src/compiler/normalize-memory.d.ts +5 -0
  103. package/dist/src/compiler/normalize-memory.js +1 -0
  104. package/dist/src/compiler/normalize-sandbox.d.ts +1 -1
  105. package/dist/src/compiler/normalize-sandbox.js +1 -1
  106. package/dist/src/compiler/normalize-schedule.d.ts +2 -2
  107. package/dist/src/compiler/normalize-schedule.js +1 -1
  108. package/dist/src/compiler/normalize-skill.d.ts +2 -2
  109. package/dist/src/compiler/normalize-skill.js +1 -1
  110. package/dist/src/compiler/normalize-subagent.d.ts +21 -39
  111. package/dist/src/compiler/normalize-subagent.js +1 -1
  112. package/dist/src/compiler/normalize-tool.d.ts +2 -1
  113. package/dist/src/compiler/normalize-tool.js +1 -1
  114. package/dist/src/compiler/project-sources.d.ts +70 -0
  115. package/dist/src/compiler/project-sources.js +1 -0
  116. package/dist/src/compiler/remote-agent-node.d.ts +8 -0
  117. package/dist/src/compiler/remote-agent-node.js +1 -1
  118. package/dist/src/compiler/source-graph.d.ts +155 -0
  119. package/dist/src/compiler/source-graph.js +1 -0
  120. package/dist/src/compiler/validate-artifact.d.ts +17 -0
  121. package/dist/src/compiler/validate-artifact.js +1 -0
  122. package/dist/src/compiler/workspace-resources.js +1 -1
  123. package/dist/src/connections/errors.d.ts +125 -0
  124. package/dist/src/connections/errors.js +1 -0
  125. package/dist/src/context/build-base-tool-context.d.ts +2 -2
  126. package/dist/src/context/build-callback-context.d.ts +1 -1
  127. package/dist/src/context/build-dynamic-tools.js +1 -1
  128. package/dist/src/context/dynamic-instruction-lifecycle.js +1 -1
  129. package/dist/src/context/dynamic-resolve-context.d.ts +1 -1
  130. package/dist/src/context/dynamic-skill-lifecycle.js +1 -1
  131. package/dist/src/context/dynamic-subagent-lifecycle.d.ts +0 -2
  132. package/dist/src/context/dynamic-subagent-lifecycle.js +1 -1
  133. package/dist/src/context/dynamic-tool-lifecycle.d.ts +10 -3
  134. package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
  135. package/dist/src/context/key-names.d.ts +12 -0
  136. package/dist/src/context/key-names.js +1 -0
  137. package/dist/src/context/keys.d.ts +33 -1
  138. package/dist/src/context/keys.js +1 -1
  139. package/dist/src/context/memory-event-lifecycle.d.ts +13 -0
  140. package/dist/src/context/memory-event-lifecycle.js +1 -0
  141. package/dist/src/context/memory-lifecycle.d.ts +52 -0
  142. package/dist/src/context/memory-lifecycle.js +1 -0
  143. package/dist/src/context/memory-tools.d.ts +12 -0
  144. package/dist/src/context/memory-tools.js +1 -0
  145. package/dist/src/context/providers/connection-key.d.ts +1 -1
  146. package/dist/src/context/providers/connection.d.ts +1 -1
  147. package/dist/src/context/session-context.d.ts +32 -0
  148. package/dist/src/discover/discover-agent.d.ts +0 -13
  149. package/dist/src/discover/discover-agent.js +1 -1
  150. package/dist/src/discover/discover-subagent.js +1 -1
  151. package/dist/src/discover/extensions.d.ts +6 -6
  152. package/dist/src/discover/extensions.js +1 -1
  153. package/dist/src/discover/filesystem.d.ts +2 -2
  154. package/dist/src/discover/filesystem.js +1 -1
  155. package/dist/src/discover/manifest.d.ts +9 -1
  156. package/dist/src/discover/manifest.js +1 -1
  157. package/dist/src/discover/memory.d.ts +14 -0
  158. package/dist/src/discover/memory.js +1 -0
  159. package/dist/src/discover/project.js +1 -1
  160. package/dist/src/dynamic/definition.d.ts +117 -0
  161. package/dist/src/dynamic/definition.js +1 -0
  162. package/dist/src/evals/autoevals-client.js +1 -1
  163. package/dist/src/evals/cli/eval.js +1 -1
  164. package/dist/src/evals/index.d.ts +1 -1
  165. package/dist/src/evals/match.d.ts +1 -1
  166. package/dist/src/evals/runner/reporters/console.js +1 -1
  167. package/dist/src/evals/session.d.ts +1 -1
  168. package/dist/src/evals/target.js +1 -1
  169. package/dist/src/evals/types.d.ts +1 -1
  170. package/dist/src/eve-channel/index.d.ts +12 -0
  171. package/dist/src/eve-channel/index.js +1 -0
  172. package/dist/src/eve-channel/request.d.ts +49 -0
  173. package/dist/src/eve-channel/request.js +3 -0
  174. package/dist/src/eve-channel/support.d.ts +34 -0
  175. package/dist/src/eve-channel/support.js +1 -0
  176. package/dist/src/eve-channel/types.d.ts +128 -0
  177. package/dist/src/eve-channel/types.js +1 -0
  178. package/dist/src/execution/agent-handle-dispatch.d.ts +1 -1
  179. package/dist/src/execution/agent-handle-dispatch.js +1 -1
  180. package/dist/src/execution/authorization-callback-match.d.ts +1 -1
  181. package/dist/src/execution/cancel-descendant-turns-step.js +1 -1
  182. package/dist/src/execution/compaction.js +1 -1
  183. package/dist/src/execution/connection-auth-tool-result.d.ts +1 -1
  184. package/dist/src/{runtime → execution}/connections/callback-route.d.ts +2 -20
  185. package/dist/src/execution/connections/callback-route.js +1 -0
  186. package/dist/src/execution/create-session-step.js +1 -1
  187. package/dist/src/execution/delegated-parent-notification.d.ts +2 -2
  188. package/dist/src/execution/delegated-parent-notification.js +1 -1
  189. package/dist/src/execution/delegated-parent-result.d.ts +1 -1
  190. package/dist/src/execution/delegated-parent-result.js +1 -1
  191. package/dist/src/execution/delegation-tool.d.ts +1 -1
  192. package/dist/src/execution/delegation-tool.js +1 -1
  193. package/dist/src/execution/dispatch-action-failures.d.ts +1 -1
  194. package/dist/src/execution/dispatch-runtime-actions-shared.d.ts +1 -2
  195. package/dist/src/execution/dispatch-runtime-actions-shared.js +1 -1
  196. package/dist/src/execution/dispatch-runtime-actions-step.js +1 -1
  197. package/dist/src/execution/dispatch-workflow-runtime-actions-step.d.ts +1 -1
  198. package/dist/src/execution/durable-session-migrations/turn-workflow.d.ts +1 -1
  199. package/dist/src/execution/durable-session-store.js +1 -1
  200. package/dist/src/execution/effective-output-schema.d.ts +2 -1
  201. package/dist/src/execution/eve-workflow-attributes.d.ts +6 -0
  202. package/dist/src/execution/eve-workflow-attributes.js +1 -1
  203. package/dist/src/execution/forward-turn-cancellation-step.js +1 -1
  204. package/dist/src/execution/history-view.d.ts +2 -2
  205. package/dist/src/execution/history-view.js +1 -1
  206. package/dist/src/execution/node-step.js +1 -1
  207. package/dist/src/execution/remote-agent-dispatch.d.ts +10 -8
  208. package/dist/src/execution/remote-agent-dispatch.js +1 -1
  209. package/dist/src/execution/runtime-context.js +1 -1
  210. package/dist/src/execution/sandbox/{bash-tool.d.ts → bash.d.ts} +2 -2
  211. package/dist/src/execution/sandbox/bindings/vercel-credentials.js +1 -1
  212. package/dist/src/execution/sandbox/glob-tool.js +1 -1
  213. package/dist/src/execution/sandbox/grep-tool.js +1 -1
  214. package/dist/src/execution/sandbox/{read-file-tool.d.ts → read-file.d.ts} +2 -2
  215. package/dist/src/execution/sandbox/{read-file-tool.js → read-file.js} +1 -1
  216. package/dist/src/execution/sandbox/{write-file-tool.d.ts → write-file.d.ts} +2 -2
  217. package/dist/src/execution/sandbox/write-file.js +1 -0
  218. package/dist/src/execution/session-callback-route.d.ts +2 -0
  219. package/dist/src/execution/session-callback-route.js +1 -0
  220. package/dist/src/execution/session-callback-step.js +1 -1
  221. package/dist/src/execution/session-timeout-steps.js +1 -1
  222. package/dist/src/execution/settle-cancelled-turn-step.js +1 -1
  223. package/dist/src/execution/subagent-adapter.js +1 -1
  224. package/dist/src/execution/subagent-hitl-proxy.d.ts +1 -1
  225. package/dist/src/execution/subagent-invocation.d.ts +0 -3
  226. package/dist/src/execution/subagent-invocation.js +1 -1
  227. package/dist/src/execution/subagent-start-local.d.ts +1 -2
  228. package/dist/src/execution/subagent-start-local.js +1 -1
  229. package/dist/src/execution/subagent-start-remote.d.ts +1 -2
  230. package/dist/src/execution/subagent-start-remote.js +1 -1
  231. package/dist/src/execution/subagent-tool.d.ts +4 -8
  232. package/dist/src/execution/subagent-tool.js +1 -1
  233. package/dist/src/execution/subagent-usage-span.d.ts +1 -1
  234. package/dist/src/execution/task-input-response-route.d.ts +2 -0
  235. package/dist/src/execution/task-input-response-route.js +1 -0
  236. package/dist/src/execution/tasks/child/instructions.js +1 -1
  237. package/dist/src/execution/tasks/child/update.d.ts +1 -1
  238. package/dist/src/execution/tasks/child/update.js +1 -1
  239. package/dist/src/execution/tasks/parent/continuation-dispatch.d.ts +1 -1
  240. package/dist/src/execution/tasks/parent/control-shared.d.ts +1 -1
  241. package/dist/src/execution/tasks/parent/delegate.d.ts +2 -2
  242. package/dist/src/execution/tasks/parent/delegate.js +1 -1
  243. package/dist/src/execution/tasks/parent/dispatch-task-step.js +1 -1
  244. package/dist/src/execution/tasks/parent/dispatch.d.ts +3 -1
  245. package/dist/src/execution/tasks/parent/dispatch.js +1 -1
  246. package/dist/src/execution/tasks/parent/hitl-proxy-steps.js +1 -1
  247. package/dist/src/execution/tasks/parent/tool-execution.js +1 -1
  248. package/dist/src/execution/terminate-child-sessions-step.d.ts +4 -5
  249. package/dist/src/execution/terminate-child-sessions-step.js +1 -1
  250. package/dist/src/execution/tool-auth.d.ts +5 -6
  251. package/dist/src/execution/tool-auth.js +1 -1
  252. package/dist/src/execution/tools/connection-search.d.ts +1 -0
  253. package/dist/src/execution/tools/connection-search.js +2 -0
  254. package/dist/src/{runtime/framework-tools → execution/tools}/file-state.d.ts +2 -2
  255. package/dist/src/execution/tools/load-skill.d.ts +6 -0
  256. package/dist/src/execution/tools/load-skill.js +1 -0
  257. package/dist/src/{runtime/framework-tools → execution/tools}/subagent/local.d.ts +7 -7
  258. package/dist/src/execution/tools/subagent/local.js +1 -0
  259. package/dist/src/{runtime/framework-tools → execution/tools}/subagent/remote.d.ts +5 -5
  260. package/dist/src/execution/tools/subagent/remote.js +1 -0
  261. package/dist/src/execution/tools/tasks.d.ts +18 -0
  262. package/dist/src/execution/tools/tasks.js +1 -0
  263. package/dist/src/{runtime/framework-tools → execution/tools}/todo.d.ts +0 -2
  264. package/dist/src/{runtime/framework-tools → execution/tools}/todo.js +1 -2
  265. package/dist/src/execution/turn-control-protocol.js +1 -1
  266. package/dist/src/execution/web-fetch/request.js +1 -1
  267. package/dist/src/execution/wire/session-inbox-resume.js +1 -1
  268. package/dist/src/execution/wire/session-inbox-wire.v1.js +1 -1
  269. package/dist/src/execution/workflow-entry.js +1 -1
  270. package/dist/src/execution/workflow-runtime.js +1 -1
  271. package/dist/src/execution/workflow-steps.d.ts +1 -3
  272. package/dist/src/execution/workflow-steps.js +1 -1
  273. package/dist/src/execution/workflow-trace-context.js +1 -1
  274. package/dist/src/framework/host-inventory.d.ts +8 -0
  275. package/dist/src/framework/host-inventory.js +1 -0
  276. package/dist/src/framework/sources/modules/agent.d.ts +4 -0
  277. package/dist/src/framework/sources/modules/agent.js +1 -0
  278. package/dist/src/framework/sources/modules/eve-channel.d.ts +1 -0
  279. package/dist/src/framework/sources/modules/eve-channel.js +1 -0
  280. package/dist/src/framework/sources/modules/home-channel.d.ts +2 -0
  281. package/dist/src/framework/sources/modules/home-channel.js +1 -0
  282. package/dist/src/framework/sources/modules/memory-wrapper.d.ts +2 -0
  283. package/dist/src/framework/sources/modules/memory-wrapper.js +1 -0
  284. package/dist/src/framework/sources/modules/sandbox.d.ts +2 -0
  285. package/dist/src/framework/sources/modules/sandbox.js +1 -0
  286. package/dist/src/framework/sources/registry.d.ts +6 -0
  287. package/dist/src/framework/sources/registry.js +1 -0
  288. package/dist/src/harness/action-result-helpers.d.ts +1 -1
  289. package/dist/src/harness/advertised-tools.js +1 -1
  290. package/dist/src/harness/authorization.d.ts +3 -3
  291. package/dist/src/harness/background-tools.d.ts +2 -2
  292. package/dist/src/harness/channel-delivery-instrumentation.js +1 -1
  293. package/dist/src/harness/compaction.js +1 -1
  294. package/dist/src/harness/emission.d.ts +1 -1
  295. package/dist/src/harness/emission.js +1 -1
  296. package/dist/src/harness/execute-tool.d.ts +3 -3
  297. package/dist/src/{runtime/framework-tools → harness}/final-output.d.ts +1 -1
  298. package/dist/src/harness/final-output.js +1 -0
  299. package/dist/src/harness/handles/query.d.ts +1 -1
  300. package/dist/src/harness/handles/store.d.ts +8 -0
  301. package/dist/src/harness/handles/store.js +1 -1
  302. package/dist/src/harness/hitl/approval-input-requests.d.ts +1 -1
  303. package/dist/src/harness/hitl/approval-prompt.d.ts +1 -1
  304. package/dist/src/harness/hitl/pending-input-resolution.d.ts +2 -2
  305. package/dist/src/harness/hitl/question-input-requests.d.ts +1 -1
  306. package/dist/src/harness/input-extraction.d.ts +1 -1
  307. package/dist/src/harness/input-extraction.js +1 -1
  308. package/dist/src/harness/input-request-class.d.ts +1 -1
  309. package/dist/src/harness/input-request-resolution.d.ts +1 -1
  310. package/dist/src/harness/input-requests.d.ts +2 -2
  311. package/dist/src/harness/instrumentation/lifecycle.d.ts +3 -0
  312. package/dist/src/harness/instrumentation/providers.js +1 -1
  313. package/dist/src/harness/instrumentation/runtime.d.ts +2 -1
  314. package/dist/src/harness/pending-input-batches.d.ts +1 -1
  315. package/dist/src/harness/prepare-trace-context.d.ts +3 -0
  316. package/dist/src/harness/prepare-trace-context.js +1 -1
  317. package/dist/src/harness/provider-safety.d.ts +7 -0
  318. package/dist/src/harness/provider-safety.js +1 -0
  319. package/dist/src/{runtime/framework-tools/web-search.d.ts → harness/provider-tool-schemas.d.ts} +1 -9
  320. package/dist/src/harness/provider-tool-schemas.js +1 -0
  321. package/dist/src/harness/provider-tools.js +1 -1
  322. package/dist/src/harness/proxy-input-requests.d.ts +1 -1
  323. package/dist/src/harness/request-input-tool.d.ts +4 -0
  324. package/dist/src/harness/request-input-tool.js +1 -0
  325. package/dist/src/harness/runtime-actions.d.ts +1 -1
  326. package/dist/src/harness/session-limit-continuation.d.ts +1 -1
  327. package/dist/src/harness/step-hooks.d.ts +2 -0
  328. package/dist/src/harness/step-hooks.js +1 -1
  329. package/dist/src/harness/stream-actions.d.ts +1 -1
  330. package/dist/src/harness/subagent-depth.d.ts +1 -1
  331. package/dist/src/harness/tool-call-action.d.ts +1 -1
  332. package/dist/src/harness/tool-call-input-errors.d.ts +1 -1
  333. package/dist/src/harness/tool-loop.js +2 -2
  334. package/dist/src/harness/tool-model-output.d.ts +1 -1
  335. package/dist/src/harness/tools.d.ts +1 -1
  336. package/dist/src/harness/tools.js +1 -1
  337. package/dist/src/harness/types.d.ts +3 -9
  338. package/dist/src/harness/workflow-runtime-action-state.d.ts +1 -1
  339. package/dist/src/harness/workflow-subagent-limit.d.ts +1 -1
  340. package/dist/src/instrumentation/provider.d.ts +117 -0
  341. package/dist/src/instrumentation/provider.js +1 -0
  342. package/dist/src/internal/application/compiled-artifacts.js +5 -4
  343. package/dist/src/internal/application/package.js +1 -1
  344. package/dist/src/internal/authored-definition/approval.d.ts +1 -1
  345. package/dist/src/internal/authored-definition/connection.js +1 -1
  346. package/dist/src/internal/authored-definition/core.js +1 -1
  347. package/dist/src/internal/authored-definition/memory.d.ts +2 -0
  348. package/dist/src/internal/authored-definition/memory.js +1 -0
  349. package/dist/src/internal/authored-definition/schema-backed.d.ts +7 -3
  350. package/dist/src/internal/authored-definition/schema-backed.js +1 -1
  351. package/dist/src/internal/authored-definition/source-identity.d.ts +17 -0
  352. package/dist/src/internal/authored-definition/source-identity.js +1 -0
  353. package/dist/src/internal/authored-module-map-loader.d.ts +1 -5
  354. package/dist/src/internal/authored-module-map-loader.js +1 -1
  355. package/dist/src/internal/dynamic-tool-rebind.d.ts +3 -0
  356. package/dist/src/internal/dynamic-tool-rebind.js +1 -0
  357. package/dist/src/internal/helpers/markdown.js +1 -1
  358. package/dist/src/internal/invocation/agent-invocation.d.ts +2 -2
  359. package/dist/src/internal/invocation/workflow-execution.d.ts +1 -1
  360. package/dist/src/internal/invocation/workflow-execution.js +1 -1
  361. package/dist/src/internal/materialized-authored-modules.js +1 -1
  362. package/dist/src/internal/nitro/dev-runtime-artifacts.js +1 -1
  363. package/dist/src/internal/nitro/host/application-route-registry.d.ts +2 -41
  364. package/dist/src/internal/nitro/host/application-route-registry.js +1 -1
  365. package/dist/src/internal/nitro/host/build-extension.js +1 -1
  366. package/dist/src/internal/nitro/host/build-vercel-agent-summary.js +1 -1
  367. package/dist/src/internal/nitro/host/configure-nitro-routes.js +3 -4
  368. package/dist/src/internal/nitro/host/create-application-nitro.js +1 -1
  369. package/dist/src/internal/nitro/host/dev-host-fingerprint.js +1 -1
  370. package/dist/src/internal/nitro/host/extension-capability-requirements.d.ts +2 -0
  371. package/dist/src/internal/nitro/host/extension-capability-requirements.js +1 -1
  372. package/dist/src/internal/nitro/host/start-development-server.js +2 -2
  373. package/dist/src/internal/nitro/host/start-production-server.js +3 -3
  374. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response.d.ts +9 -215
  375. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response.js +1 -1
  376. package/dist/src/internal/nitro/routes/agent-info/load-agent-info-data.d.ts +2 -13
  377. package/dist/src/internal/nitro/routes/agent-info/load-agent-info-data.js +1 -1
  378. package/dist/src/internal/nitro/routes/channel-dispatch.js +1 -1
  379. package/dist/src/internal/nitro/routes/channel-route-context.d.ts +5 -0
  380. package/dist/src/internal/nitro/routes/channel-route-context.js +1 -1
  381. package/dist/src/internal/nitro/routes/index.d.ts +0 -9
  382. package/dist/src/internal/nitro/routes/index.js +2 -1
  383. package/dist/src/internal/nitro/routes/info.js +1 -1
  384. package/dist/src/internal/nitro/routes/runtime-stack.d.ts +5 -5
  385. package/dist/src/internal/nitro/routes/runtime-stack.js +1 -1
  386. package/dist/src/internal/programmatic-source-loader.d.ts +2 -0
  387. package/dist/src/internal/programmatic-source-loader.js +1 -0
  388. package/dist/src/internal/runtime-registry.d.ts +3 -4
  389. package/dist/src/protocol/message.d.ts +3 -3
  390. package/dist/src/protocol/routes.d.ts +2 -0
  391. package/dist/src/protocol/routes.js +1 -1
  392. package/dist/src/public/agents/auth.d.ts +10 -6
  393. package/dist/src/public/agents/auth.js +1 -1
  394. package/dist/src/public/channels/auth.d.ts +1 -1
  395. package/dist/src/public/channels/auth.js +1 -1
  396. package/dist/src/public/channels/discord/discordChannel.js +1 -1
  397. package/dist/src/public/channels/discord/hitl.d.ts +1 -1
  398. package/dist/src/public/channels/discord/hitl.js +1 -1
  399. package/dist/src/public/channels/discord/inbound.d.ts +1 -0
  400. package/dist/src/public/channels/discord/inbound.js +1 -1
  401. package/dist/src/public/channels/eve.d.ts +1 -139
  402. package/dist/src/public/channels/eve.js +1 -3
  403. package/dist/src/public/channels/github/dispatch.d.ts +5 -0
  404. package/dist/src/public/channels/github/dispatch.js +1 -1
  405. package/dist/src/public/channels/github/githubChannel.js +1 -1
  406. package/dist/src/public/channels/github/inbound.d.ts +2 -0
  407. package/dist/src/public/channels/github/inbound.js +1 -1
  408. package/dist/src/public/channels/index.d.ts +1 -1
  409. package/dist/src/public/channels/index.js +1 -1
  410. package/dist/src/public/channels/linear/hitl.d.ts +1 -1
  411. package/dist/src/public/channels/linear/inbound.js +1 -1
  412. package/dist/src/public/channels/mcp.js +1 -1
  413. package/dist/src/public/channels/slack/action-status.d.ts +1 -1
  414. package/dist/src/public/channels/slack/hitl.d.ts +1 -1
  415. package/dist/src/public/channels/slack/hitl.js +1 -1
  416. package/dist/src/public/channels/slack/inbound.d.ts +9 -0
  417. package/dist/src/public/channels/slack/inbound.js +1 -1
  418. package/dist/src/public/channels/slack/interactions.js +1 -1
  419. package/dist/src/public/channels/slack/model-context.d.ts +3 -1
  420. package/dist/src/public/channels/slack/model-context.js +2 -2
  421. package/dist/src/public/channels/slack/session-operations.d.ts +1 -1
  422. package/dist/src/public/channels/slack/slackChannel.d.ts +1 -1
  423. package/dist/src/public/channels/slack/slackChannel.js +1 -1
  424. package/dist/src/public/channels/teams/hitl.d.ts +1 -1
  425. package/dist/src/public/channels/teams/hitl.js +1 -1
  426. package/dist/src/public/channels/teams/inbound.d.ts +2 -0
  427. package/dist/src/public/channels/teams/inbound.js +1 -1
  428. package/dist/src/public/channels/teams/teamsChannel.js +1 -1
  429. package/dist/src/public/channels/teams/verify.js +1 -1
  430. package/dist/src/public/channels/telegram/api.d.ts +15 -0
  431. package/dist/src/public/channels/telegram/api.js +2 -2
  432. package/dist/src/public/channels/telegram/authorization-callback.d.ts +10 -0
  433. package/dist/src/public/channels/telegram/authorization-callback.js +1 -0
  434. package/dist/src/public/channels/telegram/authorization.d.ts +19 -0
  435. package/dist/src/public/channels/telegram/authorization.js +3 -0
  436. package/dist/src/public/channels/telegram/defaults.d.ts +1 -0
  437. package/dist/src/public/channels/telegram/defaults.js +3 -3
  438. package/dist/src/public/channels/telegram/hitl.d.ts +1 -1
  439. package/dist/src/public/channels/telegram/hitl.js +1 -1
  440. package/dist/src/public/channels/telegram/inbound.d.ts +1 -0
  441. package/dist/src/public/channels/telegram/inbound.js +1 -1
  442. package/dist/src/public/channels/telegram/index.d.ts +1 -1
  443. package/dist/src/public/channels/telegram/index.js +1 -1
  444. package/dist/src/public/channels/telegram/state.d.ts +6 -0
  445. package/dist/src/public/channels/telegram/state.js +1 -0
  446. package/dist/src/public/channels/telegram/telegramChannel.d.ts +11 -0
  447. package/dist/src/public/channels/telegram/telegramChannel.js +1 -1
  448. package/dist/src/public/connections/errors.d.ts +1 -125
  449. package/dist/src/public/connections/errors.js +1 -1
  450. package/dist/src/public/connections/index.d.ts +2 -2
  451. package/dist/src/public/connections/index.js +1 -1
  452. package/dist/src/public/definitions/agent.d.ts +1 -1
  453. package/dist/src/public/definitions/agent.js +1 -1
  454. package/dist/src/public/definitions/approval.d.ts +2 -84
  455. package/dist/src/public/definitions/approval.js +1 -1
  456. package/dist/src/public/definitions/callback-context.d.ts +1 -32
  457. package/dist/src/public/definitions/connections/mcp.d.ts +1 -1
  458. package/dist/src/public/definitions/connections/mcp.js +1 -1
  459. package/dist/src/public/definitions/connections/openapi.d.ts +1 -1
  460. package/dist/src/public/definitions/connections/openapi.js +1 -1
  461. package/dist/src/public/definitions/connections/protocol.d.ts +1 -1
  462. package/dist/src/public/definitions/instructions.d.ts +2 -2
  463. package/dist/src/public/definitions/instructions.js +1 -1
  464. package/dist/src/public/definitions/skill.js +1 -1
  465. package/dist/src/public/index.d.ts +1 -1
  466. package/dist/src/public/instructions/index.d.ts +1 -1
  467. package/dist/src/public/instrumentation/provider.d.ts +1 -117
  468. package/dist/src/public/instrumentation/provider.js +1 -1
  469. package/dist/src/public/memory/index.d.ts +117 -0
  470. package/dist/src/public/memory/index.js +1 -0
  471. package/dist/src/public/memory/scope.d.ts +2 -0
  472. package/dist/src/public/memory/scope.js +1 -0
  473. package/dist/src/public/models/openai/chatgpt/auth.js +1 -1
  474. package/dist/src/public/next/server.js +1 -1
  475. package/dist/src/public/nuxt/dev-server.js +1 -1
  476. package/dist/src/public/sandbox/backends/default.d.ts +1 -49
  477. package/dist/src/public/sandbox/backends/default.js +1 -1
  478. package/dist/src/public/sandbox/backends/docker.d.ts +1 -14
  479. package/dist/src/public/sandbox/backends/docker.js +1 -1
  480. package/dist/src/public/sandbox/backends/just-bash.d.ts +1 -17
  481. package/dist/src/public/sandbox/backends/just-bash.js +1 -1
  482. package/dist/src/public/sandbox/backends/microsandbox.d.ts +1 -17
  483. package/dist/src/public/sandbox/backends/microsandbox.js +1 -1
  484. package/dist/src/public/sandbox/backends/vercel.d.ts +1 -30
  485. package/dist/src/public/sandbox/backends/vercel.js +1 -1
  486. package/dist/src/public/skills/index.d.ts +3 -3
  487. package/dist/src/public/skills/index.js +1 -1
  488. package/dist/src/public/sveltekit/dev-server.js +1 -1
  489. package/dist/src/public/tools/approval/index.d.ts +2 -2
  490. package/dist/src/public/tools/approval/index.js +1 -1
  491. package/dist/src/public/tools/bash.d.ts +3 -0
  492. package/dist/src/public/tools/bash.js +1 -0
  493. package/dist/src/public/tools/glob.d.ts +3 -0
  494. package/dist/src/public/tools/glob.js +1 -0
  495. package/dist/src/public/tools/grep.d.ts +3 -0
  496. package/dist/src/public/tools/grep.js +1 -0
  497. package/dist/src/public/tools/index.d.ts +6 -11
  498. package/dist/src/public/tools/index.js +1 -1
  499. package/dist/src/public/tools/load-skill.d.ts +3 -0
  500. package/dist/src/public/tools/load-skill.js +1 -0
  501. package/dist/src/public/tools/read-file.d.ts +3 -0
  502. package/dist/src/public/tools/read-file.js +1 -0
  503. package/dist/src/public/{tool-result-narrowing.d.ts → tools/result.d.ts} +2 -28
  504. package/dist/src/public/tools/result.js +1 -0
  505. package/dist/src/public/tools/sleep.d.ts +1 -0
  506. package/dist/src/public/tools/sleep.js +1 -0
  507. package/dist/src/public/tools/todo.d.ts +3 -0
  508. package/dist/src/public/tools/todo.js +1 -0
  509. package/dist/src/public/tools/web-fetch.d.ts +3 -0
  510. package/dist/src/public/tools/web-fetch.js +1 -0
  511. package/dist/src/public/tools/web-search.d.ts +3 -36
  512. package/dist/src/public/tools/web-search.js +1 -1
  513. package/dist/src/public/tools/workflow.d.ts +4 -0
  514. package/dist/src/public/tools/workflow.js +1 -0
  515. package/dist/src/public/tools/write-file.d.ts +3 -0
  516. package/dist/src/public/tools/write-file.js +1 -0
  517. package/dist/src/public/types/json.d.ts +1 -28
  518. package/dist/src/react/use-eve-agent.d.ts +1 -0
  519. package/dist/src/react/use-eve-agent.js +1 -1
  520. package/dist/src/runtime/actions/keys.d.ts +1 -1
  521. package/dist/src/runtime/actions/results.d.ts +1 -1
  522. package/dist/src/runtime/agent/bootstrap.js +1 -1
  523. package/dist/src/runtime/agent/mock-model-adapter.js +1 -1
  524. package/dist/src/runtime/connections/authorization-tokens.d.ts +1 -1
  525. package/dist/src/runtime/connections/mcp-client.d.ts +1 -1
  526. package/dist/src/runtime/connections/mcp-client.js +1 -1
  527. package/dist/src/runtime/connections/openapi-client.d.ts +1 -1
  528. package/dist/src/runtime/connections/openapi-client.js +1 -1
  529. package/dist/src/runtime/connections/principal.d.ts +1 -1
  530. package/dist/src/runtime/connections/principal.js +1 -1
  531. package/dist/src/runtime/connections/registry-types.d.ts +11 -0
  532. package/dist/src/runtime/connections/registry.d.ts +3 -2
  533. package/dist/src/runtime/connections/resolve-authorization.d.ts +2 -2
  534. package/dist/src/runtime/connections/resolve-authorization.js +1 -1
  535. package/dist/src/runtime/connections/scoped-authorization.d.ts +2 -2
  536. package/dist/src/runtime/connections/scoped-authorization.js +1 -1
  537. package/dist/src/runtime/loaders/compile-metadata.js +1 -1
  538. package/dist/src/runtime/loaders/manifest.js +1 -1
  539. package/dist/src/runtime/prompt/compose.d.ts +0 -6
  540. package/dist/src/runtime/prompt/compose.js +1 -1
  541. package/dist/src/runtime/resolve-agent-graph.js +1 -1
  542. package/dist/src/runtime/resolve-agent.js +1 -1
  543. package/dist/src/runtime/resolve-connection.js +1 -1
  544. package/dist/src/runtime/resolve-dynamic-tool.d.ts +1 -0
  545. package/dist/src/runtime/resolve-dynamic-tool.js +1 -1
  546. package/dist/src/runtime/resolve-memory.d.ts +4 -0
  547. package/dist/src/runtime/resolve-memory.js +1 -0
  548. package/dist/src/runtime/resolve-tool.d.ts +2 -1
  549. package/dist/src/runtime/resolve-tool.js +1 -1
  550. package/dist/src/runtime/sandbox/keys.js +1 -1
  551. package/dist/src/runtime/sandbox/registry.d.ts +4 -20
  552. package/dist/src/runtime/sandbox/registry.js +1 -1
  553. package/dist/src/runtime/sessions/compiled-agent-cache.js +1 -1
  554. package/dist/src/runtime/sessions/runtime-context-keys.js +1 -1
  555. package/dist/src/runtime/sessions/turn.d.ts +3 -1
  556. package/dist/src/runtime/skills/sandbox-access.d.ts +1 -1
  557. package/dist/src/runtime/subagents/dynamic-agent-config.js +1 -1
  558. package/dist/src/runtime/subagents/dynamic-remote-agent-config.js +1 -1
  559. package/dist/src/runtime/subagents/registry.d.ts +0 -27
  560. package/dist/src/runtime/subagents/registry.js +1 -1
  561. package/dist/src/runtime/tools/registry.js +1 -1
  562. package/dist/src/runtime/types.d.ts +18 -27
  563. package/dist/src/sandbox/backends/default.d.ts +49 -0
  564. package/dist/src/sandbox/backends/default.js +1 -0
  565. package/dist/src/sandbox/backends/docker.d.ts +14 -0
  566. package/dist/src/sandbox/backends/docker.js +1 -0
  567. package/dist/src/sandbox/backends/just-bash.d.ts +17 -0
  568. package/dist/src/sandbox/backends/just-bash.js +1 -0
  569. package/dist/src/sandbox/backends/microsandbox.d.ts +17 -0
  570. package/dist/src/sandbox/backends/microsandbox.js +1 -0
  571. package/dist/src/sandbox/backends/vercel.d.ts +30 -0
  572. package/dist/src/sandbox/backends/vercel.js +1 -0
  573. package/dist/src/services/dev-client/runtime-artifacts.d.ts +2 -0
  574. package/dist/src/services/dev-client/runtime-artifacts.js +1 -1
  575. package/dist/src/services/dev-client.d.ts +1 -1
  576. package/dist/src/setup/channel-add-conflicts.js +1 -1
  577. package/dist/src/setup/cli/select-component.js +1 -1
  578. package/dist/src/setup/connection-connector.d.ts +2 -0
  579. package/dist/src/setup/connection-connector.js +1 -1
  580. package/dist/src/setup/flows/link.js +1 -1
  581. package/dist/src/setup/flows/model-source-change.js +1 -1
  582. package/dist/src/setup/flows/model.js +1 -1
  583. package/dist/src/setup/flows/registry.js +1 -1
  584. package/dist/src/setup/integrations/runner.js +1 -1
  585. package/dist/src/setup/prompter.js +1 -1
  586. package/dist/src/setup/scaffold/create/add-to-project.js +1 -1
  587. package/dist/src/setup/scaffold/create/project.js +2 -2
  588. package/dist/src/setup/scaffold/create/web-template.d.ts +10 -8
  589. package/dist/src/setup/scaffold/create/web-template.js +364 -120
  590. package/dist/src/setup/scaffold/update/channels.js +1 -1
  591. package/dist/src/setup/scaffold/update/connections.js +1 -1
  592. package/dist/src/setup/vercel-project.js +0 -0
  593. package/dist/src/{runtime/actions/types.d.ts → shared/action-types.d.ts} +12 -12
  594. package/dist/src/{runtime/actions/types.js → shared/action-types.js} +1 -1
  595. package/dist/src/shared/agent-definition.d.ts +3 -10
  596. package/dist/src/shared/agent-definition.js +1 -1
  597. package/dist/src/{runtime/connections/types.d.ts → shared/connection-types.d.ts} +3 -13
  598. package/dist/src/{runtime/input/types.d.ts → shared/input.d.ts} +1 -1
  599. package/dist/src/shared/input.js +1 -0
  600. package/dist/src/shared/instructions-definition.d.ts +2 -0
  601. package/dist/src/shared/instructions-definition.js +1 -1
  602. package/dist/src/shared/memory-definition.d.ts +2 -0
  603. package/dist/src/shared/memory-definition.js +1 -0
  604. package/dist/src/shared/memory-state.d.ts +55 -0
  605. package/dist/src/shared/memory-state.js +1 -0
  606. package/dist/src/shared/objects.d.ts +5 -0
  607. package/dist/src/shared/objects.js +1 -0
  608. package/dist/src/shared/sandbox-definition.d.ts +1 -1
  609. package/dist/src/shared/skill-definition.d.ts +2 -0
  610. package/dist/src/shared/skill-definition.js +1 -1
  611. package/dist/src/{execution/skills/types.d.ts → shared/skill-types.d.ts} +1 -1
  612. package/dist/src/shared/skill-types.js +1 -0
  613. package/dist/src/{runtime/connections → shared}/validate-authorization.d.ts +1 -1
  614. package/dist/src/shared/vercel-project.d.ts +1 -0
  615. package/dist/src/shared/vercel-project.js +1 -1
  616. package/dist/src/svelte/index.js +1 -1
  617. package/dist/src/svelte/use-eve-agent.d.ts +8 -4
  618. package/dist/src/svelte/use-eve-agent.js +1 -1
  619. package/dist/src/tasks/json.d.ts +4 -89
  620. package/dist/src/tasks/json.js +1 -1
  621. package/dist/src/tasks/session-index.d.ts +1 -1
  622. package/dist/src/tasks/task-id.d.ts +0 -1
  623. package/dist/src/tasks/task-id.js +1 -1
  624. package/dist/src/tasks/types.d.ts +1 -1
  625. package/dist/src/tasks/types.js +1 -1
  626. package/dist/src/{public/tools/approval/approval-helpers.d.ts → tools/approval/policies.d.ts} +1 -1
  627. package/dist/src/tools/approval/policies.js +1 -0
  628. package/dist/src/tools/auth.d.ts +35 -0
  629. package/dist/src/tools/auth.js +1 -0
  630. package/dist/src/{public/definitions/tool.d.ts → tools/definition.d.ts} +42 -138
  631. package/dist/src/tools/definition.js +1 -0
  632. package/dist/src/{shared/durable-dynamic-tool-callbacks.d.ts → tools/durable-callbacks.d.ts} +1 -1
  633. package/dist/src/tools/durable-callbacks.js +1 -0
  634. package/dist/src/tools/dynamic.d.ts +68 -0
  635. package/dist/src/tools/dynamic.js +1 -0
  636. package/dist/src/tools/framework/agent-contract.d.ts +8 -0
  637. package/dist/src/tools/framework/agent-contract.js +1 -0
  638. package/dist/src/tools/framework/agent.d.ts +17 -0
  639. package/dist/src/tools/framework/agent.js +1 -0
  640. package/dist/src/tools/framework/ask-question.d.ts +50 -0
  641. package/dist/src/tools/framework/ask-question.js +1 -0
  642. package/dist/src/tools/framework/connection-search.d.ts +3 -0
  643. package/dist/src/tools/framework/connection-search.js +1 -0
  644. package/dist/src/tools/framework/task-cancel.d.ts +29 -0
  645. package/dist/src/tools/framework/task-cancel.js +1 -0
  646. package/dist/src/tools/framework/task-contract.d.ts +167 -0
  647. package/dist/src/tools/framework/task-contract.js +1 -0
  648. package/dist/src/tools/framework/task-update.d.ts +9 -0
  649. package/dist/src/tools/framework/task-update.js +1 -0
  650. package/dist/src/{public/tools/output-builders.d.ts → tools/model-output.d.ts} +41 -1
  651. package/dist/src/tools/provided/bash.d.ts +29 -0
  652. package/dist/src/tools/provided/bash.js +1 -0
  653. package/dist/src/tools/provided/glob.d.ts +26 -0
  654. package/dist/src/tools/provided/glob.js +2 -0
  655. package/dist/src/{runtime/framework-tools → tools/provided}/grep.d.ts +10 -10
  656. package/dist/src/tools/provided/grep.js +2 -0
  657. package/dist/src/tools/provided/load-skill.d.ts +2 -0
  658. package/dist/src/tools/provided/load-skill.js +1 -0
  659. package/dist/src/tools/provided/read-file.d.ts +27 -0
  660. package/dist/src/tools/provided/read-file.js +2 -0
  661. package/dist/src/{public/tools/sleep/index.d.ts → tools/provided/sleep.d.ts} +3 -3
  662. package/dist/src/tools/provided/sleep.js +1 -0
  663. package/dist/src/tools/provided/todo.d.ts +8 -0
  664. package/dist/src/tools/provided/todo.js +2 -0
  665. package/dist/src/{runtime/framework-tools → tools/provided}/web-fetch.d.ts +5 -2
  666. package/dist/src/tools/provided/web-fetch.js +2 -0
  667. package/dist/src/tools/provided/web-search.d.ts +39 -0
  668. package/dist/src/tools/provided/web-search.js +1 -0
  669. package/dist/src/tools/provided/write-file.d.ts +23 -0
  670. package/dist/src/tools/provided/write-file.js +2 -0
  671. package/dist/src/tools/workflow.d.ts +37 -0
  672. package/dist/src/tools/workflow.js +1 -0
  673. package/dist/src/tracing/agent-action-instrumentation.js +1 -1
  674. package/dist/src/tracing/agent-approval-instrumentation.js +1 -1
  675. package/dist/src/tracing/agent-channel-delivery-instrumentation.js +1 -1
  676. package/dist/src/tracing/agent-otel-provider.js +2 -2
  677. package/dist/src/tracing/agent-otel-session-context.d.ts +1 -1
  678. package/dist/src/tracing/agent-otel-session-context.js +1 -1
  679. package/dist/src/tracing/agent-span-id-generator.d.ts +1 -0
  680. package/dist/src/tracing/agent-span-id-generator.js +1 -1
  681. package/dist/src/tracing/agent-trace-context-store.d.ts +1 -1
  682. package/dist/src/tracing/agent-trace-context-store.js +1 -1
  683. package/dist/src/tracing/agent-trace-span-processor.js +1 -1
  684. package/dist/src/tracing/agent-trace-state.d.ts +2 -6
  685. package/dist/src/tracing/agent-trace-state.js +1 -1
  686. package/dist/src/tracing/install-instrumentation-runtime.js +1 -1
  687. package/dist/src/tracing/local-trace-reader.d.ts +1 -3
  688. package/dist/src/tracing/local-trace-reader.js +1 -1
  689. package/dist/src/tracing/otel-declaration.d.ts +1 -2
  690. package/dist/src/tracing/otel-registration.js +1 -1
  691. package/dist/src/tracing/sampled-trace.d.ts +10 -2
  692. package/dist/src/tracing/sampled-trace.js +1 -1
  693. package/dist/src/vue/index.js +1 -1
  694. package/dist/src/vue/use-eve-agent.d.ts +8 -4
  695. package/dist/src/vue/use-eve-agent.js +1 -1
  696. package/docs/agent-config.md +16 -4
  697. package/docs/channels/chat-sdk.mdx +1 -1
  698. package/docs/channels/discord.mdx +5 -1
  699. package/docs/channels/eve.mdx +19 -3
  700. package/docs/channels/github.mdx +2 -0
  701. package/docs/channels/linear.mdx +1 -1
  702. package/docs/channels/overview.mdx +1 -1
  703. package/docs/channels/slack.mdx +2 -0
  704. package/docs/channels/teams.mdx +1 -1
  705. package/docs/channels/telegram.mdx +2 -0
  706. package/docs/concepts/built-in-tools.md +30 -21
  707. package/docs/concepts/context-control.md +7 -0
  708. package/docs/concepts/default-harness.md +8 -0
  709. package/docs/concepts/sessions-runs-and-streaming.md +5 -3
  710. package/docs/concepts/state.md +8 -1
  711. package/docs/connections/overview.mdx +1 -1
  712. package/docs/extensions.md +8 -4
  713. package/docs/getting-started.mdx +9 -9
  714. package/docs/guides/auth-and-route-protection.md +3 -3
  715. package/docs/guides/client/output-schema.mdx +2 -2
  716. package/docs/guides/client/overview.mdx +4 -2
  717. package/docs/guides/dynamic-capabilities.md +3 -2
  718. package/docs/guides/frontend/nuxt.mdx +4 -3
  719. package/docs/guides/frontend/overview.mdx +21 -18
  720. package/docs/guides/frontend/sveltekit.mdx +4 -3
  721. package/docs/guides/frontend/use-eve-agent-svelte.mdx +5 -4
  722. package/docs/guides/frontend/use-eve-agent-vue.mdx +5 -4
  723. package/docs/guides/instrumentation.md +1 -0
  724. package/docs/guides/remote-agents.md +37 -18
  725. package/docs/memory.md +255 -0
  726. package/docs/meta.json +1 -0
  727. package/docs/patterns/multi-tenant-approvals.md +1 -1
  728. package/docs/patterns/multi-tenant-memory.md +108 -136
  729. package/docs/reference/cli.md +2 -4
  730. package/docs/reference/typescript-api.md +35 -31
  731. package/docs/sandbox.mdx +1 -1
  732. package/docs/subagents/index.mdx +11 -28
  733. package/docs/tools/human-in-the-loop.md +43 -2
  734. package/docs/tools/overview.mdx +1 -1
  735. package/package.json +68 -8
  736. package/dist/src/compiler/normalize-extension.d.ts +0 -80
  737. package/dist/src/compiler/normalize-extension.js +0 -1
  738. package/dist/src/execution/sandbox/write-file-tool.js +0 -1
  739. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response-from-manifest.d.ts +0 -9
  740. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response-from-manifest.js +0 -1
  741. package/dist/src/internal/nitro/routes/health.d.ts +0 -14
  742. package/dist/src/internal/nitro/routes/health.js +0 -1
  743. package/dist/src/node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js +0 -1
  744. package/dist/src/public/definitions/tool.js +0 -1
  745. package/dist/src/public/tool-result-narrowing.js +0 -1
  746. package/dist/src/public/tools/approval/approval-helpers.js +0 -1
  747. package/dist/src/public/tools/defaults.d.ts +0 -46
  748. package/dist/src/public/tools/defaults.js +0 -1
  749. package/dist/src/public/tools/define-bash-tool.d.ts +0 -21
  750. package/dist/src/public/tools/define-bash-tool.js +0 -1
  751. package/dist/src/public/tools/define-glob-tool.d.ts +0 -22
  752. package/dist/src/public/tools/define-glob-tool.js +0 -1
  753. package/dist/src/public/tools/define-grep-tool.d.ts +0 -22
  754. package/dist/src/public/tools/define-grep-tool.js +0 -1
  755. package/dist/src/public/tools/define-read-file-tool.d.ts +0 -21
  756. package/dist/src/public/tools/define-read-file-tool.js +0 -1
  757. package/dist/src/public/tools/define-write-file-tool.d.ts +0 -22
  758. package/dist/src/public/tools/define-write-file-tool.js +0 -1
  759. package/dist/src/public/tools/internal.d.ts +0 -13
  760. package/dist/src/public/tools/internal.js +0 -1
  761. package/dist/src/public/tools/sleep/index.js +0 -1
  762. package/dist/src/runtime/connections/callback-route.js +0 -1
  763. package/dist/src/runtime/framework-channels/index.d.ts +0 -6
  764. package/dist/src/runtime/framework-channels/index.js +0 -1
  765. package/dist/src/runtime/framework-tools/agent.d.ts +0 -29
  766. package/dist/src/runtime/framework-tools/agent.js +0 -1
  767. package/dist/src/runtime/framework-tools/ask-question.d.ts +0 -35
  768. package/dist/src/runtime/framework-tools/ask-question.js +0 -1
  769. package/dist/src/runtime/framework-tools/bash.d.ts +0 -24
  770. package/dist/src/runtime/framework-tools/bash.js +0 -1
  771. package/dist/src/runtime/framework-tools/connection-search-dynamic.d.ts +0 -19
  772. package/dist/src/runtime/framework-tools/connection-search-dynamic.js +0 -2
  773. package/dist/src/runtime/framework-tools/final-output.js +0 -1
  774. package/dist/src/runtime/framework-tools/glob.d.ts +0 -26
  775. package/dist/src/runtime/framework-tools/glob.js +0 -2
  776. package/dist/src/runtime/framework-tools/grep.js +0 -2
  777. package/dist/src/runtime/framework-tools/index.d.ts +0 -39
  778. package/dist/src/runtime/framework-tools/index.js +0 -1
  779. package/dist/src/runtime/framework-tools/read-file.d.ts +0 -27
  780. package/dist/src/runtime/framework-tools/read-file.js +0 -2
  781. package/dist/src/runtime/framework-tools/skill.d.ts +0 -12
  782. package/dist/src/runtime/framework-tools/skill.js +0 -1
  783. package/dist/src/runtime/framework-tools/subagent/local.js +0 -1
  784. package/dist/src/runtime/framework-tools/subagent/remote.js +0 -1
  785. package/dist/src/runtime/framework-tools/tasks.d.ts +0 -91
  786. package/dist/src/runtime/framework-tools/tasks.js +0 -1
  787. package/dist/src/runtime/framework-tools/web-fetch.js +0 -2
  788. package/dist/src/runtime/framework-tools/web-search.js +0 -1
  789. package/dist/src/runtime/framework-tools/write-file.d.ts +0 -23
  790. package/dist/src/runtime/framework-tools/write-file.js +0 -2
  791. package/dist/src/runtime/governance/auth/jwt-ecdsa.js +0 -1
  792. package/dist/src/runtime/governance/auth/jwt-hmac.js +0 -1
  793. package/dist/src/runtime/governance/auth/oidc.js +0 -1
  794. package/dist/src/runtime/input/types.js +0 -1
  795. package/dist/src/runtime/session-callback-route.d.ts +0 -6
  796. package/dist/src/runtime/session-callback-route.js +0 -1
  797. package/dist/src/runtime/task-input-response-route.d.ts +0 -5
  798. package/dist/src/runtime/task-input-response-route.js +0 -1
  799. package/dist/src/shared/durable-dynamic-tool-callbacks.js +0 -1
  800. package/dist/src/shared/dynamic-tool-definition.d.ts +0 -154
  801. package/dist/src/shared/dynamic-tool-definition.js +0 -1
  802. package/dist/src/shared/eve-server-health.d.ts +0 -5
  803. package/dist/src/shared/eve-server-health.js +0 -1
  804. package/dist/src/shared/tool-definition.d.ts +0 -89
  805. /package/dist/src/{runtime/governance → channel}/auth/http-basic.js +0 -0
  806. /package/dist/src/{runtime/governance → channel}/auth/token-claims.js +0 -0
  807. /package/dist/src/{runtime/governance → channel}/auth/types.js +0 -0
  808. /package/dist/src/{runtime/governance → channel}/auth/vercel-oidc-project.js +0 -0
  809. /package/dist/src/{runtime/governance/network → channel}/ip-allow-list.d.ts +0 -0
  810. /package/dist/src/{runtime/governance/network → channel}/ip-allow-list.js +0 -0
  811. /package/dist/src/{execution/skills/types.js → context/session-context.js} +0 -0
  812. /package/dist/src/execution/sandbox/{bash-tool.js → bash.js} +0 -0
  813. /package/dist/src/{runtime/framework-tools → execution/tools}/file-state.js +0 -0
  814. /package/dist/src/{runtime/framework-tools → execution/tools}/sleep.d.ts +0 -0
  815. /package/dist/src/{runtime/framework-tools → execution/tools}/sleep.js +0 -0
  816. /package/dist/src/execution/web-fetch/{tool.d.ts → execute.d.ts} +0 -0
  817. /package/dist/src/execution/web-fetch/{tool.js → execute.js} +0 -0
  818. /package/dist/src/{shared/tool-definition.js → runtime/connections/registry-types.js} +0 -0
  819. /package/dist/src/{runtime/connections/types.js → shared/connection-types.js} +0 -0
  820. /package/dist/src/{runtime/sessions/auth.d.ts → shared/session-auth.d.ts} +0 -0
  821. /package/dist/src/{runtime/sessions/auth.js → shared/session-auth.js} +0 -0
  822. /package/dist/src/{runtime/connections → shared}/validate-authorization.js +0 -0
  823. /package/dist/src/{public/tools/output-builders.js → tools/model-output.js} +0 -0
  824. /package/dist/src/{shared/tool-schema.d.ts → tools/schema.d.ts} +0 -0
  825. /package/dist/src/{shared/tool-schema.js → tools/schema.js} +0 -0
  826. /package/dist/src/{shared/tool-task.d.ts → tools/task.d.ts} +0 -0
  827. /package/dist/src/{shared/tool-task.js → tools/task.js} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,44 @@
1
1
  # eve
2
2
 
3
+ ## 0.45.1
4
+
5
+ ### Patch Changes
6
+
7
+ - a3a5ddd: Show the eve favicon in browser tabs for the default deployed app and generated Web Chat apps. Web Chat scaffolds also include an Apple touch icon.
8
+ - 5664cc0: Add first-class path-authored memory providers with scoped recall, capture, replayable provider tools, and compaction-safe recalled context.
9
+ - b55d036: Agentcard setup now uses the correct MCP discovery and creation identifiers, then writes the selected connector into the installed connection template.
10
+ - fdba4e0: Scope every extension contribution through one mount-namespace policy so multiple extensions can contribute flat `instructions.md` files without collisions. Extension-owned agent singleton slots such as instrumentation are now rejected during discovery.
11
+
12
+ ## 0.45.0
13
+
14
+ ### Minor Changes
15
+
16
+ - b3cf8ee: eve now compiles framework defaults, authored files, extensions, overrides, and in-memory modules through one authoritative source graph, with replaceable default config, sandbox, home, health, and inspection routes plus agent-info v3. Built-in tool definitions move from `eve/tools/defaults` to individual `eve/tools/<name>` subpaths.
17
+ - 6252784: Move provided tool definitions and capability-specific helpers to dedicated `eve/tools/*` entrypoints. Replace the removed `defineBashTool`, `defineReadFileTool`, `defineWriteFileTool`, `defineGlobTool`, and `defineGrepTool` factories with the corresponding reusable definitions.
18
+ - f439e3d: Persistent subagent sessions are now the default: subagent tools expose `agentId`, completed children remain available for follow-up messages, and eve publishes the `<agents>` listing automatically. Remove `experimental.subagentPersistentSessions` from agent configuration; `false` is no longer an opt-out.
19
+
20
+ ### Patch Changes
21
+
22
+ - 4a18994: Keep tools available during follow-up turns while an earlier tool approval remains unresolved, allowing unrelated work to continue without resolving the pending call.
23
+ - d2995e1: Stamp Workflow runs with whether eve-managed OTEL tracing is enabled so dashboards can distinguish Workflow-only runs from enabled but unsampled traces. Session titles remain available alongside that metadata.
24
+ - dfe0d18: Expose resumed session catch-up as a distinct `resuming` frontend lifecycle state so hydrated conversations do not show active-turn controls before an in-flight turn is confirmed.
25
+ - 659774f: Refine generated Web Chat with a single Send or Stop composer action, faster question controls, and compact tool calls. Bash commands get a terminal view, while focus states, spacing, typography, and the composer backdrop are polished.
26
+ - fc52796: Allow framework features to derive ordinary source slots from other selected modules through dependency-aware programmatic templates, with consistent composition and module-map hydration.
27
+ - 2be67fa: Agent trace identity is now established before workflow execution begins, allowing workflow runs and OpenTelemetry spans to refer to the same trace from the outset. Delegated agents inherit the parent trace, while already-running sessions retain their current behavior.
28
+ - 7ed4fb1: Workflow session, subagent, and turn rows now include `$eve.trace_id` when a sampled agent trace is available, allowing workflow views to open the corresponding OpenTelemetry trace directly. Rows without an exported agent trace omit the attribute.
29
+ - 0bc8432: Integration setup banners now describe the integration being configured instead of showing eve's generic framework tagline.
30
+ - 3274eee: Send remote-agent Vercel OIDC credentials in both the bearer and trusted-OIDC headers so `vercelOidc()` can reach eve agents behind Vercel Deployment Protection.
31
+ - ae83a08: Update the generated Web Chat starter to close completed reasoning without delay, soften the header-to-content boundary only while content scrolls beneath it, and enable global font antialiasing.
32
+ - 80571ee: Show declared environment variables and an eve setup link after adding a registry integration from the dev TUI. Chat SDK adapter links open the integration page's Configure section.
33
+ - 7c5a69e: Keep durable agent sessions on their persisted OpenTelemetry trace instead of rotating after 200 turns. Agent Trace schema version 2 relies on native trace parentage instead of window, root-session, and duplicated parent-lineage attributes.
34
+ - f38eaf1: Internal cleanup of the experimental background-tasks plumbing: centralized task-view schemas while preserving strict projection and broad tool-output contracts, removed a duplicate task tool-name set, established one task inbox-token import path, and shared serialized-context key-name constants. No behavior change.
35
+ - cfa90d6: Telegram now supports HITL authorization challenges.
36
+ - d79de0b: Expose channel-native receiver identity in model context, plus exact mention state for Slack, Teams, Telegram, and GitHub comments.
37
+ - 687c371: OpenAI and Anthropic model calls now receive privacy-preserving end-user safety identifiers derived from the active session caller when the agent has not provided one, including calls made during context compaction.
38
+ - 8e5d9b2: Add `j` and `k` as down and up shortcuts in non-editing TUI menus and the trace viewer while preserving normal text input in prompts, search fields, and editors.
39
+ - 7eae011: Accept Vercel OIDC tokens issued from the global issuer in `vercelOidc()` and `verifyVercelOidc()`.
40
+ - c6f9c85: Trace capture policies now receive the originating channel's type, letting a policy sample by channel (for example retaining interactive traffic while dropping scheduled runs). Policies that ignore the field are unaffected.
41
+
3
42
  ## 0.44.4
4
43
 
5
44
  ### Patch Changes
package/README.md CHANGED
@@ -55,18 +55,19 @@ my-agent/
55
55
 
56
56
  Every authored directory has a typed helper. Import each from the matching subpath:
57
57
 
58
- | Helper | Subpath | Authored Location |
59
- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------- | ------------------------------------------------ |
60
- | `defineAgent(...)` | `eve` | `agent.ts`, `subagents/<id>/agent.ts` |
61
- | `defineInstructions(...)` | `eve/instructions` | `instructions.ts` (or `instructions.md`) |
62
- | `defineTool(...)`, `defineBashTool(...)`, `defineReadFileTool(...)`, `defineWriteFileTool(...)`, `disableTool(...)` | `eve/tools` | `tools/<name>.ts` |
63
- | `defineSkill(...)`, `getSkill(...)` | `eve/skills` | `skills/<name>.ts` (or `skills/<name>.md`) |
64
- | `defineHook(...)` | `eve/hooks` | `hooks/<slug>.ts` |
65
- | `defineChannel(...)`, `POST`, `GET` | `eve/channels` | `channels/<name>.ts` |
66
- | `eveChannel(...)`, `slackChannel(...)`, `vercelOidc(...)` | `eve/channels/eve`, `/slack`, `/auth` | reused from `channels/<name>.ts` |
67
- | `defineSandbox(...)` | `eve/sandbox` | `sandbox.ts` (or `sandbox/sandbox.ts`) |
68
- | `defineSchedule(...)` | `eve/schedules` | `schedules/<name>.ts` (or `schedules/<name>.md`) |
69
- | `defineEval(...)`, `defineEvalConfig(...)` | `eve/evals` | `evals/<name>.eval.ts`, `evals/evals.config.ts` |
58
+ | Helper | Subpath | Authored Location |
59
+ | --------------------------------------------------------------- | ------------------------------------- | ------------------------------------------------ |
60
+ | `defineAgent(...)` | `eve` | `agent.ts`, `subagents/<id>/agent.ts` |
61
+ | `defineInstructions(...)` | `eve/instructions` | `instructions.ts` (or `instructions.md`) |
62
+ | `defineTool(...)`, `defineDynamic(...)`, `disableTool(...)` | `eve/tools` | `tools/<name>.ts` |
63
+ | `bash`, `readFile`, `writeFile`, and other provided definitions | `eve/tools/<name>` | `tools/<name>.ts` |
64
+ | `defineSkill(...)`, `getSkill(...)` | `eve/skills` | `skills/<name>.ts` (or `skills/<name>.md`) |
65
+ | `defineHook(...)` | `eve/hooks` | `hooks/<slug>.ts` |
66
+ | `defineChannel(...)`, `POST`, `GET` | `eve/channels` | `channels/<name>.ts` |
67
+ | `eveChannel(...)`, `slackChannel(...)`, `vercelOidc(...)` | `eve/channels/eve`, `/slack`, `/auth` | reused from `channels/<name>.ts` |
68
+ | `defineSandbox(...)` | `eve/sandbox` | `sandbox.ts` (or `sandbox/sandbox.ts`) |
69
+ | `defineSchedule(...)` | `eve/schedules` | `schedules/<name>.ts` (or `schedules/<name>.md`) |
70
+ | `defineEval(...)`, `defineEvalConfig(...)` | `eve/evals` | `evals/<name>.eval.ts`, `evals/evals.config.ts` |
70
71
 
71
72
  Runtime accessors live on the subpath that owns the concern:
72
73
 
@@ -1,7 +1,7 @@
1
1
  import { type AgentContext, type InitializeRequest, type InitializeResponse, type NewSessionRequest, type NewSessionResponse, type PromptRequest, type PromptResponse } from "#compiled/@agentclientprotocol/sdk/index.js";
2
2
  import type { ClientOptions, SendTurnInput } from "#client/types.js";
3
3
  import type { HandleMessageStreamEvent } from "#protocol/message.js";
4
- import type { InputResponse } from "#runtime/input/types.js";
4
+ import type { InputResponse } from "#shared/input.js";
5
5
  interface AdapterClientSession {
6
6
  send(message: SendTurnInput["message"]): Promise<AsyncIterable<HandleMessageStreamEvent>>;
7
7
  respond(inputResponses: readonly InputResponse[]): Promise<AsyncIterable<HandleMessageStreamEvent>>;
@@ -0,0 +1,84 @@
1
+ import type { SessionAuthContext } from "#channel/types.js";
2
+ import type { SessionParent, SessionTurn } from "#context/keys.js";
3
+ import type { ToolAuthOptions, ToolAuthProvider } from "#tools/auth.js";
4
+ import type { SessionContext } from "#context/session-context.js";
5
+ import type { TokenResult } from "#shared/connection-types.js";
6
+ type ApprovalToolInput<TInput> = TInput extends object ? Readonly<TInput> : TInput;
7
+ /**
8
+ * Context passed to an {@link ApprovalPolicy} function.
9
+ *
10
+ * Extends {@link SessionContext} so approval policies can make decisions from
11
+ * the active session, current caller, and turn.
12
+ */
13
+ export interface ApprovalContext<TInput = Record<string, unknown>> extends SessionContext {
14
+ readonly approvedTools: ReadonlySet<string>;
15
+ readonly callId: string;
16
+ readonly toolInput?: ApprovalToolInput<TInput>;
17
+ readonly toolName: string;
18
+ }
19
+ /** Request-time approval decision returned by an {@link ApprovalPolicy}. */
20
+ export type ApprovalStatus = undefined | boolean | "not-applicable" | "approved" | "denied" | "user-approval" | {
21
+ readonly type: "not-applicable";
22
+ readonly reason?: never;
23
+ } | {
24
+ readonly type: "approved";
25
+ readonly reason?: string;
26
+ } | {
27
+ readonly type: "denied";
28
+ readonly reason?: string;
29
+ } | {
30
+ readonly type: "user-approval";
31
+ readonly reason?: never;
32
+ };
33
+ /** Request-time approval policy shared by authored tools and connections. */
34
+ export type ApprovalPolicy<TInput = Record<string, unknown>> = (ctx: ApprovalContext<TInput>) => ApprovalStatus | Promise<ApprovalStatus>;
35
+ /** Stable tool request passed to a response authorizer. */
36
+ export interface ApprovalRequest<TInput = Record<string, unknown>> {
37
+ readonly callId: string;
38
+ readonly requestId: string;
39
+ readonly toolInput?: ApprovalToolInput<TInput>;
40
+ readonly toolName: string;
41
+ }
42
+ /** Read-only session identity and lineage available to a response authorizer. */
43
+ export interface ApprovalResponseSession {
44
+ readonly id: string;
45
+ readonly initiator: SessionAuthContext | null;
46
+ readonly parent?: SessionParent;
47
+ readonly turn: SessionTurn;
48
+ }
49
+ /** Narrow authorization capability available while validating a responder. */
50
+ export interface ApprovalResponseAuth {
51
+ getToken(provider: ToolAuthProvider, options?: ToolAuthOptions): Promise<TokenResult>;
52
+ requireAuth(provider: ToolAuthProvider, options?: ToolAuthOptions): never;
53
+ }
54
+ /** Submitted decision passed to an approval response policy. */
55
+ export interface ApprovalResponse {
56
+ readonly decision: "approve";
57
+ }
58
+ /** Context passed to an approval response policy. */
59
+ export interface ApprovalResponseContext<TInput = Record<string, unknown>> {
60
+ readonly auth: ApprovalResponseAuth;
61
+ readonly request: ApprovalRequest<TInput>;
62
+ readonly response: ApprovalResponse;
63
+ readonly responder: SessionAuthContext;
64
+ readonly session: ApprovalResponseSession;
65
+ }
66
+ /** Response policy decision. Rejection keeps the shared request pending. */
67
+ export type ApprovalResponseDecision = {
68
+ readonly status: "allowed";
69
+ } | {
70
+ readonly reason: string;
71
+ readonly status: "rejected";
72
+ };
73
+ /** Decides whether an authenticated responder may approve one request. */
74
+ export type ApprovalResponsePolicy<TInput = Record<string, unknown>> = (ctx: ApprovalResponseContext<TInput>) => ApprovalResponseDecision | Promise<ApprovalResponseDecision>;
75
+ /** Approval definition with request- and response-time policy. */
76
+ export interface ApprovalConfiguration<TInput = Record<string, unknown>> {
77
+ readonly request: ApprovalPolicy<TInput>;
78
+ readonly response?: ApprovalResponsePolicy<TInput>;
79
+ }
80
+ /** Shared approval definition used by authored tools and connections. */
81
+ export type Approval<TInput = Record<string, unknown>> = ApprovalPolicy<TInput> | ApprovalConfiguration<TInput>;
82
+ /** Returns the request-time policy from either approval authoring shape. */
83
+ export declare function resolveApprovalPolicy<TInput>(approval: Approval<TInput>): ApprovalPolicy<TInput>;
84
+ export {};
@@ -0,0 +1 @@
1
+ function resolveApprovalPolicy(e){return typeof e==`function`?e:e.request}export{resolveApprovalPolicy};
@@ -1,4 +1,4 @@
1
- import type { ResolvedHttpBasicAuthStrategy, RouteStrategyAuthenticationResult } from "#runtime/governance/auth/types.js";
1
+ import type { ResolvedHttpBasicAuthStrategy, RouteStrategyAuthenticationResult } from "#channel/auth/types.js";
2
2
  /**
3
3
  * Verifies one HTTP Basic credential against a resolved eve strategy.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { ResolvedJwtEcdsaAuthStrategy, RouteStrategyAuthenticationResult } from "#runtime/governance/auth/types.js";
1
+ import type { ResolvedJwtEcdsaAuthStrategy, RouteStrategyAuthenticationResult } from "#channel/auth/types.js";
2
2
  /**
3
3
  * Verifies one bearer token against a resolved ECDSA JWT strategy.
4
4
  */
@@ -0,0 +1 @@
1
+ import{importJWK,importSPKI,jwtVerify}from"#compiled/jose/index.js";import{areTokenClaimMatchersSatisfied,createJwtAuthenticatedCallerPrincipal}from"#channel/auth/token-claims.js";const importedJwtPublicKeyCache=new Map;async function authenticateJwtEcdsaStrategy(e){let t;try{t=await getImportedJwtPublicKey(e.strategy)}catch(e){return{kind:`misconfigured`,message:`Failed to import JWT ECDSA public key. ${e instanceof Error?e.message:`Unknown key import failure.`}`}}try{let a=await jwtVerify(e.token,t,{algorithms:[e.strategy.algorithm],audience:[...e.strategy.audiences],clockTolerance:e.strategy.clockSkewSeconds,issuer:e.strategy.issuer});return typeof a.payload.sub!=`string`||a.payload.sub.length===0?{kind:`not-authenticated`}:areTokenClaimMatchersSatisfied(a.payload,e.strategy)?{kind:`authenticated`,principal:createJwtAuthenticatedCallerPrincipal({authenticator:`jwt-ecdsa`,payload:a.payload,principalType:`service`})}:{kind:`caller-not-allowed`}}catch{return{kind:`not-authenticated`}}}async function getImportedJwtPublicKey(e){let t=`${e.algorithm}:${e.publicKey}`,n=importedJwtPublicKeyCache.get(t);if(n!==void 0)return await n;let r=importJwtPublicKey(e.publicKey,e.algorithm).catch(e=>{throw importedJwtPublicKeyCache.delete(t),e});return importedJwtPublicKeyCache.set(t,r),await r}async function importJwtPublicKey(n,r){let i=n.trim();return i.startsWith(`{`)?await importJWK(JSON.parse(i),r):await importSPKI(i,r)}export{authenticateJwtEcdsaStrategy};
@@ -1,4 +1,4 @@
1
- import type { ResolvedJwtHmacAuthStrategy, RouteStrategyAuthenticationResult } from "#runtime/governance/auth/types.js";
1
+ import type { ResolvedJwtHmacAuthStrategy, RouteStrategyAuthenticationResult } from "#channel/auth/types.js";
2
2
  /**
3
3
  * Verifies one bearer token against a resolved HMAC JWT strategy.
4
4
  */
@@ -0,0 +1 @@
1
+ import{createSecretKey}from"node:crypto";import{jwtVerify}from"#compiled/jose/index.js";import{areTokenClaimMatchersSatisfied,createJwtAuthenticatedCallerPrincipal}from"#channel/auth/token-claims.js";async function authenticateJwtHmacStrategy(e){try{let t=await jwtVerify(e.token,createSecretKey(Buffer.from(e.strategy.secret,`utf8`)),{algorithms:[e.strategy.algorithm],audience:[...e.strategy.audiences],clockTolerance:e.strategy.clockSkewSeconds,issuer:e.strategy.issuer});return typeof t.payload.sub!=`string`||t.payload.sub.length===0?{kind:`not-authenticated`}:areTokenClaimMatchersSatisfied(t.payload,e.strategy)?{kind:`authenticated`,principal:createJwtAuthenticatedCallerPrincipal({authenticator:`jwt-hmac`,payload:t.payload,principalType:`service`})}:{kind:`caller-not-allowed`}}catch{return{kind:`not-authenticated`}}}export{authenticateJwtHmacStrategy};
@@ -1,4 +1,4 @@
1
- import type { ResolvedOidcAuthStrategy, RouteStrategyAuthenticationResult } from "#runtime/governance/auth/types.js";
1
+ import type { ResolvedOidcAuthStrategy, RouteStrategyAuthenticationResult } from "#channel/auth/types.js";
2
2
  /**
3
3
  * Verifies one bearer token against a resolved OIDC strategy.
4
4
  */
@@ -0,0 +1 @@
1
+ import{createRemoteJWKSet,jwtVerify}from"#compiled/jose/index.js";import{areTokenClaimMatchersSatisfied,createJwtAuthenticatedCallerPrincipal}from"#channel/auth/token-claims.js";import{z}from"#compiled/zod/index.js";import{isVercelOidcIssuer}from"#shared/vercel-project.js";const oidcDiscoveryDocumentSchema=z.object({issuer:z.string().optional(),jwks_uri:z.string().url()}).passthrough(),oidcDiscoveryDocumentCache=new Map,oidcJwksCache=new Map;async function authenticateOidcStrategy(e){let i;try{i=await getOidcRemoteJwks(e.strategy)}catch(e){return{kind:`misconfigured`,message:`Failed to load OIDC discovery metadata. ${e instanceof Error?e.message:`Unknown discovery failure.`}`}}try{let a=await jwtVerify(e.token,i,{audience:[...e.strategy.audiences],clockTolerance:e.strategy.clockSkewSeconds,issuer:e.strategy.issuer});if(e.strategy.acceptCurrentVercelProject&&isVercelOidcIssuer(e.strategy.issuer)&&a.payload.external_sub!==void 0)return typeof a.payload.external_sub!=`string`||a.payload.external_sub.length===0||!currentVercelProjectMatches({payload:a.payload,strategy:e.strategy})||!currentVercelEnvironmentMatches({payload:a.payload,strategy:e.strategy})?{kind:`caller-not-allowed`}:{kind:`authenticated`,principal:createJwtAuthenticatedCallerPrincipal({authenticator:`oidc`,issuerClaims:[`external_iss`,`connector_id`],payload:a.payload,principalType:`user`,subjectClaim:`external_sub`})};if(e.strategy.acceptCurrentVercelProject&&isVercelOidcIssuer(e.strategy.issuer)&&a.payload.user_id!==void 0){if(typeof a.payload.user_id!=`string`||a.payload.user_id.length===0||a.payload.environment!==`development`||!currentVercelProjectMatches({payload:a.payload,strategy:e.strategy}))return{kind:`caller-not-allowed`};if(currentVercelEnvironmentMatches({payload:a.payload,strategy:e.strategy}))return{kind:`authenticated`,principal:createJwtAuthenticatedCallerPrincipal({authenticator:`oidc`,payload:a.payload,principalType:`user`,subjectClaim:`user_id`})}}if(typeof a.payload.sub!=`string`||a.payload.sub.length===0)return{kind:`not-authenticated`};let o=e.strategy.acceptCurrentVercelProject&&isCurrentVercelProjectToken({issuer:e.strategy.issuer,payload:a.payload,strategy:e.strategy}),s=o&&isCurrentVercelEnvironmentToken({payload:a.payload,strategy:e.strategy});return!o&&!areTokenClaimMatchersSatisfied(a.payload,e.strategy)?{kind:`caller-not-allowed`}:{kind:`authenticated`,principal:createJwtAuthenticatedCallerPrincipal({authenticator:`oidc`,payload:a.payload,principalType:s?`runtime`:`service`})}}catch{return{kind:`not-authenticated`}}}async function getOidcRemoteJwks(t){let n=await getOidcDiscoveryDocument(t.discoveryUrl),r=oidcJwksCache.get(n.jwks_uri);if(r!==void 0)return r;let i=createRemoteJWKSet(new URL(n.jwks_uri));return oidcJwksCache.set(n.jwks_uri,i),i}async function getOidcDiscoveryDocument(e){let t=oidcDiscoveryDocumentCache.get(e);if(t!==void 0)return await t;let n=fetch(e,{headers:{accept:`application/json`}}).then(async e=>{if(!e.ok)throw Error(`Discovery route returned HTTP ${e.status}.`);return oidcDiscoveryDocumentSchema.parse(await e.json())}).catch(t=>{throw oidcDiscoveryDocumentCache.delete(e),t});return oidcDiscoveryDocumentCache.set(e,n),await n}function isCurrentVercelProjectToken(e){if(!isVercelOidcIssuer(e.issuer))return!1;let t=e.strategy.currentVercelProject;return t!==void 0&&typeof e.payload.project_id==`string`&&e.payload.project_id===t.projectId}function currentVercelProjectMatches(e){let t=e.strategy.currentVercelProject;return t!==void 0&&typeof e.payload.project_id==`string`&&e.payload.project_id===t.projectId}function isCurrentVercelEnvironmentToken(e){let t=e.strategy.currentVercelProject?.environment;return t===void 0||t.length===0?!1:typeof e.payload.environment==`string`&&e.payload.environment===t}function currentVercelEnvironmentMatches(e){let t=e.strategy.currentVercelProject?.environment;return t===void 0||t.length===0?!1:typeof e.payload.environment==`string`&&e.payload.environment===t}export{authenticateOidcStrategy};
@@ -1,5 +1,5 @@
1
1
  import type { JWTPayload } from "#compiled/jose/index.js";
2
- import type { AuthenticatedCallerPrincipal, ResolvedTokenClaimMatchers } from "#runtime/governance/auth/types.js";
2
+ import type { AuthenticatedCallerPrincipal, ResolvedTokenClaimMatchers } from "#channel/auth/types.js";
3
3
  /**
4
4
  * Returns whether the verified JWT payload satisfies the authored subject and
5
5
  * claim selectors.
@@ -1,4 +1,4 @@
1
- import type { RuntimeSessionAuthAttributes, RuntimeSessionAuthContext, RuntimeSessionAuthenticator, RuntimeSessionPrincipalType } from "#runtime/sessions/auth.js";
1
+ import type { RuntimeSessionAuthAttributes, RuntimeSessionAuthContext, RuntimeSessionAuthenticator, RuntimeSessionPrincipalType } from "#shared/session-auth.js";
2
2
  /**
3
3
  * Shared serializable token-claim projection used by auth verifiers.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { CurrentVercelProject } from "#runtime/governance/auth/types.js";
1
+ import type { CurrentVercelProject } from "#channel/auth/types.js";
2
2
  type VercelOidcProjectResolver = () => CurrentVercelProject | undefined | Promise<CurrentVercelProject | undefined>;
3
3
  /**
4
4
  * Binds the current local project only to one request. The global symbol makes
@@ -5,7 +5,7 @@ import { type ChannelAddressDeliveryOptions } from "#channel/channel-address.js"
5
5
  import type { SendPayload } from "#channel/routes.js";
6
6
  import type { Session } from "#channel/session.js";
7
7
  import type { CancelTurnResult, ClearSessionResult, CompactSessionResult, ResetSessionResult, Runtime, SessionAuthContext, SessionCallback, TurnPolicy } from "#channel/types.js";
8
- import { type InputResponse, type StrictInputResponses } from "#runtime/input/types.js";
8
+ import { type InputResponse, type StrictInputResponses } from "#shared/input.js";
9
9
  import type { JsonObject } from "#shared/json.js";
10
10
  import type { RunMode } from "#shared/run-mode.js";
11
11
  interface BaseChannelSendOptions {
@@ -1 +1 @@
1
- import{createChannelAddressFn}from"#channel/channel-address.js";import{parseInputResponses}from"#runtime/input/types.js";const INTERNAL_CHANNEL_DELIVER=Symbol(`eve.internal.channel-deliver`);function createChannelOperations(r){let i=createChannelAddressFn(r);return{from(e){let r=i(e);return{async send(e,t){return await r.deliver({context:t.context,message:e,outputSchema:t.outputSchema},t)},async respond(e,n){if(e.length===0)throw Error(`respond() requires at least one input response.`);let i=parseInputResponses(e);return await r.deliver({context:n.context,inputResponses:i,outputSchema:n.outputSchema,state:n.state},n)},async cancel(e){return await r.cancel(e)},async compact(){return await r.compact()},async clear(){return await r.clear()},async reset(e){return await r.reset(e)},async[INTERNAL_CHANNEL_DELIVER](e,t){return await r.deliver(e,t)}}},async resolveSession(e){return await i(e).resolveSession()}}}export{INTERNAL_CHANNEL_DELIVER,createChannelOperations};
1
+ import{createChannelAddressFn}from"#channel/channel-address.js";import{parseInputResponses}from"#shared/input.js";const INTERNAL_CHANNEL_DELIVER=Symbol(`eve.internal.channel-deliver`);function createChannelOperations(r){let i=createChannelAddressFn(r);return{from(e){let r=i(e);return{async send(e,t){return await r.deliver({context:t.context,message:e,outputSchema:t.outputSchema},t)},async respond(e,n){if(e.length===0)throw Error(`respond() requires at least one input response.`);let i=parseInputResponses(e);return await r.deliver({context:n.context,inputResponses:i,outputSchema:n.outputSchema,state:n.state},n)},async cancel(e){return await r.cancel(e)},async compact(){return await r.compact()},async clear(){return await r.clear()},async reset(e){return await r.reset(e)},async[INTERNAL_CHANNEL_DELIVER](e,t){return await r.deliver(e,t)}}},async resolveSession(e){return await i(e).resolveSession()}}}export{INTERNAL_CHANNEL_DELIVER,createChannelOperations};
@@ -1,5 +1,6 @@
1
1
  import type { ChannelAdapter, ChannelInstrumentationMetadata } from "#channel/adapter.js";
2
2
  export interface ChannelInstrumentationProjection {
3
+ readonly channelType?: string;
3
4
  readonly kind: string;
4
5
  readonly metadata: ChannelInstrumentationMetadata;
5
6
  }
@@ -1 +1 @@
1
- import{createLogger}from"#internal/logging.js";import{getAdapterKind}from"#channel/adapter.js";import{isInstrumentationChannelKind,resolveInstrumentationProjection}from"#internal/instrumentation.js";import{normalizeChannelAudience}from"#shared/channel-audience.js";const log=createLogger(`channel.instrumentation`);function buildChannelInstrumentationProjection(e){let{adapter:t,channelName:n,existingKind:r}=e;return{kind:resolveKind({adapter:t,channelName:n,existingKind:r}),metadata:resolveMetadata(t)}}function resolveKind(e){let{adapter:r,channelName:i,existingKind:a}=e;if(a!==void 0)return a;if(i!==void 0&&i.length>0)return`channel:${i}`;let o=getAdapterKind(r);return isInstrumentationChannelKind(o)?o:`channel:${o}`}function resolveMetadata(e){let n=e.instrumentation?.metadata;if(n===void 0)return{audience:`unknown`};let o=resolveInstrumentationProjection({invoke:()=>n(e.state),log,source:getAdapterKind(e)});return{...o,audience:normalizeChannelAudience(o?.audience)}}export{buildChannelInstrumentationProjection};
1
+ import{createLogger}from"#internal/logging.js";import{getAdapterKind}from"#channel/adapter.js";import{isInstrumentationChannelKind,resolveInstrumentationProjection}from"#internal/instrumentation.js";import{normalizeChannelAudience}from"#shared/channel-audience.js";const log=createLogger(`channel.instrumentation`);function buildChannelInstrumentationProjection(e){let{adapter:t,channelName:n,existingKind:r}=e;return{channelType:getAdapterKind(t),kind:resolveKind({adapter:t,channelName:n,existingKind:r}),metadata:resolveMetadata(t)}}function resolveKind(e){let{adapter:n,channelName:r,existingKind:i}=e;if(i!==void 0)return i;if(r!==void 0&&r.length>0)return`channel:${r}`;let a=getAdapterKind(n);return isInstrumentationChannelKind(a)?a:`channel:${a}`}function resolveMetadata(e){let t=e.instrumentation?.metadata;if(t===void 0)return{audience:`unknown`};let a=resolveInstrumentationProjection({invoke:()=>t(e.state),log,source:getAdapterKind(e)});return{...a,audience:normalizeChannelAudience(a?.audience)}}export{buildChannelInstrumentationProjection};
@@ -1,4 +1,4 @@
1
- import type { InputRequest, InputResponse } from "#runtime/input/types.js";
1
+ import type { InputRequest, InputResponse } from "#shared/input.js";
2
2
  /**
3
3
  * Maps freeform text to an {@link InputResponse} for a single request.
4
4
  *
@@ -1,7 +1,7 @@
1
1
  import type { UserContent } from "ai";
2
2
  import type { CrossChannelToFn } from "#channel/cross-channel-receive.js";
3
3
  import type { ChannelFrom, ChannelResolveSession } from "#channel/channel-operations.js";
4
- import type { InputResponse } from "#runtime/input/types.js";
4
+ import type { InputResponse } from "#shared/input.js";
5
5
  import type { Session } from "#channel/session.js";
6
6
  import type { JsonObject } from "#shared/json.js";
7
7
  import type { ChannelMethod } from "#public/definitions/channel.js";
@@ -4,7 +4,7 @@ import type { MessageStreamEvent } from "#protocol/message.js";
4
4
  import type { UserContent } from "ai";
5
5
  import type { CancelTurnResult, ClearSessionResult, CompactSessionResult, ResetSessionResult, Runtime, SessionAuthContext, SessionCallback, SessionSendCommandResult, TurnPolicy, TurnCaller } from "#channel/types.js";
6
6
  import type { SessionAuth } from "#context/keys.js";
7
- import { type InputResponse, type StrictInputResponses } from "#runtime/input/types.js";
7
+ import { type InputResponse, type StrictInputResponses } from "#shared/input.js";
8
8
  import type { JsonObject } from "#shared/json.js";
9
9
  /** Immutable-ID handle for one exact durable session. */
10
10
  export interface Session {
@@ -1 +1 @@
1
- import{createChannelDeliveryMetadata}from"#channel/delivery-metadata.js";import{serializeUrlFilePartsInMessage}from"#channel/send-input.js";import{DEFAULT_TURN_POLICY}from"#channel/types.js";import{parseInputResponses}from"#runtime/input/types.js";import{AuthKey,ContinuationTokenKey,InitiatorAuthKey,SessionIdKey}from"#context/keys.js";import{toChannelLocalContinuationToken}from"#shared/continuation-token.js";function createSession(e,i,a={}){return{id:e,async send(r,o){let s=createDelivery(a),c=sessionCallbackToTurnCaller(o.callback),l={message:serializeUrlFilePartsInMessage(r)};o.context!==void 0&&(l.context=o.context),o.outputSchema!==void 0&&(l.outputSchema=o.outputSchema);let u={auth:o.auth,delivery:s,kind:`send`,payload:l,requestId:a.requestId,turnPolicy:o.turnPolicy??a.turnPolicy??DEFAULT_TURN_POLICY};return await i.dispatchSession({command:c===void 0?u:{...u,caller:c},sessionId:e})},async respond(t,n){if(t.length===0)throw Error(`respond() requires at least one input response.`);let o=parseInputResponses(t),s=sessionCallbackToTurnCaller(n.callback),c=createDelivery(a),l={inputResponses:o};n.context!==void 0&&(l.context=n.context),n.outputSchema!==void 0&&(l.outputSchema=n.outputSchema);let u={auth:n.auth,delivery:c,kind:`send`,payload:l,requestId:a.requestId};return await i.dispatchSession({command:s===void 0?u:{...u,caller:s},sessionId:e})},async cancel(t){return await i.dispatchSession({command:{kind:`cancel`,taskId:t?.taskId,turnId:t?.turnId},sessionId:e})},async compact(){return await i.dispatchSession({command:{kind:`compact`},sessionId:e})},async clear(){return await i.dispatchSession({command:{kind:`clear`},sessionId:e})},async reset(t){return await i.dispatchSession({command:{kind:`reset`,reason:t?.reason},sessionId:e})},async getEventStream(t){return i.getEventStream(e,t)},async getStreamTailIndex(){return i.getStreamTailIndex(e)}}}function createAttachSessionFn(e,t={}){return n=>createSession(n,e,t)}function createDelivery(t){return t.channelKind!==void 0&&t.channelName!==void 0?createChannelDeliveryMetadata(t):void 0}function buildSessionHandle(e){return{get id(){return e.get(SessionIdKey)??``},get auth(){return{current:e.get(AuthKey)??null,initiator:e.get(InitiatorAuthKey)??null}},get continuation(){let t=e.get(ContinuationTokenKey);if(!(t===void 0||t.length===0))return{token:toChannelLocalContinuationToken(t),rekey(n){let r=namespaceContinuationToken(t,n);t!==r&&e.set(ContinuationTokenKey,r)}}}}}function namespaceContinuationToken(e,t){let n=e.indexOf(`:`);if(n<=0)throw Error(`Cannot set session continuation token without an existing namespaced continuation token. Start the session with a placeholder continuationToken.`);return`${e.slice(0,n+1)}${t}`}function sessionCallbackToTurnCaller(e){return e===void 0?void 0:{callId:e.callId,replyTo:{kind:`callback`,token:e.token,url:e.url},subagentName:e.subagentName,taskId:e.taskId}}export{buildSessionHandle,createAttachSessionFn,createSession,sessionCallbackToTurnCaller};
1
+ import{createChannelDeliveryMetadata}from"#channel/delivery-metadata.js";import{serializeUrlFilePartsInMessage}from"#channel/send-input.js";import{DEFAULT_TURN_POLICY}from"#channel/types.js";import{parseInputResponses}from"#shared/input.js";import{AuthKey,ContinuationTokenKey,InitiatorAuthKey,SessionIdKey}from"#context/keys.js";import{toChannelLocalContinuationToken}from"#shared/continuation-token.js";function createSession(e,i,a={}){return{id:e,async send(r,o){let s=createDelivery(a),c=sessionCallbackToTurnCaller(o.callback),l={message:serializeUrlFilePartsInMessage(r)};o.context!==void 0&&(l.context=o.context),o.outputSchema!==void 0&&(l.outputSchema=o.outputSchema);let u={auth:o.auth,delivery:s,kind:`send`,payload:l,requestId:a.requestId,turnPolicy:o.turnPolicy??a.turnPolicy??DEFAULT_TURN_POLICY};return await i.dispatchSession({command:c===void 0?u:{...u,caller:c},sessionId:e})},async respond(t,n){if(t.length===0)throw Error(`respond() requires at least one input response.`);let o=parseInputResponses(t),s=sessionCallbackToTurnCaller(n.callback),c=createDelivery(a),l={inputResponses:o};n.context!==void 0&&(l.context=n.context),n.outputSchema!==void 0&&(l.outputSchema=n.outputSchema);let u={auth:n.auth,delivery:c,kind:`send`,payload:l,requestId:a.requestId};return await i.dispatchSession({command:s===void 0?u:{...u,caller:s},sessionId:e})},async cancel(t){return await i.dispatchSession({command:{kind:`cancel`,taskId:t?.taskId,turnId:t?.turnId},sessionId:e})},async compact(){return await i.dispatchSession({command:{kind:`compact`},sessionId:e})},async clear(){return await i.dispatchSession({command:{kind:`clear`},sessionId:e})},async reset(t){return await i.dispatchSession({command:{kind:`reset`,reason:t?.reason},sessionId:e})},async getEventStream(t){return i.getEventStream(e,t)},async getStreamTailIndex(){return i.getStreamTailIndex(e)}}}function createAttachSessionFn(e,t={}){return n=>createSession(n,e,t)}function createDelivery(t){return t.channelKind!==void 0&&t.channelName!==void 0?createChannelDeliveryMetadata(t):void 0}function buildSessionHandle(e){return{get id(){return e.get(SessionIdKey)??``},get auth(){return{current:e.get(AuthKey)??null,initiator:e.get(InitiatorAuthKey)??null}},get continuation(){let t=e.get(ContinuationTokenKey);if(!(t===void 0||t.length===0))return{token:toChannelLocalContinuationToken(t),rekey(n){let r=namespaceContinuationToken(t,n);t!==r&&e.set(ContinuationTokenKey,r)}}}}}function namespaceContinuationToken(e,t){let n=e.indexOf(`:`);if(n<=0)throw Error(`Cannot set session continuation token without an existing namespaced continuation token. Start the session with a placeholder continuationToken.`);return`${e.slice(0,n+1)}${t}`}function sessionCallbackToTurnCaller(e){return e===void 0?void 0:{callId:e.callId,replyTo:{kind:`callback`,token:e.token,url:e.url},subagentName:e.subagentName,taskId:e.taskId}}export{buildSessionHandle,createAttachSessionFn,createSession,sessionCallbackToTurnCaller};
@@ -2,8 +2,8 @@ import type { UserContent } from "ai";
2
2
  import type { MessageStreamEvent, UnstampedMessageStreamEvent } from "#protocol/message.js";
3
3
  import type { CancelTurnResult as ProtocolCancelTurnResult } from "#protocol/cancel-turn.js";
4
4
  import type { RunMode } from "#shared/run-mode.js";
5
- import type { RuntimeSubagentChildResult } from "#runtime/actions/types.js";
6
- import type { InputRequest, InputResponse } from "#runtime/input/types.js";
5
+ import type { RuntimeSubagentChildResult } from "#shared/action-types.js";
6
+ import type { InputRequest, InputResponse } from "#shared/input.js";
7
7
  import type { ChannelAdapter } from "#channel/adapter.js";
8
8
  import type { AgentLimitsDefinition } from "#shared/agent-definition.js";
9
9
  import type { JsonObject } from "#shared/json.js";