eve 0.65.0 → 0.66.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 (748) hide show
  1. package/CHANGELOG.md +40 -0
  2. package/README.md +1 -2
  3. package/dist/src/_virtual/_rolldown/runtime.js +1 -1
  4. package/dist/src/channel/forwarded-principal.d.ts +26 -6
  5. package/dist/src/channel/forwarded-principal.js +1 -1
  6. package/dist/src/chunks/{use-eve-agent-BIouJCii.js → use-eve-agent-Di1u2zKu.js} +266 -5
  7. package/dist/src/chunks/{use-eve-agent-BRvEh9sO.js → use-eve-agent-PbSMyJ6e.js} +266 -5
  8. package/dist/src/cli/commands/extension-build.js +1 -1
  9. package/dist/src/cli/commands/registry-project.d.ts +2 -1
  10. package/dist/src/cli/commands/registry-project.js +2 -2
  11. package/dist/src/cli/commands/registry.js +1 -1
  12. package/dist/src/cli/commands/trace-detail.d.ts +5 -25
  13. package/dist/src/cli/commands/trace-detail.js +1 -1
  14. package/dist/src/cli/commands/trace.js +2 -2
  15. package/dist/src/cli/dev/run-interactive-ui.js +1 -1
  16. package/dist/src/cli/dev/tui/argument-typeahead.d.ts +36 -0
  17. package/dist/src/cli/dev/tui/argument-typeahead.js +2 -0
  18. package/dist/src/cli/dev/tui/blocks.js +1 -1
  19. package/dist/src/cli/dev/tui/prompt-command-handler.js +1 -1
  20. package/dist/src/cli/dev/tui/prompt-commands.js +1 -1
  21. package/dist/src/cli/dev/tui/registry-result-message.js +1 -1
  22. package/dist/src/cli/dev/tui/runner.d.ts +3 -0
  23. package/dist/src/cli/dev/tui/runner.js +1 -1
  24. package/dist/src/cli/dev/tui/setup-commands.d.ts +5 -9
  25. package/dist/src/cli/dev/tui/setup-commands.js +1 -2
  26. package/dist/src/cli/dev/tui/setup-flow.d.ts +0 -3
  27. package/dist/src/cli/dev/tui/setup-panel.d.ts +14 -0
  28. package/dist/src/cli/dev/tui/setup-panel.js +4 -4
  29. package/dist/src/cli/dev/tui/subagent-pump.d.ts +2 -10
  30. package/dist/src/cli/dev/tui/subagent-pump.js +1 -1
  31. package/dist/src/cli/dev/tui/terminal-renderer.d.ts +3 -0
  32. package/dist/src/cli/dev/tui/terminal-renderer.js +10 -11
  33. package/dist/src/cli/dev/tui/test/fake-setup-flow-renderer.js +1 -1
  34. package/dist/src/cli/dev/tui/traces/trace-conversation.js +1 -1
  35. package/dist/src/cli/dev/tui/tui.js +1 -1
  36. package/dist/src/cli/dev/tui/vercel-trusted-sources-policy.d.ts +1 -1
  37. package/dist/src/cli/dev/tui/vercel-trusted-sources.js +1 -1
  38. package/dist/src/cli/invoke/result.d.ts +1 -1
  39. package/dist/src/cli/invoke/result.js +1 -1
  40. package/dist/src/cli/telemetry/preference.js +1 -1
  41. package/dist/src/client/client-error.js +1 -1
  42. package/dist/src/client/index.d.ts +1 -3
  43. package/dist/src/client/index.js +1 -1
  44. package/dist/src/client/open-stream.d.ts +3 -2
  45. package/dist/src/client/open-stream.js +1 -1
  46. package/dist/src/client/session.d.ts +16 -1
  47. package/dist/src/client/session.js +1 -1
  48. package/dist/src/compiled/.vendor-stamp.json +4 -2
  49. package/dist/src/compiled/@agentclientprotocol/sdk/index.js +2 -51
  50. package/dist/src/compiled/@ai-sdk/anthropic/index.js +2 -2
  51. package/dist/src/compiled/@ai-sdk/google/index.js +7 -7
  52. package/dist/src/compiled/@ai-sdk/mcp/index.js +1 -1
  53. package/dist/src/compiled/@ai-sdk/openai/index.js +4 -4
  54. package/dist/src/compiled/@ai-sdk/otel/index.js +1 -1
  55. package/dist/src/compiled/@cfworker/json-schema/index.d.ts +18 -0
  56. package/dist/src/compiled/@cfworker/json-schema/index.js +2 -0
  57. package/dist/src/compiled/@modelcontextprotocol/server/index.js +9 -58
  58. package/dist/src/compiled/@opentelemetry/api/index.js +1 -1
  59. package/dist/src/compiled/@opentelemetry/otlp-transformer/index.js +1 -1
  60. package/dist/src/compiled/@photon-ai/chat-adapter-imessage/index.js +55 -55
  61. package/dist/src/compiled/@vercel/blob/index.js +14 -36
  62. package/dist/src/compiled/@vercel/oidc/index.js +6 -28
  63. package/dist/src/compiled/@vercel/otel/index.js +1 -1
  64. package/dist/src/compiled/@vercel/sandbox/index.js +13 -13
  65. package/dist/src/compiled/@vercel/sdk/LICENSE +201 -0
  66. package/dist/src/compiled/@vercel/sdk/index.d.ts +41 -0
  67. package/dist/src/compiled/@vercel/sdk/index.js +1 -0
  68. package/dist/src/compiled/@workflow/core/index.js +1 -1
  69. package/dist/src/compiled/@workflow/core/private.js +1 -1
  70. package/dist/src/compiled/@workflow/core/runtime/helpers.js +1 -1
  71. package/dist/src/compiled/@workflow/core/runtime.js +2 -2
  72. package/dist/src/compiled/@workflow/core/serialization.js +1 -1
  73. package/dist/src/compiled/@workflow/core/workflow.js +1 -1
  74. package/dist/src/compiled/@workflow/errors/index.js +1 -1
  75. package/dist/src/compiled/@workflow/world-local/index.js +5 -5
  76. package/dist/src/compiled/@workflow/world-vercel/index.js +16 -16
  77. package/dist/src/compiled/_chunks/client/core-CspsxXR-.js +52 -0
  78. package/dist/src/compiled/_chunks/client/rolldown-runtime-DK3Fl9T5.js +1 -0
  79. package/dist/src/compiled/_chunks/node/auth-Dztlx9pE.js +2 -0
  80. package/dist/src/compiled/_chunks/workflow/{attribute-changes-DFx4eluc.js → attribute-changes-89Nwz7XW.js} +1 -1
  81. package/dist/src/compiled/_chunks/workflow/{chunk-5MU5Z6L3-CrYztnvh.js → chunk-5MU5Z6L3-z9-dfnHp.js} +1 -1
  82. package/dist/src/compiled/_chunks/workflow/{chunk-NWCAEW5Y-ClfmNvkQ.js → chunk-NWCAEW5Y-8afLJrun.js} +1 -1
  83. package/dist/src/compiled/_chunks/workflow/{dist-C3919PVU.js → dist-C3ZE62yI.js} +3 -3
  84. package/dist/src/compiled/_chunks/workflow/dist-CNT2vjZ4.js +1 -0
  85. package/dist/src/compiled/_chunks/workflow/{dist-xTushGCp.js → dist-DtXwQbZr.js} +1 -1
  86. package/dist/src/compiled/_chunks/workflow/{esm-DyLz8Egm.js → esm-DtrPCf49.js} +1 -1
  87. package/dist/src/compiled/_chunks/workflow/{experimental-evaluation-D8_K_Pe9.js → experimental-evaluation-Dm32egEG.js} +2 -2
  88. package/dist/src/compiled/_chunks/workflow/frames-DnrfSd1P.js +3 -0
  89. package/dist/src/compiled/_chunks/workflow/{functions-C06vHfWP.js → functions-DpZiBxgQ.js} +1 -1
  90. package/dist/src/compiled/_chunks/workflow/{getMachineId-bsd-WEBNKY2R-DcIEvZzd.js → getMachineId-bsd-WEBNKY2R-D5OkV-EY.js} +1 -1
  91. package/dist/src/compiled/_chunks/workflow/{getMachineId-darwin-LT47KAXP-C4nRhfn9.js → getMachineId-darwin-LT47KAXP-BqwKrkSO.js} +1 -1
  92. package/dist/src/compiled/_chunks/workflow/{getMachineId-linux-LTVQO6VW-BqQf2T4W.js → getMachineId-linux-LTVQO6VW-CJlbJ4KP.js} +1 -1
  93. package/dist/src/compiled/_chunks/workflow/{getMachineId-unsupported-UKWBA27G-oYffWhib.js → getMachineId-unsupported-UKWBA27G-C4Y3-LZG.js} +1 -1
  94. package/dist/src/compiled/_chunks/workflow/{getMachineId-win-NLJKOPY6-CpL96LtN.js → getMachineId-win-NLJKOPY6-CsPs71SE.js} +1 -1
  95. package/dist/src/compiled/_chunks/workflow/{global-DFW-hO6M.js → global-DIlFoH2w.js} +1 -1
  96. package/dist/src/compiled/_chunks/workflow/{helpers-Bw52uyzw.js → helpers-k3zcudWr.js} +1 -1
  97. package/dist/src/compiled/_chunks/workflow/{logger-DFNCa8Nl.js → logger-Bzc8jWWj.js} +1 -1
  98. package/dist/src/compiled/_chunks/workflow/resume-hook-BmJ263ZR.js +1 -0
  99. package/dist/src/compiled/_chunks/workflow/{rolldown-runtime-DPpTSio4.js → rolldown-runtime-B_knIduE.js} +1 -1
  100. package/dist/src/compiled/_chunks/workflow/{run-BT6SQv5f.js → run-NLvREued.js} +1 -1
  101. package/dist/src/compiled/_chunks/workflow/{serialization-Cl0SYU0I.js → serialization-HCDeQWcR.js} +2 -2
  102. package/dist/src/compiled/_chunks/workflow/{signal-exit-B9U6kH7R.js → signal-exit-DZKTacNU.js} +1 -1
  103. package/dist/src/compiled/_chunks/workflow/sleep-Bi508qmg.js +1 -0
  104. package/dist/src/compiled/_chunks/workflow/{token-CrFhCmWs.js → token-1wSBbi5N.js} +1 -1
  105. package/dist/src/compiled/_chunks/workflow/{token-U5XEWlVM.js → token-BhlnqoHM.js} +1 -1
  106. package/dist/src/compiled/_chunks/workflow/{token-util-BkqzD0OM.js → token-util-Cm4Ec1Bg.js} +1 -1
  107. package/dist/src/compiled/_chunks/workflow/token-util-DaeRTzDa.js +5 -0
  108. package/dist/src/compiled/_chunks/workflow/{wait-until-Dzhr6tzf.js → wait-until-DXLZx3tU.js} +1 -1
  109. package/dist/src/compiled/_chunks/workflow/{wrapper-CKui_eTd.js → wrapper-CzrF_dmI.js} +3 -3
  110. package/dist/src/compiled/_chunks/workflow/ws-transport-BSM_Cl7a.js +1 -0
  111. package/dist/src/compiled/jose/index.js +1 -1
  112. package/dist/src/compiled/zod/index.js +1 -51
  113. package/dist/src/compiled/zod/v3.js +1 -0
  114. package/dist/src/compiled/zod/v4/core.js +1 -0
  115. package/dist/src/compiled/zod-validation-error/index.js +1 -1
  116. package/dist/src/compiler/extension-compatibility.d.ts +20 -14
  117. package/dist/src/compiler/extension-compatibility.js +1 -1
  118. package/dist/src/context/build-base-tool-context.js +1 -1
  119. package/dist/src/context/build-callback-context.js +1 -1
  120. package/dist/src/context/dynamic-skill-lifecycle.d.ts +3 -3
  121. package/dist/src/context/dynamic-skill-lifecycle.js +1 -1
  122. package/dist/src/context/keys.d.ts +18 -4
  123. package/dist/src/context/keys.js +1 -1
  124. package/dist/src/context/session-context.d.ts +5 -4
  125. package/dist/src/evals/session.d.ts +3 -2
  126. package/dist/src/evals/session.js +1 -1
  127. package/dist/src/evals/types.d.ts +8 -2
  128. package/dist/src/eve-channel/index.js +1 -1
  129. package/dist/src/eve-channel/types.d.ts +12 -4
  130. package/dist/src/execution/cancel-indexed-session-tasks-step.js +1 -1
  131. package/dist/src/execution/dynamic-workflow/tool.js +1 -1
  132. package/dist/src/execution/proxied-deliver-step.js +1 -1
  133. package/dist/src/execution/route-child-delivery.js +2 -2
  134. package/dist/src/execution/sandbox/bindings/docker-templates.d.ts +6 -0
  135. package/dist/src/execution/sandbox/bindings/docker-templates.js +1 -1
  136. package/dist/src/execution/sandbox/bindings/docker.d.ts +6 -2
  137. package/dist/src/execution/sandbox/bindings/docker.js +1 -1
  138. package/dist/src/execution/sandbox/bindings/just-bash-runtime.d.ts +2 -2
  139. package/dist/src/execution/sandbox/bindings/just-bash.d.ts +2 -2
  140. package/dist/src/execution/sandbox/bindings/local-provider-utils.js +1 -1
  141. package/dist/src/execution/sandbox/bindings/microsandbox-lifecycle.d.ts +7 -2
  142. package/dist/src/execution/sandbox/bindings/microsandbox.d.ts +6 -2
  143. package/dist/src/execution/sandbox/bindings/vercel.d.ts +6 -3
  144. package/dist/src/execution/sandbox/bindings/vercel.js +1 -1
  145. package/dist/src/execution/sandbox/ensure.js +1 -1
  146. package/dist/src/execution/sandbox/logging-session.js +2 -2
  147. package/dist/src/execution/sandbox/provider-host.js +1 -1
  148. package/dist/src/execution/sandbox/session.d.ts +5 -2
  149. package/dist/src/execution/sandbox/session.js +1 -1
  150. package/dist/src/execution/session/admission.js +1 -1
  151. package/dist/src/execution/session/event-sink.d.ts +7 -13
  152. package/dist/src/execution/session/event-sink.js +1 -1
  153. package/dist/src/execution/session/finalization.js +1 -1
  154. package/dist/src/execution/session/handoff-steps.js +1 -1
  155. package/dist/src/execution/session/handoff.d.ts +2 -2
  156. package/dist/src/execution/session/handoff.js +1 -1
  157. package/dist/src/execution/session/input-queue.d.ts +12 -10
  158. package/dist/src/execution/session/input-queue.js +1 -1
  159. package/dist/src/execution/session/next-input.js +1 -1
  160. package/dist/src/execution/session/program.js +1 -1
  161. package/dist/src/execution/session/turn-step-result.d.ts +3 -1
  162. package/dist/src/execution/session/turn-step-result.js +1 -1
  163. package/dist/src/execution/session/turn-step-types.d.ts +7 -2
  164. package/dist/src/execution/session/turn-step.js +1 -1
  165. package/dist/src/execution/session/turn.js +1 -1
  166. package/dist/src/execution/settle-cancelled-turn-step.js +1 -1
  167. package/dist/src/execution/skills/instructions.d.ts +6 -8
  168. package/dist/src/execution/skills/instructions.js +2 -2
  169. package/dist/src/execution/tasks/parent/control-shared.js +1 -1
  170. package/dist/src/execution/tasks/parent/dispatch.js +1 -1
  171. package/dist/src/execution/tasks/parent/hitl-proxy-steps.d.ts +1 -0
  172. package/dist/src/execution/tasks/parent/hitl-proxy-steps.js +1 -1
  173. package/dist/src/execution/tasks/parent/tool-execution.js +1 -1
  174. package/dist/src/execution/tools/agent-router-workflow.js +1 -1
  175. package/dist/src/execution/tools/agent-router.d.ts +1 -2
  176. package/dist/src/execution/tools/agent-router.js +1 -1
  177. package/dist/src/execution/tools/ask-question-workflow.js +1 -1
  178. package/dist/src/execution/tools/ask-question.d.ts +17 -18
  179. package/dist/src/execution/tools/ask-question.js +2 -2
  180. package/dist/src/execution/tools/connection-search.js +1 -1
  181. package/dist/src/execution/tools/load-skill.d.ts +9 -5
  182. package/dist/src/execution/tools/load-skill.js +1 -1
  183. package/dist/src/execution/tools/sleep-workflow.js +1 -1
  184. package/dist/src/execution/tools/sleep.d.ts +8 -9
  185. package/dist/src/execution/tools/sleep.js +1 -1
  186. package/dist/src/execution/tools/subagent/accept-event-step.js +1 -1
  187. package/dist/src/execution/tools/subagent/emit-event-step.d.ts +2 -1
  188. package/dist/src/execution/tools/subagent/emit-event-step.js +1 -1
  189. package/dist/src/execution/tools/subagent/invoke-preparation.js +1 -1
  190. package/dist/src/execution/tools/subagent/invoke-step.js +1 -1
  191. package/dist/src/execution/tools/subagent/task-agent-requests.js +1 -1
  192. package/dist/src/execution/tools/subagent/task-cancel.d.ts +1 -1
  193. package/dist/src/execution/tools/subagent/task-cancel.js +1 -1
  194. package/dist/src/execution/tools/workflow/body.js +1 -1
  195. package/dist/src/extensions/code/extension/extension.d.ts +57 -0
  196. package/dist/src/extensions/code/extension/extension.js +1 -0
  197. package/dist/src/extensions/code/extension/hooks/authenticate.d.ts +2 -0
  198. package/dist/src/extensions/code/extension/hooks/authenticate.js +1 -0
  199. package/dist/src/extensions/code/extension/instructions.md +87 -0
  200. package/dist/src/extensions/code/extension/lib/command-failure.d.ts +7 -0
  201. package/dist/src/extensions/code/extension/lib/command-failure.js +2 -0
  202. package/dist/src/extensions/code/extension/lib/computer-use-driver-source.d.ts +14 -0
  203. package/dist/src/extensions/code/extension/lib/computer-use-driver-source.js +1309 -0
  204. package/dist/src/extensions/code/extension/lib/computer-use-sandbox.d.ts +9 -0
  205. package/dist/src/extensions/code/extension/lib/computer-use-sandbox.js +120 -0
  206. package/dist/src/extensions/code/extension/lib/computer-use.d.ts +36 -0
  207. package/dist/src/extensions/code/extension/lib/computer-use.js +78 -0
  208. package/dist/src/extensions/code/extension/lib/connect-authentication.d.ts +7 -0
  209. package/dist/src/extensions/code/extension/lib/connect-authentication.js +1 -0
  210. package/dist/src/extensions/code/extension/lib/credentials.d.ts +13 -0
  211. package/dist/src/extensions/code/extension/lib/credentials.js +3 -0
  212. package/dist/src/extensions/code/extension/lib/diagnostics.d.ts +30 -0
  213. package/dist/src/extensions/code/extension/lib/diagnostics.js +6 -0
  214. package/dist/src/extensions/code/extension/lib/generated-paths.d.ts +18 -0
  215. package/dist/src/extensions/code/extension/lib/generated-paths.js +2 -0
  216. package/dist/src/extensions/code/extension/lib/github-shell-schema.d.ts +11 -0
  217. package/dist/src/extensions/code/extension/lib/github-shell-schema.js +1 -0
  218. package/dist/src/extensions/code/extension/lib/github-shell.d.ts +53 -0
  219. package/dist/src/extensions/code/extension/lib/github-shell.js +1 -0
  220. package/dist/src/extensions/code/extension/lib/grep-search.d.ts +61 -0
  221. package/dist/src/extensions/code/extension/lib/grep-search.js +6 -0
  222. package/dist/src/extensions/code/extension/lib/guidelines.d.ts +25 -0
  223. package/dist/src/extensions/code/extension/lib/guidelines.js +2 -0
  224. package/dist/src/extensions/code/extension/lib/patch.d.ts +35 -0
  225. package/dist/src/extensions/code/extension/lib/patch.js +20 -0
  226. package/dist/src/extensions/code/extension/lib/prwatch-github.d.ts +70 -0
  227. package/dist/src/extensions/code/extension/lib/prwatch-github.js +1 -0
  228. package/dist/src/extensions/code/extension/lib/prwatch-registry.d.ts +27 -0
  229. package/dist/src/extensions/code/extension/lib/prwatch-registry.js +1 -0
  230. package/dist/src/extensions/code/extension/lib/prwatch.d.ts +2 -0
  231. package/dist/src/extensions/code/extension/lib/prwatch.js +1 -0
  232. package/dist/src/extensions/code/extension/lib/repository-root.d.ts +4 -0
  233. package/dist/src/extensions/code/extension/lib/repository-root.js +1 -0
  234. package/dist/src/extensions/code/extension/lib/sandbox.d.ts +12 -0
  235. package/dist/src/extensions/code/extension/lib/sandbox.js +2 -0
  236. package/dist/src/extensions/code/extension/lib/shell.d.ts +1 -0
  237. package/dist/src/extensions/code/extension/lib/shell.js +1 -0
  238. package/dist/src/extensions/code/extension/lib/signed-commit.d.ts +2 -0
  239. package/dist/src/extensions/code/extension/lib/signed-commit.js +130 -0
  240. package/dist/src/extensions/code/extension/lib/tooling.d.ts +27 -0
  241. package/dist/src/extensions/code/extension/lib/tooling.js +92 -0
  242. package/dist/src/extensions/code/extension/skills/investigate/SKILL.md +30 -0
  243. package/dist/src/extensions/code/extension/skills/lookup-agent-run/SKILL.md +29 -0
  244. package/dist/src/extensions/code/extension/skills/pr/SKILL.md +53 -0
  245. package/dist/src/extensions/code/extension/skills/review/SKILL.md +21 -0
  246. package/dist/src/extensions/code/extension/subagents/worker/agent.d.ts +17 -0
  247. package/dist/src/extensions/code/extension/subagents/worker/agent.js +1 -0
  248. package/dist/src/extensions/code/extension/subagents/worker/instructions.md +20 -0
  249. package/dist/src/extensions/code/extension/subagents/worker/sandbox.d.ts +2 -0
  250. package/dist/src/extensions/code/extension/subagents/worker/sandbox.js +1 -0
  251. package/dist/src/extensions/code/extension/subagents/worker/tools/glob.d.ts +1 -0
  252. package/dist/src/extensions/code/extension/subagents/worker/tools/glob.js +1 -0
  253. package/dist/src/extensions/code/extension/subagents/worker/tools/grep.d.ts +1 -0
  254. package/dist/src/extensions/code/extension/subagents/worker/tools/grep.js +1 -0
  255. package/dist/src/extensions/code/extension/subagents/worker/tools/load_skill.d.ts +2 -0
  256. package/dist/src/extensions/code/extension/subagents/worker/tools/load_skill.js +1 -0
  257. package/dist/src/extensions/code/extension/subagents/worker/tools/read_file.d.ts +1 -0
  258. package/dist/src/extensions/code/extension/subagents/worker/tools/read_file.js +1 -0
  259. package/dist/src/extensions/code/extension/subagents/worker/tools/web_fetch.d.ts +2 -0
  260. package/dist/src/extensions/code/extension/subagents/worker/tools/web_fetch.js +1 -0
  261. package/dist/src/extensions/code/extension/subagents/worker/tools/web_search.d.ts +2 -0
  262. package/dist/src/extensions/code/extension/subagents/worker/tools/web_search.js +1 -0
  263. package/dist/src/extensions/code/extension/subagents/worker/tools/write_file.d.ts +2 -0
  264. package/dist/src/extensions/code/extension/subagents/worker/tools/write_file.js +1 -0
  265. package/dist/src/extensions/code/extension/tools/apply_patch.d.ts +28 -0
  266. package/dist/src/extensions/code/extension/tools/apply_patch.js +2 -0
  267. package/dist/src/extensions/code/extension/tools/computer_use.d.ts +400 -0
  268. package/dist/src/extensions/code/extension/tools/computer_use.js +1 -0
  269. package/dist/src/extensions/code/extension/tools/gh.d.ts +27 -0
  270. package/dist/src/extensions/code/extension/tools/gh.js +1 -0
  271. package/dist/src/extensions/code/extension/tools/grep.d.ts +28 -0
  272. package/dist/src/extensions/code/extension/tools/grep.js +1 -0
  273. package/dist/src/extensions/code/tools.d.ts +4 -0
  274. package/dist/src/extensions/code/tools.js +1 -0
  275. package/dist/src/harness/compaction.js +1 -1
  276. package/dist/src/harness/final-output.js +1 -1
  277. package/dist/src/harness/input-extraction.js +1 -1
  278. package/dist/src/harness/session-limit-enforcement.js +1 -1
  279. package/dist/src/harness/tool-loop.js +2 -2
  280. package/dist/src/harness/tools.js +1 -1
  281. package/dist/src/harness/turn-tag-state.d.ts +2 -2
  282. package/dist/src/harness/workflow-tool-runs.d.ts +33 -5
  283. package/dist/src/harness/workflow-tool-runs.js +1 -1
  284. package/dist/src/internal/application/optional-package-import.d.ts +9 -0
  285. package/dist/src/internal/application/optional-package-import.js +1 -0
  286. package/dist/src/internal/application/optional-package-install.d.ts +1 -5
  287. package/dist/src/internal/application/optional-package-install.js +2 -2
  288. package/dist/src/internal/application/package.js +1 -1
  289. package/dist/src/internal/nitro/host/build-extension.js +1 -1
  290. package/dist/src/internal/nitro/host/extension-build-lock.d.ts +9 -0
  291. package/dist/src/internal/nitro/host/extension-build-lock.js +1 -0
  292. package/dist/src/internal/nitro/host/prepare-application-host.d.ts +5 -4
  293. package/dist/src/internal/nitro/host/prepare-application-host.js +1 -1
  294. package/dist/src/internal/nitro/host/types.d.ts +2 -2
  295. package/dist/src/internal/nitro/host/workspace-extensions.d.ts +31 -0
  296. package/dist/src/internal/nitro/host/workspace-extensions.js +1 -0
  297. package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.7/node_modules/@vercel/cli-config/dist/index.js +21 -0
  298. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/envpath.js +1 -0
  299. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/errors.js +2 -0
  300. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/errutils.js +1 -0
  301. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/exec.js +1 -0
  302. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/fsutils.js +1 -0
  303. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/index.js +1 -0
  304. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/lookup.js +1 -0
  305. package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/safety.js +1 -0
  306. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/authorization.js +1 -0
  307. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/connector.js +1 -0
  308. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/index.js +1 -0
  309. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/installation.js +1 -0
  310. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/internal/base-url.js +1 -0
  311. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/internal/default-scopes.js +1 -0
  312. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/internal/env.js +1 -0
  313. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/internal/url-validation.js +1 -0
  314. package/dist/src/node_modules/.pnpm/@vercel_connect@2.2.0_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_37d5e4f23f0f03cba2e0819e67e81b38/node_modules/@vercel/connect/dist/token.js +1 -0
  315. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/auth-errors.js +1 -0
  316. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/exchange-vercel-oidc-token.js +1 -0
  317. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/get-context.js +1 -0
  318. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-sync.js +1 -0
  319. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-with-refresh.js +2 -0
  320. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/index.js +1 -0
  321. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/oauth.js +1 -0
  322. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/token-error.js +1 -0
  323. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/token-io.js +1 -0
  324. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/token-util.js +2 -0
  325. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/token.js +1 -0
  326. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/verify-vercel-oidc-token.js +1 -0
  327. package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.8/node_modules/@vercel/oidc/dist/version.js +1 -0
  328. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js +1 -0
  329. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js +1 -0
  330. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js +1 -0
  331. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js +1 -0
  332. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js +1 -0
  333. package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js +1 -0
  334. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/index.js +1 -0
  335. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/command.js +1 -0
  336. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/error.js +2 -0
  337. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/kill.js +1 -0
  338. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/promise.js +1 -0
  339. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stdio.js +1 -0
  340. package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stream.js +1 -0
  341. package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js +1 -0
  342. package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/index.js +1 -0
  343. package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/core.js +1 -0
  344. package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/main.js +1 -0
  345. package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/realtime.js +1 -0
  346. package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/signals.js +1 -0
  347. package/dist/src/node_modules/.pnpm/is-stream@2.0.1/node_modules/is-stream/index.js +1 -0
  348. package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js +1 -0
  349. package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js +1 -0
  350. package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js +1 -0
  351. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/index.js +1 -0
  352. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/decrypt.js +1 -0
  353. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/encrypt.js +1 -0
  354. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/decrypt.js +1 -0
  355. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/encrypt.js +1 -0
  356. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/decrypt.js +1 -0
  357. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/encrypt.js +1 -0
  358. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/embedded.js +1 -0
  359. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/thumbprint.js +1 -0
  360. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/local.js +1 -0
  361. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/remote.js +1 -0
  362. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/sign.js +1 -0
  363. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/verify.js +1 -0
  364. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/sign.js +1 -0
  365. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/verify.js +1 -0
  366. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/sign.js +1 -0
  367. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/verify.js +1 -0
  368. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/decrypt.js +1 -0
  369. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/encrypt.js +1 -0
  370. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/produce.js +1 -0
  371. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/sign.js +1 -0
  372. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/unsecured.js +1 -0
  373. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/verify.js +1 -0
  374. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/export.js +1 -0
  375. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_key_pair.js +1 -0
  376. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_secret.js +1 -0
  377. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/import.js +1 -0
  378. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/aesgcmkw.js +1 -0
  379. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/buffer_utils.js +1 -0
  380. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/cek.js +1 -0
  381. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_iv_length.js +1 -0
  382. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_key_type.js +1 -0
  383. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_p2s.js +1 -0
  384. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/crypto_key.js +1 -0
  385. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/decrypt_key_management.js +1 -0
  386. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/encrypt_key_management.js +1 -0
  387. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/epoch.js +1 -0
  388. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/invalid_key_input.js +1 -0
  389. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_disjoint.js +1 -0
  390. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_jwk.js +1 -0
  391. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_object.js +1 -0
  392. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/iv.js +1 -0
  393. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/jwt_claims_set.js +1 -0
  394. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/private_symbols.js +1 -0
  395. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/secs.js +1 -0
  396. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_algorithms.js +1 -0
  397. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_crit.js +1 -0
  398. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/aeskw.js +1 -0
  399. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/asn1.js +1 -0
  400. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/base64url.js +1 -0
  401. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/cbc_tag.js +1 -0
  402. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_cek_length.js +1 -0
  403. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_key_length.js +1 -0
  404. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ciphers.js +1 -0
  405. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/decrypt.js +1 -0
  406. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/digest.js +1 -0
  407. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/dsa_digest.js +1 -0
  408. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ecdhes.js +1 -0
  409. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/encrypt.js +1 -0
  410. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/fetch_jwks.js +1 -0
  411. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/generate.js +1 -0
  412. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_named_curve.js +1 -0
  413. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_sign_verify_key.js +1 -0
  414. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/hmac_digest.js +1 -0
  415. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_like.js +1 -0
  416. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_object.js +1 -0
  417. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/jwk_to_key.js +1 -0
  418. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/key_to_jwk.js +1 -0
  419. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/node_key.js +1 -0
  420. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/normalize_key.js +1 -0
  421. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/pbes2kw.js +1 -0
  422. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/random.js +1 -0
  423. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/rsaes.js +1 -0
  424. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/runtime.js +1 -0
  425. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/sign.js +1 -0
  426. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/timing_safe_equal.js +1 -0
  427. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/verify.js +1 -0
  428. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/webcrypto.js +1 -0
  429. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/base64url.js +1 -0
  430. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_jwt.js +1 -0
  431. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_protected_header.js +1 -0
  432. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/errors.js +1 -0
  433. package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/runtime.js +1 -0
  434. package/dist/src/node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js +1 -0
  435. package/dist/src/node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js +1 -0
  436. package/dist/src/node_modules/.pnpm/npm-run-path@4.0.1/node_modules/npm-run-path/index.js +1 -0
  437. package/dist/src/node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js +1 -0
  438. package/dist/src/node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js +1 -0
  439. package/dist/src/node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js +1 -0
  440. package/dist/src/node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js +1 -0
  441. package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js +1 -0
  442. package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js +1 -0
  443. package/dist/src/node_modules/.pnpm/strip-final-newline@2.0.0/node_modules/strip-final-newline/index.js +2 -0
  444. package/dist/src/node_modules/.pnpm/which@2.0.2/node_modules/which/which.js +1 -0
  445. package/dist/src/public/channels/github/checkout.d.ts +7 -2
  446. package/dist/src/public/channels/github/checkout.js +1 -1
  447. package/dist/src/public/channels/github/defaults.js +1 -1
  448. package/dist/src/public/channels/slack/api-errors.d.ts +33 -0
  449. package/dist/src/public/channels/slack/api-errors.js +1 -0
  450. package/dist/src/public/channels/slack/api.js +1 -1
  451. package/dist/src/public/channels/slack/interaction-cards.js +1 -1
  452. package/dist/src/public/channels/slack/interactions.js +1 -1
  453. package/dist/src/public/definitions/sandbox.d.ts +1 -1
  454. package/dist/src/public/memory/file/provider.js +1 -1
  455. package/dist/src/public/next/index.d.ts +10 -7
  456. package/dist/src/public/next/index.js +1 -1
  457. package/dist/src/public/next/server.d.ts +3 -0
  458. package/dist/src/public/next/server.js +2 -2
  459. package/dist/src/public/sandbox/docker.d.ts +7 -0
  460. package/dist/src/public/sandbox/index.d.ts +1 -1
  461. package/dist/src/public/sandbox/microsandbox.d.ts +7 -0
  462. package/dist/src/public/sandbox/vercel.d.ts +7 -0
  463. package/dist/src/public/skills/index.d.ts +1 -2
  464. package/dist/src/runtime/connections/mcp-client.d.ts +0 -7
  465. package/dist/src/runtime/connections/mcp-client.js +1 -1
  466. package/dist/src/runtime/connections/openapi-client.d.ts +0 -3
  467. package/dist/src/runtime/connections/openapi-client.js +1 -1
  468. package/dist/src/runtime/workspace/seed-files.js +1 -1
  469. package/dist/src/sandbox/providers/docker.d.ts +4 -4
  470. package/dist/src/sandbox/providers/just-bash.d.ts +2 -2
  471. package/dist/src/sandbox/providers/microsandbox.d.ts +4 -4
  472. package/dist/src/sandbox/providers/vercel.d.ts +4 -3
  473. package/dist/src/sandbox/state.d.ts +2 -0
  474. package/dist/src/self-modification/config.d.ts +6 -0
  475. package/dist/src/self-modification/extension/config-schema.d.ts +25 -0
  476. package/dist/src/self-modification/extension/config-schema.js +1 -0
  477. package/dist/src/self-modification/extension/extension.d.ts +3 -47
  478. package/dist/src/self-modification/extension/extension.js +1 -1
  479. package/dist/src/self-modification/extension/local-only.d.ts +5 -0
  480. package/dist/src/self-modification/extension/local-only.js +1 -0
  481. package/dist/src/self-modification/extension/subagents/agent/instructions.js +6 -6
  482. package/dist/src/self-modification/extension/subagents/agent/skills/trace_analysis.d.ts +10 -0
  483. package/dist/src/self-modification/extension/subagents/agent/skills/trace_analysis.js +19 -0
  484. package/dist/src/self-modification/extension/subagents/agent/tools/inspect_trace.d.ts +128 -0
  485. package/dist/src/self-modification/extension/subagents/agent/tools/inspect_trace.js +1 -0
  486. package/dist/src/self-modification/extension/subagents/agent/tools/inspect_trace_spans.d.ts +80 -0
  487. package/dist/src/self-modification/extension/subagents/agent/tools/inspect_trace_spans.js +1 -0
  488. package/dist/src/self-modification/extension/subagents/agent/tools/registry_add.js +1 -1
  489. package/dist/src/self-modification/extension/subagents/agent/tools/search_traces.d.ts +53 -0
  490. package/dist/src/self-modification/extension/subagents/agent/tools/search_traces.js +1 -0
  491. package/dist/src/self-modification/extension/trace-inspection.d.ts +15 -0
  492. package/dist/src/self-modification/extension/trace-inspection.js +1 -0
  493. package/dist/src/self-modification/git-workspace.d.ts +5 -1
  494. package/dist/src/self-modification/git.d.ts +5 -1
  495. package/dist/src/self-modification/sandbox.js +1 -1
  496. package/dist/src/services/dev-client/request-headers.d.ts +1 -1
  497. package/dist/src/services/dev-client/request-headers.js +1 -1
  498. package/dist/src/setup/ask.d.ts +2 -0
  499. package/dist/src/setup/ask.js +1 -1
  500. package/dist/src/setup/cli/option-row.d.ts +3 -1
  501. package/dist/src/setup/cli/option-row.js +1 -1
  502. package/dist/src/setup/flows/model-login.d.ts +4 -0
  503. package/dist/src/setup/flows/model-login.js +1 -1
  504. package/dist/src/setup/flows/model.d.ts +0 -108
  505. package/dist/src/setup/flows/model.js +1 -1
  506. package/dist/src/setup/integrations/discord/api.js +1 -1
  507. package/dist/src/setup/integrations/discord/connect.js +1 -1
  508. package/dist/src/setup/integrations/github/connect.js +1 -1
  509. package/dist/src/setup/integrations/linear/connect.js +1 -1
  510. package/dist/src/setup/integrations/linq/connect.js +1 -1
  511. package/dist/src/setup/integrations/photon/connect.js +1 -1
  512. package/dist/src/setup/integrations/teams/connect.js +1 -1
  513. package/dist/src/setup/integrations/web/setup.d.ts +15 -10
  514. package/dist/src/setup/integrations/web/setup.js +30 -1
  515. package/dist/src/setup/project-resolution.js +1 -1
  516. package/dist/src/setup/scaffold/create/project.js +2 -2
  517. package/dist/src/setup/scaffold/create/web-template.d.ts +7 -3
  518. package/dist/src/setup/scaffold/create/web-template.js +39 -20
  519. package/dist/src/setup/scaffold/update/channels.js +2 -2
  520. package/dist/src/setup/slack-connect.d.ts +1 -1
  521. package/dist/src/setup/slack-connect.js +1 -1
  522. package/dist/src/setup/vercel-api-failure.js +1 -1
  523. package/dist/src/setup/vercel-deployment.js +1 -1
  524. package/dist/src/setup/vercel-project-api.d.ts +1 -1
  525. package/dist/src/setup/vercel-project-api.js +1 -1
  526. package/dist/src/setup/vercel-project-framework.js +1 -1
  527. package/dist/src/setup/vercel-project.js +0 -0
  528. package/dist/src/shared/connection-types.d.ts +0 -2
  529. package/dist/src/shared/sandbox-network-policy.d.ts +5 -4
  530. package/dist/src/shared/sandbox-session.d.ts +0 -15
  531. package/dist/src/shared/skill-package.d.ts +3 -0
  532. package/dist/src/shared/skill-package.js +1 -1
  533. package/dist/src/subagents/parent-notification.d.ts +1 -1
  534. package/dist/src/subagents/remote-dispatch.d.ts +1 -0
  535. package/dist/src/subagents/remote-dispatch.js +1 -1
  536. package/dist/src/svelte/index.js +1 -1
  537. package/dist/src/svelte/use-eve-agent.js +1 -1
  538. package/dist/src/tasks/delivery-context.js +2 -2
  539. package/dist/src/tasks/json.d.ts +72 -2
  540. package/dist/src/tasks/json.js +1 -1
  541. package/dist/src/tasks/notification.d.ts +6 -0
  542. package/dist/src/tasks/notification.js +1 -1
  543. package/dist/src/tools/framework/agent-contract.d.ts +7 -6
  544. package/dist/src/tools/framework/agent-contract.js +1 -1
  545. package/dist/src/tools/framework/agent.d.ts +4 -13
  546. package/dist/src/tools/framework/task-cancel.d.ts +1 -17
  547. package/dist/src/tools/framework/task-contract.d.ts +16 -137
  548. package/dist/src/tools/framework/task-contract.js +1 -1
  549. package/dist/src/tools/provided/bash.d.ts +11 -12
  550. package/dist/src/tools/provided/bash.js +1 -1
  551. package/dist/src/tools/provided/glob.d.ts +13 -14
  552. package/dist/src/tools/provided/glob.js +1 -1
  553. package/dist/src/tools/provided/grep.d.ts +17 -18
  554. package/dist/src/tools/provided/grep.js +1 -1
  555. package/dist/src/tools/provided/read-file.d.ts +14 -15
  556. package/dist/src/tools/provided/read-file.js +1 -1
  557. package/dist/src/tools/provided/web-fetch.d.ts +13 -18
  558. package/dist/src/tools/provided/web-fetch.js +1 -1
  559. package/dist/src/tools/provided/workflow.js +1 -1
  560. package/dist/src/tools/provided/write-file.d.ts +10 -11
  561. package/dist/src/tools/provided/write-file.js +1 -1
  562. package/dist/src/tools/schema.d.ts +40 -10
  563. package/dist/src/tools/schema.js +1 -1
  564. package/dist/src/tracing/agent-trace-context-store.js +1 -1
  565. package/dist/src/tracing/local-trace-analysis.d.ts +51 -0
  566. package/dist/src/tracing/local-trace-analysis.js +1 -0
  567. package/dist/src/tracing/local-trace-discovery-index.d.ts +15 -0
  568. package/dist/src/tracing/local-trace-discovery-index.js +1 -0
  569. package/dist/src/tracing/local-trace-operations.d.ts +13 -0
  570. package/dist/src/tracing/local-trace-operations.js +1 -0
  571. package/dist/src/tracing/local-trace-query.d.ts +17 -0
  572. package/dist/src/tracing/local-trace-query.js +1 -0
  573. package/dist/src/tracing/local-trace-span-processor.js +1 -1
  574. package/dist/src/tracing/local-trace-summary.d.ts +31 -0
  575. package/dist/src/tracing/local-trace-summary.js +1 -0
  576. package/dist/src/vue/index.js +1 -1
  577. package/dist/src/vue/use-eve-agent.js +1 -1
  578. package/docs/README.md +1 -1
  579. package/docs/channels/slack.mdx +1 -1
  580. package/docs/concepts/project-structure.mdx +2 -4
  581. package/docs/concepts/sessions-runs-and-streaming.md +2 -2
  582. package/docs/connections/overview.mdx +1 -1
  583. package/docs/evals/cases.mdx +1 -0
  584. package/docs/extensions.md +7 -1
  585. package/docs/getting-started.mdx +1 -1
  586. package/docs/guides/auth-and-route-protection.md +33 -1
  587. package/docs/guides/client/streaming.mdx +26 -0
  588. package/docs/guides/deployment/vercel.mdx +9 -5
  589. package/docs/guides/dev-tui.md +1 -1
  590. package/docs/guides/dynamic-capabilities.md +2 -0
  591. package/docs/guides/frontend/nextjs.mdx +20 -7
  592. package/docs/guides/frontend/overview.mdx +1 -1
  593. package/docs/guides/hooks.md +6 -3
  594. package/docs/guides/instrumentation/agent-runs.mdx +101 -0
  595. package/docs/guides/instrumentation/instrumentation.mdx +2 -1
  596. package/docs/guides/instrumentation/meta.json +1 -1
  597. package/docs/guides/instrumentation/migration.md +5 -1
  598. package/docs/guides/instrumentation/otel.mdx +8 -27
  599. package/docs/guides/remote-agents.md +3 -1
  600. package/docs/guides/self-modification.md +37 -0
  601. package/docs/guides/session-context.md +11 -13
  602. package/docs/install-integrations.mdx +2 -2
  603. package/docs/meta.json +1 -0
  604. package/docs/reference/cli.md +2 -2
  605. package/docs/reference/typescript-api.md +1 -2
  606. package/docs/sandbox/index.mdx +11 -0
  607. package/docs/skills.mdx +3 -10
  608. package/docs/subagents/index.mdx +9 -3
  609. package/docs/tools/overview.mdx +7 -1
  610. package/docs/tools/workflows.mdx +1 -1
  611. package/package.json +30 -1
  612. package/dist/src/cli/dev/tui/model-picker.d.ts +0 -50
  613. package/dist/src/cli/dev/tui/model-picker.js +0 -1
  614. package/dist/src/compiled/_chunks/client/errors-Cd0_QQdM.js +0 -2
  615. package/dist/src/compiled/_chunks/node/auth-DDrvYko5.js +0 -2
  616. package/dist/src/compiled/_chunks/node/schemas-g-rLPCNX.js +0 -50
  617. package/dist/src/compiled/_chunks/workflow/coerce-D0oqvQ_w.js +0 -1
  618. package/dist/src/compiled/_chunks/workflow/dist-DjECvUyK.js +0 -2
  619. package/dist/src/compiled/_chunks/workflow/frames-D_Q-7A1N.js +0 -3
  620. package/dist/src/compiled/_chunks/workflow/resume-hook-BhA_nDEV.js +0 -1
  621. package/dist/src/compiled/_chunks/workflow/schemas-4CmFgxN_.js +0 -50
  622. package/dist/src/compiled/_chunks/workflow/sleep-DB4AH9-A.js +0 -1
  623. package/dist/src/compiled/_chunks/workflow/token-util-pP4KRRl0.js +0 -27
  624. package/dist/src/compiled/_chunks/workflow/ws-transport-BpTMh40s.js +0 -1
  625. package/dist/src/internal/nitro/host/dev-workspace-extensions.d.ts +0 -18
  626. package/dist/src/internal/nitro/host/dev-workspace-extensions.js +0 -1
  627. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/lib/primitives.js +0 -1
  628. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/lib/schemas.js +0 -1
  629. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/models/aclaction.js +0 -1
  630. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/models/sdkvalidationerror.js +0 -1
  631. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/models/updateprojectblock.js +0 -1
  632. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/models/updateprojectprojectsbranchmatcher.js +0 -1
  633. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/defaultToZeroValue.js +0 -1
  634. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/fp.js +0 -1
  635. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/primitives.js +0 -1
  636. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/rfcdate.js +0 -1
  637. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/smartUnion.js +0 -1
  638. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.8/node_modules/@vercel/sdk/esm/types/unrecognized.js +0 -1
  639. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/index.js +0 -1
  640. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/ZodError.js +0 -1
  641. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/errors.js +0 -1
  642. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/external.js +0 -1
  643. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/helpers/errorUtil.js +0 -1
  644. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/helpers/parseUtil.js +0 -1
  645. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/helpers/typeAliases.js +0 -1
  646. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/helpers/util.js +0 -1
  647. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/index.js +0 -1
  648. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/locales/en.js +0 -1
  649. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v3/types.js +0 -1
  650. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/checks.js +0 -1
  651. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/coerce.js +0 -1
  652. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/compat.js +0 -1
  653. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/deep-partial.js +0 -1
  654. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/errors.js +0 -1
  655. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/external.js +0 -1
  656. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/from-json-schema.js +0 -1
  657. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/in-out.js +0 -1
  658. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/iso.js +0 -1
  659. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/parse.js +0 -1
  660. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/schemas.js +0 -1
  661. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/api.js +0 -1
  662. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/checks.js +0 -1
  663. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/compile.js +0 -2
  664. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/core.js +0 -1
  665. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/doc.js +0 -3
  666. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/errors.js +0 -2
  667. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/index.js +0 -1
  668. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/json-schema-generator.js +0 -1
  669. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/json-schema-processors.js +0 -1
  670. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/json-schema.js +0 -1
  671. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/memoizer.js +0 -1
  672. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/parse.js +0 -1
  673. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/regexes.js +0 -1
  674. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/registries.js +0 -1
  675. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/schemas.js +0 -46
  676. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/to-json-schema.js +0 -3
  677. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/util.js +0 -1
  678. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/versions.js +0 -1
  679. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/core/visit.js +0 -1
  680. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ar.js +0 -1
  681. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/az.js +0 -1
  682. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/be.js +0 -1
  683. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/bg.js +0 -1
  684. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/bn.js +0 -1
  685. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ca.js +0 -1
  686. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ckb.js +0 -1
  687. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/cs.js +0 -1
  688. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/da.js +0 -1
  689. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/de.js +0 -1
  690. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/el.js +0 -1
  691. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/en.js +0 -1
  692. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/eo.js +0 -1
  693. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/es.js +0 -1
  694. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/fa.js +0 -1
  695. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/fi.js +0 -1
  696. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/fr-CA.js +0 -1
  697. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/fr.js +0 -1
  698. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/gu.js +0 -1
  699. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/he.js +0 -1
  700. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/hi.js +0 -1
  701. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/hr.js +0 -1
  702. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/hu.js +0 -1
  703. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/hy.js +0 -1
  704. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/id.js +0 -1
  705. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/index.js +0 -1
  706. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/is.js +0 -1
  707. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/it.js +0 -1
  708. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ja.js +0 -1
  709. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ka.js +0 -1
  710. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/kh.js +0 -1
  711. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/km.js +0 -1
  712. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/kn.js +0 -1
  713. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ko.js +0 -1
  714. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/lt.js +0 -1
  715. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/mk.js +0 -1
  716. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ms.js +0 -1
  717. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ne.js +0 -1
  718. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/nl.js +0 -1
  719. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/nn.js +0 -1
  720. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/no.js +0 -1
  721. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ota.js +0 -1
  722. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/pl.js +0 -1
  723. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ps.js +0 -1
  724. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/pt-BR.js +0 -1
  725. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/pt.js +0 -1
  726. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ro.js +0 -1
  727. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ru.js +0 -1
  728. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/sk.js +0 -1
  729. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/sl.js +0 -1
  730. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/sv.js +0 -1
  731. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ta.js +0 -1
  732. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/th.js +0 -1
  733. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/tk.js +0 -1
  734. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/tr.js +0 -1
  735. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ua.js +0 -1
  736. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/uk.js +0 -1
  737. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/ur.js +0 -1
  738. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/uz.js +0 -1
  739. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/vi.js +0 -1
  740. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/yo.js +0 -1
  741. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/zh-CN.js +0 -1
  742. package/dist/src/node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/locales/zh-TW.js +0 -1
  743. package/dist/src/runtime/skills/sandbox-access.d.ts +0 -22
  744. package/dist/src/runtime/skills/sandbox-access.js +0 -1
  745. package/dist/src/shared/skill-types.d.ts +0 -22
  746. package/dist/src/shared/skill-types.js +0 -1
  747. package/dist/src/tasks/session-task-cohorts.d.ts +0 -7
  748. package/dist/src/tasks/session-task-cohorts.js +0 -1
