maka-agent 0.2.0-dev.62.20260928 → 0.2.0-dev.64.20260929

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 (723) hide show
  1. package/LICENSE +15 -15
  2. package/THIRD_PARTY_NOTICES.txt +26 -26
  3. package/native/runtime-host-windows-task-launcher/prebuilds/win32-x64/maka-runtime-host-task-launcher.exe +0 -0
  4. package/node_modules/@agentclientprotocol/sdk/dist/examples/dual-version-agent.js +12 -12
  5. package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.js +52 -0
  6. package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.js +5 -4
  7. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.js +7 -0
  8. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.js +51 -8
  9. package/node_modules/@agentclientprotocol/sdk/package.json +2 -2
  10. package/node_modules/@agentclientprotocol/sdk/schema/schema.json +90 -2
  11. package/node_modules/@agentclientprotocol/sdk/schema/v2/schema.unstable.json +103 -12
  12. package/node_modules/@ai-sdk/anthropic/CHANGELOG.md +140 -0
  13. package/node_modules/@ai-sdk/anthropic/README.md +1 -1
  14. package/node_modules/@ai-sdk/anthropic/dist/index.js +1622 -868
  15. package/node_modules/@ai-sdk/anthropic/dist/internal/index.js +1516 -763
  16. package/node_modules/@ai-sdk/anthropic/docs/05-anthropic.mdx +483 -62
  17. package/node_modules/@ai-sdk/anthropic/package.json +4 -4
  18. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/approval-continuation.js +0 -1
  19. package/node_modules/@ai-sdk/code-mode/dist/code-mode-tool.js +59 -0
  20. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/errors.js +0 -8
  21. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/interrupt-continuation.js +0 -2
  22. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/tool-prompt.js +43 -15
  23. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/package.json +3 -3
  24. package/node_modules/@ai-sdk/cohere/CHANGELOG.md +99 -0
  25. package/node_modules/@ai-sdk/cohere/README.md +1 -1
  26. package/node_modules/@ai-sdk/cohere/dist/index.js +35 -49
  27. package/node_modules/@ai-sdk/cohere/docs/25-cohere.mdx +11 -9
  28. package/node_modules/@ai-sdk/cohere/package.json +4 -4
  29. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/gateway/CHANGELOG.md +183 -0
  30. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/gateway/README.md +1 -1
  31. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/gateway/dist/index.js +587 -245
  32. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/gateway/docs/00-ai-gateway.mdx +235 -30
  33. package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/gateway/package.json +4 -4
  34. package/node_modules/@ai-sdk/google/CHANGELOG.md +180 -0
  35. package/node_modules/@ai-sdk/google/README.md +1 -1
  36. package/node_modules/@ai-sdk/google/dist/index.js +1147 -1130
  37. package/node_modules/@ai-sdk/google/dist/internal/index.js +809 -889
  38. package/node_modules/@ai-sdk/google/docs/15-google.mdx +224 -41
  39. package/node_modules/@ai-sdk/google/package.json +4 -4
  40. package/node_modules/@ai-sdk/open-responses/CHANGELOG.md +109 -0
  41. package/node_modules/@ai-sdk/open-responses/dist/index.js +419 -183
  42. package/node_modules/@ai-sdk/open-responses/docs/06-open-responses.mdx +121 -6
  43. package/node_modules/@ai-sdk/open-responses/package.json +4 -4
  44. package/node_modules/@ai-sdk/openai/CHANGELOG.md +147 -0
  45. package/node_modules/@ai-sdk/openai/README.md +27 -2
  46. package/node_modules/@ai-sdk/openai/dist/index.js +2445 -1828
  47. package/node_modules/@ai-sdk/openai/dist/internal/index.js +2170 -2041
  48. package/node_modules/@ai-sdk/openai/docs/03-openai.mdx +311 -102
  49. package/node_modules/@ai-sdk/openai/package.json +4 -4
  50. package/node_modules/@ai-sdk/openai-compatible/CHANGELOG.md +110 -0
  51. package/node_modules/@ai-sdk/openai-compatible/dist/index.js +120 -130
  52. package/node_modules/@ai-sdk/openai-compatible/dist/internal/index.js +22 -14
  53. package/node_modules/@ai-sdk/openai-compatible/docs/index.mdx +2 -0
  54. package/node_modules/@ai-sdk/openai-compatible/package.json +4 -4
  55. package/node_modules/@ai-sdk/{anthropic/node_modules/@ai-sdk/provider → provider}/CHANGELOG.md +47 -0
  56. package/node_modules/@ai-sdk/{cohere/node_modules/@ai-sdk/provider → provider}/dist/index.js +127 -102
  57. package/node_modules/@ai-sdk/{anthropic/node_modules/@ai-sdk/provider → provider}/package.json +1 -1
  58. package/node_modules/@ai-sdk/provider-utils/CHANGELOG.md +99 -0
  59. package/node_modules/@ai-sdk/provider-utils/dist/experimental-evaluation/index.js +1618 -0
  60. package/node_modules/@ai-sdk/provider-utils/dist/index.js +470 -268
  61. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +3 -1
  62. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/docs/docs/api/Dispatcher.md +1 -0
  63. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/core/request.js +23 -2
  64. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/dispatcher/balanced-pool.js +4 -2
  65. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/dispatcher/client-h1.js +23 -8
  66. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/dispatcher/client-h2.js +84 -19
  67. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/dispatcher/client.js +6 -2
  68. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/handler/cache-handler.js +21 -5
  69. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/handler/retry-handler.js +109 -23
  70. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/interceptor/cache.js +20 -1
  71. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/interceptor/decompress.js +338 -46
  72. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/interceptor/dump.js +10 -23
  73. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/web/eventsource/eventsource-stream.js +245 -150
  74. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/web/websocket/connection.js +19 -9
  75. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/web/websocket/permessage-deflate.js +5 -0
  76. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/lib/web/websocket/stream/websocketstream.js +8 -10
  77. package/node_modules/@ai-sdk/provider-utils/node_modules/undici/package.json +1 -1
  78. package/node_modules/@ai-sdk/provider-utils/package.json +7 -2
  79. package/node_modules/@earendil-works/pi-tui/README.md +8 -2
  80. package/node_modules/@earendil-works/pi-tui/dist/autocomplete.js +18 -11
  81. package/node_modules/@earendil-works/pi-tui/dist/components/editor.js +7 -6
  82. package/node_modules/@earendil-works/pi-tui/dist/fuzzy.js +23 -22
  83. package/node_modules/@earendil-works/pi-tui/dist/index.js +2 -0
  84. package/node_modules/@earendil-works/pi-tui/dist/latex.js +109 -16
  85. package/node_modules/@earendil-works/pi-tui/dist/native-modifiers.js +3 -44
  86. package/node_modules/@earendil-works/pi-tui/dist/native-platform.js +42 -0
  87. package/node_modules/@earendil-works/pi-tui/dist/terminal.js +2 -20
  88. package/node_modules/@earendil-works/pi-tui/dist/tui-alt-screen.js +25 -6
  89. package/node_modules/@earendil-works/pi-tui/dist/utils.js +4 -0
  90. package/node_modules/@earendil-works/pi-tui/native/clipboard.h +170 -0
  91. package/node_modules/@earendil-works/pi-tui/native/darwin/README.md +8 -6
  92. package/node_modules/@earendil-works/pi-tui/native/darwin/build.sh +12 -5
  93. package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-arm64/{darwin-modifiers.node → darwin-platform.node} +0 -0
  94. package/node_modules/@earendil-works/pi-tui/native/darwin/prebuilds/darwin-x64/{darwin-modifiers.node → darwin-platform.node} +0 -0
  95. package/node_modules/@earendil-works/pi-tui/native/darwin/src/darwin-platform.m +93 -0
  96. package/node_modules/@earendil-works/pi-tui/native/linux/README.md +23 -0
  97. package/node_modules/@earendil-works/pi-tui/native/linux/build.sh +65 -0
  98. package/node_modules/@earendil-works/pi-tui/native/linux/prebuilds/linux-arm64/linux-platform-x11.node +0 -0
  99. package/node_modules/@earendil-works/pi-tui/native/linux/prebuilds/linux-x64/linux-platform-x11.node +0 -0
  100. package/node_modules/@earendil-works/pi-tui/native/linux/src/clipboard-worker.h +70 -0
  101. package/node_modules/@earendil-works/pi-tui/native/linux/src/linux-platform-x11.c +274 -0
  102. package/node_modules/@earendil-works/pi-tui/native/napi.h +89 -0
  103. package/node_modules/@earendil-works/pi-tui/native/win32/README.md +16 -7
  104. package/node_modules/@earendil-works/pi-tui/native/win32/build.mjs +7 -4
  105. package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-arm64/win32-platform.node +0 -0
  106. package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-x64/win32-platform.node +0 -0
  107. package/node_modules/@earendil-works/pi-tui/native/win32/src/win32-platform.c +241 -0
  108. package/node_modules/@earendil-works/pi-tui/package.json +11 -4
  109. package/node_modules/@larksuiteoapi/node-sdk/README.md +20 -0
  110. package/node_modules/@larksuiteoapi/node-sdk/README.zh.md +20 -0
  111. package/node_modules/@larksuiteoapi/node-sdk/es/index.js +33 -1
  112. package/node_modules/@larksuiteoapi/node-sdk/lib/index.js +33 -1
  113. package/node_modules/@larksuiteoapi/node-sdk/package.json +1 -1
  114. package/node_modules/@maka/acp-executor-plugin/dist/plugin.mjs +17 -0
  115. package/node_modules/@maka/acp-executor-plugin/package.json +1 -1
  116. package/node_modules/@maka/core/dist/model-web-search.js +2 -3
  117. package/node_modules/@maka/core/dist/relative-time.js +19 -20
  118. package/node_modules/@maka/eval/harbor/egress_filter.py +64 -47
  119. package/node_modules/@maka/eval/harbor/eval_framework.py +3 -3
  120. package/node_modules/@maka/eval/harbor/run_trial.py +2 -2
  121. package/node_modules/@maka/eval/node_modules/undici/README.md +10 -1
  122. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Agent.md +8 -8
  123. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +9 -6
  124. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Dispatcher.md +9 -0
  125. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Errors.md +25 -0
  126. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Fetch.md +10 -0
  127. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Interceptors.md +4 -3
  128. package/node_modules/@maka/eval/node_modules/undici/docs/docs/api/Pool.md +5 -6
  129. package/node_modules/@maka/eval/node_modules/undici/docs/docs/index.md +10 -1
  130. package/node_modules/@maka/eval/node_modules/undici/lib/api/readable.js +1 -2
  131. package/node_modules/@maka/eval/node_modules/undici/lib/core/request.js +23 -2
  132. package/node_modules/@maka/eval/node_modules/undici/lib/core/util.js +0 -39
  133. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/client-h1.js +11 -4
  134. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/client-h2.js +52 -8
  135. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/client.js +6 -1
  136. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/env-http-proxy-agent.js +21 -6
  137. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/pool-base.js +63 -2
  138. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/pool.js +90 -7
  139. package/node_modules/@maka/eval/node_modules/undici/lib/dispatcher/proxy-agent.js +16 -3
  140. package/node_modules/@maka/eval/node_modules/undici/lib/handler/deduplication-handler.js +24 -11
  141. package/node_modules/@maka/eval/node_modules/undici/lib/handler/redirect-handler.js +5 -0
  142. package/node_modules/@maka/eval/node_modules/undici/lib/handler/retry-handler.js +72 -13
  143. package/node_modules/@maka/eval/node_modules/undici/lib/interceptor/cache.js +4 -1
  144. package/node_modules/@maka/eval/node_modules/undici/lib/interceptor/decompress.js +236 -69
  145. package/node_modules/@maka/eval/node_modules/undici/lib/web/cache/cache.js +17 -8
  146. package/node_modules/@maka/eval/node_modules/undici/lib/web/cache/cachestorage.js +11 -5
  147. package/node_modules/@maka/eval/node_modules/undici/lib/web/cookies/index.js +19 -7
  148. package/node_modules/@maka/eval/node_modules/undici/lib/web/cookies/util.js +3 -1
  149. package/node_modules/@maka/eval/node_modules/undici/lib/web/eventsource/eventsource.js +25 -1
  150. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/body.js +22 -15
  151. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/data-url.js +6 -6
  152. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/formdata.js +30 -36
  153. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/headers.js +34 -31
  154. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/index.js +46 -25
  155. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/request.js +74 -79
  156. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/response.js +43 -44
  157. package/node_modules/@maka/eval/node_modules/undici/lib/web/fetch/util.js +7 -7
  158. package/node_modules/@maka/eval/node_modules/undici/lib/web/infra/index.js +16 -1
  159. package/node_modules/@maka/eval/node_modules/undici/lib/web/webidl/index.js +2 -14
  160. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/connection.js +33 -12
  161. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/events.js +43 -26
  162. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/receiver.js +2 -0
  163. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/stream/websocketerror.js +13 -10
  164. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/stream/websocketstream.js +19 -4
  165. package/node_modules/@maka/eval/node_modules/undici/lib/web/websocket/websocket.js +44 -41
  166. package/node_modules/@maka/eval/node_modules/undici/package.json +1 -1
  167. package/node_modules/@maka/mcp/package.json +1 -1
  168. package/node_modules/@maka/runtime/dist/ai-sdk-compaction.js +15 -3
  169. package/node_modules/@maka/runtime/dist/ai-sdk-message-projection.js +33 -3
  170. package/node_modules/@maka/runtime/dist/deepseek-web-search-codec.js +71 -0
  171. package/node_modules/@maka/runtime/dist/history-compaction.js +11 -4
  172. package/node_modules/@maka/runtime/dist/model-adapter.js +9 -5
  173. package/node_modules/@maka/runtime/dist/model-factory.js +4 -0
  174. package/node_modules/@maka/runtime/dist/plugin-agent-service.js +5 -13
  175. package/node_modules/@maka/runtime/dist/plugin-attachment-service.js +5 -13
  176. package/node_modules/@maka/runtime/dist/plugin-composition-loader.js +26 -36
  177. package/node_modules/@maka/runtime/dist/plugin-data-services.js +9 -26
  178. package/node_modules/@maka/runtime/dist/plugin-fs-service.js +5 -13
  179. package/node_modules/@maka/runtime/dist/plugin-goal-service.js +5 -13
  180. package/node_modules/@maka/runtime/dist/plugin-internals.js +78 -0
  181. package/node_modules/@maka/runtime/dist/plugin-llm-service.js +5 -13
  182. package/node_modules/@maka/runtime/dist/plugin-runtime.js +4 -32
  183. package/node_modules/@maka/runtime/dist/plugin-session-query-service.js +5 -13
  184. package/node_modules/@maka/runtime/dist/plugin-shell-service.js +5 -13
  185. package/node_modules/@maka/runtime/dist/plugin-web-service.js +5 -13
  186. package/node_modules/@maka/runtime/dist/stream-graph-coordinator.js +3 -3
  187. package/node_modules/@maka/runtime/dist/workers/filesystem-worker.js +161 -104
  188. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +3 -1
  189. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/docs/docs/api/Dispatcher.md +1 -0
  190. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/core/request.js +23 -2
  191. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/dispatcher/balanced-pool.js +4 -2
  192. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/dispatcher/client-h1.js +23 -8
  193. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/dispatcher/client-h2.js +84 -19
  194. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/dispatcher/client.js +6 -2
  195. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/handler/cache-handler.js +21 -5
  196. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/handler/retry-handler.js +109 -23
  197. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/interceptor/cache.js +20 -1
  198. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/interceptor/decompress.js +338 -46
  199. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/interceptor/dump.js +10 -23
  200. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/web/eventsource/eventsource-stream.js +245 -150
  201. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/web/websocket/connection.js +19 -9
  202. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/web/websocket/permessage-deflate.js +5 -0
  203. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/lib/web/websocket/stream/websocketstream.js +8 -10
  204. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/node_modules/undici/package.json +1 -1
  205. package/node_modules/@maka/runtime/node_modules/@slack/socket-mode/package.json +1 -1
  206. package/node_modules/@maka/runtime/node_modules/undici/README.md +10 -1
  207. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Agent.md +8 -8
  208. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +9 -6
  209. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Dispatcher.md +9 -0
  210. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Errors.md +25 -0
  211. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Fetch.md +10 -0
  212. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Interceptors.md +4 -3
  213. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/api/Pool.md +5 -6
  214. package/node_modules/@maka/runtime/node_modules/undici/docs/docs/index.md +10 -1
  215. package/node_modules/@maka/runtime/node_modules/undici/lib/api/readable.js +1 -2
  216. package/node_modules/@maka/runtime/node_modules/undici/lib/core/request.js +23 -2
  217. package/node_modules/@maka/runtime/node_modules/undici/lib/core/util.js +0 -39
  218. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/client-h1.js +11 -4
  219. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/client-h2.js +52 -8
  220. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/client.js +6 -1
  221. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/env-http-proxy-agent.js +21 -6
  222. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/pool-base.js +63 -2
  223. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/pool.js +90 -7
  224. package/node_modules/@maka/runtime/node_modules/undici/lib/dispatcher/proxy-agent.js +16 -3
  225. package/node_modules/@maka/runtime/node_modules/undici/lib/handler/deduplication-handler.js +24 -11
  226. package/node_modules/@maka/runtime/node_modules/undici/lib/handler/redirect-handler.js +5 -0
  227. package/node_modules/@maka/runtime/node_modules/undici/lib/handler/retry-handler.js +72 -13
  228. package/node_modules/@maka/runtime/node_modules/undici/lib/interceptor/cache.js +4 -1
  229. package/node_modules/@maka/runtime/node_modules/undici/lib/interceptor/decompress.js +236 -69
  230. package/node_modules/@maka/runtime/node_modules/undici/lib/web/cache/cache.js +17 -8
  231. package/node_modules/@maka/runtime/node_modules/undici/lib/web/cache/cachestorage.js +11 -5
  232. package/node_modules/@maka/runtime/node_modules/undici/lib/web/cookies/index.js +19 -7
  233. package/node_modules/@maka/runtime/node_modules/undici/lib/web/cookies/util.js +3 -1
  234. package/node_modules/@maka/runtime/node_modules/undici/lib/web/eventsource/eventsource.js +25 -1
  235. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/body.js +22 -15
  236. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/data-url.js +6 -6
  237. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/formdata.js +30 -36
  238. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/headers.js +34 -31
  239. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/index.js +46 -25
  240. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/request.js +74 -79
  241. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/response.js +43 -44
  242. package/node_modules/@maka/runtime/node_modules/undici/lib/web/fetch/util.js +7 -7
  243. package/node_modules/@maka/runtime/node_modules/undici/lib/web/infra/index.js +16 -1
  244. package/node_modules/@maka/runtime/node_modules/undici/lib/web/webidl/index.js +2 -14
  245. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/connection.js +33 -12
  246. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/events.js +43 -26
  247. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/receiver.js +2 -0
  248. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/stream/websocketerror.js +13 -10
  249. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/stream/websocketstream.js +19 -4
  250. package/node_modules/@maka/runtime/node_modules/undici/lib/web/websocket/websocket.js +44 -41
  251. package/node_modules/@maka/runtime/node_modules/undici/package.json +1 -1
  252. package/node_modules/@maka/runtime/package.json +11 -11
  253. package/node_modules/@maka/runtime-host/dist/adapter/session-projector.js +3 -7
  254. package/node_modules/@maka/runtime-host/dist/candidate-cli.js +7 -7
  255. package/node_modules/@maka/runtime-host/dist/protocol/turn.js +20 -8
  256. package/node_modules/@maka/runtime-host/dist/server/message-coordinator.js +107 -63
  257. package/node_modules/@maka/runtime-host/dist/server/root-turn-coordinator.js +1 -3
  258. package/node_modules/@maka/runtime-host/dist/server/session-continuity-coordinator.js +51 -16
  259. package/node_modules/@maka/runtime-host/package.json +2 -2
  260. package/node_modules/@maka/storage/dist/project-catalog.js +13 -20
  261. package/node_modules/@modelcontextprotocol/client/dist/index-BCtJi0p5.d.mts.map +1 -0
  262. package/node_modules/@modelcontextprotocol/client/dist/index-CEk3qkZM.d.cts.map +1 -0
  263. package/node_modules/@modelcontextprotocol/client/dist/index.cjs +375 -60
  264. package/node_modules/@modelcontextprotocol/client/dist/index.d.cts.map +1 -1
  265. package/node_modules/@modelcontextprotocol/client/dist/index.d.mts.map +1 -1
  266. package/node_modules/@modelcontextprotocol/client/dist/index.mjs +369 -61
  267. package/node_modules/@modelcontextprotocol/client/dist/shimsWorkerd.cjs +1 -1
  268. package/node_modules/@modelcontextprotocol/client/dist/shimsWorkerd.mjs +1 -1
  269. package/node_modules/@modelcontextprotocol/client/dist/{src-NAgB4Mp8.cjs → src-D0qEN74R.cjs} +111 -38
  270. package/node_modules/@modelcontextprotocol/client/dist/{src-D_zzAWoS.mjs → src-DDAAhLnO.mjs} +106 -33
  271. package/node_modules/@modelcontextprotocol/client/dist/stdio.cjs +8 -2
  272. package/node_modules/@modelcontextprotocol/client/dist/stdio.d.cts.map +1 -1
  273. package/node_modules/@modelcontextprotocol/client/dist/stdio.d.mts.map +1 -1
  274. package/node_modules/@modelcontextprotocol/client/dist/stdio.mjs +8 -2
  275. package/node_modules/@modelcontextprotocol/{core/dist/auth-hYtaIUZm.d.cts.map → client/node_modules/@modelcontextprotocol/core/dist/auth--n_Yzytt.d.cts.map} +1 -1
  276. package/node_modules/@modelcontextprotocol/{core/dist/auth-CfDMXiII.cjs → client/node_modules/@modelcontextprotocol/core/dist/auth-4-zilcqg.cjs} +3 -2
  277. package/node_modules/@modelcontextprotocol/{core/dist/auth-CUe6YdwF.mjs → client/node_modules/@modelcontextprotocol/core/dist/auth-CGP0BDVq.mjs} +3 -2
  278. package/node_modules/@modelcontextprotocol/{core/dist/auth-BWdKR39I.d.mts.map → client/node_modules/@modelcontextprotocol/core/dist/auth-YUQV3RRv.d.mts.map} +1 -1
  279. package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/index.cjs +1 -1
  280. package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/index.mjs +1 -1
  281. package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/internal.cjs +1 -1
  282. package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/internal.mjs +1 -1
  283. package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/package.json +1 -1
  284. package/node_modules/@modelcontextprotocol/client/package.json +4 -4
  285. package/node_modules/@types/node/README.md +2 -2
  286. package/node_modules/@types/node/package.json +2 -17
  287. package/node_modules/{@maka/runtime/node_modules/ai → ai}/CHANGELOG.md +311 -0
  288. package/node_modules/{@maka/runtime/node_modules/ai → ai}/README.md +6 -6
  289. package/node_modules/{@maka/runtime/node_modules/ai → ai}/dist/index.js +4830 -1974
  290. package/node_modules/{@maka/runtime/node_modules/ai → ai}/dist/internal/index.js +694 -332
  291. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/00-introduction/index.mdx +1 -1
  292. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/02-providers-and-models.mdx +5 -0
  293. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/03-prompts.mdx +1 -1
  294. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/04-tools.mdx +2 -2
  295. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/06-provider-options.mdx +11 -11
  296. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/00-choosing-a-provider.mdx +4 -4
  297. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/02-nextjs-app-router.mdx +3 -3
  298. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/03-nextjs-pages-router.mdx +4 -4
  299. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/04-svelte.mdx +7 -7
  300. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/05-nuxt.mdx +8 -8
  301. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/06-nodejs.mdx +3 -3
  302. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/07-expo.mdx +10 -3
  303. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/08-tanstack-start.mdx +3 -3
  304. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/09-coding-agents.mdx +1 -1
  305. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/02-building-agents.mdx +2 -2
  306. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/03-workflows.mdx +2 -2
  307. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/04-loop-control.mdx +1 -1
  308. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/05-configuring-call-options.mdx +4 -2
  309. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/06-memory.mdx +2 -2
  310. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/06-policy-tool-approvals.mdx +2 -2
  311. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/06-tool-approvals.mdx +16 -0
  312. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/07-workflow-agent.mdx +12 -12
  313. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/08-terminal-ui.mdx +14 -10
  314. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/05-generating-text.mdx +2 -2
  315. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/15-tools-and-tool-calling.mdx +6 -1
  316. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/16-mcp-tools.mdx +31 -0
  317. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/17-mcp-apps.mdx +2 -2
  318. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/18-code-mode.mdx +50 -0
  319. package/node_modules/ai/docs/03-ai-sdk-core/19-tool-search.mdx +82 -0
  320. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/20-prompt-engineering.mdx +1 -1
  321. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/26-reasoning.mdx +15 -14
  322. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/31-reranking.mdx +12 -10
  323. package/node_modules/ai/docs/03-ai-sdk-core/32-evaluation.mdx +287 -0
  324. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/35-image-generation.mdx +40 -2
  325. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/36-realtime.mdx +41 -18
  326. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/36-transcription.mdx +1 -0
  327. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/37-speech.mdx +8 -6
  328. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/39-file-uploads.mdx +1 -1
  329. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/40-middleware.mdx +92 -7
  330. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/41-skill-uploads.mdx +1 -1
  331. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/42-batch.mdx +2 -3
  332. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/45-provider-management.mdx +31 -21
  333. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/55-testing.mdx +75 -0
  334. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/60-telemetry.mdx +57 -4
  335. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/65-devtools.mdx +3 -3
  336. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/65-lifecycle-callbacks.mdx +132 -7
  337. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/index.mdx +6 -0
  338. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/01-overview.mdx +3 -2
  339. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/02-harness-agent.mdx +151 -112
  340. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/03-tools.mdx +47 -22
  341. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/04-skills.mdx +0 -4
  342. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/05-harness-adapters.mdx +3 -3
  343. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/06-workflow-utilities.mdx +43 -9
  344. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/07-ui.mdx +33 -30
  345. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/08-terminal-ui.mdx +8 -6
  346. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/01-overview.mdx +1 -1
  347. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/02-chatbot.mdx +47 -21
  348. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/03-chatbot-message-persistence.mdx +46 -3
  349. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/03-chatbot-resume-streams.mdx +11 -4
  350. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/03-chatbot-tool-usage.mdx +10 -1
  351. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/05-completion.mdx +1 -1
  352. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/08-object-generation.mdx +4 -1
  353. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/21-error-handling.mdx +28 -2
  354. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/21-transport.mdx +1 -1
  355. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/02-streaming-react-components.mdx +5 -5
  356. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/04-multistep-interfaces.mdx +2 -2
  357. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/06-loading-state.mdx +1 -1
  358. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/10-migrating-to-ui.mdx +3 -3
  359. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/02-stopping-streams.mdx +8 -0
  360. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/04-caching.mdx +2 -1
  361. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/11-secure-url-fetching.mdx +47 -2
  362. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/01-generate-text.mdx +13 -4
  363. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/02-stream-text.mdx +16 -7
  364. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/06-rerank.mdx +5 -5
  365. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/11-transcribe.mdx +1 -1
  366. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/12-generate-speech.mdx +3 -3
  367. package/node_modules/ai/docs/07-reference/01-ai-sdk-core/14-evaluate.mdx +74 -0
  368. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/16-tool-loop-agent.mdx +4 -2
  369. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/20-start-batch.mdx +1 -1
  370. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/20-tool.mdx +7 -0
  371. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/22-dynamic-tool.mdx +7 -0
  372. package/node_modules/ai/docs/07-reference/01-ai-sdk-core/23-tool-search.mdx +76 -0
  373. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/32-validate-ui-messages.mdx +30 -0
  374. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/33-safe-validate-ui-messages.mdx +12 -0
  375. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/40-provider-registry.mdx +19 -1
  376. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/42-custom-provider.mdx +22 -4
  377. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/60-wrap-language-model.mdx +1 -1
  378. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/61-wrap-image-model.mdx +17 -2
  379. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/index.mdx +6 -0
  380. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/01-use-chat.mdx +1 -1
  381. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/03-use-object.mdx +4 -1
  382. package/node_modules/ai/docs/07-reference/02-ai-sdk-ui/05-use-realtime.mdx +563 -0
  383. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/31-convert-to-model-messages.mdx +12 -0
  384. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/40-create-ui-message-stream.mdx +9 -3
  385. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/50-direct-chat-transport.mdx +3 -3
  386. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/01-stream-ui.mdx +2 -1
  387. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/02-create-ai.mdx +1 -1
  388. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/03-create-streamable-ui.mdx +1 -1
  389. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/04-ai-sdk-workflow/01-workflow-agent.mdx +8 -8
  390. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/04-ai-sdk-workflow/02-workflow-chat-transport.mdx +4 -4
  391. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-api-call-error.mdx +4 -0
  392. package/node_modules/ai/docs/07-reference/05-ai-sdk-errors/ai-evaluation-unsupported-question-type-error.mdx +31 -0
  393. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-such-model-error.mdx +4 -0
  394. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-such-provider-error.mdx +4 -0
  395. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-ui-message-stream-error.mdx +6 -2
  396. package/node_modules/ai/docs/07-reference/05-ai-sdk-errors/index.mdx +138 -0
  397. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/06-ai-sdk-tui/01-run-agent-tui.mdx +13 -9
  398. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/29-migration-guide-4-0.mdx +5 -5
  399. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/37-migration-guide-3-3.mdx +1 -1
  400. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/11-use-chat-custom-request-options.mdx +3 -3
  401. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/13-repeated-assistant-messages.mdx +2 -2
  402. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/17-use-chat-stale-body-data.mdx +1 -1
  403. package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/70-high-memory-usage-with-images.mdx +2 -2
  404. package/node_modules/{@maka/runtime/node_modules/ai → ai}/package.json +13 -13
  405. package/node_modules/image-dimensions/cli.js +18 -3
  406. package/node_modules/image-dimensions/index.js +7 -5
  407. package/node_modules/image-dimensions/package.json +4 -1
  408. package/node_modules/image-dimensions/readme.md +2 -1
  409. package/node_modules/image-dimensions/types/avif.js +2 -24
  410. package/node_modules/image-dimensions/types/heic.js +2 -24
  411. package/node_modules/image-dimensions/types/jpeg.js +28 -7
  412. package/node_modules/image-dimensions/types/png.js +13 -2
  413. package/node_modules/image-dimensions/types/webp.js +20 -36
  414. package/node_modules/image-dimensions/utilities.js +184 -60
  415. package/node_modules/ip-address/README.md +145 -135
  416. package/node_modules/ip-address/dist/common.js +48 -0
  417. package/node_modules/ip-address/dist/ipv4.js +117 -11
  418. package/node_modules/ip-address/dist/ipv6.js +162 -48
  419. package/node_modules/ip-address/dist/v4/constants.js +40 -1
  420. package/node_modules/ip-address/dist/v6/constants.js +47 -1
  421. package/node_modules/ip-address/package.json +1 -1
  422. package/node_modules/marked/README.md +1 -0
  423. package/node_modules/marked/lib/marked.esm.js +30 -29
  424. package/node_modules/marked/lib/marked.umd.js +30 -29
  425. package/node_modules/marked/man/marked.1 +1 -1
  426. package/node_modules/marked/package.json +11 -11
  427. package/node_modules/systeminformation/lib/battery.js +32 -11
  428. package/node_modules/systeminformation/lib/cpu.js +23 -23
  429. package/node_modules/systeminformation/lib/filesystem.js +14 -8
  430. package/node_modules/systeminformation/lib/memory.js +3 -5
  431. package/node_modules/systeminformation/lib/network.js +8 -2
  432. package/node_modules/systeminformation/lib/osinfo.js +17 -3
  433. package/node_modules/systeminformation/lib/util.js +7 -0
  434. package/node_modules/systeminformation/package.json +1 -1
  435. package/node_modules/undici/README.md +10 -1
  436. package/node_modules/undici/docs/docs/api/Agent.md +8 -8
  437. package/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +9 -6
  438. package/node_modules/undici/docs/docs/api/Dispatcher.md +9 -0
  439. package/node_modules/undici/docs/docs/api/Errors.md +25 -0
  440. package/node_modules/undici/docs/docs/api/Fetch.md +10 -0
  441. package/node_modules/undici/docs/docs/api/Interceptors.md +4 -3
  442. package/node_modules/undici/docs/docs/api/Pool.md +5 -6
  443. package/node_modules/undici/docs/docs/index.md +10 -1
  444. package/node_modules/undici/lib/api/readable.js +1 -2
  445. package/node_modules/undici/lib/core/request.js +23 -2
  446. package/node_modules/undici/lib/core/util.js +0 -39
  447. package/node_modules/undici/lib/dispatcher/client-h1.js +11 -4
  448. package/node_modules/undici/lib/dispatcher/client-h2.js +52 -8
  449. package/node_modules/undici/lib/dispatcher/client.js +6 -1
  450. package/node_modules/undici/lib/dispatcher/env-http-proxy-agent.js +21 -6
  451. package/node_modules/undici/lib/dispatcher/pool-base.js +63 -2
  452. package/node_modules/undici/lib/dispatcher/pool.js +90 -7
  453. package/node_modules/undici/lib/dispatcher/proxy-agent.js +16 -3
  454. package/node_modules/undici/lib/handler/deduplication-handler.js +24 -11
  455. package/node_modules/undici/lib/handler/redirect-handler.js +5 -0
  456. package/node_modules/undici/lib/handler/retry-handler.js +72 -13
  457. package/node_modules/undici/lib/interceptor/cache.js +4 -1
  458. package/node_modules/undici/lib/interceptor/decompress.js +236 -69
  459. package/node_modules/undici/lib/web/cache/cache.js +17 -8
  460. package/node_modules/undici/lib/web/cache/cachestorage.js +11 -5
  461. package/node_modules/undici/lib/web/cookies/index.js +19 -7
  462. package/node_modules/undici/lib/web/cookies/util.js +3 -1
  463. package/node_modules/undici/lib/web/eventsource/eventsource.js +25 -1
  464. package/node_modules/undici/lib/web/fetch/body.js +22 -15
  465. package/node_modules/undici/lib/web/fetch/data-url.js +6 -6
  466. package/node_modules/undici/lib/web/fetch/formdata.js +30 -36
  467. package/node_modules/undici/lib/web/fetch/headers.js +34 -31
  468. package/node_modules/undici/lib/web/fetch/index.js +46 -25
  469. package/node_modules/undici/lib/web/fetch/request.js +74 -79
  470. package/node_modules/undici/lib/web/fetch/response.js +43 -44
  471. package/node_modules/undici/lib/web/fetch/util.js +7 -7
  472. package/node_modules/undici/lib/web/infra/index.js +16 -1
  473. package/node_modules/undici/lib/web/webidl/index.js +2 -14
  474. package/node_modules/undici/lib/web/websocket/connection.js +33 -12
  475. package/node_modules/undici/lib/web/websocket/events.js +43 -26
  476. package/node_modules/undici/lib/web/websocket/receiver.js +2 -0
  477. package/node_modules/undici/lib/web/websocket/stream/websocketerror.js +13 -10
  478. package/node_modules/undici/lib/web/websocket/stream/websocketstream.js +19 -4
  479. package/node_modules/undici/lib/web/websocket/websocket.js +44 -41
  480. package/node_modules/undici/package.json +1 -1
  481. package/package.json +4 -4
  482. package/node_modules/@ai-sdk/anthropic/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  483. package/node_modules/@ai-sdk/cohere/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  484. package/node_modules/@ai-sdk/cohere/node_modules/@ai-sdk/provider/README.md +0 -1
  485. package/node_modules/@ai-sdk/cohere/node_modules/@ai-sdk/provider/package.json +0 -63
  486. package/node_modules/@ai-sdk/google/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  487. package/node_modules/@ai-sdk/google/node_modules/@ai-sdk/provider/README.md +0 -1
  488. package/node_modules/@ai-sdk/google/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  489. package/node_modules/@ai-sdk/google/node_modules/@ai-sdk/provider/package.json +0 -63
  490. package/node_modules/@ai-sdk/open-responses/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  491. package/node_modules/@ai-sdk/open-responses/node_modules/@ai-sdk/provider/README.md +0 -1
  492. package/node_modules/@ai-sdk/open-responses/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  493. package/node_modules/@ai-sdk/open-responses/node_modules/@ai-sdk/provider/package.json +0 -63
  494. package/node_modules/@ai-sdk/openai/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  495. package/node_modules/@ai-sdk/openai/node_modules/@ai-sdk/provider/LICENSE +0 -13
  496. package/node_modules/@ai-sdk/openai/node_modules/@ai-sdk/provider/README.md +0 -1
  497. package/node_modules/@ai-sdk/openai/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  498. package/node_modules/@ai-sdk/openai/node_modules/@ai-sdk/provider/package.json +0 -63
  499. package/node_modules/@ai-sdk/openai-compatible/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  500. package/node_modules/@ai-sdk/openai-compatible/node_modules/@ai-sdk/provider/LICENSE +0 -13
  501. package/node_modules/@ai-sdk/openai-compatible/node_modules/@ai-sdk/provider/README.md +0 -1
  502. package/node_modules/@ai-sdk/openai-compatible/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  503. package/node_modules/@ai-sdk/openai-compatible/node_modules/@ai-sdk/provider/package.json +0 -63
  504. package/node_modules/@ai-sdk/provider-utils/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  505. package/node_modules/@ai-sdk/provider-utils/node_modules/@ai-sdk/provider/LICENSE +0 -13
  506. package/node_modules/@ai-sdk/provider-utils/node_modules/@ai-sdk/provider/README.md +0 -1
  507. package/node_modules/@ai-sdk/provider-utils/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  508. package/node_modules/@ai-sdk/provider-utils/node_modules/@ai-sdk/provider/package.json +0 -63
  509. package/node_modules/@earendil-works/pi-tui/native/darwin/src/darwin-modifiers.c +0 -70
  510. package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-arm64/win32-console-mode.node +0 -0
  511. package/node_modules/@earendil-works/pi-tui/native/win32/prebuilds/win32-x64/win32-console-mode.node +0 -0
  512. package/node_modules/@earendil-works/pi-tui/native/win32/src/win32-console-mode.c +0 -119
  513. package/node_modules/@maka/runtime/node_modules/@ai-sdk/code-mode/LICENSE +0 -13
  514. package/node_modules/@maka/runtime/node_modules/@ai-sdk/code-mode/dist/code-mode-tool.js +0 -40
  515. package/node_modules/@maka/runtime/node_modules/@ai-sdk/gateway/LICENSE +0 -13
  516. package/node_modules/@maka/runtime/node_modules/@ai-sdk/provider/CHANGELOG.md +0 -1262
  517. package/node_modules/@maka/runtime/node_modules/@ai-sdk/provider/LICENSE +0 -13
  518. package/node_modules/@maka/runtime/node_modules/@ai-sdk/provider/README.md +0 -1
  519. package/node_modules/@maka/runtime/node_modules/@ai-sdk/provider/dist/index.js +0 -426
  520. package/node_modules/@maka/runtime/node_modules/@ai-sdk/provider/package.json +0 -63
  521. package/node_modules/@maka/runtime/node_modules/ai/LICENSE +0 -13
  522. package/node_modules/@maka/runtime/node_modules/ai/docs/07-reference/02-ai-sdk-ui/05-use-realtime.mdx +0 -247
  523. package/node_modules/@maka/runtime/node_modules/ai/docs/07-reference/05-ai-sdk-errors/index.mdx +0 -43
  524. package/node_modules/@modelcontextprotocol/client/dist/index-CHhhk6PQ.d.cts.map +0 -1
  525. package/node_modules/@modelcontextprotocol/client/dist/index-D4xIIEF6.d.mts.map +0 -1
  526. /package/node_modules/@ai-sdk/{anthropic/node_modules/@ai-sdk/provider → code-mode}/LICENSE +0 -0
  527. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/README.md +0 -0
  528. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/approval.js +0 -0
  529. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/continuation-capability.js +0 -0
  530. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/direct-tool-call.js +0 -0
  531. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/host-interrupt.js +0 -0
  532. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/index.js +0 -0
  533. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/run-code-mode.js +0 -0
  534. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/tool-invocation.js +0 -0
  535. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/types.js +0 -0
  536. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/dist/utils/serialization.js +0 -0
  537. /package/node_modules/{@maka/runtime/node_modules/@ai-sdk → @ai-sdk}/code-mode/src/tsconfig.json +0 -0
  538. /package/node_modules/@ai-sdk/{cohere/node_modules/@ai-sdk/provider → gateway}/LICENSE +0 -0
  539. /package/node_modules/@ai-sdk/{google/node_modules/@ai-sdk/provider → provider}/LICENSE +0 -0
  540. /package/node_modules/@ai-sdk/{anthropic/node_modules/@ai-sdk/provider → provider}/README.md +0 -0
  541. /package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/LICENSE +0 -0
  542. /package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/README.md +0 -0
  543. /package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/internal.d.cts.map +0 -0
  544. /package/node_modules/@modelcontextprotocol/{core → client/node_modules/@modelcontextprotocol/core}/dist/internal.d.mts.map +0 -0
  545. /package/node_modules/{@ai-sdk/open-responses/node_modules/@ai-sdk/provider → ai}/LICENSE +0 -0
  546. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/01-overview.mdx +0 -0
  547. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/05-streaming.mdx +0 -0
  548. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-foundations/index.mdx +0 -0
  549. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/01-navigating-the-library.mdx +0 -0
  550. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/02-getting-started/index.mdx +0 -0
  551. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/01-overview.mdx +0 -0
  552. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/06-subagents.mdx +0 -0
  553. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-agents/index.mdx +0 -0
  554. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/01-overview.mdx +0 -0
  555. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/10-generating-structured-data.mdx +0 -0
  556. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/17-runtime-and-tool-context.mdx +0 -0
  557. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/25-settings.mdx +0 -0
  558. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/30-embeddings.mdx +0 -0
  559. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/36-translation.mdx +0 -0
  560. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/38-video-generation.mdx +0 -0
  561. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-core/50-error-handling.mdx +0 -0
  562. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/03-ai-sdk-harnesses/index.mdx +0 -0
  563. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/04-generative-user-interfaces.mdx +0 -0
  564. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/20-streaming-data.mdx +0 -0
  565. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/24-reading-ui-message-streams.mdx +0 -0
  566. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/25-message-metadata.mdx +0 -0
  567. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/50-stream-protocol.mdx +0 -0
  568. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/04-ai-sdk-ui/index.mdx +0 -0
  569. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/01-overview.mdx +0 -0
  570. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/03-generative-ui-state.mdx +0 -0
  571. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/03-saving-and-restoring-states.mdx +0 -0
  572. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/05-streaming-values.mdx +0 -0
  573. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/08-error-handling.mdx +0 -0
  574. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/09-authentication.mdx +0 -0
  575. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/05-ai-sdk-rsc/index.mdx +0 -0
  576. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/01-prompt-engineering.mdx +0 -0
  577. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/03-backpressure.mdx +0 -0
  578. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/05-multiple-streamables.mdx +0 -0
  579. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/06-rate-limiting.mdx +0 -0
  580. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/07-rendering-ui-with-language-models.mdx +0 -0
  581. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/08-model-as-router.mdx +0 -0
  582. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/09-multistep-interfaces.mdx +0 -0
  583. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/09-sequential-generations.mdx +0 -0
  584. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/10-vercel-deployment-guide.mdx +0 -0
  585. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/06-advanced/index.mdx +0 -0
  586. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/05-embed.mdx +0 -0
  587. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/06-embed-many.mdx +0 -0
  588. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/10-generate-image.mdx +0 -0
  589. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/11-stream-transcribe.mdx +0 -0
  590. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/11-stream-translate.mdx +0 -0
  591. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/13-generate-video.mdx +0 -0
  592. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/14-upload-file.mdx +0 -0
  593. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/14-upload-skill.mdx +0 -0
  594. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/15-agent.mdx +0 -0
  595. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/17-create-agent-ui-stream.mdx +0 -0
  596. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/18-create-agent-ui-stream-response.mdx +0 -0
  597. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/18-pipe-agent-ui-stream-to-response.mdx +0 -0
  598. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/21-get-batch-status.mdx +0 -0
  599. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/22-get-batch-results.mdx +0 -0
  600. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/23-cancel-batch.mdx +0 -0
  601. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/23-create-mcp-client.mdx +0 -0
  602. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/23-get-realtime-tool-definitions.mdx +0 -0
  603. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/24-list-batches.mdx +0 -0
  604. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/24-mcp-apps.mdx +0 -0
  605. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/24-mcp-stdio-transport.mdx +0 -0
  606. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/25-json-schema.mdx +0 -0
  607. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/26-zod-schema.mdx +0 -0
  608. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/27-valibot-schema.mdx +0 -0
  609. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/28-output.mdx +0 -0
  610. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/29-filter-active-tools.mdx +0 -0
  611. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/30-model-message.mdx +0 -0
  612. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/31-ui-message.mdx +0 -0
  613. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/34-sandbox.mdx +0 -0
  614. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/50-cosine-similarity.mdx +0 -0
  615. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/65-language-model-v2-middleware.mdx +0 -0
  616. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/66-extract-reasoning-middleware.mdx +0 -0
  617. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/67-simulate-streaming-middleware.mdx +0 -0
  618. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/68-default-instructions-middleware.mdx +0 -0
  619. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/68-default-settings-middleware.mdx +0 -0
  620. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/69-add-tool-input-examples-middleware.mdx +0 -0
  621. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/70-extract-json-middleware.mdx +0 -0
  622. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/70-is-step-count.mdx +0 -0
  623. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/71-has-tool-call.mdx +0 -0
  624. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/72-loop-finished.mdx +0 -0
  625. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/75-simulate-readable-stream.mdx +0 -0
  626. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/80-smooth-stream.mdx +0 -0
  627. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/90-generate-id.mdx +0 -0
  628. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/91-create-id-generator.mdx +0 -0
  629. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/01-ai-sdk-core/92-default-generated-file.mdx +0 -0
  630. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/02-use-completion.mdx +0 -0
  631. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/32-prune-messages.mdx +0 -0
  632. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/41-create-ui-message-stream-response.mdx +0 -0
  633. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/42-pipe-ui-message-stream-to-response.mdx +0 -0
  634. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/43-read-ui-message-stream.mdx +0 -0
  635. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/46-infer-ui-tools.mdx +0 -0
  636. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/47-infer-ui-tool.mdx +0 -0
  637. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/48-mcp-app-renderer.mdx +0 -0
  638. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/02-ai-sdk-ui/index.mdx +0 -0
  639. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/04-create-streamable-value.mdx +0 -0
  640. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/05-read-streamable-value.mdx +0 -0
  641. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/06-get-ai-state.mdx +0 -0
  642. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/07-get-mutable-ai-state.mdx +0 -0
  643. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/08-use-ai-state.mdx +0 -0
  644. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/09-use-actions.mdx +0 -0
  645. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/10-use-ui-state.mdx +0 -0
  646. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/11-use-streamable-value.mdx +0 -0
  647. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/20-render.mdx +0 -0
  648. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/03-ai-sdk-rsc/index.mdx +0 -0
  649. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/04-ai-sdk-workflow/03-generate-video.mdx +0 -0
  650. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/04-ai-sdk-workflow/index.mdx +0 -0
  651. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-download-error.mdx +0 -0
  652. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-empty-response-body-error.mdx +0 -0
  653. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-argument-error.mdx +0 -0
  654. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-data-content-error.mdx +0 -0
  655. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-message-role-error.mdx +0 -0
  656. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-prompt-error.mdx +0 -0
  657. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-response-data-error.mdx +0 -0
  658. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-tool-approval-error.mdx +0 -0
  659. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-tool-approval-signature-error.mdx +0 -0
  660. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-invalid-tool-input-error.mdx +0 -0
  661. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-json-parse-error.mdx +0 -0
  662. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-load-api-key-error.mdx +0 -0
  663. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-load-setting-error.mdx +0 -0
  664. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-message-conversion-error.mdx +0 -0
  665. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-content-generated-error.mdx +0 -0
  666. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-image-generated-error.mdx +0 -0
  667. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-object-generated-error.mdx +0 -0
  668. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-output-generated-error.mdx +0 -0
  669. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-speech-generated-error.mdx +0 -0
  670. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-such-provider-reference-error.mdx +0 -0
  671. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-such-tool-error.mdx +0 -0
  672. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-transcript-generated-error.mdx +0 -0
  673. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-translation-generated-error.mdx +0 -0
  674. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-no-video-generated-error.mdx +0 -0
  675. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-retry-error.mdx +0 -0
  676. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-stream-provider-error.mdx +0 -0
  677. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-too-many-embedding-values-for-call-error.mdx +0 -0
  678. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-tool-call-not-found-for-approval-error.mdx +0 -0
  679. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-tool-call-repair-error.mdx +0 -0
  680. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-tool-choice-violation-error.mdx +0 -0
  681. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-type-validation-error.mdx +0 -0
  682. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/05-ai-sdk-errors/ai-unsupported-functionality-error.mdx +0 -0
  683. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/06-ai-sdk-tui/index.mdx +0 -0
  684. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/07-reference/index.mdx +0 -0
  685. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/00-versioning.mdx +0 -0
  686. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/23-migration-guide-7-0.mdx +0 -0
  687. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/24-migration-guide-6-0.mdx +0 -0
  688. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/25-migration-guide-5-0-data.mdx +0 -0
  689. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/26-migration-guide-5-0.mdx +0 -0
  690. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/27-migration-guide-4-2.mdx +0 -0
  691. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/28-migration-guide-4-1.mdx +0 -0
  692. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/36-migration-guide-3-4.mdx +0 -0
  693. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/38-migration-guide-3-2.mdx +0 -0
  694. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/39-migration-guide-3-1.mdx +0 -0
  695. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/08-migration-guides/index.mdx +0 -0
  696. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/01-azure-stream-slow.mdx +0 -0
  697. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/03-server-actions-in-client-components.mdx +0 -0
  698. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/04-strange-stream-output.mdx +0 -0
  699. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/05-streamable-ui-errors.mdx +0 -0
  700. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/05-tool-invocation-missing-result.mdx +0 -0
  701. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/06-streaming-not-working-when-deployed.mdx +0 -0
  702. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/06-streaming-not-working-when-proxied.mdx +0 -0
  703. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/06-timeout-on-vercel.mdx +0 -0
  704. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/07-unclosed-streams.mdx +0 -0
  705. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/08-use-chat-failed-to-parse-stream.mdx +0 -0
  706. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/09-client-stream-error.mdx +0 -0
  707. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/10-use-chat-tools-no-response.mdx +0 -0
  708. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/12-typescript-performance-zod.mdx +0 -0
  709. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/12-use-chat-an-error-occurred.mdx +0 -0
  710. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/14-stream-abort-handling.mdx +0 -0
  711. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/14-tool-calling-with-structured-outputs.mdx +0 -0
  712. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/15-abort-breaks-resumable-streams.mdx +0 -0
  713. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/15-stream-text-not-working.mdx +0 -0
  714. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/16-streaming-status-delay.mdx +0 -0
  715. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/18-ontoolcall-type-narrowing.mdx +0 -0
  716. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/19-unsupported-model-version.mdx +0 -0
  717. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/20-no-object-generated-content-filter.mdx +0 -0
  718. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/21-missing-tool-results-error.mdx +0 -0
  719. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/30-model-is-not-assignable-to-type.mdx +0 -0
  720. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/40-typescript-cannot-find-namespace-jsx.mdx +0 -0
  721. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/50-react-maximum-update-depth-exceeded.mdx +0 -0
  722. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/60-jest-cannot-find-module-ai-rsc.mdx +0 -0
  723. /package/node_modules/{@maka/runtime/node_modules/ai → ai}/docs/09-troubleshooting/index.mdx +0 -0
