zevairouter 1.1.65 → 1.1.66
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.
- package/CHANGELOG.md +11 -0
- package/cli/app/.next-cli-build/BUILD_ID +1 -1
- package/cli/app/.next-cli-build/app-path-routes-manifest.json +21 -21
- package/cli/app/.next-cli-build/build-manifest.json +2 -2
- package/cli/app/.next-cli-build/prerender-manifest.json +3 -3
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/automation/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/automation/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/context/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/context/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/playground/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/playground/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/settings/pricing/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/terminal/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/terminal/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.html +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.html +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cache/stats/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/changelog/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +5 -6
- package/cli/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-gateway/accounts/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/dsh-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/dsh-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/openbot-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/openbot-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/combos/[id]/route.js +3 -1
- package/cli/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/bulk/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/chat/completions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/chat/completions/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/cli-tools/keys/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/[operation]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/[operation]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/videos/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/videos/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/enable/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/health/ready/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/init/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/[id]/rotate/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/metrics/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-token/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/quota-cookie/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-token/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/quota-cookie/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-token/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/json-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/cancel/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/manual/[workerId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/latest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/zed/import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/bulk-delete/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/bulk-delete/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/cloudflare-ai/discover-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/cloudflare-ai/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy-cn/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy-intl/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/flow/import/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/flow/login/[jobId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/flow/login/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/kiro/discover-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/kiro/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/kiro/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/kiro/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/opencode/discover-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/opencode/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/openrouter/discover-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/web-login/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/route.js +3 -1
- package/cli/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/setup/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/unlock/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/input/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/resize/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/stream/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/aggregate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/aggregate/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/quota-stream/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/usage/quota-stream/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/routing-stream/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/images/generations/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/[id]/content/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/callback.html +1 -1
- package/cli/app/.next-cli-build/server/app/callback.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/!KGRhc2hib2FyZCk/dashboard/automation/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/!KGRhc2hib2FyZCk/dashboard/context/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/!KGRhc2hib2FyZCk/dashboard/playground/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/quota.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/quota.rsc +3 -3
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +3 -3
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +3 -3
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk/dashboard/settings/pricing/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/index.html +1 -1
- package/cli/app/.next-cli-build/server/app/index.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/landing.html +1 -1
- package/cli/app/.next-cli-build/server/app/landing.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/login.html +1 -1
- package/cli/app/.next-cli-build/server/app/login.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/page.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/provider-icons/[provider]/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app/skills/[skill]/SKILL.md/route.js.nft.json +1 -1
- package/cli/app/.next-cli-build/server/app-paths-manifest.json +21 -21
- package/cli/app/.next-cli-build/server/chunks/1350.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/1757.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/3190.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/3204.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/4039.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/4128.js +3 -0
- package/cli/app/.next-cli-build/server/chunks/4177.js +1 -0
- package/cli/app/.next-cli-build/server/chunks/4730.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/4827.js +1 -0
- package/cli/app/.next-cli-build/server/chunks/5024.js +51 -1
- package/cli/app/.next-cli-build/server/chunks/5330.js +12 -12
- package/cli/app/.next-cli-build/server/chunks/5626.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/5744.js +2 -0
- package/cli/app/.next-cli-build/server/chunks/7135.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/7319.js +18 -18
- package/cli/app/.next-cli-build/server/chunks/8238.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/9489.js +1 -0
- package/cli/app/.next-cli-build/server/chunks/9548.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/9618.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/9679.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/9946.js +1 -0
- package/cli/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/pages/404.html +1 -1
- package/cli/app/.next-cli-build/server/pages/500.html +1 -1
- package/cli/app/.next-cli-build/server/preview-props.json +3 -3
- package/cli/app/.next-cli-build/server/server-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/server-reference-manifest.json +1 -1
- package/cli/app/.next-cli-build/static/chunks/{620-0ce4eb71a4de4935.js → 620-7835dd9c83c5b531.js} +1 -1
- package/cli/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/{page-a0e271ee32723312.js → page-41baf67bacd12af7.js} +1 -1
- package/cli/app/CHANGELOG.md +11 -0
- package/cli/app/package.json +1 -1
- package/cli/package.json +1 -1
- package/package.json +1 -1
- package/cli/app/.next-cli-build/server/chunks/4754.js +0 -1
- package/cli/app/.next-cli-build/server/chunks/5308.js +0 -3
- package/cli/app/.next-cli-build/server/chunks/5580.js +0 -1
- package/cli/app/.next-cli-build/server/chunks/6382.js +0 -51
- package/cli/app/.next-cli-build/server/chunks/7793.js +0 -1
- package/cli/app/.next-cli-build/server/chunks/8795.js +0 -1
- /package/cli/app/.next-cli-build/static/{CAhDXqUZlelAv-gfrHZSr → 86qPSmidvodTOsnCM3oez}/_buildManifest.js +0 -0
- /package/cli/app/.next-cli-build/static/{CAhDXqUZlelAv-gfrHZSr → 86qPSmidvodTOsnCM3oez}/_ssgManifest.js +0 -0
|
@@ -1 +1,51 @@
|
|
|
1
|
-
"use strict";exports.id=5024,exports.ids=[5024],exports.modules={35024:(a,b,c)=>{c.d(b,{Ak:()=>V,Yg:()=>X,xq:()=>U});var d=c(21820),e=c(75924),f=c(71164),g=c(36942),h=c(87098),i=c(41190),j=c(17559),k=c(25433),l=c(34204),m=c(15082),n=c(90874),o=c(79875),p=c(91861),q=c(89550),r=c(42366),s=c(65551),t=c(45452),u=c(8101),v=c(34291),w=c(67854),x=c(77016),y=c(28906),z=c(31409),A=c(13215),B=c(35824),C=c(65695),D=c(30939),E=c(34245),F=c(71017),G=c(732),H=c(66583),I=c(20610),J=c(45895),K=c(80485),L=c(98357),M=c(59304),N=c(62821),O=c(30525),P=c(38484);let Q={"Anthropic-Version":"2023-06-01","Anthropic-Beta":"claude-code-20250219,interleaved-thinking-2025-05-14"},R={"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"},S="https://api.kimi.com/coding/v1/messages",T=[{format:"openai",baseUrl:"https://api.kimi.com/coding/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:S,urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...Q}},{format:"openai-responses",baseUrl:"https://api.kimi.com/coding/v1/responses",authHeader:"bearer"}],U={"alims-intl":{...h.A.transport},"alitp-intl":{...i.A.transport},agnes:{...q.A.transport},"api-airforce":{...r.A.transport},atria:{...s.A.transport},bai:{...t.A.transport},dahl:{...u.A.transport},"opencode-zen":{...v.A.transport},runcrate:{...w.A.transport},sensenova:{...x.A.transport},bedrock:{...y.A.transport},"bedrock-xai":{...z.A.transport},tokenharbor:{...A.A.transport},tokenrouter:{...B.A.transport},zed:{...C.A.transport},"codebuddy-intl":{...D.A.transport},"minimax-code":{...E.A.transport},"minimax-code-global":{...F.A.transport},"chatgpt-web":{...G.A.transport},"deepseek-web":{...H.A.transport},"gemini-web":{...I.A.transport},"muse-web":{...J.A.transport},"veoaifree-web":{...K.A.transport},"veo-free":{...K.A.transport},nous:{...L.A.transport},muse:{...M.A.transport},"qoder-cn":{...N.A.transport},"uc-web":{...O.A.transport},"nvidia-build":{...P.A.transport},baidu:{...j.A.transport},"kilo-gateway":{...l.A.transport},poolside:{...o.A.transport},tencent:{...p.A.transport},claude:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...R},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:e.Hi,"User-Agent":(0,e.cw)(),version:e.Ch},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://api3.qoder.sh/algo/api/v2/service/pro/sse/agent_chat_generation",format:"openai",headers:{}},antigravity:{baseUrls:["https://daily-cloudcode-pa.googleapis.com"],format:"antigravity",retrySameCredential429:!1,headers:{"User-Agent":(0,e.p8)()},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:{...Q},transports:[{format:"openai",baseUrl:"https://api.z.ai/api/coding/paas/v4/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.z.ai/api/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...Q}}]},"glm-cn":{baseUrl:"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",format:"openai",headers:{}},kimi:{baseUrl:S,format:"claude",headers:{...Q},transports:T},minimax:{baseUrl:"https://api.minimax.io/anthropic/v1/messages",format:"claude",headers:{...Q},quirks:{requireClaudeToolType:!0},transports:[{format:"openai",baseUrl:"https://api.minimax.io/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.minimax.io/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...Q}}]},"minimax-cn":{baseUrl:"https://api.minimaxi.com/anthropic/v1/messages",format:"claude",headers:{...Q},quirks:{requireClaudeToolType:!0},transports:[{format:"openai",baseUrl:"https://api.minimaxi.com/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.minimaxi.com/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...Q}}]},alicode:{baseUrl:"https://coding.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{},quirks:{preserveCacheControl:!0}},"alicode-intl":{baseUrl:"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{},quirks:{preserveCacheControl:!0}},"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",messagesUrl:"https://api.githubcopilot.com/v1/messages",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://runtime.us-east-1.kiro.dev/generateAssistantResponse",baseUrls:["https://runtime.us-east-1.kiro.dev/generateAssistantResponse","https://codewhisperer.us-east-1.amazonaws.com/generateAssistantResponse","https://q.us-east-1.amazonaws.com/generateAssistantResponse"],format:"kiro",retry:{502:0,503:0,504:0},retrySameCredential429:!1,refreshOnForbidden:!1,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.138","X-Amz-User-Agent":"aws-sdk-js/3.0.0 kiro-ide/1.0.138"},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.12.17"},"kimi-coding":{baseUrl:S,format:"claude",headers:{...Q},transports:T,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:{}},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",quirks:{clineEnvelope:!0}},nvidia:{baseUrl:"https://integrate.api.nvidia.com/v1/chat/completions",format:"openai"},anthropic:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...Q}},deepseek:{baseUrl:"https://api.deepseek.com/chat/completions",format:"openai",quirks:{claudeSupportedToolTypes:["web_search_20250305","web_search_20260209"]},transports:[{baseUrl:"https://api.deepseek.com/chat/completions",format:"openai"},{baseUrl:"https://api.deepseek.com/anthropic/v1/messages",format:"claude",headers:{...Q},preserveAnthropicToolTypes:!0,claudeSupportedToolTypes:["web_search_20250305","web_search_20260209"]}]},commandcode:{baseUrl:"https://api.commandcode.ai/alpha/generate",format:"commandcode",headers:{"User-Agent":"cli","x-command-code-version":"1.88.0","x-cli-environment":"production","x-cli-surface":"cli","x-taste-learning":"false"}},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-cn":{baseUrl:"https://www.codebuddy.cn/v2/chat/completions",format:"openai",headers:{"User-Agent":"CLI/2.108.1 CodeBuddy/2.108.1","X-Product":"SaaS","X-IDE-Type":"CLI","X-IDE-Name":"CLI","x-requested-with":"XMLHttpRequest","x-codebuddy-request":"1"},refreshUrl:"https://www.codebuddy.cn/v2/plugin/auth/token/refresh",domain:"www.codebuddy.cn"},opencode:{baseUrl:"https://opencode.ai",format:"openai",headers:{Authorization:"Bearer public","x-opencode-client":"cli","User-Agent":g.B},noAuth:!0,forceStream:!0,quirks:{reasoningAliasFields:!0},retrySameCredential429:!1,retry:{502:0,503:0,504:0}},"opencode-go":{baseUrl:"https://opencode.ai/zen/go/v1/chat/completions",format:"openai",transports:[{baseUrl:"https://opencode.ai/zen/go/v1/chat/completions",format:"openai",authHeader:"bearer"},{baseUrl:"https://opencode.ai/zen/go/v1/messages",format:"claude",authHeader:"x-api-key",headers:{"anthropic-version":"2023-06-01"}},{baseUrl:"https://opencode.ai/zen/go/v1/responses",format:"openai-responses",authHeader:"bearer",thinkingFormat:"openai-responses"},{baseUrl:"https://opencode.ai/inference/go/google/v1beta/models",format:"gemini",authHeader:"x-goog-api-key"}]},"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",transports:[{baseUrl:"https://api.xiaomimimo.com/v1/chat/completions",format:"openai",authHeader:"bearer"},{baseUrl:"https://api.xiaomimimo.com/anthropic/v1/messages",format:"claude",authHeader:"x-api-key",headers:{"anthropic-version":"2023-06-01"}}]},"xiaomi-tokenplan":{baseUrl:"https://token-plan-sgp.xiaomimimo.com/v1/chat/completions",format:"openai"},venice:{baseUrl:"https://api.venice.ai/api/v1/chat/completions",format:"openai"},featherless:{baseUrl:"https://api.featherless.ai/v1/chat/completions",format:"openai"},kimchi:{baseUrl:"https://llm.kimchi.dev/openai/v1/chat/completions",format:"openai",headers:{"User-Agent":"kimchi/0.1.50"}},"grok-cli":{baseUrl:"https://cli-chat-proxy.grok.com/v1/responses",format:"openai-responses",forceStream:!0,modelsUrl:"https://cli-chat-proxy.grok.com/v1/models",userUrl:"https://cli-chat-proxy.grok.com/v1/user",billingUrl:"https://cli-chat-proxy.grok.com/v1/billing",clientVersion:f.u,clientIdentifier:"grok-pager",tokenAuth:"xai-grok-cli",headers:{"User-Agent":f.f,"x-xai-token-auth":"xai-grok-cli","x-grok-client-identifier":"grok-pager","x-grok-client-version":f.u,"x-authenticateresponse":"authenticate-response"},compactionAt:4e5,usage:{url:"https://cli-chat-proxy.grok.com/v1/billing?format=credits",userUrl:"https://cli-chat-proxy.grok.com/v1/user?include=subscription"},clientId:"b1a00492-073a-47ea-816f-4c329264a828",tokenUrl:"https://auth.x.ai/oauth2/token",refreshUrl:"https://auth.x.ai/oauth2/token",retry:{429:0,502:0,503:0,504:0}},clinepass:{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"},"perplexity-agent":{baseUrl:"https://api.perplexity.ai/v1/responses",format:"openai-responses",validateUrl:"https://api.perplexity.ai/v1/models"},agentrouter:{baseUrl:"https://agentrouter.org/v1/messages",format:"claude",headers:{...R}},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:{...k.A.transport},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:{...m.A.transport},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:{...n.A.transport},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"},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 V(a){return(a?.providerSpecificData?.baseUrl?.trim()||"http://localhost:11434").replace(/\/$/,"")}let W={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 X(a){return W[a?.providerSpecificData?.region]||W.sgp}},36942:(a,b,c)=>{c.d(b,{B:()=>d});let d="opencode/latest/2.0.26/cli"},71164:(a,b,c)=>{c.d(b,{f:()=>e,u:()=>d});let d="1.0.70",e=`grok-pager/${d} grok-shell/${d} (linux; x86_64)`},75924:(a,b,c)=>{c.d(b,{A9:()=>l,Ch:()=>g,Cn:()=>m,Co:()=>v,Hi:()=>h,Ic:()=>t,NA:()=>x,P0:()=>p,Wu:()=>w,buildKimiHeaders:()=>y,cw:()=>i,dw:()=>o,go:()=>e,nZ:()=>s,p8:()=>q,rJ:()=>r,sX:()=>f,uR:()=>n,x0:()=>j,zv:()=>u});var d=c(21820);let e="google-genai-sdk/1.41.0 gl-node/v22.19.0";function f(a="unknown"){let b;return`GeminiCLI/0.34.0/${a||"unknown"} (${(0,d.platform)()}; ${"ia32"===(b=(0,d.arch)())?"x86":b}; terminal)`}let g="0.159.0",h="codex_cli_rs";function i(){return`${h}/${g}`}let j={VSCODE_VERSION:"1.110.0",COPILOT_CHAT_VERSION:"0.38.0",USER_AGENT:"GitHubCopilotChat/0.38.0",API_VERSION:"2025-04-01"};function k(){let a=(0,d.platform)(),b=(0,d.arch)();return"darwin"===a?"arm64"===b?2:1:"linux"===a?"arm64"===b?4:3:5*("win32"===a)}function l(){return`Antigravity/1.125.0 (${function(){switch((0,d.platform)()){case"darwin":return"Macintosh; Intel Mac OS X 10_15_7";case"win32":return"Windows NT 10.0; Win64; x64";default:return"X11; Linux x86_64"}}()}) Chrome/142.0.7444.175 Electron/39.2.7`}let m={ideType:9,platform:k(),pluginType:2},n="_ide",o=new Set(["Task","TaskOutput","TaskStop","TaskCreate","TaskGet","TaskUpdate","TaskList","Bash","Glob","Grep","Read","Edit","Write","NotebookEdit","WebFetch","WebSearch","AskUserQuestion","Skill","EnterPlanMode","ExitPlanMode"]);function p(){return`antigravity/cli/1.1.13 (aidev_client; os_type=${"win32"===(0,d.platform)()?"windows":(0,d.platform)()}; arch=${"x64"===(0,d.arch)()?"amd64":"ia32"===(0,d.arch)()?"x86":(0,d.arch)()}; cl=964361259; auth_method=consumer)`}function q(){return"antigravity/ide/2.1.1 darwin/arm64"}function r(a){return"string"==typeof a&&/(?:^|\/)gemini-3\.(?:7|8)(?:-|$)/i.test(a)?p():q()}q();let s={loadCodeAssist:"https://cloudcode-pa.googleapis.com/v1internal:loadCodeAssist",onboardUser:"https://cloudcode-pa.googleapis.com/v1internal:onboardUser"},t={"Content-Type":"application/json","User-Agent":"google-api-nodejs-client/9.15.1","X-Goog-Api-Client":"google-cloud-sdk vscode_cloudshelleditor/0.1","Client-Metadata":JSON.stringify({ideType:9,platform:k(),pluginType:2})},u={ideType:9,platform:k(),pluginType:2},v="You are Claude Code, Anthropic's official CLI for Claude.",w={codex:6e5,claude:144e5,iflow:864e5,qwen:12e5,codebuddy:12e5,kimi:3e5,"kimi-coding":3e5,antigravity:3e5,"grok-cli":3e5,xai:3e5},x={google:{token:"https://oauth2.googleapis.com/token",auth:"https://accounts.google.com/o/oauth2/auth"},openai:{token:"https://auth.openai.com/oauth/token",auth:"https://auth.openai.com/oauth/authorize"},anthropic:{token:"https://api.anthropic.com/v1/oauth/token",auth:"https://api.anthropic.com/v1/oauth/authorize"},qwen:{token:"https://qwen.ai/api/v1/oauth2/token",auth:"https://qwen.ai/api/v1/oauth2/device/code"},iflow:{token:"https://iflow.cn/oauth/token",auth:"https://iflow.cn/oauth"},github:{token:"https://github.com/login/oauth/access_token",auth:"https://github.com/login/oauth/authorize",deviceCode:"https://github.com/login/device/code"}};function y(a){let b="string"==typeof a&&a.trim()?a.trim():`kimi-${Date.now()}`;return{"X-Msh-Platform":"zevairouter","X-Msh-Version":"2.1.2","X-Msh-Device-Model":"u">typeof process?`${process.platform} ${process.arch}`:"unknown","X-Msh-Device-Id":b}}}};
|
|
1
|
+
"use strict";exports.id=5024,exports.ids=[5024],exports.modules={6382:(a,b,c)=>{c.d(b,{$D:()=>x,$M:()=>B,Oj:()=>g,P9:()=>s,QR:()=>j,VE:()=>o,We:()=>k,Y2:()=>m,ZF:()=>t,Zm:()=>f,aZ:()=>H,cr:()=>F,h3:()=>h,rG:()=>r,rx:()=>i,vR:()=>D,yh:()=>G});let d="-agentic",e="-thinking",f=64,g=10237,h=64,i="AmazonCodeWhispererStreamingService.GenerateAssistantResponse",j=new Set([401,403,404]);function k(a){return"google"===a||"github"===a?"arn:aws:codewhisperer:us-east-1:699475941385:profile/EHGA3GRVQMUK":"arn:aws:codewhisperer:us-east-1:638616132270:profile/AAAACCCCXXXX"}let l={minimal:512,low:1024,medium:8192,high:24576,xhigh:32768,max:128e3},m=process.env.ZEVAI_KIRO_IDE_VERSION||"1.4.154";process.env.ZEVAI_KIRO_CLI_VERSION;let n="1.0.0";function o(a){return{userAgent:`aws-sdk-js/${n} ua/2.1 os/windows#10.0.26200 lang/js md/nodejs#22.21.1 api/codewhispererruntime#${n} m/N,E KiroIDE-${m}-${a}`,amzUserAgent:`aws-sdk-js/${n} KiroIDE-${m}-${a}`}}let p=new Set(["1","true","yes","on"]),q=new Set(["0","false","no","off"]),r=`
|
|
2
|
+
# CRITICAL: CHUNKED WRITE PROTOCOL (MANDATORY)
|
|
3
|
+
|
|
4
|
+
You MUST follow these rules for ALL file operations. Violation causes server timeouts and task failure.
|
|
5
|
+
|
|
6
|
+
## ABSOLUTE LIMITS
|
|
7
|
+
- **MAXIMUM 350 LINES** per single write/edit operation - NO EXCEPTIONS
|
|
8
|
+
- **RECOMMENDED 300 LINES** or less for optimal performance
|
|
9
|
+
- **NEVER** write entire files in one operation if >300 lines
|
|
10
|
+
|
|
11
|
+
## MANDATORY CHUNKED WRITE STRATEGY
|
|
12
|
+
|
|
13
|
+
### For NEW FILES (>300 lines total):
|
|
14
|
+
1. FIRST: Write initial chunk (first 250-300 lines) using write_to_file/fsWrite
|
|
15
|
+
2. THEN: Append remaining content in 250-300 line chunks using file append operations
|
|
16
|
+
3. REPEAT: Continue appending until complete
|
|
17
|
+
|
|
18
|
+
### For EDITING EXISTING FILES:
|
|
19
|
+
1. Use surgical edits (apply_diff/targeted edits) - change ONLY what's needed
|
|
20
|
+
2. NEVER rewrite entire files - use incremental modifications
|
|
21
|
+
3. Split large refactors into multiple small, focused edits
|
|
22
|
+
|
|
23
|
+
### For LARGE CODE GENERATION:
|
|
24
|
+
1. Generate in logical sections (imports, types, functions separately)
|
|
25
|
+
2. Write each section as a separate operation
|
|
26
|
+
3. Use append operations for subsequent sections
|
|
27
|
+
|
|
28
|
+
## EXAMPLES OF CORRECT BEHAVIOR
|
|
29
|
+
|
|
30
|
+
CORRECT: Writing a 600-line file
|
|
31
|
+
- Operation 1: Write lines 1-300 (initial file creation)
|
|
32
|
+
- Operation 2: Append lines 301-600
|
|
33
|
+
|
|
34
|
+
CORRECT: Editing multiple functions
|
|
35
|
+
- Operation 1: Edit function A
|
|
36
|
+
- Operation 2: Edit function B
|
|
37
|
+
- Operation 3: Edit function C
|
|
38
|
+
|
|
39
|
+
WRONG: Writing 500 lines in single operation -> TIMEOUT
|
|
40
|
+
WRONG: Rewriting entire file to change 5 lines -> TIMEOUT
|
|
41
|
+
WRONG: Generating massive code blocks without chunking -> TIMEOUT
|
|
42
|
+
|
|
43
|
+
## WHY THIS MATTERS
|
|
44
|
+
- Server has 2-3 minute timeout for operations
|
|
45
|
+
- Large writes exceed timeout and FAIL completely
|
|
46
|
+
- Chunked writes are FASTER and more RELIABLE
|
|
47
|
+
- Failed writes waste time and require retry
|
|
48
|
+
|
|
49
|
+
REMEMBER: When in doubt, write LESS per operation. Multiple small operations > one large operation.
|
|
50
|
+
`.trim();function s(a,b,c){if(function(a){if(!a||"object"!=typeof a)return!1;let b=a.thinking;if(b&&"object"==typeof b&&"disabled"===b.type)return!0;let c=a.reasoning_effort??a.output_config?.effort??(a.reasoning&&"object"==typeof a.reasoning?a.reasoning.effort:null);return"string"==typeof c&&["none","off","disabled"].includes(c.toLowerCase())}(a))return null;let d=a?.output_config?.effort;if("string"==typeof d){let a=l[d.toLowerCase()];if(a)return a}let e=a?.thinking,f=e&&"object"==typeof e?e.type:null,g="enabled"===f||"adaptive"===f;if(g){let a=Number(e.budget_tokens);if(Number.isFinite(a)&&a>0)return a}let h=a?.reasoning_effort??(a?.reasoning&&"object"==typeof a.reasoning?a.reasoning.effort:null);if("string"==typeof h){let a=h.toLowerCase();if("auto"===a)return l.medium;let b=l[a];if(b)return b}if(g)return 16e3;if(b){let a=function(a,b){if(!a)return;if("function"==typeof a.get)return a.get(b);let c=b.toLowerCase();for(let b of Object.keys(a))if(b.toLowerCase()===c)return a[b]}(b,"anthropic-beta");if("string"==typeof a&&a.toLowerCase().includes("interleaved-thinking"))return 16e3}if(function(a){for(let b of Array.isArray(a?.messages)?a.messages:[]){if(!b||"system"!==b.role&&"user"!==b.role)continue;let a=b.content;if("string"==typeof a){if(I(a))return!0}else if(Array.isArray(a))for(let b of a){let a=b?.text;if("string"==typeof a&&I(a))return!0}}return!!("string"==typeof a?.system&&I(a.system))}(a))return 16e3;if("string"==typeof c&&c){let a=c.toLowerCase();if(a.includes("thinking")||a.includes("-reason"))return 16e3}return null}function t(a,b=!1){let c=K(J(a?.kiro_expose_reasoning,a?.kiroExposeReasoning,a?.metadata?.kiro_expose_reasoning,a?.metadata?.kiroExposeReasoning,a?.extra_body?.kiro_expose_reasoning,a?.extra_body?.kiroExposeReasoning));if(null!==c)return c;let d="u">typeof process?process.env:{},e=K(J(d.KIRO_EXPOSE_REASONING,d.ZEVAI_EXPOSE_REASONING));return null!==e?e:!0===b}function u(a){return"string"==typeof a&&a.endsWith(d)}function v(a){return"string"==typeof a&&a.endsWith(e)}let w=/-\d{8}$/;function x(a){var b,c;let f=a,g=!1,h=!1;return u(f)&&(g=!0,f=u(b=f)?b.slice(0,-d.length):b),v(f)&&(h=!0,f=v(c=f)?c.slice(0,-e.length):c),{upstream:function(a){if("string"!=typeof a||""===a)return a;let b=a.toLowerCase().replace(w,"");if(b.includes("sonnet"))return b.includes("5.5")||b.includes("5-5")?"claude-sonnet-5.5":b.includes("4.6")||b.includes("4-6")?"claude-sonnet-4.6":b.includes("sonnet-5")||b.includes("sonnet.5")?"claude-sonnet-5":b.includes("4.5")||b.includes("4-5")?"claude-sonnet-4.5":b.includes("sonnet-4")||b.includes("sonnet.4")?"claude-sonnet-4":"claude-sonnet-4.5";if(b.includes("fable"))return"claude-fable-5";if(b.includes("opus"))return b.includes("5.5")||b.includes("5-5")?"claude-opus-5.5":b.includes("opus-5")||b.includes("opus.5")||b.includes("opus 5")?"claude-opus-5":b.includes("4.8")||b.includes("4-8")?"claude-opus-4.8":b.includes("4.7")||b.includes("4-7")?"claude-opus-4.7":b.includes("4.5")||b.includes("4-5")?"claude-opus-4.5":"claude-opus-4.6";if(b.includes("haiku"))return b.includes("5.5")||b.includes("5-5")?"claude-haiku-5.5":"claude-haiku-4.5";if("auto"===b)return"auto";if("deepseek-3.2"===b||"glm-5"===b||"qwen3-coder-next"===b||"kimi-k3"===b||"minimax-m2.5"===b||"minimax-m2.1"===b||"gpt-5.6-sol"===b||"gpt-5.6-terra"===b||"gpt-5.6-luna"===b)return b;if(b.includes("gpt")){if(b.includes("terra"))return"gpt-5.6-terra";if(b.includes("luna"))return"gpt-5.6-luna";if(b.includes("sol")||b.includes("5.6")||b.includes("5-6"))return"gpt-5.6-sol"}return a}(f),agentic:g,thinking:h}}function y(a){let b=a?.output_config?.effort??a?.reasoning_effort??("object"==typeof a?.reasoning?a.reasoning.effort:null);if("string"!=typeof b)return null;let c=b.toLowerCase();return c&&"none"!==c&&"off"!==c&&"disabled"!==c?"auto"===c?"medium":c:null}function z(a){if("string"!=typeof a)return null;let b=a.toLowerCase().replace(/-/g,".").match(/(?:^|[/.])claude(?:[/.][a-z]+)*[/.](\d+)(?:[/.](\d+))?(?:[/.]|$)/);return b?{major:Number(b[1]),minor:void 0===b[2]?null:Number(b[2])}:null}function A(a){let b=z(a);return!b||4===b.major&&null!==b.minor&&b.minor<=6}function B(a){if("string"!=typeof a)return null;let b=a.toLowerCase(),c=b.includes("claude"),d=b.includes("minimax");if(!c&&!d)return null;if(c){let b=["none","low","medium","high"];return A(a)||b.push("xhigh"),b.push("max"),b}return["none","low","medium","high","xhigh"]}function C(a){let b=y(a);return b?"max"===b?"xhigh":["low","medium","high","xhigh"].includes(b)?b:null:null}function D(a,b,{force:c=!1}={}){if(!a||"object"!=typeof a||!E(b))return a;let d=a.output_config?.effort??a.reasoning_effort??("object"==typeof a.reasoning?a.reasoning.effort:null);if("string"==typeof d&&""!==d.trim())return a;let e=a.thinking?.type==="adaptive";return c||e?{...a,reasoning_effort:e?"high":"medium"}:a}function E(a){if("string"!=typeof a)return null;let b=a.toLowerCase().replace(/-/g,".");if(/(?:^|[/.])gpt[/.]5[/.]6(?:[/.]|$)/.test(b))return"reasoning";if(!b.includes("claude"))return null;let c=z(a);if(!c)return null;let{major:d,minor:e}=c;return d<4||4===d&&(null===e||e<=5||null!==e&&e>=1e3)?null:"output_config"}function F(a,b){return"reasoning"===E(b)&&null!==C(a)}function G(a,b){let c,d=E(b);if(!d)return;if("reasoning"===d){let b=C(a);return b?{reasoning:{effort:b}}:void 0}let e=(c=y(a))?"xhigh"===c?A(b)?"high":"xhigh":"max"===c?"max":["low","medium","high"].includes(c)?c:null:null;return e?{thinking:{type:"adaptive",display:"summarized"},output_config:{effort:e}}:void 0}function H(a=16e3){let b=Math.max(1,Math.min(32e3,Number(a)||16e3));return`<thinking_mode>enabled</thinking_mode>
|
|
51
|
+
<max_thinking_length>${b}</max_thinking_length>`}function I(a){return!!a&&!!a.includes("<thinking_mode>")&&(a.includes("<thinking_mode>enabled</thinking_mode>")||a.includes("<thinking_mode>interleaved</thinking_mode>"))}function J(...a){return a.find(a=>null!=a)}function K(a){if("boolean"==typeof a)return a;if("number"==typeof a)return 1===a||0!==a&&null;if("string"!=typeof a)return null;let b=a.trim().toLowerCase();return!!p.has(b)||!q.has(b)&&null}},35024:(a,b,c)=>{c.d(b,{Ak:()=>W,Yg:()=>Y,xq:()=>V});var d=c(21820),e=c(75924),f=c(6382),g=c(71164),h=c(36942),i=c(87098),j=c(41190),k=c(17559),l=c(25433),m=c(34204),n=c(15082),o=c(90874),p=c(79875),q=c(91861),r=c(89550),s=c(42366),t=c(65551),u=c(45452),v=c(8101),w=c(34291),x=c(67854),y=c(77016),z=c(28906),A=c(31409),B=c(13215),C=c(35824),D=c(65695),E=c(30939),F=c(34245),G=c(71017),H=c(732),I=c(66583),J=c(20610),K=c(45895),L=c(80485),M=c(98357),N=c(59304),O=c(62821),P=c(30525),Q=c(38484);let R={"Anthropic-Version":"2023-06-01","Anthropic-Beta":"claude-code-20250219,interleaved-thinking-2025-05-14"},S={"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"},T="https://api.kimi.com/coding/v1/messages",U=[{format:"openai",baseUrl:"https://api.kimi.com/coding/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:T,urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...R}},{format:"openai-responses",baseUrl:"https://api.kimi.com/coding/v1/responses",authHeader:"bearer"}],V={"alims-intl":{...i.A.transport},"alitp-intl":{...j.A.transport},agnes:{...r.A.transport},"api-airforce":{...s.A.transport},atria:{...t.A.transport},bai:{...u.A.transport},dahl:{...v.A.transport},"opencode-zen":{...w.A.transport},runcrate:{...x.A.transport},sensenova:{...y.A.transport},bedrock:{...z.A.transport},"bedrock-xai":{...A.A.transport},tokenharbor:{...B.A.transport},tokenrouter:{...C.A.transport},zed:{...D.A.transport},"codebuddy-intl":{...E.A.transport},"minimax-code":{...F.A.transport},"minimax-code-global":{...G.A.transport},"chatgpt-web":{...H.A.transport},"deepseek-web":{...I.A.transport},"gemini-web":{...J.A.transport},"muse-web":{...K.A.transport},"veoaifree-web":{...L.A.transport},"veo-free":{...L.A.transport},nous:{...M.A.transport},muse:{...N.A.transport},"qoder-cn":{...O.A.transport},"uc-web":{...P.A.transport},"nvidia-build":{...Q.A.transport},baidu:{...k.A.transport},"kilo-gateway":{...m.A.transport},poolside:{...p.A.transport},tencent:{...q.A.transport},claude:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...S},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:e.Hi,"User-Agent":(0,e.cw)(),version:e.Ch},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://api3.qoder.sh/algo/api/v2/service/pro/sse/agent_chat_generation",format:"openai",headers:{}},antigravity:{baseUrls:["https://daily-cloudcode-pa.googleapis.com"],format:"antigravity",retrySameCredential429:!1,headers:{"User-Agent":(0,e.p8)()},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:{...R},transports:[{format:"openai",baseUrl:"https://api.z.ai/api/coding/paas/v4/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.z.ai/api/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...R}}]},"glm-cn":{baseUrl:"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",format:"openai",headers:{}},kimi:{baseUrl:T,format:"claude",headers:{...R},transports:U},minimax:{baseUrl:"https://api.minimax.io/anthropic/v1/messages",format:"claude",headers:{...R},quirks:{requireClaudeToolType:!0},transports:[{format:"openai",baseUrl:"https://api.minimax.io/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.minimax.io/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...R}}]},"minimax-cn":{baseUrl:"https://api.minimaxi.com/anthropic/v1/messages",format:"claude",headers:{...R},quirks:{requireClaudeToolType:!0},transports:[{format:"openai",baseUrl:"https://api.minimaxi.com/v1/chat/completions",authHeader:"bearer"},{format:"claude",baseUrl:"https://api.minimaxi.com/anthropic/v1/messages",urlSuffix:"?beta=true",authHeader:"x-api-key",headers:{...R}}]},alicode:{baseUrl:"https://coding.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{},quirks:{preserveCacheControl:!0}},"alicode-intl":{baseUrl:"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions",format:"openai",headers:{},quirks:{preserveCacheControl:!0}},"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",messagesUrl:"https://api.githubcopilot.com/v1/messages",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://runtime.us-east-1.kiro.dev/generateAssistantResponse",baseUrls:["https://runtime.us-east-1.kiro.dev/generateAssistantResponse","https://codewhisperer.us-east-1.amazonaws.com/generateAssistantResponse","https://q.us-east-1.amazonaws.com/generateAssistantResponse"],format:"kiro",retry:{502:0,503:0,504:0},retrySameCredential429:!1,refreshOnForbidden:!1,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/${f.Y2}`,"X-Amz-User-Agent":`aws-sdk-js/3.0.0 kiro-ide/${f.Y2}`},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.12.17"},"kimi-coding":{baseUrl:T,format:"claude",headers:{...R},transports:U,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:{}},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",quirks:{clineEnvelope:!0}},nvidia:{baseUrl:"https://integrate.api.nvidia.com/v1/chat/completions",format:"openai"},anthropic:{baseUrl:"https://api.anthropic.com/v1/messages",format:"claude",headers:{...R}},deepseek:{baseUrl:"https://api.deepseek.com/chat/completions",format:"openai",quirks:{claudeSupportedToolTypes:["web_search_20250305","web_search_20260209"]},transports:[{baseUrl:"https://api.deepseek.com/chat/completions",format:"openai"},{baseUrl:"https://api.deepseek.com/anthropic/v1/messages",format:"claude",headers:{...R},preserveAnthropicToolTypes:!0,claudeSupportedToolTypes:["web_search_20250305","web_search_20260209"]}]},commandcode:{baseUrl:"https://api.commandcode.ai/alpha/generate",format:"commandcode",headers:{"User-Agent":"cli","x-command-code-version":"1.88.0","x-cli-environment":"production","x-cli-surface":"cli","x-taste-learning":"false"}},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-cn":{baseUrl:"https://www.codebuddy.cn/v2/chat/completions",format:"openai",headers:{"User-Agent":"CLI/2.108.1 CodeBuddy/2.108.1","X-Product":"SaaS","X-IDE-Type":"CLI","X-IDE-Name":"CLI","x-requested-with":"XMLHttpRequest","x-codebuddy-request":"1"},refreshUrl:"https://www.codebuddy.cn/v2/plugin/auth/token/refresh",domain:"www.codebuddy.cn"},opencode:{baseUrl:"https://opencode.ai",format:"openai",headers:{Authorization:"Bearer public","x-opencode-client":"cli","User-Agent":h.B},noAuth:!0,forceStream:!0,quirks:{reasoningAliasFields:!0},retrySameCredential429:!1,retry:{502:0,503:0,504:0}},"opencode-go":{baseUrl:"https://opencode.ai/zen/go/v1/chat/completions",format:"openai",transports:[{baseUrl:"https://opencode.ai/zen/go/v1/chat/completions",format:"openai",authHeader:"bearer"},{baseUrl:"https://opencode.ai/zen/go/v1/messages",format:"claude",authHeader:"x-api-key",headers:{"anthropic-version":"2023-06-01"}},{baseUrl:"https://opencode.ai/zen/go/v1/responses",format:"openai-responses",authHeader:"bearer",thinkingFormat:"openai-responses"},{baseUrl:"https://opencode.ai/inference/go/google/v1beta/models",format:"gemini",authHeader:"x-goog-api-key"}]},"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",transports:[{baseUrl:"https://api.xiaomimimo.com/v1/chat/completions",format:"openai",authHeader:"bearer"},{baseUrl:"https://api.xiaomimimo.com/anthropic/v1/messages",format:"claude",authHeader:"x-api-key",headers:{"anthropic-version":"2023-06-01"}}]},"xiaomi-tokenplan":{baseUrl:"https://token-plan-sgp.xiaomimimo.com/v1/chat/completions",format:"openai"},venice:{baseUrl:"https://api.venice.ai/api/v1/chat/completions",format:"openai"},featherless:{baseUrl:"https://api.featherless.ai/v1/chat/completions",format:"openai"},kimchi:{baseUrl:"https://llm.kimchi.dev/openai/v1/chat/completions",format:"openai",headers:{"User-Agent":"kimchi/0.1.50"}},"grok-cli":{baseUrl:"https://cli-chat-proxy.grok.com/v1/responses",format:"openai-responses",forceStream:!0,modelsUrl:"https://cli-chat-proxy.grok.com/v1/models",userUrl:"https://cli-chat-proxy.grok.com/v1/user",billingUrl:"https://cli-chat-proxy.grok.com/v1/billing",clientVersion:g.u,clientIdentifier:"grok-pager",tokenAuth:"xai-grok-cli",headers:{"User-Agent":g.f,"x-xai-token-auth":"xai-grok-cli","x-grok-client-identifier":"grok-pager","x-grok-client-version":g.u,"x-authenticateresponse":"authenticate-response"},compactionAt:4e5,usage:{url:"https://cli-chat-proxy.grok.com/v1/billing?format=credits",userUrl:"https://cli-chat-proxy.grok.com/v1/user?include=subscription"},clientId:"b1a00492-073a-47ea-816f-4c329264a828",tokenUrl:"https://auth.x.ai/oauth2/token",refreshUrl:"https://auth.x.ai/oauth2/token",retry:{429:0,502:0,503:0,504:0}},clinepass:{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"},"perplexity-agent":{baseUrl:"https://api.perplexity.ai/v1/responses",format:"openai-responses",validateUrl:"https://api.perplexity.ai/v1/models"},agentrouter:{baseUrl:"https://agentrouter.org/v1/messages",format:"claude",headers:{...S}},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:{...l.A.transport},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:{...n.A.transport},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:{...o.A.transport},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"},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 W(a){return(a?.providerSpecificData?.baseUrl?.trim()||"http://localhost:11434").replace(/\/$/,"")}let X={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 Y(a){return X[a?.providerSpecificData?.region]||X.sgp}},36942:(a,b,c)=>{c.d(b,{B:()=>d});let d="opencode/latest/2.0.26/cli"},71164:(a,b,c)=>{c.d(b,{f:()=>e,u:()=>d});let d="1.0.70",e=`grok-pager/${d} grok-shell/${d} (linux; x86_64)`},75924:(a,b,c)=>{c.d(b,{A9:()=>l,Ch:()=>g,Cn:()=>m,Co:()=>v,Hi:()=>h,Ic:()=>t,NA:()=>x,P0:()=>p,Wu:()=>w,buildKimiHeaders:()=>y,cw:()=>i,dw:()=>o,go:()=>e,nZ:()=>s,p8:()=>q,rJ:()=>r,sX:()=>f,uR:()=>n,x0:()=>j,zv:()=>u});var d=c(21820);let e="google-genai-sdk/1.41.0 gl-node/v22.19.0";function f(a="unknown"){let b;return`GeminiCLI/0.34.0/${a||"unknown"} (${(0,d.platform)()}; ${"ia32"===(b=(0,d.arch)())?"x86":b}; terminal)`}let g="0.159.0",h="codex_cli_rs";function i(){return`${h}/${g}`}let j={VSCODE_VERSION:"1.110.0",COPILOT_CHAT_VERSION:"0.38.0",USER_AGENT:"GitHubCopilotChat/0.38.0",API_VERSION:"2025-04-01"};function k(){let a=(0,d.platform)(),b=(0,d.arch)();return"darwin"===a?"arm64"===b?2:1:"linux"===a?"arm64"===b?4:3:5*("win32"===a)}function l(){return`Antigravity/1.125.0 (${function(){switch((0,d.platform)()){case"darwin":return"Macintosh; Intel Mac OS X 10_15_7";case"win32":return"Windows NT 10.0; Win64; x64";default:return"X11; Linux x86_64"}}()}) Chrome/142.0.7444.175 Electron/39.2.7`}let m={ideType:9,platform:k(),pluginType:2},n="_ide",o=new Set(["Task","TaskOutput","TaskStop","TaskCreate","TaskGet","TaskUpdate","TaskList","Bash","Glob","Grep","Read","Edit","Write","NotebookEdit","WebFetch","WebSearch","AskUserQuestion","Skill","EnterPlanMode","ExitPlanMode"]);function p(){return`antigravity/cli/1.1.13 (aidev_client; os_type=${"win32"===(0,d.platform)()?"windows":(0,d.platform)()}; arch=${"x64"===(0,d.arch)()?"amd64":"ia32"===(0,d.arch)()?"x86":(0,d.arch)()}; cl=964361259; auth_method=consumer)`}function q(){return"antigravity/ide/2.1.1 darwin/arm64"}function r(a){return"string"==typeof a&&/(?:^|\/)gemini-3\.(?:7|8)(?:-|$)/i.test(a)?p():q()}q();let s={loadCodeAssist:"https://cloudcode-pa.googleapis.com/v1internal:loadCodeAssist",onboardUser:"https://cloudcode-pa.googleapis.com/v1internal:onboardUser"},t={"Content-Type":"application/json","User-Agent":"google-api-nodejs-client/9.15.1","X-Goog-Api-Client":"google-cloud-sdk vscode_cloudshelleditor/0.1","Client-Metadata":JSON.stringify({ideType:9,platform:k(),pluginType:2})},u={ideType:9,platform:k(),pluginType:2},v="You are Claude Code, Anthropic's official CLI for Claude.",w={codex:6e5,claude:144e5,iflow:864e5,qwen:12e5,codebuddy:12e5,kimi:3e5,"kimi-coding":3e5,antigravity:3e5,"grok-cli":3e5,xai:3e5},x={google:{token:"https://oauth2.googleapis.com/token",auth:"https://accounts.google.com/o/oauth2/auth"},openai:{token:"https://auth.openai.com/oauth/token",auth:"https://auth.openai.com/oauth/authorize"},anthropic:{token:"https://api.anthropic.com/v1/oauth/token",auth:"https://api.anthropic.com/v1/oauth/authorize"},qwen:{token:"https://qwen.ai/api/v1/oauth2/token",auth:"https://qwen.ai/api/v1/oauth2/device/code"},iflow:{token:"https://iflow.cn/oauth/token",auth:"https://iflow.cn/oauth"},github:{token:"https://github.com/login/oauth/access_token",auth:"https://github.com/login/oauth/authorize",deviceCode:"https://github.com/login/device/code"}};function y(a){let b="string"==typeof a&&a.trim()?a.trim():`kimi-${Date.now()}`;return{"X-Msh-Platform":"zevairouter","X-Msh-Version":"2.1.2","X-Msh-Device-Model":"u">typeof process?`${process.platform} ${process.arch}`:"unknown","X-Msh-Device-Id":b}}}};
|
|
@@ -286,33 +286,33 @@ ${e}`),j.join("\n\n")}(y),A=y.some(a=>"user"===a.role&&"string"==typeof a.conten
|
|
|
286
286
|
|
|
287
287
|
`)),b.enqueue(a.encode(e.$U)),b.close()}catch(c){b.enqueue(a.encode(`data: ${JSON.stringify({error:{message:c.message||"gemini-web stream failed"}})}
|
|
288
288
|
|
|
289
|
-
`)),b.enqueue(a.encode(e.$U)),b.close()}finally{await l.close().catch(()=>{}),await d.close().catch(()=>{});let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(f)}}},{highWaterMark:16384});return{response:new Response(g,{status:200,headers:{...e.uB}}),url:D,headers:{},transformedBody:b}}let s=await x({page:l,baseCount:o.count,baseText:o.lastText,signal:h});return{response:new Response(JSON.stringify(G(s,B)),{status:200,headers:{"Content-Type":"application/json"}}),url:D,headers:{},transformedBody:b}}catch(c){let a=c instanceof Error?c.message:"Unknown error";if((0,f.BE)(a))return{response:R(503,"Gemini Web needs a Chrome/Chromium binary. Install Google Chrome, set ZEVAI_BROWSER_BIN or CHROME_PATH to an existing Chrome, or run `npx playwright-core install chromium`."),url:D,headers:{},transformedBody:b};if(c instanceof Error&&("TimeoutError"===c.name||a.includes("waitForSelector")||a.includes("Timeout")||a.includes("actionability")||a.includes("interception")))return{response:R(400,a),url:D,headers:{},transformedBody:b};return{response:R(500,a),url:D,headers:{},transformedBody:b}}finally{K&&h?.removeEventListener("abort",K);try{await J?.close()}catch{}if(C){let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(C)}}}async generateMedia({prompt:a,n:b=1,size:d,credentials:e,signal:f,log:g}){if(!a)throw Error("prompt is required for image generation");let h=Q(e);if(!h)throw Error("Missing Gemini cookies");let j=[];for(let e=0;e<Math.max(1,b);e++){let b=null,e=null;try{let{acquireGeminiBrowser:g}=await c.e(2126).then(c.bind(c,69745));b=await g(F),e=await b.newContext({userAgent:E}),await e.addCookies((0,i.EU)(h,".google.com"));let k=await e.newPage(),l=await M(k),m=await N(k,l);await m.click(),await k.keyboard.insertText(function(a,b){let c=b?` (aspect ratio ${b})`:"";return`Generate an image${c}: ${a}`}(a,d)),await k.waitForTimeout(300),await k.keyboard.press("Enter");let n=await C(k,{signal:f});j.push(n)}finally{try{await e?.close()}catch{}if(b){let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(b)}}}return j}}},29675:(a,b,c)=>{"use strict";c.d(b,{P:()=>h});var d=c(86871),e=c(14170),f=c(4305);function g(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 h(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,a.message?.usage&&"object"==typeof a.message.usage&&(b.startUsage=a.message.usage),c.push(g(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;else if(d?.type==="tool_use"){let e=b.toolCallIndex++,f=b.toolNameMap?.get(d.name)||d.name,h={index:e,id:d.id,type:"function",function:{name:f,arguments:""}};b.toolCalls.set(a.index,h),c.push(g(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(g(b,{content:d.text}));else if(d?.type==="thinking_delta"&&d.thinking)c.push(g(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(g(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&&(b.inThinkingBlock=!1),b.textBlockStarted=!1,b.thinkingBlockStarted=!1;break;case"message_delta":if(a.usage&&"object"==typeof a.usage){let c={...b.startUsage||{},...a.usage},d="number"==typeof c.input_tokens?c.input_tokens:0,e="number"==typeof c.output_tokens?c.output_tokens:0,f="number"==typeof c.cache_read_input_tokens?c.cache_read_input_tokens:0,g="number"==typeof c.cache_creation_input_tokens?c.cache_creation_input_tokens:0,h=d+f+g;b.usage={prompt_tokens:h,completion_tokens:e,total_tokens:h+e,input_tokens:d,output_tokens:e},f>0&&(b.usage.cache_read_input_tokens=f),g>0&&(b.usage.cache_creation_input_tokens=g)}if(a.delta?.stop_reason){var d;d=a.delta.stop_reason,b.finishReason=(0,f.Jm)(d);let e="refusal"===a.delta.stop_reason&&a.delta.stop_details?.explanation;e&&c.push(g(b,{content:e}));let h={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){h.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)&&(h.usage.prompt_tokens_details={},a>0&&(h.usage.prompt_tokens_details.cached_tokens=a),c>0&&(h.usage.prompt_tokens_details.cache_creation_tokens=c))}c.push(h),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,h)},29994:(a,b,c)=>{"use strict";c.d(b,{D:()=>h});let d=/claude-opus-5(?:\.5|-5)(?:-|$)/i,e=/claude-sonnet-5(?:\.5|-5)(?:-|$)/i,f=/claude-haiku-5(?:\.5|-5)(?:-|$)/i;function g(a){if(!a||"object"!=typeof a)return;let b={...a};return delete b.effort,Object.keys(b).length?b:void 0}function h(a,b){if(!b||"object"!=typeof b)return b;let c=String(a||b.model||""),h={...b,...b.thinking&&"object"==typeof b.thinking?{thinking:{...b.thinking}}:{},...b.output_config&&"object"==typeof b.output_config?{output_config:{...b.output_config}}:{},...b.tool_choice&&"object"==typeof b.tool_choice?{tool_choice:{...b.tool_choice}}:{}};if(function(a){if(!/haiku/i.test(a||""))return!1;let b=String(a).match(/haiku[-._]?(\d+)|(?<![\d.])(\d+)(?:[-._]\d+)?[-._]?haiku/i);return!b||5>Number(b[1]||b[2])}(c)){h.thinking?.type==="adaptive"&&(h.thinking={type:"enabled",budget_tokens:1e4});let a=g(h.output_config);return a?h.output_config=a:delete h.output_config,h}if(f.test(c)){let a=h.thinking;if(a?.type==="enabled"||a?.type==="adaptive"){let b,c={type:"adaptive"};"string"==typeof a.display&&a.display&&(c.display=a.display),h.thinking=c,h.output_config={...h.output_config||{},effort:h.output_config?.effort||(4096===(b=Number(a.budget_tokens))?"low":8e3===b||8192===b?"medium":16384===b?"high":32768===b?"xhigh":!Number.isFinite(b)||b<=0?"high":b<=4096?"low":b<=16384?"medium":"high")}}else if(a?.type==="disabled"){h.thinking={type:"disabled"};let a=g(h.output_config);a?h.output_config=a:delete h.output_config}return h}if(!d.test(c)&&!e.test(c))return b;if(h.tool_choice?.type==="any"||h.tool_choice?.type==="tool"){let a=h.tool_choice.disable_parallel_tool_use;h.tool_choice={type:"auto",...void 0!==a?{disable_parallel_tool_use:a}:{}}}return h.thinking?.type!=="disabled"||(d.test(c)?(delete h.thinking,h.output_config={...h.output_config||{},effort:"low"}):h.thinking={type:"between_tools"}),h}},30364:(a,b,c)=>{"use strict";c.d(b,{s:()=>e});var d=c(24);function e(a,b,c){return a&&"object"==typeof a&&c&&!1===(0,d.nl)(b,c).thinkingCanDisable&&(a.thinking?.type==="disabled"&&delete a.thinking,!1===a.enable_thinking&&delete a.enable_thinking),a}},32213:(a,b,c)=>{"use strict";c.d(b,{Br:()=>L});var d=c(74957),e=c(35024),f=c(47293),g=c(12025),h=c(39609),i=c(328),j=c(59657),k=c(41004),l=c(66682),m=c(6382),n=c(8658),o=c(51455),p=c(48161),q=c(76760),r=c(77598);let s=new Map;function t(a,{now:b=Date.now()}={}){return s.set(a,{verifiedUntil:b+9e5,cleanProbes:0,probeInFlight:!1}),"verified"}function u(a,{now:b=Date.now()}={}){let c=s.get(a);return c?c.probeInFlight?(c.probeInFlight=!1,c.cleanProbes+=1,c.cleanProbes>=5)?(s.delete(a),"live"):(c.verifiedUntil=b,"verified"):"verified":"live"}function v(a,{now:b=Date.now()}={}){let c=s.get(a);c?.probeInFlight&&(c.probeInFlight=!1,c.verifiedUntil=Math.min(c.verifiedUntil,b))}var w=c(66014);let{createTaggedThinkingState:x,flushTaggedThinking:y,pushTaggedThinking:z}=(c.n(w))();function A(...a){for(let b of a)if(("string"==typeof b||"number"==typeof b)&&String(b).trim())return String(b).trim();return""}function B(...a){for(let b of a){if("string"!=typeof b&&"number"!=typeof b)continue;let a=String(b).trim();if(/^[A-Za-z0-9_.:#/-]{1,200}$/.test(a)&&!(/^aor[A-Za-z0-9._~+/=-]{8,}$/.test(a)||/^eyJ[A-Za-z0-9_-]{8,}\./.test(a)))return a}return null}function C(a,b){let c=a?.headers;if(!c)return null;if("function"==typeof c.get)return c.get(b);let d=Object.entries(c).find(([a])=>a.toLowerCase()===b.toLowerCase());return d?.[1]??null}function D(a,b){return E(a,b)[0]??null}function E(a,b){if(!a||"object"!=typeof a)return[];let c=new Set(b.map(a=>a.toLowerCase())),d=[{value:a,depth:0}],e=new Set,f=[];for(;d.length>0&&e.size<64;){let{value:a,depth:b}=d.shift();if(!(!a||"object"!=typeof a||e.has(a)))for(let[g,h]of(e.add(a),Object.entries(a)))c.has(g.toLowerCase())&&null!=h&&""!==h&&f.push(h),b<3&&h&&"object"==typeof h&&d.push({value:h,depth:b+1})}return f}function F(a){return a&&"object"==typeof a?[...new Set(E(a,["reason","code","errorCode","type","__type","status"]).map(a=>B(a)).filter(Boolean))]:[]}function G(a,b){if(null==a||""===a)return null;let c="number"==typeof a?a:Number(String(a).trim());if(Number.isFinite(c)){let a=c>=1e12?c:c>=1e9?1e3*c:null;return a&&a>b?Math.round(a):null}let d=Date.parse(String(a));return Number.isFinite(d)&&d>b?d:null}function H(a,b){if(null==a||""===a)return null;let c=String(a).trim().toLowerCase().match(/^(\d+(?:\.\d+)?)\s*(ms|s|m|h)?$/);if(!c)return null;let d=Number(c[1]);return!Number.isFinite(d)||d<=0?null:b+Math.round(d*("ms"===c[2]?1:"m"===c[2]?6e4:"h"===c[2]?36e5:1e3))}function I(a,b="KIRO_STREAM_PROTOCOL_ERROR",c="Kiro upstream returned an invalid event stream"){let d=/^(?:AWS_EVENTSTREAM|KIRO_STREAM|KIRO_VERIFIED)_[A-Z0-9_]+$/.test(String(b||""))?String(b):"KIRO_STREAM_PROTOCOL_ERROR",e=a.parseError({status:k.gx.BAD_GATEWAY,headers:{}},JSON.stringify({code:d,message:c}));return{error:{message:e.message,type:"kiro_stream_error",code:e.providerErrorCode||d,status:e.status},failureMetadata:{failureClass:"KIRO_STREAM_PROTOCOL_ERROR"===d?"upstream_protocol":/(?:CRC_MISMATCH|INVALID_|TRUNCATED|TOO_LARGE)/.test(d)?"protocol_corruption":"upstream_protocol",providerErrorCode:e.providerErrorCode,upstreamRequestId:e.upstreamRequestId,resetsAtMs:e.resetsAtMs,authLifecycle:{initialStatus:e.status,refreshAttempted:!1,refreshOutcome:"not_attempted",retryStatus:null}}}}function J(a,b){return new Response(`data: ${JSON.stringify(b)}
|
|
289
|
+
`)),b.enqueue(a.encode(e.$U)),b.close()}finally{await l.close().catch(()=>{}),await d.close().catch(()=>{});let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(f)}}},{highWaterMark:16384});return{response:new Response(g,{status:200,headers:{...e.uB}}),url:D,headers:{},transformedBody:b}}let s=await x({page:l,baseCount:o.count,baseText:o.lastText,signal:h});return{response:new Response(JSON.stringify(G(s,B)),{status:200,headers:{"Content-Type":"application/json"}}),url:D,headers:{},transformedBody:b}}catch(c){let a=c instanceof Error?c.message:"Unknown error";if((0,f.BE)(a))return{response:R(503,"Gemini Web needs a Chrome/Chromium binary. Install Google Chrome, set ZEVAI_BROWSER_BIN or CHROME_PATH to an existing Chrome, or run `npx playwright-core install chromium`."),url:D,headers:{},transformedBody:b};if(c instanceof Error&&("TimeoutError"===c.name||a.includes("waitForSelector")||a.includes("Timeout")||a.includes("actionability")||a.includes("interception")))return{response:R(400,a),url:D,headers:{},transformedBody:b};return{response:R(500,a),url:D,headers:{},transformedBody:b}}finally{K&&h?.removeEventListener("abort",K);try{await J?.close()}catch{}if(C){let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(C)}}}async generateMedia({prompt:a,n:b=1,size:d,credentials:e,signal:f,log:g}){if(!a)throw Error("prompt is required for image generation");let h=Q(e);if(!h)throw Error("Missing Gemini cookies");let j=[];for(let e=0;e<Math.max(1,b);e++){let b=null,e=null;try{let{acquireGeminiBrowser:g}=await c.e(2126).then(c.bind(c,69745));b=await g(F),e=await b.newContext({userAgent:E}),await e.addCookies((0,i.EU)(h,".google.com"));let k=await e.newPage(),l=await M(k),m=await N(k,l);await m.click(),await k.keyboard.insertText(function(a,b){let c=b?` (aspect ratio ${b})`:"";return`Generate an image${c}: ${a}`}(a,d)),await k.waitForTimeout(300),await k.keyboard.press("Enter");let n=await C(k,{signal:f});j.push(n)}finally{try{await e?.close()}catch{}if(b){let{releaseGeminiBrowser:a}=await c.e(2126).then(c.bind(c,69745));await a(b)}}}return j}}},29675:(a,b,c)=>{"use strict";c.d(b,{P:()=>h});var d=c(86871),e=c(14170),f=c(4305);function g(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 h(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,a.message?.usage&&"object"==typeof a.message.usage&&(b.startUsage=a.message.usage),c.push(g(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;else if(d?.type==="tool_use"){let e=b.toolCallIndex++,f=b.toolNameMap?.get(d.name)||d.name,h={index:e,id:d.id,type:"function",function:{name:f,arguments:""}};b.toolCalls.set(a.index,h),c.push(g(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(g(b,{content:d.text}));else if(d?.type==="thinking_delta"&&d.thinking)c.push(g(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(g(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&&(b.inThinkingBlock=!1),b.textBlockStarted=!1,b.thinkingBlockStarted=!1;break;case"message_delta":if(a.usage&&"object"==typeof a.usage){let c={...b.startUsage||{},...a.usage},d="number"==typeof c.input_tokens?c.input_tokens:0,e="number"==typeof c.output_tokens?c.output_tokens:0,f="number"==typeof c.cache_read_input_tokens?c.cache_read_input_tokens:0,g="number"==typeof c.cache_creation_input_tokens?c.cache_creation_input_tokens:0,h=d+f+g;b.usage={prompt_tokens:h,completion_tokens:e,total_tokens:h+e,input_tokens:d,output_tokens:e},f>0&&(b.usage.cache_read_input_tokens=f),g>0&&(b.usage.cache_creation_input_tokens=g)}if(a.delta?.stop_reason){var d;d=a.delta.stop_reason,b.finishReason=(0,f.Jm)(d);let e="refusal"===a.delta.stop_reason&&a.delta.stop_details?.explanation;e&&c.push(g(b,{content:e}));let h={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){h.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)&&(h.usage.prompt_tokens_details={},a>0&&(h.usage.prompt_tokens_details.cached_tokens=a),c>0&&(h.usage.prompt_tokens_details.cache_creation_tokens=c))}c.push(h),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,h)},29994:(a,b,c)=>{"use strict";c.d(b,{D:()=>h});let d=/claude-opus-5(?:\.5|-5)(?:-|$)/i,e=/claude-sonnet-5(?:\.5|-5)(?:-|$)/i,f=/claude-haiku-5(?:\.5|-5)(?:-|$)/i;function g(a){if(!a||"object"!=typeof a)return;let b={...a};return delete b.effort,Object.keys(b).length?b:void 0}function h(a,b){if(!b||"object"!=typeof b)return b;let c=String(a||b.model||""),h={...b,...b.thinking&&"object"==typeof b.thinking?{thinking:{...b.thinking}}:{},...b.output_config&&"object"==typeof b.output_config?{output_config:{...b.output_config}}:{},...b.tool_choice&&"object"==typeof b.tool_choice?{tool_choice:{...b.tool_choice}}:{}};if(function(a){if(!/haiku/i.test(a||""))return!1;let b=String(a).match(/haiku[-._]?(\d+)|(?<![\d.])(\d+)(?:[-._]\d+)?[-._]?haiku/i);return!b||5>Number(b[1]||b[2])}(c)){h.thinking?.type==="adaptive"&&(h.thinking={type:"enabled",budget_tokens:1e4});let a=g(h.output_config);return a?h.output_config=a:delete h.output_config,h}if(f.test(c)){let a=h.thinking;if(a?.type==="enabled"||a?.type==="adaptive"){let b,c={type:"adaptive"};"string"==typeof a.display&&a.display&&(c.display=a.display),h.thinking=c,h.output_config={...h.output_config||{},effort:h.output_config?.effort||(4096===(b=Number(a.budget_tokens))?"low":8e3===b||8192===b?"medium":16384===b?"high":32768===b?"xhigh":!Number.isFinite(b)||b<=0?"high":b<=4096?"low":b<=16384?"medium":"high")}}else if(a?.type==="disabled"){h.thinking={type:"disabled"};let a=g(h.output_config);a?h.output_config=a:delete h.output_config}return h}if(!d.test(c)&&!e.test(c))return b;if(h.tool_choice?.type==="any"||h.tool_choice?.type==="tool"){let a=h.tool_choice.disable_parallel_tool_use;h.tool_choice={type:"auto",...void 0!==a?{disable_parallel_tool_use:a}:{}}}return h.thinking?.type!=="disabled"||(d.test(c)?(delete h.thinking,h.output_config={...h.output_config||{},effort:"low"}):h.thinking={type:"between_tools"}),h}},30364:(a,b,c)=>{"use strict";c.d(b,{s:()=>e});var d=c(24);function e(a,b,c){return a&&"object"==typeof a&&c&&!1===(0,d.nl)(b,c).thinkingCanDisable&&(a.thinking?.type==="disabled"&&delete a.thinking,!1===a.enable_thinking&&delete a.enable_thinking),a}},32213:(a,b,c)=>{"use strict";c.d(b,{Br:()=>N});var d=c(74957),e=c(35024),f=c(47293),g=c(12025),h=c(39609),i=c(328),j=c(59657),k=c(41004),l=c(66682),m=c(6382),n=c(77598),o=c(8658),p=c(51455),q=c(48161),r=c(76760);let s=new Map;function t(a,{now:b=Date.now()}={}){return s.set(a,{verifiedUntil:b+9e5,cleanProbes:0,probeInFlight:!1}),"verified"}function u(a,{now:b=Date.now()}={}){let c=s.get(a);return c?c.probeInFlight?(c.probeInFlight=!1,c.cleanProbes+=1,c.cleanProbes>=5)?(s.delete(a),"live"):(c.verifiedUntil=b,"verified"):"verified":"live"}function v(a,{now:b=Date.now()}={}){let c=s.get(a);c?.probeInFlight&&(c.probeInFlight=!1,c.verifiedUntil=Math.min(c.verifiedUntil,b))}var w=c(66014);let{createTaggedThinkingState:x,flushTaggedThinking:y,pushTaggedThinking:z}=(c.n(w))();function A(...a){for(let b of a)if(("string"==typeof b||"number"==typeof b)&&String(b).trim())return String(b).trim();return""}function B(...a){for(let b of a){if("string"!=typeof b&&"number"!=typeof b)continue;let a=String(b).trim();if(/^[A-Za-z0-9_.:#/-]{1,200}$/.test(a)&&!(/^aor[A-Za-z0-9._~+/=-]{8,}$/.test(a)||/^eyJ[A-Za-z0-9_-]{8,}\./.test(a)))return a}return null}function C(a,b){let c=a?.headers;if(!c)return null;if("function"==typeof c.get)return c.get(b);let d=Object.entries(c).find(([a])=>a.toLowerCase()===b.toLowerCase());return d?.[1]??null}function D(a,b){return E(a,b)[0]??null}function E(a,b){if(!a||"object"!=typeof a)return[];let c=new Set(b.map(a=>a.toLowerCase())),d=[{value:a,depth:0}],e=new Set,f=[];for(;d.length>0&&e.size<64;){let{value:a,depth:b}=d.shift();if(!(!a||"object"!=typeof a||e.has(a)))for(let[g,h]of(e.add(a),Object.entries(a)))c.has(g.toLowerCase())&&null!=h&&""!==h&&f.push(h),b<3&&h&&"object"==typeof h&&d.push({value:h,depth:b+1})}return f}function F(a){return a&&"object"==typeof a?[...new Set(E(a,["reason","code","errorCode","type","__type","status"]).map(a=>B(a)).filter(Boolean))]:[]}function G(a,b){if(null==a||""===a)return null;let c="number"==typeof a?a:Number(String(a).trim());if(Number.isFinite(c)){let a=c>=1e12?c:c>=1e9?1e3*c:null;return a&&a>b?Math.round(a):null}let d=Date.parse(String(a));return Number.isFinite(d)&&d>b?d:null}function H(a,b){if(null==a||""===a)return null;let c=String(a).trim().toLowerCase().match(/^(\d+(?:\.\d+)?)\s*(ms|s|m|h)?$/);if(!c)return null;let d=Number(c[1]);return!Number.isFinite(d)||d<=0?null:b+Math.round(d*("ms"===c[2]?1:"m"===c[2]?6e4:"h"===c[2]?36e5:1e3))}let I=new Set(["KIRO_STREAM_EMPTY_RESPONSE","KIRO_STREAM_MISSING_TERMINAL"]),J={KIRO_STREAM_EMPTY_RESPONSE:"Kiro upstream returned an empty response (no content). This is usually a transient upstream blip — please retry.",KIRO_STREAM_MISSING_TERMINAL:"Kiro upstream ended the response early without producing any output (no completion event). This is usually a transient upstream blip — please retry.",KIRO_STREAM_TRUNCATED:"Kiro upstream response ended prematurely (truncated stream)."};function K(a,b="KIRO_STREAM_PROTOCOL_ERROR",c=null){let d=/^(?:AWS_EVENTSTREAM|KIRO_STREAM|KIRO_VERIFIED)_[A-Z0-9_]+$/.test(String(b||""))?String(b):"KIRO_STREAM_PROTOCOL_ERROR",e=c||J[d]||"Kiro upstream returned an invalid event stream",f=a.parseError({status:k.gx.BAD_GATEWAY,headers:{}},JSON.stringify({code:d,message:e}));return{error:{message:f.message,type:"kiro_stream_error",code:f.providerErrorCode||d,status:f.status},failureMetadata:{failureClass:"KIRO_STREAM_PROTOCOL_ERROR"===d?"upstream_protocol":/(?:CRC_MISMATCH|INVALID_|TRUNCATED|TOO_LARGE)/.test(d)?"protocol_corruption":"upstream_protocol",providerErrorCode:f.providerErrorCode,upstreamRequestId:f.upstreamRequestId,resetsAtMs:f.resetsAtMs,authLifecycle:{initialStatus:f.status,refreshAttempted:!1,refreshOutcome:"not_attempted",retryStatus:null}}}}function L(a,b){return new Response(`data: ${JSON.stringify(b)}
|
|
290
290
|
|
|
291
291
|
data: [DONE]
|
|
292
292
|
|
|
293
|
-
`,{status:a?.status||200,statusText:a?.statusText,headers:{"Content-Type":"text/event-stream","Cache-Control":"no-cache",Connection:"keep-alive"}})}function
|
|
293
|
+
`,{status:a?.status||200,statusText:a?.statusText,headers:{"Content-Type":"text/event-stream","Cache-Control":"no-cache",Connection:"keep-alive"}})}function M(a,...b){for(let c of b){let b=Number(a?.[c]);if(Number.isFinite(b)&&b>0)return b}}class N extends d.Hv{constructor(){super("kiro",e.xq.kiro)}buildHeaders(a,b=!0,c=""){let d={...this.config.headers,"Amz-Sdk-Request":"attempt=1; max=3","Amz-Sdk-Invocation-Id":(0,f.A)()};String(c).includes("://codewhisperer.")?d["X-Amz-Target"]=m.rx:delete d["X-Amz-Target"];let e=a?.providerSpecificData?.authMethod,g=a?.apiKey||a?.accessToken;g&&(d.Authorization=`Bearer ${g}`,"api_key"===e&&(d.TokenType="API_KEY"),"external_idp"===e&&(d.TokenType="EXTERNAL_IDP")),a?.accessToken&&(d["x-amz-sso-bearer"]=a.accessToken),d["x-amzn-kiro-agent-mode"]="spec",d["x-amzn-codewhisperer-machine-id"]="kiro-desktop";let h=a?.providerSpecificData?.profileArn;h&&(d["x-amzn-codewhisperer-profile-arn"]=h);let i=a?.providerSpecificData?.clientId||a?.refreshToken||a?.providerSpecificData?.profileArn||a?.accessToken||"kiro-anonymous",j=(0,n.createHash)("sha256").update(String(i)).digest("hex"),{userAgent:k,amzUserAgent:l}=(0,m.VE)(j);return d["User-Agent"]=k,d["X-Amz-User-Agent"]=l,d}getOrderedBaseUrls(a){let b=this.getBaseUrls(),c=String(a?.providerSpecificData?.region||"us-east-1").trim(),d=/^[a-z]{2}-[a-z]+-\d{1,2}$/.test(c),e=b.filter(a=>a.includes("amazonaws.com")).map(a=>d&&"us-east-1"!==c&&a.includes("amazonaws.com")?a.replace(/([a-z]+)\.[a-z0-9-]+\.amazonaws\.com/,`$1.${c}.amazonaws.com`):a),f=b.filter(a=>!a.includes("amazonaws.com")),g=e.filter(a=>a.includes("://q.")),h=e.filter(a=>!a.includes("://q."));return g.length>0?[...g,...h,...f]:[...e,...f]}shouldRetry(a,b){return a!==k.gx.RATE_LIMITED&&400!==a&&422!==a&&b+1<this.getFallbackCount()&&m.QR.has(a)}buildUrl(a,b,c=0,d=null){let e=this.getOrderedBaseUrls(d);return e[c]||e[0]||this.config.baseUrl}transformRequest(a,b,c,d){return b}async prefetchImages(a,b){let c=a?.conversationState;for(let a of[c?.currentMessage,...c?.history||[]]){let c=a?.userInputMessage;if(!Array.isArray(c?.images))continue;let d=await Promise.all(c.images.map(async a=>{let d=a?.source?.url;if(!d)return a;let e=await (0,l.n)(d,{signal:b,timeoutMs:15e3});if(!e?.url){let a=`[Image unavailable: ${d}]`;return c.content=c.content?`${c.content}
|
|
294
294
|
|
|
295
|
-
${a}`:a,null}let f=e.url.match(/^data:([^;]+);base64,(.+)$/);if(!f)return null;let g=f[1].split("/")[1]||a.format||"jpeg";return{format:"jpg"===g?"jpeg":g,source:{bytes:f[2]}}}));c.images=d.filter(Boolean),0===c.images.length&&delete c.images}}parseError(a,b){let c=Number.isFinite(a?.status)?a.status:500,d=String(C(a,"content-type")||"").toLowerCase(),e="string"==typeof b?b.trim():"",f=null;try{f=e?JSON.parse(e):null}catch{}let g=f?.error&&"object"==typeof f.error?f.error:{},h=F(f).map(a=>({code:a,normalized:String(a||"").replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")})),i=a=>h.find(({normalized:b})=>a(b)),j=i(a=>"invalid_model"===a||a.endsWith("_invalid_model")||/model_(?:not_(?:found|supported)|unsupported)/.test(a)),l=["policy_violation","content_policy","validation","invalid_request","invalid_argument","bad_request","malformed_request"],m=i(a=>l.some(b=>a.includes(b))),n=["account_suspended","user_suspended","profile_suspended","account_banned","user_banned","account_disabled","user_disabled","account_restricted","user_restricted","profile_disabled","profile_restricted"],o=i(a=>n.some(b=>a.includes(b))),p=["entitlement","subscription","payment_required","billing","quota","not_subscribed","not_entitled","resource_exhausted"],q=i(a=>p.some(b=>a.includes(b))),r=(j||m||o||q||h[0])?.code||null,s=c===k.gx.FORBIDDEN&&(d.includes("text/html")||/^\s*(?:<!doctype\s+html|<html|<head|<body)/i.test(e)),t=A(g?.message,g?.Message,g?.errorMessage,f?.message,f?.Message,f?.errorMessage,D(f,["message","errorMessage","error_description"]),"string"==typeof f?.error?f.error:""),u=f||!e||/^\s*[<{[]/.test(e)?"":e,v=s?"Kiro upstream returned an HTML 403 response":function(a,b=1e3){return String(a||"").replace(/\bBearer\s+[^\s"',;]+/gi,"Bearer [REDACTED]").replace(/\baor[A-Za-z0-9._~+/=-]{8,}/g,"[REDACTED_REFRESH_TOKEN]").replace(/\beyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,}\b/g,"[REDACTED_TOKEN]").replace(/\b((?:user|account|profile)\s*id)\s*\([^\r\n)]{1,200}\)/gi,"$1 ([REDACTED])").replace(/\b((?:user|account|profile)\s*id)(\s*[:=]\s*["']?)[A-Za-z0-9@._:/+-]{3,200}/gi,"$1$2[REDACTED]").replace(/((?:access|refresh|id)[_-]?token|authorization|client[_-]?secret|cookie)(\s*["']?\s*[:=]\s*["']?)[^\s"',;}]+/gi,"$1$2[REDACTED]").replace(/[\u0000-\u001f\u007f]+/g," ").replace(/\s+/g," ").trim().slice(0,b)}(t||u)||(r?`Kiro upstream error (${r})`:`Kiro upstream error: ${c}`),w=v.replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase(),x=w.replace(/[^a-z0-9]+/g,"_"),y=/\b(?:request|prompt|input|content|message|response)\b.{0,100}\b(?:content\s+policy|policy\s+violation|restricted|blocked|rejected)\b/.test(w)||/\b(?:content\s+policy|policy\s+violation)\b.{0,100}\b(?:request|prompt|input|content|message|response)\b/.test(w),z=!y&&(/\b(?:account|user|profile)\b.{0,80}\b(?:suspended|banned|disabled|restricted)\b/.test(w)||/\b(?:suspended|banned|disabled|restricted)\b.{0,80}\b(?:account|user|profile)\b/.test(w)),B=!!o||(c===k.gx.UNAUTHORIZED||c===k.gx.FORBIDDEN)&&z,E=[k.gx.PAYMENT_REQUIRED,k.gx.FORBIDDEN,k.gx.RATE_LIMITED].includes(c)&&p.some(a=>x.includes(a)),I=!!q||E,J="unknown";s?J="shared_egress_waf":j?J="invalid_model":m||y?J="invalid_request":B?J="policy_suspended":I?J="entitlement_or_quota":c===k.gx.RATE_LIMITED?J="rate_limited":c===k.gx.UNAUTHORIZED?J="authentication":c===k.gx.REQUEST_TIMEOUT||c>=500?J="upstream_transient":c===k.gx.FORBIDDEN?J="permission_denied":(c===k.gx.BAD_REQUEST||413===c||422===c)&&(J="invalid_request");let K=function(a,b,c){let d=G(D(b,["resetAt","resetsAt","reset_at","resets_at","resetTime","resetTimestamp","quotaResetTimeStamp","quotaResetTimestamp"]),c);if(d)return d;let e=G(C(a,"x-ratelimit-reset")||C(a,"x-rate-limit-reset"),c);if(e)return e;let f=H(D(b,["retryAfter","retry_after","retryAfterSeconds","retry_after_seconds","retryDelay","quotaResetDelay"]),c);if(f)return f;let g=C(a,"retry-after");return H(g,c)||G(g,c)}(a,f,Date.now());return{status:c,message:v,failureClass:J,providerErrorCode:r,upstreamRequestId:function(...a){for(let b of a){let a=function(a){if("string"!=typeof a&&"number"!=typeof a)return null;let b=String(a).trim();return!/^[A-Za-z0-9][A-Za-z0-9._:/#-]{0,199}$/.test(b)||/^aor[A-Za-z0-9._~+/=-]{8,}$/.test(b)||/^eyJ[A-Za-z0-9_-]{8,}\./.test(b)?null:b.slice(0,200)}(b);if(a)return a}return null}(C(a,"x-amzn-requestid"),C(a,"x-amz-request-id"),g?.requestId,g?.requestID,g?.request_id,f?.requestId,f?.requestID,f?.request_id,f?.$metadata?.requestId,D(f,["requestId","requestID","request_id"])),resetsAtMs:K}}async execute({model:a,body:b,stream:c,credentials:d,signal:e,log:f,proxyOptions:g=null,providerOverrides:l=null,integrityAttempt:m=1,streamControl:n=null,onIntegrityRetry:o=null}){await this.prefetchImages(b,e);let p=this.transformRequest(a,b,c,d),q={...k.cI,...this.config.retry},r=this.getOrderedBaseUrls(d),t=String(a||"unknown").split("-").slice(0,2).join("-")||"unknown",u=g?.proxyPoolId||"direct",v=`kiro:${t}:${u}`,w=null;for(let b=0;b<r.length;b++){let t=r[b],u=0;for(;;){let x,y=(0,i.MB)(this.buildHeaders(d,c,t),l);try{x=await (0,h.proxyAwareFetch)(t,{method:"POST",headers:y,body:JSON.stringify(p),signal:e},g)}catch(a){if(e?.aborted||a?.name==="AbortError")throw a;if(w=a,b+1<r.length){f?.debug?.("RETRY",`Kiro network error on ${t}; trying fallback endpoint`);break}throw a}let z=x.status===k.gx.RATE_LIMITED&&!1===this.config.retrySameCredential429?null:q[x.status],{attempts:A,delayMs:B}=(0,k.DR)(z);if(!x.ok&&A>0&&u<A){u++,f?.debug?.("RETRY",`${x.status} retry ${u}/${A} after ${B/1e3}s`),await (0,j.aI)(x),await new Promise(a=>setTimeout(a,B));continue}if(!x.ok){if(this.shouldRetry(x.status,b)){f?.debug?.("RETRY",`Kiro ${x.status} on ${t}; trying fallback endpoint`),await (0,j.aI)(x);break}return{response:x,url:t,headers:y,transformedBody:p}}let C="live"===function(a,{now:b=Date.now()}={}){let c=s.get(a);return c?b<c.verifiedUntil||c.probeInFlight?"verified":(c.probeInFlight=!0,"probe"):"live"}(v)?"live":"verified",D=this.transformEventStreamToSSE(x,a,p,{deliveryMode:C,integrityKey:v,onValidatedFrame:()=>n?.reportValidatedEvent?.()});return{response:"verified"===C?function({transformedResponse:a,integrityAttempt:b,onIntegrityRetry:c,signal:d}){let e=new TextEncoder,f=a,g=!1,h=!1,i=async(a,b)=>{if(!a?.response)return!1;f=a.response;let c=f.body?.getReader?.();if(c)for(;;){let{done:a,value:d}=await c.read();if(a)break;b.enqueue(d)}return b.close(),!0};return new Response(new ReadableStream({async pull(f){if(g)return;g=!0;let j=null;try{var l;j=await a.text();let g=function(a){for(let b of String(a||"").split(/\r?\n/)){let a;if(!b.startsWith("data: ")||"data: [DONE]"===b)continue;try{a=JSON.parse(b.slice(6))}catch{continue}let c=a?.failureMetadata?.failureClass;if(a?.error?.type==="kiro_stream_error"&&("upstream_protocol"===c||"protocol_corruption"===c))return{code:a?.error?.code||"KIRO_STREAM_PROTOCOL_ERROR",failureClass:c}}return null}(j);if(g&&(l=g.code,/^(?:AWS_EVENTSTREAM_|KIRO_STREAM_(?:MISSING_TERMINAL|TRUNCATED|INVALID_TOOL_CALL|PROTOCOL_ERROR|TRANSPORT_READ_FAILED))/.test(String(l||"")))&&1===b&&"function"==typeof c&&!d?.aborted){h=!0;let a=await c({...g,integrityAttempt:b});if(await i(
|
|
295
|
+
${a}`:a,null}let f=e.url.match(/^data:([^;]+);base64,(.+)$/);if(!f)return null;let g=f[1].split("/")[1]||a.format||"jpeg";return{format:"jpg"===g?"jpeg":g,source:{bytes:f[2]}}}));c.images=d.filter(Boolean),0===c.images.length&&delete c.images}}parseError(a,b){let c=Number.isFinite(a?.status)?a.status:500,d=String(C(a,"content-type")||"").toLowerCase(),e="string"==typeof b?b.trim():"",f=null;try{f=e?JSON.parse(e):null}catch{}let g=f?.error&&"object"==typeof f.error?f.error:{},h=F(f).map(a=>({code:a,normalized:String(a||"").replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")})),i=a=>h.find(({normalized:b})=>a(b)),j=i(a=>"invalid_model"===a||a.endsWith("_invalid_model")||/model_(?:not_(?:found|supported)|unsupported)/.test(a)),l=["policy_violation","content_policy","validation","invalid_request","invalid_argument","bad_request","malformed_request"],m=i(a=>l.some(b=>a.includes(b))),n=["account_suspended","user_suspended","profile_suspended","account_banned","user_banned","account_disabled","user_disabled","account_restricted","user_restricted","profile_disabled","profile_restricted"],o=i(a=>n.some(b=>a.includes(b))),p=["entitlement","subscription","payment_required","billing","quota","not_subscribed","not_entitled","resource_exhausted"],q=i(a=>p.some(b=>a.includes(b))),r=(j||m||o||q||h[0])?.code||null,s=c===k.gx.FORBIDDEN&&(d.includes("text/html")||/^\s*(?:<!doctype\s+html|<html|<head|<body)/i.test(e)),t=A(g?.message,g?.Message,g?.errorMessage,f?.message,f?.Message,f?.errorMessage,D(f,["message","errorMessage","error_description"]),"string"==typeof f?.error?f.error:""),u=f||!e||/^\s*[<{[]/.test(e)?"":e,v=s?"Kiro upstream returned an HTML 403 response":function(a,b=1e3){return String(a||"").replace(/\bBearer\s+[^\s"',;]+/gi,"Bearer [REDACTED]").replace(/\baor[A-Za-z0-9._~+/=-]{8,}/g,"[REDACTED_REFRESH_TOKEN]").replace(/\beyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,}\b/g,"[REDACTED_TOKEN]").replace(/\b((?:user|account|profile)\s*id)\s*\([^\r\n)]{1,200}\)/gi,"$1 ([REDACTED])").replace(/\b((?:user|account|profile)\s*id)(\s*[:=]\s*["']?)[A-Za-z0-9@._:/+-]{3,200}/gi,"$1$2[REDACTED]").replace(/((?:access|refresh|id)[_-]?token|authorization|client[_-]?secret|cookie)(\s*["']?\s*[:=]\s*["']?)[^\s"',;}]+/gi,"$1$2[REDACTED]").replace(/[\u0000-\u001f\u007f]+/g," ").replace(/\s+/g," ").trim().slice(0,b)}(t||u)||(r?`Kiro upstream error (${r})`:`Kiro upstream error: ${c}`),w=v.replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase(),x=w.replace(/[^a-z0-9]+/g,"_"),y=/\b(?:request|prompt|input|content|message|response)\b.{0,100}\b(?:content\s+policy|policy\s+violation|restricted|blocked|rejected)\b/.test(w)||/\b(?:content\s+policy|policy\s+violation)\b.{0,100}\b(?:request|prompt|input|content|message|response)\b/.test(w),z=!y&&(/\b(?:account|user|profile)\b.{0,80}\b(?:suspended|banned|disabled|restricted)\b/.test(w)||/\b(?:suspended|banned|disabled|restricted)\b.{0,80}\b(?:account|user|profile)\b/.test(w)),B=!!o||(c===k.gx.UNAUTHORIZED||c===k.gx.FORBIDDEN)&&z,E=[k.gx.PAYMENT_REQUIRED,k.gx.FORBIDDEN,k.gx.RATE_LIMITED].includes(c)&&p.some(a=>x.includes(a)),I=!!q||E,J="unknown";s?J="shared_egress_waf":j?J="invalid_model":m||y?J="invalid_request":B?J="policy_suspended":I?J="entitlement_or_quota":c===k.gx.RATE_LIMITED?J="rate_limited":c===k.gx.UNAUTHORIZED?J="authentication":c===k.gx.REQUEST_TIMEOUT||c>=500?J="upstream_transient":c===k.gx.FORBIDDEN?J="permission_denied":(c===k.gx.BAD_REQUEST||413===c||422===c)&&(J="invalid_request");let K=function(a,b,c){let d=G(D(b,["resetAt","resetsAt","reset_at","resets_at","resetTime","resetTimestamp","quotaResetTimeStamp","quotaResetTimestamp"]),c);if(d)return d;let e=G(C(a,"x-ratelimit-reset")||C(a,"x-rate-limit-reset"),c);if(e)return e;let f=H(D(b,["retryAfter","retry_after","retryAfterSeconds","retry_after_seconds","retryDelay","quotaResetDelay"]),c);if(f)return f;let g=C(a,"retry-after");return H(g,c)||G(g,c)}(a,f,Date.now());return{status:c,message:v,failureClass:J,providerErrorCode:r,upstreamRequestId:function(...a){for(let b of a){let a=function(a){if("string"!=typeof a&&"number"!=typeof a)return null;let b=String(a).trim();return!/^[A-Za-z0-9][A-Za-z0-9._:/#-]{0,199}$/.test(b)||/^aor[A-Za-z0-9._~+/=-]{8,}$/.test(b)||/^eyJ[A-Za-z0-9_-]{8,}\./.test(b)?null:b.slice(0,200)}(b);if(a)return a}return null}(C(a,"x-amzn-requestid"),C(a,"x-amz-request-id"),g?.requestId,g?.requestID,g?.request_id,f?.requestId,f?.requestID,f?.request_id,f?.$metadata?.requestId,D(f,["requestId","requestID","request_id"])),resetsAtMs:K}}async execute({model:a,body:b,stream:c,credentials:d,signal:e,log:f,proxyOptions:g=null,providerOverrides:l=null,integrityAttempt:m=1,streamControl:n=null,onIntegrityRetry:o=null}){await this.prefetchImages(b,e);let p=this.transformRequest(a,b,c,d),q={...k.cI,...this.config.retry},r=this.getOrderedBaseUrls(d),t=String(a||"unknown").split("-").slice(0,2).join("-")||"unknown",u=g?.proxyPoolId||"direct",v=`kiro:${t}:${u}`,w=null;for(let b=0;b<r.length;b++){let t=r[b],u=0;for(;;){let x,y=(0,i.MB)(this.buildHeaders(d,c,t),l);try{x=await (0,h.proxyAwareFetch)(t,{method:"POST",headers:y,body:JSON.stringify(p),signal:e},g)}catch(a){if(e?.aborted||a?.name==="AbortError")throw a;if(w=a,b+1<r.length){f?.debug?.("RETRY",`Kiro network error on ${t}; trying fallback endpoint`);break}throw a}let z=x.status===k.gx.RATE_LIMITED&&!1===this.config.retrySameCredential429?null:q[x.status],{attempts:A,delayMs:B}=(0,k.DR)(z);if(!x.ok&&A>0&&u<A){u++,f?.debug?.("RETRY",`${x.status} retry ${u}/${A} after ${B/1e3}s`),await (0,j.aI)(x),await new Promise(a=>setTimeout(a,B));continue}if(!x.ok){if(this.shouldRetry(x.status,b)){f?.debug?.("RETRY",`Kiro ${x.status} on ${t}; trying fallback endpoint`),await (0,j.aI)(x);break}return{response:x,url:t,headers:y,transformedBody:p}}let C="live"===function(a,{now:b=Date.now()}={}){let c=s.get(a);return c?b<c.verifiedUntil||c.probeInFlight?"verified":(c.probeInFlight=!0,"probe"):"live"}(v)?"live":"verified",D=this.transformEventStreamToSSE(x,a,p,{deliveryMode:C,integrityKey:v,onValidatedFrame:()=>n?.reportValidatedEvent?.()});return{response:"verified"===C?function({transformedResponse:a,integrityAttempt:b,onIntegrityRetry:c,signal:d}){let e=new TextEncoder,f=a,g=!1,h=!1,i=async(a,b)=>{if(!a?.response)return!1;f=a.response;let c=f.body?.getReader?.();if(c)for(;;){let{done:a,value:d}=await c.read();if(a)break;b.enqueue(d)}return b.close(),!0};return new Response(new ReadableStream({async pull(f){if(g)return;g=!0;let j=null;try{var l,m;j=await a.text();let g=function(a){for(let b of String(a||"").split(/\r?\n/)){let a;if(!b.startsWith("data: ")||"data: [DONE]"===b)continue;try{a=JSON.parse(b.slice(6))}catch{continue}let c=a?.failureMetadata?.failureClass;if(a?.error?.type==="kiro_stream_error"&&("upstream_protocol"===c||"protocol_corruption"===c))return{code:a?.error?.code||"KIRO_STREAM_PROTOCOL_ERROR",failureClass:c}}return null}(j);if(g&&(l=g.code,/^(?:AWS_EVENTSTREAM_|KIRO_STREAM_(?:MISSING_TERMINAL|TRUNCATED|EMPTY_RESPONSE|INVALID_TOOL_CALL|PROTOCOL_ERROR|TRANSPORT_READ_FAILED))/.test(String(l||"")))&&1===b&&"function"==typeof c&&!d?.aborted){h=!0;let a=(m=g.code,750*!!I.has(m));if(a>0&&!d?.aborted&&await new Promise(b=>setTimeout(b,a)),d?.aborted){f.enqueue(e.encode(j)),f.close();return}let k=await c({...g,integrityAttempt:b});if(await i(k,f))return}f.enqueue(e.encode(j)),f.close()}catch(g){if(null!==j){f.enqueue(e.encode(j)),f.close();return}if(1===b&&!h&&"function"==typeof c&&!d?.aborted)try{h=!0;let a=await c({code:"KIRO_STREAM_TRANSPORT_READ_FAILED",failureClass:"protocol_corruption",integrityAttempt:b});if(await i(a,f))return}catch{}let a={error:{message:"Kiro upstream stream ended during validation",type:"kiro_stream_error",code:"KIRO_STREAM_TRANSPORT_READ_FAILED",status:k.gx.BAD_GATEWAY},failureMetadata:{failureClass:"protocol_corruption",providerErrorCode:"KIRO_STREAM_TRANSPORT_READ_FAILED"}};f.enqueue(e.encode(`data: ${JSON.stringify(a)}
|
|
296
296
|
|
|
297
297
|
data: [DONE]
|
|
298
298
|
|
|
299
|
-
`)),f.close()}},async cancel(a){await f.body?.cancel?.(a).catch?.(()=>{})}},{highWaterMark:0}),{status:a.status,statusText:a.statusText,headers:a.headers})}({transformedResponse:D,integrityAttempt:m,onIntegrityRetry:o,signal:e}):D,url:t,headers:y,transformedBody:p,streamDelivery:{mode:C,progress:n,heartbeatIntervalMs:k.WL}}}}throw w||Error("All Kiro endpoints failed")}transformEventStreamToSSE(a,b,c=null,d={}){let e=this,f="verified"===d.deliveryMode,g=d.integrityKey||`kiro:${b}:direct`,h=String(C(a,"content-type")||"").toLowerCase().split(";",1)[0].trim();if(!(!h||"application/vnd.amazon.eventstream"===h||"application/octet-stream"===h||"application/json"===h))return t(g),a.body?.cancel?.().catch(()=>{}),
|
|
299
|
+
`)),f.close()}},async cancel(a){await f.body?.cancel?.(a).catch?.(()=>{})}},{highWaterMark:0}),{status:a.status,statusText:a.statusText,headers:a.headers})}({transformedResponse:D,integrityAttempt:m,onIntegrityRetry:o,signal:e}):D,url:t,headers:y,transformedBody:p,streamDelivery:{mode:C,progress:n,heartbeatIntervalMs:k.WL}}}}throw w||Error("All Kiro endpoints failed")}transformEventStreamToSSE(a,b,c=null,d={}){let e=this,f="verified"===d.deliveryMode,g=d.integrityKey||`kiro:${b}:direct`,h=String(C(a,"content-type")||"").toLowerCase().split(";",1)[0].trim();if(!(!h||"application/vnd.amazon.eventstream"===h||"application/octet-stream"===h||"application/json"===h))return t(g),a.body?.cancel?.().catch(()=>{}),L(a,K(e));let i=(0,o.K)(),j=f?function({memoryLimitBytes:a=2097152,maxBytes:b=0x4000000,tempDir:c=(0,q.tmpdir)()}={}){let d=[],e=0,f=null,g=null,h=!1;async function i(){if(!f){for(let a of(g=(0,r.join)(c,`.zevai-kiro-${process.pid}-${(0,n.randomUUID)()}.spool`),f=await (0,p.open)(g,"wx",384),d))await f.write(a);d=[]}}return{get size(){return e},get storage(){return f?"file":"memory"},get filePath(){return g},async append(c){if(h)throw Error("Kiro verified spool is closed");let g=c instanceof Uint8Array?Buffer.from(c):Buffer.from(String(c)),j=e+g.length;if(j>b){let a;throw(a=Error("Kiro verified stream exceeded spool limit")).code="KIRO_VERIFIED_SPOOL_LIMIT",a.totalBytes=j,a}!f&&j>a&&await i(),f?await f.write(g):d.push(g),e=j},async readAll(){if(h)throw Error("Kiro verified spool is closed");return f?(await f.sync(),(0,p.readFile)(g)):Buffer.concat(d,e)},async cleanup(){!h&&(h=!0,d=[],f&&await f.close(),f=null,g&&await (0,p.rm)(g,{force:!0}))}}}(d.spoolOptions):null,l=new TextEncoder,m=0,s=`chatcmpl-${Date.now()}`,w=Math.floor(Date.now()/1e3),E=c?._kiroExposeReasoning===!0,G=c?._kiroThinkingEnabled===!0,H={endDetected:!1,finishEmitted:!1,hasToolCalls:!1,hasTextContent:!1,hasReasoningContent:!1,hasCodeContent:!1,reasoningChunkCount:0,toolCallIndex:0,seenToolIds:new Map,toolFrames:new Map,validFrameCount:0,taggedThinking:x(),contentFiltered:!1};async function I(a,b){if(H.streamFailed)return!1;let c="string"==typeof b?l.encode(b):b;if(!f)return a.enqueue(c),!0;try{return await j.append(c),!0}catch(c){H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0;let b=K(e,c?.code||"KIRO_VERIFIED_SPOOL_FAILED","Kiro verified stream could not be retained safely");return await J(a,b),!1}}async function J(a,b){t(g),j&&await j.cleanup(),a.enqueue(l.encode(`data: ${JSON.stringify(b)}
|
|
300
300
|
|
|
301
|
-
`))}async function N(a){H.streamFailed||(H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0,await
|
|
301
|
+
`))}async function N(a){H.streamFailed||(H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0,await J(a,K(e,"KIRO_STREAM_INVALID_TOOL_CALL","Kiro upstream returned an incomplete tool call")))}async function O(a,c,d){d&&(H.totalContentLength=(H.totalContentLength||0)+d.length);let e={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{tool_calls:[{index:c,function:{arguments:d}}]},finish_reason:null}]};m++,await I(a,`data: ${JSON.stringify(e)}
|
|
302
302
|
|
|
303
|
-
`)}async function P(a){for(let[b,c]of H.toolFrames)null!==c.inputKind&&("string"!==c.inputKind||""!==c.inputChunks.join(""))||c.emptyArgumentsEmitted||(await O(a,H.seenToolIds.get(b),"{}"),c.emptyArgumentsEmitted=!0)}async function Q(a,c){if(!c||(H.hasReasoningContent=!0,H.totalContentLength=(H.totalContentLength||0)+c.length,!E))return;let d=0===H.reasoningChunkCount&&0===m?{role:"assistant",reasoning_content:c}:{reasoning_content:c};m++,H.reasoningChunkCount++,await
|
|
303
|
+
`)}async function P(a){for(let[b,c]of H.toolFrames)null!==c.inputKind&&("string"!==c.inputKind||""!==c.inputChunks.join(""))||c.emptyArgumentsEmitted||(await O(a,H.seenToolIds.get(b),"{}"),c.emptyArgumentsEmitted=!0)}async function Q(a,c){if(!c||(H.hasReasoningContent=!0,H.totalContentLength=(H.totalContentLength||0)+c.length,!E))return;let d=0===H.reasoningChunkCount&&0===m?{role:"assistant",reasoning_content:c}:{reasoning_content:c};m++,H.reasoningChunkCount++,await I(a,`data: ${JSON.stringify({id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:d,finish_reason:null}]})}
|
|
304
304
|
|
|
305
|
-
`)}async function R(a,c){if(!c)return;H.hasTextContent=!0,H.totalContentLength=(H.totalContentLength||0)+c.length;let d={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:0===m?{role:"assistant",content:c}:{content:c},finish_reason:null}]};m++,await
|
|
305
|
+
`)}async function R(a,c){if(!c)return;H.hasTextContent=!0,H.totalContentLength=(H.totalContentLength||0)+c.length;let d={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:0===m?{role:"assistant",content:c}:{content:c},finish_reason:null}]};m++,await I(a,`data: ${JSON.stringify(d)}
|
|
306
306
|
|
|
307
|
-
`)}async function S(a,b){for(let c of G?z(H.taggedThinking,b):[{type:"text",text:b}])"reasoning"===c.type?await Q(a,c.text):await R(a,c.text)}let T=new TransformStream({async transform(a,c){let f;try{f=i.push(a)}catch(a){if(!H.streamFailed){H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0;let b=
|
|
307
|
+
`)}async function S(a,b){for(let c of G?z(H.taggedThinking,b):[{type:"text",text:b}])"reasoning"===c.type?await Q(a,c.text):await R(a,c.text)}let T=new TransformStream({async transform(a,c){let f;try{f=i.push(a)}catch(a){if(!H.streamFailed){H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0;let b=K(e,a?.code);await J(c,b)}return}for(let a of f){H.validFrameCount++;try{d.onValidatedFrame?.()}catch{}a.payload?.raw!==void 0&&console.warn(`[Kiro] Failed to parse ${a.payload.raw.length}-byte event payload: SyntaxError`);let f=a.headers[":event-type"]||"",g=a.headers[":message-type"]||"",h=a.headers[":exception-type"]||"";if(("exception"===g||"error"===g||h||a.headers[":error-code"]||/exception$/i.test(f))&&!H.streamFailed){H.streamFailed=!0,H.finishEmitted=!0;let b=function(a,b){var c;let d,e,f=b?.payload&&"object"==typeof b.payload?b.payload:{message:A(b?.payload)},g=b?.headers?.[":error-code"],h=b?.headers?.[":error-message"],i=F(f),j=B(g,b?.headers?.[":exception-type"],b?.headers?.[":event-type"],...i)||"KIRO_STREAM_EXCEPTION",l={...f,reason:A(D(f,["reason"])),code:A(g,D(f,["code","errorCode"]),j),message:A(h,D(f,["message","errorMessage","error_description"]),"string"==typeof b?.payload?b.payload:"")},m=(c=`${j} ${g||""} ${h||""}`,d=A(l?.error?.message,l?.message,l?.Message,""),e=`${c||""} ${d}`.replace(/([a-z0-9])([A-Z])/g,"$1_$2").toLowerCase(),/invalid.?model|validation|invalid.?request|bad.?request|malformed/.test(e)?k.gx.BAD_REQUEST:/throttl|rate.?limit|quota|resource.?exhausted/.test(e)?k.gx.RATE_LIMITED:/unauth|invalid.?token|token.?expired/.test(e)?k.gx.UNAUTHORIZED:/forbidden|access.?denied|permission|suspend|banned|disabled|restricted/.test(e)?k.gx.FORBIDDEN:/timeout|timed.?out/.test(e)?k.gx.GATEWAY_TIMEOUT:/unavailable|internal|server.?error|service.?error/.test(e)?k.gx.SERVICE_UNAVAILABLE:k.gx.BAD_GATEWAY),n=JSON.stringify({...l,streamExceptionType:j}),o=a.parseError({status:m,headers:b?.headers||{}},n);return{error:{message:o.message,type:"kiro_stream_error",code:o.providerErrorCode||j,status:o.status},failureMetadata:{failureClass:o.failureClass,providerErrorCode:o.providerErrorCode,upstreamRequestId:o.upstreamRequestId,resetsAtMs:o.resetsAtMs,authLifecycle:{initialStatus:o.status,refreshAttempted:!1,refreshOutcome:"not_attempted",retryStatus:null}}}}(e,a);j&&await j.cleanup(),c.enqueue(l.encode(`data: ${JSON.stringify(b)}
|
|
308
308
|
|
|
309
|
-
`));continue}if(!H.streamFailed){if(H.totalContentLength||(H.totalContentLength=0),H.contextUsagePercentage||(H.contextUsagePercentage=0),("metadataEvent"===f||a.payload?.stopReason==="CONTENT_FILTERED"||a.payload?.stopDetails?.refusal)&&(a.payload?.stopReason==="CONTENT_FILTERED"||a.payload?.stopDetails?.refusal)&&!H.contentFiltered){H.contentFiltered=!0,H.endDetected=!0;let b=a.payload?.stopDetails?.refusal?.explanation||"The selected model cannot continue this conversation due to content policy.";await S(c,b)}if("assistantResponseEvent"===f&&a.payload?.content&&await S(c,a.payload.content),"reasoningContentEvent"===f){let b=a.payload?.reasoningContentEvent||a.payload||{},d="string"==typeof b?b:b.text||b.content||"";await Q(c,d)}if("codeEvent"===f&&a.payload?.content){H.hasCodeContent=!0;let d={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{content:a.payload.content},finish_reason:null}]};m++,await
|
|
309
|
+
`));continue}if(!H.streamFailed){if(H.totalContentLength||(H.totalContentLength=0),H.contextUsagePercentage||(H.contextUsagePercentage=0),("metadataEvent"===f||a.payload?.stopReason==="CONTENT_FILTERED"||a.payload?.stopDetails?.refusal)&&(a.payload?.stopReason==="CONTENT_FILTERED"||a.payload?.stopDetails?.refusal)&&!H.contentFiltered){H.contentFiltered=!0,H.endDetected=!0;let b=a.payload?.stopDetails?.refusal?.explanation||"The selected model cannot continue this conversation due to content policy.";await S(c,b)}if("assistantResponseEvent"===f&&a.payload?.content&&await S(c,a.payload.content),"reasoningContentEvent"===f){let b=a.payload?.reasoningContentEvent||a.payload||{},d="string"==typeof b?b:b.text||b.content||"";await Q(c,d)}if("codeEvent"===f&&a.payload?.content){H.hasCodeContent=!0;let d={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{content:a.payload.content},finish_reason:null}]};m++,await I(c,`data: ${JSON.stringify(d)}
|
|
310
310
|
|
|
311
|
-
`)}if("toolUseEvent"===f&&a.payload){let d=a.payload;for(let a of Array.isArray(d)?d:[d]){let d,e=a.toolUseId||`call_${Date.now()}`,f="string"==typeof a.name?a.name.trim():"",g=a.input;if(!f||null!=a.toolUseId&&("string"!=typeof a.toolUseId||!a.toolUseId.trim())){await N(c);break}let h=H.toolFrames.get(e);if(h){if(h.name!==f){await N(c);break}}else h={name:f,inputKind:null,inputChunks:[],inputObject:null,stopped:!1,emptyArgumentsEmitted:!1},H.toolFrames.set(e,h);if(void 0!==g)if("string"!=typeof g||h.inputKind&&"string"!==h.inputKind)if(!g||"object"!=typeof g||Array.isArray(g)||h.inputKind){await N(c);break}else h.inputKind="object",h.inputObject=g;else h.inputKind="string",h.inputChunks.push(g);if(!0===a.stop&&(h.stopped=!0),H.hasToolCalls=!0,H.seenToolIds.has(e))d=H.seenToolIds.get(e);else{d=H.toolCallIndex++,H.seenToolIds.set(e,d),H.totalContentLength=(H.totalContentLength||0)+f.length;let a={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{...0===m?{role:"assistant"}:{},tool_calls:[{index:d,id:e,type:"function",function:{name:f,arguments:""}}]},finish_reason:null}]};m++,await
|
|
311
|
+
`)}if("toolUseEvent"===f&&a.payload){let d=a.payload;for(let a of Array.isArray(d)?d:[d]){let d,e=a.toolUseId||`call_${Date.now()}`,f="string"==typeof a.name?a.name.trim():"",g=a.input;if(!f||null!=a.toolUseId&&("string"!=typeof a.toolUseId||!a.toolUseId.trim())){await N(c);break}let h=H.toolFrames.get(e);if(h){if(h.name!==f){await N(c);break}}else h={name:f,inputKind:null,inputChunks:[],inputObject:null,stopped:!1,emptyArgumentsEmitted:!1},H.toolFrames.set(e,h);if(void 0!==g)if("string"!=typeof g||h.inputKind&&"string"!==h.inputKind)if(!g||"object"!=typeof g||Array.isArray(g)||h.inputKind){await N(c);break}else h.inputKind="object",h.inputObject=g;else h.inputKind="string",h.inputChunks.push(g);if(!0===a.stop&&(h.stopped=!0),H.hasToolCalls=!0,H.seenToolIds.has(e))d=H.seenToolIds.get(e);else{d=H.toolCallIndex++,H.seenToolIds.set(e,d),H.totalContentLength=(H.totalContentLength||0)+f.length;let a={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{...0===m?{role:"assistant"}:{},tool_calls:[{index:d,id:e,type:"function",function:{name:f,arguments:""}}]},finish_reason:null}]};m++,await I(c,`data: ${JSON.stringify(a)}
|
|
312
312
|
|
|
313
|
-
`)}if(!0===a.stop&&(null===h.inputKind&&void 0===g||"string"===h.inputKind&&""===h.inputChunks.join("")))await O(c,d,"{}"),h.emptyArgumentsEmitted=!0;else if(void 0!==g&&""!==g){let a="string"==typeof g?g:JSON.stringify(g);await O(c,d,a)}}}if("messageStopEvent"===f&&(H.endDetected=!0,await P(c)),"contextUsageEvent"===f&&a.payload?.contextUsagePercentage&&(H.contextUsagePercentage=a.payload.contextUsagePercentage,H.hasContextUsage=!0),"meteringEvent"===f&&(H.hasMeteringEvent=!0),"metricsEvent"===f){let b=a.payload?.metricsEvent||a.payload;if(b&&"object"==typeof b){let a=b.inputTokens||0,c=b.outputTokens||0;(a>0||c>0)&&(H.usage=function(a,b=null){let c=Number(a?.inputTokens)||0,d=Number(a?.outputTokens)||0,e={...b&&"object"==typeof b?b:{},prompt_tokens:c,completion_tokens:d,total_tokens:c+d},f=
|
|
313
|
+
`)}if(!0===a.stop&&(null===h.inputKind&&void 0===g||"string"===h.inputKind&&""===h.inputChunks.join("")))await O(c,d,"{}"),h.emptyArgumentsEmitted=!0;else if(void 0!==g&&""!==g){let a="string"==typeof g?g:JSON.stringify(g);await O(c,d,a)}}}if("messageStopEvent"===f&&(H.endDetected=!0,await P(c)),"contextUsageEvent"===f&&a.payload?.contextUsagePercentage&&(H.contextUsagePercentage=a.payload.contextUsagePercentage,H.hasContextUsage=!0),"meteringEvent"===f&&(H.hasMeteringEvent=!0),"metricsEvent"===f){let b=a.payload?.metricsEvent||a.payload;if(b&&"object"==typeof b){let a=b.inputTokens||0,c=b.outputTokens||0;(a>0||c>0)&&(H.usage=function(a,b=null){let c=Number(a?.inputTokens)||0,d=Number(a?.outputTokens)||0,e={...b&&"object"==typeof b?b:{},prompt_tokens:c,completion_tokens:d,total_tokens:c+d},f=M(a,"cacheReadInputTokens","cache_read_input_tokens"),g=M(a,"cacheCreationInputTokens","cache_creation_input_tokens");return void 0!==f&&(e.cache_read_input_tokens=f),void 0!==g&&(e.cache_creation_input_tokens=g),e}(b,H.usage))}}if(H.hasMeteringEvent&&H.hasContextUsage&&!H.usage){let a=H.totalContentLength>0?Math.max(1,Math.floor(H.totalContentLength/4)):0,b=H.contextUsagePercentage>0?Math.floor(2e5*H.contextUsagePercentage/100):0;H.usage={prompt_tokens:b,completion_tokens:a,total_tokens:b+a}}}}},async flush(a){if(!H.streamFailed&&G)for(let b of y(H.taggedThinking))"reasoning"===b.type?await Q(a,b.text):await R(a,b.text);if(!H.streamFailed)try{i.finish(),H.endDetected=!0,await P(a)}catch(b){if(!(b?.code==="KIRO_STREAM_MISSING_TERMINAL"&&(H.hasTextContent||H.hasReasoningContent||H.hasCodeContent||H.hasToolCalls||H.contentFiltered))){H.streamFailed=!0,H.protocolFailed=!0,H.finishEmitted=!0;let c=K(e,b?.code);await J(a,c)}}if(!H.streamFailed&&H.hasToolCalls)try{for(let a of H.toolFrames.values()){let b,c=a.stopped||H.endDetected;if("object"===a.inputKind)b=a.inputObject;else if("string"===a.inputKind){let d=a.inputChunks.join("");b=""===d&&c?{}:JSON.parse(d)}else if(c)b={};else throw Error("missing tool input");if(!b||"object"!=typeof b||Array.isArray(b))throw Error("tool input must be an object");if("tool_call"===a.name){if("string"!=typeof b.name||!b.name.trim())throw Error("missing nested tool name");if(!Object.prototype.hasOwnProperty.call(b,"arguments"))throw Error("missing nested tool arguments")}}}catch{await N(a)}if(!H.finishEmitted&&!H.streamFailed){H.finishEmitted=!0;let c={id:s,object:"chat.completion.chunk",created:w,model:b,choices:[{index:0,delta:{},finish_reason:H.contentFiltered?"content_filter":H.hasToolCalls?"tool_calls":"stop"}]};if(H.usage)c.usage=H.usage;else if(H.contentFiltered&&(H.hasContextUsage||H.contextUsagePercentage>0)){let a=H.contextUsagePercentage>0?Math.floor(2e5*H.contextUsagePercentage/100):0,b=H.totalContentLength>0?Math.max(1,Math.floor(H.totalContentLength/4)):0;c.usage={prompt_tokens:a,completion_tokens:b,total_tokens:a+b}}"number"==typeof H.contextUsagePercentage&&Number.isFinite(H.contextUsagePercentage)&&(c.context_usage_percentage=H.contextUsagePercentage),await I(a,`data: ${JSON.stringify(c)}
|
|
314
314
|
|
|
315
|
-
`)}if(H.streamFailed){j&&!H.protocolFailed&&u(g),a.enqueue(l.encode("data: [DONE]\n\n"));return}if(await
|
|
315
|
+
`)}if(H.streamFailed){j&&!H.protocolFailed&&u(g),a.enqueue(l.encode("data: [DONE]\n\n"));return}if(await I(a,"data: [DONE]\n\n"),j){let b=await j.readAll();await j.cleanup(),u(g),a.enqueue(b)}}});if(!a.body)return t(g),j?.cleanup?.().catch(()=>{}),L(a,K(e));let U=a.body.pipeThrough(T);if(j){let a=U.getReader();U=new ReadableStream({async pull(b){try{let c=await a.read();if(c.done){await j.cleanup(),b.close();return}b.enqueue(c.value)}catch(a){v(g),await j.cleanup(),b.error(a)}},async cancel(b){try{await a.cancel(b)}finally{v(g),await j.cleanup()}}})}return new Response(U,{status:a.status,statusText:a.statusText,headers:{"Content-Type":"text/event-stream","Cache-Control":"no-cache",Connection:"keep-alive"}})}async refreshCredentials(a,b,c=null,d=null){if(!a.refreshToken){let a=Error("Kiro refresh credential is missing");throw a.name="KiroRefreshCredentialError",a.status=k.gx.UNAUTHORIZED,a.code="MISSING_REFRESH_TOKEN",a.permanent=!0,a}try{return await (0,g.Ql)(a.refreshToken,a.providerSpecificData,b,c,d)}catch(a){if(d?.aborted||a?.name==="AbortError"||(b?.error?.("TOKEN",a?.permanent===!0?"Kiro refresh credential was rejected":"Kiro refresh failed due to a transient error"),a?.permanent===!0))throw a;return null}}canRefreshCredentials(){return!0}}},32447:(a,b,c)=>{"use strict";c.d(b,{BL:()=>g});var d=c(43712),e=c(52007);let f=["anthropic_version","anthropic_beta","client_metadata","mcp_servers","stop_sequences","thinking","top_k"];class g extends d.L{constructor(){super("kimchi")}transformRequest(a,b,c,d){let g,h=super.transformRequest(a,b,c,d);if(!h||"object"!=typeof h)return h;for(let a of(!function(a){var b;if(!a?.system||!Array.isArray(a.messages))return;let c=("string"==typeof(b=a.system)?b:Array.isArray(b)?b.map(a=>"string"==typeof a?a:"string"==typeof a?.text?a.text:"").filter(Boolean).join("\n"):"").trim();if(!c)return;let d=a.messages.find(a=>a?.role==="system");d?"string"==typeof d.content?d.content=`${c}
|
|
316
316
|
|
|
317
317
|
${d.content}`:Array.isArray(d.content)&&d.content.unshift({type:"text",text:c}):a.messages.unshift({role:"system",content:c})}(h),f))void 0!==h[a]&&delete h[a];if(delete h.system,g=(0,e.gK)(a),(g?.provider==="anthropic"||g?.upstreamProvider==="anthropic"||/(^|[-_/])(?:claude|anthropic)(?:[-_/]|$)/i.test(String(a||"")))&&(delete h.reasoning_effort,delete h.reasoning,delete h.thinking),Array.isArray(h?.messages))for(let a of h.messages)a&&"object"==typeof a&&(delete a.cache_control,Array.isArray(a.content)&&(a.content=a.content.map(a=>{if(!a||"object"!=typeof a)return a;let{cache_control:b,signature:c,...d}=a;return d})));Array.isArray(h?.tools)&&(h.tools=h.tools.map(a=>{if(!a||"object"!=typeof a)return a;let{cache_control:b,...c}=a;return c}));if(Array.isArray(h?.messages))for(let a of h.messages)a&&"assistant"===a.role&&"string"==typeof a.reasoning_content&&a.reasoning_content.length>8&&delete a.reasoning_content;return h}}},32546:(a,b,c)=>{"use strict";c.d(b,{o:()=>l});var d=c(86871),e=c(14170),f=c(4305),g=c(99239),h=c(71782);function i(a,b,c){if("string"!=typeof b||!b)return;let d=new Set;for(let e of a)"string"!=typeof e||!e||d.has(e)||(d.add(e),(0,h.Sk)(e,b,c?.sessionId||null,c?.model||null))}function j(a,b){a.messageId||(a.messageId=b.responseId||`msg_${Date.now()}`,a.model=b.modelVersion||a.model||"gemini",a.functionIndex=0)}function k(a,b=null){if(!a.responseStarted||a.finishReasonSent)return null;let c=(0,f.Jm)(b,{format:e.h.GEMINI,hasToolCalls:(a.toolCalls?.size||0)>0});return a.finishReason=c,a.finishReasonSent=!0,{id:`chatcmpl-${a.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:a.model,choices:[{index:0,delta:{},finish_reason:c}],...a.usage?{usage:a.usage}:{}}}function l(a,b){let c,d;if(!a){if("antigravity"!==b.provider)return null;let a=k(b);return a?[a]:null}let e=a.response||a;if(!e)return null;if(c=e?.usageMetadata||a?.usageMetadata,(d=(0,g.i)(c))&&(b.usage=d),!e.candidates?.[0]){let a=e.promptFeedback?.blockReason;if(!(0,f.od)(a))return null;j(b,e),b.responseStarted=!0;let c=k(b,a);return c?[c]:null}let h=[],l=e.candidates[0],m=l.content;if(b.responseStarted=!0,b.messageId||(j(b,e),h.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}]})),m?.parts)for(let a of m.parts){let c=a.thoughtSignature||a.thought_signature,d=!0===a.thought;if("string"==typeof c&&c&&(b.pendingThoughtSignature=c),d&&!c&&void 0!==a.text&&""!==a.text&&h.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{reasoning_content:a.text},finish_reason:null}]}),c){let e=void 0!==a.text&&""!==a.text,f=!!a.functionCall;if(e&&h.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:d?{reasoning_content:a.text}:{content:a.text},finish_reason:null}]}),!e&&!f)continue;if(f){let d=a.functionCall.name,e=b.toolNameMap?.get(d)||d,f=a.functionCall.args||{},g=b.functionIndex++,j=a.functionCall.id||`${e}-${Date.now()}-${g}`;i([a.functionCall.id,j],c,b),b.pendingThoughtSignature=null;let k={id:j,index:g,type:"function",function:{name:e,arguments:JSON.stringify(f)}};b.toolCalls.set(g,k),h.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[k]},finish_reason:null}]})}continue}if(d||void 0===a.text||""===a.text||h.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,d=b.toolNameMap?.get(c)||c,e=a.functionCall.args||{},f=b.functionIndex++,g=a.functionCall.id||`${d}-${Date.now()}-${f}`;i([a.functionCall.id,g],b.pendingThoughtSignature,b),b.pendingThoughtSignature=null;let j={id:g,index:f,type:"function",function:{name:d,arguments:JSON.stringify(e)}};b.toolCalls.set(f,j),h.push({id:`chatcmpl-${b.messageId}`,object:"chat.completion.chunk",created:Math.floor(Date.now()/1e3),model:b.model,choices:[{index:0,delta:{tool_calls:[j]},finish_reason:null}]})}let e=a.inlineData||a.inline_data;if(e?.data){let a=e.mimeType||e.mime_type||"image/png";h.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,${e.data}`}}]},finish_reason:null}]})}}if(l.finishReason){let a=k(b,l.finishReason);a&&h.push(a)}return h.length>0?h:null}(0,d.kz)(e.h.GEMINI,e.h.OPENAI,null,l),(0,d.kz)(e.h.GEMINI_CLI,e.h.OPENAI,null,l),(0,d.kz)(e.h.ANTIGRAVITY,e.h.OPENAI,null,l),(0,d.kz)(e.h.VERTEX,e.h.OPENAI,null,l)},33801:(a,b,c)=>{"use strict";c.d(b,{Ws:()=>az,nZ:()=>ay,GH:()=>au,Y8:()=>ax});var d=c(14170);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(38492),i=c(9024),j=c(55399),k=c(60210);let l=["text","image_url","image","input_audio","audio_url","file"];var m=c(35024),n=c(57647),o=c(80662),p=c(86871);c(60983),c(19979);var q=c(3156);function r(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,q.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&&"text"===c[0].type?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,p.kz)(d.h.GEMINI,d.h.OPENAI,r,null),(0,p.kz)(d.h.GEMINI_CLI,d.h.OPENAI,r,null);var s=c(97102),t=c(96281);(0,p.kz)(d.h.OPENAI,d.h.VERTEX,function(a,b,c,d){var e=(0,s.m$)(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=t.n6),b.functionCall&&"id"in b.functionCall&&delete b.functionCall.id,b.functionResponse&&"id"in b.functionResponse&&delete b.functionResponse.id;return e},null);var u=c(58028);function v(a){return String(a||"tool").replace(/[^a-zA-Z0-9_-]/g,"_").slice(0,40)||"tool"}(0,p.kz)(d.h.ANTIGRAVITY,d.h.OPENAI,function(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,q.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=(0,u.v)(b)||"high")}}if(d.systemInstruction){var f;let a="string"==typeof(f=d.systemInstruction)?f:f.parts&&Array.isArray(f.parts)?f.parts.map(a=>a.text||"").join(""):"";a&&e.messages.push({role:"system",content:a})}if(d.contents&&Array.isArray(d.contents)){let a={nextGeneratedId:0,pendingCallIdsByName:new Map};for(let b of d.contents){let c=function(a,b){let c="model"===a.role?"assistant":"user"===a.role?"user":a.role;if(!a.parts||!Array.isArray(a.parts))return null;let d=[],e=[],f=[],g="";for(let c of a.parts){if(!0===c.thought&&c.text){g+=c.text;continue}if(c.thoughtSignature&&void 0!==c.text){d.push({type:"text",text:c.text});continue}if(void 0!==c.text&&d.push({type:"text",text:c.text}),c.inlineData&&d.push({type:"image_url",image_url:{url:`data:${c.inlineData.mimeType};base64,${c.inlineData.data}`}}),c.functionCall){let a=function(a,b){let c=a.name||"tool",d=a.id||`call_${v(c)}_${b.nextGeneratedId++}`,e=b.pendingCallIdsByName.get(c)||[];return e.push(d),b.pendingCallIdsByName.set(c,e),d}(c.functionCall,b);e.push({id:a,type:"function",function:{name:c.functionCall.name,arguments:JSON.stringify(c.functionCall.args||{})}})}c.functionResponse&&f.push({role:"tool",tool_call_id:function(a,b){let c=a.name||"tool",d=b.pendingCallIdsByName.get(c)||[];if(a.id){let b=d.indexOf(a.id);return b>=0&&d.splice(b,1),a.id}let e=d.shift();return 0===d.length&&b.pendingCallIdsByName.delete(c),e||`call_${v(c)}_response_${b.nextGeneratedId++}`}(c.functionResponse,b),content:JSON.stringify(c.functionResponse.response?.result||c.functionResponse.response||{})})}let h=null;if(e.length>0){let a={role:"assistant"};d.length>0&&(a.content=1===d.length&&"text"===d[0].type?d[0].text:d),g&&(a.reasoning_content=g),a.tool_calls=e,h=a}if(!h&&(d.length>0||g)){let a={role:c};d.length>0&&(a.content=1===d.length&&"text"===d[0].type?d[0].text:d),g&&(a.reasoning_content=g),h=a}return f.length>0?h?[...f,h]:f:h}(b,a);c&&(Array.isArray(c)?e.messages.push(...c):e.messages.push(c))}}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},null),c(65377);var w=c(47293),x=c(6382),y=c(55511),z=c.n(y),A=c(41004);let B=new Map;function C(a){return null==a?a:JSON.parse(JSON.stringify(a))}function D(a,b,c=""){let d=`${a||"anon"}:${c?`${c}:`:""}${String(b||"").slice(0,4096)}`,e=z().createHash("sha256").update(d).digest("hex");return[e.slice(0,8),e.slice(8,12),`4${e.slice(13,16)}`,`8${e.slice(17,20)}`,e.slice(20,32)].join("-")}function E(a,b){return a?.userInputMessage&&!a.userInputMessage.modelId&&b&&(a.userInputMessage.modelId=b),a}function F(a,b){for(let c of a||[])E(c,b);return a}function G(a,b,c){let d=C(a)||{userInputMessage:{content:""}};if(d.userInputMessage||(d.userInputMessage={content:""}),E(d,c),b){let a=d.userInputMessage.content||"";d.userInputMessage.content=a?`${b}
|
|
318
318
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";exports.id=5626,exports.ids=[5626],exports.modules={15626:(a,b,c)=>{c.d(b,{buildClineHeaders:()=>f,resolveClineCredential:()=>e});let d=c(39006).version||"0.0.0";function e(a){let b="string"==typeof a?.apiKey?a.apiKey.trim():"";return b?{token:b,isApiKey:!0}:{token:a?.accessToken,isApiKey:!1}}function f(a,b={},c={}){let e=function(a,b={}){let c=function(a,{isApiKey:b=!1}={}){if("string"!=typeof a)return"";let c=a.trim();return c?b||c.startsWith("workos:")?c:`workos:${c}`:""}(a,b);return c?`Bearer ${c}`:""}(a,c),g={"HTTP-Referer":"https://cline.bot","X-Title":"Cline","User-Agent":`ZevaiRouter/${d}`,"X-PLATFORM":process.platform||"unknown","X-PLATFORM-VERSION":process.version||"unknown","X-CLIENT-TYPE":"zevairouter","X-CLIENT-VERSION":d,"X-CORE-VERSION":d,"X-IS-MULTIROOT":"false",...b};return e&&(g.Authorization=e),g}},39006:a=>{a.exports=JSON.parse('{"name":"zevairouter","version":"1.1.
|
|
1
|
+
"use strict";exports.id=5626,exports.ids=[5626],exports.modules={15626:(a,b,c)=>{c.d(b,{buildClineHeaders:()=>f,resolveClineCredential:()=>e});let d=c(39006).version||"0.0.0";function e(a){let b="string"==typeof a?.apiKey?a.apiKey.trim():"";return b?{token:b,isApiKey:!0}:{token:a?.accessToken,isApiKey:!1}}function f(a,b={},c={}){let e=function(a,b={}){let c=function(a,{isApiKey:b=!1}={}){if("string"!=typeof a)return"";let c=a.trim();return c?b||c.startsWith("workos:")?c:`workos:${c}`:""}(a,b);return c?`Bearer ${c}`:""}(a,c),g={"HTTP-Referer":"https://cline.bot","X-Title":"Cline","User-Agent":`ZevaiRouter/${d}`,"X-PLATFORM":process.platform||"unknown","X-PLATFORM-VERSION":process.version||"unknown","X-CLIENT-TYPE":"zevairouter","X-CLIENT-VERSION":d,"X-CORE-VERSION":d,"X-IS-MULTIROOT":"false",...b};return e&&(g.Authorization=e),g}},39006:a=>{a.exports=JSON.parse('{"name":"zevairouter","version":"1.1.66","description":"Self-hosted AI router: many providers, one OpenAI-compatible /v1 endpoint and dashboard","bin":{"zevai":"cli/cli.js"},"files":["cli/cli.js","cli/app/","!cli/app/.next-cli-build/cache/","!cli/app/.next-cli-build/server/route-cache/","cli/hooks/","cli/src/","cli/package.json","cli/README.md","cli/LICENSE","scripts/start-standalone.mjs","scripts/gflow-reply-capture.py","scripts/flow-vps-setup.sh","skills/","README.md","README.zh-CN.md","DOCKER.md","LICENSE","CHANGELOG.md"],"scripts":{"dev":"next dev --webpack --port 1997","build":"node scripts/build-app.mjs","start":"node ./scripts/start-standalone.mjs","dev:bun":"bun --bun next dev --webpack --port 1997","build:bun":"bun --bun next build --webpack","start:bun":"bun ./.next/standalone/server.js","lint":"eslint .","test":"vitest run --config tests/vitest.config.js","build:cli":"node cli/scripts/build-cli.js","audit:package":"node cli/scripts/audit-package.mjs","smoke:package":"node cli/scripts/smoke-package.mjs","verify:mobile-scroll":"node cli/scripts/verify-dashboard-mobile-scroll.mjs","candidate:build":"node cli/scripts/local-candidate.mjs build","candidate:install":"node cli/scripts/local-candidate.mjs install","candidate:status":"node cli/scripts/local-candidate.mjs status","candidate:rollback":"node cli/scripts/local-candidate.mjs rollback","release":"node cli/scripts/release.js","prepack":"npm run build:cli && npm run audit:package","postinstall":"node cli/hooks/postinstall.js"},"dependencies":{"confbox":"0.2.4","node-machine-id":"1.1.12","react":"19.2.4","react-dom":"19.2.4"},"comment_published_runtime":"npm install -g must not download next or @next/swc. Those, plus sql.js, yaml, and @node-saml/node-saml, stay devDependencies so local dev and build:cli can trace them into cli/app. The published tarball already ships that standalone server. confbox stays here because the CLI imports it directly.","comment_optional_runtime":"Optional packages are installed into ~/.zevai/runtime instead of the published tarball. Automation uses CloakBrowser with playwright-core; ZEVAI_MINIMAL_POSTINSTALL=1 skips its browser download. Other lazy runtimes are better-sqlite3, node-pty, and systray2.","overrides":{"body-parser":"^2.3.0","brace-expansion":"5.0.12","dompurify":"^3.4.12","ip-address":"^10.4.0","js-yaml":"4.3.2","nanoid":"^3.3.18","postcss":"^8.5.10","sharp":"0.35.5"},"comment_overrides":"Security floors for transitive dependencies. ESLint\'s legacy minimatch is a private, source-pinned 3.1.5 compatibility package backed by brace-expansion 5.0.9; modern minimatch and nanoid use fixed floors directly. Monaco still pins an old DOMPurify; Express, Next, ESLint, and image processing dependencies may resolve vulnerable body-parser, js-yaml, or sharp releases. Recheck and remove overrides once parent packages require fixed versions.","devDependencies":{"@dnd-kit/core":"^6.3.1","@dnd-kit/modifiers":"^9.0.0","@dnd-kit/sortable":"^10.0.0","@dnd-kit/utilities":"^3.2.2","@monaco-editor/react":"^4.7.0","@node-saml/node-saml":"5.1.0","@tailwindcss/postcss":"^4.1.18","@xterm/addon-fit":"^0.11.0","@xterm/addon-web-links":"^0.12.0","@xterm/xterm":"^6.0.0","@xyflow/react":"^12.10.1","bcryptjs":"^3.0.3","better-sqlite3":"^12.6.2","chalk":"^4.1.2","dompurify":"^3.4.12","esbuild":"^0.28.1","eslint":"^9","eslint-config-next":"16.4.2","express":"^5.2.1","jose":"^6.1.3","marked":"^18.0.1","material-symbols":"^0.45.1","minimatch":"file:vendor/minimatch3-secure","monaco-editor":"^0.55.1","next":"16.4.2","node-forge":"^1.4.2","open":"^11.0.0","ora":"^9.1.0","postcss":"^8.5.10","prop-types":"^15.8.1","react-is":"^19.2.7","recharts":"^3.7.0","selfsigned":"^5.5.0","socks":"^2.8.9","socks-proxy-agent":"^10.1.0","sql.js":"1.14.1","tailwindcss":"^4","typescript":"6.0.3","undici":"^8.10.0","uuid":"^14.0.1","vitest":"4.1.12","yaml":"2.9.0","zustand":"^5.0.10"},"engines":{"node":">=22.5.0"},"keywords":["zevairouter","zevai","ai","router","proxy","kiro","codebuddy","claude","openai","api","quota","automation"],"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Verifiedlabs/zevairouter.git"},"bugs":{"url":"https://github.com/Verifiedlabs/zevairouter/issues"},"homepage":"https://github.com/Verifiedlabs/zevairouter"}')}};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";exports.id=5744,exports.ids=[5744],exports.modules={25744:(a,b,c)=>{c.r(b),c.d(b,{DELETE:()=>F,GET:()=>C,PATCH:()=>E,POST:()=>D});var d=c(49796),e=c(23211),f=c(79984),g=c(35175),h=c(36074),i=c(61860);let j=Object.freeze({input:["text","image"],output:["text"]}),k=Object.freeze({thinking:"high"}),l=a=>!!a&&"object"==typeof a&&!Array.isArray(a);var m=c(79748),n=c.n(m),o=c(33873),p=c.n(o),q=c(21820),r=c.n(q),s=c(24424);let t="zevai",u=`${t}/`,v=()=>p().join(r().homedir(),".config","opencode"),w=async()=>{let a=p().join(v(),"opencode.json"),b=p().join(v(),"opencode.jsonc");try{return await n().access(a),a}catch{try{return await n().access(b),b}catch{return a}}},x=async a=>{try{return await n().access(a),!0}catch{return!1}},y=async()=>{let a=await (0,g.hA)("opencode");return a?{installed:!0,binaryPath:a}:{installed:await x(await w()),binaryPath:null}},z=async(a,b)=>{let c=await n().realpath(a).catch(()=>a);await (0,h.Pl)(c,`${JSON.stringify(b,null,2)}
|
|
2
|
+
`)},A=async a=>{let b=a||await w();try{let a=await n().readFile(b,"utf-8");if(!a.trim())return null;let c=function(a){try{return JSON.parse(a)}catch{return JSON.parse(function(a){let b=String(a??"").replace(/^\uFEFF/,""),c="",d=0;for(;d<b.length;){let a=b[d],e=b[d+1];if('"'===a){let a=d+1;for(;a<b.length&&'"'!==b[a];)a+="\\"===b[a]?2:1;c+=b.slice(d,a+1),d=a+1}else if("/"===a&&"/"===e)for(;d<b.length&&"\n"!==b[d];)d+=1;else if("/"===a&&"*"===e){let a=b.indexOf("*/",d+2);d=-1===a?b.length:a+2}else c+=a,d+=1}let e="";for(let a=0;a<c.length;a+=1){let b=c[a];if('"'===b){let b=a+1;for(;b<c.length&&'"'!==c[b];)b+="\\"===c[b]?2:1;e+=c.slice(a,b+1),a=b;continue}if(","===b){let b=a+1;for(;b<c.length&&/\s/.test(c[b]);)b+=1;if("}"===c[b]||"]"===c[b])continue}e+=b}return e}(a))}}(a);if(!l(c))throw Error("OpenCode config is not a JSON object");return c}catch(a){if("ENOENT"===a.code)return null;throw a}},B=a=>"string"==typeof a&&a.startsWith(u)?a.slice(u.length):null;async function C(){try{var a;let{installed:b,binaryPath:c}=await y();if(!b)return e.NextResponse.json({installed:!1,config:null,message:"OpenCode CLI is not installed"});let d=await w(),f=null,h=null;try{f=await A(d)}catch{h=`Could not parse ${p().basename(d)}. Fix the file or remove it before applying settings.`}let i=f?.provider?.[t],j=l(i?.models)?i.models:{},k=c?await (0,g.be)(c):null;return e.NextResponse.json({installed:!0,binaryPath:c,version:k,config:f,configError:h,hasZevai:(a=f,!!a?.provider&&!!a.provider[t]),configPath:d,opencode:{models:Object.keys(j),activeModel:B(f?.model),baseURL:i?.options?.baseURL||null,variants:Object.fromEntries(Object.entries(j).map(([a,b])=>[a,l(b?.variants)?Object.keys(b.variants):[]]))}})}catch(a){return console.log("Error checking opencode settings:",a),e.NextResponse.json({error:"Failed to check opencode settings"},{status:500})}}async function D(a){try{let b,{baseUrl:c,apiKey:d,model:g,models:m,activeModel:n,subagentModel:o}=await a.json(),q=Array.isArray(m)?m:"string"==typeof g?[g]:[],r=[...new Set(q.filter(a=>"string"==typeof a&&a.trim()).map(a=>a.trim()))];if(!c||0===r.length)return e.NextResponse.json({error:"baseUrl and at least one model are required"},{status:400});let s=(0,h.hq)(c);if(!s)return e.NextResponse.json({error:"baseUrl must be an http(s) URL"},{status:400});let v=await w();try{b=await A(v)||{}}catch{return e.NextResponse.json({error:`Could not parse ${p().basename(v)}; fix or remove it before applying settings`},{status:422})}let x=await (0,f.k7)(d),y="string"==typeof o&&o.trim()||r[0],B=""===n?"":"string"==typeof n&&n.trim()||r[0],C=[...r];for(let a of[B,y])a&&!C.includes(a)&&C.push(a);l(b.provider)||(b.provider={});let D=l(b.provider[t])?{...b.provider[t]}:{};D.npm=D.npm||"@ai-sdk/openai-compatible",D.options={...l(D.options)?D.options:{},baseURL:s,apiKey:x},D.models=l(D.models)?{...D.models}:{};let E=await (0,i.M)(C);for(let a of C)D.models[a]=function(a,b,c){let d=l(a)?{...a}:{},e={...d,name:"string"==typeof d.name&&d.name.trim()?d.name:b,modalities:l(d.modalities)?d.modalities:{input:[...j.input],output:[...j.output]}};return void 0===c?e:{...e,...function(a,b=null){if(!Array.isArray(a)||0===a.length)return{reasoning:!1,variants:{}};let c=l(b)?b:{},d={};for(let b of a){if("string"!=typeof b||!b)continue;let a=l(c[b])?c[b]:{};d[b]={...a,reasoningEffort:k[b]||b}}return{reasoning:!0,variants:d}}(c,d.variants)}}(D.models[a],a,E.get(a));b.provider[t]=D,b.model=B?`${u}${B}`:"",l(b.agent)||(b.agent={});let F=l(b.agent.explorer)?b.agent.explorer:{};return b.agent.explorer={description:"Fast explorer subagent for codebase exploration",mode:"subagent",...F,model:`${u}${y}`},await z(v,b),e.NextResponse.json({success:!0,message:"OpenCode settings applied successfully!",configPath:v,variants:Object.fromEntries(C.map(a=>[a,Object.keys(D.models[a]?.variants||{})]))})}catch(a){return console.log("Error applying opencode settings:",a),e.NextResponse.json({error:"Failed to apply settings"},{status:500})}}async function E(a){try{let b,{clearActiveModel:c}=await a.json(),d=await w();try{b=await A(d)}catch{return e.NextResponse.json({error:`Could not parse ${p().basename(d)}`},{status:422})}if(!b)return e.NextResponse.json({success:!0,message:"No OpenCode config to update"});let f=!1;return!0===c&&null!==B(b.model)&&(b.model="",f=!0),f&&await z(d,b),e.NextResponse.json({success:!0,message:"Settings updated"})}catch(a){return console.log("Error patching opencode settings:",a),e.NextResponse.json({error:"Failed to patch settings"},{status:500})}}async function F(a){try{let b,{searchParams:c}=new URL(a.url),d=c.get("model"),f=await w();try{b=await A(f)}catch{return e.NextResponse.json({error:`Could not parse ${p().basename(f)}`},{status:422})}if(!b)return e.NextResponse.json({success:!0,message:"No OpenCode config to reset"});let g=l(b.provider?.[t])?b.provider[t]:null,h=()=>{l(b.provider)&&(delete b.provider[t],0===Object.keys(b.provider).length&&delete b.provider),null!==B(b.model)&&delete b.model,null!==B(b.agent?.explorer?.model)&&(delete b.agent.explorer,0===Object.keys(b.agent).length&&delete b.agent)};if(d){if(l(g?.models)){delete g.models[d];let a=Object.keys(g.models);if(0===a.length)h();else{let c=`${u}${a[0]}`;b.model===`${u}${d}`&&(b.model=c),b.agent?.explorer?.model===`${u}${d}`&&(b.agent.explorer.model=B(b.model)?b.model:c)}}}else h();return await z(f,b),e.NextResponse.json({success:!0,message:d?`Model "${d}" removed`:"ZevaiRouter settings removed from OpenCode"})}catch(a){return console.log("Error resetting opencode settings:",a),e.NextResponse.json({error:"Failed to reset opencode settings"},{status:500})}}(0,s.D)([C,D,E,F]),(0,d.A)(C,"003dcbaebc71030c996ed7db394a156cf3af265be8",null),(0,d.A)(D,"40170b9e5b2895a44245c03833a49cb8a5f5579b1a",null),(0,d.A)(E,"4027b046a8cf3b916cdb72081dff1e030ab43a55d7",null),(0,d.A)(F,"408676c2749ff23ca68f038454e46336a9812a4328",null)},35175:(a,b,c)=>{c.d(b,{be:()=>q,hA:()=>p});var d=c(79748),e=c.n(d),f=c(21820),g=c.n(f),h=c(33873),i=c.n(h),j=c(79646),k=c(28354),l=c(15507);let m=(0,k.promisify)(j.execFile);function n(a={}){let b=a.platform||g().platform(),c=a.env||process.env,d="win32"===b?";":":",e=String(c.PATH||c.Path||"").split(d),f=function({home:a=g().homedir(),platform:b=g().platform(),env:c=process.env,execPath:d=process.execPath,extraDirs:e=[]}={}){let f="win32"===b?i().win32.join:i().posix.join,h="win32"===b?i().win32.dirname:i().posix.dirname,j=[...e];return"win32"===b?(c.APPDATA&&j.push(f(c.APPDATA,"npm")),c.LOCALAPPDATA&&j.push(f(c.LOCALAPPDATA,"pnpm")),a&&j.push(f(a,".bun","bin"),f(a,".local","bin"))):(c.PNPM_HOME&&j.push(c.PNPM_HOME),c.BUN_INSTALL&&j.push(f(c.BUN_INSTALL,"bin")),c.NPM_CONFIG_PREFIX&&j.push(f(c.NPM_CONFIG_PREFIX,"bin")),c.npm_config_prefix&&j.push(f(c.npm_config_prefix,"bin")),a&&(j.push(f(a,".local","bin"),f(a,"bin"),f(a,".opencode","bin"),f(a,".bun","bin"),f(a,".npm-global","bin"),f(a,".volta","bin"),f(a,".cargo","bin"),f(a,".deno","bin"),f(a,".local","share","pnpm")),"darwin"===b&&j.push(f(a,"Library","pnpm"))),j.push("/opt/homebrew/bin","/usr/local/bin","/home/linuxbrew/.linuxbrew/bin","/usr/bin","/bin")),d&&j.push(h(d)),j.filter(Boolean)}({...a,platform:b,env:c});return[...new Set(("win32"===b&&c.APPDATA?[i().win32.join(c.APPDATA,"npm"),...e,...f]:[...e,...f]).filter(Boolean))].join(d)}async function o(a,b){try{if(!(await e().stat(a)).isFile())return!1;if("win32"===b)return!0;return await e().access(a,e().constants.X_OK),!0}catch{return!1}}async function p(a,b={}){if("string"!=typeof a||!/^[A-Za-z0-9._-]+$/.test(a))return null;let c=b.platform||g().platform(),d="win32"===c?i().win32.join:i().posix.join,e="win32"===c?[`${a}.cmd`,`${a}.exe`,`${a}.bat`,a]:[a];for(let a of n({...b,platform:c}).split("win32"===c?";":":"))if(a)for(let b of e){let e=d(a,b);if(await o(e,c))return e}return null}async function q(a,{args:b=["--version"],timeout:c=5e3,ttlMs:d=6e5}={}){if(!a)return null;let f=await e().realpath(a).catch(()=>a);return(0,l.ND)(`version:${f}:${b.join(" ")}`,{ttlMs:d,fingerprint:()=>(0,l.hC)(f)},()=>r(a,b,c))}async function r(a,b,c){try{let{stdout:d,stderr:e}=await m(a,b,{windowsHide:!0,timeout:c,env:function(a={}){return{...a.env||process.env,PATH:n(a)}}(),shell:"win32"===g().platform()&&/\.(cmd|bat)$/i.test(a)});return String(d||e||"").trim().split(/\r?\n/)[0]||null}catch{return null}}}};
|