@@ -1,7 +1,6 @@
1
1
  /**
2
- * Skill authoring helpers and runtime accessors.
2
+ * Skill authoring helpers.
3
3
  */
4
- export type { SkillFile, SkillHandle } from "#shared/skill-types.js";
5
4
  export { defineSkill, type NamedSkillDefinition, type SkillDefinition, type SkillFileContent, type SkillPackageDefinition, } from "#public/definitions/skill.js";
6
5
  export { defineDynamic } from "#dynamic/definition.js";
7
6
  export type { DynamicResolveContext, DynamicSentinel } from "#dynamic/definition.js";
@@ -1,5 +1,4 @@
1
1
  import { type MCPClient } from "#compiled/@ai-sdk/mcp/index.js";
2
- import type { ToolSet } from "ai";
3
2
  import type { ResolvedConnectionDefinition } from "#runtime/types.js";
4
3
  import type { ConnectionClient, ConnectionToolExecuteOptions, ConnectionToolMetadata, ToolFilterDefinition } from "#shared/connection-types.js";
5
4
  /**
@@ -29,12 +28,6 @@ export declare class McpConnectionClient implements ConnectionClient {
29
28
  * promise.
30
29
  */
31
30
  getToolMetadata(): Promise<readonly ConnectionToolMetadata[]>;