@@ -0,0 +1,563 @@
1
+ ---
2
+ title: experimental_useRealtime
3
+ description: API reference for the experimental_useRealtime hook.
4
+ ---
5
+
6
+ # `experimental_useRealtime()`
7
+
8
+ <Note type="warning">
9
+ `experimental_useRealtime` is an experimental feature.
10
+ </Note>
11
+
12
+ Creates a browser-side realtime session for bidirectional audio and text
13
+ conversations with a realtime provider model.
14
+
15
+ The hook supports token-based provider WebSockets, application-owned WebSocket
16
+ relays, and optional WebRTC where the model declares support. It provides controls for capture and playback, plus turn-based text input
17
+ and tool output. Turn-based conversation messages use `UIMessage[]`; continuous
18
+ transcript fragments remain in `session`.
19
+
20
+ ```tsx
21
+ import { openai } from '@ai-sdk/openai';
22
+ import { experimental_useRealtime } from '@ai-sdk/react';
23
+
24
+ const model = openai.experimental_realtime('gpt-realtime');
25
+
26
+ function Conversation() {
27
+ const realtime = experimental_useRealtime({
28
+ model,
29
+ api: { token: '/api/realtime/setup' },
30
+ });
31
+ return <button onClick={realtime.connect}>Connect</button>;
32
+ }
33
+ ```
34
+
35
+ For AI Gateway, pass `gateway.experimental_realtime(...)` as the model and point
36
+ `api.token` at a server-side setup endpoint that calls
37
+ `gateway.experimental_realtime.getToken()`.
38
+
39
+ Keep the model and session configuration stable across renders, using module scope
40
+ or `useMemo`. Replacing either object replaces the hook's session.
41
+
42
+ ## Continuous conversations
43
+
44
+ For OpenAI Live, use `openai.experimental_realtime('gpt-live-1')` and an application-owned WebSocket
45
+ relay. The relay supplies server credentials and forwards the provider's native
46
+ text frames; it must authenticate clients before accepting connections.
47
+ Use `wss:` in production, keep provider credentials server-side, and apply your
48
+ application's authentication to the relay connection.
49
+
50
+ ```tsx
51
+ import {
52
+ openai,
53
+ type Experimental_OpenAIRealtimeModelLiveOptions,
54
+ } from '@ai-sdk/openai';
55
+ import { experimental_useRealtime } from '@ai-sdk/react';
56
+
57
+ const model = openai.experimental_realtime('gpt-live-1');
58
+ const sessionConfig = {
59
+ instructions: 'Be a concise, friendly assistant.',
60
+ providerOptions: {
61
+ openai: {
62
+ delegation: { type: 'client' },
63
+ } satisfies Experimental_OpenAIRealtimeModelLiveOptions,
64
+ },
65
+ };
66
+
67
+ function LiveConversation() {
68
+ const realtime = experimental_useRealtime({
69
+ model,
70
+ api: { websocket: 'wss://your-app.example/live' },
71
+ sessionConfig,
72
+ });
73
+ return (
74
+ <>
75
+ <button onClick={realtime.connect}>Connect microphone</button>
76
+ <button onClick={() => realtime.close()}>End conversation</button>
77
+ <p>
78
+ {realtime.status}: {realtime.session?.usage?.seconds} seconds
79
+ </p>
80
+ </>
81
+ );
82
+ }
83
+ ```
84
+
85
+ The current continuous browser runtime supports a JSON/PCM16 WebSocket relay media
86
+ profile. Continuous conversation semantics alone do not guarantee support for every
87
+ codec or transport. Applications with their own audio pipeline can use the low-level
88
+ provider for other supported codecs. OpenAI-specific settings
89
+ live under `providerOptions.openai` and use camelCase fields; the provider converts
90
+ them to wire names.
91
+
92
+ ### Application-handled client delegation
93
+
94
+ Live reports client delegation metadata through `session.delegations` and normalized
95
+ events. The application owns any text conversation, agent context, tool execution,
96
+ and result validation. The SDK does not run a generic agent executor for Live, and
97
+ Live delegations do not invoke `onToolCall`.
98
+
99
+ Use `sendEvent` to append context or a result. Set `delegationId` to a known client
100
+ delegation from the current session, or `null` for session-wide context:
101
+
102
+ ```tsx
103
+ await realtime.sendEvent({
104
+ type: 'context-append',
105
+ delegationId: null,
106
+ content: 'The application has confirmed that the appointment is at 3 PM.',
107
+ providerOptions: { openai: { channel: 'commentary' } },
108
+ });
109
+ ```
110
+
111
+ The example uses application-provided content, not task arguments inferred from
112
+ delegation metadata. OpenAI's context channels are `commentary`, `thinking`, and
113
+ `instructions`; reserve `instructions` for trusted application instructions. A
114
+ successful send confirms local submission, not provider acceptance or audible delivery.
115
+
116
+ ### Optional WebRTC
117
+
118
+ For browser-direct Live audio, replace `api.websocket` with
119
+ `api: { session: '/api/realtime-live' }`. The hook posts JSON `{ sdp, sessionConfig }`
120
+ to that application endpoint and expects JSON `{ sdp, sessionId }` back. On the
121
+ server, authenticate the application user and validate the offer and allowed settings.
122
+
123
+ Use a same-origin broker authenticated with your application's session cookie.
124
+ The built-in setup request uses the browser's default same-origin credentials;
125
+ `api.session` does not accept custom authorization headers, a custom fetch, or
126
+ cross-origin credential options. A bearer-token-only or cross-origin cookie broker
127
+ therefore needs an application-owned same-origin endpoint in front of it. The
128
+ answer must contain nonempty `sdp` and `sessionId` strings (after trimming for
129
+ validation), and the JSON response body is limited to 1 MiB.
130
+
131
+ Exchange SDP using the server-held provider key:
132
+
133
+ ```ts
134
+ const answer = await openai
135
+ .experimental_realtime('gpt-live-1')
136
+ .doCreateWebRTCSession({
137
+ sdp,
138
+ sessionConfig: {
139
+ providerOptions: {
140
+ openai: {
141
+ delegation: { type: 'client' },
142
+ client: {
143
+ dataChannel: {
144
+ allowedClientEvents: ['session.close', 'session.thinking.append'],
145
+ allowedServerEvents: [
146
+ { type: 'session.started' },
147
+ { type: 'session.closed' },
148
+ { type: 'session.usage.updated' },
149
+ { type: 'session.delegation.created' },
150
+ { type: 'session.input_transcript.delta' },
151
+ { type: 'session.output_transcript.delta' },
152
+ { type: 'session.thinking.appended' },
153
+ { type: 'error' },
154
+ ],
155
+ },
156
+ },
157
+ },
158
+ },
159
+ },
160
+ });
161
+ // Return Response.json(answer) from the application endpoint.
162
+ ```
163
+
164
+ Permissions are server-owned; override browser-supplied delegation and data-channel
165
+ policy. Allow the lifecycle, caption, delegation, command acknowledgment, and error
166
+ events needed by your UI. The runnable `/realtime-live` example in
167
+ `examples/ai-e2e-next` adds protocol mute and all three context channels.
168
+
169
+ WebRTC negotiates audio through SDP, so omit fixed audio formats and the PCM-only
170
+ `maxPlaybackBufferSeconds`. Audio travels as media rather than JSON audio commands.
171
+ `connect({ capture: false })` starts without microphone capture and keeps a reusable
172
+ audio sender; `resumeAudioCapture()` can attach a microphone later. Microphone access
173
+ requires browser permission and a secure context. Autoplay may require a user gesture
174
+ followed by `resumePlayback()`.
175
+
176
+ One live audio track is selected per attachment, preferring an enabled, unmuted
177
+ track. `isCapturing` follows that sender track, including mute and ended events;
178
+ it never switches tracks automatically. Caller-owned tracks are detached without
179
+ being stopped or disabled. Capture controls serialize sender changes; a stop is
180
+ reported only after detachment succeeds or the peer closes. If detachment fails,
181
+ the peer is closed to stop transmission while leaving borrowed tracks untouched.
182
+ Client delegation remains application-handled on either transport, and Live session
183
+ updates remain unsupported.
184
+
185
+ ## Lifecycle and failure handling
186
+
187
+ Use `status === 'connected'` as the readiness signal; `connect()` does not promise
188
+ to wait for provider readiness. Operational startup errors are reported through
189
+ `onError` and `status`; the legacy resolve-and-report behavior is preserved.
190
+
191
+ `close()` stops local capture and submissions, then drains events until the provider
192
+ confirms final usage or the close deadline expires. A failed close-command send
193
+ uses the shorter accepted-event drain rather than waiting for an acknowledgment
194
+ to an unsent command. Read `session.finalization`: a fulfilled close promise does
195
+ not by itself confirm usage. `disconnect()` and unmount release resources immediately.
196
+
197
+ Hook controls keep stable identities across renders and provider events. A retained
198
+ control targets the current **committed** session, including after a model or endpoint
199
+ change. Uncommitted renders cannot replace the active session or its callbacks.
200
+ Callback-only updates take effect at commit without reconnecting.
201
+
202
+ After unmount, `connect`, `close`, `resumeAudioCapture`, and `resumePlayback` reject
203
+ with a mounted-hook error. Other controls throw that error synchronously, including
204
+ `sendEvent`, which preserves synchronous validation and returns a promise for an
205
+ accepted submission. Retained controls cannot reopen an unmounted session.
206
+
207
+ Command rejection and playback failures are recoverable and do not mark a healthy
208
+ protocol connection as failed. Irrecoverable transport failures and protocol queue
209
+ overflow stop submissions and capture, drain the accepted event prefix, and clean
210
+ up. Events are never arbitrarily dropped while continuing with unreliable state.
211
+ No commands or side-effecting tools are transparently replayed on a replacement
212
+ connection.
213
+
214
+ Continuous Live WebSocket sessions have a 128 KiB outgoing wire-frame limit and a
215
+ 128 KiB combined buffered-send budget, including the next frame and JSON/base64
216
+ encoding overhead. Oversized control messages are rejected, not silently split into
217
+ multiple commands. Keep Live context submissions within this budget; the example
218
+ relay's 128 KiB `maxPayload` aligns with the frame limit. These byte caps do not apply
219
+ to legacy turn-based sessions, which retain their pre-Live unlimited byte policy,
220
+ or to the optional WebRTC transport.
221
+
222
+ The continuous WebSocket PCM playback budget bounds local latency and memory. On overflow, stale queued audio
223
+ is discarded, playback pauses, and `onError` reports an audible gap. The connection
224
+ stays alive; `resumePlayback()` resumes from fresh audio at the live edge. Captions
225
+ and completion of delegated work do not prove that the corresponding audio was heard.
226
+
227
+ ## Import
228
+
229
+ <Snippet
230
+ text={`import { experimental_useRealtime } from "@ai-sdk/react"`}
231
+ prompt={false}
232
+ />
233
+
234
+ ## API Signature
235
+
236
+ ### Parameters
237
+
238
+ <PropertiesTable
239
+ content={[
240
+ {
241
+ name: 'model',
242
+ type: 'Experimental_RealtimeModel',
243
+ description: 'The realtime model to connect to.',
244
+ },
245
+ {
246
+ name: 'api',
247
+ type: '{ token: string } | { websocket: string; protocols?: string[] } | { session: string }',
248
+ description:
249
+ 'Choose one supported connection mechanism: token setup, a WebSocket relay, or a WebRTC SDP endpoint. Conversation semantics and connection capabilities are independent.',
250
+ properties: [
251
+ {
252
+ type: 'Object',
253
+ parameters: [
254
+ {
255
+ name: 'token',
256
+ type: 'string',
257
+ isOptional: true,
258
+ description:
259
+ 'The setup endpoint that returns an Experimental_RealtimeSetupResponse.',
260
+ },
261
+ {
262
+ name: 'session',
263
+ type: 'string',
264
+ isOptional: true,
265
+ description:
266
+ 'Application WebRTC setup endpoint. Accepts JSON { sdp, sessionConfig } and returns JSON { sdp, sessionId }.',
267
+ },
268
+ {
269
+ name: 'websocket',
270
+ type: 'string',
271
+ isOptional: true,
272
+ description:
273
+ 'Application-owned raw-protocol relay URL. Use wss in production; never put provider credentials in the URL.',
274
+ },
275
+ {
276
+ name: 'protocols',
277
+ type: 'string[]',
278
+ isOptional: true,
279
+ description:
280
+ 'Optional relay subprotocols, supported only with websocket.',
281
+ },
282
+ ],
283
+ },
284
+ ],
285
+ },
286
+ {
287
+ name: 'sessionConfig',
288
+ type: 'Partial<Experimental_RealtimeSessionConfig>',
289
+ isOptional: true,
290
+ description:
291
+ 'Provider-neutral session configuration, such as instructions, voice, audio formats, input audio transcription, turn detection, tools, and providerOptions.',
292
+ },
293
+ {
294
+ name: 'sampleRate',
295
+ type: 'number',
296
+ isOptional: true,
297
+ description:
298
+ 'Default audio sample rate used when inputAudioFormat.rate or outputAudioFormat.rate is not specified. Defaults to 24000.',
299
+ },
300
+ {
301
+ name: 'maxEvents',
302
+ type: 'number',
303
+ isOptional: true,
304
+ description:
305
+ 'Maximum number of provider events to keep in the events array. Defaults to 500.',
306
+ },
307
+ {
308
+ name: 'startupTimeoutMs',
309
+ type: 'number',
310
+ isOptional: true,
311
+ description:
312
+ 'Readiness deadline, including transport setup. Defaults to 30000.',
313
+ },
314
+ {
315
+ name: 'closeTimeoutMs',
316
+ type: 'number',
317
+ isOptional: true,
318
+ description:
319
+ 'Deadline for confirmed provider finalization after graceful close. Defaults to 15000.',
320
+ },
321
+ {
322
+ name: 'rtcDisconnectTimeoutMs',
323
+ type: 'number',
324
+ isOptional: true,
325
+ description:
326
+ 'WebRTC peer disconnect recovery grace period. Defaults to 5000. Failed ICE terminates immediately.',
327
+ },
328
+ {
329
+ name: 'maxPlaybackBufferSeconds',
330
+ type: 'number',
331
+ isOptional: true,
332
+ description:
333
+ 'Continuous WebSocket PCM playback budget before reporting a recoverable gap and pausing playback. Defaults to 2. Unsupported with WebRTC.',
334
+ },
335
+ {
336
+ name: 'onToolCall',
337
+ type: '(options: { toolCall: { toolCallId: string; toolName: string; args: unknown } }) => unknown | Promise<unknown> | undefined',
338
+ isOptional: true,
339
+ description:
340
+ 'Turn-based tools only. Return a value to automatically submit it as tool output, or return undefined and call addToolOutput manually later. Live client delegations are application-handled through session metadata and events.',
341
+ },
342
+ {
343
+ name: 'onEvent',
344
+ type: '(event: Experimental_RealtimeServerEvent) => void',
345
+ isOptional: true,
346
+ description: 'Called for every normalized realtime server event.',
347
+ },
348
+ {
349
+ name: 'onError',
350
+ type: '(error: Error) => void',
351
+ isOptional: true,
352
+ description: 'Called when the realtime session encounters an error.',
353
+ },
354
+ ]}
355
+ />
356
+
357
+ ### Returns
358
+
359
+ <PropertiesTable
360
+ content={[
361
+ {
362
+ name: 'status',
363
+ type: "'disconnected' | 'connecting' | 'connected' | 'closing' | 'error'",
364
+ description: 'The current connection status.',
365
+ },
366
+ {
367
+ name: 'messages',
368
+ type: 'UIMessage[]',
369
+ description:
370
+ 'Messages assembled from turn-based response text, transcript, and tool events. Continuous Live transcript fragments are exposed separately through session.transcripts.',
371
+ },
372
+ {
373
+ name: 'events',
374
+ type: 'Experimental_RealtimeServerEvent[]',
375
+ description:
376
+ 'Recent normalized provider events for inspection or debug UI.',
377
+ },
378
+ {
379
+ name: 'isCapturing',
380
+ type: 'boolean',
381
+ description:
382
+ 'Capture state observed through SDK controls and events on the selected audio track. External changes to borrowed tracks may require an explicit refresh; see Capture ownership.',
383
+ },
384
+ {
385
+ name: 'isPlaying',
386
+ type: 'boolean',
387
+ description: 'Whether model audio playback is active.',
388
+ },
389
+ {
390
+ name: 'session',
391
+ type: 'Experimental_RealtimeSessionState | undefined',
392
+ description:
393
+ 'Session lifecycle metadata where supported: sessionId, transcript fragments, client delegation metadata, cumulative voice usage, input mute, terminationReason, and pending/confirmed/unconfirmed finalization. Transcript fragments may overlap or arrive late; they are not complete turns.',
394
+ },
395
+ {
396
+ name: 'connect',
397
+ type: '(options?: { stream?: MediaStream; capture?: boolean }) => Promise<void>',
398
+ description:
399
+ 'Starts the selected connection. Continuous browser sessions acquire microphone audio by default; capture: false opts out. A supplied Live stream remains caller-owned. The zero-argument overload remains usable as an event handler.',
400
+ },
401
+ {
402
+ name: 'close',
403
+ type: '(options?: { eventId?: string }) => Promise<void>',
404
+ description:
405
+ 'Stops capture/submissions and waits for bounded graceful finalization where supported. Inspect session.finalization for confirmation; models without acknowledged close disconnect immediately.',
406
+ },
407
+ {
408
+ name: 'disconnect',
409
+ type: '() => void',
410
+ description:
411
+ 'Immediately releases transports and owned media. Preserves latest usage as unconfirmed unless a terminal provider event was received.',
412
+ },
413
+ {
414
+ name: 'addToolOutput',
415
+ type: '(callId: string, result: unknown) => void',
416
+ description:
417
+ 'Turn-based only: submits a tool result back to the realtime provider. Continuous Live sessions reject this control; append application-handled client delegation results with sendEvent instead.',
418
+ },
419
+ {
420
+ name: 'sendEvent',
421
+ type: '(event: Experimental_RealtimeClientEvent) => Promise<void>',
422
+ description:
423
+ 'Sends a normalized command in order. Resolves on local serialization/submission, not provider acceptance. Validation can throw synchronously; asynchronous send failures reject and are reported through onError. Live context/results use context-append with a known client delegation ID or null.',
424
+ },
425
+ {
426
+ name: 'sendTextMessage',
427
+ type: '(text: string) => void',
428
+ description:
429
+ 'Turn-based only: sends user text and requests a response. Continuous Live sessions reject this control. The application owns its text conversation and supplies Live context through sendEvent.',
430
+ },
431
+ {
432
+ name: 'sendAudio',
433
+ type: '(base64Audio: string) => void',
434
+ description:
435
+ 'Sends a base64-encoded audio chunk to the provider input audio buffer over WebSocket. WebRTC uses media tracks and rejects JSON audio commands.',
436
+ },
437
+ {
438
+ name: 'commitAudio',
439
+ type: '() => void',
440
+ description: 'Turn-based only: commits the provider input audio buffer.',
441
+ },
442
+ {
443
+ name: 'clearAudioBuffer',
444
+ type: '() => void',
445
+ description: 'Turn-based only: clears the provider input audio buffer.',
446
+ },
447
+ {
448
+ name: 'requestResponse',
449
+ type: '(options?: { modalities?: string[] }) => void',
450
+ description: 'Turn-based only: requests a new model response.',
451
+ },
452
+ {
453
+ name: 'cancelResponse',
454
+ type: '() => void',
455
+ description: 'Turn-based only: cancels the active model response.',
456
+ },
457
+ {
458
+ name: 'startAudioCapture',
459
+ type: '(stream: MediaStream) => void',
460
+ description:
461
+ 'Starts or replaces capture with the supplied MediaStream. Live paths borrow tracks; the existing legacy capture API retains ownership of its supplied stream. Async attachment failures are reported through onError.',
462
+ },
463
+ {
464
+ name: 'stopAudioCapture',
465
+ type: '() => void',
466
+ description:
467
+ 'Stops local capture and releases SDK-owned microphone tracks. Caller-owned Live tracks are only detached. Does not change the provider input-mute state.',
468
+ },
469
+ {
470
+ name: 'resumeAudioCapture',
471
+ type: '() => Promise<void>',
472
+ description:
473
+ 'Restarts capture, reusing a supplied Live stream or acquiring a fresh SDK-owned microphone. Does not reconnect the provider.',
474
+ },
475
+ {
476
+ name: 'stopPlayback',
477
+ type: '() => void',
478
+ description: 'Stops queued model audio playback.',
479
+ },
480
+ {
481
+ name: 'resumePlayback',
482
+ type: '() => Promise<void>',
483
+ description:
484
+ 'Retries browser playback after interruption, suspension, or buffer overflow. Discarded stale audio is not replayed.',
485
+ },
486
+ ]}
487
+ />
488
+
489
+ ## Tool Calling
490
+
491
+ For turn-based models such as `gpt-realtime`, tool execution is client-driven.
492
+ Use `onToolCall` to handle tool calls and return the tool output. Keep the model
493
+ stable across callback updates:
494
+
495
+ ```tsx
496
+ const model = openai.experimental_realtime('gpt-realtime');
497
+
498
+ function WeatherConversation() {
499
+ const realtime = experimental_useRealtime({
500
+ model,
501
+ api: { token: '/api/realtime/setup' },
502
+ onToolCall: async ({ toolCall }) => {
503
+ if (toolCall.toolName === 'getWeather') {
504
+ const response = await fetch('/api/weather', {
505
+ method: 'POST',
506
+ headers: { 'Content-Type': 'application/json' },
507
+ body: JSON.stringify(toolCall.args),
508
+ });
509
+
510
+ return response.json();
511
+ }
512
+ },
513
+ });
514
+ return <button onClick={realtime.connect}>Connect</button>;
515
+ }
516
+ ```
517
+
518
+ For tools that require user interaction, return `undefined` from `onToolCall`
519
+ and call `addToolOutput` later.
520
+
521
+ Turn-based providers retain their automatic continuation behavior. Live uses the
522
+ application-handled client delegation flow described above, rather than these tool
523
+ callbacks or turn controls.
524
+
525
+ Outstanding commands are bounded independently from the retained recent-ID history.
526
+ Completed work does not impose a lifetime command quota. Use fresh IDs and keep
527
+ durable operation deduplication in the application; bounded history is not a promise
528
+ of session-long exactly-once execution.
529
+
530
+ ## Capture ownership
531
+
532
+ SDK-acquired tracks are stopped on local capture stop or cleanup. Caller-owned Live
533
+ tracks are detached without stopping or disabling them. `stopAudioCapture()` controls
534
+ local hardware capture; provider `input-audio-mute` controls remote audio processing
535
+ and is tracked through its acknowledgment. These are separate operations: protocol
536
+ mute does not release the microphone, and resuming local capture does not unmute
537
+ provider input. Use `resumeAudioCapture()` to reuse a caller-supplied stream or
538
+ acquire a fresh SDK-owned microphone without reconnecting. The application remains
539
+ responsible for stopping its own tracks when finished with them.
540
+
541
+ `isCapturing` reflects SDK capture controls and events on the selected audio track;
542
+ it does not continuously observe caller-owned media. Assigning `track.enabled`
543
+ does not emit an event, and calling `track.stop()` does not emit an `ended` event.
544
+ After changing borrowed tracks externally, call `startAudioCapture(stream)` or
545
+ `resumeAudioCapture()` to refresh capture state and reattach as needed. If a track
546
+ was stopped, provide a stream with a live audio track; stopped tracks cannot be
547
+ restarted. The SDK does not poll external track state.
548
+
549
+ ## Experimental compatibility
550
+
551
+ This update adds explicit relay options and changes experimental `sendEvent` to
552
+ return a promise. Existing token setups and the no-argument `connect` call remain
553
+ supported. New session state uses `session`, not a provider-branded state object.
554
+ Generic realtime-model consumers must check optional connection methods before calling
555
+ them. Model interfaces and event unions are experimental; exhaustive external switches
556
+ may need to handle the added events. OpenAI uses `experimental_realtime` for both
557
+ Realtime and Live models, with a provider-specific `{ api: 'live' }` override for
558
+ unknown or early-access Live model IDs. This factory option selects the provider API;
559
+ the hook's `api.websocket` option selects the application's transport endpoint.
560
+ OpenAI Live startup options are exported as `Experimental_OpenAIRealtimeModelLiveOptions`.
561
+
562
+ See [Realtime](/docs/ai-sdk-core/realtime#tool-calling) for a complete example
563
+ with server-backed app-specific tool endpoints.
@@ -70,6 +70,18 @@ A Promise that resolves to an array of [`ModelMessage`](/docs/reference/ai-sdk-c
70
70
  ]}
