@oh-my-pi/pi-ai 16.3.6 → 16.3.8
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 +18 -0
- package/dist/types/api-registry.d.ts +1 -1
- package/dist/types/auth-broker/client.d.ts +2 -2
- package/dist/types/auth-broker/discover.d.ts +1 -1
- package/dist/types/auth-broker/index.d.ts +7 -7
- package/dist/types/auth-broker/refresher.d.ts +1 -1
- package/dist/types/auth-broker/remote-store.d.ts +6 -6
- package/dist/types/auth-broker/server.d.ts +1 -1
- package/dist/types/auth-broker/snapshot-cache.d.ts +1 -1
- package/dist/types/auth-broker/types.d.ts +2 -2
- package/dist/types/auth-gateway/index.d.ts +3 -3
- package/dist/types/auth-gateway/server.d.ts +3 -3
- package/dist/types/auth-gateway/types.d.ts +1 -1
- package/dist/types/auth-retry.d.ts +2 -2
- package/dist/types/auth-storage.d.ts +6 -6
- package/dist/types/dialect/anthropic.d.ts +1 -1
- package/dist/types/dialect/catalog.d.ts +1 -1
- package/dist/types/dialect/coercion.d.ts +1 -1
- package/dist/types/dialect/deepseek.d.ts +1 -1
- package/dist/types/dialect/demotion.d.ts +16 -14
- package/dist/types/dialect/examples.d.ts +1 -1
- package/dist/types/dialect/factory.d.ts +1 -1
- package/dist/types/dialect/gemini.d.ts +1 -1
- package/dist/types/dialect/gemma.d.ts +1 -1
- package/dist/types/dialect/glm.d.ts +1 -1
- package/dist/types/dialect/harmony.d.ts +1 -1
- package/dist/types/dialect/hermes.d.ts +1 -1
- package/dist/types/dialect/history.d.ts +2 -2
- package/dist/types/dialect/index.d.ts +11 -11
- package/dist/types/dialect/inventory.d.ts +1 -1
- package/dist/types/dialect/kimi.d.ts +1 -1
- package/dist/types/dialect/minimax.d.ts +1 -1
- package/dist/types/dialect/owned-stream.d.ts +2 -2
- package/dist/types/dialect/qwen3.d.ts +1 -1
- package/dist/types/dialect/rendering.d.ts +2 -2
- package/dist/types/dialect/thinking.d.ts +1 -1
- package/dist/types/dialect/types.d.ts +1 -1
- package/dist/types/dialect/xml.d.ts +1 -1
- package/dist/types/error/classes.d.ts +1 -1
- package/dist/types/error/finalize.d.ts +3 -3
- package/dist/types/error/flags.d.ts +1 -1
- package/dist/types/error/format.d.ts +1 -1
- package/dist/types/error/index.d.ts +13 -13
- package/dist/types/error/provider.d.ts +1 -1
- package/dist/types/error/rate-limit.d.ts +1 -1
- package/dist/types/index.d.ts +47 -47
- package/dist/types/provider-details.d.ts +1 -1
- package/dist/types/providers/amazon-bedrock.d.ts +1 -1
- package/dist/types/providers/anthropic-client.d.ts +3 -3
- package/dist/types/providers/anthropic-messages-server-schema.d.ts +1 -1
- package/dist/types/providers/anthropic-messages-server.d.ts +2 -2
- package/dist/types/providers/anthropic-wire.d.ts +1 -1
- package/dist/types/providers/anthropic.d.ts +3 -3
- package/dist/types/providers/aws-credentials.d.ts +2 -2
- package/dist/types/providers/azure-openai-responses.d.ts +2 -2
- package/dist/types/providers/cursor.d.ts +18 -3
- package/dist/types/providers/devin.d.ts +1 -1
- package/dist/types/providers/error-message.d.ts +1 -1
- package/dist/types/providers/github-copilot-headers.d.ts +1 -1
- package/dist/types/providers/gitlab-duo-workflow.d.ts +2 -2
- package/dist/types/providers/gitlab-duo.d.ts +2 -2
- package/dist/types/providers/google-auth.d.ts +1 -1
- package/dist/types/providers/google-gemini-cli.d.ts +6 -4
- package/dist/types/providers/google-interactions.d.ts +3 -3
- package/dist/types/providers/google-shared.d.ts +7 -5
- package/dist/types/providers/google-vertex.d.ts +2 -2
- package/dist/types/providers/google.d.ts +2 -2
- package/dist/types/providers/kimi.d.ts +3 -3
- package/dist/types/providers/mock.d.ts +2 -2
- package/dist/types/providers/ollama.d.ts +1 -1
- package/dist/types/providers/openai-anthropic-shim.d.ts +2 -2
- package/dist/types/providers/openai-chat-server-schema.d.ts +1 -1
- package/dist/types/providers/openai-chat-server.d.ts +2 -2
- package/dist/types/providers/openai-codex/request-transformer.d.ts +1 -1
- package/dist/types/providers/openai-codex/response-handler.d.ts +1 -1
- package/dist/types/providers/openai-codex-responses.d.ts +3 -3
- package/dist/types/providers/openai-completions.d.ts +3 -3
- package/dist/types/providers/openai-reasoning-fallback.d.ts +1 -1
- package/dist/types/providers/openai-responses-server-schema.d.ts +1 -1
- package/dist/types/providers/openai-responses-server.d.ts +2 -2
- package/dist/types/providers/openai-responses.d.ts +5 -5
- package/dist/types/providers/openai-shared.d.ts +10 -9
- package/dist/types/providers/pi-native-client.d.ts +1 -1
- package/dist/types/providers/pi-native-server.d.ts +2 -2
- package/dist/types/providers/register-builtins.d.ts +3 -3
- package/dist/types/providers/synthetic.d.ts +3 -3
- package/dist/types/providers/transform-messages.d.ts +1 -1
- package/dist/types/providers/vision-guard.d.ts +1 -1
- package/dist/types/registry/alibaba-coding-plan.d.ts +1 -1
- package/dist/types/registry/anthropic.d.ts +1 -1
- package/dist/types/registry/api-key-login.d.ts +1 -1
- package/dist/types/registry/api-key-validation.d.ts +1 -1
- package/dist/types/registry/baseten.d.ts +2 -2
- package/dist/types/registry/cerebras.d.ts +2 -2
- package/dist/types/registry/cloudflare-ai-gateway.d.ts +1 -1
- package/dist/types/registry/coreweave.d.ts +2 -2
- package/dist/types/registry/cursor.d.ts +1 -1
- package/dist/types/registry/deepseek.d.ts +1 -1
- package/dist/types/registry/devin.d.ts +1 -1
- package/dist/types/registry/firepass.d.ts +2 -2
- package/dist/types/registry/fireworks.d.ts +2 -2
- package/dist/types/registry/github-copilot.d.ts +1 -1
- package/dist/types/registry/gitlab-duo-workflow.d.ts +1 -1
- package/dist/types/registry/gitlab-duo.d.ts +1 -1
- package/dist/types/registry/google-antigravity.d.ts +1 -1
- package/dist/types/registry/google-gemini-cli.d.ts +1 -1
- package/dist/types/registry/huggingface.d.ts +2 -2
- package/dist/types/registry/index.d.ts +4 -4
- package/dist/types/registry/kagi.d.ts +1 -1
- package/dist/types/registry/kilo.d.ts +1 -1
- package/dist/types/registry/kimi-code.d.ts +1 -1
- package/dist/types/registry/litellm.d.ts +1 -1
- package/dist/types/registry/llama-cpp.d.ts +1 -1
- package/dist/types/registry/lm-studio.d.ts +1 -1
- package/dist/types/registry/minimax-code-cn.d.ts +1 -1
- package/dist/types/registry/minimax-code.d.ts +1 -1
- package/dist/types/registry/moonshot.d.ts +2 -2
- package/dist/types/registry/nanogpt.d.ts +2 -2
- package/dist/types/registry/nvidia.d.ts +1 -1
- package/dist/types/registry/oauth/anthropic.d.ts +3 -3
- package/dist/types/registry/oauth/callback-server.d.ts +1 -1
- package/dist/types/registry/oauth/cursor.d.ts +1 -1
- package/dist/types/registry/oauth/devin.d.ts +1 -1
- package/dist/types/registry/oauth/github-copilot.d.ts +2 -2
- package/dist/types/registry/oauth/gitlab-duo-workflow.d.ts +2 -2
- package/dist/types/registry/oauth/gitlab-duo.d.ts +1 -1
- package/dist/types/registry/oauth/google-antigravity.d.ts +1 -1
- package/dist/types/registry/oauth/google-gemini-cli.d.ts +1 -1
- package/dist/types/registry/oauth/google-oauth-shared.d.ts +2 -2
- package/dist/types/registry/oauth/index.d.ts +2 -2
- package/dist/types/registry/oauth/kimi.d.ts +1 -1
- package/dist/types/registry/oauth/minimax-code.d.ts +2 -2
- package/dist/types/registry/oauth/openai-codex.d.ts +1 -1
- package/dist/types/registry/oauth/opencode.d.ts +1 -1
- package/dist/types/registry/oauth/perplexity.d.ts +1 -1
- package/dist/types/registry/oauth/types.d.ts +2 -2
- package/dist/types/registry/oauth/wafer.d.ts +1 -1
- package/dist/types/registry/oauth/xai-oauth.d.ts +3 -3
- package/dist/types/registry/oauth/xiaomi.d.ts +1 -1
- package/dist/types/registry/ollama-cloud.d.ts +1 -1
- package/dist/types/registry/ollama.d.ts +1 -1
- package/dist/types/registry/openai-codex-device.d.ts +1 -1
- package/dist/types/registry/openai-codex.d.ts +1 -1
- package/dist/types/registry/opencode-go.d.ts +1 -1
- package/dist/types/registry/opencode-zen.d.ts +1 -1
- package/dist/types/registry/openrouter.d.ts +2 -2
- package/dist/types/registry/parallel.d.ts +1 -1
- package/dist/types/registry/perplexity.d.ts +2 -2
- package/dist/types/registry/qianfan.d.ts +2 -2
- package/dist/types/registry/qwen-portal.d.ts +1 -1
- package/dist/types/registry/registry.d.ts +69 -69
- package/dist/types/registry/sakana.d.ts +2 -2
- package/dist/types/registry/synthetic.d.ts +2 -2
- package/dist/types/registry/tavily.d.ts +1 -1
- package/dist/types/registry/together.d.ts +1 -1
- package/dist/types/registry/types.d.ts +1 -1
- package/dist/types/registry/umans.d.ts +2 -2
- package/dist/types/registry/venice.d.ts +2 -2
- package/dist/types/registry/vercel-ai-gateway.d.ts +1 -1
- package/dist/types/registry/vllm.d.ts +1 -1
- package/dist/types/registry/wafer-serverless.d.ts +1 -1
- package/dist/types/registry/xai-oauth.d.ts +1 -1
- package/dist/types/registry/xiaomi-token-plan-ams.d.ts +1 -1
- package/dist/types/registry/xiaomi-token-plan-cn.d.ts +1 -1
- package/dist/types/registry/xiaomi-token-plan-sgp.d.ts +1 -1
- package/dist/types/registry/xiaomi.d.ts +1 -1
- package/dist/types/registry/zai.d.ts +2 -2
- package/dist/types/registry/zenmux.d.ts +2 -2
- package/dist/types/registry/zhipu-coding-plan.d.ts +2 -2
- package/dist/types/stream.d.ts +6 -6
- package/dist/types/types.d.ts +24 -21
- package/dist/types/usage/claude.d.ts +1 -1
- package/dist/types/usage/gemini.d.ts +1 -1
- package/dist/types/usage/github-copilot.d.ts +1 -1
- package/dist/types/usage/google-antigravity.d.ts +1 -1
- package/dist/types/usage/kimi.d.ts +1 -1
- package/dist/types/usage/minimax-code.d.ts +1 -1
- package/dist/types/usage/ollama.d.ts +1 -1
- package/dist/types/usage/openai-codex-reset.d.ts +1 -1
- package/dist/types/usage/openai-codex.d.ts +1 -1
- package/dist/types/usage/opencode-go.d.ts +1 -1
- package/dist/types/usage/zai.d.ts +1 -1
- package/dist/types/usage.d.ts +1 -1
- package/dist/types/utils/block-symbols.d.ts +15 -0
- package/dist/types/utils/empty-completion-retry.d.ts +2 -2
- package/dist/types/utils/event-stream.d.ts +1 -1
- package/dist/types/utils/harmony-leak.d.ts +1 -1
- package/dist/types/utils/http-inspector.d.ts +19 -0
- package/dist/types/utils/leaked-thinking-stream.d.ts +1 -1
- package/dist/types/utils/openai-http.d.ts +3 -9
- package/dist/types/utils/provider-response.d.ts +1 -1
- package/dist/types/utils/proxy.d.ts +1 -1
- package/dist/types/utils/request-debug.d.ts +1 -1
- package/dist/types/utils/retry.d.ts +1 -1
- package/dist/types/utils/schema/equality.d.ts +1 -1
- package/dist/types/utils/schema/index.d.ts +15 -15
- package/dist/types/utils/schema/normalize.d.ts +2 -2
- package/dist/types/utils/schema/spill.d.ts +1 -1
- package/dist/types/utils/schema/wire.d.ts +1 -1
- package/dist/types/utils/sse-debug.d.ts +1 -1
- package/dist/types/utils/thinking-loop.d.ts +2 -2
- package/dist/types/utils/tool-call-loop-guard.d.ts +1 -1
- package/dist/types/utils/tool-choice.d.ts +1 -1
- package/dist/types/utils/validation.d.ts +1 -1
- package/dist/types/utils.d.ts +14 -2
- package/package.json +4 -4
- package/src/dialect/demotion.ts +18 -19
- package/src/error/rate-limit.ts +1 -1
- package/src/providers/azure-openai-responses.ts +3 -2
- package/src/providers/cursor.ts +36 -0
- package/src/providers/google-gemini-cli.ts +12 -3
- package/src/providers/google-shared.ts +3 -1
- package/src/providers/mock.ts +10 -3
- package/src/providers/openai-codex-responses.ts +47 -39
- package/src/providers/openai-completions.ts +48 -9
- package/src/providers/openai-responses.ts +37 -23
- package/src/providers/openai-shared.ts +145 -26
- package/src/providers/transform-messages.ts +63 -9
- package/src/registry/oauth/wafer.ts +1 -1
- package/src/stream.ts +6 -0
- package/src/types.ts +27 -3
- package/src/utils/block-symbols.ts +18 -0
- package/src/utils/http-inspector.ts +32 -4
- package/src/utils/openai-http.ts +6 -9
- package/src/utils/retry-after.ts +12 -1
- package/src/utils.ts +78 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ProviderDefinition } from "./types";
|
|
1
|
+
import type { ProviderDefinition } from "./types.js";
|
|
2
2
|
/**
|
|
3
3
|
* The single per-provider list. Adding a provider = create `./providers/<id>.ts`
|
|
4
4
|
* and add its export here. Every legacy structure (`KnownProvider`/`OAuthProvider`
|
|
@@ -12,8 +12,8 @@ declare const ALL: ({
|
|
|
12
12
|
} | {
|
|
13
13
|
readonly id: "alibaba-coding-plan";
|
|
14
14
|
readonly name: "Alibaba Coding Plan";
|
|
15
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
16
|
-
readonly getApiKey: (credentials: import("./oauth").OAuthCredentials) => string;
|
|
15
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
16
|
+
readonly getApiKey: (credentials: import("./oauth/index.js").OAuthCredentials) => string;
|
|
17
17
|
} | {
|
|
18
18
|
readonly id: "amazon-bedrock";
|
|
19
19
|
readonly name: "Amazon Bedrock";
|
|
@@ -22,8 +22,8 @@ declare const ALL: ({
|
|
|
22
22
|
readonly id: "anthropic";
|
|
23
23
|
readonly name: "Anthropic (Claude Pro/Max)";
|
|
24
24
|
readonly envKeys: () => string | undefined;
|
|
25
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
26
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
25
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
26
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
27
27
|
readonly callbackPort: 54545;
|
|
28
28
|
readonly pasteCodeFlow: true;
|
|
29
29
|
} | {
|
|
@@ -32,60 +32,60 @@ declare const ALL: ({
|
|
|
32
32
|
} | {
|
|
33
33
|
readonly id: "baseten";
|
|
34
34
|
readonly name: "Baseten";
|
|
35
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
35
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
36
36
|
} | {
|
|
37
37
|
readonly id: "cerebras";
|
|
38
38
|
readonly name: "Cerebras";
|
|
39
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
39
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
40
40
|
} | {
|
|
41
41
|
readonly id: "cloudflare-ai-gateway";
|
|
42
42
|
readonly name: "Cloudflare AI Gateway";
|
|
43
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
43
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
44
44
|
} | {
|
|
45
45
|
readonly id: "coreweave";
|
|
46
46
|
readonly name: "CoreWeave Serverless Inference";
|
|
47
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
47
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
48
48
|
} | {
|
|
49
49
|
readonly id: "cursor";
|
|
50
50
|
readonly name: "Cursor (Claude, GPT, etc.)";
|
|
51
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
52
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
51
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
52
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
53
53
|
} | {
|
|
54
54
|
readonly id: "deepseek";
|
|
55
55
|
readonly name: "DeepSeek";
|
|
56
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
56
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
57
57
|
} | {
|
|
58
58
|
readonly id: "devin";
|
|
59
59
|
readonly name: "Devin";
|
|
60
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
60
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
61
61
|
readonly callbackPort: 59653;
|
|
62
62
|
readonly pasteCodeFlow: true;
|
|
63
63
|
} | {
|
|
64
64
|
readonly id: "firepass";
|
|
65
65
|
readonly name: "Fire Pass (Fireworks Kimi K2.6 Turbo subscription)";
|
|
66
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
66
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
67
67
|
} | {
|
|
68
68
|
readonly id: "fireworks";
|
|
69
69
|
readonly name: "Fireworks";
|
|
70
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
70
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
71
71
|
} | {
|
|
72
72
|
readonly id: "github-copilot";
|
|
73
73
|
readonly name: "GitHub Copilot";
|
|
74
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
75
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
74
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
75
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
76
76
|
} | {
|
|
77
77
|
readonly id: "gitlab-duo";
|
|
78
78
|
readonly name: "GitLab Duo Non-Agentic";
|
|
79
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
80
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
79
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
80
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
81
81
|
readonly callbackPort: 8080;
|
|
82
82
|
readonly pasteCodeFlow: true;
|
|
83
83
|
} | {
|
|
84
84
|
readonly id: "gitlab-duo-agent";
|
|
85
85
|
readonly name: "GitLab Duo Agent";
|
|
86
86
|
readonly envKeys: "GITLAB_TOKEN";
|
|
87
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
88
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
87
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
88
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
89
89
|
readonly callbackPort: 8080;
|
|
90
90
|
readonly pasteCodeFlow: true;
|
|
91
91
|
} | {
|
|
@@ -94,15 +94,15 @@ declare const ALL: ({
|
|
|
94
94
|
} | {
|
|
95
95
|
readonly id: "google-antigravity";
|
|
96
96
|
readonly name: "Antigravity (Gemini 3, Claude, GPT-OSS)";
|
|
97
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
98
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
97
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
98
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
99
99
|
readonly callbackPort: 51121;
|
|
100
100
|
readonly pasteCodeFlow: true;
|
|
101
101
|
} | {
|
|
102
102
|
readonly id: "google-gemini-cli";
|
|
103
103
|
readonly name: "Google Cloud Code Assist (Gemini CLI)";
|
|
104
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
105
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
104
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
105
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
106
106
|
readonly callbackPort: 8085;
|
|
107
107
|
readonly pasteCodeFlow: true;
|
|
108
108
|
} | {
|
|
@@ -115,187 +115,187 @@ declare const ALL: ({
|
|
|
115
115
|
} | {
|
|
116
116
|
readonly id: "huggingface";
|
|
117
117
|
readonly name: "Hugging Face Inference";
|
|
118
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
118
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
119
119
|
} | {
|
|
120
120
|
readonly id: "kagi";
|
|
121
121
|
readonly name: "Kagi";
|
|
122
122
|
readonly envKeys: "KAGI_API_KEY";
|
|
123
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
123
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
124
124
|
} | {
|
|
125
125
|
readonly id: "kilo";
|
|
126
126
|
readonly name: "Kilo Gateway";
|
|
127
|
-
readonly login: typeof import("./kilo").loginKilo;
|
|
127
|
+
readonly login: typeof import("./kilo.js").loginKilo;
|
|
128
128
|
} | {
|
|
129
129
|
readonly id: "kimi-code";
|
|
130
130
|
readonly name: "Kimi Code";
|
|
131
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
132
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
131
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
132
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
133
133
|
} | {
|
|
134
134
|
readonly id: "litellm";
|
|
135
135
|
readonly name: "LiteLLM";
|
|
136
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
136
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
137
137
|
} | {
|
|
138
138
|
readonly id: "llama.cpp";
|
|
139
139
|
readonly name: "llama.cpp (Local OpenAI-compatible)";
|
|
140
140
|
readonly envKeys: "LLAMA_CPP_API_KEY";
|
|
141
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
141
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
142
142
|
} | {
|
|
143
143
|
readonly id: "lm-studio";
|
|
144
144
|
readonly name: "LM Studio (Local OpenAI-compatible)";
|
|
145
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
145
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
146
146
|
} | {
|
|
147
147
|
readonly id: "minimax";
|
|
148
148
|
readonly name: "MiniMax";
|
|
149
149
|
} | {
|
|
150
150
|
readonly id: "minimax-code";
|
|
151
151
|
readonly name: "MiniMax Token Plan (International)";
|
|
152
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
152
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
153
153
|
} | {
|
|
154
154
|
readonly id: "minimax-code-cn";
|
|
155
155
|
readonly name: "MiniMax Token Plan (China)";
|
|
156
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
156
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
157
157
|
} | {
|
|
158
158
|
readonly id: "mistral";
|
|
159
159
|
readonly name: "Mistral";
|
|
160
160
|
} | {
|
|
161
161
|
readonly id: "moonshot";
|
|
162
162
|
readonly name: "Moonshot (Kimi API)";
|
|
163
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
163
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
164
164
|
} | {
|
|
165
165
|
readonly id: "nanogpt";
|
|
166
166
|
readonly name: "NanoGPT";
|
|
167
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
167
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
168
168
|
} | {
|
|
169
169
|
readonly id: "nvidia";
|
|
170
170
|
readonly name: "NVIDIA";
|
|
171
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
171
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
172
172
|
} | {
|
|
173
173
|
readonly id: "ollama";
|
|
174
174
|
readonly name: "Ollama (Local OpenAI-compatible)";
|
|
175
|
-
readonly login: typeof import("./ollama").loginOllama;
|
|
175
|
+
readonly login: typeof import("./ollama.js").loginOllama;
|
|
176
176
|
} | {
|
|
177
177
|
readonly id: "ollama-cloud";
|
|
178
178
|
readonly name: "Ollama Cloud";
|
|
179
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
179
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
180
180
|
} | {
|
|
181
181
|
readonly id: "openai";
|
|
182
182
|
readonly name: "OpenAI";
|
|
183
183
|
} | {
|
|
184
184
|
readonly id: "openai-codex";
|
|
185
185
|
readonly name: "ChatGPT Plus/Pro (Codex Subscription)";
|
|
186
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
187
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
186
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
187
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
188
188
|
readonly callbackPort: 1455;
|
|
189
189
|
readonly pasteCodeFlow: true;
|
|
190
190
|
} | {
|
|
191
191
|
readonly id: "openai-codex-device";
|
|
192
192
|
readonly name: "ChatGPT Plus/Pro (Codex, headless/device)";
|
|
193
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
194
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
193
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
194
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
195
195
|
readonly storeCredentialsAs: "openai-codex";
|
|
196
196
|
} | {
|
|
197
197
|
readonly id: "opencode-go";
|
|
198
198
|
readonly name: "OpenCode Go";
|
|
199
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
199
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
200
200
|
} | {
|
|
201
201
|
readonly id: "opencode-zen";
|
|
202
202
|
readonly name: "OpenCode Zen";
|
|
203
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
203
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
204
204
|
} | {
|
|
205
205
|
readonly id: "openrouter";
|
|
206
206
|
readonly name: "OpenRouter";
|
|
207
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
207
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
208
208
|
} | {
|
|
209
209
|
readonly id: "parallel";
|
|
210
210
|
readonly name: "Parallel";
|
|
211
211
|
readonly envKeys: "PARALLEL_API_KEY";
|
|
212
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
212
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
213
213
|
} | {
|
|
214
214
|
readonly id: "perplexity";
|
|
215
215
|
readonly name: "Perplexity (Pro/Max)";
|
|
216
216
|
readonly envKeys: "PERPLEXITY_API_KEY";
|
|
217
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
217
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
218
218
|
} | {
|
|
219
219
|
readonly id: "qianfan";
|
|
220
220
|
readonly name: "Qianfan";
|
|
221
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
221
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
222
222
|
} | {
|
|
223
223
|
readonly id: "qwen-portal";
|
|
224
224
|
readonly name: "Qwen Portal";
|
|
225
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
225
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
226
226
|
} | {
|
|
227
227
|
readonly id: "sakana";
|
|
228
228
|
readonly name: "Sakana AI";
|
|
229
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
229
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
230
230
|
} | {
|
|
231
231
|
readonly id: "synthetic";
|
|
232
232
|
readonly name: "Synthetic";
|
|
233
|
-
readonly login: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
233
|
+
readonly login: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
234
234
|
} | {
|
|
235
235
|
readonly id: "tavily";
|
|
236
236
|
readonly name: "Tavily";
|
|
237
237
|
readonly envKeys: "TAVILY_API_KEY";
|
|
238
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
238
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
239
239
|
} | {
|
|
240
240
|
readonly id: "together";
|
|
241
241
|
readonly name: "Together";
|
|
242
|
-
readonly login: (cb: Parameters<typeof import("./together").loginTogether>[0]) => Promise<string>;
|
|
242
|
+
readonly login: (cb: Parameters<typeof import("./together.js").loginTogether>[0]) => Promise<string>;
|
|
243
243
|
} | {
|
|
244
244
|
readonly id: "umans";
|
|
245
245
|
readonly name: "Umans AI Coding Plan";
|
|
246
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
246
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
247
247
|
} | {
|
|
248
248
|
readonly id: "venice";
|
|
249
249
|
readonly name: "Venice";
|
|
250
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
250
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
251
251
|
} | {
|
|
252
252
|
readonly id: "vercel-ai-gateway";
|
|
253
253
|
readonly name: "Vercel AI Gateway";
|
|
254
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
254
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
255
255
|
} | {
|
|
256
256
|
readonly id: "vllm";
|
|
257
257
|
readonly name: "vLLM (Local OpenAI-compatible)";
|
|
258
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
258
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
259
259
|
} | {
|
|
260
260
|
readonly id: "wafer-serverless";
|
|
261
261
|
readonly name: "Wafer Serverless (pay-as-you-go)";
|
|
262
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
262
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
263
263
|
} | {
|
|
264
264
|
readonly id: "xai";
|
|
265
265
|
readonly name: "xAI";
|
|
266
266
|
} | {
|
|
267
267
|
readonly id: "xai-oauth";
|
|
268
268
|
readonly name: "xAI Grok OAuth (SuperGrok Subscription)";
|
|
269
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<import("./oauth").OAuthCredentials>;
|
|
270
|
-
readonly refreshToken: (credentials: import("./oauth").OAuthCredentials) => Promise<import("./oauth").OAuthCredentials>;
|
|
269
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
270
|
+
readonly refreshToken: (credentials: import("./oauth/index.js").OAuthCredentials) => Promise<import("./oauth/index.js").OAuthCredentials>;
|
|
271
271
|
} | {
|
|
272
272
|
readonly id: "xiaomi";
|
|
273
273
|
readonly name: "Xiaomi MiMo";
|
|
274
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
274
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
275
275
|
} | {
|
|
276
276
|
readonly id: "xiaomi-token-plan-ams";
|
|
277
277
|
readonly name: "Xiaomi Token Plan (Europe)";
|
|
278
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
278
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
279
279
|
} | {
|
|
280
280
|
readonly id: "xiaomi-token-plan-cn";
|
|
281
281
|
readonly name: "Xiaomi Token Plan (China)";
|
|
282
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
282
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
283
283
|
} | {
|
|
284
284
|
readonly id: "xiaomi-token-plan-sgp";
|
|
285
285
|
readonly name: "Xiaomi Token Plan (Singapore)";
|
|
286
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
286
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
287
287
|
} | {
|
|
288
288
|
readonly id: "zai";
|
|
289
289
|
readonly name: "Z.AI (GLM Coding Plan)";
|
|
290
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
290
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
291
291
|
} | {
|
|
292
292
|
readonly id: "zenmux";
|
|
293
293
|
readonly name: "ZenMux";
|
|
294
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
294
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
295
295
|
} | {
|
|
296
296
|
readonly id: "zhipu-coding-plan";
|
|
297
297
|
readonly name: "Zhipu Coding Plan (智谱)";
|
|
298
|
-
readonly login: (cb: import("./oauth").OAuthLoginCallbacks) => Promise<string>;
|
|
298
|
+
readonly login: (cb: import("./oauth/index.js").OAuthLoginCallbacks) => Promise<string>;
|
|
299
299
|
})[];
|
|
300
300
|
export type RegistryDef = (typeof ALL)[number];
|
|
301
301
|
export declare const PROVIDER_REGISTRY: readonly ProviderDefinition[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
2
|
-
export declare const loginSakana: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
|
+
export declare const loginSakana: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
3
3
|
export declare const sakanaProvider: {
|
|
4
4
|
readonly id: "sakana";
|
|
5
5
|
readonly name: "Sakana AI";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export declare const loginSynthetic: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
export declare const loginSynthetic: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
2
2
|
export declare const syntheticProvider: {
|
|
3
3
|
readonly id: "synthetic";
|
|
4
4
|
readonly name: "Synthetic";
|
|
5
|
-
readonly login: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
5
|
+
readonly login: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
6
6
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const loginTogether: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
export declare const loginTogether: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
2
2
|
export declare const togetherProvider: {
|
|
3
3
|
readonly id: "together";
|
|
4
4
|
readonly name: "Together";
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* (default model, model-manager factory, catalog discovery) lives in
|
|
10
10
|
* `@oh-my-pi/pi-catalog`'s descriptor table.
|
|
11
11
|
*/
|
|
12
|
-
import type { OAuthCredentials, OAuthLoginCallbacks } from "./oauth/types";
|
|
12
|
+
import type { OAuthCredentials, OAuthLoginCallbacks } from "./oauth/types.js";
|
|
13
13
|
/**
|
|
14
14
|
* API-key environment fallback: either a single env var name (e.g.
|
|
15
15
|
* `"OPENAI_API_KEY"`) or a resolver that inspects several env vars / probes
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
2
|
-
export declare const loginUmans: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
|
+
export declare const loginUmans: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
3
3
|
export declare const umansProvider: {
|
|
4
4
|
readonly id: "umans";
|
|
5
5
|
readonly name: "Umans AI Coding Plan";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
2
|
/**
|
|
3
3
|
* Login to Venice.
|
|
4
4
|
*
|
|
5
5
|
* Opens browser to API keys page, prompts user to paste their API key.
|
|
6
6
|
* Returns the API key directly (not OAuthCredentials - this isn't OAuth).
|
|
7
7
|
*/
|
|
8
|
-
export declare const loginVenice: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
8
|
+
export declare const loginVenice: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
9
9
|
export declare const veniceProvider: {
|
|
10
10
|
readonly id: "venice";
|
|
11
11
|
readonly name: "Venice";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { OAuthController, OAuthLoginCallbacks } from "./oauth/types";
|
|
1
|
+
import type { OAuthController, OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
2
|
export declare function loginVercelAiGateway(options: OAuthController): Promise<string>;
|
|
3
3
|
export declare const vercelAiGatewayProvider: {
|
|
4
4
|
readonly id: "vercel-ai-gateway";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { OAuthController, OAuthLoginCallbacks } from "./oauth/types";
|
|
1
|
+
import type { OAuthController, OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
2
|
export declare function loginVllm(options: OAuthController): Promise<string>;
|
|
3
3
|
export declare const vllmProvider: {
|
|
4
4
|
readonly id: "vllm";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { OAuthCredentials, OAuthLoginCallbacks } from "./oauth/types";
|
|
1
|
+
import type { OAuthCredentials, OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
2
|
export declare const xaiOauthProvider: {
|
|
3
3
|
readonly id: "xai-oauth";
|
|
4
4
|
readonly name: "xAI Grok OAuth (SuperGrok Subscription)";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
2
|
-
export declare const loginZai: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
|
+
export declare const loginZai: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
3
3
|
export declare const zaiProvider: {
|
|
4
4
|
readonly id: "zai";
|
|
5
5
|
readonly name: "Z.AI (GLM Coding Plan)";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
2
|
-
export declare const loginZenMux: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
|
+
export declare const loginZenMux: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
3
3
|
export declare const zenmuxProvider: {
|
|
4
4
|
readonly id: "zenmux";
|
|
5
5
|
readonly name: "ZenMux";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { OAuthLoginCallbacks } from "./oauth/types";
|
|
2
|
-
export declare const loginZhipuCodingPlan: (options: import("./oauth").OAuthController) => Promise<string>;
|
|
1
|
+
import type { OAuthLoginCallbacks } from "./oauth/types.js";
|
|
2
|
+
export declare const loginZhipuCodingPlan: (options: import("./oauth/index.js").OAuthController) => Promise<string>;
|
|
3
3
|
export declare const zhipuCodingPlanProvider: {
|
|
4
4
|
readonly id: "zhipu-coding-plan";
|
|
5
5
|
readonly name: "Zhipu Coding Plan (智谱)";
|
package/dist/types/stream.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { Effort } from "@oh-my-pi/pi-catalog/effort";
|
|
2
|
-
import type { AnthropicOptions } from "./providers/anthropic";
|
|
3
|
-
import type { GoogleOptions } from "./providers/google";
|
|
4
|
-
import type { GoogleGeminiCliOptions } from "./providers/google-gemini-cli";
|
|
5
|
-
import type { GoogleVertexOptions } from "./providers/google-vertex";
|
|
6
|
-
import type { Api, AssistantMessage, Context, Model, OptionsForApi, SimpleStreamOptions, ToolChoice } from "./types";
|
|
7
|
-
import { AssistantMessageEventStream } from "./utils/event-stream";
|
|
2
|
+
import type { AnthropicOptions } from "./providers/anthropic.js";
|
|
3
|
+
import type { GoogleOptions } from "./providers/google.js";
|
|
4
|
+
import type { GoogleGeminiCliOptions } from "./providers/google-gemini-cli.js";
|
|
5
|
+
import type { GoogleVertexOptions } from "./providers/google-vertex.js";
|
|
6
|
+
import type { Api, AssistantMessage, Context, Model, OptionsForApi, SimpleStreamOptions, ToolChoice } from "./types.js";
|
|
7
|
+
import { AssistantMessageEventStream } from "./utils/event-stream.js";
|
|
8
8
|
export declare function configureProviderMaxInFlightRequests(limits: Record<string, number> | undefined): void;
|
|
9
9
|
export declare const __providerInFlightForTesting: {
|
|
10
10
|
setRoot(root: string | undefined): void;
|
package/dist/types/types.d.ts
CHANGED
|
@@ -5,25 +5,25 @@ import type { Effort } from "@oh-my-pi/pi-catalog/effort";
|
|
|
5
5
|
import type { Api, FetchImpl, Model, Provider, ThinkingBudgets, Usage } from "@oh-my-pi/pi-catalog/types";
|
|
6
6
|
import type { Type } from "arktype";
|
|
7
7
|
import type { ZodType, z } from "zod/v4";
|
|
8
|
-
import type { ApiKey } from "./auth-retry";
|
|
9
|
-
import type { BedrockOptions } from "./providers/amazon-bedrock";
|
|
10
|
-
import type { AnthropicOptions } from "./providers/anthropic";
|
|
11
|
-
import type { FallbackParam, StopDetails } from "./providers/anthropic-wire";
|
|
12
|
-
import type { AzureOpenAIResponsesOptions } from "./providers/azure-openai-responses";
|
|
13
|
-
import type { CursorOptions } from "./providers/cursor";
|
|
14
|
-
import type { DevinOptions } from "./providers/devin";
|
|
15
|
-
import type { GitLabDuoWorkflowOptions } from "./providers/gitlab-duo-workflow";
|
|
16
|
-
import type { GoogleOptions } from "./providers/google";
|
|
17
|
-
import type { GoogleGeminiCliOptions } from "./providers/google-gemini-cli";
|
|
18
|
-
import type { GoogleVertexOptions } from "./providers/google-vertex";
|
|
19
|
-
import type { OllamaChatOptions } from "./providers/ollama";
|
|
20
|
-
import type { OpenAICodexResponsesOptions } from "./providers/openai-codex-responses";
|
|
21
|
-
import type { OpenAICompletionsOptions } from "./providers/openai-completions";
|
|
22
|
-
import type { OpenAIResponsesOptions } from "./providers/openai-responses";
|
|
23
|
-
import type { kStreamingPartialJson } from "./utils/block-symbols";
|
|
24
|
-
import type { AssistantMessageEventStream } from "./utils/event-stream";
|
|
25
|
-
export type { StopDetails } from "./providers/anthropic-wire";
|
|
26
|
-
export type { AssistantMessageEventStream } from "./utils/event-stream";
|
|
8
|
+
import type { ApiKey } from "./auth-retry.js";
|
|
9
|
+
import type { BedrockOptions } from "./providers/amazon-bedrock.js";
|
|
10
|
+
import type { AnthropicOptions } from "./providers/anthropic.js";
|
|
11
|
+
import type { FallbackParam, StopDetails } from "./providers/anthropic-wire.js";
|
|
12
|
+
import type { AzureOpenAIResponsesOptions } from "./providers/azure-openai-responses.js";
|
|
13
|
+
import type { CursorOptions } from "./providers/cursor.js";
|
|
14
|
+
import type { DevinOptions } from "./providers/devin.js";
|
|
15
|
+
import type { GitLabDuoWorkflowOptions } from "./providers/gitlab-duo-workflow.js";
|
|
16
|
+
import type { GoogleOptions } from "./providers/google.js";
|
|
17
|
+
import type { GoogleGeminiCliOptions } from "./providers/google-gemini-cli.js";
|
|
18
|
+
import type { GoogleVertexOptions } from "./providers/google-vertex.js";
|
|
19
|
+
import type { OllamaChatOptions } from "./providers/ollama.js";
|
|
20
|
+
import type { OpenAICodexResponsesOptions } from "./providers/openai-codex-responses.js";
|
|
21
|
+
import type { OpenAICompletionsOptions } from "./providers/openai-completions.js";
|
|
22
|
+
import type { OpenAIResponsesOptions } from "./providers/openai-responses.js";
|
|
23
|
+
import type { kStreamingPartialJson } from "./utils/block-symbols.js";
|
|
24
|
+
import type { AssistantMessageEventStream } from "./utils/event-stream.js";
|
|
25
|
+
export type { StopDetails } from "./providers/anthropic-wire.js";
|
|
26
|
+
export type { AssistantMessageEventStream } from "./utils/event-stream.js";
|
|
27
27
|
/**
|
|
28
28
|
* Ceiling on the output-token count omp requests from any OpenAI-family endpoint
|
|
29
29
|
* (openai-responses, azure/xai responses, and openai-completions). Mirrors
|
|
@@ -99,6 +99,7 @@ export type ServiceTierFamily = "openai" | "anthropic" | "google";
|
|
|
99
99
|
* models mid-session.
|
|
100
100
|
*/
|
|
101
101
|
export type ServiceTierByFamily = Partial<Record<ServiceTierFamily, ServiceTier>>;
|
|
102
|
+
type ServiceTierModel = Pick<Model, "provider" | "api" | "id">;
|
|
102
103
|
/**
|
|
103
104
|
* Classify a model into the service-tier family whose knob governs it, or
|
|
104
105
|
* `undefined` when the model exposes no serving-priority control.
|
|
@@ -106,8 +107,10 @@ export type ServiceTierByFamily = Partial<Record<ServiceTierFamily, ServiceTier>
|
|
|
106
107
|
* OpenRouter models are classified by id namespace (`anthropic/`, `google/`,
|
|
107
108
|
* `openai/`); Claude on Bedrock/Vertex (api `anthropic-messages`) is the
|
|
108
109
|
* anthropic family even though its provider is `amazon-bedrock`/`google-vertex`.
|
|
110
|
+
* Custom OpenAI-compatible relays that serve OpenAI model ids are OpenAI family
|
|
111
|
+
* too unless that provider owns a separate tier control such as Fireworks.
|
|
109
112
|
*/
|
|
110
|
-
export declare function serviceTierFamily(model:
|
|
113
|
+
export declare function serviceTierFamily(model: ServiceTierModel): ServiceTierFamily | undefined;
|
|
111
114
|
/**
|
|
112
115
|
* Reduce a per-family tier map to the single wire tier for `model` — the entry
|
|
113
116
|
* for the model's family, or `undefined` when the model has no family.
|
|
@@ -120,7 +123,7 @@ export declare function resolveModelServiceTier(tiers: ServiceTierByFamily | nul
|
|
|
120
123
|
* Serverless realizes only its Priority serving path. Anthropic is absent — it
|
|
121
124
|
* realizes `priority` via `speed: "fast"`, not a service-tier field.
|
|
122
125
|
*/
|
|
123
|
-
export declare function shouldSendServiceTier(serviceTier: ServiceTier | null | undefined,
|
|
126
|
+
export declare function shouldSendServiceTier(serviceTier: ServiceTier | null | undefined, target: Provider | ServiceTierModel | undefined): boolean;
|
|
124
127
|
/**
|
|
125
128
|
* True when `priority` will actually be realized on the wire for `model`.
|
|
126
129
|
* Direct Anthropic realizes fast mode; OpenAI/Google/Fireworks emit the
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type CredentialRankingStrategy, type UsageProvider, type UsageReport } from "../usage";
|
|
1
|
+
import { type CredentialRankingStrategy, type UsageProvider, type UsageReport } from "../usage.js";
|
|
2
2
|
export declare function parseClaudeRateLimitHeaders(headers: Record<string, string>, now?: number): UsageReport | null;
|
|
3
3
|
export declare const claudeUsageProvider: UsageProvider;
|
|
4
4
|
export declare const claudeRankingStrategy: CredentialRankingStrategy;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { UsageProvider } from "../usage";
|
|
1
|
+
import type { UsageProvider } from "../usage.js";
|
|
2
2
|
export declare const googleGeminiCliUsageProvider: UsageProvider;
|