32
- /**
33
- * Returns the AI SDK `ToolSet` produced by `@ai-sdk/mcp`'s
34
- * `toolsFromDefinitions()`. Each entry is a full SDK `Tool` with
35
- * `inputSchema`, `description`, and `execute` already set.
36
- */
37
- getTools(): Promise<ToolSet>;
38
31
  /**
39
32
  * Executes a named tool through the AI SDK's tool executor, which
40
33
  * handles the JSON-RPC `tools/call` internally.
@@ -1 +1 @@
1
- import{isObject}from"#shared/guards.js";import{buildCallbackContext}from"#context/build-callback-context.js";import{evictScopedToken,resolveScopedToken}from"#runtime/connections/scoped-authorization.js";import{ConnectionAuthorizationRequiredError}from"#connections/errors.js";import{resolveConnectionAuthorization}from"#runtime/connections/resolve-authorization.js";import{createMCPClient}from"#compiled/@ai-sdk/mcp/index.js";import{omitProvidedArgumentsFromSchema,resolveProvidedArguments}from"#runtime/connections/provided-arguments.js";var McpConnectionClient=class{#e;#t;#n;#r;#i;constructor(e){this.#i=e}async connect(){if(this.#t!==void 0)return this.#t;if(this.#e!==void 0)return this.#e;this.#e=this.#a();try{return this.#t=await this.#e,this.#t}catch(e){throw this.#e=void 0,e}}async#a(){let e=await resolveHeaders(this.#i),t=this.#i.url;try{return await createMCPClient({protocolVersionDiscovery:this.#i.protocolVersionDiscovery,transport:{type:`http`,url:t,headers:e}})}catch(n){if(!isMcpHttpFallbackRetryableError(n))throw n;return await createMCPClient({protocolVersionDiscovery:this.#i.protocolVersionDiscovery,transport:{type:`sse`,url:t,headers:e}})}}async getToolMetadata(){return(await this.#o()).metadata}async getTools(){return(await this.#o()).tools}async executeTool(e,t,n){try{let{tools:r}=await this.#o(),i=r[e];if(i?.execute===void 0)throw Error(`Tool "${e}" not found in connection "${this.#i.connectionName}".`);let a=await resolveProvidedArguments({args:t,callId:n.callId,connection:this.#i,toolName:e});return await i.execute(a,{abortSignal:n.abortSignal})}catch(e){return await this.#l(e)}}async#o(){if(this.#r!==void 0)return this.#r;if(this.#n!==void 0)return this.#n;this.#n=this.#s();try{return this.#r=await this.#n,this.#r}catch(e){throw this.#n=void 0,e}}async#s(){try{return await this.#c()}catch(e){return await this.#l(e)}}async#c(){let e=await this.connect(),t=await e.listTools(),n=this.#i.tools,r=n===void 0?t.tools:t.tools.filter(e=>passesToolFilter(e.name,n)),i=Object.keys(this.#i.toolCall?.providedArguments??{}),a=r.map(e=>({...e,inputSchema:omitProvidedArgumentsFromSchema(e.inputSchema,i)})),o=e.toolsFromDefinitions({tools:a});return{metadata:a.map(e=>({annotations:e.annotations,description:e.description??``,inputSchema:e.inputSchema??{},name:e.name,outputSchema:`outputSchema`in e&&e.outputSchema!==void 0?e.outputSchema:void 0})),tools:o}}async close(){this.#t!==void 0&&(await this.#t.close(),this.#t=void 0),this.#e=void 0,this.#n=void 0,this.#r=void 0}async#l(e){throw isMcpAuthRequiredError(e)?(await this.#u(),await this.close(),new ConnectionAuthorizationRequiredError(this.#i.connectionName,{message:`Connection "${this.#i.connectionName}" requires authorization (the server rejected the token).`})):e}async#u(){let e=await resolveConnectionAuthorization(this.#i);e!==void 0&&await evictScopedToken({authorization:e,connection:{url:this.#i.url},instanceId:this.#i.instanceId,scope:this.#i.connectionName})}};function isMcpAuthRequiredError(e){return readHttpStatus(e)===401}function isMcpHttpFallbackRetryableError(e){let t=readHttpStatus(e);return t===400||t===404||t===405}function readHttpStatus(e){for(let t of walkErrorChain(e)){if(!isObject(t))continue;let e=readStatusField(t);if(e!==void 0)return e;let n=t.response;if(isObject(n)){let e=readStatusField(n);if(e!==void 0)return e}if(typeof t.message==`string`){let e=/\bHTTP\s+(\d{3})\b/u.exec(t.message);if(e?.[1]!==void 0)return Number(e[1])}}}function readStatusField(e){if(typeof e.status==`number`)return e.status;if(typeof e.statusCode==`number`)return e.statusCode}function*walkErrorChain(e){let t=e,n=new Set;for(;t!=null&&!n.has(t);){if(n.add(t),yield t,!isObject(t)||!(`cause`in t))return;t=t.cause}}function passesToolFilter(e,t){return t===void 0?!0:`allow`in t?t.allow.includes(e):!t.block.includes(e)}async function resolveHeaders(e){let t={},n,getCallbackContext=()=>n??=buildCallbackContext(),r=await resolveConnectionAuthorization(e,typeof e.authorization==`function`?getCallbackContext():void 0);if(r!==void 0&&(t.Authorization=`Bearer ${(await resolveToken(e,r)).token}`),e.headers!==void 0){let n=await resolveHeadersDefinition(e.headers,getCallbackContext);for(let[i,a]of Object.entries(n)){if(r!==void 0&&i.toLowerCase()===`authorization`)throw Error(`Connection "${e.connectionName}" headers must not include an "Authorization" key when "authorization" is also provided.`);t[i]=a}}return t}async function resolveToken(e,t){return await resolveScopedToken({authorization:t,connection:{url:e.url},instanceId:e.instanceId,scope:e.connectionName})}async function resolveHeadersDefinition(e,t){if(typeof e==`function`)return{...await e(t())};let n={},r=Object.entries(e);for(let[e,i]of r)n[e]=await resolveHeaderValue(i,t);return n}async function resolveHeaderValue(e,t){return typeof e==`function`?await e(t()):await e}export{McpConnectionClient,isMcpAuthRequiredError,passesToolFilter,resolveHeaders};
1
+ import{isObject}from"#shared/guards.js";import{buildCallbackContext}from"#context/build-callback-context.js";import{evictScopedToken,resolveScopedToken}from"#runtime/connections/scoped-authorization.js";import{ConnectionAuthorizationRequiredError}from"#connections/errors.js";import{resolveConnectionAuthorization}from"#runtime/connections/resolve-authorization.js";import{createMCPClient}from"#compiled/@ai-sdk/mcp/index.js";import{omitProvidedArgumentsFromSchema,resolveProvidedArguments}from"#runtime/connections/provided-arguments.js";var McpConnectionClient=class{#e;#t;#n;#r;#i;constructor(e){this.#i=e}async connect(){if(this.#t!==void 0)return this.#t;if(this.#e!==void 0)return this.#e;this.#e=this.#a();try{return this.#t=await this.#e,this.#t}catch(e){throw this.#e=void 0,e}}async#a(){let e=await resolveHeaders(this.#i),t=this.#i.url;try{return await createMCPClient({protocolVersionDiscovery:this.#i.protocolVersionDiscovery,transport:{type:`http`,url:t,headers:e}})}catch(n){if(!isMcpHttpFallbackRetryableError(n))throw n;return await createMCPClient({protocolVersionDiscovery:this.#i.protocolVersionDiscovery,transport:{type:`sse`,url:t,headers:e}})}}async getToolMetadata(){return(await this.#o()).metadata}async executeTool(e,t,n){try{let{tools:r}=await this.#o(),i=r[e];if(i?.execute===void 0)throw Error(`Tool "${e}" not found in connection "${this.#i.connectionName}".`);let a=await resolveProvidedArguments({args:t,callId:n.callId,connection:this.#i,toolName:e});return await i.execute(a,{abortSignal:n.abortSignal})}catch(e){return await this.#l(e)}}async#o(){if(this.#r!==void 0)return this.#r;if(this.#n!==void 0)return this.#n;this.#n=this.#s();try{return this.#r=await this.#n,this.#r}catch(e){throw this.#n=void 0,e}}async#s(){try{return await this.#c()}catch(e){return await this.#l(e)}}async#c(){let e=await this.connect(),t=await e.listTools(),n=this.#i.tools,r=n===void 0?t.tools:t.tools.filter(e=>passesToolFilter(e.name,n)),i=Object.keys(this.#i.toolCall?.providedArguments??{}),a=r.map(e=>({...e,inputSchema:omitProvidedArgumentsFromSchema(e.inputSchema,i)})),o=e.toolsFromDefinitions({tools:a});return{metadata:a.map(e=>({annotations:e.annotations,description:e.description??``,inputSchema:e.inputSchema??{},name:e.name,outputSchema:`outputSchema`in e&&e.outputSchema!==void 0?e.outputSchema:void 0})),tools:o}}async close(){this.#t!==void 0&&(await this.#t.close(),this.#t=void 0),this.#e=void 0,this.#n=void 0,this.#r=void 0}async#l(e){throw isMcpAuthRequiredError(e)?(await this.#u(),await this.close(),new ConnectionAuthorizationRequiredError(this.#i.connectionName,{message:`Connection "${this.#i.connectionName}" requires authorization (the server rejected the token).`})):e}async#u(){let e=await resolveConnectionAuthorization(this.#i);e!==void 0&&await evictScopedToken({authorization:e,connection:{url:this.#i.url},instanceId:this.#i.instanceId,scope:this.#i.connectionName})}};function isMcpAuthRequiredError(e){return readHttpStatus(e)===401}function isMcpHttpFallbackRetryableError(e){let t=readHttpStatus(e);return t===400||t===404||t===405}function readHttpStatus(e){for(let t of walkErrorChain(e)){if(!isObject(t))continue;let e=readStatusField(t);if(e!==void 0)return e;let n=t.response;if(isObject(n)){let e=readStatusField(n);if(e!==void 0)return e}if(typeof t.message==`string`){let e=/\bHTTP\s+(\d{3})\b/u.exec(t.message);if(e?.[1]!==void 0)return Number(e[1])}}}function readStatusField(e){if(typeof e.status==`number`)return e.status;if(typeof e.statusCode==`number`)return e.statusCode}function*walkErrorChain(e){let t=e,n=new Set;for(;t!=null&&!n.has(t);){if(n.add(t),yield t,!isObject(t)||!(`cause`in t))return;t=t.cause}}function passesToolFilter(e,t){return t===void 0?!0:`allow`in t?t.allow.includes(e):!t.block.includes(e)}async function resolveHeaders(e){let t={},n,getCallbackContext=()=>n??=buildCallbackContext(),r=await resolveConnectionAuthorization(e,typeof e.authorization==`function`?getCallbackContext():void 0);if(r!==void 0&&(t.Authorization=`Bearer ${(await resolveToken(e,r)).token}`),e.headers!==void 0){let n=await resolveHeadersDefinition(e.headers,getCallbackContext);for(let[i,a]of Object.entries(n)){if(r!==void 0&&i.toLowerCase()===`authorization`)throw Error(`Connection "${e.connectionName}" headers must not include an "Authorization" key when "authorization" is also provided.`);t[i]=a}}return t}async function resolveToken(e,t){return await resolveScopedToken({authorization:t,connection:{url:e.url},instanceId:e.instanceId,scope:e.connectionName})}async function resolveHeadersDefinition(e,t){if(typeof e==`function`)return{...await e(t())};let n={},r=Object.entries(e);for(let[e,i]of r)n[e]=await resolveHeaderValue(i,t);return n}async function resolveHeaderValue(e,t){return typeof e==`function`?await e(t()):await e}export{McpConnectionClient,isMcpAuthRequiredError,passesToolFilter,resolveHeaders};
@@ -1,11 +1,9 @@
1
- import { type ToolSet } from "ai";
2
1
  import type { ResolvedConnectionDefinition } from "#runtime/types.js";
3
2
  import { type OpenApiOperation } from "#runtime/connections/openapi-operations.js";
4
3
  import type { ConnectionClient, ConnectionToolExecuteOptions, ConnectionToolMetadata } from "#shared/connection-types.js";
5
4
  interface OpenApiToolCache {
6
5
  readonly metadata: readonly ConnectionToolMetadata[];
7
6
  readonly operations: ReadonlyMap<string, OpenApiOperation>;
8
- readonly tools: ToolSet;
9
7
  readonly baseUrl: string;
10
8
  }
11
9
  /**
@@ -36,7 +34,6 @@ export declare class OpenApiConnectionClient implements ConnectionClient {
36
34
  /** Loads and parses the OpenAPI document, sharing one in-flight load. */