71
71
  />
72
72
 
73
+ ## Deprecated `rawInput` field
74
+
75
+ Tool parts in the `output-error` state should store their tool arguments in
76
+ `input`. The legacy `rawInput` field remains supported for persisted messages,
77
+ but `convertToModelMessages` emits an AI SDK deprecation warning when it
78
+ encounters a defined value.
79
+
80
+ When both fields are present, `input` takes precedence when it is non-nullish.
81
+ For backward compatibility, `rawInput` remains the fallback when `input` is
82
+ `null` or `undefined`. Migrate stored messages to `input` before the next major
83
+ version, when `rawInput` will be removed.
84
+
73
85
  ## Tool Approval States
74
86
 
75
87
  `convertToModelMessages` preserves tool approval state from UI messages when converting them back into `ModelMessage`s for a follow-up `generateText` or `streamText` call.
@@ -134,7 +134,7 @@ outcomes and call `setOutcome` once.
134
134
  },
135
135
  {
136
136
  name: 'onEnd',
137
- type: '(options: { messages: UIMessage[]; isContinuation: boolean; isAborted: boolean; outcome: UIMessageStreamOutcome; responseMessage: UIMessage; finishReason?: FinishReason }) => PromiseLike<void> | void',
137
+ type: '(options: { messages: UIMessage[]; isContinuation: boolean; isAborted: boolean; isCancelled?: true; outcome: UIMessageStreamOutcome; responseMessage: UIMessage; finishReason?: FinishReason }) => PromiseLike<void> | void',
138
138
  description: 'A callback function that is called when the stream ends.',
139
139
  properties: [
140
140
  {
@@ -156,11 +156,17 @@ outcomes and call `setOutcome` once.
156
156
  type: 'boolean',
157
157
  description: 'Indicates whether the stream was aborted.',
158
158
  },
159
+ {
160
+ name: 'isCancelled',
161
+ type: 'true | undefined',
162
+ description:
163
+ 'Present and true when the consumer cancelled the stream before an outcome was declared, for example because the client disconnected.',
164
+ },
159
165
  {
160
166
  name: 'outcome',
161
167
  type: "UIMessageStreamOutcome = { status: 'completed' } | { status: 'failed'; error?: unknown } | { status: 'aborted' } | { status: 'unknown' }",
162
168
  description:
163
- 'The operation-level outcome of the stream. It reflects the stream owner declaration unless a fatal stream-processing failure occurs, and is separate from model finish reasons and individual error chunks.',
169
+ "The operation-level outcome of the stream. It reflects the stream owner declaration unless a fatal stream-processing failure occurs, and is separate from model finish reasons and individual error chunks. It remains 'unknown' when the consumer cancels before an outcome is declared; check isCancelled to distinguish that case from normal closure without a declared outcome.",
164
170
  },
165
171
  {
166
172
  name: 'responseMessage',
@@ -180,7 +186,7 @@ outcomes and call `setOutcome` once.
180
186
  },
181
187
  {
182
188
  name: 'onFinish',
183
- type: '(options: { messages: UIMessage[]; isContinuation: boolean; isAborted: boolean; outcome: UIMessageStreamOutcome; responseMessage: UIMessage; finishReason?: FinishReason }) => PromiseLike<void> | void',
189
+ type: '(options: { messages: UIMessage[]; isContinuation: boolean; isAborted: boolean; isCancelled?: true; outcome: UIMessageStreamOutcome; responseMessage: UIMessage; finishReason?: FinishReason }) => PromiseLike<void> | void',
184
190
  description: 'Deprecated alias for `onEnd`.',
185
191
  },
186
192
  {
@@ -202,7 +202,7 @@ import { DirectChatTransport, ToolLoopAgent } from 'ai';
202
202
  import { openai } from '@ai-sdk/openai';
203
203
 
204
204
  const agent = new ToolLoopAgent({
205
- model: openai('gpt-4o'),
205
+ model: openai('gpt-6-astra'),
206
206
  instructions: 'You are a helpful assistant.',
207
207
  });
208
208
 
@@ -246,7 +246,7 @@ const weatherTool = tool({
246
246
  });
247
247
 
248
248
  const agent = new ToolLoopAgent({
249
- model: openai('gpt-4o'),
249
+ model: openai('gpt-6-astra'),
250
250
  instructions: 'You are a helpful assistant with access to weather data.',
251
251
  tools: { weather: weatherTool },
252
252
  });
@@ -268,7 +268,7 @@ import { DirectChatTransport, ToolLoopAgent } from 'ai';
268
268
  import { openai } from '@ai-sdk/openai';
269
269
 
270
270
  const agent = new ToolLoopAgent<{ userId: string }>({
271
- model: openai('gpt-4o'),
271
+ model: openai('gpt-6-astra'),
272
272
  prepareCall: ({ options, ...rest }) => ({
273
273
  ...rest,
274
274
  providerOptions: {
@@ -26,7 +26,7 @@ To see `streamUI` in action, check out [these examples](#examples).
26
26
  {
27
27
  name: 'model',
28
28
  type: 'LanguageModel',
29
- description: 'The language model to use. Example: openai("gpt-4.1")',
29
+ description: 'The language model to use. Example: openai("gpt-6-astra")',
30
30
  },
31
31
  {
32
32
  name: 'initial',
@@ -36,6 +36,7 @@ To see `streamUI` in action, check out [these examples](#examples).
36
36
  },
37
37
  {
38
38
  name: 'instructions',
39
+ isOptional: true,
39
40
  type: 'Instructions',
40
41
  description:
41
42
  'Instructions to use that specify the behavior of the model.'
@@ -40,7 +40,7 @@ Creates a client-server context provider that can be used to wrap parts of your
40
40
  },
41
41
  {
42
42
  name: 'onGetUIState',
43
- type: '() => UIState',
43
+ type: '() => Promise<UIState | undefined>',
44
44
  description: 'is called during SSR to compare and update UI state.',
45
45
  },
46
46
  {
@@ -72,7 +72,7 @@ Create a stream that sends UI from the server to the client. On the client side,
72
72
  },
73
73
  {
74
74
  name: 'error',
75
- type: '(Error) => void',
75
+ type: '(any) => StreamableUIWrapper',
76
76
  description:
77
77
  'Signals that there is an error in the UI stream. It will be thrown on the client side and caught by the nearest error boundary component.',
78
78
  },