9router 0.4.59 → 0.4.62

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 (871) hide show
  1. package/app/.next-cli-build/BUILD_ID +1 -1
  2. package/app/.next-cli-build/app-path-routes-manifest.json +7 -7
  3. package/app/.next-cli-build/build-manifest.json +2 -2
  4. package/app/.next-cli-build/prerender-manifest.json +3 -3
  5. package/app/.next-cli-build/routes-manifest.json +12 -12
  6. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js +2 -2
  7. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
  8. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
  9. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +3 -3
  10. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
  11. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
  12. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js +2 -2
  13. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
  14. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
  15. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js +2 -2
  16. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
  17. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
  18. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js +2 -2
  19. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
  20. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
  21. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +2 -2
  22. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  23. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  24. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +2 -2
  25. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
  26. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
  27. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +2 -2
  28. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
  29. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
  30. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +3 -3
  31. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
  32. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
  33. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +2 -2
  34. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
  35. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
  36. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +2 -2
  37. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
  38. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
  39. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +2 -2
  40. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  41. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  42. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +2 -2
  43. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  44. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  45. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +3 -3
  46. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  47. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  48. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +2 -2
  49. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  50. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  51. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +2 -2
  52. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  53. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  54. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +4 -4
  55. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
  56. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
  57. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +2 -2
  58. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
  59. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
  60. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +2 -2
  61. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
  62. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
  63. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +2 -2
  64. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
  65. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
  66. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +2 -2
  67. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
  68. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
  69. package/app/.next-cli-build/server/app/_global-error/page.js +2 -2
  70. package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
  71. package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
  72. package/app/.next-cli-build/server/app/_global-error.html +1 -1
  73. package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
  74. package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
  75. package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  76. package/app/.next-cli-build/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
  77. package/app/.next-cli-build/server/app/_global-error.segments/_head.segment.rsc +1 -1
  78. package/app/.next-cli-build/server/app/_global-error.segments/_index.segment.rsc +1 -1
  79. package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  80. package/app/.next-cli-build/server/app/_not-found/page.js +2 -2
  81. package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
  82. package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
  83. package/app/.next-cli-build/server/app/_not-found.html +1 -1
  84. package/app/.next-cli-build/server/app/_not-found.rsc +4 -4
  85. package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +4 -4
  86. package/app/.next-cli-build/server/app/_not-found.segments/_head.segment.rsc +1 -1
  87. package/app/.next-cli-build/server/app/_not-found.segments/_index.segment.rsc +4 -4
  88. package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  89. package/app/.next-cli-build/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  90. package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  91. package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
  92. package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
  93. package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
  94. package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
  95. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
  96. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
  97. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
  98. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
  99. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
  100. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
  101. package/app/.next-cli-build/server/app/api/auth/status/route.js +1 -1
  102. package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
  103. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +4 -4
  104. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
  105. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +2 -2
  106. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
  107. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
  108. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
  109. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
  110. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
  111. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +2 -2
  112. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
  113. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
  114. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
  115. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +1 -1
  116. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
  117. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +2 -2
  118. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
  119. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +2 -2
  120. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
  121. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
  122. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
  123. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +3 -3
  124. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
  125. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +2 -2
  126. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
  127. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +3 -3
  128. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
  129. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
  130. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
  131. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
  132. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
  133. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
  134. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
  135. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +2 -2
  136. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
  137. package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
  138. package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
  139. package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
  140. package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
  141. package/app/.next-cli-build/server/app/api/health/route.js +1 -1
  142. package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
  143. package/app/.next-cli-build/server/app/api/init/route.js +1 -1
  144. package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
  145. package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
  146. package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
  147. package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
  148. package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
  149. package/app/.next-cli-build/server/app/api/locale/route.js +1 -1
  150. package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
  151. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +1 -1
  152. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
  153. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +5 -5
  154. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
  155. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
  156. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
  157. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
  158. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
  159. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
  160. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
  161. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
  162. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
  163. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
  164. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
  165. package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
  166. package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
  167. package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
  168. package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
  169. package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
  170. package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
  171. package/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
  172. package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
  173. package/app/.next-cli-build/server/app/api/models/route.js +1 -1
  174. package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
  175. package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
  176. package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
  177. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
  178. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
  179. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
  180. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
  181. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +2 -2
  182. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
  183. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
  184. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
  185. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
  186. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
  187. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
  188. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
  189. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
  190. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
  191. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
  192. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
  193. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
  194. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
  195. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
  196. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
  197. package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
  198. package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
  199. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
  200. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
  201. package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
  202. package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
  203. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
  204. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
  205. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
  206. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
  207. package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
  208. package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
  209. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
  210. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
  211. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
  212. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
  213. package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
  214. package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
  215. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js +1 -1
  216. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
  217. package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
  218. package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
  219. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
  220. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
  221. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
  222. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
  223. package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
  224. package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
  225. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
  226. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
  227. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
  228. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
  229. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +43 -0
  230. package/app/.next-cli-build/server/app/api/{tunnel/tailscale-start-daemon → proxy-pools/cloudflare-deploy}/route.js.nft.json +1 -1
  231. package/app/.next-cli-build/server/app/api/{tunnel/tailscale-start-daemon → proxy-pools/cloudflare-deploy}/route_client-reference-manifest.js +1 -1
  232. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +40 -0
  233. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -0
  234. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route_client-reference-manifest.js +1 -0
  235. package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
  236. package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
  237. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +2 -2
  238. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
  239. package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
  240. package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
  241. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js +1 -1
  242. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
  243. package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
  244. package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
  245. package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
  246. package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
  247. package/app/.next-cli-build/server/app/api/shutdown/route.js +1 -1
  248. package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
  249. package/app/.next-cli-build/server/app/api/tags/route.js +1 -1
  250. package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
  251. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
  252. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
  253. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +2 -2
  254. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
  255. package/app/.next-cli-build/server/app/api/translator/load/route.js +1 -1
  256. package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
  257. package/app/.next-cli-build/server/app/api/translator/save/route.js +1 -1
  258. package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
  259. package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
  260. package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
  261. package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
  262. package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
  263. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
  264. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
  265. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
  266. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
  267. package/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
  268. package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
  269. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
  270. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
  271. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
  272. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
  273. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
  274. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
  275. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +3 -3
  276. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
  277. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
  278. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
  279. package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
  280. package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
  281. package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
  282. package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
  283. package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
  284. package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
  285. package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
  286. package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
  287. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
  288. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
  289. package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
  290. package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
  291. package/app/.next-cli-build/server/app/api/usage/stream/route.js +2 -2
  292. package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
  293. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
  294. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  295. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
  296. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
  297. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
  298. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
  299. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
  300. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
  301. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
  302. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  303. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
  304. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
  305. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +2 -2
  306. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
  307. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js +1 -1
  308. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
  309. package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
  310. package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
  311. package/app/.next-cli-build/server/app/api/v1/models/[kind]/route.js +1 -1
  312. package/app/.next-cli-build/server/app/api/v1/models/[kind]/route.js.nft.json +1 -1
  313. package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
  314. package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
  315. package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
  316. package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
  317. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
  318. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
  319. package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
  320. package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
  321. package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
  322. package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
  323. package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
  324. package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
  325. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
  326. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
  327. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
  328. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  329. package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
  330. package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
  331. package/app/.next-cli-build/server/app/api/version/route.js +1 -1
  332. package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
  333. package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
  334. package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
  335. package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
  336. package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
  337. package/app/.next-cli-build/server/app/callback/page.js +2 -2
  338. package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
  339. package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
  340. package/app/.next-cli-build/server/app/callback.html +1 -1
  341. package/app/.next-cli-build/server/app/callback.rsc +4 -4
  342. package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +4 -4
  343. package/app/.next-cli-build/server/app/callback.segments/_head.segment.rsc +1 -1
  344. package/app/.next-cli-build/server/app/callback.segments/_index.segment.rsc +4 -4
  345. package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
  346. package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +1 -1
  347. package/app/.next-cli-build/server/app/callback.segments/callback.segment.rsc +1 -1
  348. package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
  349. package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +6 -6
  350. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +2 -2
  351. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat.segment.rsc +1 -1
  352. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  353. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  354. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +6 -6
  355. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_head.segment.rsc +1 -1
  356. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_index.segment.rsc +4 -4
  357. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +2 -2
  358. package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
  359. package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +6 -6
  360. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +2 -2
  361. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools.segment.rsc +1 -1
  362. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  363. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  364. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +6 -6
  365. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_head.segment.rsc +1 -1
  366. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_index.segment.rsc +4 -4
  367. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
  368. package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
  369. package/app/.next-cli-build/server/app/dashboard/combos.rsc +6 -6
  370. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +2 -2
  371. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos.segment.rsc +1 -1
  372. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  373. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  374. package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +6 -6
  375. package/app/.next-cli-build/server/app/dashboard/combos.segments/_head.segment.rsc +1 -1
  376. package/app/.next-cli-build/server/app/dashboard/combos.segments/_index.segment.rsc +4 -4
  377. package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
  378. package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
  379. package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +6 -6
  380. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +2 -2
  381. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint.segment.rsc +1 -1
  382. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  383. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  384. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +6 -6
  385. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_head.segment.rsc +1 -1
  386. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_index.segment.rsc +4 -4
  387. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
  388. package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
  389. package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +6 -6
  390. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +2 -2
  391. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web.segment.rsc +1 -1
  392. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers.segment.rsc +1 -1
  393. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  394. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  395. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +6 -6
  396. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_head.segment.rsc +1 -1
  397. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_index.segment.rsc +4 -4
  398. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
  399. package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
  400. package/app/.next-cli-build/server/app/dashboard/mitm.rsc +6 -6
  401. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +2 -2
  402. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm.segment.rsc +1 -1
  403. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  404. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  405. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +6 -6
  406. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_head.segment.rsc +1 -1
  407. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_index.segment.rsc +4 -4
  408. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
  409. package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
  410. package/app/.next-cli-build/server/app/dashboard/profile.rsc +6 -6
  411. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +2 -2
  412. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile.segment.rsc +1 -1
  413. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  414. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  415. package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +6 -6
  416. package/app/.next-cli-build/server/app/dashboard/profile.segments/_head.segment.rsc +1 -1
  417. package/app/.next-cli-build/server/app/dashboard/profile.segments/_index.segment.rsc +4 -4
  418. package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
  419. package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
  420. package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +6 -6
  421. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +2 -2
  422. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new.segment.rsc +1 -1
  423. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
  424. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  425. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  426. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +6 -6
  427. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_head.segment.rsc +1 -1
  428. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_index.segment.rsc +4 -4
  429. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
  430. package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
  431. package/app/.next-cli-build/server/app/dashboard/providers.rsc +6 -6
  432. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +2 -2
  433. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
  434. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  435. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  436. package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +6 -6
  437. package/app/.next-cli-build/server/app/dashboard/providers.segments/_head.segment.rsc +1 -1
  438. package/app/.next-cli-build/server/app/dashboard/providers.segments/_index.segment.rsc +4 -4
  439. package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
  440. package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
  441. package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +6 -6
  442. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +2 -2
  443. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools.segment.rsc +1 -1
  444. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  445. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  446. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +6 -6
  447. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_head.segment.rsc +1 -1
  448. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_index.segment.rsc +4 -4
  449. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
  450. package/app/.next-cli-build/server/app/dashboard/quota.html +2 -2
  451. package/app/.next-cli-build/server/app/dashboard/quota.rsc +7 -7
  452. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +3 -3
  453. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota.segment.rsc +1 -1
  454. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  455. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  456. package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +7 -7
  457. package/app/.next-cli-build/server/app/dashboard/quota.segments/_head.segment.rsc +1 -1
  458. package/app/.next-cli-build/server/app/dashboard/quota.segments/_index.segment.rsc +4 -4
  459. package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
  460. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +2 -2
  461. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
  462. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
  463. package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
  464. package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +4 -4
  465. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +4 -4
  466. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_head.segment.rsc +1 -1
  467. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_index.segment.rsc +4 -4
  468. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
  469. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +1 -1
  470. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing.segment.rsc +1 -1
  471. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings.segment.rsc +1 -1
  472. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard.segment.rsc +1 -1
  473. package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
  474. package/app/.next-cli-build/server/app/dashboard/skills.rsc +6 -6
  475. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +2 -2
  476. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills.segment.rsc +1 -1
  477. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  478. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  479. package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +6 -6
  480. package/app/.next-cli-build/server/app/dashboard/skills.segments/_head.segment.rsc +1 -1
  481. package/app/.next-cli-build/server/app/dashboard/skills.segments/_index.segment.rsc +4 -4
  482. package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
  483. package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
  484. package/app/.next-cli-build/server/app/dashboard/translator.rsc +6 -6
  485. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +2 -2
  486. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator.segment.rsc +1 -1
  487. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  488. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  489. package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +6 -6
  490. package/app/.next-cli-build/server/app/dashboard/translator.segments/_head.segment.rsc +1 -1
  491. package/app/.next-cli-build/server/app/dashboard/translator.segments/_index.segment.rsc +4 -4
  492. package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
  493. package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
  494. package/app/.next-cli-build/server/app/dashboard/usage.rsc +6 -6
  495. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +2 -2
  496. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage.segment.rsc +1 -1
  497. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  498. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  499. package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +6 -6
  500. package/app/.next-cli-build/server/app/dashboard/usage.segments/_head.segment.rsc +1 -1
  501. package/app/.next-cli-build/server/app/dashboard/usage.segments/_index.segment.rsc +4 -4
  502. package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
  503. package/app/.next-cli-build/server/app/dashboard.html +1 -1
  504. package/app/.next-cli-build/server/app/dashboard.rsc +6 -6
  505. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +2 -2
  506. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  507. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  508. package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +6 -6
  509. package/app/.next-cli-build/server/app/dashboard.segments/_head.segment.rsc +1 -1
  510. package/app/.next-cli-build/server/app/dashboard.segments/_index.segment.rsc +4 -4
  511. package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
  512. package/app/.next-cli-build/server/app/favicon.ico/route.js +1 -1
  513. package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
  514. package/app/.next-cli-build/server/app/index.html +1 -1
  515. package/app/.next-cli-build/server/app/index.rsc +4 -4
  516. package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  517. package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +4 -4
  518. package/app/.next-cli-build/server/app/index.segments/_head.segment.rsc +1 -1
  519. package/app/.next-cli-build/server/app/index.segments/_index.segment.rsc +4 -4
  520. package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
  521. package/app/.next-cli-build/server/app/landing/page.js +2 -2
  522. package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
  523. package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
  524. package/app/.next-cli-build/server/app/landing.html +1 -1
  525. package/app/.next-cli-build/server/app/landing.rsc +4 -4
  526. package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +4 -4
  527. package/app/.next-cli-build/server/app/landing.segments/_head.segment.rsc +1 -1
  528. package/app/.next-cli-build/server/app/landing.segments/_index.segment.rsc +4 -4
  529. package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
  530. package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +1 -1
  531. package/app/.next-cli-build/server/app/landing.segments/landing.segment.rsc +1 -1
  532. package/app/.next-cli-build/server/app/login/page.js +2 -2
  533. package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
  534. package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
  535. package/app/.next-cli-build/server/app/login.html +1 -1
  536. package/app/.next-cli-build/server/app/login.rsc +5 -5
  537. package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +5 -5
  538. package/app/.next-cli-build/server/app/login.segments/_head.segment.rsc +1 -1
  539. package/app/.next-cli-build/server/app/login.segments/_index.segment.rsc +4 -4
  540. package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
  541. package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
  542. package/app/.next-cli-build/server/app/login.segments/login.segment.rsc +1 -1
  543. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js +2 -2
  544. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
  545. package/app/.next-cli-build/server/app/page.js +2 -2
  546. package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
  547. package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
  548. package/app/.next-cli-build/server/app-paths-manifest.json +7 -7
  549. package/app/.next-cli-build/server/chunks/1249.js +1 -1
  550. package/app/.next-cli-build/server/chunks/1435.js +1 -0
  551. package/app/.next-cli-build/server/chunks/{9129.js → 1574.js} +2 -2
  552. package/app/.next-cli-build/server/chunks/1578.js +1 -1
  553. package/app/.next-cli-build/server/chunks/1869.js +1 -0
  554. package/app/.next-cli-build/server/chunks/4185.js +1 -1
  555. package/app/.next-cli-build/server/chunks/4343.js +1 -1
  556. package/app/.next-cli-build/server/chunks/4447.js +7 -0
  557. package/app/.next-cli-build/server/chunks/450.js +1 -1
  558. package/app/.next-cli-build/server/chunks/504.js +1 -0
  559. package/app/.next-cli-build/server/chunks/5079.js +1 -0
  560. package/app/.next-cli-build/server/chunks/514.js +18 -4
  561. package/app/.next-cli-build/server/chunks/5412.js +1 -0
  562. package/app/.next-cli-build/server/chunks/586.js +1 -1
  563. package/app/.next-cli-build/server/chunks/6263.js +3 -3
  564. package/app/.next-cli-build/server/chunks/6283.js +1 -1
  565. package/app/.next-cli-build/server/chunks/6379.js +3 -3
  566. package/app/.next-cli-build/server/chunks/6560.js +1 -0
  567. package/app/.next-cli-build/server/chunks/666.js +4 -0
  568. package/app/.next-cli-build/server/chunks/7171.js +1 -1
  569. package/app/.next-cli-build/server/chunks/7686.js +1 -1
  570. package/app/.next-cli-build/server/chunks/7958.js +1 -0
  571. package/app/.next-cli-build/server/chunks/7973.js +1 -1
  572. package/app/.next-cli-build/server/chunks/8202.js +13 -5
  573. package/app/.next-cli-build/server/chunks/8395.js +1 -0
  574. package/app/.next-cli-build/server/chunks/8515.js +1 -1
  575. package/app/.next-cli-build/server/chunks/9737.js +1 -1
  576. package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
  577. package/app/.next-cli-build/server/middleware.js +1 -1
  578. package/app/.next-cli-build/server/pages/404.html +1 -1
  579. package/app/.next-cli-build/server/pages/500.html +1 -1
  580. package/app/.next-cli-build/server/server-reference-manifest.js +1 -1
  581. package/app/.next-cli-build/server/server-reference-manifest.json +1 -1
  582. package/app/.next-cli-build/static/{y2eEe1Y5KAz1b1viRdGY_ → _wFz49-RfMT2QnRpTR45i}/_buildManifest.js +1 -1
  583. package/app/.next-cli-build/static/chunks/{3771-c6aa0933e598758e.js → 3771-9c0300235faf81ff.js} +1 -1
  584. package/app/.next-cli-build/static/chunks/{4156-0129178d5950b9c2.js → 4156-c9429fb1c6c597c1.js} +1 -1
  585. package/app/.next-cli-build/static/chunks/{505-cd3b84480ae77abf.js → 505-5a62b095f0d3ccf2.js} +1 -1
  586. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/proxy-pools/page-f9aa290f48f86415.js +4 -0
  587. package/app/.next-cli-build/static/chunks/app/_global-error/{page-1dac36d6af075c54.js → page-442e7d7d2ff2814c.js} +1 -1
  588. package/app/.next-cli-build/static/chunks/app/api/auth/login/{route-1dac36d6af075c54.js → route-442e7d7d2ff2814c.js} +1 -1
  589. package/app/.next-cli-build/static/chunks/app/api/auth/logout/{route-1dac36d6af075c54.js → route-442e7d7d2ff2814c.js} +1 -1
  590. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/{route-1dac36d6af075c54.js → route-442e7d7d2ff2814c.js} +1 -1
  591. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-442e7d7d2ff2814c.js +1 -0
  592. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-442e7d7d2ff2814c.js +1 -0
  593. package/app/.next-cli-build/static/chunks/app/api/auth/status/route-442e7d7d2ff2814c.js +1 -0
  594. package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-442e7d7d2ff2814c.js +1 -0
  595. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-442e7d7d2ff2814c.js +1 -0
  596. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-442e7d7d2ff2814c.js +1 -0
  597. package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-442e7d7d2ff2814c.js +1 -0
  598. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-442e7d7d2ff2814c.js +1 -0
  599. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-442e7d7d2ff2814c.js +1 -0
  600. package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-442e7d7d2ff2814c.js +1 -0
  601. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-442e7d7d2ff2814c.js +1 -0
  602. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-442e7d7d2ff2814c.js +1 -0
  603. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-442e7d7d2ff2814c.js +1 -0
  604. package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-442e7d7d2ff2814c.js +1 -0
  605. package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-442e7d7d2ff2814c.js +1 -0
  606. package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-442e7d7d2ff2814c.js +1 -0
  607. package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-442e7d7d2ff2814c.js +1 -0
  608. package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-442e7d7d2ff2814c.js +1 -0
  609. package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-442e7d7d2ff2814c.js +1 -0
  610. package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-442e7d7d2ff2814c.js +1 -0
  611. package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-442e7d7d2ff2814c.js +1 -0
  612. package/app/.next-cli-build/static/chunks/app/api/combos/route-442e7d7d2ff2814c.js +1 -0
  613. package/app/.next-cli-build/static/chunks/app/api/health/route-442e7d7d2ff2814c.js +1 -0
  614. package/app/.next-cli-build/static/chunks/app/api/init/route-442e7d7d2ff2814c.js +1 -0
  615. package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-442e7d7d2ff2814c.js +1 -0
  616. package/app/.next-cli-build/static/chunks/app/api/keys/route-442e7d7d2ff2814c.js +1 -0
  617. package/app/.next-cli-build/static/chunks/app/api/locale/route-442e7d7d2ff2814c.js +1 -0
  618. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-442e7d7d2ff2814c.js +1 -0
  619. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-442e7d7d2ff2814c.js +1 -0
  620. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-442e7d7d2ff2814c.js +1 -0
  621. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-442e7d7d2ff2814c.js +1 -0
  622. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-442e7d7d2ff2814c.js +1 -0
  623. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-442e7d7d2ff2814c.js +1 -0
  624. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-442e7d7d2ff2814c.js +1 -0
  625. package/app/.next-cli-build/static/chunks/app/api/models/alias/route-442e7d7d2ff2814c.js +1 -0
  626. package/app/.next-cli-build/static/chunks/app/api/models/availability/route-442e7d7d2ff2814c.js +1 -0
  627. package/app/.next-cli-build/static/chunks/app/api/models/custom/route-442e7d7d2ff2814c.js +1 -0
  628. package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-442e7d7d2ff2814c.js +1 -0
  629. package/app/.next-cli-build/static/chunks/app/api/models/route-442e7d7d2ff2814c.js +1 -0
  630. package/app/.next-cli-build/static/chunks/app/api/models/test/route-442e7d7d2ff2814c.js +1 -0
  631. package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-442e7d7d2ff2814c.js +1 -0
  632. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-442e7d7d2ff2814c.js +1 -0
  633. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-442e7d7d2ff2814c.js +1 -0
  634. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-442e7d7d2ff2814c.js +1 -0
  635. package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-442e7d7d2ff2814c.js +1 -0
  636. package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-442e7d7d2ff2814c.js +1 -0
  637. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-442e7d7d2ff2814c.js +1 -0
  638. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-442e7d7d2ff2814c.js +1 -0
  639. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-442e7d7d2ff2814c.js +1 -0
  640. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-442e7d7d2ff2814c.js +1 -0
  641. package/app/.next-cli-build/static/chunks/app/api/pricing/route-442e7d7d2ff2814c.js +1 -0
  642. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-442e7d7d2ff2814c.js +1 -0
  643. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-442e7d7d2ff2814c.js +1 -0
  644. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-442e7d7d2ff2814c.js +1 -0
  645. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-442e7d7d2ff2814c.js +1 -0
  646. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-442e7d7d2ff2814c.js +1 -0
  647. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-442e7d7d2ff2814c.js +1 -0
  648. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-442e7d7d2ff2814c.js +1 -0
  649. package/app/.next-cli-build/static/chunks/app/api/providers/client/route-442e7d7d2ff2814c.js +1 -0
  650. package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-442e7d7d2ff2814c.js +1 -0
  651. package/app/.next-cli-build/static/chunks/app/api/providers/route-442e7d7d2ff2814c.js +1 -0
  652. package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-442e7d7d2ff2814c.js +1 -0
  653. package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-442e7d7d2ff2814c.js +1 -0
  654. package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-442e7d7d2ff2814c.js +1 -0
  655. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-442e7d7d2ff2814c.js +1 -0
  656. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-442e7d7d2ff2814c.js +1 -0
  657. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-442e7d7d2ff2814c.js +1 -0
  658. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-442e7d7d2ff2814c.js +1 -0
  659. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-442e7d7d2ff2814c.js +1 -0
  660. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-442e7d7d2ff2814c.js +1 -0
  661. package/app/.next-cli-build/static/chunks/app/api/settings/database/route-442e7d7d2ff2814c.js +1 -0
  662. package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-442e7d7d2ff2814c.js +1 -0
  663. package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-442e7d7d2ff2814c.js +1 -0
  664. package/app/.next-cli-build/static/chunks/app/api/settings/route-442e7d7d2ff2814c.js +1 -0
  665. package/app/.next-cli-build/static/chunks/app/api/shutdown/route-442e7d7d2ff2814c.js +1 -0
  666. package/app/.next-cli-build/static/chunks/app/api/tags/route-442e7d7d2ff2814c.js +1 -0
  667. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-442e7d7d2ff2814c.js +1 -0
  668. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-442e7d7d2ff2814c.js +1 -0
  669. package/app/.next-cli-build/static/chunks/app/api/translator/load/route-442e7d7d2ff2814c.js +1 -0
  670. package/app/.next-cli-build/static/chunks/app/api/translator/save/route-442e7d7d2ff2814c.js +1 -0
  671. package/app/.next-cli-build/static/chunks/app/api/translator/send/route-442e7d7d2ff2814c.js +1 -0
  672. package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-442e7d7d2ff2814c.js +1 -0
  673. package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-442e7d7d2ff2814c.js +1 -0
  674. package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-442e7d7d2ff2814c.js +1 -0
  675. package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-442e7d7d2ff2814c.js +1 -0
  676. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-442e7d7d2ff2814c.js +1 -0
  677. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-442e7d7d2ff2814c.js +1 -0
  678. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-442e7d7d2ff2814c.js +1 -0
  679. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-442e7d7d2ff2814c.js +1 -0
  680. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-442e7d7d2ff2814c.js +1 -0
  681. package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-442e7d7d2ff2814c.js +1 -0
  682. package/app/.next-cli-build/static/chunks/app/api/usage/history/route-442e7d7d2ff2814c.js +1 -0
  683. package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-442e7d7d2ff2814c.js +1 -0
  684. package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-442e7d7d2ff2814c.js +1 -0
  685. package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-442e7d7d2ff2814c.js +1 -0
  686. package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-442e7d7d2ff2814c.js +1 -0
  687. package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-442e7d7d2ff2814c.js +1 -0
  688. package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-442e7d7d2ff2814c.js +1 -0
  689. package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-442e7d7d2ff2814c.js +1 -0
  690. package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-442e7d7d2ff2814c.js +1 -0
  691. package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-442e7d7d2ff2814c.js +1 -0
  692. package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-442e7d7d2ff2814c.js +1 -0
  693. package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-442e7d7d2ff2814c.js +1 -0
  694. package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-442e7d7d2ff2814c.js +1 -0
  695. package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-442e7d7d2ff2814c.js +1 -0
  696. package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-442e7d7d2ff2814c.js +1 -0
  697. package/app/.next-cli-build/static/chunks/app/api/v1/models/[kind]/route-442e7d7d2ff2814c.js +1 -0
  698. package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-442e7d7d2ff2814c.js +1 -0
  699. package/app/.next-cli-build/static/chunks/app/api/v1/models/route-442e7d7d2ff2814c.js +1 -0
  700. package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-442e7d7d2ff2814c.js +1 -0
  701. package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-442e7d7d2ff2814c.js +1 -0
  702. package/app/.next-cli-build/static/chunks/app/api/v1/route-442e7d7d2ff2814c.js +1 -0
  703. package/app/.next-cli-build/static/chunks/app/api/v1/search/route-442e7d7d2ff2814c.js +1 -0
  704. package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-442e7d7d2ff2814c.js +1 -0
  705. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-442e7d7d2ff2814c.js +1 -0
  706. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-442e7d7d2ff2814c.js +1 -0
  707. package/app/.next-cli-build/static/chunks/app/api/version/route-442e7d7d2ff2814c.js +1 -0
  708. package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-442e7d7d2ff2814c.js +1 -0
  709. package/app/.next-cli-build/static/chunks/app/api/version/update/route-442e7d7d2ff2814c.js +1 -0
  710. package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-442e7d7d2ff2814c.js +1 -0
  711. package/app/.next-cli-build/static/chunks/app/page-442e7d7d2ff2814c.js +1 -0
  712. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-442e7d7d2ff2814c.js +1 -0
  713. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-442e7d7d2ff2814c.js +1 -0
  714. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-442e7d7d2ff2814c.js +1 -0
  715. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-442e7d7d2ff2814c.js +1 -0
  716. package/app/.next-cli-build/static/css/4b7bd5878335a29b.css +1 -0
  717. package/app/cli/.build-home/.9router/db/data.sqlite +0 -0
  718. package/app/cli/.build-home/.9router/jwt-secret +1 -1
  719. package/app/cli/.build-home/Library/Preferences/nextjs-nodejs/config.json +3 -3
  720. package/app/package.json +1 -1
  721. package/app/src/mitm/server.js +31 -27
  722. package/package.json +1 -1
  723. package/src/cli/menus/providers.js +7 -6
  724. package/app/.next-cli-build/server/app/api/tunnel/tailscale-login/route.js +0 -1
  725. package/app/.next-cli-build/server/app/api/tunnel/tailscale-login/route.js.nft.json +0 -1
  726. package/app/.next-cli-build/server/app/api/tunnel/tailscale-login/route_client-reference-manifest.js +0 -1
  727. package/app/.next-cli-build/server/app/api/tunnel/tailscale-start-daemon/route.js +0 -2
  728. package/app/.next-cli-build/server/chunks/1071.js +0 -1
  729. package/app/.next-cli-build/server/chunks/1229.js +0 -1
  730. package/app/.next-cli-build/server/chunks/1729.js +0 -1
  731. package/app/.next-cli-build/server/chunks/1795.js +0 -1
  732. package/app/.next-cli-build/server/chunks/3774.js +0 -4
  733. package/app/.next-cli-build/server/chunks/5662.js +0 -1
  734. package/app/.next-cli-build/server/chunks/5882.js +0 -1
  735. package/app/.next-cli-build/server/chunks/6634.js +0 -7
  736. package/app/.next-cli-build/server/chunks/7188.js +0 -1
  737. package/app/.next-cli-build/server/chunks/8012.js +0 -15
  738. package/app/.next-cli-build/server/chunks/9603.js +0 -1
  739. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/proxy-pools/page-884603e61682c07d.js +0 -4
  740. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-1dac36d6af075c54.js +0 -1
  741. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-1dac36d6af075c54.js +0 -1
  742. package/app/.next-cli-build/static/chunks/app/api/auth/status/route-1dac36d6af075c54.js +0 -1
  743. package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-1dac36d6af075c54.js +0 -1
  744. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-1dac36d6af075c54.js +0 -1
  745. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-1dac36d6af075c54.js +0 -1
  746. package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-1dac36d6af075c54.js +0 -1
  747. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-1dac36d6af075c54.js +0 -1
  748. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-1dac36d6af075c54.js +0 -1
  749. package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-1dac36d6af075c54.js +0 -1
  750. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-1dac36d6af075c54.js +0 -1
  751. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-1dac36d6af075c54.js +0 -1
  752. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-1dac36d6af075c54.js +0 -1
  753. package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-1dac36d6af075c54.js +0 -1
  754. package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-1dac36d6af075c54.js +0 -1
  755. package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-1dac36d6af075c54.js +0 -1
  756. package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-1dac36d6af075c54.js +0 -1
  757. package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-1dac36d6af075c54.js +0 -1
  758. package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-1dac36d6af075c54.js +0 -1
  759. package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-1dac36d6af075c54.js +0 -1
  760. package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-1dac36d6af075c54.js +0 -1
  761. package/app/.next-cli-build/static/chunks/app/api/combos/route-1dac36d6af075c54.js +0 -1
  762. package/app/.next-cli-build/static/chunks/app/api/health/route-1dac36d6af075c54.js +0 -1
  763. package/app/.next-cli-build/static/chunks/app/api/init/route-1dac36d6af075c54.js +0 -1
  764. package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-1dac36d6af075c54.js +0 -1
  765. package/app/.next-cli-build/static/chunks/app/api/keys/route-1dac36d6af075c54.js +0 -1
  766. package/app/.next-cli-build/static/chunks/app/api/locale/route-1dac36d6af075c54.js +0 -1
  767. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-1dac36d6af075c54.js +0 -1
  768. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-1dac36d6af075c54.js +0 -1
  769. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-1dac36d6af075c54.js +0 -1
  770. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-1dac36d6af075c54.js +0 -1
  771. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-1dac36d6af075c54.js +0 -1
  772. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-1dac36d6af075c54.js +0 -1
  773. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-1dac36d6af075c54.js +0 -1
  774. package/app/.next-cli-build/static/chunks/app/api/models/alias/route-1dac36d6af075c54.js +0 -1
  775. package/app/.next-cli-build/static/chunks/app/api/models/availability/route-1dac36d6af075c54.js +0 -1
  776. package/app/.next-cli-build/static/chunks/app/api/models/custom/route-1dac36d6af075c54.js +0 -1
  777. package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-1dac36d6af075c54.js +0 -1
  778. package/app/.next-cli-build/static/chunks/app/api/models/route-1dac36d6af075c54.js +0 -1
  779. package/app/.next-cli-build/static/chunks/app/api/models/test/route-1dac36d6af075c54.js +0 -1
  780. package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-1dac36d6af075c54.js +0 -1
  781. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-1dac36d6af075c54.js +0 -1
  782. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-1dac36d6af075c54.js +0 -1
  783. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-1dac36d6af075c54.js +0 -1
  784. package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-1dac36d6af075c54.js +0 -1
  785. package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-1dac36d6af075c54.js +0 -1
  786. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-1dac36d6af075c54.js +0 -1
  787. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-1dac36d6af075c54.js +0 -1
  788. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-1dac36d6af075c54.js +0 -1
  789. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-1dac36d6af075c54.js +0 -1
  790. package/app/.next-cli-build/static/chunks/app/api/pricing/route-1dac36d6af075c54.js +0 -1
  791. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-1dac36d6af075c54.js +0 -1
  792. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-1dac36d6af075c54.js +0 -1
  793. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-1dac36d6af075c54.js +0 -1
  794. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-1dac36d6af075c54.js +0 -1
  795. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-1dac36d6af075c54.js +0 -1
  796. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-1dac36d6af075c54.js +0 -1
  797. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-1dac36d6af075c54.js +0 -1
  798. package/app/.next-cli-build/static/chunks/app/api/providers/client/route-1dac36d6af075c54.js +0 -1
  799. package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-1dac36d6af075c54.js +0 -1
  800. package/app/.next-cli-build/static/chunks/app/api/providers/route-1dac36d6af075c54.js +0 -1
  801. package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-1dac36d6af075c54.js +0 -1
  802. package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-1dac36d6af075c54.js +0 -1
  803. package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-1dac36d6af075c54.js +0 -1
  804. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-1dac36d6af075c54.js +0 -1
  805. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-1dac36d6af075c54.js +0 -1
  806. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-1dac36d6af075c54.js +0 -1
  807. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-1dac36d6af075c54.js +0 -1
  808. package/app/.next-cli-build/static/chunks/app/api/settings/database/route-1dac36d6af075c54.js +0 -1
  809. package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-1dac36d6af075c54.js +0 -1
  810. package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-1dac36d6af075c54.js +0 -1
  811. package/app/.next-cli-build/static/chunks/app/api/settings/route-1dac36d6af075c54.js +0 -1
  812. package/app/.next-cli-build/static/chunks/app/api/shutdown/route-1dac36d6af075c54.js +0 -1
  813. package/app/.next-cli-build/static/chunks/app/api/tags/route-1dac36d6af075c54.js +0 -1
  814. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-1dac36d6af075c54.js +0 -1
  815. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-1dac36d6af075c54.js +0 -1
  816. package/app/.next-cli-build/static/chunks/app/api/translator/load/route-1dac36d6af075c54.js +0 -1
  817. package/app/.next-cli-build/static/chunks/app/api/translator/save/route-1dac36d6af075c54.js +0 -1
  818. package/app/.next-cli-build/static/chunks/app/api/translator/send/route-1dac36d6af075c54.js +0 -1
  819. package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-1dac36d6af075c54.js +0 -1
  820. package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-1dac36d6af075c54.js +0 -1
  821. package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-1dac36d6af075c54.js +0 -1
  822. package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-1dac36d6af075c54.js +0 -1
  823. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-1dac36d6af075c54.js +0 -1
  824. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-1dac36d6af075c54.js +0 -1
  825. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-1dac36d6af075c54.js +0 -1
  826. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-1dac36d6af075c54.js +0 -1
  827. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-login/route-1dac36d6af075c54.js +0 -1
  828. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-start-daemon/route-1dac36d6af075c54.js +0 -1
  829. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-1dac36d6af075c54.js +0 -1
  830. package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-1dac36d6af075c54.js +0 -1
  831. package/app/.next-cli-build/static/chunks/app/api/usage/history/route-1dac36d6af075c54.js +0 -1
  832. package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-1dac36d6af075c54.js +0 -1
  833. package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-1dac36d6af075c54.js +0 -1
  834. package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-1dac36d6af075c54.js +0 -1
  835. package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-1dac36d6af075c54.js +0 -1
  836. package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-1dac36d6af075c54.js +0 -1
  837. package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-1dac36d6af075c54.js +0 -1
  838. package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-1dac36d6af075c54.js +0 -1
  839. package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-1dac36d6af075c54.js +0 -1
  840. package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-1dac36d6af075c54.js +0 -1
  841. package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-1dac36d6af075c54.js +0 -1
  842. package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-1dac36d6af075c54.js +0 -1
  843. package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-1dac36d6af075c54.js +0 -1
  844. package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-1dac36d6af075c54.js +0 -1
  845. package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-1dac36d6af075c54.js +0 -1
  846. package/app/.next-cli-build/static/chunks/app/api/v1/models/[kind]/route-1dac36d6af075c54.js +0 -1
  847. package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-1dac36d6af075c54.js +0 -1
  848. package/app/.next-cli-build/static/chunks/app/api/v1/models/route-1dac36d6af075c54.js +0 -1
  849. package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-1dac36d6af075c54.js +0 -1
  850. package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-1dac36d6af075c54.js +0 -1
  851. package/app/.next-cli-build/static/chunks/app/api/v1/route-1dac36d6af075c54.js +0 -1
  852. package/app/.next-cli-build/static/chunks/app/api/v1/search/route-1dac36d6af075c54.js +0 -1
  853. package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-1dac36d6af075c54.js +0 -1
  854. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-1dac36d6af075c54.js +0 -1
  855. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-1dac36d6af075c54.js +0 -1
  856. package/app/.next-cli-build/static/chunks/app/api/version/route-1dac36d6af075c54.js +0 -1
  857. package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-1dac36d6af075c54.js +0 -1
  858. package/app/.next-cli-build/static/chunks/app/api/version/update/route-1dac36d6af075c54.js +0 -1
  859. package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-1dac36d6af075c54.js +0 -1
  860. package/app/.next-cli-build/static/chunks/app/page-1dac36d6af075c54.js +0 -1
  861. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-1dac36d6af075c54.js +0 -1
  862. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-1dac36d6af075c54.js +0 -1
  863. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-1dac36d6af075c54.js +0 -1
  864. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-1dac36d6af075c54.js +0 -1
  865. package/app/.next-cli-build/static/css/b1cf370be2444f61.css +0 -1
  866. package/app/cli/.build-home/.9router/db/backups/upgrade-0.4.49-to-0.4.50-0.4.50-20260516-134729/data.sqlite +0 -0
  867. package/app/cli/.build-home/.9router/db/backups/upgrade-0.4.50-to-0.4.52-0.4.52-20260517-162943/data.sqlite +0 -0
  868. package/app/cli/.build-home/.9router/db/backups/upgrade-0.4.52-to-0.4.55-0.4.55-20260518-162644/data.sqlite +0 -0
  869. package/app/cli/.build-home/.9router/db/backups/upgrade-0.4.55-to-0.4.58-0.4.58-20260521-121905/data.sqlite +0 -0
  870. package/app/cli/.build-home/.9router/db/backups/upgrade-0.4.58-to-0.4.59-0.4.59-20260521-133932/data.sqlite +0 -0
  871. /package/app/.next-cli-build/static/{y2eEe1Y5KAz1b1viRdGY_ → _wFz49-RfMT2QnRpTR45i}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ exports.id=5412,exports.ids=[5412],exports.modules={24429:()=>{},24709:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(29737);Object.entries(c(50021).AI_PROVIDERS).filter(([,a])=>a.passthroughModels).map(([a])=>a);let e=Object.entries(d.vq).flatMap(([a,b])=>b.map(b=>({provider:a,model:b.id,name:b.name})))},39006:a=>{"use strict";a.exports={rE:"0.4.62"}},62276:(a,b,c)=>{"use strict";c.d(b,{Ak:()=>i,Yg:()=>k,xq:()=>h});var d=c(21820);let e={"Anthropic-Version":"2023-06-01","Anthropic-Beta":"claude-code-20250219,interleaved-thinking-2025-05-14"},f={"Anthropic-Version":"2023-06-01","Anthropic-Beta":"claude-code-20250219,oauth-2025-04-20,interleaved-thinking-2025-05-14,context-management-2025-06-27,prompt-caching-scope-2026-01-05,advanced-tool-use-2025-11-20,effort-2025-11-24,structured-outputs-2025-12-15,fast-mode-2026-02-01,redact-thinking-2026-02-12,token-efficient-tools-2026-03-28","Anthropic-Dangerous-Direct-Browser-Access":"true","User-Agent":"claude-cli/2.1.92 (external, sdk-cli)","X-App":"cli","X-Stainless-Helper-Method":"stream","X-Stainless-Retry-Count":"0","X-Stainless-Runtime-Version":"v24.14.0","X-Stainless-Package-Version":"0.80.0","X-Stainless-Runtime":"node","X-Stainless-Lang":"js","X-Stainless-Arch":function(){switch((0,d.arch)()){case"x64":return"x64";case"arm64":return"arm64";case"ia32":return"x86";default:return`other::${(0,d.arch)()}`}}(),"X-Stainless-Os":function(){switch((0,d.platform)()){case"darwin":return"MacOS";case"win32":return"Windows";case"linux":return"Linux";case"freebsd":return"FreeBSD";default:return`Other::${(0,d.platform)()}`}}(),"X-Stainless-Timeout":"600"},g="https://api.kimi.com/coding/v1/messages",h={claude:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...f},clientId:"9d1c250a-e61b-44d9-88ed-5944d1962f5e",tokenUrl:"https://api.anthropic.com/v1/oauth/token"},gemini:{baseUrl:"https://generativelanguage.googleapis.com/v1beta/models",format:"gemini",clientId:"681255809395-oo8ft2oprdrnp9e3aqf6av3hmdib135j.apps.googleusercontent.com",clientSecret:"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"},"gemini-cli":{baseUrl:"https://cloudcode-pa.googleapis.com/v1internal",format:"gemini-cli",clientId:"681255809395-oo8ft2oprdrnp9e3aqf6av3hmdib135j.apps.googleusercontent.com",clientSecret:"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"},codex:{baseUrl:"https://chatgpt.com/backend-api/codex/responses",format:"openai-responses",headers:{originator:"codex-cli","User-Agent":"codex-cli/1.0.18 (macOS; arm64)"},clientId:"app_EMoamEEZ73f0CkXaXp7hrann",tokenUrl:"https://auth.openai.com/oauth/token"},qwen:{baseUrl:"https://portal.qwen.ai/v1/chat/completions",format:"openai",clientId:"f0304373b74a44d2b584a3fb70ca9e56",tokenUrl:"https://chat.qwen.ai/api/v1/oauth2/token",authUrl:"https://chat.qwen.ai/api/v1/oauth2/device/code"},iflow:{baseUrl:"https://apis.iflow.cn/v1/chat/completions",format:"openai",headers:{"User-Agent":"iFlow-Cli"},clientId:"10009311001",clientSecret:"4Z3YjXycVsQvyGF1etiNlIBB4RsqSDtW",tokenUrl:"https://iflow.cn/oauth/token",authUrl:"https://iflow.cn/oauth"},qoder:{baseUrl:"https://api.qoder.com/v1/chat/completions",format:"openai",headers:{"User-Agent":"Qoder-Cli"},clientId:process.env.QODER_OAUTH_CLIENT_ID||"10009311001",clientSecret:process.env.QODER_OAUTH_CLIENT_SECRET||"4Z3YjXycVsQvyGF1etiNlIBB4RsqSDtW",tokenUrl:"https://api.qoder.com/oauth/token",authUrl:"https://qoder.com/oauth/authorize"},antigravity:{baseUrls:["https://daily-cloudcode-pa.googleapis.com","https://daily-cloudcode-pa.sandbox.googleapis.com"],format:"antigravity",headers:{"User-Agent":`antigravity/1.107.0 ${(0,d.platform)()}/${(0,d.arch)()}`},clientId:"1071006060591-tmhssin2h21lcre235vtolojh4g403ep.apps.googleusercontent.com",clientSecret:"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"},openrouter:{baseUrl:"https://openrouter.ai/api/v1/chat/completions",format:"openai",headers:{"HTTP-Referer":"https://endpoint-proxy.local","X-Title":"Endpoint Proxy"}},openai:{baseUrl:"https://api.openai.com/v1/chat/completions",format:"openai"},"vercel-ai-gateway":{baseUrl:"https://ai-gateway.vercel.sh/v1/chat/completions",format:"openai"},glm:{baseUrl:"https://api.z.ai/api/anthropic/v1/messages",format:"claude",headers:{...e}},"glm-cn":{baseUrl:"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",format:"openai",headers:{}},kimi:{baseUrl:g,format:"claude",headers:{...e}},minimax:{baseUrl:"https://api.minimax.io/anthropic/v1/messages",format:"claude",headers:{...e}},"minimax-cn":{baseUrl:"https://api.minimaxi.com/anthropic/v1/messages",format:"claude",headers:{...e}},alicode:{baseUrl:"https://coding.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{}},"alicode-intl":{baseUrl:"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{}},"volcengine-ark":{baseUrl:"https://ark.cn-beijing.volces.com/api/coding/v3/chat/completions",format:"openai",headers:{}},byteplus:{baseUrl:"https://ark.ap-southeast.bytepluses.com/api/coding/v3/chat/completions",format:"openai",headers:{}},github:{baseUrl:"https://api.githubcopilot.com/chat/completions",responsesUrl:"https://api.githubcopilot.com/responses",format:"openai",headers:{"copilot-integration-id":"vscode-chat","editor-version":"vscode/1.110.0","editor-plugin-version":"copilot-chat/0.38.0","user-agent":"GitHubCopilotChat/0.38.0","openai-intent":"conversation-panel","x-github-api-version":"2025-04-01","x-vscode-user-agent-library-version":"electron-fetch","X-Initiator":"user",Accept:"application/json","Content-Type":"application/json"},clientId:"Iv1.b507a08c87ecfe98"},kiro:{baseUrl:"https://codewhisperer.us-east-1.amazonaws.com/generateAssistantResponse",format:"kiro",retry:{429:2},headers:{"Content-Type":"application/json",Accept:"application/vnd.amazon.eventstream","X-Amz-Target":"AmazonCodeWhispererStreamingService.GenerateAssistantResponse","User-Agent":"AWS-SDK-JS/3.0.0 kiro-ide/1.0.0","X-Amz-User-Agent":"aws-sdk-js/3.0.0 kiro-ide/1.0.0"},tokenUrl:"https://prod.us-east-1.auth.desktop.kiro.dev/refreshToken",authUrl:"https://prod.us-east-1.auth.desktop.kiro.dev"},cursor:{baseUrl:"https://api2.cursor.sh",chatPath:"/aiserver.v1.ChatService/StreamUnifiedChatWithTools",format:"cursor",headers:{"connect-accept-encoding":"gzip","connect-protocol-version":"1","Content-Type":"application/connect+proto","User-Agent":"connect-es/1.6.1"},clientVersion:"3.1.0"},"kimi-coding":{baseUrl:g,format:"claude",headers:{...e},clientId:"17e5f671-d194-4dfb-9706-5516cb48c098",tokenUrl:"https://auth.kimi.com/api/oauth/token",refreshUrl:"https://auth.kimi.com/api/oauth/token"},kilocode:{baseUrl:"https://api.kilo.ai/api/openrouter/chat/completions",format:"openai",headers:{}},opencode:{baseUrl:"http://localhost:4096/v1/chat/completions",format:"openai",headers:{}},cline:{baseUrl:"https://api.cline.bot/api/v1/chat/completions",format:"openai",headers:{"HTTP-Referer":"https://cline.bot","X-Title":"Cline"},tokenUrl:"https://api.cline.bot/api/v1/auth/token",refreshUrl:"https://api.cline.bot/api/v1/auth/refresh"},nvidia:{baseUrl:"https://integrate.api.nvidia.com/v1/chat/completions",format:"openai"},anthropic:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...e}},deepseek:{baseUrl:"https://api.deepseek.com/chat/completions",format:"openai"},commandcode:{baseUrl:"https://api.commandcode.ai/alpha/generate",format:"commandcode",headers:{"x-command-code-version":"0.25.7","x-cli-environment":"cli"}},groq:{baseUrl:"https://api.groq.com/openai/v1/chat/completions",format:"openai"},xai:{baseUrl:"https://api.x.ai/v1/chat/completions",responsesUrl:"https://api.x.ai/v1/responses",format:"openai",clientId:"b1a00492-073a-47ea-816f-4c329264a828",tokenUrl:"https://auth.x.ai/oauth2/token",refreshUrl:"https://auth.x.ai/oauth2/token"},mistral:{baseUrl:"https://api.mistral.ai/v1/chat/completions",format:"openai"},perplexity:{baseUrl:"https://api.perplexity.ai/chat/completions",format:"openai"},together:{baseUrl:"https://api.together.xyz/v1/chat/completions",format:"openai"},fireworks:{baseUrl:"https://api.fireworks.ai/inference/v1/chat/completions",format:"openai"},cerebras:{baseUrl:"https://api.cerebras.ai/v1/chat/completions",format:"openai"},cohere:{baseUrl:"https://api.cohere.ai/v1/chat/completions",format:"openai"},nebius:{baseUrl:"https://api.studio.nebius.ai/v1/chat/completions",format:"openai"},siliconflow:{baseUrl:"https://api.siliconflow.cn/v1/chat/completions",format:"openai"},hyperbolic:{baseUrl:"https://api.hyperbolic.xyz/v1/chat/completions",format:"openai"},deepgram:{baseUrl:"https://api.deepgram.com/v1/listen",format:"openai"},assemblyai:{baseUrl:"https://api.assemblyai.com/v1/audio/transcriptions",format:"openai"},nanobanana:{baseUrl:"https://api.nanobananaapi.ai/v1/chat/completions",format:"openai"},chutes:{baseUrl:"https://llm.chutes.ai/v1/chat/completions",format:"openai"},ollama:{baseUrl:"https://ollama.com/api/chat",format:"ollama"},"ollama-local":{baseUrl:"http://localhost:11434/api/chat",format:"ollama"},vertex:{baseUrl:"https://aiplatform.googleapis.com",format:"vertex"},"vertex-partner":{baseUrl:"https://aiplatform.googleapis.com",format:"openai"},gitlab:{baseUrl:"https://gitlab.com/api/v4/chat/completions",format:"openai"},codebuddy:{baseUrl:"https://copilot.tencent.com/v1/chat/completions",format:"openai"},opencode:{baseUrl:"https://opencode.ai",format:"openai",headers:{"x-opencode-client":"desktop"},noAuth:!0},"opencode-go":{baseUrl:"https://opencode.ai/zen/go/v1/chat/completions",format:"openai",headers:{}},"grok-web":{baseUrl:"https://grok.com/rest/app-chat/conversations/new",format:"grok-web",authType:"cookie"},"perplexity-web":{baseUrl:"https://www.perplexity.ai/rest/sse/perplexity_ask",format:"perplexity-web",authType:"cookie"},azure:{baseUrl:"",format:"openai",headers:{}},"cloudflare-ai":{baseUrl:"https://api.cloudflare.com/client/v4/accounts/{accountId}/ai/v1/chat/completions",format:"openai"},"xiaomi-mimo":{baseUrl:"https://api.xiaomimimo.com/v1/chat/completions",format:"openai"},"xiaomi-tokenplan":{baseUrl:"https://token-plan-sgp.xiaomimimo.com/v1/chat/completions",format:"openai"},agentrouter:{baseUrl:"https://agentrouter.org/v1/messages",format:"claude",headers:{...f}},aimlapi:{baseUrl:"https://api.aimlapi.com/v1/chat/completions",format:"openai"},novita:{baseUrl:"https://api.novita.ai/v3/openai/chat/completions",format:"openai"},modal:{baseUrl:"https://api.modal.com/v1/chat/completions",format:"openai"},reka:{baseUrl:"https://api.reka.ai/v1/chat/completions",format:"openai"},nlpcloud:{baseUrl:"https://api.nlpcloud.io/v1/gpu/chatbot",format:"openai"},bazaarlink:{baseUrl:"https://bazaarlink.ai/api/v1/chat/completions",format:"openai"},completions:{baseUrl:"https://completions.me/api/v1/chat/completions",format:"openai"},enally:{baseUrl:"https://ai.enally.in/v1/chat/completions",format:"openai",authHeader:"x-api-key"},freetheai:{baseUrl:"https://api.freetheai.xyz/v1/chat/completions",format:"openai"},llm7:{baseUrl:"https://api.llm7.io/v1/chat/completions",format:"openai"},lepton:{baseUrl:"https://api.lepton.ai/api/v1/chat/completions",format:"openai"},kluster:{baseUrl:"https://api.kluster.ai/v1/chat/completions",format:"openai"},ai21:{baseUrl:"https://api.ai21.com/studio/v1/chat/completions",format:"openai"},"inference-net":{baseUrl:"https://api.inference.net/v1/chat/completions",format:"openai"},predibase:{baseUrl:"https://serving.app.predibase.com/v1/chat/completions",format:"openai"},bytez:{baseUrl:"https://api.bytez.com/models/v2",format:"openai"},morph:{baseUrl:"https://api.morphllm.com/v1/chat/completions",format:"openai"},longcat:{baseUrl:"https://api.longcat.chat/openai/v1/chat/completions",format:"openai"},puter:{baseUrl:"https://api.puter.com/puterai/openai/v1/chat/completions",format:"openai"},uncloseai:{baseUrl:"https://hermes.ai.unturf.com/v1/chat/completions",format:"openai",noAuth:!0},scaleway:{baseUrl:"https://api.scaleway.ai/v1/chat/completions",format:"openai"},deepinfra:{baseUrl:"https://api.deepinfra.com/v1/openai/chat/completions",format:"openai"},sambanova:{baseUrl:"https://api.sambanova.ai/v1/chat/completions",format:"openai"},nscale:{baseUrl:"https://inference.api.nscale.com/v1/chat/completions",format:"openai"},baseten:{baseUrl:"https://inference.baseten.co/v1/chat/completions",format:"openai"},publicai:{baseUrl:"https://api.publicai.co/v1/chat/completions",format:"openai"},"nous-research":{baseUrl:"https://inference-api.nousresearch.com/v1/chat/completions",format:"openai"},glhf:{baseUrl:"https://glhf.chat/api/openai/v1/chat/completions",format:"openai"},blackbox:{baseUrl:"https://api.blackbox.ai/chat/completions",format:"openai"}};function i(a){return(a?.providerSpecificData?.baseUrl?.trim()||"http://localhost:11434").replace(/\/$/,"")}let j={sgp:"https://token-plan-sgp.xiaomimimo.com/v1",cn:"https://token-plan-cn.xiaomimimo.com/v1",ams:"https://token-plan-ams.xiaomimimo.com/v1"};function k(a){return j[a?.providerSpecificData?.region]||j.sgp}},64749:()=>{},68355:(a,b,c)=>{"use strict";c.d(b,{g:()=>m,l:()=>l});var d=c(79646),e=c(33873),f=c.n(e),g=c(29021),h=c.n(g),i=c(21820),j=c.n(i),k=c(89489);async function l(){!function(){try{let a=f().join("win32"===process.platform?f().join(process.env.APPDATA||"","9router"):f().join(j().homedir(),".9router"),"mitm",".mitm.pid");if(!h().existsSync(a))return;let b=parseInt(h().readFileSync(a,"utf8").trim(),10);if(!b)return;if("win32"===process.platform)try{(0,d.execSync)(`taskkill /F /T /PID ${b}`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{try{(0,d.execSync)(`powershell -NonInteractive -WindowStyle Hidden -Command "Stop-Process -Id ${b} -Force"`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{}}else try{(0,d.execSync)(`sudo -n kill -9 ${b} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{try{process.kill(b,"SIGKILL")}catch{}}try{h().unlinkSync(a)}catch{}}catch{}}();let a=function(){let a=[];if("win32"===process.platform){try{(0,d.execSync)('powershell -NonInteractive -WindowStyle Hidden -Command "Get-WmiObject Win32_Process -Filter \'Name=\\"node.exe\\"\' | Select-Object ProcessId,CommandLine | ConvertTo-Csv -NoTypeInformation"',{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").slice(1).filter(a=>a.trim()).forEach(b=>{let c=b.toLowerCase();if(c.includes("9router")||c.includes("next-server")||c.includes("\\bin\\app\\")||c.includes("/bin/app/")||c.includes("cli.js")){let c=b.match(/^"(\d+)"/);c&&c[1]&&c[1]!==process.pid.toString()&&a.push(c[1])}})}catch{}for(let b of["cloudflared","tray_windows_release"])try{let c=`powershell -NonInteractive -WindowStyle Hidden -Command "Get-Process ${b} -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Id"`;(0,d.execSync)(c,{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").forEach(b=>{let c=b.trim();c&&!isNaN(c)&&a.push(c)})}catch{}}else try{(0,d.execSync)("ps aux 2>/dev/null",{encoding:"utf8",timeout:5e3}).split("\n").forEach(b=>{if(b.includes("9router")||b.includes("next-server")||b.includes("cloudflared")||b.includes("/bin/app/")||b.includes("tray_darwin")||b.includes("tray_linux")){let c=b.trim().split(/\s+/)[1];c&&!isNaN(c)&&c!==process.pid.toString()&&a.push(c)}})}catch{}return a}(),b=process.platform;a.forEach(a=>{try{"win32"===b?(0,d.execSync)(`taskkill /F /PID ${a} 2>nul`,{stdio:"ignore",shell:!0,windowsHide:!0,timeout:3e3}):(0,d.execSync)(`kill -9 ${a} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{}}),a.length>0&&await new Promise(a=>setTimeout(a,1500))}function m(a=k.h0.npmPackageName){let b=function(a){try{if(!a||!h().existsSync(a))return a;let b=f().join(process.env.DATA_DIR?process.env.DATA_DIR:"win32"===process.platform?f().join(process.env.APPDATA||f().join(j().homedir(),"AppData","Roaming"),"9router"):f().join(j().homedir(),".9router"),"runtime","updater"),c=f().join(b,"updater.js");if(h().existsSync(c))try{if(h().statSync(a).size===h().statSync(c).size)return c}catch{}return h().mkdirSync(b,{recursive:!0}),h().copyFileSync(a,c),c}catch{return a}}(function(){if(process.env.UPDATER_SCRIPT_PATH&&h().existsSync(process.env.UPDATER_SCRIPT_PATH))return process.env.UPDATER_SCRIPT_PATH;let a=f().join(process.cwd(),"src","lib","updater","updater.js");if(h().existsSync(a))return a;let b=f().join(process.cwd(),"..","src","lib","updater","updater.js");return h().existsSync(b)?b:a}()),c="1"===process.env.TRAY_MODE,e={cmd:"win32"===process.platform?"npx.cmd":"npx",args:[k.h0.npmPackageName]},g=c?[...e.args,"--tray","--skip-update"]:[...e.args,"--skip-update"];(0,d.spawn)(process.execPath,[b],{detached:!0,stdio:"ignore",windowsHide:!0,env:{...process.env,UPDATER_PKG_NAME:a,UPDATER_PORT:String(k.h0.statusPort),UPDATER_TAIL_LINES:String(k.h0.statusLogTailLines),UPDATER_RETRIES:String(k.h0.installRetries),UPDATER_RETRY_DELAY_MS:String(k.h0.installRetryDelayMs),UPDATER_LINGER_MS:String(k.h0.lingerAfterDoneMs),UPDATER_WAIT_MIN_MS:String(k.h0.waitForExitMinMs),UPDATER_WAIT_MAX_MS:String(k.h0.waitForExitMaxMs),UPDATER_WAIT_CHECK_MS:String(k.h0.waitForExitCheckMs),UPDATER_APP_PORT:String(k.h0.appPort),UPDATER_RELAUNCH:"1",UPDATER_RELAUNCH_CMD:e.cmd,UPDATER_RELAUNCH_ARGS:JSON.stringify(g)}}).unref(),setTimeout(()=>process.exit(0),k.h0.exitDelayMs)}},89489:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(50021),f=c(24709);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@latest --prefer-online",shutdownCountdownSec:3,exitDelayMs:500,statusPort:20129,statusPollIntervalMs:1e3,statusLogTailLines:8,installRetries:3,installRetryDelayMs:5e3,lingerAfterDoneMs:3e4,waitForExitMinMs:5e3,waitForExitMaxMs:2e4,waitForExitCheckMs:500,appPort:20128},h={maxLines:200,pollIntervalMs:1e3},i={openrouter:"https://openrouter.ai/api/v1/chat/completions",glm:"https://api.z.ai/api/anthropic/v1/messages","glm-cn":"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",kimi:"https://api.kimi.com/coding/v1/messages",minimax:"https://api.minimax.io/anthropic/v1/messages","minimax-cn":"https://api.minimaxi.com/anthropic/v1/messages",alicode:"https://coding.dashscope.aliyuncs.com/v1/chat/completions","alicode-intl":"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions","volcengine-ark":"https://ark.cn-beijing.volces.com/api/coding/v3/chat/completions",byteplus:"https://ark.ap-southeast.bytepluses.com/api/coding/v3/chat/completions",openai:"https://api.openai.com/v1/chat/completions","vercel-ai-gateway":"https://ai-gateway.vercel.sh/v1/chat/completions",anthropic:"https://api.anthropic.com/v1/messages",gemini:"https://generativelanguage.googleapis.com/v1beta/models",ollama:"https://ollama.com/api/chat","ollama-local":"http://localhost:11434/api/chat"}}};
@@ -1 +1 @@
1
- "use strict";exports.id=586,exports.ids=[586],exports.modules={30586:(a,b,c)=>{c.d(b,{PROVIDER_PRICING:()=>e,getPricingForModel:()=>h});let d={"claude-opus-4-6":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-opus-4-5-20251101":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-sonnet-4-6":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-sonnet-4-5-20250929":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-haiku-4-5-20251001":{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25},"claude-sonnet-4-20250514":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-opus-4-20250514":{input:15,output:25,cached:7.5,reasoning:112.5,cache_creation:15},"claude-3-5-sonnet-20241022":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-haiku-4.5":{input:.5,output:2.5,cached:.05,reasoning:3.75,cache_creation:.5},"claude-opus-4.1":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.5":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.6":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-sonnet-4":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.5":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.6":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-opus-4-5-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4-6-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"gpt-3.5-turbo":{input:.5,output:1.5,cached:.25,reasoning:2.25,cache_creation:.5},"gpt-4":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4-turbo":{input:10,output:30,cached:5,reasoning:45,cache_creation:10},"gpt-4o":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15},"gpt-4.1":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-5":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5-mini":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"gpt-5-codex":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5.1":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.1-codex":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.1-codex-mini":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"gpt-5.1-codex-mini-high":{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"gpt-5.1-codex-max":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.2":{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5},"gpt-5.2-codex":{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5},"gpt-5.3-codex":{input:6,output:24,cached:3,reasoning:36,cache_creation:6},"gpt-5.3-codex-xhigh":{input:10,output:40,cached:5,reasoning:60,cache_creation:10},"gpt-5.3-codex-high":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.3-codex-low":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.3-codex-none":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5.3-codex-spark":{input:3,output:12,cached:.3,reasoning:12,cache_creation:3},o1:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15},"o1-mini":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gemini-3-flash-preview":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-pro-preview":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-low":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-high":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-3-flash":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-2.5-pro":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-2.5-flash":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3},"gemini-2.5-flash-lite":{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15},"qwen3-coder-plus":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"qwen3-coder-flash":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"kimi-k2":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-k2-thinking":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"kimi-k2.5":{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2},"kimi-k2.5-thinking":{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8},"kimi-latest":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"deepseek-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-r1":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87,cache_creation:.435},"glm-4.6":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"glm-4.6v":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-4.7":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-5":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"MiniMax-M2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.5":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.7":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.5":{input:.6,output:2.4,cached:.3,reasoning:3.6,cache_creation:.6},"grok-code-fast-1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},auto:{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"oswe-vscode-prime":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"gpt-oss-120b-medium":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"vision-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"coder-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},e={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}}},f=[{pattern:"*-codex-xhigh",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"*-codex-high",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-max",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-mini-*",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-mini",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-low",pricing:{input:4,output:16,cached:2,reasoning:24,cache_creation:4}},{pattern:"*-codex-none",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"*-codex-spark",pricing:{input:3,output:12,cached:.3,reasoning:12,cache_creation:3}},{pattern:"codex-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"*-codex",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"claude-opus-*",pricing:{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25}},{pattern:"claude-sonnet-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"claude-haiku-*",pricing:{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25}},{pattern:"claude-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"gemini-*-flash-lite",pricing:{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15}},{pattern:"gemini-*-flash",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*-pro",pricing:{input:2,output:12,cached:.25,reasoning:18,cache_creation:2}},{pattern:"gemini-3-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gemini-2.5-*",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gpt-5.3-*",pricing:{input:6,output:24,cached:3,reasoning:36,cache_creation:6}},{pattern:"gpt-5.2-*",pricing:{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5}},{pattern:"gpt-5.1-*",pricing:{input:4,output:16,cached:2,reasoning:24,cache_creation:4}},{pattern:"gpt-5-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"gpt-5*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"gpt-4o-*",pricing:{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15}},{pattern:"gpt-4o",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-4*",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"o1-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"o1",pricing:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15}},{pattern:"o3-*",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"o4-*",pricing:{input:2,output:8,cached:1,reasoning:12,cache_creation:2}},{pattern:"qwen3-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"kimi-*-thinking",pricing:{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8}},{pattern:"kimi-k2*",pricing:{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2}},{pattern:"kimi-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"deepseek-*reasoner*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-r*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-v*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"glm-5*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"glm-4*",pricing:{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75}},{pattern:"glm-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"MiniMax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"minimax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-code-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}}];function g(a,b){return RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$").test(b)}function h(a,b){if(!b)return null;if(a&&e[a]?.[b])return e[a][b];let c=b.includes("/")?b.split("/").pop():b;if(d[c])return d[c];if(d[b])return d[b];for(let{pattern:a,pricing:d}of f)if(g(a,c)||g(a,b))return d;return null}}};
1
+ "use strict";exports.id=586,exports.ids=[586],exports.modules={30586:(a,b,c)=>{c.d(b,{PROVIDER_PRICING:()=>e,getPricingForModel:()=>h});let d={"claude-opus-4-6":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-opus-4-5-20251101":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-sonnet-4-6":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-sonnet-4-5-20250929":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-haiku-4-5-20251001":{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25},"claude-sonnet-4-20250514":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-opus-4-20250514":{input:15,output:25,cached:7.5,reasoning:112.5,cache_creation:15},"claude-3-5-sonnet-20241022":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-haiku-4.5":{input:.5,output:2.5,cached:.05,reasoning:3.75,cache_creation:.5},"claude-opus-4.1":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.5":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.6":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-sonnet-4":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.5":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.6":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-opus-4-5-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4-6-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"gpt-3.5-turbo":{input:.5,output:1.5,cached:.25,reasoning:2.25,cache_creation:.5},"gpt-4":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4-turbo":{input:10,output:30,cached:5,reasoning:45,cache_creation:10},"gpt-4o":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15},"gpt-4.1":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-5":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5-mini":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"gpt-5-codex":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5.1":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.1-codex":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.1-codex-mini":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"gpt-5.1-codex-mini-high":{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"gpt-5.1-codex-max":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.2":{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5},"gpt-5.2-codex":{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5},"gpt-5.3-codex":{input:6,output:24,cached:3,reasoning:36,cache_creation:6},"gpt-5.3-codex-xhigh":{input:10,output:40,cached:5,reasoning:60,cache_creation:10},"gpt-5.3-codex-high":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.3-codex-low":{input:4,output:16,cached:2,reasoning:24,cache_creation:4},"gpt-5.3-codex-none":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gpt-5.3-codex-spark":{input:3,output:12,cached:.3,reasoning:12,cache_creation:3},o1:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15},"o1-mini":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gemini-3-flash-preview":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-pro-preview":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-low":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-high":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-pro-agent":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-3-flash-agent":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3.5-flash-low":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-flash":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-2.5-pro":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-2.5-flash":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3},"gemini-2.5-flash-lite":{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15},"qwen3-coder-plus":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"qwen3-coder-flash":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"kimi-k2":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-k2-thinking":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"kimi-k2.5":{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2},"kimi-k2.5-thinking":{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8},"kimi-latest":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"deepseek-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-r1":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87,cache_creation:.435},"glm-4.6":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"glm-4.6v":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-4.7":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-5":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"MiniMax-M2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.5":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.7":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.5":{input:.6,output:2.4,cached:.3,reasoning:3.6,cache_creation:.6},"grok-code-fast-1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},auto:{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"oswe-vscode-prime":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"gpt-oss-120b-medium":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"vision-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"coder-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},e={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}}},f=[{pattern:"*-codex-xhigh",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"*-codex-high",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-max",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-mini-*",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-mini",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-low",pricing:{input:4,output:16,cached:2,reasoning:24,cache_creation:4}},{pattern:"*-codex-none",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"*-codex-spark",pricing:{input:3,output:12,cached:.3,reasoning:12,cache_creation:3}},{pattern:"codex-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"*-codex",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"claude-opus-*",pricing:{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25}},{pattern:"claude-sonnet-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"claude-haiku-*",pricing:{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25}},{pattern:"claude-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"gemini-*-flash-lite",pricing:{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15}},{pattern:"gemini-*-flash",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*-pro",pricing:{input:2,output:12,cached:.25,reasoning:18,cache_creation:2}},{pattern:"gemini-3-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gemini-2.5-*",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gpt-5.3-*",pricing:{input:6,output:24,cached:3,reasoning:36,cache_creation:6}},{pattern:"gpt-5.2-*",pricing:{input:5,output:20,cached:2.5,reasoning:30,cache_creation:5}},{pattern:"gpt-5.1-*",pricing:{input:4,output:16,cached:2,reasoning:24,cache_creation:4}},{pattern:"gpt-5-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"gpt-5*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"gpt-4o-*",pricing:{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15}},{pattern:"gpt-4o",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-4*",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"o1-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"o1",pricing:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15}},{pattern:"o3-*",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"o4-*",pricing:{input:2,output:8,cached:1,reasoning:12,cache_creation:2}},{pattern:"qwen3-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"kimi-*-thinking",pricing:{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8}},{pattern:"kimi-k2*",pricing:{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2}},{pattern:"kimi-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"deepseek-*reasoner*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-r*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-v*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"glm-5*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"glm-4*",pricing:{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75}},{pattern:"glm-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"MiniMax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"minimax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-code-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}}];function g(a,b){return RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$").test(b)}function h(a,b){if(!b)return null;if(a&&e[a]?.[b])return e[a][b];let c=b.includes("/")?b.split("/").pop():b;if(d[c])return d[c];if(d[b])return d[b];for(let{pattern:a,pricing:d}of f)if(g(a,c)||g(a,b))return d;return null}}};
@@ -1,13 +1,13 @@
1
- "use strict";exports.id=6263,exports.ids=[6263],exports.modules={1820:(a,b,c)=>{c.d(b,{c:()=>m});var d=c(55511),e=c.n(d),f=c(24353),g=c(62276),h=c(43528),i=c(23016),j=c(20362),k=c(37973),l=c(13077);class m extends f.H{constructor(){super("antigravity",g.xq.antigravity)}buildUrl(a,b,c=0){let d=this.getBaseUrls(),e=d[c]||d[0];return`${e}/v1internal:${b?"streamGenerateContent?alt=sse":"generateContent"}`}buildHeaders(a,b=!0,c=null){return{"Content-Type":"application/json",Authorization:`Bearer ${a.accessToken}`,"User-Agent":this.config.headers?.["User-Agent"]||h.K["User-Agent"],[h.Ox.name]:h.Ox.value,...c&&{"X-Machine-Session-Id":c},Accept:b?"text/event-stream":"application/json"}}transformRequest(a,b,c,d){let f=d?.projectId||this.generateProjectId(),g=b.request?.contents?.map(a=>{let b=a.role;a.parts?.some(a=>a.functionResponse)&&(b="user");let c=a.parts?.filter(a=>(!a.thought||!!a.functionCall)&&(!a.thoughtSignature||!!a.functionCall||!!a.text));return b!==a.role||c?.length!==a.parts?.length?{...a,role:b,parts:c}:a}),h=b.request?.tools;if(h&&h.length>0){let a=h.flatMap(a=>(a.functionDeclarations||[]).map(a=>({...a,name:function(a){if(!a)return"_unknown";let b=a.replace(/[^a-zA-Z0-9_.:\-]/g,"_");return/^[a-zA-Z_]/.test(b)||(b="_"+b),b.substring(0,64)}(a.name),parameters:a.parameters?(0,l.Yr)(structuredClone(a.parameters)):{type:"object",properties:{reason:{type:"string",description:"Brief explanation"}},required:["reason"]}})));h=a.length>0?[{functionDeclarations:a}]:[]}let{tools:i,toolConfig:k,...m}=b.request||{},n={...m.generationConfig||{}};n.maxOutputTokens>16384&&(n.maxOutputTokens=16384);let o={...m,generationConfig:n,...g&&{contents:g},...h&&{tools:h},sessionId:b.request?.sessionId||(0,j.RF)(d?.email||d?.connectionId),safetySettings:void 0,...h?.length>0&&{toolConfig:{functionCallingConfig:{mode:"VALIDATED"}}}};return{...b,project:f,model:a,userAgent:"antigravity",requestType:"agent",requestId:`agent-${e().randomUUID()}`,request:o}}async refreshCredentials(a,b,c=null){if(!a.refreshToken)return null;try{let d=await (0,k.proxyAwareFetch)(h.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a.refreshToken,client_id:this.config.clientId,client_secret:this.config.clientSecret})},c);if(!d.ok)return null;let e=await d.json();return b?.info?.("TOKEN","Antigravity refreshed"),{accessToken:e.access_token,refreshToken:e.refresh_token||a.refreshToken,expiresIn:e.expires_in,projectId:a.projectId}}catch(a){return b?.error?.("TOKEN",`Antigravity refresh error: ${a.message}`),null}}generateProjectId(){let a=["useful","bright","swift","calm","bold"][Math.floor(5*Math.random())],b=["fuze","wave","spark","flow","core"][Math.floor(5*Math.random())];return`${a}-${b}-${e().randomUUID().slice(0,5)}`}generateSessionId(){return e().randomUUID()+Date.now().toString()}parseRetryHeaders(a){if(!a?.get)return null;let b=a.get("retry-after");if(b){let a=parseInt(b,10);if(!isNaN(a)&&a>0)return 1e3*a;let c=new Date(b);if(!isNaN(c.getTime())){let a=c.getTime()-Date.now();return a>0?a:null}}let c=a.get("x-ratelimit-reset-after");if(c){let a=parseInt(c,10);if(!isNaN(a)&&a>0)return 1e3*a}let d=a.get("x-ratelimit-reset");if(d){let a=1e3*parseInt(d,10)-Date.now();return a>0?a:null}return null}parseRetryFromErrorMessage(a){if(!a||"string"!=typeof a)return null;let b=a.match(/reset after (\d+h)?(\d+m)?(\d+s)?/i);if(!b)return null;let c=0;return b[1]&&(c+=3600*parseInt(b[1])*1e3),b[2]&&(c+=60*parseInt(b[2])*1e3),b[3]&&(c+=1e3*parseInt(b[3])),c>0?c:null}async execute({model:a,body:b,stream:c,credentials:d,signal:e,log:f,proxyOptions:g=null}){let h=this.getFallbackCount(),j=null,l=0,m={},n={};for(let o=0;o<h;o++){let p=this.buildUrl(a,c,o),q=this.transformRequest(a,b,c,d),r=q.request?.sessionId,s=this.buildHeaders(d,c,r);m[o]||(m[o]=0),n[o]||(n[o]=0);try{let a=await (0,k.proxyAwareFetch)(p,{method:"POST",headers:s,body:JSON.stringify(q),signal:e},g);if(a.status===i.gx.RATE_LIMITED||a.status===i.gx.SERVICE_UNAVAILABLE){let b=this.parseRetryHeaders(a.headers);if(!b)try{let c=await a.clone().text(),d=JSON.parse(c),e=d?.error?.message||d?.message||"";b=this.parseRetryFromErrorMessage(e)}catch(a){}if(b&&b<=1e4&&n[o]<3){n[o]++,f?.debug?.("RETRY",`${a.status} with Retry-After: ${Math.ceil(b/1e3)}s, waiting... (${n[o]}/3)`),await new Promise(a=>setTimeout(a,b)),o--;continue}if(a.status===i.gx.RATE_LIMITED&&(!b||0===b)&&m[o]<3){m[o]++;let a=Math.min(1e3*2**m[o],1e4);f?.debug?.("RETRY",`429 auto retry ${m[o]}/3 after ${a/1e3}s`),await new Promise(b=>setTimeout(b,a)),o--;continue}if(f?.debug?.("RETRY",`${a.status}, Retry-After ${b?`too long (${Math.ceil(b/1e3)}s)`:"missing"}, trying fallback`),l=a.status,o+1<h)continue}if(this.shouldRetry(a.status,o)){f?.debug?.("RETRY",`${a.status} on ${p}, trying fallback ${o+1}`),l=a.status;continue}return{response:a,url:p,headers:s,transformedBody:q}}catch(a){if(j=a,o+1<h){f?.debug?.("RETRY",`Error on ${p}, trying fallback ${o+1}`);continue}throw a}}throw j||Error(`All ${h} URLs failed with status ${l}`)}static cloakTools(a,b=null){let c=a.request?.tools;if(!c||0===c.length)return{cloakedBody:a,toolNameMap:null};let d="github-copilot"===b,e=new Map,f=[],g=new Set(n.map(a=>a.name));for(let a of c)if(a.functionDeclarations)for(let b of a.functionDeclarations){if(d&&h.J5.has(b.name)||d&&g.has(b.name))continue;if(h.J5.has(b.name)){f.push(b);continue}let a=`${b.name}${h.QH}`;e.set(a,b.name),f.push({...b,name:a})}let i=[],j=new Set;for(let a of[...f,...n])!a?.name||j.has(a.name)||(j.add(a.name),i.push(a));let k=a.request?.contents?.map(a=>{if(!a.parts)return a;let b=a.parts.map(a=>a.functionCall&&!h.J5.has(a.functionCall.name)?{...a,functionCall:{...a.functionCall,name:`${a.functionCall.name}${h.QH}`}}:a.functionResponse&&!h.J5.has(a.functionResponse.name)?{...a,functionResponse:{...a.functionResponse,name:`${a.functionResponse.name}${h.QH}`}}:a);return{...a,parts:b}});return{cloakedBody:{...a,request:{...a.request,tools:[{functionDeclarations:i}],contents:k||a.request.contents}},toolNameMap:e}}}let n=[{name:"browser_subagent",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"command_status",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"find_by_name",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"generate_image",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"grep_search",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"list_dir",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"list_resources",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"mcp_sequential-thinking_sequentialthinking",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"multi_replace_file_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"notify_user",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_resource",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_terminal",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_url_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"replace_file_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"run_command",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"search_web",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"send_command_input",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"task_boundary",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"view_content_chunk",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"view_file",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"write_to_file",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}}]},1950:(a,b,c)=>{c.r(b),c.d(b,{openaiResponsesToOpenAIResponse:()=>n,openaiToOpenAIResponsesResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a){var c=b;if(c.completedSent)return[];let a=[],d=(b,d)=>{d.sequence_number=++c.seq,a.push({event:b,data:d})};for(let a in c.msgItemAdded)j(c,d,a);for(let a in i(c,d),c.funcCallIds)k(c,d,a);return l(c,d),a}if(!a.choices?.length)return[];let d=[],e=(a,c)=>{c.sequence_number=++b.seq,d.push({event:a,data:c})},f=a.choices[0],m=f.index||0,n=f.delta||{};if(b.started||(b.started=!0,b.responseId=a.id?`resp_${a.id}`:b.responseId,e("response.created",{type:"response.created",response:{id:b.responseId,object:"response",created_at:b.created,status:"in_progress",background:!1,error:null,output:[]}}),e("response.in_progress",{type:"response.in_progress",response:{id:b.responseId,object:"response",created_at:b.created,status:"in_progress"}})),n.reasoning_content&&(g(b,e,m),h(b,e,n.reasoning_content)),n.content){let a=n.content;if(a.includes("<think>")&&(b.inThinking=!0,a=a.replace("<think>",""),g(b,e,m)),a.includes("</think>")){let c=a.split("</think>"),d=c[0],f=c.slice(1).join("</think>");d&&h(b,e,d),i(b,e),b.inThinking=!1,a=f}if(b.inThinking&&a)return h(b,e,a),d;a&&function(a,b,c,d){if(!a.msgItemAdded[c]){a.msgItemAdded[c]=!0;let d=`msg_${a.responseId}_${c}`;b("response.output_item.added",{type:"response.output_item.added",output_index:c,item:{id:d,type:"message",content:[],role:"assistant"}})}a.msgContentAdded[c]||(a.msgContentAdded[c]=!0,b("response.content_part.added",{type:"response.content_part.added",item_id:`msg_${a.responseId}_${c}`,output_index:c,content_index:0,part:{type:"output_text",annotations:[],logprobs:[],text:""}})),b("response.output_text.delta",{type:"response.output_text.delta",item_id:`msg_${a.responseId}_${c}`,output_index:c,content_index:0,delta:d,logprobs:[]}),a.msgTextBuf[c]||(a.msgTextBuf[c]=""),a.msgTextBuf[c]+=d}(b,e,m,a)}if(n.tool_calls)for(let a of(j(b,e,m),n.tool_calls))!function(a,b,c){let d=c.index??0,e=c.id,f=c.function?.name;if(f&&(a.funcNames[d]=f),!a.funcCallIds[d]&&e&&(a.funcCallIds[d]=e,b("response.output_item.added",{type:"response.output_item.added",output_index:d,item:{id:`fc_${e}`,type:"function_call",arguments:"",call_id:e,name:a.funcNames[d]||""}})),a.funcArgsBuf[d]||(a.funcArgsBuf[d]=""),c.function?.arguments){let f=a.funcCallIds[d]||e;f&&b("response.function_call_arguments.delta",{type:"response.function_call_arguments.delta",item_id:`fc_${f}`,output_index:d,delta:c.function.arguments}),a.funcArgsBuf[d]+=c.function.arguments}}(b,e,a);if(f.finish_reason){for(let a in b.msgItemAdded)j(b,e,a);for(let a in i(b,e),b.funcCallIds)k(b,e,a);l(b,e)}return d}function g(a,b,c){a.reasoningId||(a.reasoningId=`rs_${a.responseId}_${c}`,a.reasoningIndex=c,b("response.output_item.added",{type:"response.output_item.added",output_index:c,item:{id:a.reasoningId,type:"reasoning",summary:[]}}),b("response.reasoning_summary_part.added",{type:"response.reasoning_summary_part.added",item_id:a.reasoningId,output_index:c,summary_index:0,part:{type:"summary_text",text:""}}),a.reasoningPartAdded=!0)}function h(a,b,c){c&&(a.reasoningBuf+=c,b("response.reasoning_summary_text.delta",{type:"response.reasoning_summary_text.delta",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,delta:c}))}function i(a,b){a.reasoningId&&!a.reasoningDone&&(a.reasoningDone=!0,b("response.reasoning_summary_text.done",{type:"response.reasoning_summary_text.done",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,text:a.reasoningBuf}),b("response.reasoning_summary_part.done",{type:"response.reasoning_summary_part.done",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,part:{type:"summary_text",text:a.reasoningBuf}}),b("response.output_item.done",{type:"response.output_item.done",output_index:a.reasoningIndex,item:{id:a.reasoningId,type:"reasoning",summary:[{type:"summary_text",text:a.reasoningBuf}]}}))}function j(a,b,c){if(a.msgItemAdded[c]&&!a.msgItemDone[c]){a.msgItemDone[c]=!0;let d=a.msgTextBuf[c]||"",e=`msg_${a.responseId}_${c}`;b("response.output_text.done",{type:"response.output_text.done",item_id:e,output_index:parseInt(c),content_index:0,text:d,logprobs:[]}),b("response.content_part.done",{type:"response.content_part.done",item_id:e,output_index:parseInt(c),content_index:0,part:{type:"output_text",annotations:[],logprobs:[],text:d}}),b("response.output_item.done",{type:"response.output_item.done",output_index:parseInt(c),item:{id:e,type:"message",content:[{type:"output_text",annotations:[],logprobs:[],text:d}],role:"assistant"}})}}function k(a,b,c){let d=a.funcCallIds[c];if(d&&!a.funcItemDone[c]){let e=a.funcArgsBuf[c]||"{}";b("response.function_call_arguments.done",{type:"response.function_call_arguments.done",item_id:`fc_${d}`,output_index:parseInt(c),arguments:e}),b("response.output_item.done",{type:"response.output_item.done",output_index:parseInt(c),item:{id:`fc_${d}`,type:"function_call",arguments:e,call_id:d,name:a.funcNames[c]||""}}),a.funcItemDone[c]=!0,a.funcArgsDone[c]=!0}}function l(a,b){a.completedSent||(a.completedSent=!0,b("response.completed",{type:"response.completed",response:{id:a.responseId,object:"response",created_at:a.created,status:"completed",background:!1,error:null}}))}function m(a){return a.toolCallIndex>0||a.currentToolCallId?"tool_calls":"stop"}function n(a,b){if(!a){if(b.finishReasonSent||!b.started)return null;let a=m(b);b.finishReasonSent=!0,b.finishReason=a;let c={id:b.chatId||`chatcmpl-${Date.now()}`,object:"chat.completion.chunk",created:b.created||Math.floor(Date.now()/1e3),model:b.model||"unknown",choices:[{index:0,delta:{},finish_reason:a}]};return b.usage&&"object"==typeof b.usage&&(c.usage=b.usage),c}let c=a.type||a.event,d=a.data||a;if(b.started||(b.started=!0,b.chatId=`chatcmpl-${Date.now()}`,b.created=Math.floor(Date.now()/1e3),b.toolCallIndex=0,b.currentToolCallId=null),"response.output_text.delta"===c){let a=d.delta||"";return a?{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{content:a},finish_reason:null}]}:null}if("response.output_text.done"===c)return null;if("response.output_item.added"===c&&(d.item?.type==="function_call"||d.item?.type==="custom_tool_call")){let a=d.item;return b.currentToolCallId=a.call_id||`call_${Date.now()}`,{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{tool_calls:[{index:b.toolCallIndex,id:b.currentToolCallId,type:"function",function:{name:a.name||"",arguments:""}}]},finish_reason:null}]}}if("response.function_call_arguments.delta"===c||"response.custom_tool_call_input.delta"===c){let a=d.delta||"";return a?{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{tool_calls:[{index:b.toolCallIndex,function:{arguments:a}}]},finish_reason:null}]}:null}if("response.output_item.done"===c&&(d.item?.type==="function_call"||d.item?.type==="custom_tool_call"))return b.toolCallIndex++,null;if("response.completed"===c){let a=d.response?.usage;if(a&&"object"==typeof a){let c=a.input_tokens||a.prompt_tokens||0,d=a.output_tokens||a.completion_tokens||0,e=a.input_tokens_details?.cached_tokens||a.cache_read_input_tokens||0;b.usage={prompt_tokens:c,completion_tokens:d,total_tokens:c+d},e>0&&(b.usage.prompt_tokens_details={cached_tokens:e})}if(!b.finishReasonSent){let a=m(b);b.finishReasonSent=!0,b.finishReason=a;let c={id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{},finish_reason:a}]};return b.usage&&"object"==typeof b.usage&&(c.usage=b.usage),c}return null}if("error"===c||"response.failed"===c){if(b.finishReasonSent)return null;let a=d.error||d.response?.error;return a?(b.error=a,b.finishReasonSent=!0,{id:b.chatId||`chatcmpl-${Date.now()}`,object:"chat.completion.chunk",created:b.created||Math.floor(Date.now()/1e3),model:b.model||"unknown",choices:[{index:0,delta:{content:`[Error] ${a.message||JSON.stringify(a)}`},finish_reason:"stop"}]}):null}return null}(0,d.kz)(e.h.OPENAI,e.h.OPENAI_RESPONSES,null,f),(0,d.kz)(e.h.OPENAI_RESPONSES,e.h.OPENAI,null,n)},8335:(a,b,c)=>{c.r(b),c.d(b,{convertCursorToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){return a?("chat.completion.chunk"===a.object&&a.choices||"chat.completion"===a.object&&a.choices,a):null}(0,d.kz)(e.h.CURSOR,e.h.OPENAI,null,f)},11203:(a,b,c)=>{c.r(b),c.d(b,{openaiToOllamaRequest:()=>f});var d=c(26263),e=c(56790);function f(a,b,c){let d={model:a,messages:function(a){if(!Array.isArray(a))return a;let b=[],c=new Map;for(let b of a)if("assistant"===b.role&&b.tool_calls)for(let a of b.tool_calls)a.id&&a.function?.name&&c.set(a.id,a.function.name);for(let d of a){if("tool"===d.role){let a=g(d.content);if(!a)continue;let e=c.get(d.tool_call_id)||d.name||"unknown_tool";b.push({role:"tool",tool_name:e,content:a});continue}if("assistant"===d.role&&d.tool_calls){let a=g(d.content)||"",c=d.tool_calls.map(a=>({type:"function",function:{index:a.index||0,name:a.function?.name||"",arguments:"string"==typeof a.function?.arguments?JSON.parse(a.function.arguments||"{}"):a.function?.arguments||{}}}));b.push({role:"assistant",content:a,tool_calls:c});continue}let a=d.role,e=g(d.content),f=function(a){if(!Array.isArray(a))return[];let b=[];for(let c of a){if(!c||"image_url"!==c.type)continue;let a="string"==typeof c.image_url?c.image_url:c.image_url?.url;if("string"!=typeof a||!a)continue;let d=a.match(/^data:[^;]+;base64,([\s\S]+)$/);d&&b.push(d[1])}return b}(d.content);if(!e&&"assistant"!==a)continue;let h={role:a,content:e};f.length>0&&(h.images=f),b.push(h)}return b}(b.messages),stream:c};return void 0!==b.temperature&&(d.options=d.options||{},d.options.temperature=b.temperature),void 0!==b.max_tokens&&(d.options=d.options||{},d.options.num_predict=b.max_tokens),void 0!==b.top_p&&(d.options=d.options||{},d.options.top_p=b.top_p),b.tools&&Array.isArray(b.tools)&&(d.tools=b.tools),b.tool_choice&&(d.tool_choice=b.tool_choice),d}function g(a){return"string"==typeof a?a:Array.isArray(a)&&a.filter(a=>a&&"text"===a.type&&a.text).map(a=>a.text).join("\n")||""}(0,d.kz)(e.h.OPENAI,e.h.OLLAMA,f,null)},13077:(a,b,c)=>{c.d(b,{KZ:()=>i,S6:()=>f,Yr:()=>m,f6:()=>j,fc:()=>e,kU:()=>g,pT:()=>h,w_:()=>k});let d=["minLength","maxLength","exclusiveMinimum","exclusiveMaximum","pattern","minItems","maxItems","format","default","examples","$schema","$defs","definitions","const","$ref","$comment","additionalProperties","propertyNames","patternProperties","enumDescriptions","anyOf","oneOf","allOf","not","dependencies","dependentSchemas","dependentRequired","title","if","then","else","contentMediaType","contentEncoding","cornerRadius","fillColor","fontFamily","fontSize","fontWeight","gap","padding","strokeColor","strokeThickness","textColor"],e=[{category:"HARM_CATEGORY_HATE_SPEECH",threshold:"OFF"},{category:"HARM_CATEGORY_DANGEROUS_CONTENT",threshold:"OFF"},{category:"HARM_CATEGORY_SEXUALLY_EXPLICIT",threshold:"OFF"},{category:"HARM_CATEGORY_HARASSMENT",threshold:"OFF"},{category:"HARM_CATEGORY_CIVIC_INTEGRITY",threshold:"OFF"}];function f(a){let b=[];if("string"==typeof a)b.push({text:a});else if(Array.isArray(a)){for(let c of a)if("text"===c.type)b.push({text:c.text});else if("image_url"===c.type&&c.image_url?.url?.startsWith("data:")){let a=c.image_url.url,d=a.indexOf(",");if(-1!==d){let c=a.substring(5,d),e=a.substring(d+1),f=c.split(";")[0];b.push({inlineData:{mime_type:f,data:e}})}}else if("image_url"===c.type&&c.image_url?.url&&(c.image_url.url.startsWith("http://")||c.image_url.url.startsWith("https://")))b.push({fileData:{fileUri:c.image_url.url,mimeType:"image/*"}});else if("input_audio"===c.type&&c.input_audio?.data){let a=c.input_audio.format||"wav",d="mp3"===a?"audio/mpeg":`audio/${a}`;b.push({inlineData:{mime_type:d,data:c.input_audio.data}})}else if("audio_url"===c.type&&c.audio_url?.url?.startsWith("data:")){let a=c.audio_url.url,d=a.indexOf(",");if(-1!==d){let c=a.substring(5,d),e=a.substring(d+1),f=c.split(";")[0];b.push({inlineData:{mime_type:f,data:e}})}}}return b}function g(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>"text"===a.type).map(a=>a.text).join(""):""}function h(a){if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return null}}function i(){return`agent-${crypto.randomUUID()}`}function j(){return crypto.randomUUID()+Date.now().toString()}function k(){let a=["useful","bright","swift","calm","bold"],b=["fuze","wave","spark","flow","core"],c=a[Math.floor(Math.random()*a.length)],d=b[Math.floor(Math.random()*b.length)];return`${c}-${d}-${crypto.randomUUID().slice(0,5)}`}function l(a){let b=0,c=-1;for(let d=0;d<a.length;d++){let e=a[d],f=0,g=e.type;"object"===g||e.properties?f=3:"array"===g||e.items?f=2:g&&"null"!==g&&(f=1),f>c&&(c=f,b=d)}return b}function m(a){return a&&"object"==typeof a&&(!function a(b){if(b&&"object"==typeof b)for(let c of(void 0===b.const||b.enum||(b.enum=[b.const],delete b.const),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b){if(b&&"object"==typeof b)for(let c of(b.enum&&Array.isArray(b.enum)&&(b.enum=b.enum.map(a=>String(a)),b.type||(b.type="string")),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b){if(b&&"object"==typeof b){if(b.allOf&&Array.isArray(b.allOf)){let a={};for(let c of b.allOf)if(c.properties&&(a.properties||(a.properties={}),Object.assign(a.properties,c.properties)),c.required&&Array.isArray(c.required))for(let b of(a.required||(a.required=[]),c.required))a.required.includes(b)||a.required.push(b);delete b.allOf,a.properties&&(b.properties={...b.properties,...a.properties}),a.required&&(b.required=[...b.required||[],...a.required])}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b){if(b.anyOf&&Array.isArray(b.anyOf)&&b.anyOf.length>0){let a=b.anyOf.filter(a=>a&&"null"!==a.type);if(a.length>0){let c=l(a),d=a[c];delete b.anyOf,Object.assign(b,d)}}if(b.oneOf&&Array.isArray(b.oneOf)&&b.oneOf.length>0){let a=b.oneOf.filter(a=>a&&"null"!==a.type);if(a.length>0){let c=l(a),d=a[c];delete b.oneOf,Object.assign(b,d)}}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b){if(b.type&&Array.isArray(b.type)){let a=b.type.filter(a=>"null"!==a);b.type=a.length>0?a[0]:"string"}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b)for(let c of(b.properties&&!b.type&&(b.type="object"),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b,c){if(b&&"object"==typeof b){if(Array.isArray(b)){for(let d of b)a(d,c);return}for(let d of Object.keys(b)){if(c.includes(d)||d.startsWith("x-")){delete b[d];continue}let e=b[d];e&&"object"==typeof e&&a(e,c)}}}(a,d),!function a(b){if(b&&"object"==typeof b){if(b.required&&Array.isArray(b.required)&&b.properties){let a=b.required.filter(a=>Object.prototype.hasOwnProperty.call(b.properties,a));0===a.length?delete b.required:b.required=a}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b)for(let c of("object"!==b.type||b.properties&&0!==Object.keys(b.properties).length||(b.properties={reason:{type:"string",description:"Brief explanation of why you are calling this tool"}},b.required=["reason"]),Object.values(b)))c&&"object"==typeof c&&a(c)}(a)),a}},17019:(a,b,c)=>{c.r(b),c.d(b,{ollamaBodyToOpenAI:()=>i,ollamaToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a||"object"!=typeof a)return null;b.ollama||(b.ollama={id:`chatcmpl-${Date.now()}`,created:Math.floor(Date.now()/1e3),model:a.model||b.model});let{id:c,created:d,model:e}=b.ollama;if(a.done){let f=g(a),h="stop";return("tool_calls"===a.done_reason||b.hadToolCalls)&&(h="tool_calls"),{id:c,object:"chat.completion.chunk",created:d,model:e,choices:[{index:0,delta:{},finish_reason:h}],usage:f}}let f=a.message;if(!f)return null;let i="string"==typeof f.content?f.content:"",j="string"==typeof f.thinking?f.thinking:"",k=Array.isArray(f.tool_calls)?f.tool_calls:null;if(!i&&!j&&!k)return null;i&&(b.accumulatedContent=(b.accumulatedContent||"")+i),j&&(b.accumulatedThinking=(b.accumulatedThinking||"")+j);let l={};return i&&(l.content=i),j&&(l.reasoning_content=j),k&&(b.hadToolCalls=!0,l.tool_calls=h(k)),{id:c,object:"chat.completion.chunk",created:d,model:e,choices:[{index:0,delta:l,finish_reason:null}]}}function g(a){return{prompt_tokens:a.prompt_eval_count||0,completion_tokens:a.eval_count||0,total_tokens:(a.prompt_eval_count||0)+(a.eval_count||0)}}function h(a){return a.map((a,b)=>({index:a.function?.index??b,id:a.id||`call_${b}_${Date.now()}`,type:"function",function:{name:a.function?.name||"",arguments:"string"==typeof a.function?.arguments?a.function.arguments:JSON.stringify(a.function?.arguments||{})}}))}function i(a){let b=a.message||{},c=b.content||"",d=b.thinking||"",e=Array.isArray(b.tool_calls)?b.tool_calls:[],f={role:"assistant"};c&&(f.content=c),d&&(f.reasoning_content=d),e.length>0&&(f.tool_calls=h(e)),f.content||f.tool_calls||(f.content="");let i=a.done_reason||"stop";return e.length>0&&(i="tool_calls"),{id:`chatcmpl-${Date.now()}`,object:"chat.completion",created:Math.floor(Date.now()/1e3),model:a.model||"ollama",choices:[{index:0,message:f,finish_reason:i}],usage:g(a)}}(0,d.kz)(e.h.OLLAMA,e.h.OPENAI,null,f)},19171:(a,b,c)=>{c.d(b,{SZ:()=>j,Tz:()=>h,jJ:()=>i});var d=c(62276);c(98774);function e(a){return"string"==typeof a&&a.startsWith("openai-compatible-")}function f(a){return"string"==typeof a&&a.startsWith("anthropic-compatible-")}function g(a){return e(a)&&a.includes("responses")?"responses":"chat"}function h(a){if(a.input&&(Array.isArray(a.input)||"string"==typeof a.input)&&!a.messages)return"openai-responses";if(a.request?.contents&&"antigravity"===a.userAgent)return"antigravity";if(a.contents&&Array.isArray(a.contents))return"gemini";if(a.stream_options||a.response_format||void 0!==a.logprobs||void 0!==a.top_logprobs||void 0!==a.n||void 0!==a.presence_penalty||void 0!==a.frequency_penalty||a.logit_bias||a.user)return"openai";if(a.messages&&Array.isArray(a.messages)){let b=a.messages[0];if(b?.content&&Array.isArray(b.content)){let c=b.content[0];if(c?.type==="text"&&!a.model?.includes("/")){if(a.system||a.anthropic_version)return"claude";let c=b.content.some(a=>"image"===a.type&&a.source?.type==="base64"),d=b.content.some(a=>"image_url"===a.type&&a.image_url?.url);if(c)return"claude";if(d)return"openai";if(b.content.some(a=>"tool_use"===a.type||"tool_result"===a.type))return"claude"}}if(void 0!==a.system||a.anthropic_version)return"claude"}return"openai"}function i(a){return e(a)?"responses"===g(a)?"openai-responses":"openai":f(a)?"claude":function(a){if(e(a)){let b=g(a);return{...d.xq.openai,format:"responses"===b?"openai-responses":"openai",baseUrl:"https://api.openai.com/v1"}}return f(a)?{...d.xq.anthropic,format:"claude",baseUrl:"https://api.anthropic.com/v1"}:d.xq[a]||d.xq.openai}(a).format||"openai"}function j(a){return!function(a){let b=a.messages||a.contents;if(!b?.length)return!0;let c=b[b.length-1];return c?.role==="user"}(a)&&(delete a.reasoning_effort,delete a.thinking),a}},19312:(a,b,c)=>{c.d(b,{M:()=>e});var d=c(23016);function e(a){let b=a.max_tokens||d.Uc;return a.tools&&Array.isArray(a.tools)&&a.tools.length>0&&b<d.eo&&(b=d.eo),a.thinking?.budget_tokens&&b<=a.thinking.budget_tokens&&(b=a.thinking.budget_tokens+1024),b}},19999:(a,b,c)=>{c.r(b),c.d(b,{openaiToVertexRequest:()=>h});var d=c(26263),e=c(56790),f=c(78178),g=c(52589);function h(a,b,c,d){var e=(0,f.openaiToGeminiRequest)(a,b,c,d);if(!e?.contents)return e;for(let a of e.contents)if(Array.isArray(a.parts))for(let b of a.parts)void 0!==b.thoughtSignature&&(b.thoughtSignature=g.n6),b.functionCall&&"id"in b.functionCall&&delete b.functionCall.id,b.functionResponse&&"id"in b.functionResponse&&delete b.functionResponse.id;return e}(0,d.kz)(e.h.OPENAI,e.h.VERTEX,h,null)},20362:(a,b,c)=>{c.d(b,{RF:()=>i});var d=c(55511),e=c.n(d),f=c(23016);let g=new Map,h=setInterval(()=>{let a=Date.now();for(let[b,c]of g)a-c.lastUsed>f.v1.sessionTtlMs&&g.delete(b)},f.v1.sessionCleanupIntervalMs);function i(a){if(!a)return j();let b=g.get(a);if(b)return b.lastUsed=Date.now(),b.sessionId;if(g.size>=1e3){let a=g.keys().next().value;g.delete(a)}let c=j();return g.set(a,{sessionId:c,lastUsed:Date.now()}),c}function j(){return e().randomUUID()+Date.now().toString()}h.unref&&h.unref()},24353:(a,b,c)=>{c.d(b,{H:()=>f});var d=c(23016),e=c(37973);class f{constructor(a,b){this.provider=a,this.config=b,this.noAuth=b?.noAuth||!1}getProvider(){return this.provider}getBaseUrls(){return this.config.baseUrls||(this.config.baseUrl?[this.config.baseUrl]:[])}getFallbackCount(){return this.getBaseUrls().length||1}buildUrl(a,b,c=0,d=null){if(this.provider?.startsWith?.("openai-compatible-")){let a=(d?.providerSpecificData?.baseUrl||"https://api.openai.com/v1").replace(/\/$/,""),b=this.provider.includes("responses")?"/responses":"/chat/completions";return`${a}${b}`}if(this.provider?.startsWith?.("anthropic-compatible-")){let a=(d?.providerSpecificData?.baseUrl||"https://api.anthropic.com/v1").replace(/\/$/,"");return`${a}/messages`}let e=this.getBaseUrls();return e[c]||e[0]||this.config.baseUrl}buildHeaders(a,b=!0){let c={"Content-Type":"application/json",...this.config.headers};return this.provider?.startsWith?.("anthropic-compatible-")?(a.apiKey?c["x-api-key"]=a.apiKey:a.accessToken&&(c.Authorization=`Bearer ${a.accessToken}`),c["anthropic-version"]||(c["anthropic-version"]="2023-06-01")):a.accessToken?c.Authorization=`Bearer ${a.accessToken}`:a.apiKey&&(c.Authorization=`Bearer ${a.apiKey}`),b&&(c.Accept="text/event-stream"),c}transformRequest(a,b,c,d){return b}shouldRetry(a,b){return a===d.gx.RATE_LIMITED&&b+1<this.getFallbackCount()}async refreshCredentials(a,b,c=null){return null}needsRefresh(a){return!!a.expiresAt&&new Date(a.expiresAt).getTime()-Date.now()<3e5}parseError(a,b){return{status:a.status,message:b||`HTTP ${a.status}`}}async execute({model:a,body:b,stream:c,credentials:f,signal:g,log:h,proxyOptions:i=null}){let j=this.getFallbackCount(),k=null,l=0,m={},n={...d.cI,...this.config.retry},o=async(a,b,c)=>{let{attempts:e,delayMs:f}=(0,d.DR)(n[b]);return!(e<=0)&&!(m[a]>=e)&&(m[a]++,h?.debug?.("RETRY",`${c} retry ${m[a]}/${e} after ${f/1e3}s`),await new Promise(a=>setTimeout(a,f)),!0)};for(let n=0;n<j;n++){let p=this.buildUrl(a,c,n,f),q=this.transformRequest(a,b,c,f),r=this.buildHeaders(f,c);m[n]||(m[n]=0);try{let a=await (0,e.proxyAwareFetch)(p,{method:"POST",headers:r,body:JSON.stringify(q),signal:g},i);if(await o(n,a.status,`status ${a.status}`)){n--;continue}if(this.shouldRetry(a.status,n)){h?.debug?.("RETRY",`${a.status} on ${p}, trying fallback ${n+1}`),l=a.status;continue}return{response:a,url:p,headers:r,transformedBody:q}}catch(a){if(k=a,"AbortError"===a.name)throw a;if(await o(n,d.gx.BAD_GATEWAY,`network "${a.message}"`)){n--;continue}if(n+1<j){h?.debug?.("RETRY",`Error on ${p}, trying fallback ${n+1}`);continue}throw a}}throw k||Error(`All ${j} URLs failed with status ${l}`)}}},26263:(a,b,c)=>{c.d(b,{Ws:()=>v,Ai:()=>w,nZ:()=>u,kz:()=>q,GH:()=>s,Y8:()=>t});var d=c(56790);let e=/^[a-zA-Z0-9_-]+$/;function f(a=0,b=0,c=""){let d=c?`_${c.replace(/[^a-zA-Z0-9_-]/g,"")}`:"";return`call_msg${a}_tc${b}${d}`}function g(a){if(!a||"string"!=typeof a)return null;let b=a.replace(/[^a-zA-Z0-9_-]/g,"");return b.length>0?b:null}var h=c(52589);c(19312);var i=c(96771),j=c(20362);let k=new Set(["minimax","minimax-cn"]),l=["text","image_url","image","input_audio","audio_url"];var m=c(19171);c(1820);let n=new Map,o=new Map,p=!1;function q(a,b,c,d){let e=`${a}:${b}`;c&&n.set(e,c),d&&o.set(e,d)}function r(){p||(p=!0,c(95579),c(39359),c(32178),c(78178),c(19999),c(44901),c(77021),c(85917),c(38911),c(11203),c(33465),c(76839),c(66299),c(45070),c(63151),c(1950),c(29202),c(8335),c(17019),c(80319))}function s(a,b,c,o,p=!0,q=null,t=null,u=null,v=[],w=null,x=null){r();let y=o;if(!function(a,b=[]){if(!b.length||!a.messages||!Array.isArray(a.messages))return;let c=new Set(["image_url","image"]),d=new Set(["audio_url","input_audio"]),e=a=>c.has(a)?b.includes("image"):!!d.has(a)&&b.includes("audio");for(let b of a.messages)Array.isArray(b.content)&&(b.content=b.content.filter(a=>!e(a.type)),0===b.content.length&&(b.content=""))}(y,v),(0,m.SZ)(y),!function(a){if(a.messages&&Array.isArray(a.messages))for(let b=0;b<a.messages.length;b++){let c=a.messages[b];if("assistant"===c.role&&c.tool_calls&&Array.isArray(c.tool_calls))for(let a=0;a<c.tool_calls.length;a++){let d=c.tool_calls[a];if(!d.id||!e.test(d.id)){let c=g(d.id);d.id=c||f(b,a,d.function?.name)}d.type||(d.type="function"),d.function?.arguments&&"string"!=typeof d.function.arguments&&(d.function.arguments=JSON.stringify(d.function.arguments))}if("tool"===c.role&&c.tool_call_id&&!e.test(c.tool_call_id)){let a=g(c.tool_call_id);c.tool_call_id=a||f(b,0)}if(Array.isArray(c.content))for(let a=0;a<c.content.length;a++){let d=c.content[a];if("tool_use"===d.type&&d.id&&!e.test(d.id)){let c=g(d.id);d.id=c||f(b,a,d.name)}if("tool_result"===d.type&&d.tool_use_id&&!e.test(d.tool_use_id)){let c=g(d.tool_use_id);d.tool_use_id=c||f(b,a)}}}}(y),!function(a){if(!a.messages||!Array.isArray(a.messages))return;let b=[];for(let c=0;c<a.messages.length;c++){let d=a.messages[c],e=a.messages[c+1];b.push(d);let f=function(a){if("assistant"!==a.role)return[];let b=[];if(a.tool_calls&&Array.isArray(a.tool_calls))for(let c of a.tool_calls)c.id&&b.push(c.id);if(Array.isArray(a.content))for(let c of a.content)"tool_use"===c.type&&c.id&&b.push(c.id);return b}(d);if(0!==f.length&&e&&!function(a,b){if(!a||!b.length)return!1;if("tool"===a.role&&a.tool_call_id)return b.includes(a.tool_call_id);if("user"===a.role&&Array.isArray(a.content)){for(let c of a.content)if("tool_result"===c.type&&b.includes(c.tool_use_id))return!0}return!1}(e,f))for(let a of f)b.push({role:"tool",tool_call_id:a,content:""})}a.messages=b}(y),a!==b){if(a!==d.h.OPENAI){let b=n.get(`${a}:${d.h.OPENAI}`);b&&(y=b(c,y,p,q),u?.logOpenAIRequest?.(y))}if(b!==d.h.OPENAI){let a=n.get(`${d.h.OPENAI}:${b}`);a&&(y=a(c,y,p,q))}}if(b===d.h.OPENAI&&(y=function(a){if(!a.messages||!Array.isArray(a.messages))return a;if(a.messages=a.messages.map(a=>{if("developer"===a.role&&(a={...a,role:"system"}),"tool"===a.role||"assistant"===a.role&&a.tool_calls||"string"==typeof a.content)return a;if(Array.isArray(a.content)){let b=[];for(let c of a.content)if("thinking"!==c.type&&"redacted_thinking"!==c.type){if(l.includes(c.type)){let{signature:a,cache_control:d,...e}=c;b.push(e)}else if("tool_use"===c.type)continue;else if("tool_result"===c.type){let{signature:a,cache_control:d,...e}=c;b.push(e)}}return 0===b.length&&b.push({type:"text",text:""}),{...a,content:b}}return a}),a.messages=a.messages.filter(a=>"tool"===a.role||"assistant"===a.role&&!!a.tool_calls||("string"==typeof a.content?""!==a.content.trim():!Array.isArray(a.content)||a.content.some(a=>"text"===a.type&&a.text?.trim()||"text"!==a.type))),a.tools&&Array.isArray(a.tools)&&0===a.tools.length&&delete a.tools,a.tools&&Array.isArray(a.tools)&&a.tools.length>0&&(a.tools=a.tools.map(a=>"function"===a.type&&a.function?a:a.name&&(a.input_schema||a.description)?{type:"function",function:{name:a.name,description:String(a.description||""),parameters:a.input_schema||{type:"object",properties:{}}}}:a.functionDeclarations&&Array.isArray(a.functionDeclarations)?a.functionDeclarations.map(a=>({type:"function",function:{name:a.name,description:String(a.description||""),parameters:a.parameters||{type:"object",properties:{}}}})):a).flat()),a.tool_choice&&"object"==typeof a.tool_choice){let b=a.tool_choice;"auto"===b.type?a.tool_choice="auto":"any"===b.type?a.tool_choice="required":"tool"===b.type&&b.name&&(a.tool_choice={type:"function",function:{name:b.name}})}return a}(y)),b===d.h.CLAUDE&&(y=function(a,b=null,c=null,d=null){if(k.has(b)&&delete a.output_config,a.system&&Array.isArray(a.system)&&(a.system=a.system.map((b,c)=>{let{cache_control:d,...e}=b;return c===a.system.length-1?{...e,cache_control:{type:"ephemeral",ttl:"1h"}}:e})),a.messages&&Array.isArray(a.messages)){let c=a.messages.length,d=[];for(let b=0;b<c;b++){let e=a.messages[b];if(Array.isArray(e.content))for(let a of e.content)delete a.cache_control;(b===c-1&&"assistant"===e.role||"string"==typeof e.content&&e.content.trim()||Array.isArray(e.content)&&e.content.some(a=>"text"===a.type&&a.text?.trim()||"tool_use"===a.type||"tool_result"===a.type))&&d.push(e)}d=function(a){if(a.length<=1)return a;for(let b of a)if("assistant"===b.role&&Array.isArray(b.content)&&b.content.some(a=>"tool_use"===a.type)){let a=[],c=!1;for(let d of b.content)"tool_use"===d.type?(c=!0,a.push(d)):"thinking"===d.type||"redacted_thinking"===d.type?a.push(d):c||a.push(d);b.content=a}let b=[];for(let c of a){let a=b[b.length-1];if(a&&a.role===c.role){let b=Array.isArray(a.content)?a.content:[{type:"text",text:a.content}],d=Array.isArray(c.content)?c.content:[{type:"text",text:c.content}];a.content=[...b.filter(a=>"tool_result"===a.type),...d.filter(a=>"tool_result"===a.type),...b.filter(a=>"tool_result"!==a.type),...d.filter(a=>"tool_result"!==a.type)]}else{let a=Array.isArray(c.content)?c.content:[{type:"text",text:c.content}];b.push({role:c.role,content:[...a]})}}return b}(d),a.messages=d;let e=d[d.length-1],f=e?.role==="user",g=a.thinking?.type==="enabled"&&f,i=!1;for(let a=d.length-1;a>=0;a--){let c=d[a];if("assistant"===c.role&&Array.isArray(c.content)){if(!i&&c.content.length>0){for(let a=c.content.length-1;a>=0;a--){let b=c.content[a];if("thinking"!==b.type&&"redacted_thinking"!==b.type){b.cache_control={type:"ephemeral"};break}}i=!0}if("claude"===b||b?.startsWith("anthropic-compatible")){let a=!1,b=!1;for(let d of c.content)("thinking"===d.type||"redacted_thinking"===d.type)&&(d.signature=h.xr,b=!0),"tool_use"===d.type&&(a=!0);g&&!b&&a&&c.content.unshift({type:"thinking",thinking:".",signature:h.xr})}}}}if(a.tools&&Array.isArray(a.tools)&&("claude"!==b&&(a.tools=a.tools.filter(a=>!a.type||"function"===a.type)),a.tools=a.tools.map((b,c)=>{let{cache_control:d,...e}=b;return c===a.tools.length-1?{...e,cache_control:{type:"ephemeral",ttl:"1h"}}:e}),0===a.tools.length&&(delete a.tools,delete a.tool_choice)),("claude"===b||b?.startsWith("anthropic-compatible"))&&c){let b=d?(0,j.RF)(d):null;a=(0,i.fO)(a,c,b)}return a}(y,t,q?.accessToken||q?.apiKey||null,w)),"claude"===t){let a=q?.accessToken||q?.apiKey||null;if(a?.includes("sk-ant-oat")){let{body:a,toolNameMap:b}=(0,i.Az)(y);y=a,b?.size>0&&(y._toolNameMap=b)}}return y}function t(a,b,c,e){if(r(),b===a)return[c];let f=[c],g=null;if(a!==d.h.OPENAI){let b=o.get(`${a}:${d.h.OPENAI}`);if(b){f=[];let a=b(c,e);a&&(g=f=Array.isArray(a)?a:[a])}}if(b!==d.h.OPENAI){let a=o.get(`${d.h.OPENAI}:${b}`);if(a){let b=[];for(let c of f){let d=a(c,e);d&&b.push(...Array.isArray(d)?d:[d])}f=b}}return g&&b!==d.h.OPENAI&&a!==d.h.OPENAI&&(f._openaiIntermediate=g),f}function u(a,b){return a!==b}function v(a){let b={messageId:null,model:null,textBlockStarted:!1,thinkingBlockStarted:!1,inThinkingBlock:!1,currentBlockIndex:null,toolCalls:new Map,finishReason:null,finishReasonSent:!1,usage:null,contentBlockIndex:-1};return a===d.h.OPENAI_RESPONSES?{...b,seq:0,responseId:`resp_${Date.now()}`,created:Math.floor(Date.now()/1e3),started:!1,msgTextBuf:{},msgItemAdded:{},msgContentAdded:{},msgItemDone:{},reasoningId:"",reasoningIndex:-1,reasoningBuf:"",reasoningPartAdded:!1,reasoningDone:!1,inThinking:!1,funcArgsBuf:{},funcNames:{},funcCallIds:{},funcArgsDone:{},funcItemDone:{},completedSent:!1}:b}function w(){r()}},29202:(a,b,c)=>{c.r(b),c.d(b,{convertKiroToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;if("chat.completion.chunk"===a.object&&a.choices)return a;let c=a;if("string"==typeof a){let b=a.split("\n"),d="",e="";for(let a of b)a.startsWith("event:")?d=a.slice(6).trim():a.startsWith(":event-type:")?d=a.slice(12).trim():a.startsWith("data:")?e=a.slice(5).trim():a.startsWith(":content-type:")||a.trim()&&!a.startsWith(":")&&(e=a.trim());if(!e)return null;try{(c=JSON.parse(e))._eventType=d}catch{c={text:e,_eventType:d}}}b.responseId||(b.responseId=`chatcmpl-${Date.now()}`,b.created=Math.floor(Date.now()/1e3),b.chunkIndex=0);let d=c._eventType||c.event||"";if("assistantResponseEvent"===d||c.assistantResponseEvent){let a=c.assistantResponseEvent?.content||c.content||"";if(!a)return null;let d={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},content:a},finish_reason:null}]};return b.chunkIndex++,d}if("reasoningContentEvent"===d||c.reasoningContentEvent){let a=c.reasoningContentEvent||c,d="string"==typeof a?a:a.text||a.content||c.content||"";if(!d)return null;let e={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},reasoning_content:d},finish_reason:null}]};return b.chunkIndex++,e}if("toolUseEvent"===d||c.toolUseEvent){let a=c.toolUseEvent||c,d=a.toolUseId||`call_${Date.now()}`,e=a.name||"",f=a.input||{},g={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},tool_calls:[{index:0,id:d,type:"function",function:{name:e,arguments:JSON.stringify(f)}}]},finish_reason:null}]};return b.chunkIndex++,g}if("messageStopEvent"===d||"done"===d||c.messageStopEvent){b.finishReason="stop";let a={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{},finish_reason:"stop"}]};return b.usage&&"object"==typeof b.usage&&(a.usage=b.usage),a}if("usageEvent"===d||c.usageEvent){let a=c.usageEvent||c;a&&"object"==typeof a&&(b.usage={prompt_tokens:a.inputTokens||0,completion_tokens:a.outputTokens||0,total_tokens:(a.inputTokens||0)+(a.outputTokens||0)})}return null}(0,d.kz)(e.h.KIRO,e.h.OPENAI,null,f)},32178:(a,b,c)=>{c.r(b),c.d(b,{geminiToOpenAIRequest:()=>g});var d=c(26263),e=c(56790),f=c(19312);function g(a,b,c){let d={model:a,messages:[],stream:c};if(b.generationConfig){let a=b.generationConfig;if(a.maxOutputTokens){let c={max_tokens:a.maxOutputTokens,tools:b.tools};d.max_tokens=(0,f.M)(c)}void 0!==a.temperature&&(d.temperature=a.temperature),void 0!==a.topP&&(d.top_p=a.topP)}if(b.systemInstruction){var e;let a="string"==typeof(e=b.systemInstruction)?e:e.parts&&Array.isArray(e.parts)?e.parts.map(a=>a.text||"").join(""):"";a&&d.messages.push({role:"system",content:a})}if(b.contents&&Array.isArray(b.contents))for(let a of b.contents){let b=function(a){let b="user"===a.role?"user":"assistant";if(!a.parts||!Array.isArray(a.parts))return null;let c=[],d=[];for(let b of a.parts)if(void 0!==b.text&&c.push({type:"text",text:b.text}),b.inlineData&&c.push({type:"image_url",image_url:{url:`data:${b.inlineData.mimeType};base64,${b.inlineData.data}`}}),b.functionCall&&d.push({id:`call_${Date.now()}_${Math.random().toString(36).slice(2,8)}`,type:"function",function:{name:b.functionCall.name,arguments:JSON.stringify(b.functionCall.args||{})}}),b.functionResponse)return{role:"tool",tool_call_id:b.functionResponse.id||b.functionResponse.name,content:JSON.stringify(b.functionResponse.response?.result||b.functionResponse.response||{})};if(d.length>0){let a={role:"assistant"};return c.length>0&&(a.content=1===c.length?c[0].text:c),a.tool_calls=d,a}return c.length>0?{role:b,content:1===c.length&&"text"===c[0].type?c[0].text:c}:null}(a);b&&d.messages.push(b)}if(b.tools&&Array.isArray(b.tools)){for(let a of(d.tools=[],b.tools))if(a.functionDeclarations)for(let b of a.functionDeclarations)d.tools.push({type:"function",function:{name:b.name,description:b.description||"",parameters:b.parameters||{type:"object",properties:{}}}})}return d}(0,d.kz)(e.h.GEMINI,e.h.OPENAI,g,null),(0,d.kz)(e.h.GEMINI_CLI,e.h.OPENAI,g,null)},33465:(a,b,c)=>{c.r(b),c.d(b,{openaiToCommandCode:()=>h});var d=c(26263),e=c(56790),f=c(55511);function g(a){if(null==a)return"";if("string"==typeof a)return a;if(Array.isArray(a)){let b=[];for(let c of a)"string"==typeof c?b.push(c):c&&"object"==typeof c&&"string"==typeof c.text&&b.push(c.text);return b.join("\n")}return String(a)}function h(a,b,c){let{messages:d,system:e}=function(a=[]){let b=[],c=[];for(let d of a){if(!d)continue;let a=d.role;if("system"===a){let a=g(d.content);a&&c.push(a);continue}if("tool"===a){let a="string"==typeof d.content?d.content:g(d.content);b.push({role:"tool",content:[{type:"tool-result",toolCallId:d.tool_call_id||"",toolName:d.name||"",output:{type:"text",value:a}}]});continue}if("assistant"===a){let a=[],c=g(d.content);if(c&&a.push({type:"text",text:c}),Array.isArray(d.tool_calls))for(let b of d.tool_calls){let c=b.function||{};a.push({type:"tool-call",toolCallId:b.id||"",toolName:c.name||"",input:function(a){if(null==a)return{};if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return{}}}(c.arguments)})}b.push({role:"assistant",content:a.length?a:[{type:"text",text:""}]});continue}b.push({role:"user",content:function(a){if(null==a)return[{type:"text",text:""}];if("string"==typeof a)return[{type:"text",text:a}];if(Array.isArray(a)){let b=[];for(let c of a)"string"==typeof c?b.push({type:"text",text:c}):c&&"object"==typeof c&&("text"===c.type&&"string"==typeof c.text?b.push({type:"text",text:c.text}):"image_url"===c.type||"image"===c.type?b.push({type:"text",text:"[image omitted]"}):"string"==typeof c.text&&b.push({type:"text",text:c.text}));return b.length?b:[{type:"text",text:""}]}return[{type:"text",text:String(a)}]}(d.content)})}return{messages:b,system:c.join("\n\n")}}(b.messages),h={model:a,messages:d,stream:!1!==c,max_tokens:b.max_tokens??b.max_output_tokens??64e3,temperature:b.temperature??.3};e&&(h.system=e);let i=function(a){if(!Array.isArray(a)||0===a.length)return;let b=[];for(let c of a)c&&("function"===c.type&&c.function?b.push({name:c.function.name,description:c.function.description,input_schema:c.function.parameters||{type:"object"}}):c.name&&(c.input_schema||c.parameters)&&b.push({name:c.name,description:c.description,input_schema:c.input_schema||c.parameters}));return b.length?b:void 0}(b.tools);i&&(h.tools=i),null!=b.top_p&&(h.top_p=b.top_p);let j=new Date().toISOString().slice(0,10);return{threadId:(0,f.randomUUID)(),memory:"",config:{workingDir:process.cwd(),date:j,environment:process.platform,structure:[],isGitRepo:!1,currentBranch:"",mainBranch:"",gitStatus:"",recentCommits:[]},params:h}}(0,d.kz)(e.h.OPENAI,e.h.COMMANDCODE,h,null)},38911:(a,b,c)=>{c.r(b),c.d(b,{buildCursorRequest:()=>j});var d=c(26263),e=c(56790);function f(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>!!a&&"object"==typeof a&&"text"===a.type&&"string"==typeof a.text).map(a=>a.text||"").join(""):""}function g(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function h(a,b,c){let d=(c||"").replace(/[\u0000-\u0008\u000B\u000C\u000E-\u001F\u007F]/g,"");return`<tool_result>
1
+ "use strict";exports.id=6263,exports.ids=[6263],exports.modules={1820:(a,b,c)=>{c.d(b,{c:()=>m});var d=c(55511),e=c.n(d),f=c(24353),g=c(62276),h=c(43528),i=c(23016),j=c(20362),k=c(37973),l=c(13077);class m extends f.H{constructor(){super("antigravity",g.xq.antigravity)}buildUrl(a,b,c=0){let d=this.getBaseUrls(),e=d[c]||d[0];return`${e}/v1internal:${b?"streamGenerateContent?alt=sse":"generateContent"}`}buildHeaders(a,b=!0,c=null){return{"Content-Type":"application/json",Authorization:`Bearer ${a.accessToken}`,"User-Agent":this.config.headers?.["User-Agent"]||h.K["User-Agent"],[h.Ox.name]:h.Ox.value,...c&&{"X-Machine-Session-Id":c},Accept:b?"text/event-stream":"application/json"}}transformRequest(a,b,c,d){let f=d?.projectId||this.generateProjectId(),g=b.request?.contents?.map(a=>{let b=a.role;a.parts?.some(a=>a.functionResponse)&&(b="user");let c=a.parts?.filter(a=>(!a.thought||!!a.functionCall)&&(!a.thoughtSignature||!!a.functionCall||!!a.text));return b!==a.role||c?.length!==a.parts?.length?{...a,role:b,parts:c}:a}),h=b.request?.tools;if(h&&h.length>0){let a=h.flatMap(a=>(a.functionDeclarations||[]).map(a=>({...a,name:function(a){if(!a)return"_unknown";let b=a.replace(/[^a-zA-Z0-9_.:\-]/g,"_");return/^[a-zA-Z_]/.test(b)||(b="_"+b),b.substring(0,64)}(a.name),parameters:a.parameters?(0,l.Yr)(structuredClone(a.parameters)):{type:"object",properties:{reason:{type:"string",description:"Brief explanation"}},required:["reason"]}})));h=a.length>0?[{functionDeclarations:a}]:[]}let{tools:i,toolConfig:k,...m}=b.request||{},n={...m.generationConfig||{}};n.maxOutputTokens>16384&&(n.maxOutputTokens=16384);let o={...m,generationConfig:n,...g&&{contents:g},...h&&{tools:h},sessionId:b.request?.sessionId||(0,j.RF)(d?.email||d?.connectionId),safetySettings:void 0,...h?.length>0&&{toolConfig:{functionCallingConfig:{mode:"VALIDATED"}}}};return{...b,project:f,model:a,userAgent:"antigravity",requestType:"agent",requestId:`agent-${e().randomUUID()}`,request:o}}async refreshCredentials(a,b,c=null){if(!a.refreshToken)return null;try{let d=await (0,k.proxyAwareFetch)(h.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a.refreshToken,client_id:this.config.clientId,client_secret:this.config.clientSecret})},c);if(!d.ok)return null;let e=await d.json();return b?.info?.("TOKEN","Antigravity refreshed"),{accessToken:e.access_token,refreshToken:e.refresh_token||a.refreshToken,expiresIn:e.expires_in,projectId:a.projectId}}catch(a){return b?.error?.("TOKEN",`Antigravity refresh error: ${a.message}`),null}}generateProjectId(){let a=["useful","bright","swift","calm","bold"][Math.floor(5*Math.random())],b=["fuze","wave","spark","flow","core"][Math.floor(5*Math.random())];return`${a}-${b}-${e().randomUUID().slice(0,5)}`}generateSessionId(){return e().randomUUID()+Date.now().toString()}parseRetryHeaders(a){if(!a?.get)return null;let b=a.get("retry-after");if(b){let a=parseInt(b,10);if(!isNaN(a)&&a>0)return 1e3*a;let c=new Date(b);if(!isNaN(c.getTime())){let a=c.getTime()-Date.now();return a>0?a:null}}let c=a.get("x-ratelimit-reset-after");if(c){let a=parseInt(c,10);if(!isNaN(a)&&a>0)return 1e3*a}let d=a.get("x-ratelimit-reset");if(d){let a=1e3*parseInt(d,10)-Date.now();return a>0?a:null}return null}parseRetryFromErrorMessage(a){if(!a||"string"!=typeof a)return null;let b=a.match(/reset after (\d+h)?(\d+m)?(\d+s)?/i);if(!b)return null;let c=0;return b[1]&&(c+=3600*parseInt(b[1])*1e3),b[2]&&(c+=60*parseInt(b[2])*1e3),b[3]&&(c+=1e3*parseInt(b[3])),c>0?c:null}async execute({model:a,body:b,stream:c,credentials:d,signal:e,log:f,proxyOptions:g=null}){let h=this.getFallbackCount(),j=null,l=0,m={},n={};for(let o=0;o<h;o++){let p=this.buildUrl(a,c,o),q=this.transformRequest(a,b,c,d),r=q.request?.sessionId,s=this.buildHeaders(d,c,r);m[o]||(m[o]=0),n[o]||(n[o]=0);try{let a=await (0,k.proxyAwareFetch)(p,{method:"POST",headers:s,body:JSON.stringify(q),signal:e},g);if(a.status===i.gx.RATE_LIMITED||a.status===i.gx.SERVICE_UNAVAILABLE){let b=this.parseRetryHeaders(a.headers);if(!b)try{let c=await a.clone().text(),d=JSON.parse(c),e=d?.error?.message||d?.message||"";b=this.parseRetryFromErrorMessage(e)}catch(a){}if(b&&b<=1e4&&n[o]<3){n[o]++,f?.debug?.("RETRY",`${a.status} with Retry-After: ${Math.ceil(b/1e3)}s, waiting... (${n[o]}/3)`),await new Promise(a=>setTimeout(a,b)),o--;continue}if(a.status===i.gx.RATE_LIMITED&&(!b||0===b)&&m[o]<3){m[o]++;let a=Math.min(1e3*2**m[o],1e4);f?.debug?.("RETRY",`429 auto retry ${m[o]}/3 after ${a/1e3}s`),await new Promise(b=>setTimeout(b,a)),o--;continue}if(f?.debug?.("RETRY",`${a.status}, Retry-After ${b?`too long (${Math.ceil(b/1e3)}s)`:"missing"}, trying fallback`),l=a.status,o+1<h)continue}if(this.shouldRetry(a.status,o)){f?.debug?.("RETRY",`${a.status} on ${p}, trying fallback ${o+1}`),l=a.status;continue}return{response:a,url:p,headers:s,transformedBody:q}}catch(a){if(j=a,o+1<h){f?.debug?.("RETRY",`Error on ${p}, trying fallback ${o+1}`);continue}throw a}}throw j||Error(`All ${h} URLs failed with status ${l}`)}static cloakTools(a,b=null){let c=a.request?.tools;if(!c||0===c.length)return{cloakedBody:a,toolNameMap:null};let d="github-copilot"===b,e=new Map,f=[],g=new Set(n.map(a=>a.name));for(let a of c)if(a.functionDeclarations)for(let b of a.functionDeclarations){if(d&&h.J5.has(b.name)||d&&g.has(b.name))continue;if(h.J5.has(b.name)){f.push(b);continue}let a=`${b.name}${h.QH}`;e.set(a,b.name),f.push({...b,name:a})}let i=[],j=new Set;for(let a of[...f,...n])!a?.name||j.has(a.name)||(j.add(a.name),i.push(a));let k=a.request?.contents?.map(a=>{if(!a.parts)return a;let b=a.parts.map(a=>a.functionCall&&!h.J5.has(a.functionCall.name)?{...a,functionCall:{...a.functionCall,name:`${a.functionCall.name}${h.QH}`}}:a.functionResponse&&!h.J5.has(a.functionResponse.name)?{...a,functionResponse:{...a.functionResponse,name:`${a.functionResponse.name}${h.QH}`}}:a);return{...a,parts:b}});return{cloakedBody:{...a,request:{...a.request,tools:[{functionDeclarations:i}],contents:k||a.request.contents}},toolNameMap:e}}}let n=[{name:"browser_subagent",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"command_status",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"find_by_name",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"generate_image",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"grep_search",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"list_dir",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"list_resources",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"mcp_sequential-thinking_sequentialthinking",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"multi_replace_file_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"notify_user",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_resource",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_terminal",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"read_url_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"replace_file_content",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"run_command",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"search_web",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"send_command_input",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"task_boundary",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"view_content_chunk",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"view_file",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}},{name:"write_to_file",description:"This tool is currently unavailable.",parameters:{type:"OBJECT",properties:{},required:[]}}]},1950:(a,b,c)=>{c.r(b),c.d(b,{openaiResponsesToOpenAIResponse:()=>n,openaiToOpenAIResponsesResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a){var c=b;if(c.completedSent)return[];let a=[],d=(b,d)=>{d.sequence_number=++c.seq,a.push({event:b,data:d})};for(let a in c.msgItemAdded)j(c,d,a);for(let a in i(c,d),c.funcCallIds)k(c,d,a);return l(c,d),a}if(!a.choices?.length)return[];let d=[],e=(a,c)=>{c.sequence_number=++b.seq,d.push({event:a,data:c})},f=a.choices[0],m=f.index||0,n=f.delta||{};if(b.started||(b.started=!0,b.responseId=a.id?`resp_${a.id}`:b.responseId,e("response.created",{type:"response.created",response:{id:b.responseId,object:"response",created_at:b.created,status:"in_progress",background:!1,error:null,output:[]}}),e("response.in_progress",{type:"response.in_progress",response:{id:b.responseId,object:"response",created_at:b.created,status:"in_progress"}})),n.reasoning_content&&(g(b,e,m),h(b,e,n.reasoning_content)),n.content){let a=n.content;if(a.includes("<think>")&&(b.inThinking=!0,a=a.replace("<think>",""),g(b,e,m)),a.includes("</think>")){let c=a.split("</think>"),d=c[0],f=c.slice(1).join("</think>");d&&h(b,e,d),i(b,e),b.inThinking=!1,a=f}if(b.inThinking&&a)return h(b,e,a),d;a&&function(a,b,c,d){if(!a.msgItemAdded[c]){a.msgItemAdded[c]=!0;let d=`msg_${a.responseId}_${c}`;b("response.output_item.added",{type:"response.output_item.added",output_index:c,item:{id:d,type:"message",content:[],role:"assistant"}})}a.msgContentAdded[c]||(a.msgContentAdded[c]=!0,b("response.content_part.added",{type:"response.content_part.added",item_id:`msg_${a.responseId}_${c}`,output_index:c,content_index:0,part:{type:"output_text",annotations:[],logprobs:[],text:""}})),b("response.output_text.delta",{type:"response.output_text.delta",item_id:`msg_${a.responseId}_${c}`,output_index:c,content_index:0,delta:d,logprobs:[]}),a.msgTextBuf[c]||(a.msgTextBuf[c]=""),a.msgTextBuf[c]+=d}(b,e,m,a)}if(n.tool_calls)for(let a of(j(b,e,m),n.tool_calls))!function(a,b,c){let d=c.index??0,e=c.id,f=c.function?.name;if(f&&(a.funcNames[d]=f),!a.funcCallIds[d]&&e&&(a.funcCallIds[d]=e,b("response.output_item.added",{type:"response.output_item.added",output_index:d,item:{id:`fc_${e}`,type:"function_call",arguments:"",call_id:e,name:a.funcNames[d]||""}})),a.funcArgsBuf[d]||(a.funcArgsBuf[d]=""),c.function?.arguments){let f=a.funcCallIds[d]||e;f&&b("response.function_call_arguments.delta",{type:"response.function_call_arguments.delta",item_id:`fc_${f}`,output_index:d,delta:c.function.arguments}),a.funcArgsBuf[d]+=c.function.arguments}}(b,e,a);if(f.finish_reason){for(let a in b.msgItemAdded)j(b,e,a);for(let a in i(b,e),b.funcCallIds)k(b,e,a);l(b,e)}return d}function g(a,b,c){a.reasoningId||(a.reasoningId=`rs_${a.responseId}_${c}`,a.reasoningIndex=c,b("response.output_item.added",{type:"response.output_item.added",output_index:c,item:{id:a.reasoningId,type:"reasoning",summary:[]}}),b("response.reasoning_summary_part.added",{type:"response.reasoning_summary_part.added",item_id:a.reasoningId,output_index:c,summary_index:0,part:{type:"summary_text",text:""}}),a.reasoningPartAdded=!0)}function h(a,b,c){c&&(a.reasoningBuf+=c,b("response.reasoning_summary_text.delta",{type:"response.reasoning_summary_text.delta",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,delta:c}))}function i(a,b){a.reasoningId&&!a.reasoningDone&&(a.reasoningDone=!0,b("response.reasoning_summary_text.done",{type:"response.reasoning_summary_text.done",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,text:a.reasoningBuf}),b("response.reasoning_summary_part.done",{type:"response.reasoning_summary_part.done",item_id:a.reasoningId,output_index:a.reasoningIndex,summary_index:0,part:{type:"summary_text",text:a.reasoningBuf}}),b("response.output_item.done",{type:"response.output_item.done",output_index:a.reasoningIndex,item:{id:a.reasoningId,type:"reasoning",summary:[{type:"summary_text",text:a.reasoningBuf}]}}))}function j(a,b,c){if(a.msgItemAdded[c]&&!a.msgItemDone[c]){a.msgItemDone[c]=!0;let d=a.msgTextBuf[c]||"",e=`msg_${a.responseId}_${c}`;b("response.output_text.done",{type:"response.output_text.done",item_id:e,output_index:parseInt(c),content_index:0,text:d,logprobs:[]}),b("response.content_part.done",{type:"response.content_part.done",item_id:e,output_index:parseInt(c),content_index:0,part:{type:"output_text",annotations:[],logprobs:[],text:d}}),b("response.output_item.done",{type:"response.output_item.done",output_index:parseInt(c),item:{id:e,type:"message",content:[{type:"output_text",annotations:[],logprobs:[],text:d}],role:"assistant"}})}}function k(a,b,c){let d=a.funcCallIds[c];if(d&&!a.funcItemDone[c]){let e=a.funcArgsBuf[c]||"{}";b("response.function_call_arguments.done",{type:"response.function_call_arguments.done",item_id:`fc_${d}`,output_index:parseInt(c),arguments:e}),b("response.output_item.done",{type:"response.output_item.done",output_index:parseInt(c),item:{id:`fc_${d}`,type:"function_call",arguments:e,call_id:d,name:a.funcNames[c]||""}}),a.funcItemDone[c]=!0,a.funcArgsDone[c]=!0}}function l(a,b){a.completedSent||(a.completedSent=!0,b("response.completed",{type:"response.completed",response:{id:a.responseId,object:"response",created_at:a.created,status:"completed",background:!1,error:null}}))}function m(a){return a.toolCallIndex>0||a.currentToolCallId?"tool_calls":"stop"}function n(a,b){if(!a){if(b.finishReasonSent||!b.started)return null;let a=m(b);b.finishReasonSent=!0,b.finishReason=a;let c={id:b.chatId||`chatcmpl-${Date.now()}`,object:"chat.completion.chunk",created:b.created||Math.floor(Date.now()/1e3),model:b.model||"unknown",choices:[{index:0,delta:{},finish_reason:a}]};return b.usage&&"object"==typeof b.usage&&(c.usage=b.usage),c}let c=a.type||a.event,d=a.data||a;if(b.started||(b.started=!0,b.chatId=`chatcmpl-${Date.now()}`,b.created=Math.floor(Date.now()/1e3),b.toolCallIndex=0,b.currentToolCallId=null),"response.output_text.delta"===c){let a=d.delta||"";return a?{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{content:a},finish_reason:null}]}:null}if("response.output_text.done"===c)return null;if("response.output_item.added"===c&&(d.item?.type==="function_call"||d.item?.type==="custom_tool_call")){let a=d.item;return b.currentToolCallId=a.call_id||`call_${Date.now()}`,{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{tool_calls:[{index:b.toolCallIndex,id:b.currentToolCallId,type:"function",function:{name:a.name||"",arguments:""}}]},finish_reason:null}]}}if("response.function_call_arguments.delta"===c||"response.custom_tool_call_input.delta"===c){let a=d.delta||"";return a?{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{tool_calls:[{index:b.toolCallIndex,function:{arguments:a}}]},finish_reason:null}]}:null}if("response.output_item.done"===c&&(d.item?.type==="function_call"||d.item?.type==="custom_tool_call"))return b.toolCallIndex++,null;if("response.completed"===c){let a=d.response?.usage;if(a&&"object"==typeof a){let c=a.input_tokens||a.prompt_tokens||0,d=a.output_tokens||a.completion_tokens||0,e=a.input_tokens_details?.cached_tokens||a.cache_read_input_tokens||0;b.usage={prompt_tokens:c,completion_tokens:d,total_tokens:c+d},e>0&&(b.usage.prompt_tokens_details={cached_tokens:e})}if(!b.finishReasonSent){let a=m(b);b.finishReasonSent=!0,b.finishReason=a;let c={id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{},finish_reason:a}]};return b.usage&&"object"==typeof b.usage&&(c.usage=b.usage),c}return null}if("error"===c||"response.failed"===c){if(b.finishReasonSent)return null;let a=d.error||d.response?.error;return a?(b.error=a,b.finishReasonSent=!0,{id:b.chatId||`chatcmpl-${Date.now()}`,object:"chat.completion.chunk",created:b.created||Math.floor(Date.now()/1e3),model:b.model||"unknown",choices:[{index:0,delta:{content:`[Error] ${a.message||JSON.stringify(a)}`},finish_reason:"stop"}]}):null}if("response.reasoning_summary_text.delta"===c){let a=d.delta||"";return a?{id:b.chatId,object:"chat.completion.chunk",created:b.created,model:b.model||"unknown",choices:[{index:0,delta:{reasoning_content:a},finish_reason:null}]}:null}return null}(0,d.kz)(e.h.OPENAI,e.h.OPENAI_RESPONSES,null,f),(0,d.kz)(e.h.OPENAI_RESPONSES,e.h.OPENAI,null,n)},8335:(a,b,c)=>{c.r(b),c.d(b,{convertCursorToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){return a?("chat.completion.chunk"===a.object&&a.choices||"chat.completion"===a.object&&a.choices,a):null}(0,d.kz)(e.h.CURSOR,e.h.OPENAI,null,f)},11203:(a,b,c)=>{c.r(b),c.d(b,{openaiToOllamaRequest:()=>f});var d=c(26263),e=c(56790);function f(a,b,c){let d={model:a,messages:function(a){if(!Array.isArray(a))return a;let b=[],c=new Map;for(let b of a)if("assistant"===b.role&&b.tool_calls)for(let a of b.tool_calls)a.id&&a.function?.name&&c.set(a.id,a.function.name);for(let d of a){if("tool"===d.role){let a=g(d.content);if(!a)continue;let e=c.get(d.tool_call_id)||d.name||"unknown_tool";b.push({role:"tool",tool_name:e,content:a});continue}if("assistant"===d.role&&d.tool_calls){let a=g(d.content)||"",c=d.tool_calls.map(a=>({type:"function",function:{index:a.index||0,name:a.function?.name||"",arguments:"string"==typeof a.function?.arguments?JSON.parse(a.function.arguments||"{}"):a.function?.arguments||{}}}));b.push({role:"assistant",content:a,tool_calls:c});continue}let a=d.role,e=g(d.content),f=function(a){if(!Array.isArray(a))return[];let b=[];for(let c of a){if(!c||"image_url"!==c.type)continue;let a="string"==typeof c.image_url?c.image_url:c.image_url?.url;if("string"!=typeof a||!a)continue;let d=a.match(/^data:[^;]+;base64,([\s\S]+)$/);d&&b.push(d[1])}return b}(d.content);if(!e&&"assistant"!==a)continue;let h={role:a,content:e};f.length>0&&(h.images=f),b.push(h)}return b}(b.messages),stream:c};return void 0!==b.temperature&&(d.options=d.options||{},d.options.temperature=b.temperature),void 0!==b.max_tokens&&(d.options=d.options||{},d.options.num_predict=b.max_tokens),void 0!==b.top_p&&(d.options=d.options||{},d.options.top_p=b.top_p),b.tools&&Array.isArray(b.tools)&&(d.tools=b.tools),b.tool_choice&&(d.tool_choice=b.tool_choice),d}function g(a){return"string"==typeof a?a:Array.isArray(a)&&a.filter(a=>a&&"text"===a.type&&a.text).map(a=>a.text).join("\n")||""}(0,d.kz)(e.h.OPENAI,e.h.OLLAMA,f,null)},13077:(a,b,c)=>{c.d(b,{KZ:()=>i,S6:()=>f,Yr:()=>m,f6:()=>j,fc:()=>e,kU:()=>g,pT:()=>h,w_:()=>k});let d=["minLength","maxLength","exclusiveMinimum","exclusiveMaximum","pattern","minItems","maxItems","format","default","examples","$schema","$defs","definitions","const","$ref","$comment","additionalProperties","propertyNames","patternProperties","enumDescriptions","anyOf","oneOf","allOf","not","dependencies","dependentSchemas","dependentRequired","title","if","then","else","contentMediaType","contentEncoding","cornerRadius","fillColor","fontFamily","fontSize","fontWeight","gap","padding","strokeColor","strokeThickness","textColor"],e=[{category:"HARM_CATEGORY_HATE_SPEECH",threshold:"OFF"},{category:"HARM_CATEGORY_DANGEROUS_CONTENT",threshold:"OFF"},{category:"HARM_CATEGORY_SEXUALLY_EXPLICIT",threshold:"OFF"},{category:"HARM_CATEGORY_HARASSMENT",threshold:"OFF"},{category:"HARM_CATEGORY_CIVIC_INTEGRITY",threshold:"OFF"}];function f(a){let b=[];if("string"==typeof a)b.push({text:a});else if(Array.isArray(a)){for(let c of a)if("text"===c.type)b.push({text:c.text});else if("image_url"===c.type&&c.image_url?.url?.startsWith("data:")){let a=c.image_url.url,d=a.indexOf(",");if(-1!==d){let c=a.substring(5,d),e=a.substring(d+1),f=c.split(";")[0];b.push({inlineData:{mime_type:f,data:e}})}}else if("image_url"===c.type&&c.image_url?.url&&(c.image_url.url.startsWith("http://")||c.image_url.url.startsWith("https://")))b.push({fileData:{fileUri:c.image_url.url,mimeType:"image/*"}});else if("input_audio"===c.type&&c.input_audio?.data){let a=c.input_audio.format||"wav",d="mp3"===a?"audio/mpeg":`audio/${a}`;b.push({inlineData:{mime_type:d,data:c.input_audio.data}})}else if("audio_url"===c.type&&c.audio_url?.url?.startsWith("data:")){let a=c.audio_url.url,d=a.indexOf(",");if(-1!==d){let c=a.substring(5,d),e=a.substring(d+1),f=c.split(";")[0];b.push({inlineData:{mime_type:f,data:e}})}}}return b}function g(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>"text"===a.type).map(a=>a.text).join(""):""}function h(a){if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return null}}function i(){return`agent-${crypto.randomUUID()}`}function j(){return crypto.randomUUID()+Date.now().toString()}function k(){let a=["useful","bright","swift","calm","bold"],b=["fuze","wave","spark","flow","core"],c=a[Math.floor(Math.random()*a.length)],d=b[Math.floor(Math.random()*b.length)];return`${c}-${d}-${crypto.randomUUID().slice(0,5)}`}function l(a){let b=0,c=-1;for(let d=0;d<a.length;d++){let e=a[d],f=0,g=e.type;"object"===g||e.properties?f=3:"array"===g||e.items?f=2:g&&"null"!==g&&(f=1),f>c&&(c=f,b=d)}return b}function m(a){return a&&"object"==typeof a&&(!function a(b){if(b&&"object"==typeof b)for(let c of(void 0===b.const||b.enum||(b.enum=[b.const],delete b.const),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b){if(b&&"object"==typeof b)for(let c of(b.enum&&Array.isArray(b.enum)&&(b.enum=b.enum.map(a=>String(a)),b.type||(b.type="string")),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b){if(b&&"object"==typeof b){if(b.allOf&&Array.isArray(b.allOf)){let a={};for(let c of b.allOf)if(c.properties&&(a.properties||(a.properties={}),Object.assign(a.properties,c.properties)),c.required&&Array.isArray(c.required))for(let b of(a.required||(a.required=[]),c.required))a.required.includes(b)||a.required.push(b);delete b.allOf,a.properties&&(b.properties={...b.properties,...a.properties}),a.required&&(b.required=[...b.required||[],...a.required])}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b){if(b.anyOf&&Array.isArray(b.anyOf)&&b.anyOf.length>0){let a=b.anyOf.filter(a=>a&&"null"!==a.type);if(a.length>0){let c=l(a),d=a[c];delete b.anyOf,Object.assign(b,d)}}if(b.oneOf&&Array.isArray(b.oneOf)&&b.oneOf.length>0){let a=b.oneOf.filter(a=>a&&"null"!==a.type);if(a.length>0){let c=l(a),d=a[c];delete b.oneOf,Object.assign(b,d)}}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b){if(b.type&&Array.isArray(b.type)){let a=b.type.filter(a=>"null"!==a);b.type=a.length>0?a[0]:"string"}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b)for(let c of(b.properties&&!b.type&&(b.type="object"),Object.values(b)))c&&"object"==typeof c&&a(c)}(a),!function a(b,c){if(b&&"object"==typeof b){if(Array.isArray(b)){for(let d of b)a(d,c);return}for(let d of Object.keys(b)){if(c.includes(d)||d.startsWith("x-")){delete b[d];continue}let e=b[d];e&&"object"==typeof e&&a(e,c)}}}(a,d),!function a(b){if(b&&"object"==typeof b){if(b.required&&Array.isArray(b.required)&&b.properties){let a=b.required.filter(a=>Object.prototype.hasOwnProperty.call(b.properties,a));0===a.length?delete b.required:b.required=a}for(let c of Object.values(b))c&&"object"==typeof c&&a(c)}}(a),!function a(b){if(b&&"object"==typeof b)for(let c of("object"!==b.type||b.properties&&0!==Object.keys(b.properties).length||(b.properties={reason:{type:"string",description:"Brief explanation of why you are calling this tool"}},b.required=["reason"]),Object.values(b)))c&&"object"==typeof c&&a(c)}(a)),a}},17019:(a,b,c)=>{c.r(b),c.d(b,{ollamaBodyToOpenAI:()=>i,ollamaToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a||"object"!=typeof a)return null;b.ollama||(b.ollama={id:`chatcmpl-${Date.now()}`,created:Math.floor(Date.now()/1e3),model:a.model||b.model});let{id:c,created:d,model:e}=b.ollama;if(a.done){let f=g(a),h="stop";return("tool_calls"===a.done_reason||b.hadToolCalls)&&(h="tool_calls"),{id:c,object:"chat.completion.chunk",created:d,model:e,choices:[{index:0,delta:{},finish_reason:h}],usage:f}}let f=a.message;if(!f)return null;let i="string"==typeof f.content?f.content:"",j="string"==typeof f.thinking?f.thinking:"",k=Array.isArray(f.tool_calls)?f.tool_calls:null;if(!i&&!j&&!k)return null;i&&(b.accumulatedContent=(b.accumulatedContent||"")+i),j&&(b.accumulatedThinking=(b.accumulatedThinking||"")+j);let l={};return i&&(l.content=i),j&&(l.reasoning_content=j),k&&(b.hadToolCalls=!0,l.tool_calls=h(k)),{id:c,object:"chat.completion.chunk",created:d,model:e,choices:[{index:0,delta:l,finish_reason:null}]}}function g(a){return{prompt_tokens:a.prompt_eval_count||0,completion_tokens:a.eval_count||0,total_tokens:(a.prompt_eval_count||0)+(a.eval_count||0)}}function h(a){return a.map((a,b)=>({index:a.function?.index??b,id:a.id||`call_${b}_${Date.now()}`,type:"function",function:{name:a.function?.name||"",arguments:"string"==typeof a.function?.arguments?a.function.arguments:JSON.stringify(a.function?.arguments||{})}}))}function i(a){let b=a.message||{},c=b.content||"",d=b.thinking||"",e=Array.isArray(b.tool_calls)?b.tool_calls:[],f={role:"assistant"};c&&(f.content=c),d&&(f.reasoning_content=d),e.length>0&&(f.tool_calls=h(e)),f.content||f.tool_calls||(f.content="");let i=a.done_reason||"stop";return e.length>0&&(i="tool_calls"),{id:`chatcmpl-${Date.now()}`,object:"chat.completion",created:Math.floor(Date.now()/1e3),model:a.model||"ollama",choices:[{index:0,message:f,finish_reason:i}],usage:g(a)}}(0,d.kz)(e.h.OLLAMA,e.h.OPENAI,null,f)},18230:(a,b,c)=>{function d(a,b){}c.d(b,{T:()=>e,s:()=>d});let e=!1},19171:(a,b,c)=>{c.d(b,{SZ:()=>j,Tz:()=>h,jJ:()=>i});var d=c(62276);c(98774);function e(a){return"string"==typeof a&&a.startsWith("openai-compatible-")}function f(a){return"string"==typeof a&&a.startsWith("anthropic-compatible-")}function g(a){return e(a)&&a.includes("responses")?"responses":"chat"}function h(a){if(a.input&&(Array.isArray(a.input)||"string"==typeof a.input)&&!a.messages)return"openai-responses";if(a.request?.contents&&"antigravity"===a.userAgent)return"antigravity";if(a.contents&&Array.isArray(a.contents))return"gemini";if(a.stream_options||a.response_format||void 0!==a.logprobs||void 0!==a.top_logprobs||void 0!==a.n||void 0!==a.presence_penalty||void 0!==a.frequency_penalty||a.logit_bias||a.user)return"openai";if(a.messages&&Array.isArray(a.messages)){let b=a.messages[0];if(b?.content&&Array.isArray(b.content)){let c=b.content[0];if(c?.type==="text"&&!a.model?.includes("/")){if(a.system||a.anthropic_version)return"claude";let c=b.content.some(a=>"image"===a.type&&a.source?.type==="base64"),d=b.content.some(a=>"image_url"===a.type&&a.image_url?.url);if(c)return"claude";if(d)return"openai";if(b.content.some(a=>"tool_use"===a.type||"tool_result"===a.type))return"claude"}}if(void 0!==a.system||a.anthropic_version)return"claude"}return"openai"}function i(a){return e(a)?"responses"===g(a)?"openai-responses":"openai":f(a)?"claude":function(a){if(e(a)){let b=g(a);return{...d.xq.openai,format:"responses"===b?"openai-responses":"openai",baseUrl:"https://api.openai.com/v1"}}return f(a)?{...d.xq.anthropic,format:"claude",baseUrl:"https://api.anthropic.com/v1"}:d.xq[a]||d.xq.openai}(a).format||"openai"}function j(a){return!function(a){let b=a.messages||a.contents;if(!b?.length)return!0;let c=b[b.length-1];return c?.role==="user"}(a)&&(delete a.reasoning_effort,delete a.thinking),a}},19312:(a,b,c)=>{c.d(b,{M:()=>e});var d=c(23016);function e(a){let b=a.max_tokens||d.Uc;return a.tools&&Array.isArray(a.tools)&&a.tools.length>0&&b<d.eo&&(b=d.eo),a.thinking?.budget_tokens&&b<=a.thinking.budget_tokens&&(b=a.thinking.budget_tokens+1024),b}},19999:(a,b,c)=>{c.r(b),c.d(b,{openaiToVertexRequest:()=>h});var d=c(26263),e=c(56790),f=c(78178),g=c(52589);function h(a,b,c,d){var e=(0,f.openaiToGeminiRequest)(a,b,c,d);if(!e?.contents)return e;for(let a of e.contents)if(Array.isArray(a.parts))for(let b of a.parts)void 0!==b.thoughtSignature&&(b.thoughtSignature=g.n6),b.functionCall&&"id"in b.functionCall&&delete b.functionCall.id,b.functionResponse&&"id"in b.functionResponse&&delete b.functionResponse.id;return e}(0,d.kz)(e.h.OPENAI,e.h.VERTEX,h,null)},20362:(a,b,c)=>{c.d(b,{RF:()=>i});var d=c(55511),e=c.n(d),f=c(23016);let g=new Map,h=setInterval(()=>{let a=Date.now();for(let[b,c]of g)a-c.lastUsed>f.v1.sessionTtlMs&&g.delete(b)},f.v1.sessionCleanupIntervalMs);function i(a){if(!a)return j();let b=g.get(a);if(b)return b.lastUsed=Date.now(),b.sessionId;if(g.size>=1e3){let a=g.keys().next().value;g.delete(a)}let c=j();return g.set(a,{sessionId:c,lastUsed:Date.now()}),c}function j(){return e().randomUUID()+Date.now().toString()}h.unref&&h.unref()},24353:(a,b,c)=>{c.d(b,{H:()=>g});var d=c(23016),e=c(37973),f=c(18230);class g{constructor(a,b){this.provider=a,this.config=b,this.noAuth=b?.noAuth||!1}getProvider(){return this.provider}getBaseUrls(){return this.config.baseUrls||(this.config.baseUrl?[this.config.baseUrl]:[])}getFallbackCount(){return this.getBaseUrls().length||1}buildUrl(a,b,c=0,d=null){if(this.provider?.startsWith?.("openai-compatible-")){let a=(d?.providerSpecificData?.baseUrl||"https://api.openai.com/v1").replace(/\/$/,""),b=this.provider.includes("responses")?"/responses":"/chat/completions";return`${a}${b}`}if(this.provider?.startsWith?.("anthropic-compatible-")){let a=(d?.providerSpecificData?.baseUrl||"https://api.anthropic.com/v1").replace(/\/$/,"");return`${a}/messages`}let e=this.getBaseUrls();return e[c]||e[0]||this.config.baseUrl}buildHeaders(a,b=!0){let c={"Content-Type":"application/json",...this.config.headers};return this.provider?.startsWith?.("anthropic-compatible-")?(a.apiKey?c["x-api-key"]=a.apiKey:a.accessToken&&(c.Authorization=`Bearer ${a.accessToken}`),c["anthropic-version"]||(c["anthropic-version"]="2023-06-01")):a.accessToken?c.Authorization=`Bearer ${a.accessToken}`:a.apiKey&&(c.Authorization=`Bearer ${a.apiKey}`),b&&(c.Accept="text/event-stream"),c}transformRequest(a,b,c,d){return b}shouldRetry(a,b){return a===d.gx.RATE_LIMITED&&b+1<this.getFallbackCount()}async refreshCredentials(a,b,c=null){return null}needsRefresh(a){return!!a.expiresAt&&new Date(a.expiresAt).getTime()-Date.now()<3e5}parseError(a,b){return{status:a.status,message:b||`HTTP ${a.status}`}}async execute({model:a,body:b,stream:c,credentials:g,signal:h,log:i,proxyOptions:j=null}){let k=this.getFallbackCount(),l=null,m=0,n={},o={...d.cI,...this.config.retry},p=async(a,b,c)=>{let{attempts:e,delayMs:f}=(0,d.DR)(o[b]);return!(e<=0)&&!(n[a]>=e)&&(n[a]++,i?.debug?.("RETRY",`${c} retry ${n[a]}/${e} after ${f/1e3}s`),await new Promise(a=>setTimeout(a,f)),!0)};for(let o=0;o<k;o++){let q=this.buildUrl(a,c,o,g),r=this.transformRequest(a,b,c,g),s=this.buildHeaders(g,c);n[o]||(n[o]=0);let t=new AbortController,u=setTimeout(()=>t.abort(Error("fetch connect timeout")),d.pH),v=h?AbortSignal.any([h,t.signal]):t.signal;try{let a=JSON.stringify(r),b=Date.now();(0,f.s)("FETCH",`${this.provider.toUpperCase()} → ${q} | body=${a.length}B | connectTimeout=${d.pH}ms`);let c=await (0,e.proxyAwareFetch)(q,{method:"POST",headers:s,body:a,signal:v},j);clearTimeout(u);let g=c.headers?.get?.("content-type")||"",h=c.headers?.get?.("content-length")||"?";if((0,f.s)("FETCH",`${this.provider.toUpperCase()} ← ${c.status} | ttft=${Date.now()-b}ms | ct=${g} | cl=${h}`),await p(o,c.status,`status ${c.status}`)){o--;continue}if(this.shouldRetry(c.status,o)){i?.debug?.("RETRY",`${c.status} on ${q}, trying fallback ${o+1}`),m=c.status;continue}return{response:c,url:q,headers:s,transformedBody:r}}catch(b){clearTimeout(u),l=b;let a=t.signal.aborted&&"AbortError"===b.name;if((0,f.s)("FETCH",`${this.provider.toUpperCase()} ✖ ${b.name}: ${b.message}${a?" (connect timeout)":""}`),"AbortError"===b.name&&!a)throw b;if(await p(o,d.gx.BAD_GATEWAY,`network "${b.message}"`)){o--;continue}if(o+1<k){i?.debug?.("RETRY",`Error on ${q}, trying fallback ${o+1}`);continue}throw b}}throw l||Error(`All ${k} URLs failed with status ${m}`)}}},26263:(a,b,c)=>{c.d(b,{Ws:()=>v,Ai:()=>w,nZ:()=>u,kz:()=>q,GH:()=>s,Y8:()=>t});var d=c(56790);let e=/^[a-zA-Z0-9_-]+$/;function f(a=0,b=0,c=""){let d=c?`_${c.replace(/[^a-zA-Z0-9_-]/g,"")}`:"";return`call_msg${a}_tc${b}${d}`}function g(a){if(!a||"string"!=typeof a)return null;let b=a.replace(/[^a-zA-Z0-9_-]/g,"");return b.length>0?b:null}var h=c(52589);c(19312);var i=c(96771),j=c(20362);let k=new Set(["minimax","minimax-cn"]),l=["text","image_url","image","input_audio","audio_url"];var m=c(19171);c(1820);let n=new Map,o=new Map,p=!1;function q(a,b,c,d){let e=`${a}:${b}`;c&&n.set(e,c),d&&o.set(e,d)}function r(){p||(p=!0,c(95579),c(39359),c(32178),c(78178),c(19999),c(44901),c(77021),c(85917),c(38911),c(11203),c(33465),c(76839),c(66299),c(45070),c(63151),c(1950),c(29202),c(8335),c(17019),c(80319))}function s(a,b,c,o,p=!0,q=null,t=null,u=null,v=[],w=null,x=null){r();let y=o;if(!function(a,b=[]){if(!b.length||!a.messages||!Array.isArray(a.messages))return;let c=new Set(["image_url","image"]),d=new Set(["audio_url","input_audio"]),e=a=>c.has(a)?b.includes("image"):!!d.has(a)&&b.includes("audio");for(let b of a.messages)Array.isArray(b.content)&&(b.content=b.content.filter(a=>!e(a.type)),0===b.content.length&&(b.content=""))}(y,v),(0,m.SZ)(y),!function(a){if(a.messages&&Array.isArray(a.messages))for(let b=0;b<a.messages.length;b++){let c=a.messages[b];if("assistant"===c.role&&c.tool_calls&&Array.isArray(c.tool_calls))for(let a=0;a<c.tool_calls.length;a++){let d=c.tool_calls[a];if(!d.id||!e.test(d.id)){let c=g(d.id);d.id=c||f(b,a,d.function?.name)}d.type||(d.type="function"),d.function?.arguments&&"string"!=typeof d.function.arguments&&(d.function.arguments=JSON.stringify(d.function.arguments))}if("tool"===c.role&&c.tool_call_id&&!e.test(c.tool_call_id)){let a=g(c.tool_call_id);c.tool_call_id=a||f(b,0)}if(Array.isArray(c.content))for(let a=0;a<c.content.length;a++){let d=c.content[a];if("tool_use"===d.type&&d.id&&!e.test(d.id)){let c=g(d.id);d.id=c||f(b,a,d.name)}if("tool_result"===d.type&&d.tool_use_id&&!e.test(d.tool_use_id)){let c=g(d.tool_use_id);d.tool_use_id=c||f(b,a)}}}}(y),!function(a){if(!a.messages||!Array.isArray(a.messages))return;let b=[];for(let c=0;c<a.messages.length;c++){let d=a.messages[c],e=a.messages[c+1];b.push(d);let f=function(a){if("assistant"!==a.role)return[];let b=[];if(a.tool_calls&&Array.isArray(a.tool_calls))for(let c of a.tool_calls)c.id&&b.push(c.id);if(Array.isArray(a.content))for(let c of a.content)"tool_use"===c.type&&c.id&&b.push(c.id);return b}(d);if(0!==f.length&&e&&!function(a,b){if(!a||!b.length)return!1;if("tool"===a.role&&a.tool_call_id)return b.includes(a.tool_call_id);if("user"===a.role&&Array.isArray(a.content)){for(let c of a.content)if("tool_result"===c.type&&b.includes(c.tool_use_id))return!0}return!1}(e,f))for(let a of f)b.push({role:"tool",tool_call_id:a,content:""})}a.messages=b}(y),a!==b){if(a!==d.h.OPENAI){let b=n.get(`${a}:${d.h.OPENAI}`);b&&(y=b(c,y,p,q),u?.logOpenAIRequest?.(y))}if(b!==d.h.OPENAI){let a=n.get(`${d.h.OPENAI}:${b}`);a&&(y=a(c,y,p,q))}}if(b===d.h.OPENAI&&(y=function(a){if(!a.messages||!Array.isArray(a.messages))return a;if(a.messages=a.messages.map(a=>{if("developer"===a.role&&(a={...a,role:"system"}),"tool"===a.role||"assistant"===a.role&&a.tool_calls||"string"==typeof a.content)return a;if(Array.isArray(a.content)){let b=[];for(let c of a.content)if("thinking"!==c.type&&"redacted_thinking"!==c.type){if(l.includes(c.type)){let{signature:a,cache_control:d,...e}=c;b.push(e)}else if("tool_use"===c.type)continue;else if("tool_result"===c.type){let{signature:a,cache_control:d,...e}=c;b.push(e)}}return 0===b.length&&b.push({type:"text",text:""}),{...a,content:b}}return a}),a.messages=a.messages.filter(a=>"tool"===a.role||"assistant"===a.role&&!!a.tool_calls||("string"==typeof a.content?""!==a.content.trim():!Array.isArray(a.content)||a.content.some(a=>"text"===a.type&&a.text?.trim()||"text"!==a.type))),a.tools&&Array.isArray(a.tools)&&0===a.tools.length&&delete a.tools,a.tools&&Array.isArray(a.tools)&&a.tools.length>0&&(a.tools=a.tools.map(a=>"function"===a.type&&a.function?a:a.name&&(a.input_schema||a.description)?{type:"function",function:{name:a.name,description:String(a.description||""),parameters:a.input_schema||{type:"object",properties:{}}}}:a.functionDeclarations&&Array.isArray(a.functionDeclarations)?a.functionDeclarations.map(a=>({type:"function",function:{name:a.name,description:String(a.description||""),parameters:a.parameters||{type:"object",properties:{}}}})):a).flat()),a.tool_choice&&"object"==typeof a.tool_choice){let b=a.tool_choice;"auto"===b.type?a.tool_choice="auto":"any"===b.type?a.tool_choice="required":"tool"===b.type&&b.name&&(a.tool_choice={type:"function",function:{name:b.name}})}return a}(y)),b===d.h.CLAUDE&&(y=function(a,b=null,c=null,d=null){if(k.has(b)&&delete a.output_config,a.system&&Array.isArray(a.system)&&(a.system=a.system.map((b,c)=>{let{cache_control:d,...e}=b;return c===a.system.length-1?{...e,cache_control:{type:"ephemeral",ttl:"1h"}}:e})),a.messages&&Array.isArray(a.messages)){let c=a.messages.length,d=[];for(let b=0;b<c;b++){let e=a.messages[b];if(Array.isArray(e.content))for(let a of e.content)delete a.cache_control;(b===c-1&&"assistant"===e.role||"string"==typeof e.content&&e.content.trim()||Array.isArray(e.content)&&e.content.some(a=>"text"===a.type&&a.text?.trim()||"tool_use"===a.type||"tool_result"===a.type))&&d.push(e)}d=function(a){if(a.length<=1)return a;for(let b of a)if("assistant"===b.role&&Array.isArray(b.content)&&b.content.some(a=>"tool_use"===a.type)){let a=[],c=!1;for(let d of b.content)"tool_use"===d.type?(c=!0,a.push(d)):"thinking"===d.type||"redacted_thinking"===d.type?a.push(d):c||a.push(d);b.content=a}let b=[];for(let c of a){let a=b[b.length-1];if(a&&a.role===c.role){let b=Array.isArray(a.content)?a.content:[{type:"text",text:a.content}],d=Array.isArray(c.content)?c.content:[{type:"text",text:c.content}];a.content=[...b.filter(a=>"tool_result"===a.type),...d.filter(a=>"tool_result"===a.type),...b.filter(a=>"tool_result"!==a.type),...d.filter(a=>"tool_result"!==a.type)]}else{let a=Array.isArray(c.content)?c.content:[{type:"text",text:c.content}];b.push({role:c.role,content:[...a]})}}return b}(d),a.messages=d;let e=d[d.length-1],f=e?.role==="user",g=a.thinking?.type==="enabled"&&f,i=!1;for(let a=d.length-1;a>=0;a--){let c=d[a];if("assistant"===c.role&&Array.isArray(c.content)){if(!i&&c.content.length>0){for(let a=c.content.length-1;a>=0;a--){let b=c.content[a];if("thinking"!==b.type&&"redacted_thinking"!==b.type){b.cache_control={type:"ephemeral"};break}}i=!0}if("claude"===b||b?.startsWith("anthropic-compatible")){let a=!1,b=!1;for(let d of c.content)("thinking"===d.type||"redacted_thinking"===d.type)&&(d.signature=h.xr,b=!0),"tool_use"===d.type&&(a=!0);g&&!b&&a&&c.content.unshift({type:"thinking",thinking:".",signature:h.xr})}}}}if(a.tools&&Array.isArray(a.tools)&&("claude"!==b&&(a.tools=a.tools.filter(a=>!a.type||"function"===a.type)),a.tools=a.tools.map((b,c)=>{let{cache_control:d,...e}=b;return c===a.tools.length-1?{...e,cache_control:{type:"ephemeral",ttl:"1h"}}:e}),0===a.tools.length&&(delete a.tools,delete a.tool_choice)),("claude"===b||b?.startsWith("anthropic-compatible"))&&c){let b=d?(0,j.RF)(d):null;a=(0,i.fO)(a,c,b)}return a}(y,t,q?.accessToken||q?.apiKey||null,w)),"claude"===t){let a=q?.accessToken||q?.apiKey||null;if(a?.includes("sk-ant-oat")){let{body:a,toolNameMap:b}=(0,i.Az)(y);y=a,b?.size>0&&(y._toolNameMap=b)}}return y}function t(a,b,c,e){if(r(),b===a)return[c];let f=[c],g=null;if(a!==d.h.OPENAI){let b=o.get(`${a}:${d.h.OPENAI}`);if(b){f=[];let a=b(c,e);a&&(g=f=Array.isArray(a)?a:[a])}}if(b!==d.h.OPENAI){let a=o.get(`${d.h.OPENAI}:${b}`);if(a){let b=[];for(let c of f){let d=a(c,e);d&&b.push(...Array.isArray(d)?d:[d])}f=b}}return g&&b!==d.h.OPENAI&&a!==d.h.OPENAI&&(f._openaiIntermediate=g),f}function u(a,b){return a!==b}function v(a){let b={messageId:null,model:null,textBlockStarted:!1,thinkingBlockStarted:!1,inThinkingBlock:!1,currentBlockIndex:null,toolCalls:new Map,finishReason:null,finishReasonSent:!1,usage:null,contentBlockIndex:-1};return a===d.h.OPENAI_RESPONSES?{...b,seq:0,responseId:`resp_${Date.now()}`,created:Math.floor(Date.now()/1e3),started:!1,msgTextBuf:{},msgItemAdded:{},msgContentAdded:{},msgItemDone:{},reasoningId:"",reasoningIndex:-1,reasoningBuf:"",reasoningPartAdded:!1,reasoningDone:!1,inThinking:!1,funcArgsBuf:{},funcNames:{},funcCallIds:{},funcArgsDone:{},funcItemDone:{},completedSent:!1}:b}function w(){r()}},29202:(a,b,c)=>{c.r(b),c.d(b,{convertKiroToOpenAI:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;if("chat.completion.chunk"===a.object&&a.choices)return a;let c=a;if("string"==typeof a){let b=a.split("\n"),d="",e="";for(let a of b)a.startsWith("event:")?d=a.slice(6).trim():a.startsWith(":event-type:")?d=a.slice(12).trim():a.startsWith("data:")?e=a.slice(5).trim():a.startsWith(":content-type:")||a.trim()&&!a.startsWith(":")&&(e=a.trim());if(!e)return null;try{(c=JSON.parse(e))._eventType=d}catch{c={text:e,_eventType:d}}}b.responseId||(b.responseId=`chatcmpl-${Date.now()}`,b.created=Math.floor(Date.now()/1e3),b.chunkIndex=0);let d=c._eventType||c.event||"";if("assistantResponseEvent"===d||c.assistantResponseEvent){let a=c.assistantResponseEvent?.content||c.content||"";if(!a)return null;let d={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},content:a},finish_reason:null}]};return b.chunkIndex++,d}if("reasoningContentEvent"===d||c.reasoningContentEvent){let a=c.reasoningContentEvent||c,d="string"==typeof a?a:a.text||a.content||c.content||"";if(!d)return null;let e={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},reasoning_content:d},finish_reason:null}]};return b.chunkIndex++,e}if("toolUseEvent"===d||c.toolUseEvent){let a=c.toolUseEvent||c,d=a.toolUseId||`call_${Date.now()}`,e=a.name||"",f=a.input||{},g={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{...0===b.chunkIndex?{role:"assistant"}:{},tool_calls:[{index:0,id:d,type:"function",function:{name:e,arguments:JSON.stringify(f)}}]},finish_reason:null}]};return b.chunkIndex++,g}if("messageStopEvent"===d||"done"===d||c.messageStopEvent){b.finishReason="stop";let a={id:b.responseId,object:"chat.completion.chunk",created:b.created,model:b.model||"kiro",choices:[{index:0,delta:{},finish_reason:"stop"}]};return b.usage&&"object"==typeof b.usage&&(a.usage=b.usage),a}if("usageEvent"===d||c.usageEvent){let a=c.usageEvent||c;a&&"object"==typeof a&&(b.usage={prompt_tokens:a.inputTokens||0,completion_tokens:a.outputTokens||0,total_tokens:(a.inputTokens||0)+(a.outputTokens||0)})}return null}(0,d.kz)(e.h.KIRO,e.h.OPENAI,null,f)},32178:(a,b,c)=>{c.r(b),c.d(b,{geminiToOpenAIRequest:()=>g});var d=c(26263),e=c(56790),f=c(19312);function g(a,b,c){let d={model:a,messages:[],stream:c};if(b.generationConfig){let a=b.generationConfig;if(a.maxOutputTokens){let c={max_tokens:a.maxOutputTokens,tools:b.tools};d.max_tokens=(0,f.M)(c)}void 0!==a.temperature&&(d.temperature=a.temperature),void 0!==a.topP&&(d.top_p=a.topP)}if(b.systemInstruction){var e;let a="string"==typeof(e=b.systemInstruction)?e:e.parts&&Array.isArray(e.parts)?e.parts.map(a=>a.text||"").join(""):"";a&&d.messages.push({role:"system",content:a})}if(b.contents&&Array.isArray(b.contents))for(let a of b.contents){let b=function(a){let b="user"===a.role?"user":"assistant";if(!a.parts||!Array.isArray(a.parts))return null;let c=[],d=[];for(let b of a.parts)if(void 0!==b.text&&c.push({type:"text",text:b.text}),b.inlineData&&c.push({type:"image_url",image_url:{url:`data:${b.inlineData.mimeType};base64,${b.inlineData.data}`}}),b.functionCall&&d.push({id:`call_${Date.now()}_${Math.random().toString(36).slice(2,8)}`,type:"function",function:{name:b.functionCall.name,arguments:JSON.stringify(b.functionCall.args||{})}}),b.functionResponse)return{role:"tool",tool_call_id:b.functionResponse.id||b.functionResponse.name,content:JSON.stringify(b.functionResponse.response?.result||b.functionResponse.response||{})};if(d.length>0){let a={role:"assistant"};return c.length>0&&(a.content=1===c.length?c[0].text:c),a.tool_calls=d,a}return c.length>0?{role:b,content:1===c.length&&"text"===c[0].type?c[0].text:c}:null}(a);b&&d.messages.push(b)}if(b.tools&&Array.isArray(b.tools)){for(let a of(d.tools=[],b.tools))if(a.functionDeclarations)for(let b of a.functionDeclarations)d.tools.push({type:"function",function:{name:b.name,description:b.description||"",parameters:b.parameters||{type:"object",properties:{}}}})}return d}(0,d.kz)(e.h.GEMINI,e.h.OPENAI,g,null),(0,d.kz)(e.h.GEMINI_CLI,e.h.OPENAI,g,null)},33465:(a,b,c)=>{c.r(b),c.d(b,{openaiToCommandCode:()=>h});var d=c(26263),e=c(56790),f=c(55511);function g(a){if(null==a)return"";if("string"==typeof a)return a;if(Array.isArray(a)){let b=[];for(let c of a)"string"==typeof c?b.push(c):c&&"object"==typeof c&&"string"==typeof c.text&&b.push(c.text);return b.join("\n")}return String(a)}function h(a,b,c){let{messages:d,system:e}=function(a=[]){let b=[],c=[];for(let d of a){if(!d)continue;let a=d.role;if("system"===a){let a=g(d.content);a&&c.push(a);continue}if("tool"===a){let a="string"==typeof d.content?d.content:g(d.content);b.push({role:"tool",content:[{type:"tool-result",toolCallId:d.tool_call_id||"",toolName:d.name||"",output:{type:"text",value:a}}]});continue}if("assistant"===a){let a=[],c=g(d.content);if(c&&a.push({type:"text",text:c}),Array.isArray(d.tool_calls))for(let b of d.tool_calls){let c=b.function||{};a.push({type:"tool-call",toolCallId:b.id||"",toolName:c.name||"",input:function(a){if(null==a)return{};if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return{}}}(c.arguments)})}b.push({role:"assistant",content:a.length?a:[{type:"text",text:""}]});continue}b.push({role:"user",content:function(a){if(null==a)return[{type:"text",text:""}];if("string"==typeof a)return[{type:"text",text:a}];if(Array.isArray(a)){let b=[];for(let c of a)"string"==typeof c?b.push({type:"text",text:c}):c&&"object"==typeof c&&("text"===c.type&&"string"==typeof c.text?b.push({type:"text",text:c.text}):"image_url"===c.type||"image"===c.type?b.push({type:"text",text:"[image omitted]"}):"string"==typeof c.text&&b.push({type:"text",text:c.text}));return b.length?b:[{type:"text",text:""}]}return[{type:"text",text:String(a)}]}(d.content)})}return{messages:b,system:c.join("\n\n")}}(b.messages),h={model:a,messages:d,stream:!1!==c,max_tokens:b.max_tokens??b.max_output_tokens??64e3,temperature:b.temperature??.3};e&&(h.system=e);let i=function(a){if(!Array.isArray(a)||0===a.length)return;let b=[];for(let c of a)c&&("function"===c.type&&c.function?b.push({name:c.function.name,description:c.function.description,input_schema:c.function.parameters||{type:"object"}}):c.name&&(c.input_schema||c.parameters)&&b.push({name:c.name,description:c.description,input_schema:c.input_schema||c.parameters}));return b.length?b:void 0}(b.tools);i&&(h.tools=i),null!=b.top_p&&(h.top_p=b.top_p);let j=new Date().toISOString().slice(0,10);return{threadId:(0,f.randomUUID)(),memory:"",config:{workingDir:process.cwd(),date:j,environment:process.platform,structure:[],isGitRepo:!1,currentBranch:"",mainBranch:"",gitStatus:"",recentCommits:[]},params:h}}(0,d.kz)(e.h.OPENAI,e.h.COMMANDCODE,h,null)},38911:(a,b,c)=>{c.r(b),c.d(b,{buildCursorRequest:()=>j});var d=c(26263),e=c(56790);function f(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>!!a&&"object"==typeof a&&"text"===a.type&&"string"==typeof a.text).map(a=>a.text||"").join(""):""}function g(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function h(a,b,c){let d=(c||"").replace(/[\u0000-\u0008\u000B\u000C\u000E-\u001F\u007F]/g,"");return`<tool_result>
2
2
  <tool_name>${g(a||"tool")}</tool_name>
3
3
  <tool_call_id>${g(b||"")}</tool_call_id>
4
4
  <result>${g(d)}</result>
5
5
  </tool_result>`}function i(a){return"string"==typeof a?a.split("\n")[0]:""}function j(a,b,c,d){let e=function(a){let b=[],c=new Map,d=(a,b)=>{if(!a)return;let d=b||"tool";c.set(a,{name:d});let e=i(a);e&&e!==a&&c.set(e,{name:d})};for(let b of a){if("assistant"===b.role&&b.tool_calls)for(let a of b.tool_calls)d(a.id||"",a.function?.name||"tool");if("assistant"===b.role&&Array.isArray(b.content))for(let a of b.content)a?.type==="tool_use"&&d(a.id||"",a.name||"tool")}for(let d=0;d<a.length;d++){let e=a[d];if("system"===e.role){b.push({role:"user",content:`[System Instructions]
6
- ${f(e.content)}`});continue}if("tool"===e.role){let a=f(e.content),d=e.tool_call_id||"",g=c.get(d)||{},i=e.name||g.name||"tool";b.push({role:"user",content:h(i,d,a)});continue}if("user"===e.role||"assistant"===e.role){if("user"===e.role&&Array.isArray(e.content)){let a=[];for(let b of e.content)if(b&&"object"==typeof b){if("text"===b.type){"string"==typeof b.text&&a.push(b.text||"");continue}if("tool_result"===b.type){let d=b.tool_use_id||"",e=c.get(d)||c.get(i(d)),g=e?.name||"tool",j=f(b.content);a.push(h(g,d,j))}}let d=a.filter(Boolean).join("\n");d&&b.push({role:"user",content:d});continue}let a=f(e.content);if("assistant"===e.role&&e.tool_calls&&e.tool_calls.length>0){let c={role:"assistant",content:a||""};c.tool_calls=e.tool_calls.map(a=>{let{index:b,...c}=a||{};return c}),b.push(c)}else if("assistant"===e.role&&Array.isArray(e.content)){let c=e.content.filter(a=>a?.type==="tool_use").map(a=>({id:a.id||"",type:"function",function:{name:a.name||"tool",arguments:JSON.stringify(a.input||{})}})).filter(a=>a.id);c.length>0?b.push({role:"assistant",content:a||"",tool_calls:c}):a&&b.push({role:"assistant",content:a})}else a&&b.push({role:e.role,content:a})}}return b}(b.messages||[]),{user:g,metadata:j,tool_choice:k,stream_options:l,system:m,...n}=b;return{...n,messages:e,max_tokens:32e3}}(0,d.kz)(e.h.OPENAI,e.h.CURSOR,j,null)},39006:a=>{a.exports={rE:"0.4.59"}},39359:(a,b,c)=>{c.r(b),c.d(b,{openaiToClaudeRequest:()=>h,openaiToClaudeRequestForAntigravity:()=>j});var d=c(26263),e=c(56790),f=c(43528),g=c(19312);function h(a,b,c){var d;let e=new Map,h={model:a,max_tokens:(0,g.M)(b),stream:c};void 0!==b.temperature&&(h.temperature=b.temperature),h.messages=[];let j=[];if(b.messages&&Array.isArray(b.messages)){let a;for(let a of b.messages)"system"===a.role&&j.push("string"==typeof a.content?a.content:i(a.content));let c=b.messages.filter(a=>"system"!==a.role),d=[],f=()=>{a&&d.length>0&&(h.messages.push({role:a,content:d}),d=[])};for(let b of c){let c="user"===b.role||"tool"===b.role?"user":"assistant",g=function(a,b=new Map){let c=[];if("tool"===a.role)c.push({type:"tool_result",tool_use_id:a.tool_call_id,content:a.content});else if("user"===a.role){if("string"==typeof a.content)a.content&&c.push({type:"text",text:a.content});else if(Array.isArray(a.content))for(let b of a.content)if("text"===b.type&&b.text)c.push({type:"text",text:b.text});else if("tool_result"===b.type)c.push({type:"tool_result",tool_use_id:b.tool_use_id,content:b.content,...b.is_error&&{is_error:b.is_error}});else if("image_url"===b.type){let a=b.image_url.url,d=a.match(/^data:([^;]+);base64,(.+)$/);d?c.push({type:"image",source:{type:"base64",media_type:d[1],data:d[2]}}):(a.startsWith("http://")||a.startsWith("https://"))&&c.push({type:"image",source:{type:"url",url:a}})}else"image"===b.type&&b.source&&c.push({type:"image",source:b.source})}else if("assistant"===a.role){if(Array.isArray(a.content)){for(let b of a.content)if("text"===b.type&&b.text)c.push({type:"text",text:b.text});else if("tool_use"===b.type)c.push({type:"tool_use",id:b.id,name:b.name,input:b.input});else if("thinking"===b.type){let{cache_control:a,...d}=b;c.push(d)}}else if(a.content){let b="string"==typeof a.content?a.content:i(a.content);b&&c.push({type:"text",text:b})}if(a.tool_calls&&Array.isArray(a.tool_calls)){for(let b of a.tool_calls)if("function"===b.type){let a=""+b.function.name;c.push({type:"tool_use",id:b.id,name:a,input:function(a){if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return a}}(b.function.arguments)})}}}return c}(b,e),j=g.some(a=>"tool_use"===a.type);if(g.some(a=>"tool_result"===a.type)){let b=g.filter(a=>"tool_result"===a.type),e=g.filter(a=>"tool_result"!==a.type);f(),b.length>0&&h.messages.push({role:"user",content:b}),e.length>0&&(a=c,d.push(...e));continue}a!==c&&(f(),a=c),d.push(...g),j&&f()}f();for(let a=h.messages.length-1;a>=0;a--){let b=h.messages[a];if("assistant"===b.role&&Array.isArray(b.content)&&b.content.length>0){let a=["text","tool_use","tool_result","image"];for(let c=b.content.length-1;c>=0;c--){let d=b.content[c];if(a.includes(d.type)){d.cache_control={type:"ephemeral"};break}}break}}}if(b.response_format){let a=b.response_format;if("json_schema"===a.type&&a.json_schema?.schema){let b=JSON.stringify(a.json_schema.schema,null,2);j.push(`You must respond with valid JSON that strictly follows this JSON schema:
6
+ ${f(e.content)}`});continue}if("tool"===e.role){let a=f(e.content),d=e.tool_call_id||"",g=c.get(d)||{},i=e.name||g.name||"tool";b.push({role:"user",content:h(i,d,a)});continue}if("user"===e.role||"assistant"===e.role){if("user"===e.role&&Array.isArray(e.content)){let a=[];for(let b of e.content)if(b&&"object"==typeof b){if("text"===b.type){"string"==typeof b.text&&a.push(b.text||"");continue}if("tool_result"===b.type){let d=b.tool_use_id||"",e=c.get(d)||c.get(i(d)),g=e?.name||"tool",j=f(b.content);a.push(h(g,d,j))}}let d=a.filter(Boolean).join("\n");d&&b.push({role:"user",content:d});continue}let a=f(e.content);if("assistant"===e.role&&e.tool_calls&&e.tool_calls.length>0){let c={role:"assistant",content:a||""};c.tool_calls=e.tool_calls.map(a=>{let{index:b,...c}=a||{};return c}),b.push(c)}else if("assistant"===e.role&&Array.isArray(e.content)){let c=e.content.filter(a=>a?.type==="tool_use").map(a=>({id:a.id||"",type:"function",function:{name:a.name||"tool",arguments:JSON.stringify(a.input||{})}})).filter(a=>a.id);c.length>0?b.push({role:"assistant",content:a||"",tool_calls:c}):a&&b.push({role:"assistant",content:a})}else a&&b.push({role:e.role,content:a})}}return b}(b.messages||[]),{user:g,metadata:j,tool_choice:k,stream_options:l,system:m,...n}=b;return{...n,messages:e,max_tokens:32e3}}(0,d.kz)(e.h.OPENAI,e.h.CURSOR,j,null)},39006:a=>{a.exports={rE:"0.4.62"}},39359:(a,b,c)=>{c.r(b),c.d(b,{openaiToClaudeRequest:()=>h,openaiToClaudeRequestForAntigravity:()=>j});var d=c(26263),e=c(56790),f=c(43528),g=c(19312);function h(a,b,c){var d;let e=new Map,h={model:a,max_tokens:(0,g.M)(b),stream:c};void 0!==b.temperature&&(h.temperature=b.temperature),h.messages=[];let j=[];if(b.messages&&Array.isArray(b.messages)){let a;for(let a of b.messages)"system"===a.role&&j.push("string"==typeof a.content?a.content:i(a.content));let c=b.messages.filter(a=>"system"!==a.role),d=[],f=()=>{a&&d.length>0&&(h.messages.push({role:a,content:d}),d=[])};for(let b of c){let c="user"===b.role||"tool"===b.role?"user":"assistant",g=function(a,b=new Map){let c=[];if("tool"===a.role)c.push({type:"tool_result",tool_use_id:a.tool_call_id,content:a.content});else if("user"===a.role){if("string"==typeof a.content)a.content&&c.push({type:"text",text:a.content});else if(Array.isArray(a.content))for(let b of a.content)if("text"===b.type&&b.text)c.push({type:"text",text:b.text});else if("tool_result"===b.type)c.push({type:"tool_result",tool_use_id:b.tool_use_id,content:b.content,...b.is_error&&{is_error:b.is_error}});else if("image_url"===b.type){let a=b.image_url.url,d=a.match(/^data:([^;]+);base64,(.+)$/);d?c.push({type:"image",source:{type:"base64",media_type:d[1],data:d[2]}}):(a.startsWith("http://")||a.startsWith("https://"))&&c.push({type:"image",source:{type:"url",url:a}})}else"image"===b.type&&b.source&&c.push({type:"image",source:b.source})}else if("assistant"===a.role){if(Array.isArray(a.content)){for(let b of a.content)if("text"===b.type&&b.text)c.push({type:"text",text:b.text});else if("tool_use"===b.type)c.push({type:"tool_use",id:b.id,name:b.name,input:b.input});else if("thinking"===b.type){let{cache_control:a,...d}=b;c.push(d)}}else if(a.content){let b="string"==typeof a.content?a.content:i(a.content);b&&c.push({type:"text",text:b})}if(a.tool_calls&&Array.isArray(a.tool_calls)){for(let b of a.tool_calls)if("function"===b.type){let a=""+b.function.name;c.push({type:"tool_use",id:b.id,name:a,input:function(a){if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return a}}(b.function.arguments)})}}}return c}(b,e),j=g.some(a=>"tool_use"===a.type);if(g.some(a=>"tool_result"===a.type)){let b=g.filter(a=>"tool_result"===a.type),e=g.filter(a=>"tool_result"!==a.type);f(),b.length>0&&h.messages.push({role:"user",content:b}),e.length>0&&(a=c,d.push(...e));continue}a!==c&&(f(),a=c),d.push(...g),j&&f()}f();for(let a=h.messages.length-1;a>=0;a--){let b=h.messages[a];if("assistant"===b.role&&Array.isArray(b.content)&&b.content.length>0){let a=["text","tool_use","tool_result","image"];for(let c=b.content.length-1;c>=0;c--){let d=b.content[c];if(a.includes(d.type)){d.cache_control={type:"ephemeral"};break}}break}}}if(b.response_format){let a=b.response_format;if("json_schema"===a.type&&a.json_schema?.schema){let b=JSON.stringify(a.json_schema.schema,null,2);j.push(`You must respond with valid JSON that strictly follows this JSON schema:
7
7
  \`\`\`json
8
8
  ${b}
9
9
  \`\`\`
10
- Respond ONLY with the JSON object, no other text.`)}else"json_object"===a.type&&j.push("You must respond with valid JSON. Respond ONLY with a JSON object, no other text.")}let k={type:"text",text:f.Co};if(j.length>0?h.system=[k,{type:"text",text:j.join("\n"),cache_control:{type:"ephemeral",ttl:"1h"}}]:h.system=[k],b.tools&&Array.isArray(b.tools)){for(let a of(h.tools=[],b.tools)){let b=a.type;if(b&&"function"!==b){h.tools.push(a);continue}let c="function"===b&&a.function?a.function:a,d=c.name,f=""+d;e.set(f,d),h.tools.push({name:f,description:c.description||"",input_schema:c.parameters||c.input_schema||{type:"object",properties:{},required:[]}})}h.tools.length>0&&(h.tools[h.tools.length-1].cache_control={type:"ephemeral",ttl:"1h"})}if(b.tool_choice&&(h.tool_choice=(d=b.tool_choice)?"object"==typeof d&&d.type?d:"auto"===d||"none"===d?{type:"auto"}:"required"===d?{type:"any"}:"object"==typeof d&&d.function?{type:"tool",name:d.function.name}:{type:"auto"}:{type:"auto"}),b.thinking&&(h.thinking={type:b.thinking.type||"enabled",...b.thinking.budget_tokens&&{budget_tokens:b.thinking.budget_tokens},...b.thinking.max_tokens&&{max_tokens:b.thinking.max_tokens}}),b.reasoning_effort&&!h.thinking){let a={none:0,low:4096,medium:8192,high:16384,xhigh:32768}[b.reasoning_effort.toLowerCase()];0===a||a&&(h.thinking={type:"enabled",budget_tokens:a})}return e.size>0&&(h._toolNameMap=e),h}function i(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>"text"===a.type).map(a=>a.text).join("\n"):""}function j(a,b,c){let d=h(a,b,c);return d.system&&Array.isArray(d.system)&&(d.system=d.system.filter(a=>!a.text||!a.text.includes("You are Claude Code")),0===d.system.length&&delete d.system),d.tools&&Array.isArray(d.tools)&&(d.tools=d.tools.map(a=>a.name&&a.name.startsWith("")?{...a,name:a.name.slice(0)}:a)),d.messages&&Array.isArray(d.messages)&&(d.messages=d.messages.map(a=>{if(!a.content||!Array.isArray(a.content))return a;let b=a.content.map(a=>"tool_use"===a.type&&a.name&&a.name.startsWith("")?{...a,name:a.name.slice(0)}:a);return{...a,content:b}})),d}(0,d.kz)(e.h.OPENAI,e.h.CLAUDE,h,null)},44901:(a,b,c)=>{c.r(b),c.d(b,{antigravityToOpenAIRequest:()=>g});var d=c(26263),e=c(56790),f=c(19312);function g(a,b,c){let d=b.request||b,e={model:a,messages:[],stream:c};if(d.generationConfig){let a=d.generationConfig;if(a.maxOutputTokens){let b={max_tokens:a.maxOutputTokens,tools:d.tools};e.max_tokens=(0,f.M)(b)}if(void 0!==a.temperature&&(e.temperature=a.temperature),void 0!==a.topP&&(e.top_p=a.topP),void 0!==a.topK&&(e.top_k=a.topK),a.thinkingConfig){let b=a.thinkingConfig.thinkingBudget||0;b>0&&(b<=2048?e.reasoning_effort="low":b<=16384?e.reasoning_effort="medium":e.reasoning_effort="high")}}if(d.systemInstruction){var g;let a="string"==typeof(g=d.systemInstruction)?g:g.parts&&Array.isArray(g.parts)?g.parts.map(a=>a.text||"").join(""):"";a&&e.messages.push({role:"system",content:a})}if(d.contents&&Array.isArray(d.contents))for(let a of d.contents){let b=function(a){let b="model"===a.role?"assistant":"user"===a.role?"user":a.role;if(!a.parts||!Array.isArray(a.parts))return null;let c=[],d=[],e=[],f="";for(let b of a.parts){if(!0===b.thought&&b.text){f+=b.text;continue}if(b.thoughtSignature&&void 0!==b.text){c.push({type:"text",text:b.text});continue}void 0!==b.text&&c.push({type:"text",text:b.text}),b.inlineData&&c.push({type:"image_url",image_url:{url:`data:${b.inlineData.mimeType};base64,${b.inlineData.data}`}}),b.functionCall&&d.push({id:b.functionCall.id||`call_${Date.now()}_${Math.random().toString(36).slice(2,8)}`,type:"function",function:{name:b.functionCall.name,arguments:JSON.stringify(b.functionCall.args||{})}}),b.functionResponse&&e.push({role:"tool",tool_call_id:b.functionResponse.id||b.functionResponse.name,content:JSON.stringify(b.functionResponse.response?.result||b.functionResponse.response||{})})}if(e.length>0)return e;if(d.length>0){let a={role:"assistant"};return c.length>0&&(a.content=1===c.length&&"text"===c[0].type?c[0].text:c),f&&(a.reasoning_content=f),a.tool_calls=d,a}if(c.length>0||f){let a={role:b};return c.length>0&&(a.content=1===c.length&&"text"===c[0].type?c[0].text:c),f&&(a.reasoning_content=f),a}return null}(a);b&&(Array.isArray(b)?e.messages.push(...b):e.messages.push(b))}if(d.tools&&Array.isArray(d.tools)){for(let a of(e.tools=[],d.tools))if(a.functionDeclarations)for(let b of a.functionDeclarations)e.tools.push({type:"function",function:{name:b.name,description:b.description||"",parameters:function a(b){if(!b||"object"!=typeof b)return b;let c=Array.isArray(b)?[...b]:{...b};if("string"==typeof c.type&&(c.type=c.type.toLowerCase()),delete c.enumDescriptions,c.properties){let b={};for(let[d,e]of Object.entries(c.properties))b[d]=a(e);c.properties=b}return c.items&&(c.items=a(c.items)),c}(b.parameters)||{type:"object",properties:{}}}})}return e}(0,d.kz)(e.h.ANTIGRAVITY,e.h.OPENAI,g,null)},45070:(a,b,c)=>{c.r(b),c.d(b,{geminiToOpenAIResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;let c=a.response||a;if(!c||!c.candidates?.[0])return null;let d=[],e=c.candidates[0],f=e.content;if(b.messageId||(b.messageId=c.responseId||`msg_${Date.now()}`,b.model=c.modelVersion||"gemini",b.functionIndex=0,d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{role:"assistant"},finish_reason:null}]})),f?.parts)for(let a of f.parts){let c=a.thoughtSignature||a.thought_signature,e=!0===a.thought;if(c){let c=void 0!==a.text&&""!==a.text,f=!!a.functionCall;if(c&&d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:e?{reasoning_content:a.text}:{content:a.text},finish_reason:null}]}),f){let c=a.functionCall.name,e=b.toolNameMap?.get(c)||c,f=a.functionCall.args||{},g=b.functionIndex++,h={id:`${e}-${Date.now()}-${g}`,index:g,type:"function",function:{name:e,arguments:JSON.stringify(f)}};b.toolCalls.set(g,h),d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[h]},finish_reason:null}]})}continue}if(void 0!==a.text&&""!==a.text&&d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{content:a.text},finish_reason:null}]}),a.functionCall){let c=a.functionCall.name,e=b.toolNameMap?.get(c)||c,f=a.functionCall.args||{},g=b.functionIndex++,h={id:`${e}-${Date.now()}-${g}`,index:g,type:"function",function:{name:e,arguments:JSON.stringify(f)}};b.toolCalls.set(g,h),d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[h]},finish_reason:null}]})}let f=a.inlineData||a.inline_data;if(f?.data){let a=f.mimeType||f.mime_type||"image/png";d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{images:[{type:"image_url",image_url:{url:`data:${a};base64,${f.data}`}}]},finish_reason:null}]})}}let g=c.usageMetadata||a.usageMetadata;if(g&&"object"==typeof g){let a="number"==typeof g.cachedContentTokenCount?g.cachedContentTokenCount:0,c="number"==typeof g.promptTokenCount?g.promptTokenCount:0,d="number"==typeof g.thoughtsTokenCount?g.thoughtsTokenCount:0,e="number"==typeof g.candidatesTokenCount?g.candidatesTokenCount:0,f="number"==typeof g.totalTokenCount?g.totalTokenCount:0;0===e&&f>0&&(e=f-c-d)<0&&(e=0),b.usage={prompt_tokens:c,completion_tokens:e+d,total_tokens:f},a>0&&(b.usage.prompt_tokens_details={cached_tokens:a}),d>0&&(b.usage.completion_tokens_details={reasoning_tokens:d})}if(e.finishReason){let a=e.finishReason.toLowerCase();"stop"===a&&b.toolCalls.size>0&&(a="tool_calls");let c={id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:a}]};b.usage&&(c.usage=b.usage),d.push(c),b.finishReason=a}return d.length>0?d:null}(0,d.kz)(e.h.GEMINI,e.h.OPENAI,null,f),(0,d.kz)(e.h.GEMINI_CLI,e.h.OPENAI,null,f),(0,d.kz)(e.h.ANTIGRAVITY,e.h.OPENAI,null,f),(0,d.kz)(e.h.VERTEX,e.h.OPENAI,null,f)},52589:(a,b,c)=>{c.d(b,{$G:()=>g,bf:()=>e,n6:()=>f,xr:()=>d});let d="EpwGCkYIChgCKkCzVUuRrg7CcglSUWEef4rH6o35g9UYS8ZPe0/VomQTBsFx6sttYNj5l8GqgW6ejuHyYqpFToxIbZl0bw17l5dJEgzCnqDO0Z8fRlMrNgsaDLS1cnCjC53KBqE0CCIwAADQdo1eO+7qPAmo8J4WR3JPmr92S97kmvr5K1iPMiOpkZNj8mEXW8uzBoOJs/9ZKoMFiqHJ3UObwaJDqFOW70E9oCwDoc6jesaWVAEdN5vWfKMpIkjFJjECdjIdkxyJNJ8Ib8yXVal3qwE7uThoPRqSZDdHB5mmwPEjWE/90cSYCbtX2YsJki1265CabBb8/QEkODXg4kgRrL+c8e8rRXz/dr1RswvaPuzEdGKHRNi9UooNUeOK4/ebx1KkP9YZttyohN9GWqlts36kOoW0Cfie/ABDgF9g534BPth/sstxDM6d79QlRmh6NxizyTF74DXJI34u0M4tTRchqE5pAq85SgdJaa+dix1yJPMji8m6nZkwJbscJb9rdc2MKyKWjz8QL2+rTSSuZ2F1k1qSsW0xNcI7qLcI12Vncfn/VqY6YOIZy/saZBR0ezXvN6g+UYbuIdyVg7AyIFZt3nbrO7/kmOEb2VKzygwklHGEIJHfFgMpH3JSrAzbZIowVHOF7VaJ+KXRFDCFin7hHTOiOsdg+1ij1mML9Z/x/9CP4b7OUcaQm1llDZPSHc6rZMNL3DdB+fW5YfmNgKU35S+7AMtA10nVILzDAk1UV4T2K9Do09JlI6rjOs9UuULlIN2Z0eE8YTlANR6uQcw7lMcdfqYE8tke4rDKc2dDiaS5vVe45VewICNpdXGN11yw8QqH7p27CR1HtN30e0tHXOR3bIwWk/Yb6O5fTaKG6Ri8e5ZCPvdD9HqepVi188nM0iTjJqL58F3ni04ECIhcbyaQWnuTes1Kw4CMwiZDLQkk8Hgz7HkUOf1btQTF/0nhD7ry0n0hAEg2PaDM3V6TjOjf4hEldRmeqERcQF1PfgKb6ZM12rlIIfUqKACczWJSzTV158+47HX36o0cgux6nFlv/DE+sEiRVxgB",e="EuwGCukGAXLI2nxwZIq54WWSoL/YN0P3TsDZ7zRnLi8g0S4aVr2HUGxvaHKySuY6HAVzcE0GPGjXrytLIldxthSvfxgUlJh6Qa9Z+Oj5QZBlYdg6HaJ6yuY5R7waE6rdwBsRf7Ft2j3DJ9rMi9qhWFqApewYtPhls3VHtuvND3l8Rm09+lbAXQs6KKWEWrxNLKTBkfpMgXhRERc/TQRMZu1twAablm6/Zk1tsYRvfWKLsNbeKF+CCojJdXJKvnR/8Ouuoa+Y2Ti20hcW7aZIIjZDFYPU//k6Ybmhg69J/imbFai2ckhfLaisqdDkdoIiBJScTOUvYqP6AE9d4MsydSC+UlhIMk4hoP76R8vUSCZRMkjOaDXstf/QoVZKbt94wyRZgAJ1G0BqI8L5ow86kLpA4wJEtxsRGymOE4bKUvApveBakYDNM9APkf+LbtbzWSseGjoZcSlycF9iN8Q2XNYKRrHbv3Lr5Y8JjdH/5y/6SHkNehTEZugaeGnSPSyCTWto1kQgHpxdWmhkLfJGNUGLmue7Mesj4TSms4J33mRpYVhNB/J333FCqIP0hr/E7BkkjEn7yZ4X7SQlh+xKPurapsnHRwiKmtsilmEFrnTE9iQr+pMr6M29qqFNv1tr5yumbaJw8JW9sB15tNsRv+dW6BjNanbsKz7HCgKUBc8tGy+7YuhXzAfViyRefcjK7eZW0Fbyt7AbybJTKz78W8NH7ye6LAwzOebXpeZ4D43fNIt8bKh26qgduSQv/7o+pAflkuqHZ99YWgHQ8h8OkZFi3eOiSYjsjhdZ/czWOdoPI/OnqIldzMPF5YlrKBLFX8VhRKVmqgsmWf5PHGulHhMkVlS+XG2UIseGy69ARa93D78Gsa+1n1kJr7EEB7Rh+27vUMxVYLdz1yMSvE5nalTAlg/ZeG8+XQ0cHuAI3KbQpHW2Q++RdXfm5JzD5WdJZUU+Zn8t8UUn85BH4RxZLeE0qJikgSsKoYVBc6YhiMjhPgkR95ReimY4Z0xCJdRo1gjexOFeODZMpQF6Yxnoic7IrdgsFA3iePTbFnPp3IAM1fAThWhXJUn3QInUOTd5o1qmTmn6REbL15g/JQNl+dqUoPkhleeb2V3kjqp1okmO3wMZbPknR3S1LZNmlS72/iBQUm+n2b/RCn4PjmM2",f="CloBjz1rX5+yg1ILh/Ag+suum5k1f/9m/hI0XDQ33lsQIYnOHLn9KZwN0C7E4jgep5MzZvz5Se1Z1xxYrA1+Iz0Il4tabBhaDfMKNa5dGdEA3KnikfjfIpMlPaAKaQGPPWtf2hodPdBgguiZqDn+Qz2LwGEqHVJ16LVBUpeSx7UnYBLSwio8cyNy0jPijOh5QXKLTeHVdO2tKKcCCrtG2JCW3dOSrW2qA8eyAg40iQUnMNECjbcjkqB1+zrab7jX9ILwg7L9OgqYAQGPPWtfT4nzaPzSkXePAa920abYxPs3fg/RHDlg8PUVFLa+ko6qOjt7nXJTMxN0cpCwUCFX7eHHcMnA6vApyA/rXvJiAABkHZ3HilAktXRtxr/thHU0H8/4H5gT3kzoQcq9aMznrKomd3ct0mFi0ioSKnOEfoY1Mrfj00p/ZWm0tT7Wrjcm3BQXZ+T9Vrb94k+6CjtcEBrGCq8BAY89a1/vTMczqwB1NP3HCCuBdnds2vDXkj6XAYaXjsjmik8tGqwMKHz8R9RAWsx6SO6pkGEpXXpRzAaUx6c+aofsL/z1xOcN7ArCAa6uEeQKEgNngZuCP05p4+9P95epVmgOjFa4KfsPnyg+NKUkEFmpPSDrIRyMT+xERlclVcCI98/u7i8a9+vTbgzl8TRFYryClNH37K1ye5i6kqSGDUcMyiEasjke5BxbUh3i6wqMAgGPPWtfk+A+iY38QAldu117FEkTIkzbYOIt67lk9c6Ou3Y3Ct8TFHFw5QwGfSFc0YWjeTFHdm9UdV5jPK35p6VfhiRSva3w2+JLIHb4jvv5HutZPOJ3yQTt/+hUDj80oMNMbwnxNZvCEdzKS+D9vwmTACAm5H0ZetBSH2gPJXnhhuQo9AegS3wIWVR2a5k643Vx9r4u4pOvij4476lxKswIHvqsjL4jnTzRCvd44G6dn7vD0ENGb1K/i+dMRQMcOBaOxPN0ynk9bKxXWRDbZ+Rhakfr+y74z+6eYCdRPVqO9I7s+riilFuRIfaQ+U6/vuVKGIWEVKCfZZi0z6H5Xgz1xmse0u0AsittDlIKxwEBjz1rX783A0vehvUeabRia+/pX46IsN5efTAxFEBUeUce3jLuXIghkMV2b8KNhUs2G0aZldDDewRQbkluQabBMDT82N5I7reJP0VZgLIKccCL5DoGv1J7YWM2npLMIgZ6aP8aSlT3PFFJ0IXbUZUrzduczmIm6nzAJf9zxmq1aIFYw8YrgW8RjUdy0UvUmRoBEShSGUrvsyaRTl7J//KJW5utIPunFMu53GPWLidCFHzM1QA3Cj1+4zv5UXajP/V92RQayWbzCvYBAY89a1+yzoVSWukUGH7kX71Tg9dx7HA7OyKYwnYaqekG98zJfcUM/3KoiiiotW5t4xYu//ksEl36bSWvUHsRnxGByg+3WYdnZqKg0AtdRB/EXbI5PsjvS5ko96bkjSuFkY3TjHGwAM2B94K6/t6OTE/NBbxCsY9sT4d+1sbFv/iyfmfCnfvJaSzGmC9CDWKy4iqQ/vBNWps9j1JXk0p5uPAYC2BaMkxl5xoTVZqI3zAuRtQF5JLmPPy+PdqOgFxMKcLGNhwp7dbhIFLF68vCYQ9CL0NnK2d3CFk1UFVYxsi1TsolR1xahe/Rxt5HZDz/z65nevrQ",g="CiQBjz1rX/AlslZWMe5RgBt4Tv9j4+YNZTTez+JH2/+5oAlICygKXgGPPWtf7/Sux9eLYap/bmYAdPqFThLXj+l7o0DLu/hdgU98MA9ZrlRDNHXx+T0tuY8AcnjPZbiDyOq2bE11Fjhsk6p5axqayaapC/Pt9GczcgIQf1z15WTxCeKWAPYKYQGPPWtfDYj0nlNFNoTlU39RC91Z16xFKJ2MLEmkm+NvimsoOJ6be3g2BssNPtJ/9BKDXRA5cVs17tBeeW72lH8TMB5999udtxHM2SiUsnWsrHlfVuGSCpNQQ+5REw8HNvEKkgEBjz1rXzBNWrqZGbjun55K+vgYPBhJO2qZ67uRWXUA5/qcU12U/mbi5XoA3swoxYE8LEXfZvFFC9WG/W28QNCA0Qd4Trk/WkWiAwZmB8a84Fs14rkv3wqyxwFavPkJorqurAfd2XzGiFy0sB0ITCOPYi1HzDGV5WfXk6b9k+jT66/RuzGa8EcSOWo/QtC3Bkhgowo4AY89a1/f/tw8A02zjIoK7JVDAbf8W4UfmbApJJhwXIiGtu1M0JItObx7g2reYqT+HHL2Q/R4VDc="},56790:(a,b,c)=>{c.d(b,{h:()=>d,t:()=>e});let d={OPENAI:"openai",OPENAI_RESPONSES:"openai-responses",OPENAI_RESPONSE:"openai-response",CLAUDE:"claude",GEMINI:"gemini",GEMINI_CLI:"gemini-cli",VERTEX:"vertex",CODEX:"codex",ANTIGRAVITY:"antigravity",KIRO:"kiro",CURSOR:"cursor",OLLAMA:"ollama",COMMANDCODE:"commandcode"};function e(a,b){return a.includes("/v1/responses")?d.OPENAI_RESPONSES:a.includes("/v1/messages")?d.CLAUDE:a.includes("/v1/chat/completions")&&Array.isArray(b?.input)?d.OPENAI:null}},62970:(a,b,c)=>{c.d(b,{m:()=>d});function d(a){return"string"==typeof a?[{type:"message",role:"user",content:[{type:"input_text",text:""===a.trim()?"...":a}]}]:Array.isArray(a)?0===a.length?[{type:"message",role:"user",content:[{type:"input_text",text:"..."}]}]:a:null}},63151:(a,b,c)=>{c.r(b),c.d(b,{openaiToAntigravityResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;let c=a.choices?.[0];if(!c)return a.usage&&(b._usage=a.usage),null;let d=c.delta||{},e=c.finish_reason;b._toolCallAccum||(b._toolCallAccum={}),b._responseId||(b._responseId=a.id||`resp_${Date.now()}`),b._modelVersion||(b._modelVersion=a.model||"");let f=[];if(d.reasoning_content&&f.push({thought:!0,text:d.reasoning_content}),d.content&&f.push({text:d.content}),d.tool_calls){for(let a of d.tool_calls){let c=a.index??0;b._toolCallAccum[c]||(b._toolCallAccum[c]={id:"",name:"",arguments:""});let d=b._toolCallAccum[c];a.id&&(d.id=a.id),a.function?.name&&(d.name+=a.function.name),a.function?.arguments&&(d.arguments+=a.function.arguments)}if(0===f.length&&!e)return null}if(e)for(let a of Object.keys(b._toolCallAccum)){let c=b._toolCallAccum[a],d={};try{d=JSON.parse(c.arguments)}catch{}let e=b.toolNameMap?.get(c.name)||c.name;f.push({functionCall:{name:e,args:d}})}if(0===f.length&&!e)return null;0===f.length&&e&&f.push({text:""});let g={content:{role:"model",parts:f}};e&&(g.finishReason=({stop:"STOP",length:"MAX_TOKENS",tool_calls:"STOP",content_filter:"SAFETY"})[e]||"STOP");let h={candidates:[g],modelVersion:b._modelVersion,responseId:b._responseId},i=a.usage||b._usage;return i&&(h.usageMetadata={promptTokenCount:i.prompt_tokens||0,candidatesTokenCount:i.completion_tokens||0,totalTokenCount:i.total_tokens||0},i.completion_tokens_details?.reasoning_tokens&&(h.usageMetadata.thoughtsTokenCount=i.completion_tokens_details.reasoning_tokens),i.prompt_tokens_details?.cached_tokens&&(h.usageMetadata.cachedContentTokenCount=i.prompt_tokens_details.cached_tokens)),{response:h}}(0,d.kz)(e.h.OPENAI,e.h.ANTIGRAVITY,null,f)},66299:(a,b,c)=>{c.r(b),c.d(b,{openaiToClaudeResponse:()=>i});var d=c(26263),e=c(56790);let f="proxy_";function g(a,b){a.thinkingBlockStarted&&(b.push({type:"content_block_stop",index:a.thinkingBlockIndex}),a.thinkingBlockStarted=!1)}function h(a,b){a.textBlockStarted&&!a.textBlockClosed&&(a.textBlockClosed=!0,b.push({type:"content_block_stop",index:a.textBlockIndex}),a.textBlockStarted=!1)}function i(a,b){if(!a||!a.choices?.[0])return null;let c=[],d=a.choices[0],e=d.delta;if(a.usage&&"object"==typeof a.usage){let c="number"==typeof a.usage.prompt_tokens?a.usage.prompt_tokens:0,d="number"==typeof a.usage.completion_tokens?a.usage.completion_tokens:0,e=a.usage.prompt_tokens_details?.cached_tokens,f=a.usage.prompt_tokens_details?.cache_creation_tokens,g="number"==typeof e?e:0,h="number"==typeof f?f:0;b.usage={input_tokens:c-g-h,output_tokens:d},g>0&&(b.usage.cache_read_input_tokens=g),h>0&&(b.usage.cache_creation_input_tokens=h)}b.messageStartSent||(b.messageStartSent=!0,b.messageId=a.id?.replace("chatcmpl-","")||`msg_${Date.now()}`,(!b.messageId||"chat"===b.messageId||b.messageId.length<8)&&(b.messageId=a.extend_fields?.requestId||a.extend_fields?.traceId||`msg_${Date.now()}`),b.model=a.model||"unknown",b.nextBlockIndex=0,c.push({type:"message_start",message:{id:b.messageId,type:"message",role:"assistant",model:b.model,content:[],stop_reason:null,stop_sequence:null,usage:{input_tokens:0,output_tokens:0}}}));let i=e?.reasoning_content||e?.reasoning;if(i&&(h(b,c),b.thinkingBlockStarted||(b.thinkingBlockIndex=b.nextBlockIndex++,b.thinkingBlockStarted=!0,c.push({type:"content_block_start",index:b.thinkingBlockIndex,content_block:{type:"thinking",thinking:""}})),c.push({type:"content_block_delta",index:b.thinkingBlockIndex,delta:{type:"thinking_delta",thinking:i}})),e?.content&&(g(b,c),b.textBlockStarted||(b.textBlockIndex=b.nextBlockIndex++,b.textBlockStarted=!0,b.textBlockClosed=!1,c.push({type:"content_block_start",index:b.textBlockIndex,content_block:{type:"text",text:""}})),c.push({type:"content_block_delta",index:b.textBlockIndex,delta:{type:"text_delta",text:e.content}})),e?.tool_calls)for(let a of e.tool_calls){let d=a.index??0;if(a.id){g(b,c),h(b,c);let e=b.nextBlockIndex++;b.toolCalls.set(d,{id:a.id,name:a.function?.name||"",blockIndex:e});let i=a.function?.name||"";i.startsWith(f)&&(i=i.slice(f.length)),c.push({type:"content_block_start",index:e,content_block:{type:"tool_use",id:a.id,name:i,input:{}}})}if(a.function?.arguments){let e=b.toolCalls.get(d);e&&c.push({type:"content_block_delta",index:e.blockIndex,delta:{type:"input_json_delta",partial_json:a.function.arguments}})}}if(d.finish_reason){for(let[,a]of(g(b,c),h(b,c),b.toolCalls))c.push({type:"content_block_stop",index:a.blockIndex});b.finishReason=d.finish_reason;let a=b.usage||{input_tokens:0,output_tokens:0};c.push({type:"message_delta",delta:{stop_reason:function(a){switch(a){case"stop":default:return"end_turn";case"length":return"max_tokens";case"tool_calls":return"tool_use"}}(d.finish_reason)},usage:a}),c.push({type:"message_stop"})}return c.length>0?c:null}(0,d.kz)(e.h.OPENAI,e.h.CLAUDE,null,i)},76839:(a,b,c)=>{c.r(b),c.d(b,{claudeToOpenAIResponse:()=>g});var d=c(26263),e=c(56790);function f(a,b,c=null){return{id:`chatcmpl-${a.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:a.model,choices:[{index:0,delta:b,finish_reason:c}]}}function g(a,b){if(!a)return null;let c=[];switch(a.type){case"message_start":b.messageId=a.message?.id||`msg_${Date.now()}`,b.model=a.message?.model,b.toolCallIndex=0,c.push(f(b,{role:"assistant"}));break;case"content_block_start":{let d=a.content_block;if(d?.type==="server_tool_use"){b.serverToolBlockIndex=a.index;break}if(d?.type==="text")b.textBlockStarted=!0;else if(d?.type==="thinking")b.inThinkingBlock=!0,b.currentBlockIndex=a.index,c.push(f(b,{content:"<think>"}));else if(d?.type==="tool_use"){let e=b.toolCallIndex++,g=b.toolNameMap?.get(d.name)||d.name,h={index:e,id:d.id,type:"function",function:{name:g,arguments:""}};b.toolCalls.set(a.index,h),c.push(f(b,{tool_calls:[h]}))}break}case"content_block_delta":{if(a.index===b.serverToolBlockIndex)break;let d=a.delta;if(d?.type==="text_delta"&&d.text)c.push(f(b,{content:d.text}));else if(d?.type==="thinking_delta"&&d.thinking)c.push(f(b,{reasoning_content:d.thinking}));else if(d?.type==="input_json_delta"&&d.partial_json){let e=b.toolCalls.get(a.index);e&&(e.function.arguments+=d.partial_json,c.push(f(b,{tool_calls:[{index:e.index,id:e.id,function:{arguments:d.partial_json}}]})))}break}case"content_block_stop":if(a.index===b.serverToolBlockIndex){b.serverToolBlockIndex=-1;break}b.inThinkingBlock&&a.index===b.currentBlockIndex&&(c.push(f(b,{content:"</think>"})),b.inThinkingBlock=!1),b.textBlockStarted=!1,b.thinkingBlockStarted=!1;break;case"message_delta":if(a.usage&&"object"==typeof a.usage){let c="number"==typeof a.usage.input_tokens?a.usage.input_tokens:0,d="number"==typeof a.usage.output_tokens?a.usage.output_tokens:0,e="number"==typeof a.usage.cache_read_input_tokens?a.usage.cache_read_input_tokens:0,f="number"==typeof a.usage.cache_creation_input_tokens?a.usage.cache_creation_input_tokens:0,g=c+e+f;b.usage={prompt_tokens:g,completion_tokens:d,total_tokens:g+d,input_tokens:c,output_tokens:d},e>0&&(b.usage.cache_read_input_tokens=e),f>0&&(b.usage.cache_creation_input_tokens=f)}if(a.delta?.stop_reason){b.finishReason=function(a){switch(a){case"end_turn":case"stop_sequence":default:return"stop";case"max_tokens":return"length";case"tool_use":return"tool_calls"}}(a.delta.stop_reason);let d={id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:b.finishReason}]};if(b.usage){d.usage={prompt_tokens:b.usage.prompt_tokens,completion_tokens:b.usage.completion_tokens,total_tokens:b.usage.total_tokens};let a=b.usage.cache_read_input_tokens,c=b.usage.cache_creation_input_tokens;(a>0||c>0)&&(d.usage.prompt_tokens_details={},a>0&&(d.usage.prompt_tokens_details.cached_tokens=a),c>0&&(d.usage.prompt_tokens_details.cache_creation_tokens=c))}c.push(d),b.finishReasonSent=!0}break;case"message_stop":if(!b.finishReasonSent){let a=b.finishReason||(b.toolCalls?.size>0?"tool_calls":"stop"),d=b.usage&&"object"==typeof b.usage?{usage:{prompt_tokens:b.usage.input_tokens||0,completion_tokens:b.usage.output_tokens||0,total_tokens:(b.usage.input_tokens||0)+(b.usage.output_tokens||0)}}:{};c.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:a}],...d}),b.finishReasonSent=!0}}return c.length>0?c:null}(0,d.kz)(e.h.CLAUDE,e.h.OPENAI,null,g)},77021:(a,b,c)=>{c.r(b),c.d(b,{openaiResponsesToOpenAIRequest:()=>h,openaiToOpenAIResponsesRequest:()=>j});var d=c(26263),e=c(56790),f=c(62970);let g=a=>"string"==typeof a&&a.length>64?a.substring(0,64):a;function h(a,b,c,d){if(!b.input)return b;let e={...b};e.messages=[],b.instructions&&e.messages.push({role:"system",content:b.instructions});let g=null,h=[],j="",k=(0,f.m)(b.input);if(!k)return b;let l=a=>{if(Array.isArray(a.summary)){let b=a.summary.map(a=>a?.text||"").filter(Boolean).join("\n");if(b)return b}if(Array.isArray(a.content)){let b=a.content.map(a=>a?.text||"").filter(Boolean).join("\n");if(b)return b}return""};for(let a of k){let b=a.type||(a.role?"message":null);if("message"===b){if(g&&(e.messages.push(g),g=null),h.length>0){for(let a of h)e.messages.push(a);h=[]}let b=Array.isArray(a.content)?a.content.map(a=>"input_text"===a.type||"output_text"===a.type?{type:"text",text:a.text}:"input_image"===a.type?{type:"image_url",image_url:{url:a.image_url||a.file_id||"",detail:a.detail||"auto"}}:a):a.content,c={role:a.role,content:b};"assistant"===a.role&&j&&(c.reasoning_content=j),j="",e.messages.push(c)}else if("function_call"===b){if(!g&&(g={role:"assistant",content:null,tool_calls:[]},j&&(g.reasoning_content=j,j="")),!a.name||"string"!=typeof a.name||""===a.name.trim())continue;g.tool_calls.push({id:a.call_id,type:"function",function:{name:a.name,arguments:a.arguments}})}else if("function_call_output"===b){if(g&&(e.messages.push(g),g=null),h.length>0){for(let a of h)e.messages.push(a);h=[]}e.messages.push({role:"tool",tool_call_id:a.call_id,content:"string"==typeof a.output?a.output:JSON.stringify(a.output)})}else if("reasoning"===b){let b=l(a);b&&(j=j?`${j}
10
+ Respond ONLY with the JSON object, no other text.`)}else"json_object"===a.type&&j.push("You must respond with valid JSON. Respond ONLY with a JSON object, no other text.")}let k={type:"text",text:f.Co};if(j.length>0?h.system=[k,{type:"text",text:j.join("\n"),cache_control:{type:"ephemeral",ttl:"1h"}}]:h.system=[k],b.tools&&Array.isArray(b.tools)){for(let a of(h.tools=[],b.tools)){let b=a.type;if(b&&"function"!==b){h.tools.push(a);continue}let c="function"===b&&a.function?a.function:a,d=c.name,f=""+d;e.set(f,d),h.tools.push({name:f,description:c.description||"",input_schema:c.parameters||c.input_schema||{type:"object",properties:{},required:[]}})}h.tools.length>0&&(h.tools[h.tools.length-1].cache_control={type:"ephemeral",ttl:"1h"})}if(b.tool_choice&&(h.tool_choice=(d=b.tool_choice)?"object"==typeof d&&d.type?d:"auto"===d||"none"===d?{type:"auto"}:"required"===d?{type:"any"}:"object"==typeof d&&d.function?{type:"tool",name:d.function.name}:{type:"auto"}:{type:"auto"}),b.thinking&&(h.thinking={type:b.thinking.type||"enabled",...b.thinking.budget_tokens&&{budget_tokens:b.thinking.budget_tokens},...b.thinking.max_tokens&&{max_tokens:b.thinking.max_tokens}}),b.reasoning_effort&&!h.thinking){let a={none:0,low:4096,medium:8192,high:16384,xhigh:32768}[b.reasoning_effort.toLowerCase()];0===a||a&&(h.thinking={type:"enabled",budget_tokens:a})}return e.size>0&&(h._toolNameMap=e),h}function i(a){return"string"==typeof a?a:Array.isArray(a)?a.filter(a=>"text"===a.type).map(a=>a.text).join("\n"):""}function j(a,b,c){let d=h(a,b,c);return d.system&&Array.isArray(d.system)&&(d.system=d.system.filter(a=>!a.text||!a.text.includes("You are Claude Code")),0===d.system.length&&delete d.system),d.tools&&Array.isArray(d.tools)&&(d.tools=d.tools.map(a=>a.name&&a.name.startsWith("")?{...a,name:a.name.slice(0)}:a)),d.messages&&Array.isArray(d.messages)&&(d.messages=d.messages.map(a=>{if(!a.content||!Array.isArray(a.content))return a;let b=a.content.map(a=>"tool_use"===a.type&&a.name&&a.name.startsWith("")?{...a,name:a.name.slice(0)}:a);return{...a,content:b}})),d}(0,d.kz)(e.h.OPENAI,e.h.CLAUDE,h,null)},44901:(a,b,c)=>{c.r(b),c.d(b,{antigravityToOpenAIRequest:()=>g});var d=c(26263),e=c(56790),f=c(19312);function g(a,b,c){let d=b.request||b,e={model:a,messages:[],stream:c};if(d.generationConfig){let a=d.generationConfig;if(a.maxOutputTokens){let b={max_tokens:a.maxOutputTokens,tools:d.tools};e.max_tokens=(0,f.M)(b)}if(void 0!==a.temperature&&(e.temperature=a.temperature),void 0!==a.topP&&(e.top_p=a.topP),void 0!==a.topK&&(e.top_k=a.topK),a.thinkingConfig){let b=a.thinkingConfig.thinkingBudget||0;b>0&&(b<=2048?e.reasoning_effort="low":b<=16384?e.reasoning_effort="medium":e.reasoning_effort="high")}}if(d.systemInstruction){var g;let a="string"==typeof(g=d.systemInstruction)?g:g.parts&&Array.isArray(g.parts)?g.parts.map(a=>a.text||"").join(""):"";a&&e.messages.push({role:"system",content:a})}if(d.contents&&Array.isArray(d.contents))for(let a of d.contents){let b=function(a){let b="model"===a.role?"assistant":"user"===a.role?"user":a.role;if(!a.parts||!Array.isArray(a.parts))return null;let c=[],d=[],e=[],f="";for(let b of a.parts){if(!0===b.thought&&b.text){f+=b.text;continue}if(b.thoughtSignature&&void 0!==b.text){c.push({type:"text",text:b.text});continue}void 0!==b.text&&c.push({type:"text",text:b.text}),b.inlineData&&c.push({type:"image_url",image_url:{url:`data:${b.inlineData.mimeType};base64,${b.inlineData.data}`}}),b.functionCall&&d.push({id:b.functionCall.id||`call_${Date.now()}_${Math.random().toString(36).slice(2,8)}`,type:"function",function:{name:b.functionCall.name,arguments:JSON.stringify(b.functionCall.args||{})}}),b.functionResponse&&e.push({role:"tool",tool_call_id:b.functionResponse.id||b.functionResponse.name,content:JSON.stringify(b.functionResponse.response?.result||b.functionResponse.response||{})})}if(e.length>0)return e;if(d.length>0){let a={role:"assistant"};return c.length>0&&(a.content=1===c.length&&"text"===c[0].type?c[0].text:c),f&&(a.reasoning_content=f),a.tool_calls=d,a}if(c.length>0||f){let a={role:b};return c.length>0&&(a.content=1===c.length&&"text"===c[0].type?c[0].text:c),f&&(a.reasoning_content=f),a}return null}(a);b&&(Array.isArray(b)?e.messages.push(...b):e.messages.push(b))}if(d.tools&&Array.isArray(d.tools)){for(let a of(e.tools=[],d.tools))if(a.functionDeclarations)for(let b of a.functionDeclarations)e.tools.push({type:"function",function:{name:b.name,description:b.description||"",parameters:function a(b){if(!b||"object"!=typeof b)return b;let c=Array.isArray(b)?[...b]:{...b};if("string"==typeof c.type&&(c.type=c.type.toLowerCase()),delete c.enumDescriptions,c.properties){let b={};for(let[d,e]of Object.entries(c.properties))b[d]=a(e);c.properties=b}return c.items&&(c.items=a(c.items)),c}(b.parameters)||{type:"object",properties:{}}}})}return e}(0,d.kz)(e.h.ANTIGRAVITY,e.h.OPENAI,g,null)},45070:(a,b,c)=>{c.r(b),c.d(b,{geminiToOpenAIResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;let c=a.response||a;if(!c||!c.candidates?.[0])return null;let d=[],e=c.candidates[0],f=e.content;if(b.messageId||(b.messageId=c.responseId||`msg_${Date.now()}`,b.model=c.modelVersion||"gemini",b.functionIndex=0,d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{role:"assistant"},finish_reason:null}]})),f?.parts)for(let a of f.parts){let c=a.thoughtSignature||a.thought_signature,e=!0===a.thought;if(c){let c=void 0!==a.text&&""!==a.text,f=!!a.functionCall;if(c&&d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:e?{reasoning_content:a.text}:{content:a.text},finish_reason:null}]}),f){let c=a.functionCall.name,e=b.toolNameMap?.get(c)||c,f=a.functionCall.args||{},g=b.functionIndex++,h={id:`${e}-${Date.now()}-${g}`,index:g,type:"function",function:{name:e,arguments:JSON.stringify(f)}};b.toolCalls.set(g,h),d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[h]},finish_reason:null}]})}continue}if(void 0!==a.text&&""!==a.text&&d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{content:a.text},finish_reason:null}]}),a.functionCall){let c=a.functionCall.name,e=b.toolNameMap?.get(c)||c,f=a.functionCall.args||{},g=b.functionIndex++,h={id:`${e}-${Date.now()}-${g}`,index:g,type:"function",function:{name:e,arguments:JSON.stringify(f)}};b.toolCalls.set(g,h),d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[h]},finish_reason:null}]})}let f=a.inlineData||a.inline_data;if(f?.data){let a=f.mimeType||f.mime_type||"image/png";d.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{images:[{type:"image_url",image_url:{url:`data:${a};base64,${f.data}`}}]},finish_reason:null}]})}}let g=c.usageMetadata||a.usageMetadata;if(g&&"object"==typeof g){let a="number"==typeof g.cachedContentTokenCount?g.cachedContentTokenCount:0,c="number"==typeof g.promptTokenCount?g.promptTokenCount:0,d="number"==typeof g.thoughtsTokenCount?g.thoughtsTokenCount:0,e="number"==typeof g.candidatesTokenCount?g.candidatesTokenCount:0,f="number"==typeof g.totalTokenCount?g.totalTokenCount:0;0===e&&f>0&&(e=f-c-d)<0&&(e=0),b.usage={prompt_tokens:c,completion_tokens:e+d,total_tokens:f},a>0&&(b.usage.prompt_tokens_details={cached_tokens:a}),d>0&&(b.usage.completion_tokens_details={reasoning_tokens:d})}if(e.finishReason){let a=e.finishReason.toLowerCase();"stop"===a&&b.toolCalls.size>0&&(a="tool_calls");let c={id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:a}]};b.usage&&(c.usage=b.usage),d.push(c),b.finishReason=a}return d.length>0?d:null}(0,d.kz)(e.h.GEMINI,e.h.OPENAI,null,f),(0,d.kz)(e.h.GEMINI_CLI,e.h.OPENAI,null,f),(0,d.kz)(e.h.ANTIGRAVITY,e.h.OPENAI,null,f),(0,d.kz)(e.h.VERTEX,e.h.OPENAI,null,f)},52589:(a,b,c)=>{c.d(b,{$G:()=>g,bf:()=>e,n6:()=>f,xr:()=>d});let d="EpwGCkYIChgCKkCzVUuRrg7CcglSUWEef4rH6o35g9UYS8ZPe0/VomQTBsFx6sttYNj5l8GqgW6ejuHyYqpFToxIbZl0bw17l5dJEgzCnqDO0Z8fRlMrNgsaDLS1cnCjC53KBqE0CCIwAADQdo1eO+7qPAmo8J4WR3JPmr92S97kmvr5K1iPMiOpkZNj8mEXW8uzBoOJs/9ZKoMFiqHJ3UObwaJDqFOW70E9oCwDoc6jesaWVAEdN5vWfKMpIkjFJjECdjIdkxyJNJ8Ib8yXVal3qwE7uThoPRqSZDdHB5mmwPEjWE/90cSYCbtX2YsJki1265CabBb8/QEkODXg4kgRrL+c8e8rRXz/dr1RswvaPuzEdGKHRNi9UooNUeOK4/ebx1KkP9YZttyohN9GWqlts36kOoW0Cfie/ABDgF9g534BPth/sstxDM6d79QlRmh6NxizyTF74DXJI34u0M4tTRchqE5pAq85SgdJaa+dix1yJPMji8m6nZkwJbscJb9rdc2MKyKWjz8QL2+rTSSuZ2F1k1qSsW0xNcI7qLcI12Vncfn/VqY6YOIZy/saZBR0ezXvN6g+UYbuIdyVg7AyIFZt3nbrO7/kmOEb2VKzygwklHGEIJHfFgMpH3JSrAzbZIowVHOF7VaJ+KXRFDCFin7hHTOiOsdg+1ij1mML9Z/x/9CP4b7OUcaQm1llDZPSHc6rZMNL3DdB+fW5YfmNgKU35S+7AMtA10nVILzDAk1UV4T2K9Do09JlI6rjOs9UuULlIN2Z0eE8YTlANR6uQcw7lMcdfqYE8tke4rDKc2dDiaS5vVe45VewICNpdXGN11yw8QqH7p27CR1HtN30e0tHXOR3bIwWk/Yb6O5fTaKG6Ri8e5ZCPvdD9HqepVi188nM0iTjJqL58F3ni04ECIhcbyaQWnuTes1Kw4CMwiZDLQkk8Hgz7HkUOf1btQTF/0nhD7ry0n0hAEg2PaDM3V6TjOjf4hEldRmeqERcQF1PfgKb6ZM12rlIIfUqKACczWJSzTV158+47HX36o0cgux6nFlv/DE+sEiRVxgB",e="EuwGCukGAXLI2nxwZIq54WWSoL/YN0P3TsDZ7zRnLi8g0S4aVr2HUGxvaHKySuY6HAVzcE0GPGjXrytLIldxthSvfxgUlJh6Qa9Z+Oj5QZBlYdg6HaJ6yuY5R7waE6rdwBsRf7Ft2j3DJ9rMi9qhWFqApewYtPhls3VHtuvND3l8Rm09+lbAXQs6KKWEWrxNLKTBkfpMgXhRERc/TQRMZu1twAablm6/Zk1tsYRvfWKLsNbeKF+CCojJdXJKvnR/8Ouuoa+Y2Ti20hcW7aZIIjZDFYPU//k6Ybmhg69J/imbFai2ckhfLaisqdDkdoIiBJScTOUvYqP6AE9d4MsydSC+UlhIMk4hoP76R8vUSCZRMkjOaDXstf/QoVZKbt94wyRZgAJ1G0BqI8L5ow86kLpA4wJEtxsRGymOE4bKUvApveBakYDNM9APkf+LbtbzWSseGjoZcSlycF9iN8Q2XNYKRrHbv3Lr5Y8JjdH/5y/6SHkNehTEZugaeGnSPSyCTWto1kQgHpxdWmhkLfJGNUGLmue7Mesj4TSms4J33mRpYVhNB/J333FCqIP0hr/E7BkkjEn7yZ4X7SQlh+xKPurapsnHRwiKmtsilmEFrnTE9iQr+pMr6M29qqFNv1tr5yumbaJw8JW9sB15tNsRv+dW6BjNanbsKz7HCgKUBc8tGy+7YuhXzAfViyRefcjK7eZW0Fbyt7AbybJTKz78W8NH7ye6LAwzOebXpeZ4D43fNIt8bKh26qgduSQv/7o+pAflkuqHZ99YWgHQ8h8OkZFi3eOiSYjsjhdZ/czWOdoPI/OnqIldzMPF5YlrKBLFX8VhRKVmqgsmWf5PHGulHhMkVlS+XG2UIseGy69ARa93D78Gsa+1n1kJr7EEB7Rh+27vUMxVYLdz1yMSvE5nalTAlg/ZeG8+XQ0cHuAI3KbQpHW2Q++RdXfm5JzD5WdJZUU+Zn8t8UUn85BH4RxZLeE0qJikgSsKoYVBc6YhiMjhPgkR95ReimY4Z0xCJdRo1gjexOFeODZMpQF6Yxnoic7IrdgsFA3iePTbFnPp3IAM1fAThWhXJUn3QInUOTd5o1qmTmn6REbL15g/JQNl+dqUoPkhleeb2V3kjqp1okmO3wMZbPknR3S1LZNmlS72/iBQUm+n2b/RCn4PjmM2",f="CloBjz1rX5+yg1ILh/Ag+suum5k1f/9m/hI0XDQ33lsQIYnOHLn9KZwN0C7E4jgep5MzZvz5Se1Z1xxYrA1+Iz0Il4tabBhaDfMKNa5dGdEA3KnikfjfIpMlPaAKaQGPPWtf2hodPdBgguiZqDn+Qz2LwGEqHVJ16LVBUpeSx7UnYBLSwio8cyNy0jPijOh5QXKLTeHVdO2tKKcCCrtG2JCW3dOSrW2qA8eyAg40iQUnMNECjbcjkqB1+zrab7jX9ILwg7L9OgqYAQGPPWtfT4nzaPzSkXePAa920abYxPs3fg/RHDlg8PUVFLa+ko6qOjt7nXJTMxN0cpCwUCFX7eHHcMnA6vApyA/rXvJiAABkHZ3HilAktXRtxr/thHU0H8/4H5gT3kzoQcq9aMznrKomd3ct0mFi0ioSKnOEfoY1Mrfj00p/ZWm0tT7Wrjcm3BQXZ+T9Vrb94k+6CjtcEBrGCq8BAY89a1/vTMczqwB1NP3HCCuBdnds2vDXkj6XAYaXjsjmik8tGqwMKHz8R9RAWsx6SO6pkGEpXXpRzAaUx6c+aofsL/z1xOcN7ArCAa6uEeQKEgNngZuCP05p4+9P95epVmgOjFa4KfsPnyg+NKUkEFmpPSDrIRyMT+xERlclVcCI98/u7i8a9+vTbgzl8TRFYryClNH37K1ye5i6kqSGDUcMyiEasjke5BxbUh3i6wqMAgGPPWtfk+A+iY38QAldu117FEkTIkzbYOIt67lk9c6Ou3Y3Ct8TFHFw5QwGfSFc0YWjeTFHdm9UdV5jPK35p6VfhiRSva3w2+JLIHb4jvv5HutZPOJ3yQTt/+hUDj80oMNMbwnxNZvCEdzKS+D9vwmTACAm5H0ZetBSH2gPJXnhhuQo9AegS3wIWVR2a5k643Vx9r4u4pOvij4476lxKswIHvqsjL4jnTzRCvd44G6dn7vD0ENGb1K/i+dMRQMcOBaOxPN0ynk9bKxXWRDbZ+Rhakfr+y74z+6eYCdRPVqO9I7s+riilFuRIfaQ+U6/vuVKGIWEVKCfZZi0z6H5Xgz1xmse0u0AsittDlIKxwEBjz1rX783A0vehvUeabRia+/pX46IsN5efTAxFEBUeUce3jLuXIghkMV2b8KNhUs2G0aZldDDewRQbkluQabBMDT82N5I7reJP0VZgLIKccCL5DoGv1J7YWM2npLMIgZ6aP8aSlT3PFFJ0IXbUZUrzduczmIm6nzAJf9zxmq1aIFYw8YrgW8RjUdy0UvUmRoBEShSGUrvsyaRTl7J//KJW5utIPunFMu53GPWLidCFHzM1QA3Cj1+4zv5UXajP/V92RQayWbzCvYBAY89a1+yzoVSWukUGH7kX71Tg9dx7HA7OyKYwnYaqekG98zJfcUM/3KoiiiotW5t4xYu//ksEl36bSWvUHsRnxGByg+3WYdnZqKg0AtdRB/EXbI5PsjvS5ko96bkjSuFkY3TjHGwAM2B94K6/t6OTE/NBbxCsY9sT4d+1sbFv/iyfmfCnfvJaSzGmC9CDWKy4iqQ/vBNWps9j1JXk0p5uPAYC2BaMkxl5xoTVZqI3zAuRtQF5JLmPPy+PdqOgFxMKcLGNhwp7dbhIFLF68vCYQ9CL0NnK2d3CFk1UFVYxsi1TsolR1xahe/Rxt5HZDz/z65nevrQ",g="CiQBjz1rX/AlslZWMe5RgBt4Tv9j4+YNZTTez+JH2/+5oAlICygKXgGPPWtf7/Sux9eLYap/bmYAdPqFThLXj+l7o0DLu/hdgU98MA9ZrlRDNHXx+T0tuY8AcnjPZbiDyOq2bE11Fjhsk6p5axqayaapC/Pt9GczcgIQf1z15WTxCeKWAPYKYQGPPWtfDYj0nlNFNoTlU39RC91Z16xFKJ2MLEmkm+NvimsoOJ6be3g2BssNPtJ/9BKDXRA5cVs17tBeeW72lH8TMB5999udtxHM2SiUsnWsrHlfVuGSCpNQQ+5REw8HNvEKkgEBjz1rXzBNWrqZGbjun55K+vgYPBhJO2qZ67uRWXUA5/qcU12U/mbi5XoA3swoxYE8LEXfZvFFC9WG/W28QNCA0Qd4Trk/WkWiAwZmB8a84Fs14rkv3wqyxwFavPkJorqurAfd2XzGiFy0sB0ITCOPYi1HzDGV5WfXk6b9k+jT66/RuzGa8EcSOWo/QtC3Bkhgowo4AY89a1/f/tw8A02zjIoK7JVDAbf8W4UfmbApJJhwXIiGtu1M0JItObx7g2reYqT+HHL2Q/R4VDc="},56790:(a,b,c)=>{c.d(b,{h:()=>d,t:()=>e});let d={OPENAI:"openai",OPENAI_RESPONSES:"openai-responses",OPENAI_RESPONSE:"openai-response",CLAUDE:"claude",GEMINI:"gemini",GEMINI_CLI:"gemini-cli",VERTEX:"vertex",CODEX:"codex",ANTIGRAVITY:"antigravity",KIRO:"kiro",CURSOR:"cursor",OLLAMA:"ollama",COMMANDCODE:"commandcode"};function e(a,b){return a.includes("/v1/responses")?d.OPENAI_RESPONSES:a.includes("/v1/messages")?d.CLAUDE:a.includes("/v1/chat/completions")&&Array.isArray(b?.input)?d.OPENAI:null}},62970:(a,b,c)=>{c.d(b,{m:()=>d});function d(a){return"string"==typeof a?[{type:"message",role:"user",content:[{type:"input_text",text:""===a.trim()?"...":a}]}]:Array.isArray(a)?0===a.length?[{type:"message",role:"user",content:[{type:"input_text",text:"..."}]}]:a:null}},63151:(a,b,c)=>{c.r(b),c.d(b,{openaiToAntigravityResponse:()=>f});var d=c(26263),e=c(56790);function f(a,b){if(!a)return null;let c=a.choices?.[0];if(!c)return a.usage&&(b._usage=a.usage),null;let d=c.delta||{},e=c.finish_reason;b._toolCallAccum||(b._toolCallAccum={}),b._responseId||(b._responseId=a.id||`resp_${Date.now()}`),b._modelVersion||(b._modelVersion=a.model||"");let f=[];if(d.reasoning_content&&f.push({thought:!0,text:d.reasoning_content}),d.content&&f.push({text:d.content}),d.tool_calls){for(let a of d.tool_calls){let c=a.index??0;b._toolCallAccum[c]||(b._toolCallAccum[c]={id:"",name:"",arguments:""});let d=b._toolCallAccum[c];a.id&&(d.id=a.id),a.function?.name&&(d.name+=a.function.name),a.function?.arguments&&(d.arguments+=a.function.arguments)}if(0===f.length&&!e)return null}if(e)for(let a of Object.keys(b._toolCallAccum)){let c=b._toolCallAccum[a],d={};try{d=JSON.parse(c.arguments)}catch{}let e=b.toolNameMap?.get(c.name)||c.name;f.push({functionCall:{name:e,args:d}})}if(0===f.length&&!e)return null;0===f.length&&e&&f.push({text:""});let g={content:{role:"model",parts:f}};e&&(g.finishReason=({stop:"STOP",length:"MAX_TOKENS",tool_calls:"STOP",content_filter:"SAFETY"})[e]||"STOP");let h={candidates:[g],modelVersion:b._modelVersion,responseId:b._responseId},i=a.usage||b._usage;return i&&(h.usageMetadata={promptTokenCount:i.prompt_tokens||0,candidatesTokenCount:i.completion_tokens||0,totalTokenCount:i.total_tokens||0},i.completion_tokens_details?.reasoning_tokens&&(h.usageMetadata.thoughtsTokenCount=i.completion_tokens_details.reasoning_tokens),i.prompt_tokens_details?.cached_tokens&&(h.usageMetadata.cachedContentTokenCount=i.prompt_tokens_details.cached_tokens)),{response:h}}(0,d.kz)(e.h.OPENAI,e.h.ANTIGRAVITY,null,f)},66299:(a,b,c)=>{c.r(b),c.d(b,{openaiToClaudeResponse:()=>i});var d=c(26263),e=c(56790);let f="proxy_";function g(a,b){a.thinkingBlockStarted&&(b.push({type:"content_block_stop",index:a.thinkingBlockIndex}),a.thinkingBlockStarted=!1)}function h(a,b){a.textBlockStarted&&!a.textBlockClosed&&(a.textBlockClosed=!0,b.push({type:"content_block_stop",index:a.textBlockIndex}),a.textBlockStarted=!1)}function i(a,b){if(!a||!a.choices?.[0])return null;let c=[],d=a.choices[0],e=d.delta;if(a.usage&&"object"==typeof a.usage){let c="number"==typeof a.usage.prompt_tokens?a.usage.prompt_tokens:0,d="number"==typeof a.usage.completion_tokens?a.usage.completion_tokens:0,e=a.usage.prompt_tokens_details?.cached_tokens,f=a.usage.prompt_tokens_details?.cache_creation_tokens,g="number"==typeof e?e:0,h="number"==typeof f?f:0;b.usage={input_tokens:c-g-h,output_tokens:d},g>0&&(b.usage.cache_read_input_tokens=g),h>0&&(b.usage.cache_creation_input_tokens=h)}b.messageStartSent||(b.messageStartSent=!0,b.messageId=a.id?.replace("chatcmpl-","")||`msg_${Date.now()}`,(!b.messageId||"chat"===b.messageId||b.messageId.length<8)&&(b.messageId=a.extend_fields?.requestId||a.extend_fields?.traceId||`msg_${Date.now()}`),b.model=a.model||"unknown",b.nextBlockIndex=0,c.push({type:"message_start",message:{id:b.messageId,type:"message",role:"assistant",model:b.model,content:[],stop_reason:null,stop_sequence:null,usage:{input_tokens:0,output_tokens:0}}}));let i=e?.reasoning_content||e?.reasoning;if(i&&(h(b,c),b.thinkingBlockStarted||(b.thinkingBlockIndex=b.nextBlockIndex++,b.thinkingBlockStarted=!0,c.push({type:"content_block_start",index:b.thinkingBlockIndex,content_block:{type:"thinking",thinking:""}})),c.push({type:"content_block_delta",index:b.thinkingBlockIndex,delta:{type:"thinking_delta",thinking:i}})),e?.content&&(g(b,c),b.textBlockStarted||(b.textBlockIndex=b.nextBlockIndex++,b.textBlockStarted=!0,b.textBlockClosed=!1,c.push({type:"content_block_start",index:b.textBlockIndex,content_block:{type:"text",text:""}})),c.push({type:"content_block_delta",index:b.textBlockIndex,delta:{type:"text_delta",text:e.content}})),e?.tool_calls)for(let a of e.tool_calls){let d=a.index??0;if(a.id){g(b,c),h(b,c);let e=b.nextBlockIndex++;b.toolCalls.set(d,{id:a.id,name:a.function?.name||"",blockIndex:e});let i=a.function?.name||"";i.startsWith(f)&&(i=i.slice(f.length)),c.push({type:"content_block_start",index:e,content_block:{type:"tool_use",id:a.id,name:i,input:{}}})}a.function?.arguments&&b.toolCalls.get(d)&&(b.toolArgBuffers||(b.toolArgBuffers=new Map),b.toolArgBuffers.set(d,(b.toolArgBuffers.get(d)||"")+a.function.arguments))}if(d.finish_reason){for(let[a,d]of(g(b,c),h(b,c),b.toolCalls)){let e=b.toolArgBuffers?.get(a);if(e){let a=function(a,b){try{let c=JSON.parse(b),d=a.startsWith(f)?a.slice(f.length):a;return"Read"===d&&function(a){var b,c;"string"==typeof a.limit&&/^\d+$/.test(a.limit)&&(a.limit=Number(a.limit)),"string"==typeof a.offset&&/^-?\d+$/.test(a.offset)&&(a.offset=Number(a.offset)),"number"==typeof a.limit&&(a.limit>2e3&&(a.limit=2e3),a.limit<1&&delete a.limit),"number"==typeof a.offset&&a.offset<0&&(a.offset=0),"pages"in a&&(b=a.file_path,c=a.pages,!("string"==typeof b&&b.toLowerCase().endsWith(".pdf")&&"string"==typeof c&&/^\d+(?:-\d+)?$/.test(c)))&&delete a.pages}(c),JSON.stringify(c)}catch{return b}}(d.name,e);c.push({type:"content_block_delta",index:d.blockIndex,delta:{type:"input_json_delta",partial_json:a}})}c.push({type:"content_block_stop",index:d.blockIndex})}b.finishReason=d.finish_reason;let a=b.usage||{input_tokens:0,output_tokens:0};c.push({type:"message_delta",delta:{stop_reason:function(a){switch(a){case"stop":default:return"end_turn";case"length":return"max_tokens";case"tool_calls":return"tool_use"}}(d.finish_reason)},usage:a}),c.push({type:"message_stop"})}return c.length>0?c:null}(0,d.kz)(e.h.OPENAI,e.h.CLAUDE,null,i)},76839:(a,b,c)=>{c.r(b),c.d(b,{claudeToOpenAIResponse:()=>g});var d=c(26263),e=c(56790);function f(a,b,c=null){return{id:`chatcmpl-${a.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:a.model,choices:[{index:0,delta:b,finish_reason:c}]}}function g(a,b){if(!a)return null;let c=[];switch(a.type){case"message_start":b.messageId=a.message?.id||`msg_${Date.now()}`,b.model=a.message?.model,b.toolCallIndex=0,c.push(f(b,{role:"assistant"}));break;case"content_block_start":{let d=a.content_block;if(d?.type==="server_tool_use"){b.serverToolBlockIndex=a.index;break}if(d?.type==="text")b.textBlockStarted=!0;else if(d?.type==="thinking")b.inThinkingBlock=!0,b.currentBlockIndex=a.index,c.push(f(b,{content:"<think>"}));else if(d?.type==="tool_use"){let e=b.toolCallIndex++,g=b.toolNameMap?.get(d.name)||d.name,h={index:e,id:d.id,type:"function",function:{name:g,arguments:""}};b.toolCalls.set(a.index,h),c.push(f(b,{tool_calls:[h]}))}break}case"content_block_delta":{if(a.index===b.serverToolBlockIndex)break;let d=a.delta;if(d?.type==="text_delta"&&d.text)c.push(f(b,{content:d.text}));else if(d?.type==="thinking_delta"&&d.thinking)c.push(f(b,{reasoning_content:d.thinking}));else if(d?.type==="input_json_delta"&&d.partial_json){let e=b.toolCalls.get(a.index);e&&(e.function.arguments+=d.partial_json,c.push(f(b,{tool_calls:[{index:e.index,id:e.id,function:{arguments:d.partial_json}}]})))}break}case"content_block_stop":if(a.index===b.serverToolBlockIndex){b.serverToolBlockIndex=-1;break}b.inThinkingBlock&&a.index===b.currentBlockIndex&&(c.push(f(b,{content:"</think>"})),b.inThinkingBlock=!1),b.textBlockStarted=!1,b.thinkingBlockStarted=!1;break;case"message_delta":if(a.usage&&"object"==typeof a.usage){let c="number"==typeof a.usage.input_tokens?a.usage.input_tokens:0,d="number"==typeof a.usage.output_tokens?a.usage.output_tokens:0,e="number"==typeof a.usage.cache_read_input_tokens?a.usage.cache_read_input_tokens:0,f="number"==typeof a.usage.cache_creation_input_tokens?a.usage.cache_creation_input_tokens:0,g=c+e+f;b.usage={prompt_tokens:g,completion_tokens:d,total_tokens:g+d,input_tokens:c,output_tokens:d},e>0&&(b.usage.cache_read_input_tokens=e),f>0&&(b.usage.cache_creation_input_tokens=f)}if(a.delta?.stop_reason){b.finishReason=function(a){switch(a){case"end_turn":case"stop_sequence":default:return"stop";case"max_tokens":return"length";case"tool_use":return"tool_calls"}}(a.delta.stop_reason);let d={id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:b.finishReason}]};if(b.usage){d.usage={prompt_tokens:b.usage.prompt_tokens,completion_tokens:b.usage.completion_tokens,total_tokens:b.usage.total_tokens};let a=b.usage.cache_read_input_tokens,c=b.usage.cache_creation_input_tokens;(a>0||c>0)&&(d.usage.prompt_tokens_details={},a>0&&(d.usage.prompt_tokens_details.cached_tokens=a),c>0&&(d.usage.prompt_tokens_details.cache_creation_tokens=c))}c.push(d),b.finishReasonSent=!0}break;case"message_stop":if(!b.finishReasonSent){let a=b.finishReason||(b.toolCalls?.size>0?"tool_calls":"stop"),d=b.usage&&"object"==typeof b.usage?{usage:{prompt_tokens:b.usage.input_tokens||0,completion_tokens:b.usage.output_tokens||0,total_tokens:(b.usage.input_tokens||0)+(b.usage.output_tokens||0)}}:{};c.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{},finish_reason:a}],...d}),b.finishReasonSent=!0}}return c.length>0?c:null}(0,d.kz)(e.h.CLAUDE,e.h.OPENAI,null,g)},77021:(a,b,c)=>{c.r(b),c.d(b,{openaiResponsesToOpenAIRequest:()=>h,openaiToOpenAIResponsesRequest:()=>j});var d=c(26263),e=c(56790),f=c(62970);let g=a=>"string"==typeof a&&a.length>64?a.substring(0,64):a;function h(a,b,c,d){if(!b.input)return b;let e={...b};e.messages=[],b.instructions&&e.messages.push({role:"system",content:b.instructions});let g=null,h=[],j="",k=(0,f.m)(b.input);if(!k)return b;let l=a=>{if(Array.isArray(a.summary)){let b=a.summary.map(a=>a?.text||"").filter(Boolean).join("\n");if(b)return b}if(Array.isArray(a.content)){let b=a.content.map(a=>a?.text||"").filter(Boolean).join("\n");if(b)return b}return""};for(let a of k){let b=a.type||(a.role?"message":null);if("message"===b){if(g&&(e.messages.push(g),g=null),h.length>0){for(let a of h)e.messages.push(a);h=[]}let b=Array.isArray(a.content)?a.content.map(a=>"input_text"===a.type||"output_text"===a.type?{type:"text",text:a.text}:"input_image"===a.type?{type:"image_url",image_url:{url:a.image_url||a.file_id||"",detail:a.detail||"auto"}}:a):a.content,c={role:a.role,content:b};"assistant"===a.role&&j&&(c.reasoning_content=j),j="",e.messages.push(c)}else if("function_call"===b){if(!g&&(g={role:"assistant",content:null,tool_calls:[]},j&&(g.reasoning_content=j,j="")),!a.name||"string"!=typeof a.name||""===a.name.trim())continue;g.tool_calls.push({id:a.call_id,type:"function",function:{name:a.name,arguments:a.arguments}})}else if("function_call_output"===b){if(g&&(e.messages.push(g),g=null),h.length>0){for(let a of h)e.messages.push(a);h=[]}e.messages.push({role:"tool",tool_call_id:a.call_id,content:"string"==typeof a.output?a.output:JSON.stringify(a.output)})}else if("reasoning"===b){let b=l(a);b&&(j=j?`${j}
11
11
  ${b}`:b);continue}}if(g&&e.messages.push(g),h.length>0)for(let a of h)e.messages.push(a);return b.tools&&Array.isArray(b.tools)&&(e.tools=b.tools.map(a=>{if(a.function)return a;let b=a.name;return b&&"string"==typeof b&&""!==b.trim()?{type:"function",function:{name:b,description:String(a.description||""),parameters:i(a.parameters),strict:a.strict}}:null}).filter(Boolean)),delete e.input,delete e.instructions,delete e.include,delete e.prompt_cache_key,delete e.store,delete e.reasoning,e}function i(a){return a?"object"!==a.type||a.properties?a:{...a,properties:{}}:{type:"object",properties:{}}}function j(a,b,c,d){if(b.input)return{...b,model:a,stream:!0};let e={model:a,input:[],stream:!0,store:!1},f=!1;for(let a of b.messages||[]){if("system"===a.role){f||(e.instructions="string"==typeof a.content?a.content:"",f=!0);continue}if("user"===a.role||"assistant"===a.role){let b="user"===a.role?"input_text":"output_text",c="string"==typeof a.content?[{type:b,text:a.content}]:Array.isArray(a.content)?a.content.map(a=>{if("text"===a.type)return{type:b,text:a.text};if("image_url"===a.type)return{type:"input_image",image_url:"string"==typeof a.image_url?a.image_url:a.image_url?.url,detail:a.image_url?.detail||"auto"};if("input_image"===a.type)return a;let c=a.text||a.content||JSON.stringify(a);return{type:b,text:"string"==typeof c?c:JSON.stringify(c)}}):[];c.length>0&&e.input.push({type:"message",role:a.role,content:c})}if("assistant"===a.role&&a.tool_calls)for(let b of a.tool_calls)e.input.push({type:"function_call",call_id:g(b.id),name:b.function?.name||"_unknown",arguments:b.function?.arguments||"{}"});if("tool"===a.role){let b="string"==typeof a.content?a.content:Array.isArray(a.content)?a.content.map(a=>a.text||JSON.stringify(a)).join(""):JSON.stringify(a.content);e.input.push({type:"function_call_output",call_id:g(a.tool_call_id),output:b})}}return f||(e.instructions=""),b.tools&&Array.isArray(b.tools)&&(e.tools=b.tools.map(a=>"function"===a.type?{type:"function",name:a.function.name,description:String(a.function.description||""),parameters:i(a.function.parameters),strict:a.function.strict}:a)),void 0!==b.temperature&&(e.temperature=b.temperature),void 0!==b.max_tokens&&(e.max_tokens=b.max_tokens),void 0!==b.top_p&&(e.top_p=b.top_p),e}(0,d.kz)(e.h.OPENAI_RESPONSES,e.h.OPENAI,h,null),(0,d.kz)(e.h.OPENAI,e.h.OPENAI_RESPONSES,j,null)},78178:(a,b,c)=>{c.r(b),c.d(b,{openaiToAntigravityRequest:()=>q,openaiToGeminiCLIRequest:()=>o,openaiToGeminiRequest:()=>n});var d=c(26263),e=c(56790),f=c(52589),g=c(43528),h=c(39359),i=c(13077),j=c(20362);function k(){return crypto.randomUUID()}function l(a){if(!a)return"_unknown";let b=a.replace(/[^a-zA-Z0-9_.:\-]/g,"_");return/^[a-zA-Z_]/.test(b)||(b="_"+b),b.substring(0,64)}function m(a,b,c,d=f.bf){let e={model:a,contents:[],generationConfig:{},safetySettings:i.fc};void 0!==b.temperature&&(e.generationConfig.temperature=b.temperature),void 0!==b.top_p&&(e.generationConfig.topP=b.top_p),void 0!==b.top_k&&(e.generationConfig.topK=b.top_k),void 0!==b.max_tokens&&(e.generationConfig.maxOutputTokens=b.max_tokens);let g={};if(b.messages&&Array.isArray(b.messages)){for(let a of b.messages)if("assistant"===a.role&&a.tool_calls)for(let b of a.tool_calls)"function"===b.type&&b.id&&b.function?.name&&(g[b.id]=b.function.name)}let h={};if(b.messages&&Array.isArray(b.messages))for(let a of b.messages)"tool"===a.role&&a.tool_call_id&&(h[a.tool_call_id]=a.content);if(b.messages&&Array.isArray(b.messages))for(let a=0;a<b.messages.length;a++){let c=b.messages[a],f=c.role,j=c.content;if("system"===f&&b.messages.length>1)e.systemInstruction={role:"user",parts:[{text:"string"==typeof j?j:(0,i.kU)(j)}]};else if("user"===f||"system"===f&&1===b.messages.length){let a=(0,i.S6)(j);a.length>0&&e.contents.push({role:"user",parts:a})}else if("assistant"===f){let a=[];if(c.reasoning_content&&(a.push({thought:!0,text:c.reasoning_content}),a.push({thoughtSignature:d,text:""})),j){let b="string"==typeof j?j:(0,i.kU)(j);b&&a.push({text:b})}if(c.tool_calls&&Array.isArray(c.tool_calls)){let b=[];for(let e of c.tool_calls){if("function"!==e.type)continue;let c=(0,i.pT)(e.function?.arguments||"{}");a.push({thoughtSignature:d,functionCall:{id:e.id,name:l(e.function.name),args:c}}),b.push(e.id)}if(a.length>0&&e.contents.push({role:"model",parts:a}),b.some(a=>h[a])){let a=[];for(let c of b){if(!h[c])continue;let b=g[c];if(!b){let a=c.split("-");b=a.length>2?a.slice(0,-2).join("-"):c}let d=h[c],e=(0,i.pT)(d);null===e?e={result:d}:"object"!=typeof e&&(e={result:e}),a.push({functionResponse:{id:c,name:l(b),response:{result:e}}})}a.length>0&&e.contents.push({role:"user",parts:a})}}else a.length>0&&e.contents.push({role:"model",parts:a})}}if(b.tools&&Array.isArray(b.tools)&&b.tools.length>0){let a=[];for(let c of b.tools)if(c.name&&c.input_schema){let b=(0,i.Yr)(structuredClone(c.input_schema||{type:"object",properties:{}}));a.push({name:l(c.name),description:c.description||"",parameters:b})}else if("function"===c.type&&c.function){let b=c.function,d=(0,i.Yr)(structuredClone(b.parameters||{type:"object",properties:{}}));a.push({name:l(b.name),description:b.description||"",parameters:d})}a.length>0&&(e.tools=[{functionDeclarations:a}])}return e}function n(a,b,c){return m(a,b,c)}function o(a,b,c){let d=m(a,b,c,f.$G);if(a.toLowerCase().includes("claude"),b.reasoning_effort){let a={low:1024,medium:8192,high:32768}[b.reasoning_effort]||8192;d.generationConfig.thinkingConfig={thinkingBudget:a,include_thoughts:!0}}if(b.thinking?.type==="enabled"&&b.thinking.budget_tokens&&(d.generationConfig.thinkingConfig={thinkingBudget:b.thinking.budget_tokens,include_thoughts:!0}),d.tools?.[0]?.functionDeclarations){for(let a of d.tools[0].functionDeclarations)if(a.parameters){let b=(0,i.Yr)(a.parameters);a.parameters=b}}return d}function p(a,b,c=null,d=!1){let e={project:c?.projectId||(0,i.w_)(),model:a,userAgent:d?"antigravity":"gemini-cli",requestId:d?`agent-${k()}`:(0,i.KZ)(),request:{sessionId:d?(0,j.RF)(c?.email||c?.connectionId):(0,i.f6)(),contents:b.contents,systemInstruction:b.systemInstruction,generationConfig:b.generationConfig,tools:b.tools}};if(d){e.requestType="agent";let a=[{text:g.$V},{text:`Please ignore the following [ignore]${g.$V}[/ignore]`}];e.request.systemInstruction?.parts?e.request.systemInstruction.parts.unshift(...a):e.request.systemInstruction={role:"user",parts:a},b.tools?.length>0&&(e.request.toolConfig={functionCallingConfig:{mode:"VALIDATED"}})}else e.request.safetySettings=b.safetySettings;return e}function q(a,b,c,d=null){if(a.toLowerCase().includes("claude")){let e=(0,h.openaiToClaudeRequestForAntigravity)(a,b,c);return function(a,b,c=null){let d={project:c?.projectId||(0,i.w_)(),model:a,userAgent:"antigravity",requestId:`agent-${k()}`,requestType:"agent",request:{sessionId:(0,j.RF)(c?.email||c?.connectionId),contents:[],generationConfig:{temperature:b.temperature||1,maxOutputTokens:b.max_tokens||4096}}},e={};if(b.messages&&Array.isArray(b.messages)){for(let a of b.messages)if(Array.isArray(a.content))for(let b of a.content)"tool_use"===b.type&&b.id&&b.name&&(e[b.id]=b.name)}if(b.messages&&Array.isArray(b.messages))for(let a of b.messages){let b=[];if(Array.isArray(a.content)){for(let c of a.content)if("text"===c.type)b.push({text:c.text});else if("tool_use"===c.type)b.push({functionCall:{id:c.id,name:l(c.name),args:c.input||{}}});else if("tool_result"===c.type){let a=c.content;Array.isArray(a)&&(a=a.map(a=>"text"===a.type?a.text:JSON.stringify(a)).join("\n"));let d=e[c.tool_use_id]?l(e[c.tool_use_id]):"tool";b.push({functionResponse:{id:c.tool_use_id,name:d,response:{result:(0,i.pT)(a)||a}}})}}else"string"==typeof a.content&&b.push({text:a.content});b.length>0&&d.request.contents.push({role:"assistant"===a.role?"model":"user",parts:b})}if(b.tools&&Array.isArray(b.tools)){let a=[];for(let c of b.tools)if(c.name&&c.input_schema){let b=(0,i.Yr)(c.input_schema);a.push({name:l(c.name),description:c.description||"",parameters:b})}a.length>0&&(d.request.tools=[{functionDeclarations:a}],d.request.toolConfig={functionCallingConfig:{mode:"VALIDATED"}})}let f=[{text:g.$V},{text:`Please ignore the following [ignore]${g.$V}[/ignore]`}];if(b.system)if(Array.isArray(b.system))for(let a of b.system)a.text&&f.push({text:a.text});else"string"==typeof b.system&&f.push({text:b.system});return d.request.systemInstruction?.parts?d.request.systemInstruction.parts.unshift(...f):d.request.systemInstruction={role:"user",parts:f},d}(a,e,d)}let e=o(a,b,c);return p(a,e,d,!0)}(0,d.kz)(e.h.OPENAI,e.h.GEMINI,n,null),(0,d.kz)(e.h.OPENAI,e.h.GEMINI_CLI,(a,b,c,d)=>p(a,o(a,b,c),d),null),(0,d.kz)(e.h.OPENAI,e.h.ANTIGRAVITY,q,null)},80319:(a,b,c)=>{c.r(b),c.d(b,{convertCommandCodeToOpenAI:()=>h});var d=c(26263),e=c(56790);function f(a,b,c=null){return{id:a.responseId,object:"chat.completion.chunk",created:a.created,model:a.model,choices:[{index:0,delta:b,finish_reason:c}]}}function g(a){switch(a){case"stop":case"error":return"stop";case"length":return"length";case"tool-calls":case"tool_use":return"tool_calls";case"content-filter":return"content_filter";default:return a||"stop"}}function h(a,b){var c;if(!a)return null;if(a&&"object"==typeof a&&"chat.completion.chunk"===a.object)return a;let d=a;if("string"==typeof a){let b=a.trim();if(!b)return null;let c=b.startsWith("data:")?b.slice(5).trim():b;if(!c||"[DONE]"===c)return null;try{d=JSON.parse(c)}catch{return null}}if(!d||"object"!=typeof d||!d.type)return null;c=d.model,b.responseId||(b.responseId=`chatcmpl-${Date.now()}`,b.created=Math.floor(Date.now()/1e3),b.model=b.model||c||"commandcode",b.chunkIndex=0,b.toolIndex=0,b.toolIndexById=new Map,b.openTools=new Set,b.openText=!1,b.finishReason=null,b.usage=null);let e=[];switch(d.type){case"text-delta":{let a=d.text||d.delta||"";if(!a)break;let c=0===b.chunkIndex?{role:"assistant",content:a}:{content:a};b.chunkIndex++,b.openText=!0,e.push(f(b,c));break}case"reasoning-delta":{let a=d.text||"";if(!a)break;let c=0===b.chunkIndex?{role:"assistant",reasoning_content:a}:{reasoning_content:a};b.chunkIndex++,e.push(f(b,c));break}case"tool-input-start":{let a=d.id||d.toolCallId||`call_${Date.now()}_${b.toolIndex}`,c=b.toolIndexById.get(a);null==c&&(c=b.toolIndex++,b.toolIndexById.set(a,c)),b.openTools.add(a);let g={...0===b.chunkIndex?{role:"assistant"}:{},tool_calls:[{index:c,id:a,type:"function",function:{name:d.toolName||"",arguments:""}}]};b.chunkIndex++,e.push(f(b,g));break}case"tool-input-delta":{let a=d.id||d.toolCallId,c=b.toolIndexById.get(a);if(null==c)break;let g={tool_calls:[{index:c,function:{arguments:d.delta||d.inputTextDelta||""}}]};e.push(f(b,g));break}case"tool-call":{let a=d.toolCallId;if(b.toolIndexById.has(a))break;let c=b.toolIndex++;b.toolIndexById.set(a,c);let g="string"==typeof d.input?d.input:JSON.stringify(d.input??{}),h={...0===b.chunkIndex?{role:"assistant"}:{},tool_calls:[{index:c,id:a,type:"function",function:{name:d.toolName||"",arguments:g}}]};b.chunkIndex++,e.push(f(b,h));break}case"finish-step":b.finishReason=g(d.finishReason),d.usage&&(b.usage=d.usage);break;case"finish":{let a=b.finishReason||g(d.finishReason||"stop"),c=f(b,{},a),h=d.totalUsage||b.usage;h&&(c.usage={prompt_tokens:h.inputTokens??0,completion_tokens:h.outputTokens??0,total_tokens:h.totalTokens??(h.inputTokens??0)+(h.outputTokens??0)}),e.push(c);break}case"error":{b.finishReason="stop";let a=d.error??d.message??"unknown",c="string"==typeof a?a:JSON.stringify(a);e.push(f(b,{content:`
12
12
 
13
13
  [CommandCode error: ${c}]`})),e.push(f(b,{},"stop"))}}return e.length?e:null}(0,d.kz)(e.h.COMMANDCODE,e.h.OPENAI,null,h)},85917:(a,b,c)=>{c.r(b),c.d(b,{buildKiroPayload:()=>m});var d=c(26263),e=c(56790),f=c(37873);let g="-agentic",h="-thinking",i=`