37
35
  connect(): Promise<OpenApiToolCache>;
38
36
  getToolMetadata(): Promise<readonly ConnectionToolMetadata[]>;
39
- getTools(): Promise<ToolSet>;
40
37
  executeTool(toolName: string, args: unknown, options: ConnectionToolExecuteOptions): Promise<OpenApiToolResult>;
41
38
  close(): Promise<void>;
42
39
  }
@@ -1 +1 @@
1
- import{tool}from"ai";import{isLoopbackHostname}from"#shared/network-address.js";import{createLogger}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{toInputSchema}from"#tools/schema.js";import{omitProvidedArgumentsFromSchema,resolveProvidedArguments}from"#runtime/connections/provided-arguments.js";import{passesToolFilter,resolveHeaders}from"#runtime/connections/mcp-client.js";import{HTTP_METHODS,operationDescription,operationName,uniqueName}from"#runtime/connections/openapi-operations.js";import{buildInputSchema,deref,derefSchema,isArray}from"#runtime/connections/openapi-schema.js";import{applySecurity,resolveSecurity}from"#runtime/connections/openapi-security.js";import{extractServerUrl,parseSpecDocument}from"#runtime/connections/openapi-spec.js";const log=createLogger(`runtime.connections.openapi-client`),SWAGGER_PARAMETER_SCHEMA_KEYS=[`default`,`enum`,`exclusiveMaximum`,`exclusiveMinimum`,`format`,`items`,`maximum`,`maxItems`,`maxLength`,`minimum`,`minItems`,`minLength`,`multipleOf`,`pattern`,`type`,`uniqueItems`];var OpenApiConnectionClient=class{#e;#t;#n;constructor(e){this.#n=e}async connect(){return this.#r()}async getToolMetadata(){return(await this.#r()).metadata}async getTools(){return(await this.#r()).tools}async executeTool(e,t,n){let r=await this.#r(),i=r.operations.get(e);if(i===void 0)throw Error(`Tool "${e}" not found in connection "${this.#n.connectionName}".`);return this.#f(i,r.baseUrl,isObject(t)?t:{},{abortSignal:n.abortSignal,callId:n.callId})}async close(){this.#e=void 0,this.#t=void 0}async#r(){if(this.#t!==void 0)return this.#t;if(this.#e!==void 0)return this.#e;this.#e=this.#i();try{return this.#t=await this.#e,this.#t}catch(e){throw this.#e=void 0,e}}async#i(){let e=await this.#o(),t=this.#a(e),n=this.#s(e),r=this.#n.tools,i=r===void 0?n:n.filter(e=>passesToolFilter(e.toolName,r)),a=[],o=new Map,s={},c=Object.keys(this.#n.toolCall?.providedArguments??{});for(let e of i){let n=omitProvidedArgumentsFromSchema(e.inputSchema,c),r;try{r=toInputSchema(n)}catch(t){log.warn(`omitting OpenAPI operation with an invalid input schema`,{connectionName:this.#n.connectionName,error:t,toolName:e.toolName});continue}o.set(e.toolName,e),a.push({description:e.description,inputSchema:n,name:e.toolName}),s[e.toolName]=tool({description:e.description,inputSchema:r,execute:async(n,r)=>this.#f(e,t,isObject(n)?n:{},{abortSignal:r?.abortSignal,callId:r.toolCallId})})}return{metadata:a,operations:o,tools:s,baseUrl:t}}#a(e){let t=this.#n.url,n=typeof t==`string`&&t.trim().length>0?t:extractServerUrl(e,this.#n.spec);if(n===void 0)throw Error(`OpenAPI connection "${this.#n.connectionName}" has no base URL: set "baseUrl" or ensure the document declares an absolute "servers" entry or Swagger "host".`);return assertSecureUrl(n,this.#n.connectionName,`base`),n}async#o(){let e=this.#n.spec;if(e===void 0)throw Error(`OpenAPI connection "${this.#n.connectionName}" is missing its "spec" source.`);if(typeof e!=`string`)return e;assertSecureUrl(e,this.#n.connectionName,`spec`);let t;try{t=await fetch(e,{headers:{accept:`application/json, application/yaml, text/yaml, */*`}})}catch(t){throw Error(`OpenAPI connection "${this.#n.connectionName}" failed to fetch its spec from "${e}": ${String(t)}`)}if(t.redirected&&assertSecureUrl(t.url,this.#n.connectionName,`spec`),!t.ok)throw Error(`OpenAPI connection "${this.#n.connectionName}" failed to fetch its spec from "${e}": HTTP ${t.status}.`);let n=await t.text(),r;try{r=parseSpecDocument(n)}catch(t){throw Error(`OpenAPI connection "${this.#n.connectionName}" spec at "${e}" could not be parsed as JSON or YAML: ${String(t)}`)}if(!isObject(r))throw Error(`OpenAPI connection "${this.#n.connectionName}" spec at "${e}" is not an OpenAPI document object.`);return r}#s(e){let t=e.paths;if(!isObject(t))return[];let n=[],r=new Set;for(let[i,a]of Object.entries(t)){if(!isObject(a))continue;let t=isArray(a.parameters)?a.parameters:[];for(let o of HTTP_METHODS){let s=a[o];if(!isObject(s))continue;let c=uniqueName(operationName(s,o,i),r),l=isArray(s.parameters)?s.parameters:[],u=[...t,...l],d=this.#c(e,u),f=this.#l(e,s.requestBody,u);n.push({toolName:c,method:o,pathTemplate:i,description:operationDescription(s),parameters:d,requestBody:f,inputSchema:buildInputSchema(d,f),security:resolveSecurity(e,s)})}}return n}#c(e,t){let n=[];for(let r of t){let t=isObject(r)?deref(e,r):r;if(!isObject(t))continue;let i=t.in;if(i!==`path`&&i!==`query`&&i!==`header`&&i!==`cookie`||typeof t.name!=`string`)continue;let a=this.#u(e,t);n.push({name:t.name,location:i,required:t.required===!0||i===`path`,schema:a,description:typeof t.description==`string`?t.description:void 0})}return n}#l(e,t,n=[]){if(isObject(t)){let n=deref(e,t);if(isObject(n)&&isObject(n.content)){let t=n.content,r=`application/json`in t?`application/json`:Object.keys(t)[0];if(r!==void 0){let i=t[r],a=isObject(i)&&isObject(i.schema)?derefSchema(e,i.schema):{};return{required:n.required===!0,contentType:r,schema:a}}}}return this.#d(e,n)}#u(e,t){if(isObject(t.schema))return derefSchema(e,t.schema);let n={};for(let e of SWAGGER_PARAMETER_SCHEMA_KEYS)t[e]!==void 0&&(n[e]=t[e]);return derefSchema(e,n)}#d(e,t){for(let n of t){let t=isObject(n)?deref(e,n):n;if(!isObject(t)||t.in!==`body`)continue;let r=isObject(t.schema)?derefSchema(e,t.schema):{};return{required:t.required===!0,contentType:`application/json`,schema:r}}}async#f(e,t,n,r){let i=await resolveProvidedArguments({args:n,callId:r.callId,connection:this.#n,toolName:e.toolName}),a=await resolveHeaders(this.#n),o=e.pathTemplate,s=new URLSearchParams,c=[];for(let t of e.parameters){let e=i[t.name];e!=null&&(t.location===`path`?o=o.replace(`{${t.name}}`,encodeURIComponent(String(e))):t.location===`query`?appendQuery(s,t.name,e):t.location===`cookie`?c.push(`${t.name}=${encodeURIComponent(String(e))}`):a[t.name]=String(e))}if(applySecurity(e.security,this.#n,a,s,c),c.length>0){let e=a.cookie??a.Cookie;delete a.Cookie,a.cookie=[e,...c].filter(e=>!!e).join(`; `)}let l=new URL(joinPath(t,o));l.search=s.toString();let u;e.requestBody!==void 0&&i.body!==void 0&&(u=JSON.stringify(i.body),a[`content-type`]=e.requestBody.contentType);let d=await fetch(l,{method:e.method.toUpperCase(),headers:a,body:u,signal:r?.abortSignal});return{status:d.status,statusText:d.statusText,body:await readResponseBody(d)}}};function appendQuery(e,t,n){if(isArray(n)){for(let r of n)e.append(t,String(r));return}e.append(t,String(n))}function joinPath(e,t){return`${e.endsWith(`/`)?e.slice(0,-1):e}${t.startsWith(`/`)?t:`/${t}`}`}function assertSecureUrl(e,t,n){let r;try{r=new URL(e)}catch{throw Error(`OpenAPI connection "${t}" has an invalid ${n} URL "${e}".`)}if(r.protocol!==`https:`&&!(r.protocol===`http:`&&isLoopbackHostname(r.hostname)))throw Error(`OpenAPI connection "${t}" must use https for its ${n} (got "${r.protocol}//${r.host}").`)}async function readResponseBody(e){let t=await e.text();if(t.length===0)return null;if((e.headers.get(`content-type`)??``).includes(`application/json`))try{return JSON.parse(t)}catch{return t}return t}export{OpenApiConnectionClient};
1
+ import{isLoopbackHostname}from"#shared/network-address.js";import{createLogger}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{parseJsonObject}from"#shared/json.js";import{omitProvidedArgumentsFromSchema,resolveProvidedArguments}from"#runtime/connections/provided-arguments.js";import{passesToolFilter,resolveHeaders}from"#runtime/connections/mcp-client.js";import{HTTP_METHODS,operationDescription,operationName,uniqueName}from"#runtime/connections/openapi-operations.js";import{buildInputSchema,deref,derefSchema,isArray}from"#runtime/connections/openapi-schema.js";import{applySecurity,resolveSecurity}from"#runtime/connections/openapi-security.js";import{extractServerUrl,parseSpecDocument}from"#runtime/connections/openapi-spec.js";const log=createLogger(`runtime.connections.openapi-client`),SWAGGER_PARAMETER_SCHEMA_KEYS=[`default`,`enum`,`exclusiveMaximum`,`exclusiveMinimum`,`format`,`items`,`maximum`,`maxItems`,`maxLength`,`minimum`,`minItems`,`minLength`,`multipleOf`,`pattern`,`type`,`uniqueItems`];var OpenApiConnectionClient=class{#e;#t;#n;constructor(e){this.#n=e}async connect(){return this.#r()}async getToolMetadata(){return(await this.#r()).metadata}async executeTool(e,t,n){let r=await this.#r(),i=r.operations.get(e);if(i===void 0)throw Error(`Tool "${e}" not found in connection "${this.#n.connectionName}".`);return this.#f(i,r.baseUrl,isObject(t)?t:{},{abortSignal:n.abortSignal,callId:n.callId})}async close(){this.#e=void 0,this.#t=void 0}async#r(){if(this.#t!==void 0)return this.#t;if(this.#e!==void 0)return this.#e;this.#e=this.#i();try{return this.#t=await this.#e,this.#t}catch(e){throw this.#e=void 0,e}}async#i(){let e=await this.#o(),t=this.#a(e),n=this.#s(e),r=this.#n.tools,i=r===void 0?n:n.filter(e=>passesToolFilter(e.toolName,r)),a=[],o=new Map,s=Object.keys(this.#n.toolCall?.providedArguments??{});for(let e of i){let t;try{t=parseJsonObject(omitProvidedArgumentsFromSchema(e.inputSchema,s))}catch(t){log.warn(`omitting OpenAPI operation with an invalid input schema`,{connectionName:this.#n.connectionName,error:t,toolName:e.toolName});continue}o.set(e.toolName,e),a.push({description:e.description,inputSchema:t,name:e.toolName})}return{metadata:a,operations:o,baseUrl:t}}#a(e){let t=this.#n.url,n=typeof t==`string`&&t.trim().length>0?t:extractServerUrl(e,this.#n.spec);if(n===void 0)throw Error(`OpenAPI connection "${this.#n.connectionName}" has no base URL: set "baseUrl" or ensure the document declares an absolute "servers" entry or Swagger "host".`);return assertSecureUrl(n,this.#n.connectionName,`base`),n}async#o(){let e=this.#n.spec;if(e===void 0)throw Error(`OpenAPI connection "${this.#n.connectionName}" is missing its "spec" source.`);if(typeof e!=`string`)return e;assertSecureUrl(e,this.#n.connectionName,`spec`);let t;try{t=await fetch(e,{headers:{accept:`application/json, application/yaml, text/yaml, */*`}})}catch(t){throw Error(`OpenAPI connection "${this.#n.connectionName}" failed to fetch its spec from "${e}": ${String(t)}`)}if(t.redirected&&assertSecureUrl(t.url,this.#n.connectionName,`spec`),!t.ok)throw Error(`OpenAPI connection "${this.#n.connectionName}" failed to fetch its spec from "${e}": HTTP ${t.status}.`);let n=await t.text(),r;try{r=parseSpecDocument(n)}catch(t){throw Error(`OpenAPI connection "${this.#n.connectionName}" spec at "${e}" could not be parsed as JSON or YAML: ${String(t)}`)}if(!isObject(r))throw Error(`OpenAPI connection "${this.#n.connectionName}" spec at "${e}" is not an OpenAPI document object.`);return r}#s(e){let t=e.paths;if(!isObject(t))return[];let n=[],r=new Set;for(let[i,a]of Object.entries(t)){if(!isObject(a))continue;let t=isArray(a.parameters)?a.parameters:[];for(let o of HTTP_METHODS){let s=a[o];if(!isObject(s))continue;let c=uniqueName(operationName(s,o,i),r),l=isArray(s.parameters)?s.parameters:[],u=[...t,...l],d=this.#c(e,u),f=this.#l(e,s.requestBody,u);n.push({toolName:c,method:o,pathTemplate:i,description:operationDescription(s),parameters:d,requestBody:f,inputSchema:buildInputSchema(d,f),security:resolveSecurity(e,s)})}}return n}#c(e,t){let n=[];for(let r of t){let t=isObject(r)?deref(e,r):r;if(!isObject(t))continue;let i=t.in;if(i!==`path`&&i!==`query`&&i!==`header`&&i!==`cookie`||typeof t.name!=`string`)continue;let a=this.#u(e,t);n.push({name:t.name,location:i,required:t.required===!0||i===`path`,schema:a,description:typeof t.description==`string`?t.description:void 0})}return n}#l(e,t,n=[]){if(isObject(t)){let n=deref(e,t);if(isObject(n)&&isObject(n.content)){let t=n.content,r=`application/json`in t?`application/json`:Object.keys(t)[0];if(r!==void 0){let i=t[r],a=isObject(i)&&isObject(i.schema)?derefSchema(e,i.schema):{};return{required:n.required===!0,contentType:r,schema:a}}}}return this.#d(e,n)}#u(e,t){if(isObject(t.schema))return derefSchema(e,t.schema);let n={};for(let e of SWAGGER_PARAMETER_SCHEMA_KEYS)t[e]!==void 0&&(n[e]=t[e]);return derefSchema(e,n)}#d(e,t){for(let n of t){let t=isObject(n)?deref(e,n):n;if(!isObject(t)||t.in!==`body`)continue;let r=isObject(t.schema)?derefSchema(e,t.schema):{};return{required:t.required===!0,contentType:`application/json`,schema:r}}}async#f(e,t,n,r){let i=await resolveProvidedArguments({args:n,callId:r.callId,connection:this.#n,toolName:e.toolName}),a=await resolveHeaders(this.#n),o=e.pathTemplate,s=new URLSearchParams,c=[];for(let t of e.parameters){let e=i[t.name];e!=null&&(t.location===`path`?o=o.replace(`{${t.name}}`,encodeURIComponent(String(e))):t.location===`query`?appendQuery(s,t.name,e):t.location===`cookie`?c.push(`${t.name}=${encodeURIComponent(String(e))}`):a[t.name]=String(e))}if(applySecurity(e.security,this.#n,a,s,c),c.length>0){let e=a.cookie??a.Cookie;delete a.Cookie,a.cookie=[e,...c].filter(e=>!!e).join(`; `)}let l=new URL(joinPath(t,o));l.search=s.toString();let u;e.requestBody!==void 0&&i.body!==void 0&&(u=JSON.stringify(i.body),a[`content-type`]=e.requestBody.contentType);let d=await fetch(l,{method:e.method.toUpperCase(),headers:a,body:u,signal:r?.abortSignal});return{status:d.status,statusText:d.statusText,body:await readResponseBody(d)}}};function appendQuery(e,t,n){if(isArray(n)){for(let r of n)e.append(t,String(r));return}e.append(t,String(n))}function joinPath(e,t){return`${e.endsWith(`/`)?e.slice(0,-1):e}${t.startsWith(`/`)?t:`/${t}`}`}function assertSecureUrl(e,t,n){let r;try{r=new URL(e)}catch{throw Error(`OpenAPI connection "${t}" has an invalid ${n} URL "${e}".`)}if(r.protocol!==`https:`&&!(r.protocol===`http:`&&isLoopbackHostname(r.hostname)))throw Error(`OpenAPI connection "${t}" must use https for its ${n} (got "${r.protocol}//${r.host}").`)}async function readResponseBody(e){let t=await e.text();if(t.length===0)return null;if((e.headers.get(`content-type`)??``).includes(`application/json`))try{return JSON.parse(t)}catch{return t}return t}export{OpenApiConnectionClient};
@@ -1 +1 @@
1
- import{readFile,readdir}from"node:fs/promises";import{join,posix}from"node:path";import{MODEL_SKILL_ROOT}from"#shared/skill-paths.js";import{WORKSPACE_ROOT}from"#runtime/workspace/types.js";const RESOURCE_WORKSPACE_DIRECTORY=`workspace`,RESOURCE_SKILLS_DIRECTORY=`skills`;async function materializeWorkspaceDirectory(e){let t=[],n=await readdir(e,{withFileTypes:!0}),r=n.find(e=>e.name===RESOURCE_WORKSPACE_DIRECTORY&&e.isDirectory()),i=n.find(e=>e.name===RESOURCE_SKILLS_DIRECTORY&&e.isDirectory());return r!==void 0||i!==void 0?(r!==void 0&&await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:join(e,RESOURCE_WORKSPACE_DIRECTORY),targetRoot:WORKSPACE_ROOT}),i!==void 0&&await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:join(e,RESOURCE_SKILLS_DIRECTORY),targetRoot:MODEL_SKILL_ROOT})):await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:e,targetRoot:WORKSPACE_ROOT}),t.sort((e,t)=>e.path.localeCompare(t.path)),t}async function addMaterializedDirectoryFiles(e){let t=await readdir(e.sourceDirectoryPath,{withFileTypes:!0});for(let n of t){if(!n.isDirectory()&&!n.isFile())continue;let t=join(e.sourceDirectoryPath,n.name),r=posix.join(e.logicalDirectoryPath,n.name);if(n.isDirectory()){await addMaterializedDirectoryFiles({files:e.files,logicalDirectoryPath:r,sourceDirectoryPath:t,targetRoot:e.targetRoot});continue}e.files.push({content:await readFile(t),path:posix.join(e.targetRoot,r)})}}export{materializeWorkspaceDirectory};
1
+ import{readFile,readdir}from"node:fs/promises";import{join,posix}from"node:path";import{WORKSPACE_ROOT}from"#runtime/workspace/types.js";import{MODEL_SKILL_ROOT}from"#shared/skill-paths.js";const RESOURCE_WORKSPACE_DIRECTORY=`workspace`,RESOURCE_SKILLS_DIRECTORY=`skills`;async function materializeWorkspaceDirectory(e){let t=[],n=await readdir(e,{withFileTypes:!0}),r=n.find(e=>e.name===RESOURCE_WORKSPACE_DIRECTORY&&e.isDirectory()),i=n.find(e=>e.name===RESOURCE_SKILLS_DIRECTORY&&e.isDirectory());return r!==void 0||i!==void 0?(r!==void 0&&await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:join(e,RESOURCE_WORKSPACE_DIRECTORY),targetRoot:WORKSPACE_ROOT}),i!==void 0&&await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:join(e,RESOURCE_SKILLS_DIRECTORY),targetRoot:MODEL_SKILL_ROOT})):await addMaterializedDirectoryFiles({files:t,logicalDirectoryPath:`.`,sourceDirectoryPath:e,targetRoot:WORKSPACE_ROOT}),t.sort((e,t)=>e.path.localeCompare(t.path)),t}async function addMaterializedDirectoryFiles(e){let t=await readdir(e.sourceDirectoryPath,{withFileTypes:!0});for(let n of t){if(!n.isDirectory()&&!n.isFile())continue;let t=join(e.sourceDirectoryPath,n.name),r=posix.join(e.logicalDirectoryPath,n.name);if(n.isDirectory()){await addMaterializedDirectoryFiles({files:e.files,logicalDirectoryPath:r,sourceDirectoryPath:t,targetRoot:e.targetRoot});continue}e.files.push({content:await readFile(t),path:posix.join(e.targetRoot,r)})}}export{materializeWorkspaceDirectory};
@@ -1,11 +1,11 @@
1
+ import type { DockerSandboxSession } from "#public/sandbox/docker.js";
1
2
  import type { DockerSandboxEnvironmentOptions, DockerSandboxRuntimeOptions } from "#public/sandbox/docker-sandbox.js";
