@earendil-works/pi-ai 0.79.8 → 0.79.10
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/README.md +2 -1
- package/dist/models.generated.d.ts +30 -70
- package/dist/models.generated.d.ts.map +1 -1
- package/dist/models.generated.js +48 -82
- package/dist/models.generated.js.map +1 -1
- package/dist/providers/openai-completions.d.ts.map +1 -1
- package/dist/providers/openai-completions.js +63 -4
- package/dist/providers/openai-completions.js.map +1 -1
- package/dist/types.d.ts +8 -2
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/dist/utils/oauth/github-copilot.d.ts.map +1 -1
- package/dist/utils/oauth/github-copilot.js +66 -7
- package/dist/utils/oauth/github-copilot.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -967,7 +967,8 @@ interface OpenAICompletionsCompat {
|
|
|
967
967
|
requiresAssistantAfterToolResult?: boolean; // Whether tool results must be followed by an assistant message (default: false)
|
|
968
968
|
requiresThinkingAsText?: boolean; // Whether thinking blocks must be converted to text (default: false)
|
|
969
969
|
requiresReasoningContentOnAssistantMessages?: boolean; // Whether all replayed assistant messages must include empty reasoning_content when reasoning is enabled (default: auto-detected for DeepSeek)
|
|
970
|
-
thinkingFormat?: 'openai' | 'openrouter' | 'deepseek' | 'together' | 'zai' | 'qwen' | 'qwen-chat-template' | 'string-thinking' | 'ant-ling'; // Format for reasoning param: 'openai' uses reasoning_effort, 'openrouter' uses reasoning: { effort }, 'deepseek' uses thinking: { type } plus reasoning_effort when supported, 'together' uses reasoning: { enabled } plus reasoning_effort when supported, 'zai' uses
|
|
970
|
+
thinkingFormat?: 'openai' | 'openrouter' | 'deepseek' | 'together' | 'zai' | 'qwen' | 'chat-template' | 'qwen-chat-template' | 'string-thinking' | 'ant-ling'; // Format for reasoning param: 'openai' uses reasoning_effort, 'openrouter' uses reasoning: { effort }, 'deepseek' uses thinking: { type } plus reasoning_effort when supported, 'together' uses reasoning: { enabled } plus reasoning_effort when supported, 'zai' uses thinking: { type }, 'qwen' uses enable_thinking, 'chat-template' uses configurable chat_template_kwargs, 'qwen-chat-template' uses chat_template_kwargs.enable_thinking and preserve_thinking, 'string-thinking' uses top-level thinking, 'ant-ling' uses reasoning: { effort } only for mapped efforts (default: openai)
|
|
971
|
+
chatTemplateKwargs?: Record<string, string | number | boolean | null | { '$var': 'thinking.enabled' | 'thinking.effort'; omitWhenOff?: boolean }>; // chat_template_kwargs values; use $var for pi-controlled thinking values
|
|
971
972
|
cacheControlFormat?: 'anthropic'; // Anthropic-style cache_control on system prompt, last tool, and last user/assistant text content
|
|
972
973
|
openRouterRouting?: OpenRouterRouting; // OpenRouter routing preferences (default: {})
|
|
973
974
|
vercelGatewayRouting?: VercelGatewayRouting; // Vercel AI Gateway routing preferences (default: {})
|
|
@@ -4187,16 +4187,21 @@ export declare const MODELS: {
|
|
|
4187
4187
|
readonly "accounts/fireworks/models/glm-5p2": {
|
|
4188
4188
|
id: string;
|
|
4189
4189
|
name: string;
|
|
4190
|
-
api: "
|
|
4190
|
+
api: "openai-completions";
|
|
4191
4191
|
provider: string;
|
|
4192
4192
|
baseUrl: string;
|
|
4193
4193
|
compat: {
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
supportsCacheControlOnTools: false;
|
|
4197
|
-
supportsLongCacheRetention: false;
|
|
4194
|
+
supportsStore: false;
|
|
4195
|
+
supportsDeveloperRole: false;
|
|
4198
4196
|
};
|
|
4199
4197
|
reasoning: true;
|
|
4198
|
+
thinkingLevelMap: {
|
|
4199
|
+
off: string;
|
|
4200
|
+
minimal: null;
|
|
4201
|
+
low: string;
|
|
4202
|
+
medium: string;
|
|
4203
|
+
xhigh: string;
|
|
4204
|
+
};
|
|
4200
4205
|
input: "text"[];
|
|
4201
4206
|
cost: {
|
|
4202
4207
|
input: number;
|
|
@@ -5402,54 +5407,6 @@ export declare const MODELS: {
|
|
|
5402
5407
|
contextWindow: number;
|
|
5403
5408
|
maxTokens: number;
|
|
5404
5409
|
};
|
|
5405
|
-
readonly "gemma-4-E2B-it": {
|
|
5406
|
-
id: string;
|
|
5407
|
-
name: string;
|
|
5408
|
-
api: "google-generative-ai";
|
|
5409
|
-
provider: string;
|
|
5410
|
-
baseUrl: string;
|
|
5411
|
-
reasoning: true;
|
|
5412
|
-
thinkingLevelMap: {
|
|
5413
|
-
off: null;
|
|
5414
|
-
minimal: string;
|
|
5415
|
-
low: null;
|
|
5416
|
-
medium: null;
|
|
5417
|
-
high: string;
|
|
5418
|
-
};
|
|
5419
|
-
input: ("image" | "text")[];
|
|
5420
|
-
cost: {
|
|
5421
|
-
input: number;
|
|
5422
|
-
output: number;
|
|
5423
|
-
cacheRead: number;
|
|
5424
|
-
cacheWrite: number;
|
|
5425
|
-
};
|
|
5426
|
-
contextWindow: number;
|
|
5427
|
-
maxTokens: number;
|
|
5428
|
-
};
|
|
5429
|
-
readonly "gemma-4-E4B-it": {
|
|
5430
|
-
id: string;
|
|
5431
|
-
name: string;
|
|
5432
|
-
api: "google-generative-ai";
|
|
5433
|
-
provider: string;
|
|
5434
|
-
baseUrl: string;
|
|
5435
|
-
reasoning: true;
|
|
5436
|
-
thinkingLevelMap: {
|
|
5437
|
-
off: null;
|
|
5438
|
-
minimal: string;
|
|
5439
|
-
low: null;
|
|
5440
|
-
medium: null;
|
|
5441
|
-
high: string;
|
|
5442
|
-
};
|
|
5443
|
-
input: ("image" | "text")[];
|
|
5444
|
-
cost: {
|
|
5445
|
-
input: number;
|
|
5446
|
-
output: number;
|
|
5447
|
-
cacheRead: number;
|
|
5448
|
-
cacheWrite: number;
|
|
5449
|
-
};
|
|
5450
|
-
contextWindow: number;
|
|
5451
|
-
maxTokens: number;
|
|
5452
|
-
};
|
|
5453
5410
|
};
|
|
5454
5411
|
readonly "google-vertex": {
|
|
5455
5412
|
readonly "gemini-2.5-flash": {
|
|
@@ -10116,23 +10073,6 @@ export declare const MODELS: {
|
|
|
10116
10073
|
contextWindow: number;
|
|
10117
10074
|
maxTokens: number;
|
|
10118
10075
|
};
|
|
10119
|
-
readonly "anthropic/claude-3.5-haiku": {
|
|
10120
|
-
id: string;
|
|
10121
|
-
name: string;
|
|
10122
|
-
api: "openai-completions";
|
|
10123
|
-
provider: string;
|
|
10124
|
-
baseUrl: string;
|
|
10125
|
-
reasoning: false;
|
|
10126
|
-
input: ("image" | "text")[];
|
|
10127
|
-
cost: {
|
|
10128
|
-
input: number;
|
|
10129
|
-
output: number;
|
|
10130
|
-
cacheRead: number;
|
|
10131
|
-
cacheWrite: number;
|
|
10132
|
-
};
|
|
10133
|
-
contextWindow: number;
|
|
10134
|
-
maxTokens: number;
|
|
10135
|
-
};
|
|
10136
10076
|
readonly "anthropic/claude-fable-5": {
|
|
10137
10077
|
id: string;
|
|
10138
10078
|
name: string;
|
|
@@ -14338,6 +14278,9 @@ export declare const MODELS: {
|
|
|
14338
14278
|
provider: string;
|
|
14339
14279
|
baseUrl: string;
|
|
14340
14280
|
reasoning: true;
|
|
14281
|
+
thinkingLevelMap: {
|
|
14282
|
+
xhigh: string;
|
|
14283
|
+
};
|
|
14341
14284
|
input: "text"[];
|
|
14342
14285
|
cost: {
|
|
14343
14286
|
input: number;
|
|
@@ -17472,6 +17415,23 @@ export declare const MODELS: {
|
|
|
17472
17415
|
contextWindow: number;
|
|
17473
17416
|
maxTokens: number;
|
|
17474
17417
|
};
|
|
17418
|
+
readonly "sakana/fugu-ultra": {
|
|
17419
|
+
id: string;
|
|
17420
|
+
name: string;
|
|
17421
|
+
api: "anthropic-messages";
|
|
17422
|
+
provider: string;
|
|
17423
|
+
baseUrl: string;
|
|
17424
|
+
reasoning: true;
|
|
17425
|
+
input: ("image" | "text")[];
|
|
17426
|
+
cost: {
|
|
17427
|
+
input: number;
|
|
17428
|
+
output: number;
|
|
17429
|
+
cacheRead: number;
|
|
17430
|
+
cacheWrite: number;
|
|
17431
|
+
};
|
|
17432
|
+
contextWindow: number;
|
|
17433
|
+
maxTokens: number;
|
|
17434
|
+
};
|
|
17475
17435
|
readonly "stepfun/step-3.5-flash": {
|
|
17476
17436
|
id: string;
|
|
17477
17437
|
name: string;
|