2
3
  import type { SandboxEnvironment } from "#shared/sandbox-environment.js";
3
- import type { MutableNetworkSandboxSession } from "#shared/sandbox-session.js";
4
4
  export type { DockerSandboxEnvironmentOptions, DockerSandboxRuntimeOptions, } from "#public/sandbox/docker-sandbox.js";
5
5
  type DockerfileEnvironmentInput = Omit<DockerSandboxEnvironmentOptions, "image">;
6
6
  export declare const DockerSandbox: {
7
7
  name: string;
8
- environment(options?: Readonly<DockerSandboxEnvironmentOptions> | undefined): SandboxEnvironment<DockerSandboxRuntimeOptions, MutableNetworkSandboxSession>;
9
- dockerfile(options?: DockerfileEnvironmentInput): SandboxEnvironment<DockerSandboxRuntimeOptions, MutableNetworkSandboxSession>;
10
- image(reference: string, options?: DockerfileEnvironmentInput): SandboxEnvironment<DockerSandboxRuntimeOptions, MutableNetworkSandboxSession>;
8
+ environment(options?: Readonly<DockerSandboxEnvironmentOptions> | undefined): SandboxEnvironment<DockerSandboxRuntimeOptions, DockerSandboxSession>;
9
+ dockerfile(options?: DockerfileEnvironmentInput): SandboxEnvironment<DockerSandboxRuntimeOptions, DockerSandboxSession>;
10
+ image(reference: string, options?: DockerfileEnvironmentInput): SandboxEnvironment<DockerSandboxRuntimeOptions, DockerSandboxSession>;
11
11
  };
@@ -1,4 +1,4 @@
1
1
  import type { JustBashSandboxCreateOptions } from "#public/sandbox/just-bash-sandbox.js";
2
- import type { FixedNetworkSandboxSession } from "#shared/sandbox-session.js";
2
+ import type { SandboxSession } from "#shared/sandbox-session.js";
3
3
  export type JustBashEnvironmentOptions = JustBashSandboxCreateOptions;
4
- export declare const JustBashSandbox: import("#shared/sandbox-provider.js").SandboxProvider<JustBashSandboxCreateOptions, undefined, FixedNetworkSandboxSession>;
4
+ export declare const JustBashSandbox: import("#shared/sandbox-provider.js").SandboxProvider<JustBashSandboxCreateOptions, undefined, SandboxSession>;
@@ -1,12 +1,12 @@
1
+ import type { MicrosandboxSandboxSession } from "#public/sandbox/microsandbox.js";
1
2
  import type { MicrosandboxSandboxCreateOptions, MicrosandboxSandboxRuntimeOptions } from "#public/sandbox/microsandbox-sandbox.js";
2
3
  import type { SandboxEnvironment } from "#shared/sandbox-environment.js";
3
- import type { MutableNetworkSandboxSession } from "#shared/sandbox-session.js";
4
4
  export type MicrosandboxEnvironmentOptions = MicrosandboxSandboxCreateOptions;
5
5
  type DockerfileEnvironmentInput = Omit<MicrosandboxEnvironmentOptions, "image">;
6
6
  export declare const MicrosandboxSandbox: {
7
7
  name: string;
8
- environment(options?: Readonly<MicrosandboxSandboxCreateOptions> | undefined): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MutableNetworkSandboxSession>;
9
- dockerfile(options?: DockerfileEnvironmentInput): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MutableNetworkSandboxSession>;
10
- image(reference: string, options?: DockerfileEnvironmentInput): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MutableNetworkSandboxSession>;
8
+ environment(options?: Readonly<MicrosandboxSandboxCreateOptions> | undefined): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MicrosandboxSandboxSession>;
9
+ dockerfile(options?: DockerfileEnvironmentInput): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MicrosandboxSandboxSession>;
10
+ image(reference: string, options?: DockerfileEnvironmentInput): SandboxEnvironment<MicrosandboxSandboxRuntimeOptions, MicrosandboxSandboxSession>;
11
11
  };
12
12
  export {};
@@ -1,12 +1,13 @@
1
+ import type { VercelSandboxSession } from "#public/sandbox/vercel.js";
1
2
  import type { VercelSandboxCreateOptions, VercelSandboxRuntimeOptions } from "#public/sandbox/vercel-sandbox.js";
2
3
  import type { SandboxEnvironment } from "#shared/sandbox-environment.js";
3
- import type { MutableNetworkSandboxSession, SandboxSession } from "#shared/sandbox-session.js";
4
+ import type { SandboxSession } from "#shared/sandbox-session.js";
4
5
  export type VercelSandboxEnvironmentOptions = VercelSandboxCreateOptions & {
5
6
  readonly prepare?: (sandbox: SandboxSession) => Promise<void> | void;
6
7
  };
7
8
  export type { VercelSandboxRuntimeOptions } from "#public/sandbox/vercel-sandbox.js";
8
- export declare function createDefaultVercelEnvironment(options?: VercelSandboxEnvironmentOptions): SandboxEnvironment<VercelSandboxRuntimeOptions, MutableNetworkSandboxSession>;
9
+ export declare function createDefaultVercelEnvironment(options?: VercelSandboxEnvironmentOptions): SandboxEnvironment<VercelSandboxRuntimeOptions, VercelSandboxSession>;
9
10
  export declare const VercelSandbox: {
10
11
  name: string;
11
- environment(options?: VercelSandboxEnvironmentOptions): SandboxEnvironment<VercelSandboxRuntimeOptions, MutableNetworkSandboxSession>;
12
+ environment(options?: VercelSandboxEnvironmentOptions): SandboxEnvironment<VercelSandboxRuntimeOptions, VercelSandboxSession>;
12
13
  };
@@ -1,4 +1,5 @@
1
1
  import type { SandboxSession } from "#public/definitions/sandbox.js";
2
+ import type { SandboxEnvironmentIdentity } from "#shared/sandbox-environment.js";
2
3
  import type { SandboxDeleteOptions, SandboxPreparedArtifact } from "#shared/sandbox-provider.js";
3
4
  export interface SandboxSessionState {
4
5
  readonly providerName: string;
@@ -9,6 +10,7 @@ export interface SandboxState {
9
10
  readonly session: SandboxSessionState | null;
10
11
  }
11
12
  export interface SandboxAccess {
13
+ readonly environment?: SandboxEnvironmentIdentity;
12
14
  captureState(): Promise<SandboxState>;
13
15
  delete?(options?: SandboxDeleteOptions): Promise<void>;
14
16
  get(): Promise<SandboxSession | null>;
@@ -1,4 +1,5 @@
1
1
  import type { SessionAuthContext } from "#channel/types.js";
2
+ import type { AgentReasoningDefinition, AgentStaticModelDefinition } from "#public/index.js";
2
3
  /** Principal and channel that requested a deployed source modification. */
3
4
  export interface SelfModificationAuthorizationContext {
4
5
  readonly channel: {
@@ -50,6 +51,11 @@ export interface SelfModificationConfig {
50
51
  };
51
52
  };
52
53
  }
54
+ /** Values accepted by the self-modification extension mount. */
55
+ export interface SelfModificationExtensionConfig extends SelfModificationConfig {
56
+ readonly model?: AgentStaticModelDefinition;
57
+ readonly reasoning?: AgentReasoningDefinition;
58
+ }
53
59
  export interface ResolvedSelfModificationConfig {
54
60
  readonly localEnabled: boolean;
55
61
  readonly deployed?: ResolvedDeployedSelfModificationConfig;
@@ -0,0 +1,25 @@
1
+ import { z } from "#compiled/zod/index.js";
2
+ import type { AgentReasoningDefinition, AgentStaticModelDefinition } from "#public/index.js";
3
+ import type { GitHubCredentialProvider, SelfModificationAuthorization } from "../config.js";
4
+ export declare const selfModificationConfigSchema: z.ZodObject<{
5
+ model: z.ZodOptional<z.ZodCustom<AgentStaticModelDefinition, AgentStaticModelDefinition>>;
6
+ reasoning: z.ZodOptional<z.ZodCustom<AgentReasoningDefinition, AgentReasoningDefinition>>;
7
+ local: z.ZodOptional<z.ZodObject<{
8
+ enabled: z.ZodOptional<z.ZodBoolean>;
9
+ }, z.core.$strip>>;
10
+ deployed: z.ZodOptional<z.ZodObject<{
11
+ credentials: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
12
+ pat: z.ZodLiteral<true>;
13
+ }, z.core.$strip>, z.ZodCustom<GitHubCredentialProvider, GitHubCredentialProvider>]>>;
14
+ source: z.ZodObject<{
15
+ git: z.ZodObject<{
16
+ directory: z.ZodString;
17
+ repository: z.ZodString;
18
+ }, z.core.$strip>;
19
+ }, z.core.$strip>;
20
+ target: z.ZodObject<{
21
+ branch: z.ZodString;
22
+ }, z.core.$strip>;
23
+ authorize: z.ZodCustom<SelfModificationAuthorization, SelfModificationAuthorization>;
24
+ }, z.core.$strip>>;
25
+ }, z.core.$strip>;
@@ -0,0 +1 @@
1
+ import{z}from"#compiled/zod/index.js";import{isAgentReasoningDefinition,isRuntimeLanguageModel}from"#internal/runtime-model.js";const selfModificationConfigSchema=z.object({model:z.custom(e=>typeof e==`string`||isRuntimeLanguageModel(e)).optional(),reasoning:z.custom(isAgentReasoningDefinition).optional(),local:z.object({enabled:z.boolean().optional()}).optional(),deployed:z.object({credentials:z.union([z.object({pat:z.literal(!0)}),z.custom(e=>typeof e==`object`&&!!e&&`resolve`in e&&typeof e.resolve==`function`)]).optional(),source:z.object({git:z.object({directory:z.string(),repository:z.string()})}),target:z.object({branch:z.string()}),authorize:z.custom(e=>typeof e==`function`)}).optional()});export{selfModificationConfigSchema};
@@ -1,49 +1,5 @@
1
- import { z } from "zod";
2
- import type { AgentReasoningDefinition, AgentStaticModelDefinition } from "#public/index.js";
3
- import type { GitHubCredentialProvider, SelfModificationAuthorization } from "../config.js";
4
- export declare const selfModificationConfigSchema: z.ZodObject<{
5
- model: z.ZodOptional<z.ZodCustom<AgentStaticModelDefinition, AgentStaticModelDefinition>>;
6
- reasoning: z.ZodOptional<z.ZodCustom<AgentReasoningDefinition, AgentReasoningDefinition>>;
7
- local: z.ZodOptional<z.ZodObject<{
8
- enabled: z.ZodOptional<z.ZodBoolean>;
9
- }, z.core.$strip>>;
10
- deployed: z.ZodOptional<z.ZodObject<{
11
- credentials: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
12
- pat: z.ZodLiteral<true>;
13
- }, z.core.$strip>, z.ZodCustom<GitHubCredentialProvider, GitHubCredentialProvider>]>>;
14
- source: z.ZodObject<{
15
- git: z.ZodObject<{
16
- directory: z.ZodString;
17
- repository: z.ZodString;
18
- }, z.core.$strip>;
19
- }, z.core.$strip>;
20
- target: z.ZodObject<{
21
- branch: z.ZodString;
22
- }, z.core.$strip>;
23
- authorize: z.ZodCustom<SelfModificationAuthorization, SelfModificationAuthorization>;
24
- }, z.core.$strip>>;
25
- }, z.core.$strip>;
1
+ import type { StandardSchemaV1 } from "#compiled/@standard-schema/spec/index.js";
2
+ import type { SelfModificationExtensionConfig } from "../config.js";
26
3
  /** Extension mount configured with the same policy as the agent and sandbox. */
27
- declare const _default: import("eve/extension").ExtensionHandle<z.ZodObject<{
28
- model: z.ZodOptional<z.ZodCustom<AgentStaticModelDefinition, AgentStaticModelDefinition>>;
29
- reasoning: z.ZodOptional<z.ZodCustom<AgentReasoningDefinition, AgentReasoningDefinition>>;
30
- local: z.ZodOptional<z.ZodObject<{
31
- enabled: z.ZodOptional<z.ZodBoolean>;
32
- }, z.core.$strip>>;
33
- deployed: z.ZodOptional<z.ZodObject<{
34
- credentials: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
35
- pat: z.ZodLiteral<true>;
36
- }, z.core.$strip>, z.ZodCustom<GitHubCredentialProvider, GitHubCredentialProvider>]>>;
37
- source: z.ZodObject<{
38
- git: z.ZodObject<{
39
- directory: z.ZodString;
40
- repository: z.ZodString;
41
- }, z.core.$strip>;
42
- }, z.core.$strip>;
43
- target: z.ZodObject<{
44
- branch: z.ZodString;
45
- }, z.core.$strip>;
46
- authorize: z.ZodCustom<SelfModificationAuthorization, SelfModificationAuthorization>;
47
- }, z.core.$strip>>;
48
- }, z.core.$strip>>;
4
+ declare const _default: import("eve/extension").ExtensionHandle<StandardSchemaV1<SelfModificationExtensionConfig, SelfModificationExtensionConfig>>;
49
5
  export default _default;
@@ -1 +1 @@
1
- import{boolean,custom,literal,object,string,union}from"../../node_modules/.pnpm/zod@4.5.4/node_modules/zod/v4/classic/schemas.js";import"../../node_modules/.pnpm/zod@4.5.4/node_modules/zod/index.js";import{isAgentReasoningDefinition,isRuntimeLanguageModel}from"#internal/runtime-model.js";import{defineExtension}from"eve/extension";const selfModificationConfigSchema=object({model:custom(e=>typeof e==`string`||isRuntimeLanguageModel(e)).optional(),reasoning:custom(isAgentReasoningDefinition).optional(),local:object({enabled:boolean().optional()}).optional(),deployed:object({credentials:union([object({pat:literal(!0)}),custom(e=>typeof e==`object`&&!!e&&`resolve`in e&&typeof e.resolve==`function`)]).optional(),source:object({git:object({directory:string(),repository:string()})}),target:object({branch:string()}),authorize:custom(e=>typeof e==`function`)}).optional()});var extension_default=defineExtension({config:selfModificationConfigSchema});export{extension_default as default,selfModificationConfigSchema};
1
+ import{selfModificationConfigSchema}from"./config-schema.js";import{defineExtension}from"eve/extension";var extension_default=defineExtension({config:selfModificationConfigSchema});export{extension_default as default};
@@ -0,0 +1,5 @@
1
+ import { type ResolvedSelfModificationConfig } from "../config.js";
2
+ /** Returns a definition only when self-modification is running locally. */
3
+ export declare function resolveLocalOnly<T>(config: ResolvedSelfModificationConfig, definition: T): T | null;
4
+ /** Creates a dynamic definition that is absent from deployed self-modification. */
5
+ export declare function defineLocalOnlyDynamic<T>(definition: T): import("#dynamic/definition.js").DynamicSentinel<Awaited<T> | null>;
@@ -0,0 +1 @@
1
+ import{resolveSelfModificationConfig}from"../config.js";import extension_default from"./extension.js";import{resolveSelfModificationMode}from"../mode.js";import{defineDynamic}from"#dynamic/definition.js";function resolveLocalOnly(e,t){return resolveSelfModificationMode(e)===`local`?t:null}function defineLocalOnlyDynamic(e){return defineDynamic({events:{"session.started":()=>resolveLocalOnly(resolveSelfModificationConfig(extension_default.config),e)}})}export{defineLocalOnlyDynamic,resolveLocalOnly};
@@ -1,14 +1,14 @@
1
- import{resolveSelfModificationConfig}from"../../../config.js";import extension_default from"../../extension.js";import{resolveSelfModificationMode}from"../../../mode.js";import{defineDynamic,defineInstructions}from"eve/instructions";function readTrace(e){return e.data?.trace}function localTraceGuidance(e){let t=readTrace(e);return t===void 0?``:`The invoking trace has ID ${t.traceId}. ${(t.traceFlags&1)==1?`If local segments were captured,`:`This trace was not sampled, so local segments may be absent. If any are present,`} inspect them at /traces/${t.traceId}.`}function renderInstructions(e){return e.filter(e=>e.length>0).join(`
1
+ import{resolveSelfModificationConfig}from"../../../config.js";import extension_default from"../../extension.js";import{resolveSelfModificationMode}from"../../../mode.js";import{defineDynamic,defineInstructions}from"eve/instructions";function renderInstructions(e){return e.filter(e=>e.length>0).join(`
2
2
 
3
- `)}var instructions_default=defineDynamic({events:{"session.started":e=>{let t=resolveSelfModificationMode(resolveSelfModificationConfig(extension_default.config));return t!==`local`&&t!==`deployed`?null:defineInstructions({markdown:renderInstructions([`## Role
3
+ `)}var instructions_default=defineDynamic({events:{"session.started":()=>{let e=resolveSelfModificationMode(resolveSelfModificationConfig(extension_default.config));return e!==`local`&&e!==`deployed`?null:defineInstructions({markdown:renderInstructions([`## Role
4
4
 
5
5
  You are an expert coding assistant operating inside of an eve agent. You help users by reading files, editing code, and writing new files that shape the behavior of the agent itself.`,`## Source workspace
6
6
 
7
7
  The source code of the eve agent is mounted read-write at /source. /source is the authored agent directory. Locate source files with bash. Read source contents with read_file, not shell commands. Before generating an overwrite, ensure read_file has succeeded for that path. Shell reads do not satisfy write_file's read-before-write requirement. edit_file instead validates exact matches against current contents. Never modify source files with bash, sed, awk, redirection, or scripting.
8
8
 
9
- Resolve named tools by filename under /source/tools before searching contents. Tool identifiers derive from filenames and may not occur in the implementation.`,`## Configure this subagent
9
+ Resolve named tools by filename under /source/tools before searching contents. Tool identifiers derive from filenames and may not occur in the implementation.`,`## Changing this subagent
10
10
 
11
- Configure this self-modification subagent's model, reasoning, and policy only through its authored mount. Check /source/extensions/self-modification.ts and /source/extensions/self-modification/extension.ts; modify whichever exists. If neither file exists, this subagent is the bundled eve development default and is using the default settings: first call registry_add with the exact address eve/self-modification to scaffold the authored mount. This known scaffold does not require search_registry.
11
+ When the user explicitly asks to change the self-modification subagent's model, reasoning, or policy, make edits only through its authored mount. For such requests, check /source/extensions/self-modification.ts and /source/extensions/self-modification/extension.ts; modify whichever exists. If neither file exists, this subagent is the bundled eve development default and is using the default settings: first call registry_add with the exact address eve/self-modification to scaffold the authored mount. This known scaffold does not require search_registry.
12
12
 
13
13
  After registry_add reports successful installation, try to read /source/extensions/self-modification.ts and /source/extensions/self-modification/extension.ts. If either is available, modify it. If neither is yet available, you may need to wait for the next turn, by asking the requester to confirm.`,`## Implement changes
14
14
 
@@ -26,11 +26,11 @@ Modifying the behavior of an existing skill or tool does not require a registry
26
26
 
27
27
  Registry installation is outside the source sandbox.`,`## Consult documentation
28
28
 
29
- The eve framework documentation is mounted read-only at /eve-docs. Prefer source and existing local patterns. Before reading docs, identify the specific unresolved API question. Search the relevant file for its heading or term, then read only the bounded surrounding section. Do not concatenate wildcard files or read a full page when a section answers the question. Stop when the question is resolved.`,t===`local`?"## Local environment\n\nThe registry_add tool will complete installation for items that need no setup. In the local dev TUI, a `needs-terminal` result from the tool call automatically opens the existing setup panel for the user to complete setup there. In headless development, if a `needs-terminal` result includes `nextCommand`, present that exact value as the only shell command in your response. Never infer, construct, or rewrite a command: installing an item uses `eve add <item>`; `eve registry add` configures registry namespace mappings and does not install items.\n\nLocal eve dev logs are available read-only at /logs.\nLocal trace segments are mounted read-only at /traces when available. Inspect other traces only when the user asks about another session or broader behavior.\n\nThe application package.json is not mounted. Do not search outside /source for application files. You cannot run host binaries such as git, node, pnpm, or tsc. Use existing imports and registry_add for supported registry installations.":"## Deployed environment\n\nThe registry_add tool may return `completed`, `input-required`, `external-action-required`, `cancelled`, or `failed`. Supply only non-secret structured answers when continuing an `input-required` setup; set `installed: true` so the continuation does not reinstall source. Never request, accept, or repeat secret values. External authorization and secret binding are incomplete follow-up boundaries, not evidence that an integration is active.\n\nThe configured target branch is checked out as a disposable workspace under /workspace/repository. Make ordinary changes through /source, which is the writable view of the configured application's agent/ directory. Publication validates the final repository snapshot, including registry, manifest, and lockfile changes. Never modify Git refs, access GitHub directly, or use shell commands to write files. The sandbox has no reusable GitHub credential after checkout.\n\nComplete all edits and registry installations before publication, and call publish by itself. Before publication, review and summarize the complete intended scope. Call publish once with a concise title and summary. A successful result is only a draft pull request. Return its URL and changed paths, and state that merge and deployment have not occurred.",t===`local`?localTraceGuidance(e):``,`## Work efficiently
29
+ The eve framework documentation is mounted read-only at /eve-docs. Prefer source and existing local patterns. Before reading docs, identify the specific unresolved API question. Search the relevant file for its heading or term, then read only the bounded surrounding section. Do not concatenate wildcard files or read a full page when a section answers the question. Stop when the question is resolved.`,e===`local`?"## Local environment\n\nThe registry_add tool will complete installation for items that need no setup. In the local dev TUI, a `needs-terminal` result from the tool call automatically opens the existing setup panel for the user to complete setup there. In headless development, if a `needs-terminal` result includes `nextCommand`, present that exact value as the only shell command in your response. Never infer, construct, or rewrite a command: installing an item uses `eve add <item>`; `eve registry add` configures registry namespace mappings and does not install items.\n\nLocal eve dev logs are mounted read-only at /logs. Local trace segments are mounted read-only at /traces when available. For latency, failure, token, or behavior analysis, load and follow the `trace_analysis` skill. Trace searches are scoped to the invoking conversation and exclude the current investigation by default.\n\nThe application package.json is not mounted. Do not search outside /source for application files. You cannot run host binaries such as git, node, pnpm, or tsc. Use existing imports and registry_add for supported registry installations.":"## Deployed environment\n\nThe registry_add tool may return `completed`, `input-required`, `external-action-required`, `cancelled`, or `failed`. Supply only non-secret structured answers when continuing an `input-required` setup; set `installed: true` so the continuation does not reinstall source. Never request, accept, or repeat secret values. External authorization and secret binding are incomplete follow-up boundaries, not evidence that an integration is active.\n\nThe configured target branch is checked out as a disposable workspace under /workspace/repository. Make ordinary changes through /source, which is the writable view of the configured application's agent/ directory. Publication validates the final repository snapshot, including registry, manifest, and lockfile changes. Never modify Git refs, access GitHub directly, or use shell commands to write files. The sandbox has no reusable GitHub credential after checkout.\n\nComplete all edits and registry installations before publication, and call publish by itself. Before publication, review and summarize the complete intended scope. Call publish once with a concise title and summary. A successful result is only a draft pull request. Return its URL and changed paths, and state that merge and deployment have not occurred.",`## Work efficiently
30
30
 
31
31
  Skip task lists for simple work - only use them for complex actions. Never spend a turn only reporting status or updating the task list - batch them with other calls.
32
32
 
33
- Treat a successful file-edit tool result as confirmation; do not reread a file solely to verify that the edit succeeded. Do not approximate unavailable build or test commands with broad source searches.`,t===`local`?`## Report results
33
+ Treat a successful file-edit tool result as confirmation; do not reread a file solely to verify that the edit succeeded. Do not approximate unavailable build or test commands with broad source searches.`,e===`local`?`## Report results
34
34
 
35
35
  For source-modification tasks, return a concise handoff to the caller. Use at most four short bullets covering changed paths and behavior, and any required setup or unresolved issues.
36
36
 
@@ -0,0 +1,10 @@
1
+ import type { ResolvedSelfModificationConfig } from "../../../../config.js";
2
+ export declare function resolveTraceAnalysisSkill(config: ResolvedSelfModificationConfig): {
3
+ description: string;
4
+ markdown: string;
5
+ } | null;
6
+ declare const _default: import("eve/skills").DynamicSentinel<{
7
+ description: string;
8
+ markdown: string;
9
+ } | null>;
10
+ export default _default;
@@ -0,0 +1,19 @@
1
+ import{defineLocalOnlyDynamic,resolveLocalOnly}from"../../../local-only.js";import{defineSkill}from"eve/skills";const traceAnalysisSkill=defineSkill({description:`Analyze local eve traces for latency, token usage, failures, repeated tool calls, and discovery inefficiency with a bounded, conversation-scoped investigation.`,markdown:`# Trace analysis
2
+
3
+ Use this workflow when the user asks to review, diagnose, or optimize behavior from local traces.
4
+
5
+ ## Keep the investigation bounded
6
+
7
+ 1. Call \`search_traces\` once with \`limit\` no greater than 5. It is already scoped to the invoking conversation, including its child-agent traces, and excludes the current investigation by default.
8
+ 2. Rank findings across correctness, latency, token usage, and tool-call efficiency. Follow the user's stated priority; do not assume that "improve" means only fixing errors.
9
+ 3. Call \`inspect_trace\` only for the one or two traces needed to explain a high-impact signal. Set \`limit\` to the smallest useful bound, normally 20–40. Its timeline includes bounded argument previews and \`availableFields\` for each span.
10
+ 4. Use \`inspect_trace_spans\` only with span ids returned by a timeline. Include only the required payload fields and batch related spans in one call. An empty \`availableFields\` list means none are recorded, not that the call failed.
11
+ 5. Use the read-only \`/logs\` mount only to corroborate a specific runtime error that the structural trace cannot explain. Search a literal diagnostic fragment with bounded output before reading a file. With no observed failure, skip broad log searches and speculative web searches for possible failures.
12
+ 6. Inspect \`/source\` or \`/eve-docs\` only when evidence points to a persistent authored change or an unresolved API question.
13
+
14
+ Prefer three analysis rounds or fewer. Do not read raw trace segments, search the whole filesystem, or enumerate broad documentation when the bounded tools answer the question.
15
+
16
+ Search and inspection share the same summary. Its durationMs is elapsed time; inspection's modelWorkMs and toolWorkMs sum operation time and may exceed elapsed time when calls overlap. errorSpanCount counts error-bearing spans, not independent failures or final activation outcome; failures ranking uses this count. Token totals sum step usage without counting repeated model counters.
17
+
18
+ For latency, distinguish tool execution time from model round-trip time. Repeated tool counts are leads, not proof that calls are independent; inspect the compact timeline before recommending batching. Report the highest-impact opportunities first.
19
+ `});function resolveTraceAnalysisSkill(e){return resolveLocalOnly(e,traceAnalysisSkill)}var trace_analysis_default=defineLocalOnlyDynamic(traceAnalysisSkill);export{trace_analysis_default as default,resolveTraceAnalysisSkill};
@@ -0,0 +1,128 @@
1
+ import type { ResolvedSelfModificationConfig } from "../../../../config.js";
2
+ export declare function resolveInspectTraceTool(config: ResolvedSelfModificationConfig): (import("eve/tools").ToolDefinition<Record<string, unknown>, {
3
+ traceId: string;
4
+ offset: number;
5
+ timeline: {
6
+ actionDurationMs?: number;
7
+ actionName?: string;
8
+ callId?: string;
9
+ category: "model" | "other" | "tool";
10
+ durationMs: number;
11
+ endOffsetMs: number;
12
+ error?: string;
13
+ model?: string;
14
+ outcome: "completed" | "failed";
15
+ parentSpanId?: string;
16
+ sessionId?: string;
17
+ spanId: string;
18
+ startOffsetMs: number;
19
+ toolName?: string;
20
+ turnId?: string;
21
+ usage?: import("#tracing/local-trace-analysis.js").TraceTokenUsage;
22
+ availableFields: ("arguments" | "error" | "result")[];
23
+ argumentsPreview?: string | undefined;
24
+ }[];
25
+ summary: import("../../../../../tracing/local-trace-summary.ts").LocalTraceSummary;
26
+ modelWorkMs: number;
27
+ toolWorkMs: number;
28
+ groups: readonly import("#tracing/local-trace-analysis.js").TraceAnalysisGroup[];
29
+ total: number;
30
+ hasMore: boolean;
31
+ truncated: boolean;
32
+ }> & {
33
+ execute(input: Record<string, unknown>, ctx: import("eve/tools").ToolContext): Promise<{
34
+ traceId: string;
35
+ offset: number;
36
+ timeline: {
37
+ actionDurationMs?: number;
38
+ actionName?: string;
39
+ callId?: string;
40
+ category: "model" | "other" | "tool";
41
+ durationMs: number;
42
+ endOffsetMs: number;
43
+ error?: string;
44
+ model?: string;
45
+ outcome: "completed" | "failed";
46
+ parentSpanId?: string;
47
+ sessionId?: string;
48
+ spanId: string;
49
+ startOffsetMs: number;
50
+ toolName?: string;
51
+ turnId?: string;
52
+ usage?: import("#tracing/local-trace-analysis.js").TraceTokenUsage;
53
+ availableFields: ("arguments" | "error" | "result")[];
54
+ argumentsPreview?: string | undefined;
55
+ }[];
56
+ summary: import("../../../../../tracing/local-trace-summary.ts").LocalTraceSummary;
57
+ modelWorkMs: number;
58
+ toolWorkMs: number;
59
+ groups: readonly import("#tracing/local-trace-analysis.js").TraceAnalysisGroup[];
60
+ total: number;
61
+ hasMore: boolean;
62
+ truncated: boolean;
63
+ }>;
64
+ }) | null;
65
+ declare const _default: import("eve/tools").DynamicSentinel<(import("eve/tools").ToolDefinition<Record<string, unknown>, {
66
+ traceId: string;
67
+ offset: number;
68
+ timeline: {
69
+ actionDurationMs?: number;
70
+ actionName?: string;
71
+ callId?: string;
72
+ category: "model" | "other" | "tool";
73
+ durationMs: number;
74
+ endOffsetMs: number;
75
+ error?: string;
76
+ model?: string;
77
+ outcome: "completed" | "failed";
78
+ parentSpanId?: string;
79
+ sessionId?: string;
80
+ spanId: string;
81
+ startOffsetMs: number;
82
+ toolName?: string;
83
+ turnId?: string;
84
+ usage?: import("#tracing/local-trace-analysis.js").TraceTokenUsage;
85
+ availableFields: ("arguments" | "error" | "result")[];
86
+ argumentsPreview?: string | undefined;
87
+ }[];
88
+ summary: import("../../../../../tracing/local-trace-summary.ts").LocalTraceSummary;
89
+ modelWorkMs: number;
90
+ toolWorkMs: number;
91
+ groups: readonly import("#tracing/local-trace-analysis.js").TraceAnalysisGroup[];
92
+ total: number;
93
+ hasMore: boolean;
94
+ truncated: boolean;
95
+ }> & {
96
+ execute(input: Record<string, unknown>, ctx: import("eve/tools").ToolContext): Promise<{
97
+ traceId: string;
98
+ offset: number;
99
+ timeline: {
100
+ actionDurationMs?: number;
101
+ actionName?: string;
102
+ callId?: string;
103
+ category: "model" | "other" | "tool";
104
+ durationMs: number;
105
+ endOffsetMs: number;
106
+ error?: string;
107
+ model?: string;
108
+ outcome: "completed" | "failed";
109
+ parentSpanId?: string;
110
+ sessionId?: string;
111
+ spanId: string;
112
+ startOffsetMs: number;
113
+ toolName?: string;
114
+ turnId?: string;
115
+ usage?: import("#tracing/local-trace-analysis.js").TraceTokenUsage;
116
+ availableFields: ("arguments" | "error" | "result")[];
117
+ argumentsPreview?: string | undefined;
118
+ }[];
119
+ summary: import("../../../../../tracing/local-trace-summary.ts").LocalTraceSummary;
120
+ modelWorkMs: number;
121
+ toolWorkMs: number;
122
+ groups: readonly import("#tracing/local-trace-analysis.js").TraceAnalysisGroup[];
123
+ total: number;
124
+ hasMore: boolean;
125
+ truncated: boolean;
126
+ }>;
127
+ }) | null>;
128
+ export default _default;
@@ -0,0 +1 @@
1
+ import{defineLocalOnlyDynamic,resolveLocalOnly}from"../../../local-only.js";import{TRACE_ID,boundedText,detailFields,readTraceSources}from"../../../trace-inspection.js";import{defineTool}from"eve/tools";import{analyzeLocalTrace}from"#tracing/local-trace-analysis.js";const MAX_OFFSET=1e5,inspectTraceTool=defineTool({description:`Inspect one trace as a bounded structural timeline. Use offset to page through larger traces. Tool records include a short argument preview and availableFields; use inspect_trace_spans only for selected raw tool payloads.`,inputSchema:{type:`object`,additionalProperties:!1,properties:{limit:{type:`integer`,minimum:1,maximum:200},offset:{type:`integer`,minimum:0,maximum:MAX_OFFSET,description:`Zero-based record offset for paging through larger traces.`},traceId:{type:`string`,pattern:`^[0-9a-f]{32}$`}},required:[`traceId`]},outputSchema:{type:`object`,additionalProperties:!0},async execute(e,t){let{limit:n,offset:r,traceId:i}=parseInput(e),a=await readTraceSources(i,t),o=analyzeLocalTrace(i,a.map(({span:e})=>e)),s=new Map(a.map(e=>[e.span.spanId,e])),c=o.records.slice(r,r+n).map(e=>{let t=s.get(e.spanId),n=t===void 0?void 0:detailFields(t),r=n===void 0?[]:[`arguments`,`result`,`error`].filter(e=>typeof n[e]==`string`),i=n?.arguments;return{...boundedRecord(e),availableFields:r,...e.category===`tool`&&typeof i==`string`?{argumentsPreview:boundedText(i,200)}:{}}});return{traceId:i,offset:r,timeline:c,summary:o.summary,modelWorkMs:o.modelWorkMs,toolWorkMs:o.toolWorkMs,groups:o.groups,total:o.records.length,hasMore:r+c.length<o.records.length,truncated:r+c.length<o.records.length}}});function resolveInspectTraceTool(e){return resolveLocalOnly(e,inspectTraceTool)}var inspect_trace_default=defineLocalOnlyDynamic(inspectTraceTool);function parseInput(e){if(typeof e!=`object`||!e||Array.isArray(e))throw Error(`Trace inspection input must be an object.`);let t=e;if(typeof t.traceId!=`string`||!TRACE_ID.test(t.traceId))throw Error(`traceId must be a lowercase 32-character hex id.`);if(t.limit!==void 0&&(typeof t.limit!=`number`||!Number.isInteger(t.limit)||t.limit<1||t.limit>200))throw Error(`limit must be an integer between 1 and 200.`);if(t.offset!==void 0&&(typeof t.offset!=`number`||!Number.isInteger(t.offset)||t.offset<0||t.offset>MAX_OFFSET))throw Error(`offset must be an integer between 0 and ${MAX_OFFSET}.`);return{limit:t.limit??40,offset:t.offset??0,traceId:t.traceId}}function boundedRecord(e){return e.error===void 0?e:{...e,error:boundedText(e.error,500)}}export{inspect_trace_default as default,resolveInspectTraceTool};