@roo-code/types 1.83.0 → 1.85.0
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/dist/index.cjs +1269 -954
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1651 -1684
- package/dist/index.d.ts +1651 -1684
- package/dist/index.js +1255 -952
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -26,6 +26,7 @@ __export(index_exports, {
|
|
|
26
26
|
BEDROCK_1M_CONTEXT_MODEL_IDS: () => BEDROCK_1M_CONTEXT_MODEL_IDS,
|
|
27
27
|
BEDROCK_DEFAULT_CONTEXT: () => BEDROCK_DEFAULT_CONTEXT,
|
|
28
28
|
BEDROCK_DEFAULT_TEMPERATURE: () => BEDROCK_DEFAULT_TEMPERATURE,
|
|
29
|
+
BEDROCK_GLOBAL_INFERENCE_MODEL_IDS: () => BEDROCK_GLOBAL_INFERENCE_MODEL_IDS,
|
|
29
30
|
BEDROCK_MAX_TOKENS: () => BEDROCK_MAX_TOKENS,
|
|
30
31
|
BEDROCK_REGIONS: () => BEDROCK_REGIONS,
|
|
31
32
|
CLAUDE_CODE_DEFAULT_MAX_OUTPUT_TOKENS: () => CLAUDE_CODE_DEFAULT_MAX_OUTPUT_TOKENS,
|
|
@@ -34,6 +35,7 @@ __export(index_exports, {
|
|
|
34
35
|
COOKIE_CONSENT_EVENTS: () => COOKIE_CONSENT_EVENTS,
|
|
35
36
|
ConnectionState: () => ConnectionState,
|
|
36
37
|
DEEP_SEEK_DEFAULT_TEMPERATURE: () => DEEP_SEEK_DEFAULT_TEMPERATURE,
|
|
38
|
+
DEFAULT_CHECKPOINT_TIMEOUT_SECONDS: () => DEFAULT_CHECKPOINT_TIMEOUT_SECONDS,
|
|
37
39
|
DEFAULT_CONSECUTIVE_MISTAKE_LIMIT: () => DEFAULT_CONSECUTIVE_MISTAKE_LIMIT,
|
|
38
40
|
DEFAULT_MODES: () => DEFAULT_MODES,
|
|
39
41
|
DEFAULT_TERMINAL_OUTPUT_CHARACTER_LIMIT: () => DEFAULT_TERMINAL_OUTPUT_CHARACTER_LIMIT,
|
|
@@ -63,15 +65,16 @@ __export(index_exports, {
|
|
|
63
65
|
IO_INTELLIGENCE_CACHE_DURATION: () => IO_INTELLIGENCE_CACHE_DURATION,
|
|
64
66
|
IpcMessageType: () => IpcMessageType,
|
|
65
67
|
IpcOrigin: () => IpcOrigin,
|
|
66
|
-
LITELLM_COMPUTER_USE_MODELS: () => LITELLM_COMPUTER_USE_MODELS,
|
|
67
68
|
LMSTUDIO_DEFAULT_TEMPERATURE: () => LMSTUDIO_DEFAULT_TEMPERATURE,
|
|
69
|
+
MAX_CHECKPOINT_TIMEOUT_SECONDS: () => MAX_CHECKPOINT_TIMEOUT_SECONDS,
|
|
70
|
+
MINIMAX_DEFAULT_TEMPERATURE: () => MINIMAX_DEFAULT_TEMPERATURE,
|
|
71
|
+
MIN_CHECKPOINT_TIMEOUT_SECONDS: () => MIN_CHECKPOINT_TIMEOUT_SECONDS,
|
|
68
72
|
MISTRAL_DEFAULT_TEMPERATURE: () => MISTRAL_DEFAULT_TEMPERATURE,
|
|
69
73
|
MODELS_BY_PROVIDER: () => MODELS_BY_PROVIDER,
|
|
70
74
|
MOONSHOT_DEFAULT_TEMPERATURE: () => MOONSHOT_DEFAULT_TEMPERATURE,
|
|
71
75
|
OPENAI_AZURE_AI_INFERENCE_PATH: () => OPENAI_AZURE_AI_INFERENCE_PATH,
|
|
72
76
|
OPENAI_NATIVE_DEFAULT_TEMPERATURE: () => OPENAI_NATIVE_DEFAULT_TEMPERATURE,
|
|
73
77
|
OPENROUTER_DEFAULT_PROVIDER_NAME: () => OPENROUTER_DEFAULT_PROVIDER_NAME,
|
|
74
|
-
OPEN_ROUTER_COMPUTER_USE_MODELS: () => OPEN_ROUTER_COMPUTER_USE_MODELS,
|
|
75
78
|
OPEN_ROUTER_PROMPT_CACHING_MODELS: () => OPEN_ROUTER_PROMPT_CACHING_MODELS,
|
|
76
79
|
OPEN_ROUTER_REASONING_BUDGET_MODELS: () => OPEN_ROUTER_REASONING_BUDGET_MODELS,
|
|
77
80
|
OPEN_ROUTER_REQUIRED_REASONING_BUDGET_MODELS: () => OPEN_ROUTER_REQUIRED_REASONING_BUDGET_MODELS,
|
|
@@ -79,6 +82,9 @@ __export(index_exports, {
|
|
|
79
82
|
ORGANIZATION_DEFAULT: () => ORGANIZATION_DEFAULT,
|
|
80
83
|
PROVIDER_SETTINGS_KEYS: () => PROVIDER_SETTINGS_KEYS,
|
|
81
84
|
RooCodeEventName: () => RooCodeEventName,
|
|
85
|
+
RooModelSchema: () => RooModelSchema,
|
|
86
|
+
RooModelsResponseSchema: () => RooModelsResponseSchema,
|
|
87
|
+
RooPricingSchema: () => RooPricingSchema,
|
|
82
88
|
SECRET_STATE_KEYS: () => SECRET_STATE_KEYS,
|
|
83
89
|
TaskBridgeCommandName: () => TaskBridgeCommandName,
|
|
84
90
|
TaskBridgeEventName: () => TaskBridgeEventName,
|
|
@@ -103,6 +109,7 @@ __export(index_exports, {
|
|
|
103
109
|
cerebrasDefaultModelId: () => cerebrasDefaultModelId,
|
|
104
110
|
cerebrasModels: () => cerebrasModels,
|
|
105
111
|
chutesDefaultModelId: () => chutesDefaultModelId,
|
|
112
|
+
chutesDefaultModelInfo: () => chutesDefaultModelInfo,
|
|
106
113
|
chutesModels: () => chutesModels,
|
|
107
114
|
claudeCodeDefaultModelId: () => claudeCodeDefaultModelId,
|
|
108
115
|
claudeCodeModels: () => claudeCodeModels,
|
|
@@ -151,6 +158,7 @@ __export(index_exports, {
|
|
|
151
158
|
getApiProtocol: () => getApiProtocol,
|
|
152
159
|
getClaudeCodeModelId: () => getClaudeCodeModelId,
|
|
153
160
|
getModelId: () => getModelId,
|
|
161
|
+
getProviderDefaultModelId: () => getProviderDefaultModelId,
|
|
154
162
|
gitPropertiesSchema: () => gitPropertiesSchema,
|
|
155
163
|
glamaDefaultModelId: () => glamaDefaultModelId,
|
|
156
164
|
glamaDefaultModelInfo: () => glamaDefaultModelInfo,
|
|
@@ -180,6 +188,7 @@ __export(index_exports, {
|
|
|
180
188
|
isLanguage: () => isLanguage,
|
|
181
189
|
isLocalProvider: () => isLocalProvider,
|
|
182
190
|
isModelParameter: () => isModelParameter,
|
|
191
|
+
isNonBlockingAsk: () => isNonBlockingAsk,
|
|
183
192
|
isProviderName: () => isProviderName,
|
|
184
193
|
isResumableAsk: () => isResumableAsk,
|
|
185
194
|
isSecretStateKey: () => isSecretStateKey,
|
|
@@ -199,6 +208,8 @@ __export(index_exports, {
|
|
|
199
208
|
mcpInstallationMethodSchema: () => mcpInstallationMethodSchema,
|
|
200
209
|
mcpMarketplaceItemSchema: () => mcpMarketplaceItemSchema,
|
|
201
210
|
mcpParameterSchema: () => mcpParameterSchema,
|
|
211
|
+
minimaxDefaultModelId: () => minimaxDefaultModelId,
|
|
212
|
+
minimaxModels: () => minimaxModels,
|
|
202
213
|
mistralDefaultModelId: () => mistralDefaultModelId,
|
|
203
214
|
mistralModels: () => mistralModels,
|
|
204
215
|
modeConfigSchema: () => modeConfigSchema,
|
|
@@ -210,6 +221,7 @@ __export(index_exports, {
|
|
|
210
221
|
modelParametersSchema: () => modelParametersSchema,
|
|
211
222
|
moonshotDefaultModelId: () => moonshotDefaultModelId,
|
|
212
223
|
moonshotModels: () => moonshotModels,
|
|
224
|
+
nonBlockingAsks: () => nonBlockingAsks,
|
|
213
225
|
ollamaDefaultModelId: () => ollamaDefaultModelId,
|
|
214
226
|
ollamaDefaultModelInfo: () => ollamaDefaultModelInfo,
|
|
215
227
|
openAiModelInfoSaneDefaults: () => openAiModelInfoSaneDefaults,
|
|
@@ -292,7 +304,7 @@ __export(index_exports, {
|
|
|
292
304
|
module.exports = __toCommonJS(index_exports);
|
|
293
305
|
|
|
294
306
|
// src/cloud.ts
|
|
295
|
-
var
|
|
307
|
+
var import_zod16 = require("zod");
|
|
296
308
|
|
|
297
309
|
// src/events.ts
|
|
298
310
|
var import_zod3 = require("zod");
|
|
@@ -314,6 +326,10 @@ var clineAsks = [
|
|
|
314
326
|
"auto_approval_max_req_reached"
|
|
315
327
|
];
|
|
316
328
|
var clineAskSchema = import_zod.z.enum(clineAsks);
|
|
329
|
+
var nonBlockingAsks = ["command_output"];
|
|
330
|
+
function isNonBlockingAsk(ask) {
|
|
331
|
+
return nonBlockingAsks.includes(ask);
|
|
332
|
+
}
|
|
317
333
|
var idleAsks = [
|
|
318
334
|
"completion_result",
|
|
319
335
|
"api_req_failed",
|
|
@@ -395,9 +411,7 @@ var clineMessageSchema = import_zod.z.object({
|
|
|
395
411
|
isAnswered: import_zod.z.boolean().optional(),
|
|
396
412
|
metadata: import_zod.z.object({
|
|
397
413
|
gpt5: import_zod.z.object({
|
|
398
|
-
previous_response_id: import_zod.z.string().optional()
|
|
399
|
-
instructions: import_zod.z.string().optional(),
|
|
400
|
-
reasoning_summary: import_zod.z.string().optional()
|
|
414
|
+
previous_response_id: import_zod.z.string().optional()
|
|
401
415
|
}).optional()
|
|
402
416
|
}).optional()
|
|
403
417
|
});
|
|
@@ -426,7 +440,6 @@ var toolNames = [
|
|
|
426
440
|
"write_to_file",
|
|
427
441
|
"apply_diff",
|
|
428
442
|
"insert_content",
|
|
429
|
-
"search_and_replace",
|
|
430
443
|
"search_files",
|
|
431
444
|
"list_files",
|
|
432
445
|
"list_code_definition_names",
|
|
@@ -640,10 +653,10 @@ var taskMetadataSchema = import_zod4.z.object({
|
|
|
640
653
|
});
|
|
641
654
|
|
|
642
655
|
// src/global-settings.ts
|
|
643
|
-
var
|
|
656
|
+
var import_zod14 = require("zod");
|
|
644
657
|
|
|
645
658
|
// src/provider-settings.ts
|
|
646
|
-
var
|
|
659
|
+
var import_zod8 = require("zod");
|
|
647
660
|
|
|
648
661
|
// src/model.ts
|
|
649
662
|
var import_zod5 = require("zod");
|
|
@@ -662,15 +675,19 @@ var modelInfoSchema = import_zod5.z.object({
|
|
|
662
675
|
maxThinkingTokens: import_zod5.z.number().nullish(),
|
|
663
676
|
contextWindow: import_zod5.z.number(),
|
|
664
677
|
supportsImages: import_zod5.z.boolean().optional(),
|
|
665
|
-
supportsComputerUse: import_zod5.z.boolean().optional(),
|
|
666
678
|
supportsPromptCache: import_zod5.z.boolean(),
|
|
667
679
|
// Capability flag to indicate whether the model supports an output verbosity parameter
|
|
668
680
|
supportsVerbosity: import_zod5.z.boolean().optional(),
|
|
669
681
|
supportsReasoningBudget: import_zod5.z.boolean().optional(),
|
|
682
|
+
// Capability flag to indicate whether the model supports simple on/off binary reasoning
|
|
683
|
+
supportsReasoningBinary: import_zod5.z.boolean().optional(),
|
|
670
684
|
// Capability flag to indicate whether the model supports temperature parameter
|
|
671
685
|
supportsTemperature: import_zod5.z.boolean().optional(),
|
|
686
|
+
defaultTemperature: import_zod5.z.number().optional(),
|
|
672
687
|
requiredReasoningBudget: import_zod5.z.boolean().optional(),
|
|
673
688
|
supportsReasoningEffort: import_zod5.z.boolean().optional(),
|
|
689
|
+
requiredReasoningEffort: import_zod5.z.boolean().optional(),
|
|
690
|
+
preserveReasoning: import_zod5.z.boolean().optional(),
|
|
674
691
|
supportedParameters: import_zod5.z.array(modelParametersSchema).optional(),
|
|
675
692
|
inputPrice: import_zod5.z.number().optional(),
|
|
676
693
|
outputPrice: import_zod5.z.number().optional(),
|
|
@@ -683,6 +700,8 @@ var modelInfoSchema = import_zod5.z.object({
|
|
|
683
700
|
cachableFields: import_zod5.z.array(import_zod5.z.string()).optional(),
|
|
684
701
|
// Flag to indicate if the model is deprecated and should not be used
|
|
685
702
|
deprecated: import_zod5.z.boolean().optional(),
|
|
703
|
+
// Flag to indicate if the model is free (no cost)
|
|
704
|
+
isFree: import_zod5.z.boolean().optional(),
|
|
686
705
|
/**
|
|
687
706
|
* Service tiers with pricing information.
|
|
688
707
|
* Each tier can have a name (for OpenAI service tiers) and pricing overrides.
|
|
@@ -716,7 +735,7 @@ var CODEBASE_INDEX_DEFAULTS = {
|
|
|
716
735
|
var codebaseIndexConfigSchema = import_zod6.z.object({
|
|
717
736
|
codebaseIndexEnabled: import_zod6.z.boolean().optional(),
|
|
718
737
|
codebaseIndexQdrantUrl: import_zod6.z.string().optional(),
|
|
719
|
-
codebaseIndexEmbedderProvider: import_zod6.z.enum(["openai", "ollama", "openai-compatible", "gemini", "mistral", "vercel-ai-gateway"]).optional(),
|
|
738
|
+
codebaseIndexEmbedderProvider: import_zod6.z.enum(["openai", "ollama", "openai-compatible", "gemini", "mistral", "vercel-ai-gateway", "openrouter"]).optional(),
|
|
720
739
|
codebaseIndexEmbedderBaseUrl: import_zod6.z.string().optional(),
|
|
721
740
|
codebaseIndexEmbedderModelId: import_zod6.z.string().optional(),
|
|
722
741
|
codebaseIndexEmbedderModelDimension: import_zod6.z.number().optional(),
|
|
@@ -732,7 +751,8 @@ var codebaseIndexModelsSchema = import_zod6.z.object({
|
|
|
732
751
|
"openai-compatible": import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional(),
|
|
733
752
|
gemini: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional(),
|
|
734
753
|
mistral: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional(),
|
|
735
|
-
"vercel-ai-gateway": import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional()
|
|
754
|
+
"vercel-ai-gateway": import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional(),
|
|
755
|
+
openrouter: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.object({ dimension: import_zod6.z.number() })).optional()
|
|
736
756
|
});
|
|
737
757
|
var codebaseIndexProviderSchema = import_zod6.z.object({
|
|
738
758
|
codeIndexOpenAiKey: import_zod6.z.string().optional(),
|
|
@@ -742,11 +762,12 @@ var codebaseIndexProviderSchema = import_zod6.z.object({
|
|
|
742
762
|
codebaseIndexOpenAiCompatibleModelDimension: import_zod6.z.number().optional(),
|
|
743
763
|
codebaseIndexGeminiApiKey: import_zod6.z.string().optional(),
|
|
744
764
|
codebaseIndexMistralApiKey: import_zod6.z.string().optional(),
|
|
745
|
-
codebaseIndexVercelAiGatewayApiKey: import_zod6.z.string().optional()
|
|
765
|
+
codebaseIndexVercelAiGatewayApiKey: import_zod6.z.string().optional(),
|
|
766
|
+
codebaseIndexOpenRouterApiKey: import_zod6.z.string().optional()
|
|
746
767
|
});
|
|
747
768
|
|
|
748
769
|
// src/providers/anthropic.ts
|
|
749
|
-
var anthropicDefaultModelId = "claude-sonnet-4-
|
|
770
|
+
var anthropicDefaultModelId = "claude-sonnet-4-5";
|
|
750
771
|
var anthropicModels = {
|
|
751
772
|
"claude-sonnet-4-5": {
|
|
752
773
|
maxTokens: 64e3,
|
|
@@ -754,7 +775,6 @@ var anthropicModels = {
|
|
|
754
775
|
contextWindow: 2e5,
|
|
755
776
|
// Default 200K, extendable to 1M with beta flag 'context-1m-2025-08-07'
|
|
756
777
|
supportsImages: true,
|
|
757
|
-
supportsComputerUse: true,
|
|
758
778
|
supportsPromptCache: true,
|
|
759
779
|
inputPrice: 3,
|
|
760
780
|
// $3 per million input tokens (≤200K context)
|
|
@@ -787,7 +807,6 @@ var anthropicModels = {
|
|
|
787
807
|
contextWindow: 2e5,
|
|
788
808
|
// Default 200K, extendable to 1M with beta flag 'context-1m-2025-08-07'
|
|
789
809
|
supportsImages: true,
|
|
790
|
-
supportsComputerUse: true,
|
|
791
810
|
supportsPromptCache: true,
|
|
792
811
|
inputPrice: 3,
|
|
793
812
|
// $3 per million input tokens (≤200K context)
|
|
@@ -815,10 +834,10 @@ var anthropicModels = {
|
|
|
815
834
|
]
|
|
816
835
|
},
|
|
817
836
|
"claude-opus-4-1-20250805": {
|
|
818
|
-
maxTokens:
|
|
837
|
+
maxTokens: 32e3,
|
|
838
|
+
// Overridden to 8k if `enableReasoningEffort` is false.
|
|
819
839
|
contextWindow: 2e5,
|
|
820
840
|
supportsImages: true,
|
|
821
|
-
supportsComputerUse: true,
|
|
822
841
|
supportsPromptCache: true,
|
|
823
842
|
inputPrice: 15,
|
|
824
843
|
// $15 per million input tokens
|
|
@@ -835,7 +854,6 @@ var anthropicModels = {
|
|
|
835
854
|
// Overridden to 8k if `enableReasoningEffort` is false.
|
|
836
855
|
contextWindow: 2e5,
|
|
837
856
|
supportsImages: true,
|
|
838
|
-
supportsComputerUse: true,
|
|
839
857
|
supportsPromptCache: true,
|
|
840
858
|
inputPrice: 15,
|
|
841
859
|
// $15 per million input tokens
|
|
@@ -852,7 +870,6 @@ var anthropicModels = {
|
|
|
852
870
|
// Unlocked by passing `beta` flag to the model. Otherwise, it's 64k.
|
|
853
871
|
contextWindow: 2e5,
|
|
854
872
|
supportsImages: true,
|
|
855
|
-
supportsComputerUse: true,
|
|
856
873
|
supportsPromptCache: true,
|
|
857
874
|
inputPrice: 3,
|
|
858
875
|
// $3 per million input tokens
|
|
@@ -870,7 +887,6 @@ var anthropicModels = {
|
|
|
870
887
|
// Since we already have a `:thinking` virtual model we aren't setting `supportsReasoningBudget: true` here.
|
|
871
888
|
contextWindow: 2e5,
|
|
872
889
|
supportsImages: true,
|
|
873
|
-
supportsComputerUse: true,
|
|
874
890
|
supportsPromptCache: true,
|
|
875
891
|
inputPrice: 3,
|
|
876
892
|
// $3 per million input tokens
|
|
@@ -885,7 +901,6 @@ var anthropicModels = {
|
|
|
885
901
|
maxTokens: 8192,
|
|
886
902
|
contextWindow: 2e5,
|
|
887
903
|
supportsImages: true,
|
|
888
|
-
supportsComputerUse: true,
|
|
889
904
|
supportsPromptCache: true,
|
|
890
905
|
inputPrice: 3,
|
|
891
906
|
// $3 per million input tokens
|
|
@@ -925,19 +940,30 @@ var anthropicModels = {
|
|
|
925
940
|
outputPrice: 1.25,
|
|
926
941
|
cacheWritesPrice: 0.3,
|
|
927
942
|
cacheReadsPrice: 0.03
|
|
943
|
+
},
|
|
944
|
+
"claude-haiku-4-5-20251001": {
|
|
945
|
+
maxTokens: 64e3,
|
|
946
|
+
contextWindow: 2e5,
|
|
947
|
+
supportsImages: true,
|
|
948
|
+
supportsPromptCache: true,
|
|
949
|
+
inputPrice: 1,
|
|
950
|
+
outputPrice: 5,
|
|
951
|
+
cacheWritesPrice: 1.25,
|
|
952
|
+
cacheReadsPrice: 0.1,
|
|
953
|
+
supportsReasoningBudget: true,
|
|
954
|
+
description: "Claude Haiku 4.5 delivers near-frontier intelligence at lightning speeds with extended thinking, vision, and multilingual support."
|
|
928
955
|
}
|
|
929
956
|
};
|
|
930
957
|
var ANTHROPIC_DEFAULT_MAX_TOKENS = 8192;
|
|
931
958
|
|
|
932
959
|
// src/providers/bedrock.ts
|
|
933
|
-
var bedrockDefaultModelId = "anthropic.claude-sonnet-4-
|
|
960
|
+
var bedrockDefaultModelId = "anthropic.claude-sonnet-4-5-20250929-v1:0";
|
|
934
961
|
var bedrockDefaultPromptRouterModelId = "anthropic.claude-3-sonnet-20240229-v1:0";
|
|
935
962
|
var bedrockModels = {
|
|
936
963
|
"anthropic.claude-sonnet-4-5-20250929-v1:0": {
|
|
937
964
|
maxTokens: 8192,
|
|
938
965
|
contextWindow: 2e5,
|
|
939
966
|
supportsImages: true,
|
|
940
|
-
supportsComputerUse: true,
|
|
941
967
|
supportsPromptCache: true,
|
|
942
968
|
supportsReasoningBudget: true,
|
|
943
969
|
inputPrice: 3,
|
|
@@ -952,7 +978,6 @@ var bedrockModels = {
|
|
|
952
978
|
maxTokens: 5e3,
|
|
953
979
|
contextWindow: 3e5,
|
|
954
980
|
supportsImages: true,
|
|
955
|
-
supportsComputerUse: false,
|
|
956
981
|
supportsPromptCache: true,
|
|
957
982
|
inputPrice: 0.8,
|
|
958
983
|
outputPrice: 3.2,
|
|
@@ -968,7 +993,6 @@ var bedrockModels = {
|
|
|
968
993
|
maxTokens: 5e3,
|
|
969
994
|
contextWindow: 3e5,
|
|
970
995
|
supportsImages: true,
|
|
971
|
-
supportsComputerUse: false,
|
|
972
996
|
supportsPromptCache: false,
|
|
973
997
|
inputPrice: 1,
|
|
974
998
|
outputPrice: 4,
|
|
@@ -982,7 +1006,6 @@ var bedrockModels = {
|
|
|
982
1006
|
maxTokens: 5e3,
|
|
983
1007
|
contextWindow: 3e5,
|
|
984
1008
|
supportsImages: true,
|
|
985
|
-
supportsComputerUse: false,
|
|
986
1009
|
supportsPromptCache: true,
|
|
987
1010
|
inputPrice: 0.06,
|
|
988
1011
|
outputPrice: 0.24,
|
|
@@ -998,7 +1021,6 @@ var bedrockModels = {
|
|
|
998
1021
|
maxTokens: 5e3,
|
|
999
1022
|
contextWindow: 128e3,
|
|
1000
1023
|
supportsImages: false,
|
|
1001
|
-
supportsComputerUse: false,
|
|
1002
1024
|
supportsPromptCache: true,
|
|
1003
1025
|
inputPrice: 0.035,
|
|
1004
1026
|
outputPrice: 0.14,
|
|
@@ -1014,7 +1036,6 @@ var bedrockModels = {
|
|
|
1014
1036
|
maxTokens: 8192,
|
|
1015
1037
|
contextWindow: 2e5,
|
|
1016
1038
|
supportsImages: true,
|
|
1017
|
-
supportsComputerUse: true,
|
|
1018
1039
|
supportsPromptCache: true,
|
|
1019
1040
|
supportsReasoningBudget: true,
|
|
1020
1041
|
inputPrice: 3,
|
|
@@ -1029,7 +1050,6 @@ var bedrockModels = {
|
|
|
1029
1050
|
maxTokens: 8192,
|
|
1030
1051
|
contextWindow: 2e5,
|
|
1031
1052
|
supportsImages: true,
|
|
1032
|
-
supportsComputerUse: true,
|
|
1033
1053
|
supportsPromptCache: true,
|
|
1034
1054
|
supportsReasoningBudget: true,
|
|
1035
1055
|
inputPrice: 15,
|
|
@@ -1044,7 +1064,6 @@ var bedrockModels = {
|
|
|
1044
1064
|
maxTokens: 8192,
|
|
1045
1065
|
contextWindow: 2e5,
|
|
1046
1066
|
supportsImages: true,
|
|
1047
|
-
supportsComputerUse: true,
|
|
1048
1067
|
supportsPromptCache: true,
|
|
1049
1068
|
supportsReasoningBudget: true,
|
|
1050
1069
|
inputPrice: 15,
|
|
@@ -1059,7 +1078,6 @@ var bedrockModels = {
|
|
|
1059
1078
|
maxTokens: 8192,
|
|
1060
1079
|
contextWindow: 2e5,
|
|
1061
1080
|
supportsImages: true,
|
|
1062
|
-
supportsComputerUse: true,
|
|
1063
1081
|
supportsPromptCache: true,
|
|
1064
1082
|
supportsReasoningBudget: true,
|
|
1065
1083
|
inputPrice: 3,
|
|
@@ -1074,7 +1092,6 @@ var bedrockModels = {
|
|
|
1074
1092
|
maxTokens: 8192,
|
|
1075
1093
|
contextWindow: 2e5,
|
|
1076
1094
|
supportsImages: true,
|
|
1077
|
-
supportsComputerUse: true,
|
|
1078
1095
|
supportsPromptCache: true,
|
|
1079
1096
|
inputPrice: 3,
|
|
1080
1097
|
outputPrice: 15,
|
|
@@ -1097,6 +1114,22 @@ var bedrockModels = {
|
|
|
1097
1114
|
maxCachePoints: 4,
|
|
1098
1115
|
cachableFields: ["system", "messages", "tools"]
|
|
1099
1116
|
},
|
|
1117
|
+
"anthropic.claude-haiku-4-5-20251001-v1:0": {
|
|
1118
|
+
maxTokens: 8192,
|
|
1119
|
+
contextWindow: 2e5,
|
|
1120
|
+
supportsImages: true,
|
|
1121
|
+
supportsPromptCache: true,
|
|
1122
|
+
supportsReasoningBudget: true,
|
|
1123
|
+
inputPrice: 1,
|
|
1124
|
+
outputPrice: 5,
|
|
1125
|
+
cacheWritesPrice: 1.25,
|
|
1126
|
+
// 5m cache writes
|
|
1127
|
+
cacheReadsPrice: 0.1,
|
|
1128
|
+
// cache hits / refreshes
|
|
1129
|
+
minTokensPerCachePoint: 2048,
|
|
1130
|
+
maxCachePoints: 4,
|
|
1131
|
+
cachableFields: ["system", "messages", "tools"]
|
|
1132
|
+
},
|
|
1100
1133
|
"anthropic.claude-3-5-sonnet-20240620-v1:0": {
|
|
1101
1134
|
maxTokens: 8192,
|
|
1102
1135
|
contextWindow: 2e5,
|
|
@@ -1168,7 +1201,6 @@ var bedrockModels = {
|
|
|
1168
1201
|
maxTokens: 8192,
|
|
1169
1202
|
contextWindow: 128e3,
|
|
1170
1203
|
supportsImages: false,
|
|
1171
|
-
supportsComputerUse: false,
|
|
1172
1204
|
supportsPromptCache: false,
|
|
1173
1205
|
inputPrice: 0.5,
|
|
1174
1206
|
outputPrice: 1.5,
|
|
@@ -1178,7 +1210,6 @@ var bedrockModels = {
|
|
|
1178
1210
|
maxTokens: 8192,
|
|
1179
1211
|
contextWindow: 128e3,
|
|
1180
1212
|
supportsImages: false,
|
|
1181
|
-
supportsComputerUse: false,
|
|
1182
1213
|
supportsPromptCache: false,
|
|
1183
1214
|
inputPrice: 2,
|
|
1184
1215
|
outputPrice: 6,
|
|
@@ -1188,7 +1219,6 @@ var bedrockModels = {
|
|
|
1188
1219
|
maxTokens: 8192,
|
|
1189
1220
|
contextWindow: 128e3,
|
|
1190
1221
|
supportsImages: false,
|
|
1191
|
-
supportsComputerUse: false,
|
|
1192
1222
|
supportsPromptCache: false,
|
|
1193
1223
|
inputPrice: 0.72,
|
|
1194
1224
|
outputPrice: 0.72,
|
|
@@ -1198,7 +1228,6 @@ var bedrockModels = {
|
|
|
1198
1228
|
maxTokens: 8192,
|
|
1199
1229
|
contextWindow: 128e3,
|
|
1200
1230
|
supportsImages: true,
|
|
1201
|
-
supportsComputerUse: false,
|
|
1202
1231
|
supportsPromptCache: false,
|
|
1203
1232
|
inputPrice: 0.72,
|
|
1204
1233
|
outputPrice: 0.72,
|
|
@@ -1208,7 +1237,6 @@ var bedrockModels = {
|
|
|
1208
1237
|
maxTokens: 8192,
|
|
1209
1238
|
contextWindow: 128e3,
|
|
1210
1239
|
supportsImages: true,
|
|
1211
|
-
supportsComputerUse: false,
|
|
1212
1240
|
supportsPromptCache: false,
|
|
1213
1241
|
inputPrice: 0.16,
|
|
1214
1242
|
outputPrice: 0.16,
|
|
@@ -1218,7 +1246,6 @@ var bedrockModels = {
|
|
|
1218
1246
|
maxTokens: 8192,
|
|
1219
1247
|
contextWindow: 128e3,
|
|
1220
1248
|
supportsImages: false,
|
|
1221
|
-
supportsComputerUse: false,
|
|
1222
1249
|
supportsPromptCache: false,
|
|
1223
1250
|
inputPrice: 0.15,
|
|
1224
1251
|
outputPrice: 0.15,
|
|
@@ -1228,7 +1255,6 @@ var bedrockModels = {
|
|
|
1228
1255
|
maxTokens: 8192,
|
|
1229
1256
|
contextWindow: 128e3,
|
|
1230
1257
|
supportsImages: false,
|
|
1231
|
-
supportsComputerUse: false,
|
|
1232
1258
|
supportsPromptCache: false,
|
|
1233
1259
|
inputPrice: 0.1,
|
|
1234
1260
|
outputPrice: 0.1,
|
|
@@ -1238,7 +1264,6 @@ var bedrockModels = {
|
|
|
1238
1264
|
maxTokens: 8192,
|
|
1239
1265
|
contextWindow: 128e3,
|
|
1240
1266
|
supportsImages: false,
|
|
1241
|
-
supportsComputerUse: false,
|
|
1242
1267
|
supportsPromptCache: false,
|
|
1243
1268
|
inputPrice: 2.4,
|
|
1244
1269
|
outputPrice: 2.4,
|
|
@@ -1248,7 +1273,6 @@ var bedrockModels = {
|
|
|
1248
1273
|
maxTokens: 8192,
|
|
1249
1274
|
contextWindow: 128e3,
|
|
1250
1275
|
supportsImages: false,
|
|
1251
|
-
supportsComputerUse: false,
|
|
1252
1276
|
supportsPromptCache: false,
|
|
1253
1277
|
inputPrice: 0.72,
|
|
1254
1278
|
outputPrice: 0.72,
|
|
@@ -1258,7 +1282,6 @@ var bedrockModels = {
|
|
|
1258
1282
|
maxTokens: 8192,
|
|
1259
1283
|
contextWindow: 128e3,
|
|
1260
1284
|
supportsImages: false,
|
|
1261
|
-
supportsComputerUse: false,
|
|
1262
1285
|
supportsPromptCache: false,
|
|
1263
1286
|
inputPrice: 0.9,
|
|
1264
1287
|
outputPrice: 0.9,
|
|
@@ -1268,7 +1291,6 @@ var bedrockModels = {
|
|
|
1268
1291
|
maxTokens: 8192,
|
|
1269
1292
|
contextWindow: 8e3,
|
|
1270
1293
|
supportsImages: false,
|
|
1271
|
-
supportsComputerUse: false,
|
|
1272
1294
|
supportsPromptCache: false,
|
|
1273
1295
|
inputPrice: 0.22,
|
|
1274
1296
|
outputPrice: 0.22,
|
|
@@ -1278,7 +1300,6 @@ var bedrockModels = {
|
|
|
1278
1300
|
maxTokens: 2048,
|
|
1279
1301
|
contextWindow: 8e3,
|
|
1280
1302
|
supportsImages: false,
|
|
1281
|
-
supportsComputerUse: false,
|
|
1282
1303
|
supportsPromptCache: false,
|
|
1283
1304
|
inputPrice: 2.65,
|
|
1284
1305
|
outputPrice: 3.5
|
|
@@ -1287,7 +1308,6 @@ var bedrockModels = {
|
|
|
1287
1308
|
maxTokens: 2048,
|
|
1288
1309
|
contextWindow: 4e3,
|
|
1289
1310
|
supportsImages: false,
|
|
1290
|
-
supportsComputerUse: false,
|
|
1291
1311
|
supportsPromptCache: false,
|
|
1292
1312
|
inputPrice: 0.3,
|
|
1293
1313
|
outputPrice: 0.6
|
|
@@ -1296,7 +1316,6 @@ var bedrockModels = {
|
|
|
1296
1316
|
maxTokens: 4096,
|
|
1297
1317
|
contextWindow: 8e3,
|
|
1298
1318
|
supportsImages: false,
|
|
1299
|
-
supportsComputerUse: false,
|
|
1300
1319
|
supportsPromptCache: false,
|
|
1301
1320
|
inputPrice: 0.15,
|
|
1302
1321
|
outputPrice: 0.2,
|
|
@@ -1306,7 +1325,6 @@ var bedrockModels = {
|
|
|
1306
1325
|
maxTokens: 4096,
|
|
1307
1326
|
contextWindow: 8e3,
|
|
1308
1327
|
supportsImages: false,
|
|
1309
|
-
supportsComputerUse: false,
|
|
1310
1328
|
supportsPromptCache: false,
|
|
1311
1329
|
inputPrice: 0.2,
|
|
1312
1330
|
outputPrice: 0.6,
|
|
@@ -1316,7 +1334,6 @@ var bedrockModels = {
|
|
|
1316
1334
|
maxTokens: 8192,
|
|
1317
1335
|
contextWindow: 8e3,
|
|
1318
1336
|
supportsImages: false,
|
|
1319
|
-
supportsComputerUse: false,
|
|
1320
1337
|
supportsPromptCache: false,
|
|
1321
1338
|
inputPrice: 0.1,
|
|
1322
1339
|
description: "Amazon Titan Text Embeddings"
|
|
@@ -1325,7 +1342,6 @@ var bedrockModels = {
|
|
|
1325
1342
|
maxTokens: 8192,
|
|
1326
1343
|
contextWindow: 8e3,
|
|
1327
1344
|
supportsImages: false,
|
|
1328
|
-
supportsComputerUse: false,
|
|
1329
1345
|
supportsPromptCache: false,
|
|
1330
1346
|
inputPrice: 0.02,
|
|
1331
1347
|
description: "Amazon Titan Text Embeddings V2"
|
|
@@ -1335,17 +1351,22 @@ var BEDROCK_DEFAULT_TEMPERATURE = 0.3;
|
|
|
1335
1351
|
var BEDROCK_MAX_TOKENS = 4096;
|
|
1336
1352
|
var BEDROCK_DEFAULT_CONTEXT = 128e3;
|
|
1337
1353
|
var AWS_INFERENCE_PROFILE_MAPPING = [
|
|
1338
|
-
//
|
|
1354
|
+
// Australia regions (Sydney and Melbourne) → au. inference profile (most specific - 14 chars)
|
|
1355
|
+
["ap-southeast-2", "au."],
|
|
1356
|
+
["ap-southeast-4", "au."],
|
|
1357
|
+
// Japan regions (Tokyo and Osaka) → jp. inference profile (13 chars)
|
|
1358
|
+
["ap-northeast-", "jp."],
|
|
1359
|
+
// US Government Cloud → ug. inference profile (7 chars)
|
|
1339
1360
|
["us-gov-", "ug."],
|
|
1340
|
-
// Americas regions → us. inference profile
|
|
1361
|
+
// Americas regions → us. inference profile (3 chars)
|
|
1341
1362
|
["us-", "us."],
|
|
1342
|
-
// Europe regions → eu. inference profile
|
|
1363
|
+
// Europe regions → eu. inference profile (3 chars)
|
|
1343
1364
|
["eu-", "eu."],
|
|
1344
|
-
// Asia Pacific regions → apac. inference profile
|
|
1365
|
+
// Asia Pacific regions → apac. inference profile (3 chars)
|
|
1345
1366
|
["ap-", "apac."],
|
|
1346
|
-
// Canada regions → ca. inference profile
|
|
1367
|
+
// Canada regions → ca. inference profile (3 chars)
|
|
1347
1368
|
["ca-", "ca."],
|
|
1348
|
-
// South America regions → sa. inference profile
|
|
1369
|
+
// South America regions → sa. inference profile (3 chars)
|
|
1349
1370
|
["sa-", "sa."]
|
|
1350
1371
|
];
|
|
1351
1372
|
var BEDROCK_REGIONS = [
|
|
@@ -1378,10 +1399,25 @@ var BEDROCK_1M_CONTEXT_MODEL_IDS = [
|
|
|
1378
1399
|
"anthropic.claude-sonnet-4-20250514-v1:0",
|
|
1379
1400
|
"anthropic.claude-sonnet-4-5-20250929-v1:0"
|
|
1380
1401
|
];
|
|
1402
|
+
var BEDROCK_GLOBAL_INFERENCE_MODEL_IDS = [
|
|
1403
|
+
"anthropic.claude-sonnet-4-20250514-v1:0",
|
|
1404
|
+
"anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
1405
|
+
"anthropic.claude-haiku-4-5-20251001-v1:0"
|
|
1406
|
+
];
|
|
1381
1407
|
|
|
1382
1408
|
// src/providers/cerebras.ts
|
|
1383
|
-
var cerebrasDefaultModelId = "
|
|
1409
|
+
var cerebrasDefaultModelId = "gpt-oss-120b";
|
|
1384
1410
|
var cerebrasModels = {
|
|
1411
|
+
"zai-glm-4.6": {
|
|
1412
|
+
maxTokens: 16384,
|
|
1413
|
+
// consistent with their other models
|
|
1414
|
+
contextWindow: 131072,
|
|
1415
|
+
supportsImages: false,
|
|
1416
|
+
supportsPromptCache: false,
|
|
1417
|
+
inputPrice: 0,
|
|
1418
|
+
outputPrice: 0,
|
|
1419
|
+
description: "Highly intelligent general purpose model with up to 1,000 tokens/s"
|
|
1420
|
+
},
|
|
1385
1421
|
"qwen-3-coder-480b-free": {
|
|
1386
1422
|
maxTokens: 4e4,
|
|
1387
1423
|
contextWindow: 64e3,
|
|
@@ -1389,7 +1425,7 @@ var cerebrasModels = {
|
|
|
1389
1425
|
supportsPromptCache: false,
|
|
1390
1426
|
inputPrice: 0,
|
|
1391
1427
|
outputPrice: 0,
|
|
1392
|
-
description: "SOTA coding model with ~2000 tokens/s ($0 free tier)\n\n\u2022 Use this if you don't have a Cerebras subscription\n\u2022 64K context window\n\u2022 Rate limits: 150K TPM, 1M TPH/TPD, 10 RPM, 100 RPH/RPD\n\nUpgrade for higher limits: [https://cloud.cerebras.ai/?utm=roocode](https://cloud.cerebras.ai/?utm=roocode)"
|
|
1428
|
+
description: "[SOON TO BE DEPRECATED] SOTA coding model with ~2000 tokens/s ($0 free tier)\n\n\u2022 Use this if you don't have a Cerebras subscription\n\u2022 64K context window\n\u2022 Rate limits: 150K TPM, 1M TPH/TPD, 10 RPM, 100 RPH/RPD\n\nUpgrade for higher limits: [https://cloud.cerebras.ai/?utm=roocode](https://cloud.cerebras.ai/?utm=roocode)"
|
|
1393
1429
|
},
|
|
1394
1430
|
"qwen-3-coder-480b": {
|
|
1395
1431
|
maxTokens: 4e4,
|
|
@@ -1398,7 +1434,7 @@ var cerebrasModels = {
|
|
|
1398
1434
|
supportsPromptCache: false,
|
|
1399
1435
|
inputPrice: 0,
|
|
1400
1436
|
outputPrice: 0,
|
|
1401
|
-
description: "SOTA coding model with ~2000 tokens/s ($50/$250 paid tiers)\n\n\u2022 Use this if you have a Cerebras subscription\n\u2022 131K context window with higher rate limits"
|
|
1437
|
+
description: "[SOON TO BE DEPRECATED] SOTA coding model with ~2000 tokens/s ($50/$250 paid tiers)\n\n\u2022 Use this if you have a Cerebras subscription\n\u2022 131K context window with higher rate limits"
|
|
1402
1438
|
},
|
|
1403
1439
|
"qwen-3-235b-a22b-instruct-2507": {
|
|
1404
1440
|
maxTokens: 64e3,
|
|
@@ -1732,6 +1768,25 @@ var chutesModels = {
|
|
|
1732
1768
|
outputPrice: 0,
|
|
1733
1769
|
description: "GLM-4.6 introduces major upgrades over GLM-4.5, including a longer 200K-token context window for complex tasks, stronger coding performance in benchmarks and real-world tools (such as Claude Code, Cline, Roo Code, and Kilo Code), improved reasoning with tool use during inference, more capable and efficient agent integration, and refined writing that better matches human style, readability, and natural role-play scenarios."
|
|
1734
1770
|
},
|
|
1771
|
+
"zai-org/GLM-4.6-turbo": {
|
|
1772
|
+
maxTokens: 202752,
|
|
1773
|
+
// From Chutes /v1/models: max_output_length
|
|
1774
|
+
contextWindow: 202752,
|
|
1775
|
+
supportsImages: false,
|
|
1776
|
+
supportsPromptCache: false,
|
|
1777
|
+
inputPrice: 1.15,
|
|
1778
|
+
outputPrice: 3.25,
|
|
1779
|
+
description: "GLM-4.6-turbo model with 200K-token context window, optimized for fast inference."
|
|
1780
|
+
},
|
|
1781
|
+
"meituan-longcat/LongCat-Flash-Thinking-FP8": {
|
|
1782
|
+
maxTokens: 32768,
|
|
1783
|
+
contextWindow: 128e3,
|
|
1784
|
+
supportsImages: false,
|
|
1785
|
+
supportsPromptCache: false,
|
|
1786
|
+
inputPrice: 0,
|
|
1787
|
+
outputPrice: 0,
|
|
1788
|
+
description: "LongCat Flash Thinking FP8 model with 128K context window, optimized for complex reasoning and coding tasks."
|
|
1789
|
+
},
|
|
1735
1790
|
"Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
|
|
1736
1791
|
maxTokens: 32768,
|
|
1737
1792
|
contextWindow: 262144,
|
|
@@ -1796,13 +1851,14 @@ var chutesModels = {
|
|
|
1796
1851
|
description: "Qwen3\u2011VL\u2011235B\u2011A22B\u2011Thinking is an open\u2011weight MoE vision\u2011language model (235B total, ~22B activated) optimized for deliberate multi\u2011step reasoning with strong text\u2011image\u2011video understanding and long\u2011context capabilities."
|
|
1797
1852
|
}
|
|
1798
1853
|
};
|
|
1854
|
+
var chutesDefaultModelInfo = chutesModels[chutesDefaultModelId];
|
|
1799
1855
|
|
|
1800
1856
|
// src/providers/claude-code.ts
|
|
1801
1857
|
var VERTEX_DATE_PATTERN = /-(\d{8})$/;
|
|
1802
1858
|
function convertModelNameForVertex(modelName) {
|
|
1803
1859
|
return modelName.replace(VERTEX_DATE_PATTERN, "@$1");
|
|
1804
1860
|
}
|
|
1805
|
-
var claudeCodeDefaultModelId = "claude-sonnet-4-
|
|
1861
|
+
var claudeCodeDefaultModelId = "claude-sonnet-4-5";
|
|
1806
1862
|
var CLAUDE_CODE_DEFAULT_MAX_OUTPUT_TOKENS = 16e3;
|
|
1807
1863
|
function getClaudeCodeModelId(baseModelId, useVertex = false) {
|
|
1808
1864
|
return useVertex ? convertModelNameForVertex(baseModelId) : baseModelId;
|
|
@@ -1817,6 +1873,17 @@ var claudeCodeModels = {
|
|
|
1817
1873
|
supportsReasoningBudget: false,
|
|
1818
1874
|
requiredReasoningBudget: false
|
|
1819
1875
|
},
|
|
1876
|
+
"claude-sonnet-4-5-20250929[1m]": {
|
|
1877
|
+
...anthropicModels["claude-sonnet-4-5"],
|
|
1878
|
+
contextWindow: 1e6,
|
|
1879
|
+
// 1M token context window (requires [1m] suffix)
|
|
1880
|
+
supportsImages: false,
|
|
1881
|
+
supportsPromptCache: true,
|
|
1882
|
+
// Claude Code does report cache tokens
|
|
1883
|
+
supportsReasoningEffort: false,
|
|
1884
|
+
supportsReasoningBudget: false,
|
|
1885
|
+
requiredReasoningBudget: false
|
|
1886
|
+
},
|
|
1820
1887
|
"claude-sonnet-4-20250514": {
|
|
1821
1888
|
...anthropicModels["claude-sonnet-4-20250514"],
|
|
1822
1889
|
supportsImages: false,
|
|
@@ -1870,6 +1937,15 @@ var claudeCodeModels = {
|
|
|
1870
1937
|
supportsReasoningEffort: false,
|
|
1871
1938
|
supportsReasoningBudget: false,
|
|
1872
1939
|
requiredReasoningBudget: false
|
|
1940
|
+
},
|
|
1941
|
+
"claude-haiku-4-5-20251001": {
|
|
1942
|
+
...anthropicModels["claude-haiku-4-5-20251001"],
|
|
1943
|
+
supportsImages: false,
|
|
1944
|
+
supportsPromptCache: true,
|
|
1945
|
+
// Claude Code does report cache tokens
|
|
1946
|
+
supportsReasoningEffort: false,
|
|
1947
|
+
supportsReasoningBudget: false,
|
|
1948
|
+
requiredReasoningBudget: false
|
|
1873
1949
|
}
|
|
1874
1950
|
};
|
|
1875
1951
|
|
|
@@ -2036,6 +2112,15 @@ var fireworksModels = {
|
|
|
2036
2112
|
outputPrice: 2.5,
|
|
2037
2113
|
description: "Kimi K2 is a state-of-the-art mixture-of-experts (MoE) language model with 32 billion activated parameters and 1 trillion total parameters. Trained with the Muon optimizer, Kimi K2 achieves exceptional performance across frontier knowledge, reasoning, and coding tasks while being meticulously optimized for agentic capabilities."
|
|
2038
2114
|
},
|
|
2115
|
+
"accounts/fireworks/models/minimax-m2": {
|
|
2116
|
+
maxTokens: 4096,
|
|
2117
|
+
contextWindow: 204800,
|
|
2118
|
+
supportsImages: false,
|
|
2119
|
+
supportsPromptCache: false,
|
|
2120
|
+
inputPrice: 0.3,
|
|
2121
|
+
outputPrice: 1.2,
|
|
2122
|
+
description: "MiniMax M2 is a high-performance language model with 204.8K context window, optimized for long-context understanding and generation tasks."
|
|
2123
|
+
},
|
|
2039
2124
|
"accounts/fireworks/models/qwen3-235b-a22b-instruct-2507": {
|
|
2040
2125
|
maxTokens: 32768,
|
|
2041
2126
|
contextWindow: 256e3,
|
|
@@ -2099,6 +2184,15 @@ var fireworksModels = {
|
|
|
2099
2184
|
outputPrice: 2.19,
|
|
2100
2185
|
description: "Z.ai GLM-4.5-Air with 106B total parameters and 12B active parameters. Features unified reasoning, coding, and intelligent agent capabilities."
|
|
2101
2186
|
},
|
|
2187
|
+
"accounts/fireworks/models/glm-4p6": {
|
|
2188
|
+
maxTokens: 25344,
|
|
2189
|
+
contextWindow: 198e3,
|
|
2190
|
+
supportsImages: false,
|
|
2191
|
+
supportsPromptCache: false,
|
|
2192
|
+
inputPrice: 0.55,
|
|
2193
|
+
outputPrice: 2.19,
|
|
2194
|
+
description: "Z.ai GLM-4.6 is an advanced coding model with exceptional performance on complex programming tasks. Features improved reasoning capabilities and enhanced code generation quality, making it ideal for software development workflows."
|
|
2195
|
+
},
|
|
2102
2196
|
"accounts/fireworks/models/gpt-oss-20b": {
|
|
2103
2197
|
maxTokens: 16384,
|
|
2104
2198
|
contextWindow: 128e3,
|
|
@@ -2122,25 +2216,70 @@ var fireworksModels = {
|
|
|
2122
2216
|
// src/providers/gemini.ts
|
|
2123
2217
|
var geminiDefaultModelId = "gemini-2.0-flash-001";
|
|
2124
2218
|
var geminiModels = {
|
|
2125
|
-
|
|
2126
|
-
|
|
2219
|
+
// Latest models (pointing to the most recent stable versions)
|
|
2220
|
+
"gemini-flash-latest": {
|
|
2221
|
+
maxTokens: 65536,
|
|
2127
2222
|
contextWindow: 1048576,
|
|
2128
2223
|
supportsImages: true,
|
|
2129
|
-
supportsPromptCache:
|
|
2130
|
-
inputPrice: 0.
|
|
2131
|
-
outputPrice:
|
|
2224
|
+
supportsPromptCache: true,
|
|
2225
|
+
inputPrice: 0.3,
|
|
2226
|
+
outputPrice: 2.5,
|
|
2227
|
+
cacheReadsPrice: 0.075,
|
|
2228
|
+
cacheWritesPrice: 1,
|
|
2132
2229
|
maxThinkingTokens: 24576,
|
|
2230
|
+
supportsReasoningBudget: true
|
|
2231
|
+
},
|
|
2232
|
+
"gemini-flash-lite-latest": {
|
|
2233
|
+
maxTokens: 65536,
|
|
2234
|
+
contextWindow: 1048576,
|
|
2235
|
+
supportsImages: true,
|
|
2236
|
+
supportsPromptCache: true,
|
|
2237
|
+
inputPrice: 0.1,
|
|
2238
|
+
outputPrice: 0.4,
|
|
2239
|
+
cacheReadsPrice: 0.025,
|
|
2240
|
+
cacheWritesPrice: 1,
|
|
2133
2241
|
supportsReasoningBudget: true,
|
|
2134
|
-
|
|
2242
|
+
maxThinkingTokens: 24576
|
|
2135
2243
|
},
|
|
2136
|
-
|
|
2137
|
-
|
|
2244
|
+
// 2.5 Flash models (09-2025 versions - most recent)
|
|
2245
|
+
"gemini-2.5-flash-preview-09-2025": {
|
|
2246
|
+
maxTokens: 65536,
|
|
2138
2247
|
contextWindow: 1048576,
|
|
2139
2248
|
supportsImages: true,
|
|
2140
|
-
supportsPromptCache:
|
|
2141
|
-
inputPrice: 0.
|
|
2142
|
-
outputPrice:
|
|
2249
|
+
supportsPromptCache: true,
|
|
2250
|
+
inputPrice: 0.3,
|
|
2251
|
+
outputPrice: 2.5,
|
|
2252
|
+
cacheReadsPrice: 0.075,
|
|
2253
|
+
cacheWritesPrice: 1,
|
|
2254
|
+
maxThinkingTokens: 24576,
|
|
2255
|
+
supportsReasoningBudget: true
|
|
2256
|
+
},
|
|
2257
|
+
"gemini-2.5-flash-lite-preview-09-2025": {
|
|
2258
|
+
maxTokens: 65536,
|
|
2259
|
+
contextWindow: 1048576,
|
|
2260
|
+
supportsImages: true,
|
|
2261
|
+
supportsPromptCache: true,
|
|
2262
|
+
inputPrice: 0.1,
|
|
2263
|
+
outputPrice: 0.4,
|
|
2264
|
+
cacheReadsPrice: 0.025,
|
|
2265
|
+
cacheWritesPrice: 1,
|
|
2266
|
+
supportsReasoningBudget: true,
|
|
2267
|
+
maxThinkingTokens: 24576
|
|
2143
2268
|
},
|
|
2269
|
+
// 2.5 Flash models (06-17 version)
|
|
2270
|
+
"gemini-2.5-flash-lite-preview-06-17": {
|
|
2271
|
+
maxTokens: 64e3,
|
|
2272
|
+
contextWindow: 1048576,
|
|
2273
|
+
supportsImages: true,
|
|
2274
|
+
supportsPromptCache: true,
|
|
2275
|
+
inputPrice: 0.1,
|
|
2276
|
+
outputPrice: 0.4,
|
|
2277
|
+
cacheReadsPrice: 0.025,
|
|
2278
|
+
cacheWritesPrice: 1,
|
|
2279
|
+
supportsReasoningBudget: true,
|
|
2280
|
+
maxThinkingTokens: 24576
|
|
2281
|
+
},
|
|
2282
|
+
// 2.5 Flash models (05-20 versions)
|
|
2144
2283
|
"gemini-2.5-flash-preview-05-20:thinking": {
|
|
2145
2284
|
maxTokens: 65535,
|
|
2146
2285
|
contextWindow: 1048576,
|
|
@@ -2164,6 +2303,27 @@ var geminiModels = {
|
|
|
2164
2303
|
cacheReadsPrice: 0.0375,
|
|
2165
2304
|
cacheWritesPrice: 1
|
|
2166
2305
|
},
|
|
2306
|
+
// 2.5 Flash models (04-17 versions)
|
|
2307
|
+
"gemini-2.5-flash-preview-04-17:thinking": {
|
|
2308
|
+
maxTokens: 65535,
|
|
2309
|
+
contextWindow: 1048576,
|
|
2310
|
+
supportsImages: true,
|
|
2311
|
+
supportsPromptCache: false,
|
|
2312
|
+
inputPrice: 0.15,
|
|
2313
|
+
outputPrice: 3.5,
|
|
2314
|
+
maxThinkingTokens: 24576,
|
|
2315
|
+
supportsReasoningBudget: true,
|
|
2316
|
+
requiredReasoningBudget: true
|
|
2317
|
+
},
|
|
2318
|
+
"gemini-2.5-flash-preview-04-17": {
|
|
2319
|
+
maxTokens: 65535,
|
|
2320
|
+
contextWindow: 1048576,
|
|
2321
|
+
supportsImages: true,
|
|
2322
|
+
supportsPromptCache: false,
|
|
2323
|
+
inputPrice: 0.15,
|
|
2324
|
+
outputPrice: 0.6
|
|
2325
|
+
},
|
|
2326
|
+
// 2.5 Flash stable
|
|
2167
2327
|
"gemini-2.5-flash": {
|
|
2168
2328
|
maxTokens: 64e3,
|
|
2169
2329
|
contextWindow: 1048576,
|
|
@@ -2176,15 +2336,8 @@ var geminiModels = {
|
|
|
2176
2336
|
maxThinkingTokens: 24576,
|
|
2177
2337
|
supportsReasoningBudget: true
|
|
2178
2338
|
},
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
contextWindow: 1048576,
|
|
2182
|
-
supportsImages: true,
|
|
2183
|
-
supportsPromptCache: false,
|
|
2184
|
-
inputPrice: 0,
|
|
2185
|
-
outputPrice: 0
|
|
2186
|
-
},
|
|
2187
|
-
"gemini-2.5-pro-preview-03-25": {
|
|
2339
|
+
// 2.5 Pro models
|
|
2340
|
+
"gemini-2.5-pro-preview-06-05": {
|
|
2188
2341
|
maxTokens: 65535,
|
|
2189
2342
|
contextWindow: 1048576,
|
|
2190
2343
|
supportsImages: true,
|
|
@@ -2194,6 +2347,8 @@ var geminiModels = {
|
|
|
2194
2347
|
outputPrice: 15,
|
|
2195
2348
|
cacheReadsPrice: 0.625,
|
|
2196
2349
|
cacheWritesPrice: 4.5,
|
|
2350
|
+
maxThinkingTokens: 32768,
|
|
2351
|
+
supportsReasoningBudget: true,
|
|
2197
2352
|
tiers: [
|
|
2198
2353
|
{
|
|
2199
2354
|
contextWindow: 2e5,
|
|
@@ -2234,7 +2389,7 @@ var geminiModels = {
|
|
|
2234
2389
|
}
|
|
2235
2390
|
]
|
|
2236
2391
|
},
|
|
2237
|
-
"gemini-2.5-pro-preview-
|
|
2392
|
+
"gemini-2.5-pro-preview-03-25": {
|
|
2238
2393
|
maxTokens: 65535,
|
|
2239
2394
|
contextWindow: 1048576,
|
|
2240
2395
|
supportsImages: true,
|
|
@@ -2261,6 +2416,14 @@ var geminiModels = {
|
|
|
2261
2416
|
}
|
|
2262
2417
|
]
|
|
2263
2418
|
},
|
|
2419
|
+
"gemini-2.5-pro-exp-03-25": {
|
|
2420
|
+
maxTokens: 65535,
|
|
2421
|
+
contextWindow: 1048576,
|
|
2422
|
+
supportsImages: true,
|
|
2423
|
+
supportsPromptCache: false,
|
|
2424
|
+
inputPrice: 0,
|
|
2425
|
+
outputPrice: 0
|
|
2426
|
+
},
|
|
2264
2427
|
"gemini-2.5-pro": {
|
|
2265
2428
|
maxTokens: 64e3,
|
|
2266
2429
|
contextWindow: 1048576,
|
|
@@ -2289,16 +2452,7 @@ var geminiModels = {
|
|
|
2289
2452
|
}
|
|
2290
2453
|
]
|
|
2291
2454
|
},
|
|
2292
|
-
|
|
2293
|
-
maxTokens: 8192,
|
|
2294
|
-
contextWindow: 1048576,
|
|
2295
|
-
supportsImages: true,
|
|
2296
|
-
supportsPromptCache: true,
|
|
2297
|
-
inputPrice: 0.1,
|
|
2298
|
-
outputPrice: 0.4,
|
|
2299
|
-
cacheReadsPrice: 0.025,
|
|
2300
|
-
cacheWritesPrice: 1
|
|
2301
|
-
},
|
|
2455
|
+
// 2.0 Flash models
|
|
2302
2456
|
"gemini-2.0-flash-lite-preview-02-05": {
|
|
2303
2457
|
maxTokens: 8192,
|
|
2304
2458
|
contextWindow: 1048576,
|
|
@@ -2307,14 +2461,6 @@ var geminiModels = {
|
|
|
2307
2461
|
inputPrice: 0,
|
|
2308
2462
|
outputPrice: 0
|
|
2309
2463
|
},
|
|
2310
|
-
"gemini-2.0-pro-exp-02-05": {
|
|
2311
|
-
maxTokens: 8192,
|
|
2312
|
-
contextWindow: 2097152,
|
|
2313
|
-
supportsImages: true,
|
|
2314
|
-
supportsPromptCache: false,
|
|
2315
|
-
inputPrice: 0,
|
|
2316
|
-
outputPrice: 0
|
|
2317
|
-
},
|
|
2318
2464
|
"gemini-2.0-flash-thinking-exp-01-21": {
|
|
2319
2465
|
maxTokens: 65536,
|
|
2320
2466
|
contextWindow: 1048576,
|
|
@@ -2339,6 +2485,26 @@ var geminiModels = {
|
|
|
2339
2485
|
inputPrice: 0,
|
|
2340
2486
|
outputPrice: 0
|
|
2341
2487
|
},
|
|
2488
|
+
"gemini-2.0-flash-001": {
|
|
2489
|
+
maxTokens: 8192,
|
|
2490
|
+
contextWindow: 1048576,
|
|
2491
|
+
supportsImages: true,
|
|
2492
|
+
supportsPromptCache: true,
|
|
2493
|
+
inputPrice: 0.1,
|
|
2494
|
+
outputPrice: 0.4,
|
|
2495
|
+
cacheReadsPrice: 0.025,
|
|
2496
|
+
cacheWritesPrice: 1
|
|
2497
|
+
},
|
|
2498
|
+
// 2.0 Pro models
|
|
2499
|
+
"gemini-2.0-pro-exp-02-05": {
|
|
2500
|
+
maxTokens: 8192,
|
|
2501
|
+
contextWindow: 2097152,
|
|
2502
|
+
supportsImages: true,
|
|
2503
|
+
supportsPromptCache: false,
|
|
2504
|
+
inputPrice: 0,
|
|
2505
|
+
outputPrice: 0
|
|
2506
|
+
},
|
|
2507
|
+
// 1.5 Flash models
|
|
2342
2508
|
"gemini-1.5-flash-002": {
|
|
2343
2509
|
maxTokens: 8192,
|
|
2344
2510
|
contextWindow: 1048576,
|
|
@@ -2380,6 +2546,7 @@ var geminiModels = {
|
|
|
2380
2546
|
inputPrice: 0,
|
|
2381
2547
|
outputPrice: 0
|
|
2382
2548
|
},
|
|
2549
|
+
// 1.5 Pro models
|
|
2383
2550
|
"gemini-1.5-pro-002": {
|
|
2384
2551
|
maxTokens: 8192,
|
|
2385
2552
|
contextWindow: 2097152,
|
|
@@ -2396,6 +2563,7 @@ var geminiModels = {
|
|
|
2396
2563
|
inputPrice: 0,
|
|
2397
2564
|
outputPrice: 0
|
|
2398
2565
|
},
|
|
2566
|
+
// Experimental models
|
|
2399
2567
|
"gemini-exp-1206": {
|
|
2400
2568
|
maxTokens: 8192,
|
|
2401
2569
|
contextWindow: 2097152,
|
|
@@ -2403,18 +2571,6 @@ var geminiModels = {
|
|
|
2403
2571
|
supportsPromptCache: false,
|
|
2404
2572
|
inputPrice: 0,
|
|
2405
2573
|
outputPrice: 0
|
|
2406
|
-
},
|
|
2407
|
-
"gemini-2.5-flash-lite-preview-06-17": {
|
|
2408
|
-
maxTokens: 64e3,
|
|
2409
|
-
contextWindow: 1048576,
|
|
2410
|
-
supportsImages: true,
|
|
2411
|
-
supportsPromptCache: true,
|
|
2412
|
-
inputPrice: 0.1,
|
|
2413
|
-
outputPrice: 0.4,
|
|
2414
|
-
cacheReadsPrice: 0.025,
|
|
2415
|
-
cacheWritesPrice: 1,
|
|
2416
|
-
supportsReasoningBudget: true,
|
|
2417
|
-
maxThinkingTokens: 24576
|
|
2418
2574
|
}
|
|
2419
2575
|
};
|
|
2420
2576
|
|
|
@@ -2424,7 +2580,6 @@ var glamaDefaultModelInfo = {
|
|
|
2424
2580
|
maxTokens: 8192,
|
|
2425
2581
|
contextWindow: 2e5,
|
|
2426
2582
|
supportsImages: true,
|
|
2427
|
-
supportsComputerUse: true,
|
|
2428
2583
|
supportsPromptCache: true,
|
|
2429
2584
|
inputPrice: 3,
|
|
2430
2585
|
outputPrice: 15,
|
|
@@ -2602,50 +2757,12 @@ var litellmDefaultModelInfo = {
|
|
|
2602
2757
|
maxTokens: 8192,
|
|
2603
2758
|
contextWindow: 2e5,
|
|
2604
2759
|
supportsImages: true,
|
|
2605
|
-
supportsComputerUse: true,
|
|
2606
2760
|
supportsPromptCache: true,
|
|
2607
2761
|
inputPrice: 3,
|
|
2608
2762
|
outputPrice: 15,
|
|
2609
2763
|
cacheWritesPrice: 3.75,
|
|
2610
2764
|
cacheReadsPrice: 0.3
|
|
2611
2765
|
};
|
|
2612
|
-
var LITELLM_COMPUTER_USE_MODELS = /* @__PURE__ */ new Set([
|
|
2613
|
-
"claude-3-5-sonnet-latest",
|
|
2614
|
-
"claude-opus-4-1-20250805",
|
|
2615
|
-
"claude-opus-4-20250514",
|
|
2616
|
-
"claude-sonnet-4-20250514",
|
|
2617
|
-
"claude-3-7-sonnet-latest",
|
|
2618
|
-
"claude-3-7-sonnet-20250219",
|
|
2619
|
-
"claude-3-5-sonnet-20241022",
|
|
2620
|
-
"vertex_ai/claude-3-5-sonnet",
|
|
2621
|
-
"vertex_ai/claude-3-5-sonnet-v2",
|
|
2622
|
-
"vertex_ai/claude-3-5-sonnet-v2@20241022",
|
|
2623
|
-
"vertex_ai/claude-3-7-sonnet@20250219",
|
|
2624
|
-
"vertex_ai/claude-opus-4-1@20250805",
|
|
2625
|
-
"vertex_ai/claude-opus-4@20250514",
|
|
2626
|
-
"vertex_ai/claude-sonnet-4@20250514",
|
|
2627
|
-
"vertex_ai/claude-sonnet-4-5@20250929",
|
|
2628
|
-
"openrouter/anthropic/claude-3.5-sonnet",
|
|
2629
|
-
"openrouter/anthropic/claude-3.5-sonnet:beta",
|
|
2630
|
-
"openrouter/anthropic/claude-3.7-sonnet",
|
|
2631
|
-
"openrouter/anthropic/claude-3.7-sonnet:beta",
|
|
2632
|
-
"anthropic.claude-opus-4-1-20250805-v1:0",
|
|
2633
|
-
"anthropic.claude-opus-4-20250514-v1:0",
|
|
2634
|
-
"anthropic.claude-sonnet-4-20250514-v1:0",
|
|
2635
|
-
"anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
2636
|
-
"anthropic.claude-3-5-sonnet-20241022-v2:0",
|
|
2637
|
-
"us.anthropic.claude-3-5-sonnet-20241022-v2:0",
|
|
2638
|
-
"us.anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
2639
|
-
"us.anthropic.claude-opus-4-1-20250805-v1:0",
|
|
2640
|
-
"us.anthropic.claude-opus-4-20250514-v1:0",
|
|
2641
|
-
"us.anthropic.claude-sonnet-4-20250514-v1:0",
|
|
2642
|
-
"eu.anthropic.claude-3-5-sonnet-20241022-v2:0",
|
|
2643
|
-
"eu.anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
2644
|
-
"eu.anthropic.claude-opus-4-1-20250805-v1:0",
|
|
2645
|
-
"eu.anthropic.claude-opus-4-20250514-v1:0",
|
|
2646
|
-
"eu.anthropic.claude-sonnet-4-20250514-v1:0",
|
|
2647
|
-
"snowflake/claude-3-5-sonnet"
|
|
2648
|
-
]);
|
|
2649
2766
|
|
|
2650
2767
|
// src/providers/lm-studio.ts
|
|
2651
2768
|
var LMSTUDIO_DEFAULT_TEMPERATURE = 0;
|
|
@@ -2654,7 +2771,6 @@ var lMStudioDefaultModelInfo = {
|
|
|
2654
2771
|
maxTokens: 8192,
|
|
2655
2772
|
contextWindow: 2e5,
|
|
2656
2773
|
supportsImages: true,
|
|
2657
|
-
supportsComputerUse: true,
|
|
2658
2774
|
supportsPromptCache: true,
|
|
2659
2775
|
inputPrice: 0,
|
|
2660
2776
|
outputPrice: 0,
|
|
@@ -2667,9 +2783,9 @@ var lMStudioDefaultModelInfo = {
|
|
|
2667
2783
|
var mistralDefaultModelId = "codestral-latest";
|
|
2668
2784
|
var mistralModels = {
|
|
2669
2785
|
"magistral-medium-latest": {
|
|
2670
|
-
maxTokens:
|
|
2671
|
-
contextWindow:
|
|
2672
|
-
supportsImages:
|
|
2786
|
+
maxTokens: 8192,
|
|
2787
|
+
contextWindow: 128e3,
|
|
2788
|
+
supportsImages: true,
|
|
2673
2789
|
supportsPromptCache: false,
|
|
2674
2790
|
inputPrice: 2,
|
|
2675
2791
|
outputPrice: 5
|
|
@@ -2783,6 +2899,28 @@ var moonshotModels = {
|
|
|
2783
2899
|
cacheReadsPrice: 0.6,
|
|
2784
2900
|
// $0.60 per million tokens (cache hit)
|
|
2785
2901
|
description: `Kimi K2 Turbo is a high-speed version of the state-of-the-art Kimi K2 mixture-of-experts (MoE) language model, with the same 32 billion activated parameters and 1 trillion total parameters, optimized for output speeds of up to 60 tokens per second, peaking at 100 tokens per second.`
|
|
2902
|
+
},
|
|
2903
|
+
"kimi-k2-thinking": {
|
|
2904
|
+
maxTokens: 16e3,
|
|
2905
|
+
// Recommended ≥ 16,000
|
|
2906
|
+
contextWindow: 262144,
|
|
2907
|
+
// 262,144 tokens
|
|
2908
|
+
supportsImages: false,
|
|
2909
|
+
// Text-only (no image/vision support)
|
|
2910
|
+
supportsPromptCache: true,
|
|
2911
|
+
inputPrice: 0.6,
|
|
2912
|
+
// $0.60 per million tokens (cache miss)
|
|
2913
|
+
outputPrice: 2.5,
|
|
2914
|
+
// $2.50 per million tokens
|
|
2915
|
+
cacheWritesPrice: 0,
|
|
2916
|
+
// $0 per million tokens (cache miss)
|
|
2917
|
+
cacheReadsPrice: 0.15,
|
|
2918
|
+
// $0.15 per million tokens (cache hit)
|
|
2919
|
+
supportsTemperature: true,
|
|
2920
|
+
// Default temperature: 1.0
|
|
2921
|
+
preserveReasoning: true,
|
|
2922
|
+
defaultTemperature: 1,
|
|
2923
|
+
description: `The kimi-k2-thinking model is a general-purpose agentic reasoning model developed by Moonshot AI. Thanks to its strength in deep reasoning and multi-turn tool use, it can solve even the hardest problems.`
|
|
2786
2924
|
}
|
|
2787
2925
|
};
|
|
2788
2926
|
var MOONSHOT_DEFAULT_TEMPERATURE = 0.6;
|
|
@@ -2793,7 +2931,6 @@ var ollamaDefaultModelInfo = {
|
|
|
2793
2931
|
maxTokens: 4096,
|
|
2794
2932
|
contextWindow: 2e5,
|
|
2795
2933
|
supportsImages: true,
|
|
2796
|
-
supportsComputerUse: true,
|
|
2797
2934
|
supportsPromptCache: true,
|
|
2798
2935
|
inputPrice: 0,
|
|
2799
2936
|
outputPrice: 0,
|
|
@@ -3114,12 +3251,11 @@ var GPT5_DEFAULT_TEMPERATURE = 1;
|
|
|
3114
3251
|
var OPENAI_AZURE_AI_INFERENCE_PATH = "/models/chat/completions";
|
|
3115
3252
|
|
|
3116
3253
|
// src/providers/openrouter.ts
|
|
3117
|
-
var openRouterDefaultModelId = "anthropic/claude-sonnet-4";
|
|
3254
|
+
var openRouterDefaultModelId = "anthropic/claude-sonnet-4.5";
|
|
3118
3255
|
var openRouterDefaultModelInfo = {
|
|
3119
3256
|
maxTokens: 8192,
|
|
3120
3257
|
contextWindow: 2e5,
|
|
3121
3258
|
supportsImages: true,
|
|
3122
|
-
supportsComputerUse: true,
|
|
3123
3259
|
supportsPromptCache: true,
|
|
3124
3260
|
inputPrice: 3,
|
|
3125
3261
|
outputPrice: 15,
|
|
@@ -3150,6 +3286,7 @@ var OPEN_ROUTER_PROMPT_CACHING_MODELS = /* @__PURE__ */ new Set([
|
|
|
3150
3286
|
"anthropic/claude-sonnet-4.5",
|
|
3151
3287
|
"anthropic/claude-opus-4",
|
|
3152
3288
|
"anthropic/claude-opus-4.1",
|
|
3289
|
+
"anthropic/claude-haiku-4.5",
|
|
3153
3290
|
"google/gemini-2.5-flash-preview",
|
|
3154
3291
|
"google/gemini-2.5-flash-preview:thinking",
|
|
3155
3292
|
"google/gemini-2.5-flash-preview-05-20",
|
|
@@ -3160,17 +3297,6 @@ var OPEN_ROUTER_PROMPT_CACHING_MODELS = /* @__PURE__ */ new Set([
|
|
|
3160
3297
|
"google/gemini-flash-1.5",
|
|
3161
3298
|
"google/gemini-flash-1.5-8b"
|
|
3162
3299
|
]);
|
|
3163
|
-
var OPEN_ROUTER_COMPUTER_USE_MODELS = /* @__PURE__ */ new Set([
|
|
3164
|
-
"anthropic/claude-3.5-sonnet",
|
|
3165
|
-
"anthropic/claude-3.5-sonnet:beta",
|
|
3166
|
-
"anthropic/claude-3.7-sonnet",
|
|
3167
|
-
"anthropic/claude-3.7-sonnet:beta",
|
|
3168
|
-
"anthropic/claude-3.7-sonnet:thinking",
|
|
3169
|
-
"anthropic/claude-sonnet-4",
|
|
3170
|
-
"anthropic/claude-sonnet-4.5",
|
|
3171
|
-
"anthropic/claude-opus-4",
|
|
3172
|
-
"anthropic/claude-opus-4.1"
|
|
3173
|
-
]);
|
|
3174
3300
|
var OPEN_ROUTER_REQUIRED_REASONING_BUDGET_MODELS = /* @__PURE__ */ new Set([
|
|
3175
3301
|
"anthropic/claude-3.7-sonnet:thinking",
|
|
3176
3302
|
"google/gemini-2.5-pro",
|
|
@@ -3182,6 +3308,7 @@ var OPEN_ROUTER_REASONING_BUDGET_MODELS = /* @__PURE__ */ new Set([
|
|
|
3182
3308
|
"anthropic/claude-opus-4.1",
|
|
3183
3309
|
"anthropic/claude-sonnet-4",
|
|
3184
3310
|
"anthropic/claude-sonnet-4.5",
|
|
3311
|
+
"anthropic/claude-haiku-4.5",
|
|
3185
3312
|
"google/gemini-2.5-pro-preview",
|
|
3186
3313
|
"google/gemini-2.5-pro",
|
|
3187
3314
|
"google/gemini-2.5-flash-preview-05-20",
|
|
@@ -3226,7 +3353,6 @@ var requestyDefaultModelInfo = {
|
|
|
3226
3353
|
maxTokens: 8192,
|
|
3227
3354
|
contextWindow: 2e5,
|
|
3228
3355
|
supportsImages: true,
|
|
3229
|
-
supportsComputerUse: true,
|
|
3230
3356
|
supportsPromptCache: true,
|
|
3231
3357
|
inputPrice: 3,
|
|
3232
3358
|
outputPrice: 15,
|
|
@@ -3236,46 +3362,33 @@ var requestyDefaultModelInfo = {
|
|
|
3236
3362
|
};
|
|
3237
3363
|
|
|
3238
3364
|
// src/providers/roo.ts
|
|
3365
|
+
var import_zod7 = require("zod");
|
|
3239
3366
|
var rooDefaultModelId = "xai/grok-code-fast-1";
|
|
3240
|
-
var rooModels = {
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
|
|
3252
|
-
|
|
3253
|
-
|
|
3254
|
-
|
|
3255
|
-
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
outputPrice: 0,
|
|
3266
|
-
description: "Grok 4 Fast is xAI's latest multimodal model with SOTA cost-efficiency and a 2M token context window. (Note: prompts and completions are logged by xAI and used to improve the model.)",
|
|
3267
|
-
deprecated: true
|
|
3268
|
-
},
|
|
3269
|
-
"deepseek/deepseek-chat-v3.1": {
|
|
3270
|
-
maxTokens: 16384,
|
|
3271
|
-
contextWindow: 163840,
|
|
3272
|
-
supportsImages: false,
|
|
3273
|
-
supportsPromptCache: false,
|
|
3274
|
-
inputPrice: 0,
|
|
3275
|
-
outputPrice: 0,
|
|
3276
|
-
description: "DeepSeek-V3.1 is a large hybrid reasoning model (671B parameters, 37B active). It extends the DeepSeek-V3 base with a two-phase long-context training process, reaching up to 128K tokens, and uses FP8 microscaling for efficient inference."
|
|
3277
|
-
}
|
|
3278
|
-
};
|
|
3367
|
+
var rooModels = {};
|
|
3368
|
+
var RooPricingSchema = import_zod7.z.object({
|
|
3369
|
+
input: import_zod7.z.string(),
|
|
3370
|
+
output: import_zod7.z.string(),
|
|
3371
|
+
input_cache_read: import_zod7.z.string().optional(),
|
|
3372
|
+
input_cache_write: import_zod7.z.string().optional()
|
|
3373
|
+
});
|
|
3374
|
+
var RooModelSchema = import_zod7.z.object({
|
|
3375
|
+
id: import_zod7.z.string(),
|
|
3376
|
+
object: import_zod7.z.literal("model"),
|
|
3377
|
+
created: import_zod7.z.number(),
|
|
3378
|
+
owned_by: import_zod7.z.string(),
|
|
3379
|
+
name: import_zod7.z.string(),
|
|
3380
|
+
description: import_zod7.z.string(),
|
|
3381
|
+
context_window: import_zod7.z.number(),
|
|
3382
|
+
max_tokens: import_zod7.z.number(),
|
|
3383
|
+
type: import_zod7.z.literal("language"),
|
|
3384
|
+
tags: import_zod7.z.array(import_zod7.z.string()).optional(),
|
|
3385
|
+
pricing: RooPricingSchema,
|
|
3386
|
+
deprecated: import_zod7.z.boolean().optional()
|
|
3387
|
+
});
|
|
3388
|
+
var RooModelsResponseSchema = import_zod7.z.object({
|
|
3389
|
+
object: import_zod7.z.literal("list"),
|
|
3390
|
+
data: import_zod7.z.array(RooModelSchema)
|
|
3391
|
+
});
|
|
3279
3392
|
|
|
3280
3393
|
// src/providers/sambanova.ts
|
|
3281
3394
|
var sambaNovaDefaultModelId = "Meta-Llama-3.3-70B-Instruct";
|
|
@@ -3374,7 +3487,7 @@ var sambaNovaModels = {
|
|
|
3374
3487
|
};
|
|
3375
3488
|
|
|
3376
3489
|
// src/providers/unbound.ts
|
|
3377
|
-
var unboundDefaultModelId = "anthropic/claude-
|
|
3490
|
+
var unboundDefaultModelId = "anthropic/claude-sonnet-4-5";
|
|
3378
3491
|
var unboundDefaultModelInfo = {
|
|
3379
3492
|
maxTokens: 8192,
|
|
3380
3493
|
contextWindow: 2e5,
|
|
@@ -3550,7 +3663,6 @@ var vertexModels = {
|
|
|
3550
3663
|
maxTokens: 8192,
|
|
3551
3664
|
contextWindow: 2e5,
|
|
3552
3665
|
supportsImages: true,
|
|
3553
|
-
supportsComputerUse: true,
|
|
3554
3666
|
supportsPromptCache: true,
|
|
3555
3667
|
inputPrice: 3,
|
|
3556
3668
|
outputPrice: 15,
|
|
@@ -3562,7 +3674,6 @@ var vertexModels = {
|
|
|
3562
3674
|
maxTokens: 8192,
|
|
3563
3675
|
contextWindow: 2e5,
|
|
3564
3676
|
supportsImages: true,
|
|
3565
|
-
supportsComputerUse: true,
|
|
3566
3677
|
supportsPromptCache: true,
|
|
3567
3678
|
inputPrice: 3,
|
|
3568
3679
|
outputPrice: 15,
|
|
@@ -3570,11 +3681,21 @@ var vertexModels = {
|
|
|
3570
3681
|
cacheReadsPrice: 0.3,
|
|
3571
3682
|
supportsReasoningBudget: true
|
|
3572
3683
|
},
|
|
3684
|
+
"claude-haiku-4-5@20251001": {
|
|
3685
|
+
maxTokens: 8192,
|
|
3686
|
+
contextWindow: 2e5,
|
|
3687
|
+
supportsImages: true,
|
|
3688
|
+
supportsPromptCache: true,
|
|
3689
|
+
inputPrice: 1,
|
|
3690
|
+
outputPrice: 5,
|
|
3691
|
+
cacheWritesPrice: 1.25,
|
|
3692
|
+
cacheReadsPrice: 0.1,
|
|
3693
|
+
supportsReasoningBudget: true
|
|
3694
|
+
},
|
|
3573
3695
|
"claude-opus-4-1@20250805": {
|
|
3574
3696
|
maxTokens: 8192,
|
|
3575
3697
|
contextWindow: 2e5,
|
|
3576
3698
|
supportsImages: true,
|
|
3577
|
-
supportsComputerUse: true,
|
|
3578
3699
|
supportsPromptCache: true,
|
|
3579
3700
|
inputPrice: 15,
|
|
3580
3701
|
outputPrice: 75,
|
|
@@ -3586,7 +3707,6 @@ var vertexModels = {
|
|
|
3586
3707
|
maxTokens: 8192,
|
|
3587
3708
|
contextWindow: 2e5,
|
|
3588
3709
|
supportsImages: true,
|
|
3589
|
-
supportsComputerUse: true,
|
|
3590
3710
|
supportsPromptCache: true,
|
|
3591
3711
|
inputPrice: 15,
|
|
3592
3712
|
outputPrice: 75,
|
|
@@ -3597,7 +3717,6 @@ var vertexModels = {
|
|
|
3597
3717
|
maxTokens: 64e3,
|
|
3598
3718
|
contextWindow: 2e5,
|
|
3599
3719
|
supportsImages: true,
|
|
3600
|
-
supportsComputerUse: true,
|
|
3601
3720
|
supportsPromptCache: true,
|
|
3602
3721
|
inputPrice: 3,
|
|
3603
3722
|
outputPrice: 15,
|
|
@@ -3610,7 +3729,6 @@ var vertexModels = {
|
|
|
3610
3729
|
maxTokens: 8192,
|
|
3611
3730
|
contextWindow: 2e5,
|
|
3612
3731
|
supportsImages: true,
|
|
3613
|
-
supportsComputerUse: true,
|
|
3614
3732
|
supportsPromptCache: true,
|
|
3615
3733
|
inputPrice: 3,
|
|
3616
3734
|
outputPrice: 15,
|
|
@@ -3621,7 +3739,6 @@ var vertexModels = {
|
|
|
3621
3739
|
maxTokens: 8192,
|
|
3622
3740
|
contextWindow: 2e5,
|
|
3623
3741
|
supportsImages: true,
|
|
3624
|
-
supportsComputerUse: true,
|
|
3625
3742
|
supportsPromptCache: true,
|
|
3626
3743
|
inputPrice: 3,
|
|
3627
3744
|
outputPrice: 15,
|
|
@@ -4141,7 +4258,6 @@ var vercelAiGatewayDefaultModelInfo = {
|
|
|
4141
4258
|
maxTokens: 64e3,
|
|
4142
4259
|
contextWindow: 2e5,
|
|
4143
4260
|
supportsImages: true,
|
|
4144
|
-
supportsComputerUse: true,
|
|
4145
4261
|
supportsPromptCache: true,
|
|
4146
4262
|
inputPrice: 3,
|
|
4147
4263
|
outputPrice: 15,
|
|
@@ -4152,13 +4268,14 @@ var vercelAiGatewayDefaultModelInfo = {
|
|
|
4152
4268
|
var VERCEL_AI_GATEWAY_DEFAULT_TEMPERATURE = 0.7;
|
|
4153
4269
|
|
|
4154
4270
|
// src/providers/zai.ts
|
|
4155
|
-
var internationalZAiDefaultModelId = "glm-4.
|
|
4271
|
+
var internationalZAiDefaultModelId = "glm-4.6";
|
|
4156
4272
|
var internationalZAiModels = {
|
|
4157
4273
|
"glm-4.5": {
|
|
4158
4274
|
maxTokens: 98304,
|
|
4159
4275
|
contextWindow: 131072,
|
|
4160
4276
|
supportsImages: false,
|
|
4161
4277
|
supportsPromptCache: true,
|
|
4278
|
+
supportsReasoningBinary: true,
|
|
4162
4279
|
inputPrice: 0.6,
|
|
4163
4280
|
outputPrice: 2.2,
|
|
4164
4281
|
cacheWritesPrice: 0,
|
|
@@ -4176,50 +4293,87 @@ var internationalZAiModels = {
|
|
|
4176
4293
|
cacheReadsPrice: 0.03,
|
|
4177
4294
|
description: "GLM-4.5-Air is the lightweight version of GLM-4.5. It balances performance and cost-effectiveness, and can flexibly switch to hybrid thinking models."
|
|
4178
4295
|
},
|
|
4296
|
+
"glm-4.5-x": {
|
|
4297
|
+
maxTokens: 98304,
|
|
4298
|
+
contextWindow: 131072,
|
|
4299
|
+
supportsImages: false,
|
|
4300
|
+
supportsPromptCache: true,
|
|
4301
|
+
inputPrice: 2.2,
|
|
4302
|
+
outputPrice: 8.9,
|
|
4303
|
+
cacheWritesPrice: 0,
|
|
4304
|
+
cacheReadsPrice: 0.45,
|
|
4305
|
+
description: "GLM-4.5-X is a high-performance variant optimized for strong reasoning with ultra-fast responses."
|
|
4306
|
+
},
|
|
4307
|
+
"glm-4.5-airx": {
|
|
4308
|
+
maxTokens: 98304,
|
|
4309
|
+
contextWindow: 131072,
|
|
4310
|
+
supportsImages: false,
|
|
4311
|
+
supportsPromptCache: true,
|
|
4312
|
+
inputPrice: 1.1,
|
|
4313
|
+
outputPrice: 4.5,
|
|
4314
|
+
cacheWritesPrice: 0,
|
|
4315
|
+
cacheReadsPrice: 0.22,
|
|
4316
|
+
description: "GLM-4.5-AirX is a lightweight, ultra-fast variant delivering strong performance with lower cost."
|
|
4317
|
+
},
|
|
4318
|
+
"glm-4.5-flash": {
|
|
4319
|
+
maxTokens: 98304,
|
|
4320
|
+
contextWindow: 131072,
|
|
4321
|
+
supportsImages: false,
|
|
4322
|
+
supportsPromptCache: true,
|
|
4323
|
+
inputPrice: 0,
|
|
4324
|
+
outputPrice: 0,
|
|
4325
|
+
cacheWritesPrice: 0,
|
|
4326
|
+
cacheReadsPrice: 0,
|
|
4327
|
+
description: "GLM-4.5-Flash is a free, high-speed model excellent for reasoning, coding, and agentic tasks."
|
|
4328
|
+
},
|
|
4329
|
+
"glm-4.5v": {
|
|
4330
|
+
maxTokens: 16384,
|
|
4331
|
+
contextWindow: 131072,
|
|
4332
|
+
supportsImages: true,
|
|
4333
|
+
supportsPromptCache: true,
|
|
4334
|
+
inputPrice: 0.6,
|
|
4335
|
+
outputPrice: 1.8,
|
|
4336
|
+
cacheWritesPrice: 0,
|
|
4337
|
+
cacheReadsPrice: 0.11,
|
|
4338
|
+
description: "GLM-4.5V is Z.AI's multimodal visual reasoning model (image/video/text/file input), optimized for GUI tasks, grounding, and document/video understanding."
|
|
4339
|
+
},
|
|
4179
4340
|
"glm-4.6": {
|
|
4180
4341
|
maxTokens: 98304,
|
|
4181
|
-
contextWindow:
|
|
4342
|
+
contextWindow: 2e5,
|
|
4182
4343
|
supportsImages: false,
|
|
4183
4344
|
supportsPromptCache: true,
|
|
4345
|
+
supportsReasoningBinary: true,
|
|
4184
4346
|
inputPrice: 0.6,
|
|
4185
4347
|
outputPrice: 2.2,
|
|
4186
4348
|
cacheWritesPrice: 0,
|
|
4187
4349
|
cacheReadsPrice: 0.11,
|
|
4188
4350
|
description: "GLM-4.6 is Zhipu's newest model with an extended context window of up to 200k tokens, providing enhanced capabilities for processing longer documents and conversations."
|
|
4351
|
+
},
|
|
4352
|
+
"glm-4-32b-0414-128k": {
|
|
4353
|
+
maxTokens: 98304,
|
|
4354
|
+
contextWindow: 131072,
|
|
4355
|
+
supportsImages: false,
|
|
4356
|
+
supportsPromptCache: false,
|
|
4357
|
+
inputPrice: 0.1,
|
|
4358
|
+
outputPrice: 0.1,
|
|
4359
|
+
cacheWritesPrice: 0,
|
|
4360
|
+
cacheReadsPrice: 0,
|
|
4361
|
+
description: "GLM-4-32B is a 32 billion parameter model with 128k context length, optimized for efficiency."
|
|
4189
4362
|
}
|
|
4190
4363
|
};
|
|
4191
|
-
var mainlandZAiDefaultModelId = "glm-4.
|
|
4364
|
+
var mainlandZAiDefaultModelId = "glm-4.6";
|
|
4192
4365
|
var mainlandZAiModels = {
|
|
4193
4366
|
"glm-4.5": {
|
|
4194
4367
|
maxTokens: 98304,
|
|
4195
4368
|
contextWindow: 131072,
|
|
4196
4369
|
supportsImages: false,
|
|
4197
4370
|
supportsPromptCache: true,
|
|
4371
|
+
supportsReasoningBinary: true,
|
|
4198
4372
|
inputPrice: 0.29,
|
|
4199
4373
|
outputPrice: 1.14,
|
|
4200
4374
|
cacheWritesPrice: 0,
|
|
4201
4375
|
cacheReadsPrice: 0.057,
|
|
4202
|
-
description: "GLM-4.5 is Zhipu's latest featured model. Its comprehensive capabilities in reasoning, coding, and agent reach the state-of-the-art (SOTA) level among open-source models, with a context length of up to 128k."
|
|
4203
|
-
tiers: [
|
|
4204
|
-
{
|
|
4205
|
-
contextWindow: 32e3,
|
|
4206
|
-
inputPrice: 0.21,
|
|
4207
|
-
outputPrice: 1,
|
|
4208
|
-
cacheReadsPrice: 0.043
|
|
4209
|
-
},
|
|
4210
|
-
{
|
|
4211
|
-
contextWindow: 128e3,
|
|
4212
|
-
inputPrice: 0.29,
|
|
4213
|
-
outputPrice: 1.14,
|
|
4214
|
-
cacheReadsPrice: 0.057
|
|
4215
|
-
},
|
|
4216
|
-
{
|
|
4217
|
-
contextWindow: Infinity,
|
|
4218
|
-
inputPrice: 0.29,
|
|
4219
|
-
outputPrice: 1.14,
|
|
4220
|
-
cacheReadsPrice: 0.057
|
|
4221
|
-
}
|
|
4222
|
-
]
|
|
4376
|
+
description: "GLM-4.5 is Zhipu's latest featured model. Its comprehensive capabilities in reasoning, coding, and agent reach the state-of-the-art (SOTA) level among open-source models, with a context length of up to 128k."
|
|
4223
4377
|
},
|
|
4224
4378
|
"glm-4.5-air": {
|
|
4225
4379
|
maxTokens: 98304,
|
|
@@ -4230,76 +4384,77 @@ var mainlandZAiModels = {
|
|
|
4230
4384
|
outputPrice: 0.6,
|
|
4231
4385
|
cacheWritesPrice: 0,
|
|
4232
4386
|
cacheReadsPrice: 0.02,
|
|
4233
|
-
description: "GLM-4.5-Air is the lightweight version of GLM-4.5. It balances performance and cost-effectiveness, and can flexibly switch to hybrid thinking models."
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
|
|
4239
|
-
|
|
4240
|
-
|
|
4241
|
-
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
|
|
4247
|
-
|
|
4248
|
-
|
|
4249
|
-
|
|
4250
|
-
|
|
4251
|
-
|
|
4252
|
-
|
|
4253
|
-
|
|
4387
|
+
description: "GLM-4.5-Air is the lightweight version of GLM-4.5. It balances performance and cost-effectiveness, and can flexibly switch to hybrid thinking models."
|
|
4388
|
+
},
|
|
4389
|
+
"glm-4.5-x": {
|
|
4390
|
+
maxTokens: 98304,
|
|
4391
|
+
contextWindow: 131072,
|
|
4392
|
+
supportsImages: false,
|
|
4393
|
+
supportsPromptCache: true,
|
|
4394
|
+
inputPrice: 0.29,
|
|
4395
|
+
outputPrice: 1.14,
|
|
4396
|
+
cacheWritesPrice: 0,
|
|
4397
|
+
cacheReadsPrice: 0.057,
|
|
4398
|
+
description: "GLM-4.5-X is a high-performance variant optimized for strong reasoning with ultra-fast responses."
|
|
4399
|
+
},
|
|
4400
|
+
"glm-4.5-airx": {
|
|
4401
|
+
maxTokens: 98304,
|
|
4402
|
+
contextWindow: 131072,
|
|
4403
|
+
supportsImages: false,
|
|
4404
|
+
supportsPromptCache: true,
|
|
4405
|
+
inputPrice: 0.1,
|
|
4406
|
+
outputPrice: 0.6,
|
|
4407
|
+
cacheWritesPrice: 0,
|
|
4408
|
+
cacheReadsPrice: 0.02,
|
|
4409
|
+
description: "GLM-4.5-AirX is a lightweight, ultra-fast variant delivering strong performance with lower cost."
|
|
4410
|
+
},
|
|
4411
|
+
"glm-4.5-flash": {
|
|
4412
|
+
maxTokens: 98304,
|
|
4413
|
+
contextWindow: 131072,
|
|
4414
|
+
supportsImages: false,
|
|
4415
|
+
supportsPromptCache: true,
|
|
4416
|
+
inputPrice: 0,
|
|
4417
|
+
outputPrice: 0,
|
|
4418
|
+
cacheWritesPrice: 0,
|
|
4419
|
+
cacheReadsPrice: 0,
|
|
4420
|
+
description: "GLM-4.5-Flash is a free, high-speed model excellent for reasoning, coding, and agentic tasks."
|
|
4421
|
+
},
|
|
4422
|
+
"glm-4.5v": {
|
|
4423
|
+
maxTokens: 16384,
|
|
4424
|
+
contextWindow: 131072,
|
|
4425
|
+
supportsImages: true,
|
|
4426
|
+
supportsPromptCache: true,
|
|
4427
|
+
inputPrice: 0.29,
|
|
4428
|
+
outputPrice: 0.93,
|
|
4429
|
+
cacheWritesPrice: 0,
|
|
4430
|
+
cacheReadsPrice: 0.057,
|
|
4431
|
+
description: "GLM-4.5V is Z.AI's multimodal visual reasoning model (image/video/text/file input), optimized for GUI tasks, grounding, and document/video understanding."
|
|
4254
4432
|
},
|
|
4255
4433
|
"glm-4.6": {
|
|
4256
4434
|
maxTokens: 98304,
|
|
4257
4435
|
contextWindow: 204800,
|
|
4258
4436
|
supportsImages: false,
|
|
4259
4437
|
supportsPromptCache: true,
|
|
4438
|
+
supportsReasoningBinary: true,
|
|
4260
4439
|
inputPrice: 0.29,
|
|
4261
4440
|
outputPrice: 1.14,
|
|
4262
4441
|
cacheWritesPrice: 0,
|
|
4263
4442
|
cacheReadsPrice: 0.057,
|
|
4264
|
-
description: "GLM-4.6 is Zhipu's newest model with an extended context window of up to 200k tokens, providing enhanced capabilities for processing longer documents and conversations."
|
|
4265
|
-
tiers: [
|
|
4266
|
-
{
|
|
4267
|
-
contextWindow: 32e3,
|
|
4268
|
-
inputPrice: 0.21,
|
|
4269
|
-
outputPrice: 1,
|
|
4270
|
-
cacheReadsPrice: 0.043
|
|
4271
|
-
},
|
|
4272
|
-
{
|
|
4273
|
-
contextWindow: 128e3,
|
|
4274
|
-
inputPrice: 0.29,
|
|
4275
|
-
outputPrice: 1.14,
|
|
4276
|
-
cacheReadsPrice: 0.057
|
|
4277
|
-
},
|
|
4278
|
-
{
|
|
4279
|
-
contextWindow: 2e5,
|
|
4280
|
-
inputPrice: 0.29,
|
|
4281
|
-
outputPrice: 1.14,
|
|
4282
|
-
cacheReadsPrice: 0.057
|
|
4283
|
-
},
|
|
4284
|
-
{
|
|
4285
|
-
contextWindow: Infinity,
|
|
4286
|
-
inputPrice: 0.29,
|
|
4287
|
-
outputPrice: 1.14,
|
|
4288
|
-
cacheReadsPrice: 0.057
|
|
4289
|
-
}
|
|
4290
|
-
]
|
|
4443
|
+
description: "GLM-4.6 is Zhipu's newest model with an extended context window of up to 200k tokens, providing enhanced capabilities for processing longer documents and conversations."
|
|
4291
4444
|
}
|
|
4292
4445
|
};
|
|
4293
|
-
var ZAI_DEFAULT_TEMPERATURE = 0;
|
|
4446
|
+
var ZAI_DEFAULT_TEMPERATURE = 0.6;
|
|
4294
4447
|
var zaiApiLineConfigs = {
|
|
4295
4448
|
international_coding: {
|
|
4296
|
-
name: "International
|
|
4449
|
+
name: "International",
|
|
4297
4450
|
baseUrl: "https://api.z.ai/api/coding/paas/v4",
|
|
4298
4451
|
isChina: false
|
|
4299
4452
|
},
|
|
4300
|
-
|
|
4301
|
-
|
|
4302
|
-
|
|
4453
|
+
china_coding: {
|
|
4454
|
+
name: "China",
|
|
4455
|
+
baseUrl: "https://open.bigmodel.cn/api/coding/paas/v4",
|
|
4456
|
+
isChina: true
|
|
4457
|
+
}
|
|
4303
4458
|
};
|
|
4304
4459
|
|
|
4305
4460
|
// src/providers/deepinfra.ts
|
|
@@ -4314,6 +4469,118 @@ var deepInfraDefaultModelInfo = {
|
|
|
4314
4469
|
description: "Qwen 3 Coder 480B A35B Instruct Turbo model, 256K context."
|
|
4315
4470
|
};
|
|
4316
4471
|
|
|
4472
|
+
// src/providers/minimax.ts
|
|
4473
|
+
var minimaxDefaultModelId = "MiniMax-M2";
|
|
4474
|
+
var minimaxModels = {
|
|
4475
|
+
"MiniMax-M2": {
|
|
4476
|
+
maxTokens: 16384,
|
|
4477
|
+
contextWindow: 192e3,
|
|
4478
|
+
supportsImages: false,
|
|
4479
|
+
supportsPromptCache: true,
|
|
4480
|
+
inputPrice: 0.3,
|
|
4481
|
+
outputPrice: 1.2,
|
|
4482
|
+
cacheWritesPrice: 0.375,
|
|
4483
|
+
cacheReadsPrice: 0.03,
|
|
4484
|
+
preserveReasoning: true,
|
|
4485
|
+
description: "MiniMax M2, a model born for Agents and code, featuring Top-tier Coding Capabilities, Powerful Agentic Performance, and Ultimate Cost-Effectiveness & Speed."
|
|
4486
|
+
},
|
|
4487
|
+
"MiniMax-M2-Stable": {
|
|
4488
|
+
maxTokens: 16384,
|
|
4489
|
+
contextWindow: 192e3,
|
|
4490
|
+
supportsImages: false,
|
|
4491
|
+
supportsPromptCache: true,
|
|
4492
|
+
inputPrice: 0.3,
|
|
4493
|
+
outputPrice: 1.2,
|
|
4494
|
+
cacheWritesPrice: 0.375,
|
|
4495
|
+
cacheReadsPrice: 0.03,
|
|
4496
|
+
preserveReasoning: true,
|
|
4497
|
+
description: "MiniMax M2 Stable (High Concurrency, Commercial Use), a model born for Agents and code, featuring Top-tier Coding Capabilities, Powerful Agentic Performance, and Ultimate Cost-Effectiveness & Speed."
|
|
4498
|
+
}
|
|
4499
|
+
};
|
|
4500
|
+
var MINIMAX_DEFAULT_TEMPERATURE = 1;
|
|
4501
|
+
|
|
4502
|
+
// src/providers/index.ts
|
|
4503
|
+
function getProviderDefaultModelId(provider, options = { isChina: false }) {
|
|
4504
|
+
switch (provider) {
|
|
4505
|
+
case "openrouter":
|
|
4506
|
+
return openRouterDefaultModelId;
|
|
4507
|
+
case "requesty":
|
|
4508
|
+
return requestyDefaultModelId;
|
|
4509
|
+
case "glama":
|
|
4510
|
+
return glamaDefaultModelId;
|
|
4511
|
+
case "unbound":
|
|
4512
|
+
return unboundDefaultModelId;
|
|
4513
|
+
case "litellm":
|
|
4514
|
+
return litellmDefaultModelId;
|
|
4515
|
+
case "xai":
|
|
4516
|
+
return xaiDefaultModelId;
|
|
4517
|
+
case "groq":
|
|
4518
|
+
return groqDefaultModelId;
|
|
4519
|
+
case "huggingface":
|
|
4520
|
+
return "meta-llama/Llama-3.3-70B-Instruct";
|
|
4521
|
+
case "chutes":
|
|
4522
|
+
return chutesDefaultModelId;
|
|
4523
|
+
case "bedrock":
|
|
4524
|
+
return bedrockDefaultModelId;
|
|
4525
|
+
case "vertex":
|
|
4526
|
+
return vertexDefaultModelId;
|
|
4527
|
+
case "gemini":
|
|
4528
|
+
return geminiDefaultModelId;
|
|
4529
|
+
case "deepseek":
|
|
4530
|
+
return deepSeekDefaultModelId;
|
|
4531
|
+
case "doubao":
|
|
4532
|
+
return doubaoDefaultModelId;
|
|
4533
|
+
case "moonshot":
|
|
4534
|
+
return moonshotDefaultModelId;
|
|
4535
|
+
case "minimax":
|
|
4536
|
+
return minimaxDefaultModelId;
|
|
4537
|
+
case "zai":
|
|
4538
|
+
return options?.isChina ? mainlandZAiDefaultModelId : internationalZAiDefaultModelId;
|
|
4539
|
+
case "openai-native":
|
|
4540
|
+
return "gpt-4o";
|
|
4541
|
+
// Based on openai-native patterns
|
|
4542
|
+
case "mistral":
|
|
4543
|
+
return mistralDefaultModelId;
|
|
4544
|
+
case "openai":
|
|
4545
|
+
return "";
|
|
4546
|
+
// OpenAI provider uses custom model configuration
|
|
4547
|
+
case "ollama":
|
|
4548
|
+
return "";
|
|
4549
|
+
// Ollama uses dynamic model selection
|
|
4550
|
+
case "lmstudio":
|
|
4551
|
+
return "";
|
|
4552
|
+
// LMStudio uses dynamic model selection
|
|
4553
|
+
case "deepinfra":
|
|
4554
|
+
return deepInfraDefaultModelId;
|
|
4555
|
+
case "vscode-lm":
|
|
4556
|
+
return vscodeLlmDefaultModelId;
|
|
4557
|
+
case "claude-code":
|
|
4558
|
+
return claudeCodeDefaultModelId;
|
|
4559
|
+
case "cerebras":
|
|
4560
|
+
return cerebrasDefaultModelId;
|
|
4561
|
+
case "sambanova":
|
|
4562
|
+
return sambaNovaDefaultModelId;
|
|
4563
|
+
case "fireworks":
|
|
4564
|
+
return fireworksDefaultModelId;
|
|
4565
|
+
case "featherless":
|
|
4566
|
+
return featherlessDefaultModelId;
|
|
4567
|
+
case "io-intelligence":
|
|
4568
|
+
return ioIntelligenceDefaultModelId;
|
|
4569
|
+
case "roo":
|
|
4570
|
+
return rooDefaultModelId;
|
|
4571
|
+
case "qwen-code":
|
|
4572
|
+
return qwenCodeDefaultModelId;
|
|
4573
|
+
case "vercel-ai-gateway":
|
|
4574
|
+
return vercelAiGatewayDefaultModelId;
|
|
4575
|
+
case "anthropic":
|
|
4576
|
+
case "gemini-cli":
|
|
4577
|
+
case "human-relay":
|
|
4578
|
+
case "fake-ai":
|
|
4579
|
+
default:
|
|
4580
|
+
return anthropicDefaultModelId;
|
|
4581
|
+
}
|
|
4582
|
+
}
|
|
4583
|
+
|
|
4317
4584
|
// src/provider-settings.ts
|
|
4318
4585
|
var DEFAULT_CONSECUTIVE_MISTAKE_LIMIT = 3;
|
|
4319
4586
|
var dynamicProviders = [
|
|
@@ -4325,7 +4592,9 @@ var dynamicProviders = [
|
|
|
4325
4592
|
"io-intelligence",
|
|
4326
4593
|
"requesty",
|
|
4327
4594
|
"unbound",
|
|
4328
|
-
"glama"
|
|
4595
|
+
"glama",
|
|
4596
|
+
"roo",
|
|
4597
|
+
"chutes"
|
|
4329
4598
|
];
|
|
4330
4599
|
var isDynamicProvider = (key) => dynamicProviders.includes(key);
|
|
4331
4600
|
var localProviders = ["ollama", "lmstudio"];
|
|
@@ -4345,7 +4614,6 @@ var providerNames = [
|
|
|
4345
4614
|
"anthropic",
|
|
4346
4615
|
"bedrock",
|
|
4347
4616
|
"cerebras",
|
|
4348
|
-
"chutes",
|
|
4349
4617
|
"claude-code",
|
|
4350
4618
|
"doubao",
|
|
4351
4619
|
"deepseek",
|
|
@@ -4356,6 +4624,7 @@ var providerNames = [
|
|
|
4356
4624
|
"groq",
|
|
4357
4625
|
"mistral",
|
|
4358
4626
|
"moonshot",
|
|
4627
|
+
"minimax",
|
|
4359
4628
|
"openai-native",
|
|
4360
4629
|
"qwen-code",
|
|
4361
4630
|
"roo",
|
|
@@ -4364,260 +4633,267 @@ var providerNames = [
|
|
|
4364
4633
|
"xai",
|
|
4365
4634
|
"zai"
|
|
4366
4635
|
];
|
|
4367
|
-
var providerNamesSchema =
|
|
4636
|
+
var providerNamesSchema = import_zod8.z.enum(providerNames);
|
|
4368
4637
|
var isProviderName = (key) => typeof key === "string" && providerNames.includes(key);
|
|
4369
|
-
var providerSettingsEntrySchema =
|
|
4370
|
-
id:
|
|
4371
|
-
name:
|
|
4638
|
+
var providerSettingsEntrySchema = import_zod8.z.object({
|
|
4639
|
+
id: import_zod8.z.string(),
|
|
4640
|
+
name: import_zod8.z.string(),
|
|
4372
4641
|
apiProvider: providerNamesSchema.optional(),
|
|
4373
|
-
modelId:
|
|
4642
|
+
modelId: import_zod8.z.string().optional()
|
|
4374
4643
|
});
|
|
4375
|
-
var baseProviderSettingsSchema =
|
|
4376
|
-
includeMaxTokens:
|
|
4377
|
-
diffEnabled:
|
|
4378
|
-
todoListEnabled:
|
|
4379
|
-
fuzzyMatchThreshold:
|
|
4380
|
-
modelTemperature:
|
|
4381
|
-
rateLimitSeconds:
|
|
4382
|
-
consecutiveMistakeLimit:
|
|
4644
|
+
var baseProviderSettingsSchema = import_zod8.z.object({
|
|
4645
|
+
includeMaxTokens: import_zod8.z.boolean().optional(),
|
|
4646
|
+
diffEnabled: import_zod8.z.boolean().optional(),
|
|
4647
|
+
todoListEnabled: import_zod8.z.boolean().optional(),
|
|
4648
|
+
fuzzyMatchThreshold: import_zod8.z.number().optional(),
|
|
4649
|
+
modelTemperature: import_zod8.z.number().nullish(),
|
|
4650
|
+
rateLimitSeconds: import_zod8.z.number().optional(),
|
|
4651
|
+
consecutiveMistakeLimit: import_zod8.z.number().min(0).optional(),
|
|
4383
4652
|
// Model reasoning.
|
|
4384
|
-
enableReasoningEffort:
|
|
4653
|
+
enableReasoningEffort: import_zod8.z.boolean().optional(),
|
|
4385
4654
|
reasoningEffort: reasoningEffortWithMinimalSchema.optional(),
|
|
4386
|
-
modelMaxTokens:
|
|
4387
|
-
modelMaxThinkingTokens:
|
|
4655
|
+
modelMaxTokens: import_zod8.z.number().optional(),
|
|
4656
|
+
modelMaxThinkingTokens: import_zod8.z.number().optional(),
|
|
4388
4657
|
// Model verbosity.
|
|
4389
4658
|
verbosity: verbosityLevelsSchema.optional()
|
|
4390
4659
|
});
|
|
4391
4660
|
var apiModelIdProviderModelSchema = baseProviderSettingsSchema.extend({
|
|
4392
|
-
apiModelId:
|
|
4661
|
+
apiModelId: import_zod8.z.string().optional()
|
|
4393
4662
|
});
|
|
4394
4663
|
var anthropicSchema = apiModelIdProviderModelSchema.extend({
|
|
4395
|
-
apiKey:
|
|
4396
|
-
anthropicBaseUrl:
|
|
4397
|
-
anthropicUseAuthToken:
|
|
4398
|
-
anthropicBeta1MContext:
|
|
4664
|
+
apiKey: import_zod8.z.string().optional(),
|
|
4665
|
+
anthropicBaseUrl: import_zod8.z.string().optional(),
|
|
4666
|
+
anthropicUseAuthToken: import_zod8.z.boolean().optional(),
|
|
4667
|
+
anthropicBeta1MContext: import_zod8.z.boolean().optional()
|
|
4399
4668
|
// Enable 'context-1m-2025-08-07' beta for 1M context window.
|
|
4400
4669
|
});
|
|
4401
4670
|
var claudeCodeSchema = apiModelIdProviderModelSchema.extend({
|
|
4402
|
-
claudeCodePath:
|
|
4403
|
-
claudeCodeMaxOutputTokens:
|
|
4671
|
+
claudeCodePath: import_zod8.z.string().optional(),
|
|
4672
|
+
claudeCodeMaxOutputTokens: import_zod8.z.number().int().min(1).max(2e5).optional()
|
|
4404
4673
|
});
|
|
4405
4674
|
var glamaSchema = baseProviderSettingsSchema.extend({
|
|
4406
|
-
glamaModelId:
|
|
4407
|
-
glamaApiKey:
|
|
4675
|
+
glamaModelId: import_zod8.z.string().optional(),
|
|
4676
|
+
glamaApiKey: import_zod8.z.string().optional()
|
|
4408
4677
|
});
|
|
4409
4678
|
var openRouterSchema = baseProviderSettingsSchema.extend({
|
|
4410
|
-
openRouterApiKey:
|
|
4411
|
-
openRouterModelId:
|
|
4412
|
-
openRouterBaseUrl:
|
|
4413
|
-
openRouterSpecificProvider:
|
|
4414
|
-
openRouterUseMiddleOutTransform:
|
|
4679
|
+
openRouterApiKey: import_zod8.z.string().optional(),
|
|
4680
|
+
openRouterModelId: import_zod8.z.string().optional(),
|
|
4681
|
+
openRouterBaseUrl: import_zod8.z.string().optional(),
|
|
4682
|
+
openRouterSpecificProvider: import_zod8.z.string().optional(),
|
|
4683
|
+
openRouterUseMiddleOutTransform: import_zod8.z.boolean().optional()
|
|
4415
4684
|
});
|
|
4416
4685
|
var bedrockSchema = apiModelIdProviderModelSchema.extend({
|
|
4417
|
-
awsAccessKey:
|
|
4418
|
-
awsSecretKey:
|
|
4419
|
-
awsSessionToken:
|
|
4420
|
-
awsRegion:
|
|
4421
|
-
awsUseCrossRegionInference:
|
|
4422
|
-
|
|
4423
|
-
|
|
4424
|
-
|
|
4425
|
-
|
|
4426
|
-
|
|
4427
|
-
|
|
4428
|
-
|
|
4429
|
-
|
|
4430
|
-
|
|
4431
|
-
|
|
4686
|
+
awsAccessKey: import_zod8.z.string().optional(),
|
|
4687
|
+
awsSecretKey: import_zod8.z.string().optional(),
|
|
4688
|
+
awsSessionToken: import_zod8.z.string().optional(),
|
|
4689
|
+
awsRegion: import_zod8.z.string().optional(),
|
|
4690
|
+
awsUseCrossRegionInference: import_zod8.z.boolean().optional(),
|
|
4691
|
+
awsUseGlobalInference: import_zod8.z.boolean().optional(),
|
|
4692
|
+
// Enable Global Inference profile routing when supported
|
|
4693
|
+
awsUsePromptCache: import_zod8.z.boolean().optional(),
|
|
4694
|
+
awsProfile: import_zod8.z.string().optional(),
|
|
4695
|
+
awsUseProfile: import_zod8.z.boolean().optional(),
|
|
4696
|
+
awsApiKey: import_zod8.z.string().optional(),
|
|
4697
|
+
awsUseApiKey: import_zod8.z.boolean().optional(),
|
|
4698
|
+
awsCustomArn: import_zod8.z.string().optional(),
|
|
4699
|
+
awsModelContextWindow: import_zod8.z.number().optional(),
|
|
4700
|
+
awsBedrockEndpointEnabled: import_zod8.z.boolean().optional(),
|
|
4701
|
+
awsBedrockEndpoint: import_zod8.z.string().optional(),
|
|
4702
|
+
awsBedrock1MContext: import_zod8.z.boolean().optional()
|
|
4432
4703
|
// Enable 'context-1m-2025-08-07' beta for 1M context window.
|
|
4433
4704
|
});
|
|
4434
4705
|
var vertexSchema = apiModelIdProviderModelSchema.extend({
|
|
4435
|
-
vertexKeyFile:
|
|
4436
|
-
vertexJsonCredentials:
|
|
4437
|
-
vertexProjectId:
|
|
4438
|
-
vertexRegion:
|
|
4439
|
-
enableUrlContext:
|
|
4440
|
-
enableGrounding:
|
|
4706
|
+
vertexKeyFile: import_zod8.z.string().optional(),
|
|
4707
|
+
vertexJsonCredentials: import_zod8.z.string().optional(),
|
|
4708
|
+
vertexProjectId: import_zod8.z.string().optional(),
|
|
4709
|
+
vertexRegion: import_zod8.z.string().optional(),
|
|
4710
|
+
enableUrlContext: import_zod8.z.boolean().optional(),
|
|
4711
|
+
enableGrounding: import_zod8.z.boolean().optional()
|
|
4441
4712
|
});
|
|
4442
4713
|
var openAiSchema = baseProviderSettingsSchema.extend({
|
|
4443
|
-
openAiBaseUrl:
|
|
4444
|
-
openAiApiKey:
|
|
4445
|
-
openAiLegacyFormat:
|
|
4446
|
-
openAiR1FormatEnabled:
|
|
4447
|
-
openAiModelId:
|
|
4714
|
+
openAiBaseUrl: import_zod8.z.string().optional(),
|
|
4715
|
+
openAiApiKey: import_zod8.z.string().optional(),
|
|
4716
|
+
openAiLegacyFormat: import_zod8.z.boolean().optional(),
|
|
4717
|
+
openAiR1FormatEnabled: import_zod8.z.boolean().optional(),
|
|
4718
|
+
openAiModelId: import_zod8.z.string().optional(),
|
|
4448
4719
|
openAiCustomModelInfo: modelInfoSchema.nullish(),
|
|
4449
|
-
openAiUseAzure:
|
|
4450
|
-
azureApiVersion:
|
|
4451
|
-
openAiStreamingEnabled:
|
|
4452
|
-
openAiHostHeader:
|
|
4720
|
+
openAiUseAzure: import_zod8.z.boolean().optional(),
|
|
4721
|
+
azureApiVersion: import_zod8.z.string().optional(),
|
|
4722
|
+
openAiStreamingEnabled: import_zod8.z.boolean().optional(),
|
|
4723
|
+
openAiHostHeader: import_zod8.z.string().optional(),
|
|
4453
4724
|
// Keep temporarily for backward compatibility during migration.
|
|
4454
|
-
openAiHeaders:
|
|
4725
|
+
openAiHeaders: import_zod8.z.record(import_zod8.z.string(), import_zod8.z.string()).optional()
|
|
4455
4726
|
});
|
|
4456
4727
|
var ollamaSchema = baseProviderSettingsSchema.extend({
|
|
4457
|
-
ollamaModelId:
|
|
4458
|
-
ollamaBaseUrl:
|
|
4459
|
-
ollamaApiKey:
|
|
4460
|
-
ollamaNumCtx:
|
|
4728
|
+
ollamaModelId: import_zod8.z.string().optional(),
|
|
4729
|
+
ollamaBaseUrl: import_zod8.z.string().optional(),
|
|
4730
|
+
ollamaApiKey: import_zod8.z.string().optional(),
|
|
4731
|
+
ollamaNumCtx: import_zod8.z.number().int().min(128).optional()
|
|
4461
4732
|
});
|
|
4462
4733
|
var vsCodeLmSchema = baseProviderSettingsSchema.extend({
|
|
4463
|
-
vsCodeLmModelSelector:
|
|
4464
|
-
vendor:
|
|
4465
|
-
family:
|
|
4466
|
-
version:
|
|
4467
|
-
id:
|
|
4734
|
+
vsCodeLmModelSelector: import_zod8.z.object({
|
|
4735
|
+
vendor: import_zod8.z.string().optional(),
|
|
4736
|
+
family: import_zod8.z.string().optional(),
|
|
4737
|
+
version: import_zod8.z.string().optional(),
|
|
4738
|
+
id: import_zod8.z.string().optional()
|
|
4468
4739
|
}).optional()
|
|
4469
4740
|
});
|
|
4470
4741
|
var lmStudioSchema = baseProviderSettingsSchema.extend({
|
|
4471
|
-
lmStudioModelId:
|
|
4472
|
-
lmStudioBaseUrl:
|
|
4473
|
-
lmStudioDraftModelId:
|
|
4474
|
-
lmStudioSpeculativeDecodingEnabled:
|
|
4742
|
+
lmStudioModelId: import_zod8.z.string().optional(),
|
|
4743
|
+
lmStudioBaseUrl: import_zod8.z.string().optional(),
|
|
4744
|
+
lmStudioDraftModelId: import_zod8.z.string().optional(),
|
|
4745
|
+
lmStudioSpeculativeDecodingEnabled: import_zod8.z.boolean().optional()
|
|
4475
4746
|
});
|
|
4476
4747
|
var geminiSchema = apiModelIdProviderModelSchema.extend({
|
|
4477
|
-
geminiApiKey:
|
|
4478
|
-
googleGeminiBaseUrl:
|
|
4479
|
-
enableUrlContext:
|
|
4480
|
-
enableGrounding:
|
|
4748
|
+
geminiApiKey: import_zod8.z.string().optional(),
|
|
4749
|
+
googleGeminiBaseUrl: import_zod8.z.string().optional(),
|
|
4750
|
+
enableUrlContext: import_zod8.z.boolean().optional(),
|
|
4751
|
+
enableGrounding: import_zod8.z.boolean().optional()
|
|
4481
4752
|
});
|
|
4482
4753
|
var geminiCliSchema = apiModelIdProviderModelSchema.extend({
|
|
4483
|
-
geminiCliOAuthPath:
|
|
4484
|
-
geminiCliProjectId:
|
|
4754
|
+
geminiCliOAuthPath: import_zod8.z.string().optional(),
|
|
4755
|
+
geminiCliProjectId: import_zod8.z.string().optional()
|
|
4485
4756
|
});
|
|
4486
4757
|
var openAiNativeSchema = apiModelIdProviderModelSchema.extend({
|
|
4487
|
-
openAiNativeApiKey:
|
|
4488
|
-
openAiNativeBaseUrl:
|
|
4758
|
+
openAiNativeApiKey: import_zod8.z.string().optional(),
|
|
4759
|
+
openAiNativeBaseUrl: import_zod8.z.string().optional(),
|
|
4489
4760
|
// OpenAI Responses API service tier for openai-native provider only.
|
|
4490
4761
|
// UI should only expose this when the selected model supports flex/priority.
|
|
4491
4762
|
openAiNativeServiceTier: serviceTierSchema.optional()
|
|
4492
4763
|
});
|
|
4493
4764
|
var mistralSchema = apiModelIdProviderModelSchema.extend({
|
|
4494
|
-
mistralApiKey:
|
|
4495
|
-
mistralCodestralUrl:
|
|
4765
|
+
mistralApiKey: import_zod8.z.string().optional(),
|
|
4766
|
+
mistralCodestralUrl: import_zod8.z.string().optional()
|
|
4496
4767
|
});
|
|
4497
4768
|
var deepSeekSchema = apiModelIdProviderModelSchema.extend({
|
|
4498
|
-
deepSeekBaseUrl:
|
|
4499
|
-
deepSeekApiKey:
|
|
4769
|
+
deepSeekBaseUrl: import_zod8.z.string().optional(),
|
|
4770
|
+
deepSeekApiKey: import_zod8.z.string().optional()
|
|
4500
4771
|
});
|
|
4501
4772
|
var deepInfraSchema = apiModelIdProviderModelSchema.extend({
|
|
4502
|
-
deepInfraBaseUrl:
|
|
4503
|
-
deepInfraApiKey:
|
|
4504
|
-
deepInfraModelId:
|
|
4773
|
+
deepInfraBaseUrl: import_zod8.z.string().optional(),
|
|
4774
|
+
deepInfraApiKey: import_zod8.z.string().optional(),
|
|
4775
|
+
deepInfraModelId: import_zod8.z.string().optional()
|
|
4505
4776
|
});
|
|
4506
4777
|
var doubaoSchema = apiModelIdProviderModelSchema.extend({
|
|
4507
|
-
doubaoBaseUrl:
|
|
4508
|
-
doubaoApiKey:
|
|
4778
|
+
doubaoBaseUrl: import_zod8.z.string().optional(),
|
|
4779
|
+
doubaoApiKey: import_zod8.z.string().optional()
|
|
4509
4780
|
});
|
|
4510
4781
|
var moonshotSchema = apiModelIdProviderModelSchema.extend({
|
|
4511
|
-
moonshotBaseUrl:
|
|
4512
|
-
moonshotApiKey:
|
|
4782
|
+
moonshotBaseUrl: import_zod8.z.union([import_zod8.z.literal("https://api.moonshot.ai/v1"), import_zod8.z.literal("https://api.moonshot.cn/v1")]).optional(),
|
|
4783
|
+
moonshotApiKey: import_zod8.z.string().optional()
|
|
4784
|
+
});
|
|
4785
|
+
var minimaxSchema = apiModelIdProviderModelSchema.extend({
|
|
4786
|
+
minimaxBaseUrl: import_zod8.z.union([import_zod8.z.literal("https://api.minimax.io/v1"), import_zod8.z.literal("https://api.minimaxi.com/v1")]).optional(),
|
|
4787
|
+
minimaxApiKey: import_zod8.z.string().optional()
|
|
4513
4788
|
});
|
|
4514
4789
|
var unboundSchema = baseProviderSettingsSchema.extend({
|
|
4515
|
-
unboundApiKey:
|
|
4516
|
-
unboundModelId:
|
|
4790
|
+
unboundApiKey: import_zod8.z.string().optional(),
|
|
4791
|
+
unboundModelId: import_zod8.z.string().optional()
|
|
4517
4792
|
});
|
|
4518
4793
|
var requestySchema = baseProviderSettingsSchema.extend({
|
|
4519
|
-
requestyBaseUrl:
|
|
4520
|
-
requestyApiKey:
|
|
4521
|
-
requestyModelId:
|
|
4794
|
+
requestyBaseUrl: import_zod8.z.string().optional(),
|
|
4795
|
+
requestyApiKey: import_zod8.z.string().optional(),
|
|
4796
|
+
requestyModelId: import_zod8.z.string().optional()
|
|
4522
4797
|
});
|
|
4523
4798
|
var humanRelaySchema = baseProviderSettingsSchema;
|
|
4524
4799
|
var fakeAiSchema = baseProviderSettingsSchema.extend({
|
|
4525
|
-
fakeAi:
|
|
4800
|
+
fakeAi: import_zod8.z.unknown().optional()
|
|
4526
4801
|
});
|
|
4527
4802
|
var xaiSchema = apiModelIdProviderModelSchema.extend({
|
|
4528
|
-
xaiApiKey:
|
|
4803
|
+
xaiApiKey: import_zod8.z.string().optional()
|
|
4529
4804
|
});
|
|
4530
4805
|
var groqSchema = apiModelIdProviderModelSchema.extend({
|
|
4531
|
-
groqApiKey:
|
|
4806
|
+
groqApiKey: import_zod8.z.string().optional()
|
|
4532
4807
|
});
|
|
4533
4808
|
var huggingFaceSchema = baseProviderSettingsSchema.extend({
|
|
4534
|
-
huggingFaceApiKey:
|
|
4535
|
-
huggingFaceModelId:
|
|
4536
|
-
huggingFaceInferenceProvider:
|
|
4809
|
+
huggingFaceApiKey: import_zod8.z.string().optional(),
|
|
4810
|
+
huggingFaceModelId: import_zod8.z.string().optional(),
|
|
4811
|
+
huggingFaceInferenceProvider: import_zod8.z.string().optional()
|
|
4537
4812
|
});
|
|
4538
4813
|
var chutesSchema = apiModelIdProviderModelSchema.extend({
|
|
4539
|
-
chutesApiKey:
|
|
4814
|
+
chutesApiKey: import_zod8.z.string().optional()
|
|
4540
4815
|
});
|
|
4541
4816
|
var litellmSchema = baseProviderSettingsSchema.extend({
|
|
4542
|
-
litellmBaseUrl:
|
|
4543
|
-
litellmApiKey:
|
|
4544
|
-
litellmModelId:
|
|
4545
|
-
litellmUsePromptCache:
|
|
4817
|
+
litellmBaseUrl: import_zod8.z.string().optional(),
|
|
4818
|
+
litellmApiKey: import_zod8.z.string().optional(),
|
|
4819
|
+
litellmModelId: import_zod8.z.string().optional(),
|
|
4820
|
+
litellmUsePromptCache: import_zod8.z.boolean().optional()
|
|
4546
4821
|
});
|
|
4547
4822
|
var cerebrasSchema = apiModelIdProviderModelSchema.extend({
|
|
4548
|
-
cerebrasApiKey:
|
|
4823
|
+
cerebrasApiKey: import_zod8.z.string().optional()
|
|
4549
4824
|
});
|
|
4550
4825
|
var sambaNovaSchema = apiModelIdProviderModelSchema.extend({
|
|
4551
|
-
sambaNovaApiKey:
|
|
4826
|
+
sambaNovaApiKey: import_zod8.z.string().optional()
|
|
4552
4827
|
});
|
|
4553
|
-
var zaiApiLineSchema =
|
|
4828
|
+
var zaiApiLineSchema = import_zod8.z.enum(["international_coding", "china_coding"]);
|
|
4554
4829
|
var zaiSchema = apiModelIdProviderModelSchema.extend({
|
|
4555
|
-
zaiApiKey:
|
|
4830
|
+
zaiApiKey: import_zod8.z.string().optional(),
|
|
4556
4831
|
zaiApiLine: zaiApiLineSchema.optional()
|
|
4557
4832
|
});
|
|
4558
4833
|
var fireworksSchema = apiModelIdProviderModelSchema.extend({
|
|
4559
|
-
fireworksApiKey:
|
|
4834
|
+
fireworksApiKey: import_zod8.z.string().optional()
|
|
4560
4835
|
});
|
|
4561
4836
|
var featherlessSchema = apiModelIdProviderModelSchema.extend({
|
|
4562
|
-
featherlessApiKey:
|
|
4837
|
+
featherlessApiKey: import_zod8.z.string().optional()
|
|
4563
4838
|
});
|
|
4564
4839
|
var ioIntelligenceSchema = apiModelIdProviderModelSchema.extend({
|
|
4565
|
-
ioIntelligenceModelId:
|
|
4566
|
-
ioIntelligenceApiKey:
|
|
4840
|
+
ioIntelligenceModelId: import_zod8.z.string().optional(),
|
|
4841
|
+
ioIntelligenceApiKey: import_zod8.z.string().optional()
|
|
4567
4842
|
});
|
|
4568
4843
|
var qwenCodeSchema = apiModelIdProviderModelSchema.extend({
|
|
4569
|
-
qwenCodeOauthPath:
|
|
4844
|
+
qwenCodeOauthPath: import_zod8.z.string().optional()
|
|
4570
4845
|
});
|
|
4571
4846
|
var rooSchema = apiModelIdProviderModelSchema.extend({
|
|
4572
4847
|
// No additional fields needed - uses cloud authentication.
|
|
4573
4848
|
});
|
|
4574
4849
|
var vercelAiGatewaySchema = baseProviderSettingsSchema.extend({
|
|
4575
|
-
vercelAiGatewayApiKey:
|
|
4576
|
-
vercelAiGatewayModelId:
|
|
4850
|
+
vercelAiGatewayApiKey: import_zod8.z.string().optional(),
|
|
4851
|
+
vercelAiGatewayModelId: import_zod8.z.string().optional()
|
|
4577
4852
|
});
|
|
4578
|
-
var defaultSchema =
|
|
4579
|
-
apiProvider:
|
|
4853
|
+
var defaultSchema = import_zod8.z.object({
|
|
4854
|
+
apiProvider: import_zod8.z.undefined()
|
|
4580
4855
|
});
|
|
4581
|
-
var providerSettingsSchemaDiscriminated =
|
|
4582
|
-
anthropicSchema.merge(
|
|
4583
|
-
claudeCodeSchema.merge(
|
|
4584
|
-
glamaSchema.merge(
|
|
4585
|
-
openRouterSchema.merge(
|
|
4586
|
-
bedrockSchema.merge(
|
|
4587
|
-
vertexSchema.merge(
|
|
4588
|
-
openAiSchema.merge(
|
|
4589
|
-
ollamaSchema.merge(
|
|
4590
|
-
vsCodeLmSchema.merge(
|
|
4591
|
-
lmStudioSchema.merge(
|
|
4592
|
-
geminiSchema.merge(
|
|
4593
|
-
geminiCliSchema.merge(
|
|
4594
|
-
openAiNativeSchema.merge(
|
|
4595
|
-
mistralSchema.merge(
|
|
4596
|
-
deepSeekSchema.merge(
|
|
4597
|
-
deepInfraSchema.merge(
|
|
4598
|
-
doubaoSchema.merge(
|
|
4599
|
-
moonshotSchema.merge(
|
|
4600
|
-
|
|
4601
|
-
|
|
4602
|
-
|
|
4603
|
-
|
|
4604
|
-
|
|
4605
|
-
|
|
4606
|
-
|
|
4607
|
-
|
|
4608
|
-
|
|
4609
|
-
|
|
4610
|
-
|
|
4611
|
-
|
|
4612
|
-
|
|
4613
|
-
|
|
4614
|
-
|
|
4615
|
-
|
|
4616
|
-
|
|
4617
|
-
|
|
4856
|
+
var providerSettingsSchemaDiscriminated = import_zod8.z.discriminatedUnion("apiProvider", [
|
|
4857
|
+
anthropicSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("anthropic") })),
|
|
4858
|
+
claudeCodeSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("claude-code") })),
|
|
4859
|
+
glamaSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("glama") })),
|
|
4860
|
+
openRouterSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("openrouter") })),
|
|
4861
|
+
bedrockSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("bedrock") })),
|
|
4862
|
+
vertexSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("vertex") })),
|
|
4863
|
+
openAiSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("openai") })),
|
|
4864
|
+
ollamaSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("ollama") })),
|
|
4865
|
+
vsCodeLmSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("vscode-lm") })),
|
|
4866
|
+
lmStudioSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("lmstudio") })),
|
|
4867
|
+
geminiSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("gemini") })),
|
|
4868
|
+
geminiCliSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("gemini-cli") })),
|
|
4869
|
+
openAiNativeSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("openai-native") })),
|
|
4870
|
+
mistralSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("mistral") })),
|
|
4871
|
+
deepSeekSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("deepseek") })),
|
|
4872
|
+
deepInfraSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("deepinfra") })),
|
|
4873
|
+
doubaoSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("doubao") })),
|
|
4874
|
+
moonshotSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("moonshot") })),
|
|
4875
|
+
minimaxSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("minimax") })),
|
|
4876
|
+
unboundSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("unbound") })),
|
|
4877
|
+
requestySchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("requesty") })),
|
|
4878
|
+
humanRelaySchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("human-relay") })),
|
|
4879
|
+
fakeAiSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("fake-ai") })),
|
|
4880
|
+
xaiSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("xai") })),
|
|
4881
|
+
groqSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("groq") })),
|
|
4882
|
+
huggingFaceSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("huggingface") })),
|
|
4883
|
+
chutesSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("chutes") })),
|
|
4884
|
+
litellmSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("litellm") })),
|
|
4885
|
+
cerebrasSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("cerebras") })),
|
|
4886
|
+
sambaNovaSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("sambanova") })),
|
|
4887
|
+
zaiSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("zai") })),
|
|
4888
|
+
fireworksSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("fireworks") })),
|
|
4889
|
+
featherlessSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("featherless") })),
|
|
4890
|
+
ioIntelligenceSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("io-intelligence") })),
|
|
4891
|
+
qwenCodeSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("qwen-code") })),
|
|
4892
|
+
rooSchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("roo") })),
|
|
4893
|
+
vercelAiGatewaySchema.merge(import_zod8.z.object({ apiProvider: import_zod8.z.literal("vercel-ai-gateway") })),
|
|
4618
4894
|
defaultSchema
|
|
4619
4895
|
]);
|
|
4620
|
-
var providerSettingsSchema =
|
|
4896
|
+
var providerSettingsSchema = import_zod8.z.object({
|
|
4621
4897
|
apiProvider: providerNamesSchema.optional(),
|
|
4622
4898
|
...anthropicSchema.shape,
|
|
4623
4899
|
...claudeCodeSchema.shape,
|
|
@@ -4637,6 +4913,7 @@ var providerSettingsSchema = import_zod7.z.object({
|
|
|
4637
4913
|
...deepInfraSchema.shape,
|
|
4638
4914
|
...doubaoSchema.shape,
|
|
4639
4915
|
...moonshotSchema.shape,
|
|
4916
|
+
...minimaxSchema.shape,
|
|
4640
4917
|
...unboundSchema.shape,
|
|
4641
4918
|
...requestySchema.shape,
|
|
4642
4919
|
...humanRelaySchema.shape,
|
|
@@ -4657,9 +4934,9 @@ var providerSettingsSchema = import_zod7.z.object({
|
|
|
4657
4934
|
...vercelAiGatewaySchema.shape,
|
|
4658
4935
|
...codebaseIndexProviderSchema.shape
|
|
4659
4936
|
});
|
|
4660
|
-
var providerSettingsWithIdSchema = providerSettingsSchema.extend({ id:
|
|
4937
|
+
var providerSettingsWithIdSchema = providerSettingsSchema.extend({ id: import_zod8.z.string().optional() });
|
|
4661
4938
|
var discriminatedProviderSettingsWithIdSchema = providerSettingsSchemaDiscriminated.and(
|
|
4662
|
-
|
|
4939
|
+
import_zod8.z.object({ id: import_zod8.z.string().optional() })
|
|
4663
4940
|
);
|
|
4664
4941
|
var PROVIDER_SETTINGS_KEYS = providerSettingsSchema.keyof().options;
|
|
4665
4942
|
var modelIdKeys = [
|
|
@@ -4697,6 +4974,7 @@ var modelIdKeysByProvider = {
|
|
|
4697
4974
|
"gemini-cli": "apiModelId",
|
|
4698
4975
|
mistral: "apiModelId",
|
|
4699
4976
|
moonshot: "apiModelId",
|
|
4977
|
+
minimax: "apiModelId",
|
|
4700
4978
|
deepseek: "apiModelId",
|
|
4701
4979
|
deepinfra: "deepInfraModelId",
|
|
4702
4980
|
doubao: "apiModelId",
|
|
@@ -4725,7 +5003,7 @@ var getApiProtocol = (provider, modelId) => {
|
|
|
4725
5003
|
if (provider && provider === "vertex" && modelId && modelId.toLowerCase().includes("claude")) {
|
|
4726
5004
|
return "anthropic";
|
|
4727
5005
|
}
|
|
4728
|
-
if (provider &&
|
|
5006
|
+
if (provider && ["vercel-ai-gateway", "roo"].includes(provider) && modelId && modelId.toLowerCase().startsWith("anthropic/")) {
|
|
4729
5007
|
return "anthropic";
|
|
4730
5008
|
}
|
|
4731
5009
|
return "openai";
|
|
@@ -4746,11 +5024,6 @@ var MODELS_BY_PROVIDER = {
|
|
|
4746
5024
|
label: "Cerebras",
|
|
4747
5025
|
models: Object.keys(cerebrasModels)
|
|
4748
5026
|
},
|
|
4749
|
-
chutes: {
|
|
4750
|
-
id: "chutes",
|
|
4751
|
-
label: "Chutes AI",
|
|
4752
|
-
models: Object.keys(chutesModels)
|
|
4753
|
-
},
|
|
4754
5027
|
"claude-code": { id: "claude-code", label: "Claude Code", models: Object.keys(claudeCodeModels) },
|
|
4755
5028
|
deepseek: {
|
|
4756
5029
|
id: "deepseek",
|
|
@@ -4789,13 +5062,18 @@ var MODELS_BY_PROVIDER = {
|
|
|
4789
5062
|
label: "Moonshot",
|
|
4790
5063
|
models: Object.keys(moonshotModels)
|
|
4791
5064
|
},
|
|
5065
|
+
minimax: {
|
|
5066
|
+
id: "minimax",
|
|
5067
|
+
label: "MiniMax",
|
|
5068
|
+
models: Object.keys(minimaxModels)
|
|
5069
|
+
},
|
|
4792
5070
|
"openai-native": {
|
|
4793
5071
|
id: "openai-native",
|
|
4794
5072
|
label: "OpenAI",
|
|
4795
5073
|
models: Object.keys(openAiNativeModels)
|
|
4796
5074
|
},
|
|
4797
5075
|
"qwen-code": { id: "qwen-code", label: "Qwen Code", models: Object.keys(qwenCodeModels) },
|
|
4798
|
-
roo: { id: "roo", label: "Roo", models:
|
|
5076
|
+
roo: { id: "roo", label: "Roo Code Cloud", models: [] },
|
|
4799
5077
|
sambanova: {
|
|
4800
5078
|
id: "sambanova",
|
|
4801
5079
|
label: "SambaNova",
|
|
@@ -4822,32 +5100,33 @@ var MODELS_BY_PROVIDER = {
|
|
|
4822
5100
|
unbound: { id: "unbound", label: "Unbound", models: [] },
|
|
4823
5101
|
deepinfra: { id: "deepinfra", label: "DeepInfra", models: [] },
|
|
4824
5102
|
"vercel-ai-gateway": { id: "vercel-ai-gateway", label: "Vercel AI Gateway", models: [] },
|
|
5103
|
+
chutes: { id: "chutes", label: "Chutes AI", models: [] },
|
|
4825
5104
|
// Local providers; models discovered from localhost endpoints.
|
|
4826
5105
|
lmstudio: { id: "lmstudio", label: "LM Studio", models: [] },
|
|
4827
5106
|
ollama: { id: "ollama", label: "Ollama", models: [] }
|
|
4828
5107
|
};
|
|
4829
5108
|
|
|
4830
5109
|
// src/history.ts
|
|
4831
|
-
var
|
|
4832
|
-
var historyItemSchema =
|
|
4833
|
-
id:
|
|
4834
|
-
rootTaskId:
|
|
4835
|
-
parentTaskId:
|
|
4836
|
-
number:
|
|
4837
|
-
ts:
|
|
4838
|
-
task:
|
|
4839
|
-
tokensIn:
|
|
4840
|
-
tokensOut:
|
|
4841
|
-
cacheWrites:
|
|
4842
|
-
cacheReads:
|
|
4843
|
-
totalCost:
|
|
4844
|
-
size:
|
|
4845
|
-
workspace:
|
|
4846
|
-
mode:
|
|
5110
|
+
var import_zod9 = require("zod");
|
|
5111
|
+
var historyItemSchema = import_zod9.z.object({
|
|
5112
|
+
id: import_zod9.z.string(),
|
|
5113
|
+
rootTaskId: import_zod9.z.string().optional(),
|
|
5114
|
+
parentTaskId: import_zod9.z.string().optional(),
|
|
5115
|
+
number: import_zod9.z.number(),
|
|
5116
|
+
ts: import_zod9.z.number(),
|
|
5117
|
+
task: import_zod9.z.string(),
|
|
5118
|
+
tokensIn: import_zod9.z.number(),
|
|
5119
|
+
tokensOut: import_zod9.z.number(),
|
|
5120
|
+
cacheWrites: import_zod9.z.number().optional(),
|
|
5121
|
+
cacheReads: import_zod9.z.number().optional(),
|
|
5122
|
+
totalCost: import_zod9.z.number(),
|
|
5123
|
+
size: import_zod9.z.number().optional(),
|
|
5124
|
+
workspace: import_zod9.z.string().optional(),
|
|
5125
|
+
mode: import_zod9.z.string().optional()
|
|
4847
5126
|
});
|
|
4848
5127
|
|
|
4849
5128
|
// src/experiment.ts
|
|
4850
|
-
var
|
|
5129
|
+
var import_zod10 = require("zod");
|
|
4851
5130
|
var experimentIds = [
|
|
4852
5131
|
"powerSteering",
|
|
4853
5132
|
"multiFileApplyDiff",
|
|
@@ -4855,19 +5134,19 @@ var experimentIds = [
|
|
|
4855
5134
|
"imageGeneration",
|
|
4856
5135
|
"runSlashCommand"
|
|
4857
5136
|
];
|
|
4858
|
-
var experimentIdsSchema =
|
|
4859
|
-
var experimentsSchema =
|
|
4860
|
-
powerSteering:
|
|
4861
|
-
multiFileApplyDiff:
|
|
4862
|
-
preventFocusDisruption:
|
|
4863
|
-
imageGeneration:
|
|
4864
|
-
runSlashCommand:
|
|
5137
|
+
var experimentIdsSchema = import_zod10.z.enum(experimentIds);
|
|
5138
|
+
var experimentsSchema = import_zod10.z.object({
|
|
5139
|
+
powerSteering: import_zod10.z.boolean().optional(),
|
|
5140
|
+
multiFileApplyDiff: import_zod10.z.boolean().optional(),
|
|
5141
|
+
preventFocusDisruption: import_zod10.z.boolean().optional(),
|
|
5142
|
+
imageGeneration: import_zod10.z.boolean().optional(),
|
|
5143
|
+
runSlashCommand: import_zod10.z.boolean().optional()
|
|
4865
5144
|
});
|
|
4866
5145
|
|
|
4867
5146
|
// src/telemetry.ts
|
|
4868
|
-
var
|
|
5147
|
+
var import_zod11 = require("zod");
|
|
4869
5148
|
var telemetrySettings = ["unset", "enabled", "disabled"];
|
|
4870
|
-
var telemetrySettingsSchema =
|
|
5149
|
+
var telemetrySettingsSchema = import_zod11.z.enum(telemetrySettings);
|
|
4871
5150
|
var TelemetryEventName = /* @__PURE__ */ ((TelemetryEventName2) => {
|
|
4872
5151
|
TelemetryEventName2["TASK_CREATED"] = "Task Created";
|
|
4873
5152
|
TelemetryEventName2["TASK_RESTARTED"] = "Task Reopened";
|
|
@@ -4913,53 +5192,53 @@ var TelemetryEventName = /* @__PURE__ */ ((TelemetryEventName2) => {
|
|
|
4913
5192
|
TelemetryEventName2["TELEMETRY_SETTINGS_CHANGED"] = "Telemetry Settings Changed";
|
|
4914
5193
|
return TelemetryEventName2;
|
|
4915
5194
|
})(TelemetryEventName || {});
|
|
4916
|
-
var staticAppPropertiesSchema =
|
|
4917
|
-
appName:
|
|
4918
|
-
appVersion:
|
|
4919
|
-
vscodeVersion:
|
|
4920
|
-
platform:
|
|
4921
|
-
editorName:
|
|
4922
|
-
hostname:
|
|
5195
|
+
var staticAppPropertiesSchema = import_zod11.z.object({
|
|
5196
|
+
appName: import_zod11.z.string(),
|
|
5197
|
+
appVersion: import_zod11.z.string(),
|
|
5198
|
+
vscodeVersion: import_zod11.z.string(),
|
|
5199
|
+
platform: import_zod11.z.string(),
|
|
5200
|
+
editorName: import_zod11.z.string(),
|
|
5201
|
+
hostname: import_zod11.z.string().optional()
|
|
4923
5202
|
});
|
|
4924
|
-
var dynamicAppPropertiesSchema =
|
|
4925
|
-
language:
|
|
4926
|
-
mode:
|
|
5203
|
+
var dynamicAppPropertiesSchema = import_zod11.z.object({
|
|
5204
|
+
language: import_zod11.z.string(),
|
|
5205
|
+
mode: import_zod11.z.string()
|
|
4927
5206
|
});
|
|
4928
|
-
var cloudAppPropertiesSchema =
|
|
4929
|
-
cloudIsAuthenticated:
|
|
5207
|
+
var cloudAppPropertiesSchema = import_zod11.z.object({
|
|
5208
|
+
cloudIsAuthenticated: import_zod11.z.boolean().optional()
|
|
4930
5209
|
});
|
|
4931
|
-
var appPropertiesSchema =
|
|
5210
|
+
var appPropertiesSchema = import_zod11.z.object({
|
|
4932
5211
|
...staticAppPropertiesSchema.shape,
|
|
4933
5212
|
...dynamicAppPropertiesSchema.shape,
|
|
4934
5213
|
...cloudAppPropertiesSchema.shape
|
|
4935
5214
|
});
|
|
4936
|
-
var taskPropertiesSchema =
|
|
4937
|
-
taskId:
|
|
4938
|
-
parentTaskId:
|
|
4939
|
-
apiProvider:
|
|
4940
|
-
modelId:
|
|
4941
|
-
diffStrategy:
|
|
4942
|
-
isSubtask:
|
|
4943
|
-
todos:
|
|
4944
|
-
total:
|
|
4945
|
-
completed:
|
|
4946
|
-
inProgress:
|
|
4947
|
-
pending:
|
|
5215
|
+
var taskPropertiesSchema = import_zod11.z.object({
|
|
5216
|
+
taskId: import_zod11.z.string().optional(),
|
|
5217
|
+
parentTaskId: import_zod11.z.string().optional(),
|
|
5218
|
+
apiProvider: import_zod11.z.enum(providerNames).optional(),
|
|
5219
|
+
modelId: import_zod11.z.string().optional(),
|
|
5220
|
+
diffStrategy: import_zod11.z.string().optional(),
|
|
5221
|
+
isSubtask: import_zod11.z.boolean().optional(),
|
|
5222
|
+
todos: import_zod11.z.object({
|
|
5223
|
+
total: import_zod11.z.number(),
|
|
5224
|
+
completed: import_zod11.z.number(),
|
|
5225
|
+
inProgress: import_zod11.z.number(),
|
|
5226
|
+
pending: import_zod11.z.number()
|
|
4948
5227
|
}).optional()
|
|
4949
5228
|
});
|
|
4950
|
-
var gitPropertiesSchema =
|
|
4951
|
-
repositoryUrl:
|
|
4952
|
-
repositoryName:
|
|
4953
|
-
defaultBranch:
|
|
5229
|
+
var gitPropertiesSchema = import_zod11.z.object({
|
|
5230
|
+
repositoryUrl: import_zod11.z.string().optional(),
|
|
5231
|
+
repositoryName: import_zod11.z.string().optional(),
|
|
5232
|
+
defaultBranch: import_zod11.z.string().optional()
|
|
4954
5233
|
});
|
|
4955
|
-
var telemetryPropertiesSchema =
|
|
5234
|
+
var telemetryPropertiesSchema = import_zod11.z.object({
|
|
4956
5235
|
...appPropertiesSchema.shape,
|
|
4957
5236
|
...taskPropertiesSchema.shape,
|
|
4958
5237
|
...gitPropertiesSchema.shape
|
|
4959
5238
|
});
|
|
4960
|
-
var rooCodeTelemetryEventSchema =
|
|
4961
|
-
|
|
4962
|
-
type:
|
|
5239
|
+
var rooCodeTelemetryEventSchema = import_zod11.z.discriminatedUnion("type", [
|
|
5240
|
+
import_zod11.z.object({
|
|
5241
|
+
type: import_zod11.z.enum([
|
|
4963
5242
|
"Task Created" /* TASK_CREATED */,
|
|
4964
5243
|
"Task Reopened" /* TASK_RESTARTED */,
|
|
4965
5244
|
"Task Completed" /* TASK_COMPLETED */,
|
|
@@ -5002,39 +5281,39 @@ var rooCodeTelemetryEventSchema = import_zod10.z.discriminatedUnion("type", [
|
|
|
5002
5281
|
]),
|
|
5003
5282
|
properties: telemetryPropertiesSchema
|
|
5004
5283
|
}),
|
|
5005
|
-
|
|
5006
|
-
type:
|
|
5007
|
-
properties:
|
|
5284
|
+
import_zod11.z.object({
|
|
5285
|
+
type: import_zod11.z.literal("Telemetry Settings Changed" /* TELEMETRY_SETTINGS_CHANGED */),
|
|
5286
|
+
properties: import_zod11.z.object({
|
|
5008
5287
|
...telemetryPropertiesSchema.shape,
|
|
5009
5288
|
previousSetting: telemetrySettingsSchema,
|
|
5010
5289
|
newSetting: telemetrySettingsSchema
|
|
5011
5290
|
})
|
|
5012
5291
|
}),
|
|
5013
|
-
|
|
5014
|
-
type:
|
|
5015
|
-
properties:
|
|
5292
|
+
import_zod11.z.object({
|
|
5293
|
+
type: import_zod11.z.literal("Task Message" /* TASK_MESSAGE */),
|
|
5294
|
+
properties: import_zod11.z.object({
|
|
5016
5295
|
...telemetryPropertiesSchema.shape,
|
|
5017
|
-
taskId:
|
|
5296
|
+
taskId: import_zod11.z.string(),
|
|
5018
5297
|
message: clineMessageSchema
|
|
5019
5298
|
})
|
|
5020
5299
|
}),
|
|
5021
|
-
|
|
5022
|
-
type:
|
|
5023
|
-
properties:
|
|
5300
|
+
import_zod11.z.object({
|
|
5301
|
+
type: import_zod11.z.literal("LLM Completion" /* LLM_COMPLETION */),
|
|
5302
|
+
properties: import_zod11.z.object({
|
|
5024
5303
|
...telemetryPropertiesSchema.shape,
|
|
5025
|
-
inputTokens:
|
|
5026
|
-
outputTokens:
|
|
5027
|
-
cacheReadTokens:
|
|
5028
|
-
cacheWriteTokens:
|
|
5029
|
-
cost:
|
|
5304
|
+
inputTokens: import_zod11.z.number(),
|
|
5305
|
+
outputTokens: import_zod11.z.number(),
|
|
5306
|
+
cacheReadTokens: import_zod11.z.number().optional(),
|
|
5307
|
+
cacheWriteTokens: import_zod11.z.number().optional(),
|
|
5308
|
+
cost: import_zod11.z.number().optional()
|
|
5030
5309
|
})
|
|
5031
5310
|
})
|
|
5032
5311
|
]);
|
|
5033
5312
|
|
|
5034
5313
|
// src/mode.ts
|
|
5035
|
-
var
|
|
5036
|
-
var groupOptionsSchema =
|
|
5037
|
-
fileRegex:
|
|
5314
|
+
var import_zod12 = require("zod");
|
|
5315
|
+
var groupOptionsSchema = import_zod12.z.object({
|
|
5316
|
+
fileRegex: import_zod12.z.string().optional().refine(
|
|
5038
5317
|
(pattern) => {
|
|
5039
5318
|
if (!pattern) {
|
|
5040
5319
|
return true;
|
|
@@ -5048,10 +5327,10 @@ var groupOptionsSchema = import_zod11.z.object({
|
|
|
5048
5327
|
},
|
|
5049
5328
|
{ message: "Invalid regular expression pattern" }
|
|
5050
5329
|
),
|
|
5051
|
-
description:
|
|
5330
|
+
description: import_zod12.z.string().optional()
|
|
5052
5331
|
});
|
|
5053
|
-
var groupEntrySchema =
|
|
5054
|
-
var groupEntryArraySchema =
|
|
5332
|
+
var groupEntrySchema = import_zod12.z.union([toolGroupsSchema, import_zod12.z.tuple([toolGroupsSchema, groupOptionsSchema])]);
|
|
5333
|
+
var groupEntryArraySchema = import_zod12.z.array(groupEntrySchema).refine(
|
|
5055
5334
|
(groups) => {
|
|
5056
5335
|
const seen = /* @__PURE__ */ new Set();
|
|
5057
5336
|
return groups.every((group) => {
|
|
@@ -5065,18 +5344,18 @@ var groupEntryArraySchema = import_zod11.z.array(groupEntrySchema).refine(
|
|
|
5065
5344
|
},
|
|
5066
5345
|
{ message: "Duplicate groups are not allowed" }
|
|
5067
5346
|
);
|
|
5068
|
-
var modeConfigSchema =
|
|
5069
|
-
slug:
|
|
5070
|
-
name:
|
|
5071
|
-
roleDefinition:
|
|
5072
|
-
whenToUse:
|
|
5073
|
-
description:
|
|
5074
|
-
customInstructions:
|
|
5347
|
+
var modeConfigSchema = import_zod12.z.object({
|
|
5348
|
+
slug: import_zod12.z.string().regex(/^[a-zA-Z0-9-]+$/, "Slug must contain only letters numbers and dashes"),
|
|
5349
|
+
name: import_zod12.z.string().min(1, "Name is required"),
|
|
5350
|
+
roleDefinition: import_zod12.z.string().min(1, "Role definition is required"),
|
|
5351
|
+
whenToUse: import_zod12.z.string().optional(),
|
|
5352
|
+
description: import_zod12.z.string().optional(),
|
|
5353
|
+
customInstructions: import_zod12.z.string().optional(),
|
|
5075
5354
|
groups: groupEntryArraySchema,
|
|
5076
|
-
source:
|
|
5355
|
+
source: import_zod12.z.enum(["global", "project"]).optional()
|
|
5077
5356
|
});
|
|
5078
|
-
var customModesSettingsSchema =
|
|
5079
|
-
customModes:
|
|
5357
|
+
var customModesSettingsSchema = import_zod12.z.object({
|
|
5358
|
+
customModes: import_zod12.z.array(modeConfigSchema).refine(
|
|
5080
5359
|
(modes) => {
|
|
5081
5360
|
const slugs = /* @__PURE__ */ new Set();
|
|
5082
5361
|
return modes.every((mode) => {
|
|
@@ -5092,14 +5371,14 @@ var customModesSettingsSchema = import_zod11.z.object({
|
|
|
5092
5371
|
}
|
|
5093
5372
|
)
|
|
5094
5373
|
});
|
|
5095
|
-
var promptComponentSchema =
|
|
5096
|
-
roleDefinition:
|
|
5097
|
-
whenToUse:
|
|
5098
|
-
description:
|
|
5099
|
-
customInstructions:
|
|
5374
|
+
var promptComponentSchema = import_zod12.z.object({
|
|
5375
|
+
roleDefinition: import_zod12.z.string().optional(),
|
|
5376
|
+
whenToUse: import_zod12.z.string().optional(),
|
|
5377
|
+
description: import_zod12.z.string().optional(),
|
|
5378
|
+
customInstructions: import_zod12.z.string().optional()
|
|
5100
5379
|
});
|
|
5101
|
-
var customModePromptsSchema =
|
|
5102
|
-
var customSupportPromptsSchema =
|
|
5380
|
+
var customModePromptsSchema = import_zod12.z.record(import_zod12.z.string(), promptComponentSchema.optional());
|
|
5381
|
+
var customSupportPromptsSchema = import_zod12.z.record(import_zod12.z.string(), import_zod12.z.string().optional());
|
|
5103
5382
|
var DEFAULT_MODES = [
|
|
5104
5383
|
{
|
|
5105
5384
|
slug: "architect",
|
|
@@ -5148,7 +5427,7 @@ var DEFAULT_MODES = [
|
|
|
5148
5427
|
];
|
|
5149
5428
|
|
|
5150
5429
|
// src/vscode.ts
|
|
5151
|
-
var
|
|
5430
|
+
var import_zod13 = require("zod");
|
|
5152
5431
|
var codeActionIds = ["explainCode", "fixCode", "improveCode", "addToContext", "newTask"];
|
|
5153
5432
|
var terminalActionIds = ["terminalAddToContext", "terminalFixCommand", "terminalExplainCommand"];
|
|
5154
5433
|
var commandIds = [
|
|
@@ -5194,114 +5473,128 @@ var languages = [
|
|
|
5194
5473
|
"zh-CN",
|
|
5195
5474
|
"zh-TW"
|
|
5196
5475
|
];
|
|
5197
|
-
var languagesSchema =
|
|
5476
|
+
var languagesSchema = import_zod13.z.enum(languages);
|
|
5198
5477
|
var isLanguage = (value) => languages.includes(value);
|
|
5199
5478
|
|
|
5200
5479
|
// src/global-settings.ts
|
|
5201
5480
|
var DEFAULT_WRITE_DELAY_MS = 1e3;
|
|
5202
5481
|
var DEFAULT_TERMINAL_OUTPUT_CHARACTER_LIMIT = 5e4;
|
|
5203
|
-
var
|
|
5204
|
-
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5482
|
+
var MIN_CHECKPOINT_TIMEOUT_SECONDS = 10;
|
|
5483
|
+
var MAX_CHECKPOINT_TIMEOUT_SECONDS = 60;
|
|
5484
|
+
var DEFAULT_CHECKPOINT_TIMEOUT_SECONDS = 15;
|
|
5485
|
+
var globalSettingsSchema = import_zod14.z.object({
|
|
5486
|
+
currentApiConfigName: import_zod14.z.string().optional(),
|
|
5487
|
+
listApiConfigMeta: import_zod14.z.array(providerSettingsEntrySchema).optional(),
|
|
5488
|
+
pinnedApiConfigs: import_zod14.z.record(import_zod14.z.string(), import_zod14.z.boolean()).optional(),
|
|
5489
|
+
lastShownAnnouncementId: import_zod14.z.string().optional(),
|
|
5490
|
+
customInstructions: import_zod14.z.string().optional(),
|
|
5491
|
+
taskHistory: import_zod14.z.array(historyItemSchema).optional(),
|
|
5492
|
+
dismissedUpsells: import_zod14.z.array(import_zod14.z.string()).optional(),
|
|
5211
5493
|
// Image generation settings (experimental) - flattened for simplicity
|
|
5212
|
-
openRouterImageApiKey:
|
|
5213
|
-
openRouterImageGenerationSelectedModel:
|
|
5214
|
-
condensingApiConfigId:
|
|
5215
|
-
customCondensingPrompt:
|
|
5216
|
-
autoApprovalEnabled:
|
|
5217
|
-
alwaysAllowReadOnly:
|
|
5218
|
-
alwaysAllowReadOnlyOutsideWorkspace:
|
|
5219
|
-
alwaysAllowWrite:
|
|
5220
|
-
alwaysAllowWriteOutsideWorkspace:
|
|
5221
|
-
alwaysAllowWriteProtected:
|
|
5222
|
-
writeDelayMs:
|
|
5223
|
-
alwaysAllowBrowser:
|
|
5224
|
-
alwaysApproveResubmit:
|
|
5225
|
-
requestDelaySeconds:
|
|
5226
|
-
alwaysAllowMcp:
|
|
5227
|
-
alwaysAllowModeSwitch:
|
|
5228
|
-
alwaysAllowSubtasks:
|
|
5229
|
-
alwaysAllowExecute:
|
|
5230
|
-
alwaysAllowFollowupQuestions:
|
|
5231
|
-
followupAutoApproveTimeoutMs:
|
|
5232
|
-
alwaysAllowUpdateTodoList:
|
|
5233
|
-
allowedCommands:
|
|
5234
|
-
deniedCommands:
|
|
5235
|
-
commandExecutionTimeout:
|
|
5236
|
-
commandTimeoutAllowlist:
|
|
5237
|
-
preventCompletionWithOpenTodos:
|
|
5238
|
-
allowedMaxRequests:
|
|
5239
|
-
allowedMaxCost:
|
|
5240
|
-
autoCondenseContext:
|
|
5241
|
-
autoCondenseContextPercent:
|
|
5242
|
-
maxConcurrentFileReads:
|
|
5494
|
+
openRouterImageApiKey: import_zod14.z.string().optional(),
|
|
5495
|
+
openRouterImageGenerationSelectedModel: import_zod14.z.string().optional(),
|
|
5496
|
+
condensingApiConfigId: import_zod14.z.string().optional(),
|
|
5497
|
+
customCondensingPrompt: import_zod14.z.string().optional(),
|
|
5498
|
+
autoApprovalEnabled: import_zod14.z.boolean().optional(),
|
|
5499
|
+
alwaysAllowReadOnly: import_zod14.z.boolean().optional(),
|
|
5500
|
+
alwaysAllowReadOnlyOutsideWorkspace: import_zod14.z.boolean().optional(),
|
|
5501
|
+
alwaysAllowWrite: import_zod14.z.boolean().optional(),
|
|
5502
|
+
alwaysAllowWriteOutsideWorkspace: import_zod14.z.boolean().optional(),
|
|
5503
|
+
alwaysAllowWriteProtected: import_zod14.z.boolean().optional(),
|
|
5504
|
+
writeDelayMs: import_zod14.z.number().min(0).optional(),
|
|
5505
|
+
alwaysAllowBrowser: import_zod14.z.boolean().optional(),
|
|
5506
|
+
alwaysApproveResubmit: import_zod14.z.boolean().optional(),
|
|
5507
|
+
requestDelaySeconds: import_zod14.z.number().optional(),
|
|
5508
|
+
alwaysAllowMcp: import_zod14.z.boolean().optional(),
|
|
5509
|
+
alwaysAllowModeSwitch: import_zod14.z.boolean().optional(),
|
|
5510
|
+
alwaysAllowSubtasks: import_zod14.z.boolean().optional(),
|
|
5511
|
+
alwaysAllowExecute: import_zod14.z.boolean().optional(),
|
|
5512
|
+
alwaysAllowFollowupQuestions: import_zod14.z.boolean().optional(),
|
|
5513
|
+
followupAutoApproveTimeoutMs: import_zod14.z.number().optional(),
|
|
5514
|
+
alwaysAllowUpdateTodoList: import_zod14.z.boolean().optional(),
|
|
5515
|
+
allowedCommands: import_zod14.z.array(import_zod14.z.string()).optional(),
|
|
5516
|
+
deniedCommands: import_zod14.z.array(import_zod14.z.string()).optional(),
|
|
5517
|
+
commandExecutionTimeout: import_zod14.z.number().optional(),
|
|
5518
|
+
commandTimeoutAllowlist: import_zod14.z.array(import_zod14.z.string()).optional(),
|
|
5519
|
+
preventCompletionWithOpenTodos: import_zod14.z.boolean().optional(),
|
|
5520
|
+
allowedMaxRequests: import_zod14.z.number().nullish(),
|
|
5521
|
+
allowedMaxCost: import_zod14.z.number().nullish(),
|
|
5522
|
+
autoCondenseContext: import_zod14.z.boolean().optional(),
|
|
5523
|
+
autoCondenseContextPercent: import_zod14.z.number().optional(),
|
|
5524
|
+
maxConcurrentFileReads: import_zod14.z.number().optional(),
|
|
5525
|
+
/**
|
|
5526
|
+
* Whether to include current time in the environment details
|
|
5527
|
+
* @default true
|
|
5528
|
+
*/
|
|
5529
|
+
includeCurrentTime: import_zod14.z.boolean().optional(),
|
|
5530
|
+
/**
|
|
5531
|
+
* Whether to include current cost in the environment details
|
|
5532
|
+
* @default true
|
|
5533
|
+
*/
|
|
5534
|
+
includeCurrentCost: import_zod14.z.boolean().optional(),
|
|
5243
5535
|
/**
|
|
5244
5536
|
* Whether to include diagnostic messages (errors, warnings) in tool outputs
|
|
5245
5537
|
* @default true
|
|
5246
5538
|
*/
|
|
5247
|
-
includeDiagnosticMessages:
|
|
5539
|
+
includeDiagnosticMessages: import_zod14.z.boolean().optional(),
|
|
5248
5540
|
/**
|
|
5249
5541
|
* Maximum number of diagnostic messages to include in tool outputs
|
|
5250
5542
|
* @default 50
|
|
5251
5543
|
*/
|
|
5252
|
-
maxDiagnosticMessages:
|
|
5253
|
-
browserToolEnabled:
|
|
5254
|
-
browserViewportSize:
|
|
5255
|
-
screenshotQuality:
|
|
5256
|
-
remoteBrowserEnabled:
|
|
5257
|
-
remoteBrowserHost:
|
|
5258
|
-
cachedChromeHostUrl:
|
|
5259
|
-
enableCheckpoints:
|
|
5260
|
-
|
|
5261
|
-
|
|
5262
|
-
|
|
5263
|
-
|
|
5264
|
-
|
|
5265
|
-
|
|
5266
|
-
|
|
5267
|
-
|
|
5268
|
-
|
|
5269
|
-
|
|
5270
|
-
|
|
5271
|
-
|
|
5272
|
-
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5276
|
-
|
|
5277
|
-
|
|
5278
|
-
|
|
5279
|
-
|
|
5280
|
-
|
|
5281
|
-
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
|
|
5544
|
+
maxDiagnosticMessages: import_zod14.z.number().optional(),
|
|
5545
|
+
browserToolEnabled: import_zod14.z.boolean().optional(),
|
|
5546
|
+
browserViewportSize: import_zod14.z.string().optional(),
|
|
5547
|
+
screenshotQuality: import_zod14.z.number().optional(),
|
|
5548
|
+
remoteBrowserEnabled: import_zod14.z.boolean().optional(),
|
|
5549
|
+
remoteBrowserHost: import_zod14.z.string().optional(),
|
|
5550
|
+
cachedChromeHostUrl: import_zod14.z.string().optional(),
|
|
5551
|
+
enableCheckpoints: import_zod14.z.boolean().optional(),
|
|
5552
|
+
checkpointTimeout: import_zod14.z.number().int().min(MIN_CHECKPOINT_TIMEOUT_SECONDS).max(MAX_CHECKPOINT_TIMEOUT_SECONDS).optional(),
|
|
5553
|
+
ttsEnabled: import_zod14.z.boolean().optional(),
|
|
5554
|
+
ttsSpeed: import_zod14.z.number().optional(),
|
|
5555
|
+
soundEnabled: import_zod14.z.boolean().optional(),
|
|
5556
|
+
soundVolume: import_zod14.z.number().optional(),
|
|
5557
|
+
maxOpenTabsContext: import_zod14.z.number().optional(),
|
|
5558
|
+
maxWorkspaceFiles: import_zod14.z.number().optional(),
|
|
5559
|
+
showRooIgnoredFiles: import_zod14.z.boolean().optional(),
|
|
5560
|
+
maxReadFileLine: import_zod14.z.number().optional(),
|
|
5561
|
+
maxImageFileSize: import_zod14.z.number().optional(),
|
|
5562
|
+
maxTotalImageSize: import_zod14.z.number().optional(),
|
|
5563
|
+
terminalOutputLineLimit: import_zod14.z.number().optional(),
|
|
5564
|
+
terminalOutputCharacterLimit: import_zod14.z.number().optional(),
|
|
5565
|
+
terminalShellIntegrationTimeout: import_zod14.z.number().optional(),
|
|
5566
|
+
terminalShellIntegrationDisabled: import_zod14.z.boolean().optional(),
|
|
5567
|
+
terminalCommandDelay: import_zod14.z.number().optional(),
|
|
5568
|
+
terminalPowershellCounter: import_zod14.z.boolean().optional(),
|
|
5569
|
+
terminalZshClearEolMark: import_zod14.z.boolean().optional(),
|
|
5570
|
+
terminalZshOhMy: import_zod14.z.boolean().optional(),
|
|
5571
|
+
terminalZshP10k: import_zod14.z.boolean().optional(),
|
|
5572
|
+
terminalZdotdir: import_zod14.z.boolean().optional(),
|
|
5573
|
+
terminalCompressProgressBar: import_zod14.z.boolean().optional(),
|
|
5574
|
+
diagnosticsEnabled: import_zod14.z.boolean().optional(),
|
|
5575
|
+
rateLimitSeconds: import_zod14.z.number().optional(),
|
|
5576
|
+
diffEnabled: import_zod14.z.boolean().optional(),
|
|
5577
|
+
fuzzyMatchThreshold: import_zod14.z.number().optional(),
|
|
5285
5578
|
experiments: experimentsSchema.optional(),
|
|
5286
5579
|
codebaseIndexModels: codebaseIndexModelsSchema.optional(),
|
|
5287
5580
|
codebaseIndexConfig: codebaseIndexConfigSchema.optional(),
|
|
5288
5581
|
language: languagesSchema.optional(),
|
|
5289
5582
|
telemetrySetting: telemetrySettingsSchema.optional(),
|
|
5290
|
-
mcpEnabled:
|
|
5291
|
-
enableMcpServerCreation:
|
|
5292
|
-
mode:
|
|
5293
|
-
modeApiConfigs:
|
|
5294
|
-
customModes:
|
|
5583
|
+
mcpEnabled: import_zod14.z.boolean().optional(),
|
|
5584
|
+
enableMcpServerCreation: import_zod14.z.boolean().optional(),
|
|
5585
|
+
mode: import_zod14.z.string().optional(),
|
|
5586
|
+
modeApiConfigs: import_zod14.z.record(import_zod14.z.string(), import_zod14.z.string()).optional(),
|
|
5587
|
+
customModes: import_zod14.z.array(modeConfigSchema).optional(),
|
|
5295
5588
|
customModePrompts: customModePromptsSchema.optional(),
|
|
5296
5589
|
customSupportPrompts: customSupportPromptsSchema.optional(),
|
|
5297
|
-
enhancementApiConfigId:
|
|
5298
|
-
includeTaskHistoryInEnhance:
|
|
5299
|
-
historyPreviewCollapsed:
|
|
5300
|
-
reasoningBlockCollapsed:
|
|
5301
|
-
profileThresholds:
|
|
5302
|
-
hasOpenedModeSelector:
|
|
5303
|
-
lastModeExportPath:
|
|
5304
|
-
lastModeImportPath:
|
|
5590
|
+
enhancementApiConfigId: import_zod14.z.string().optional(),
|
|
5591
|
+
includeTaskHistoryInEnhance: import_zod14.z.boolean().optional(),
|
|
5592
|
+
historyPreviewCollapsed: import_zod14.z.boolean().optional(),
|
|
5593
|
+
reasoningBlockCollapsed: import_zod14.z.boolean().optional(),
|
|
5594
|
+
profileThresholds: import_zod14.z.record(import_zod14.z.string(), import_zod14.z.number()).optional(),
|
|
5595
|
+
hasOpenedModeSelector: import_zod14.z.boolean().optional(),
|
|
5596
|
+
lastModeExportPath: import_zod14.z.string().optional(),
|
|
5597
|
+
lastModeImportPath: import_zod14.z.string().optional()
|
|
5305
5598
|
});
|
|
5306
5599
|
var GLOBAL_SETTINGS_KEYS = globalSettingsSchema.keyof().options;
|
|
5307
5600
|
var rooCodeSettingsSchema = providerSettingsSchema.merge(globalSettingsSchema);
|
|
@@ -5322,6 +5615,7 @@ var SECRET_STATE_KEYS = [
|
|
|
5322
5615
|
"doubaoApiKey",
|
|
5323
5616
|
"moonshotApiKey",
|
|
5324
5617
|
"mistralApiKey",
|
|
5618
|
+
"minimaxApiKey",
|
|
5325
5619
|
"unboundApiKey",
|
|
5326
5620
|
"requestyApiKey",
|
|
5327
5621
|
"xaiApiKey",
|
|
@@ -5335,6 +5629,7 @@ var SECRET_STATE_KEYS = [
|
|
|
5335
5629
|
"codebaseIndexGeminiApiKey",
|
|
5336
5630
|
"codebaseIndexMistralApiKey",
|
|
5337
5631
|
"codebaseIndexVercelAiGatewayApiKey",
|
|
5632
|
+
"codebaseIndexOpenRouterApiKey",
|
|
5338
5633
|
"huggingFaceApiKey",
|
|
5339
5634
|
"sambaNovaApiKey",
|
|
5340
5635
|
"zaiApiKey",
|
|
@@ -5419,62 +5714,62 @@ var EVALS_SETTINGS = {
|
|
|
5419
5714
|
var EVALS_TIMEOUT = 5 * 60 * 1e3;
|
|
5420
5715
|
|
|
5421
5716
|
// src/marketplace.ts
|
|
5422
|
-
var
|
|
5423
|
-
var mcpParameterSchema =
|
|
5424
|
-
name:
|
|
5425
|
-
key:
|
|
5426
|
-
placeholder:
|
|
5427
|
-
optional:
|
|
5717
|
+
var import_zod15 = require("zod");
|
|
5718
|
+
var mcpParameterSchema = import_zod15.z.object({
|
|
5719
|
+
name: import_zod15.z.string().min(1),
|
|
5720
|
+
key: import_zod15.z.string().min(1),
|
|
5721
|
+
placeholder: import_zod15.z.string().optional(),
|
|
5722
|
+
optional: import_zod15.z.boolean().optional().default(false)
|
|
5428
5723
|
});
|
|
5429
|
-
var mcpInstallationMethodSchema =
|
|
5430
|
-
name:
|
|
5431
|
-
content:
|
|
5432
|
-
parameters:
|
|
5433
|
-
prerequisites:
|
|
5724
|
+
var mcpInstallationMethodSchema = import_zod15.z.object({
|
|
5725
|
+
name: import_zod15.z.string().min(1),
|
|
5726
|
+
content: import_zod15.z.string().min(1),
|
|
5727
|
+
parameters: import_zod15.z.array(mcpParameterSchema).optional(),
|
|
5728
|
+
prerequisites: import_zod15.z.array(import_zod15.z.string()).optional()
|
|
5434
5729
|
});
|
|
5435
|
-
var marketplaceItemTypeSchema =
|
|
5436
|
-
var baseMarketplaceItemSchema =
|
|
5437
|
-
id:
|
|
5438
|
-
name:
|
|
5439
|
-
description:
|
|
5440
|
-
author:
|
|
5441
|
-
authorUrl:
|
|
5442
|
-
tags:
|
|
5443
|
-
prerequisites:
|
|
5730
|
+
var marketplaceItemTypeSchema = import_zod15.z.enum(["mode", "mcp"]);
|
|
5731
|
+
var baseMarketplaceItemSchema = import_zod15.z.object({
|
|
5732
|
+
id: import_zod15.z.string().min(1),
|
|
5733
|
+
name: import_zod15.z.string().min(1, "Name is required"),
|
|
5734
|
+
description: import_zod15.z.string(),
|
|
5735
|
+
author: import_zod15.z.string().optional(),
|
|
5736
|
+
authorUrl: import_zod15.z.string().url("Author URL must be a valid URL").optional(),
|
|
5737
|
+
tags: import_zod15.z.array(import_zod15.z.string()).optional(),
|
|
5738
|
+
prerequisites: import_zod15.z.array(import_zod15.z.string()).optional()
|
|
5444
5739
|
});
|
|
5445
5740
|
var modeMarketplaceItemSchema = baseMarketplaceItemSchema.extend({
|
|
5446
|
-
content:
|
|
5741
|
+
content: import_zod15.z.string().min(1)
|
|
5447
5742
|
// YAML content for modes
|
|
5448
5743
|
});
|
|
5449
5744
|
var mcpMarketplaceItemSchema = baseMarketplaceItemSchema.extend({
|
|
5450
|
-
url:
|
|
5745
|
+
url: import_zod15.z.string().url(),
|
|
5451
5746
|
// Required url field
|
|
5452
|
-
content:
|
|
5747
|
+
content: import_zod15.z.union([import_zod15.z.string().min(1), import_zod15.z.array(mcpInstallationMethodSchema)]),
|
|
5453
5748
|
// Single config or array of methods
|
|
5454
|
-
parameters:
|
|
5749
|
+
parameters: import_zod15.z.array(mcpParameterSchema).optional()
|
|
5455
5750
|
});
|
|
5456
|
-
var marketplaceItemSchema =
|
|
5751
|
+
var marketplaceItemSchema = import_zod15.z.discriminatedUnion("type", [
|
|
5457
5752
|
// Mode marketplace item
|
|
5458
5753
|
modeMarketplaceItemSchema.extend({
|
|
5459
|
-
type:
|
|
5754
|
+
type: import_zod15.z.literal("mode")
|
|
5460
5755
|
}),
|
|
5461
5756
|
// MCP marketplace item
|
|
5462
5757
|
mcpMarketplaceItemSchema.extend({
|
|
5463
|
-
type:
|
|
5758
|
+
type: import_zod15.z.literal("mcp")
|
|
5464
5759
|
})
|
|
5465
5760
|
]);
|
|
5466
|
-
var installMarketplaceItemOptionsSchema =
|
|
5467
|
-
target:
|
|
5468
|
-
parameters:
|
|
5761
|
+
var installMarketplaceItemOptionsSchema = import_zod15.z.object({
|
|
5762
|
+
target: import_zod15.z.enum(["global", "project"]).optional().default("project"),
|
|
5763
|
+
parameters: import_zod15.z.record(import_zod15.z.string(), import_zod15.z.any()).optional()
|
|
5469
5764
|
});
|
|
5470
5765
|
|
|
5471
5766
|
// src/cloud.ts
|
|
5472
|
-
var organizationAllowListSchema =
|
|
5473
|
-
allowAll:
|
|
5474
|
-
providers:
|
|
5475
|
-
|
|
5476
|
-
allowAll:
|
|
5477
|
-
models:
|
|
5767
|
+
var organizationAllowListSchema = import_zod16.z.object({
|
|
5768
|
+
allowAll: import_zod16.z.boolean(),
|
|
5769
|
+
providers: import_zod16.z.record(
|
|
5770
|
+
import_zod16.z.object({
|
|
5771
|
+
allowAll: import_zod16.z.boolean(),
|
|
5772
|
+
models: import_zod16.z.array(import_zod16.z.string()).optional()
|
|
5478
5773
|
})
|
|
5479
5774
|
)
|
|
5480
5775
|
});
|
|
@@ -5492,46 +5787,46 @@ var organizationDefaultSettingsSchema = globalSettingsSchema.pick({
|
|
|
5492
5787
|
terminalShellIntegrationTimeout: true,
|
|
5493
5788
|
terminalZshClearEolMark: true
|
|
5494
5789
|
}).merge(
|
|
5495
|
-
|
|
5496
|
-
maxOpenTabsContext:
|
|
5497
|
-
maxReadFileLine:
|
|
5498
|
-
maxWorkspaceFiles:
|
|
5499
|
-
terminalCommandDelay:
|
|
5500
|
-
terminalOutputLineLimit:
|
|
5501
|
-
terminalShellIntegrationTimeout:
|
|
5790
|
+
import_zod16.z.object({
|
|
5791
|
+
maxOpenTabsContext: import_zod16.z.number().int().nonnegative().optional(),
|
|
5792
|
+
maxReadFileLine: import_zod16.z.number().int().gte(-1).optional(),
|
|
5793
|
+
maxWorkspaceFiles: import_zod16.z.number().int().nonnegative().optional(),
|
|
5794
|
+
terminalCommandDelay: import_zod16.z.number().int().nonnegative().optional(),
|
|
5795
|
+
terminalOutputLineLimit: import_zod16.z.number().int().nonnegative().optional(),
|
|
5796
|
+
terminalShellIntegrationTimeout: import_zod16.z.number().int().nonnegative().optional()
|
|
5502
5797
|
})
|
|
5503
5798
|
);
|
|
5504
|
-
var organizationCloudSettingsSchema =
|
|
5505
|
-
recordTaskMessages:
|
|
5506
|
-
enableTaskSharing:
|
|
5507
|
-
taskShareExpirationDays:
|
|
5508
|
-
allowMembersViewAllTasks:
|
|
5799
|
+
var organizationCloudSettingsSchema = import_zod16.z.object({
|
|
5800
|
+
recordTaskMessages: import_zod16.z.boolean().optional(),
|
|
5801
|
+
enableTaskSharing: import_zod16.z.boolean().optional(),
|
|
5802
|
+
taskShareExpirationDays: import_zod16.z.number().int().positive().optional(),
|
|
5803
|
+
allowMembersViewAllTasks: import_zod16.z.boolean().optional()
|
|
5509
5804
|
});
|
|
5510
|
-
var organizationFeaturesSchema =
|
|
5511
|
-
roomoteControlEnabled:
|
|
5805
|
+
var organizationFeaturesSchema = import_zod16.z.object({
|
|
5806
|
+
roomoteControlEnabled: import_zod16.z.boolean().optional()
|
|
5512
5807
|
});
|
|
5513
|
-
var organizationSettingsSchema =
|
|
5514
|
-
version:
|
|
5808
|
+
var organizationSettingsSchema = import_zod16.z.object({
|
|
5809
|
+
version: import_zod16.z.number(),
|
|
5515
5810
|
cloudSettings: organizationCloudSettingsSchema.optional(),
|
|
5516
5811
|
defaultSettings: organizationDefaultSettingsSchema,
|
|
5517
5812
|
allowList: organizationAllowListSchema,
|
|
5518
5813
|
features: organizationFeaturesSchema.optional(),
|
|
5519
|
-
hiddenMcps:
|
|
5520
|
-
hideMarketplaceMcps:
|
|
5521
|
-
mcps:
|
|
5522
|
-
providerProfiles:
|
|
5814
|
+
hiddenMcps: import_zod16.z.array(import_zod16.z.string()).optional(),
|
|
5815
|
+
hideMarketplaceMcps: import_zod16.z.boolean().optional(),
|
|
5816
|
+
mcps: import_zod16.z.array(mcpMarketplaceItemSchema).optional(),
|
|
5817
|
+
providerProfiles: import_zod16.z.record(import_zod16.z.string(), providerSettingsWithIdSchema).optional()
|
|
5523
5818
|
});
|
|
5524
|
-
var userFeaturesSchema =
|
|
5525
|
-
roomoteControlEnabled:
|
|
5819
|
+
var userFeaturesSchema = import_zod16.z.object({
|
|
5820
|
+
roomoteControlEnabled: import_zod16.z.boolean().optional()
|
|
5526
5821
|
});
|
|
5527
|
-
var userSettingsConfigSchema =
|
|
5528
|
-
extensionBridgeEnabled:
|
|
5529
|
-
taskSyncEnabled:
|
|
5822
|
+
var userSettingsConfigSchema = import_zod16.z.object({
|
|
5823
|
+
extensionBridgeEnabled: import_zod16.z.boolean().optional(),
|
|
5824
|
+
taskSyncEnabled: import_zod16.z.boolean().optional()
|
|
5530
5825
|
});
|
|
5531
|
-
var userSettingsDataSchema =
|
|
5826
|
+
var userSettingsDataSchema = import_zod16.z.object({
|
|
5532
5827
|
features: userFeaturesSchema,
|
|
5533
5828
|
settings: userSettingsConfigSchema,
|
|
5534
|
-
version:
|
|
5829
|
+
version: import_zod16.z.number()
|
|
5535
5830
|
});
|
|
5536
5831
|
var ORGANIZATION_ALLOW_ALL = {
|
|
5537
5832
|
allowAll: true,
|
|
@@ -5548,12 +5843,12 @@ var ORGANIZATION_DEFAULT = {
|
|
|
5548
5843
|
defaultSettings: {},
|
|
5549
5844
|
allowList: ORGANIZATION_ALLOW_ALL
|
|
5550
5845
|
};
|
|
5551
|
-
var shareResponseSchema =
|
|
5552
|
-
success:
|
|
5553
|
-
shareUrl:
|
|
5554
|
-
error:
|
|
5555
|
-
isNewShare:
|
|
5556
|
-
manageUrl:
|
|
5846
|
+
var shareResponseSchema = import_zod16.z.object({
|
|
5847
|
+
success: import_zod16.z.boolean(),
|
|
5848
|
+
shareUrl: import_zod16.z.string().optional(),
|
|
5849
|
+
error: import_zod16.z.string().optional(),
|
|
5850
|
+
isNewShare: import_zod16.z.boolean().optional(),
|
|
5851
|
+
manageUrl: import_zod16.z.string().optional()
|
|
5557
5852
|
});
|
|
5558
5853
|
var ConnectionState = /* @__PURE__ */ ((ConnectionState2) => {
|
|
5559
5854
|
ConnectionState2["DISCONNECTED"] = "disconnected";
|
|
@@ -5565,31 +5860,31 @@ var ConnectionState = /* @__PURE__ */ ((ConnectionState2) => {
|
|
|
5565
5860
|
})(ConnectionState || {});
|
|
5566
5861
|
var HEARTBEAT_INTERVAL_MS = 2e4;
|
|
5567
5862
|
var INSTANCE_TTL_SECONDS = 60;
|
|
5568
|
-
var extensionTaskSchema =
|
|
5569
|
-
taskId:
|
|
5570
|
-
taskStatus:
|
|
5863
|
+
var extensionTaskSchema = import_zod16.z.object({
|
|
5864
|
+
taskId: import_zod16.z.string(),
|
|
5865
|
+
taskStatus: import_zod16.z.nativeEnum(TaskStatus),
|
|
5571
5866
|
taskAsk: clineMessageSchema.optional(),
|
|
5572
|
-
queuedMessages:
|
|
5573
|
-
parentTaskId:
|
|
5574
|
-
childTaskId:
|
|
5867
|
+
queuedMessages: import_zod16.z.array(queuedMessageSchema).optional(),
|
|
5868
|
+
parentTaskId: import_zod16.z.string().optional(),
|
|
5869
|
+
childTaskId: import_zod16.z.string().optional(),
|
|
5575
5870
|
tokenUsage: tokenUsageSchema.optional(),
|
|
5576
5871
|
...taskMetadataSchema.shape
|
|
5577
5872
|
});
|
|
5578
|
-
var extensionInstanceSchema =
|
|
5579
|
-
instanceId:
|
|
5580
|
-
userId:
|
|
5581
|
-
workspacePath:
|
|
5873
|
+
var extensionInstanceSchema = import_zod16.z.object({
|
|
5874
|
+
instanceId: import_zod16.z.string(),
|
|
5875
|
+
userId: import_zod16.z.string(),
|
|
5876
|
+
workspacePath: import_zod16.z.string(),
|
|
5582
5877
|
appProperties: staticAppPropertiesSchema,
|
|
5583
5878
|
gitProperties: gitPropertiesSchema.optional(),
|
|
5584
|
-
lastHeartbeat:
|
|
5879
|
+
lastHeartbeat: import_zod16.z.coerce.number(),
|
|
5585
5880
|
task: extensionTaskSchema,
|
|
5586
5881
|
taskAsk: clineMessageSchema.optional(),
|
|
5587
|
-
taskHistory:
|
|
5588
|
-
mode:
|
|
5589
|
-
modes:
|
|
5590
|
-
providerProfile:
|
|
5591
|
-
providerProfiles:
|
|
5592
|
-
isCloudAgent:
|
|
5882
|
+
taskHistory: import_zod16.z.array(import_zod16.z.string()),
|
|
5883
|
+
mode: import_zod16.z.string().optional(),
|
|
5884
|
+
modes: import_zod16.z.array(import_zod16.z.object({ slug: import_zod16.z.string(), name: import_zod16.z.string() })).optional(),
|
|
5885
|
+
providerProfile: import_zod16.z.string().optional(),
|
|
5886
|
+
providerProfiles: import_zod16.z.array(import_zod16.z.object({ name: import_zod16.z.string(), provider: import_zod16.z.string().optional() })).optional(),
|
|
5887
|
+
isCloudAgent: import_zod16.z.boolean().optional()
|
|
5593
5888
|
});
|
|
5594
5889
|
var ExtensionBridgeEventName = ((ExtensionBridgeEventName2) => {
|
|
5595
5890
|
ExtensionBridgeEventName2[ExtensionBridgeEventName2["TaskCreated"] = "taskCreated" /* TaskCreated */] = "TaskCreated";
|
|
@@ -5614,108 +5909,108 @@ var ExtensionBridgeEventName = ((ExtensionBridgeEventName2) => {
|
|
|
5614
5909
|
ExtensionBridgeEventName2["HeartbeatUpdated"] = "heartbeat_updated";
|
|
5615
5910
|
return ExtensionBridgeEventName2;
|
|
5616
5911
|
})(ExtensionBridgeEventName || {});
|
|
5617
|
-
var extensionBridgeEventSchema =
|
|
5618
|
-
|
|
5619
|
-
type:
|
|
5912
|
+
var extensionBridgeEventSchema = import_zod16.z.discriminatedUnion("type", [
|
|
5913
|
+
import_zod16.z.object({
|
|
5914
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskCreated),
|
|
5620
5915
|
instance: extensionInstanceSchema,
|
|
5621
|
-
timestamp:
|
|
5916
|
+
timestamp: import_zod16.z.number()
|
|
5622
5917
|
}),
|
|
5623
|
-
|
|
5624
|
-
type:
|
|
5918
|
+
import_zod16.z.object({
|
|
5919
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskStarted),
|
|
5625
5920
|
instance: extensionInstanceSchema,
|
|
5626
|
-
timestamp:
|
|
5921
|
+
timestamp: import_zod16.z.number()
|
|
5627
5922
|
}),
|
|
5628
|
-
|
|
5629
|
-
type:
|
|
5923
|
+
import_zod16.z.object({
|
|
5924
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskCompleted),
|
|
5630
5925
|
instance: extensionInstanceSchema,
|
|
5631
|
-
timestamp:
|
|
5926
|
+
timestamp: import_zod16.z.number()
|
|
5632
5927
|
}),
|
|
5633
|
-
|
|
5634
|
-
type:
|
|
5928
|
+
import_zod16.z.object({
|
|
5929
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskAborted),
|
|
5635
5930
|
instance: extensionInstanceSchema,
|
|
5636
|
-
timestamp:
|
|
5931
|
+
timestamp: import_zod16.z.number()
|
|
5637
5932
|
}),
|
|
5638
|
-
|
|
5639
|
-
type:
|
|
5933
|
+
import_zod16.z.object({
|
|
5934
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskFocused),
|
|
5640
5935
|
instance: extensionInstanceSchema,
|
|
5641
|
-
timestamp:
|
|
5936
|
+
timestamp: import_zod16.z.number()
|
|
5642
5937
|
}),
|
|
5643
|
-
|
|
5644
|
-
type:
|
|
5938
|
+
import_zod16.z.object({
|
|
5939
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskUnfocused),
|
|
5645
5940
|
instance: extensionInstanceSchema,
|
|
5646
|
-
timestamp:
|
|
5941
|
+
timestamp: import_zod16.z.number()
|
|
5647
5942
|
}),
|
|
5648
|
-
|
|
5649
|
-
type:
|
|
5943
|
+
import_zod16.z.object({
|
|
5944
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskActive),
|
|
5650
5945
|
instance: extensionInstanceSchema,
|
|
5651
|
-
timestamp:
|
|
5946
|
+
timestamp: import_zod16.z.number()
|
|
5652
5947
|
}),
|
|
5653
|
-
|
|
5654
|
-
type:
|
|
5948
|
+
import_zod16.z.object({
|
|
5949
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskInteractive),
|
|
5655
5950
|
instance: extensionInstanceSchema,
|
|
5656
|
-
timestamp:
|
|
5951
|
+
timestamp: import_zod16.z.number()
|
|
5657
5952
|
}),
|
|
5658
|
-
|
|
5659
|
-
type:
|
|
5953
|
+
import_zod16.z.object({
|
|
5954
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskResumable),
|
|
5660
5955
|
instance: extensionInstanceSchema,
|
|
5661
|
-
timestamp:
|
|
5956
|
+
timestamp: import_zod16.z.number()
|
|
5662
5957
|
}),
|
|
5663
|
-
|
|
5664
|
-
type:
|
|
5958
|
+
import_zod16.z.object({
|
|
5959
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskIdle),
|
|
5665
5960
|
instance: extensionInstanceSchema,
|
|
5666
|
-
timestamp:
|
|
5961
|
+
timestamp: import_zod16.z.number()
|
|
5667
5962
|
}),
|
|
5668
|
-
|
|
5669
|
-
type:
|
|
5963
|
+
import_zod16.z.object({
|
|
5964
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskPaused),
|
|
5670
5965
|
instance: extensionInstanceSchema,
|
|
5671
|
-
timestamp:
|
|
5966
|
+
timestamp: import_zod16.z.number()
|
|
5672
5967
|
}),
|
|
5673
|
-
|
|
5674
|
-
type:
|
|
5968
|
+
import_zod16.z.object({
|
|
5969
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskUnpaused),
|
|
5675
5970
|
instance: extensionInstanceSchema,
|
|
5676
|
-
timestamp:
|
|
5971
|
+
timestamp: import_zod16.z.number()
|
|
5677
5972
|
}),
|
|
5678
|
-
|
|
5679
|
-
type:
|
|
5973
|
+
import_zod16.z.object({
|
|
5974
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskSpawned),
|
|
5680
5975
|
instance: extensionInstanceSchema,
|
|
5681
|
-
timestamp:
|
|
5976
|
+
timestamp: import_zod16.z.number()
|
|
5682
5977
|
}),
|
|
5683
|
-
|
|
5684
|
-
type:
|
|
5978
|
+
import_zod16.z.object({
|
|
5979
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskUserMessage),
|
|
5685
5980
|
instance: extensionInstanceSchema,
|
|
5686
|
-
timestamp:
|
|
5981
|
+
timestamp: import_zod16.z.number()
|
|
5687
5982
|
}),
|
|
5688
|
-
|
|
5689
|
-
type:
|
|
5983
|
+
import_zod16.z.object({
|
|
5984
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.TaskTokenUsageUpdated),
|
|
5690
5985
|
instance: extensionInstanceSchema,
|
|
5691
|
-
timestamp:
|
|
5986
|
+
timestamp: import_zod16.z.number()
|
|
5692
5987
|
}),
|
|
5693
|
-
|
|
5694
|
-
type:
|
|
5988
|
+
import_zod16.z.object({
|
|
5989
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.ModeChanged),
|
|
5695
5990
|
instance: extensionInstanceSchema,
|
|
5696
|
-
mode:
|
|
5697
|
-
timestamp:
|
|
5991
|
+
mode: import_zod16.z.string(),
|
|
5992
|
+
timestamp: import_zod16.z.number()
|
|
5698
5993
|
}),
|
|
5699
|
-
|
|
5700
|
-
type:
|
|
5994
|
+
import_zod16.z.object({
|
|
5995
|
+
type: import_zod16.z.literal(ExtensionBridgeEventName.ProviderProfileChanged),
|
|
5701
5996
|
instance: extensionInstanceSchema,
|
|
5702
|
-
providerProfile:
|
|
5703
|
-
timestamp:
|
|
5997
|
+
providerProfile: import_zod16.z.object({ name: import_zod16.z.string(), provider: import_zod16.z.string().optional() }),
|
|
5998
|
+
timestamp: import_zod16.z.number()
|
|
5704
5999
|
}),
|
|
5705
|
-
|
|
5706
|
-
type:
|
|
6000
|
+
import_zod16.z.object({
|
|
6001
|
+
type: import_zod16.z.literal("instance_registered" /* InstanceRegistered */),
|
|
5707
6002
|
instance: extensionInstanceSchema,
|
|
5708
|
-
timestamp:
|
|
6003
|
+
timestamp: import_zod16.z.number()
|
|
5709
6004
|
}),
|
|
5710
|
-
|
|
5711
|
-
type:
|
|
6005
|
+
import_zod16.z.object({
|
|
6006
|
+
type: import_zod16.z.literal("instance_unregistered" /* InstanceUnregistered */),
|
|
5712
6007
|
instance: extensionInstanceSchema,
|
|
5713
|
-
timestamp:
|
|
6008
|
+
timestamp: import_zod16.z.number()
|
|
5714
6009
|
}),
|
|
5715
|
-
|
|
5716
|
-
type:
|
|
6010
|
+
import_zod16.z.object({
|
|
6011
|
+
type: import_zod16.z.literal("heartbeat_updated" /* HeartbeatUpdated */),
|
|
5717
6012
|
instance: extensionInstanceSchema,
|
|
5718
|
-
timestamp:
|
|
6013
|
+
timestamp: import_zod16.z.number()
|
|
5719
6014
|
})
|
|
5720
6015
|
]);
|
|
5721
6016
|
var ExtensionBridgeCommandName = /* @__PURE__ */ ((ExtensionBridgeCommandName2) => {
|
|
@@ -5724,29 +6019,29 @@ var ExtensionBridgeCommandName = /* @__PURE__ */ ((ExtensionBridgeCommandName2)
|
|
|
5724
6019
|
ExtensionBridgeCommandName2["ResumeTask"] = "resume_task";
|
|
5725
6020
|
return ExtensionBridgeCommandName2;
|
|
5726
6021
|
})(ExtensionBridgeCommandName || {});
|
|
5727
|
-
var extensionBridgeCommandSchema =
|
|
5728
|
-
|
|
5729
|
-
type:
|
|
5730
|
-
instanceId:
|
|
5731
|
-
payload:
|
|
5732
|
-
text:
|
|
5733
|
-
images:
|
|
5734
|
-
mode:
|
|
5735
|
-
providerProfile:
|
|
6022
|
+
var extensionBridgeCommandSchema = import_zod16.z.discriminatedUnion("type", [
|
|
6023
|
+
import_zod16.z.object({
|
|
6024
|
+
type: import_zod16.z.literal("start_task" /* StartTask */),
|
|
6025
|
+
instanceId: import_zod16.z.string(),
|
|
6026
|
+
payload: import_zod16.z.object({
|
|
6027
|
+
text: import_zod16.z.string(),
|
|
6028
|
+
images: import_zod16.z.array(import_zod16.z.string()).optional(),
|
|
6029
|
+
mode: import_zod16.z.string().optional(),
|
|
6030
|
+
providerProfile: import_zod16.z.string().optional()
|
|
5736
6031
|
}),
|
|
5737
|
-
timestamp:
|
|
6032
|
+
timestamp: import_zod16.z.number()
|
|
5738
6033
|
}),
|
|
5739
|
-
|
|
5740
|
-
type:
|
|
5741
|
-
instanceId:
|
|
5742
|
-
payload:
|
|
5743
|
-
timestamp:
|
|
6034
|
+
import_zod16.z.object({
|
|
6035
|
+
type: import_zod16.z.literal("stop_task" /* StopTask */),
|
|
6036
|
+
instanceId: import_zod16.z.string(),
|
|
6037
|
+
payload: import_zod16.z.object({ taskId: import_zod16.z.string() }),
|
|
6038
|
+
timestamp: import_zod16.z.number()
|
|
5744
6039
|
}),
|
|
5745
|
-
|
|
5746
|
-
type:
|
|
5747
|
-
instanceId:
|
|
5748
|
-
payload:
|
|
5749
|
-
timestamp:
|
|
6040
|
+
import_zod16.z.object({
|
|
6041
|
+
type: import_zod16.z.literal("resume_task" /* ResumeTask */),
|
|
6042
|
+
instanceId: import_zod16.z.string(),
|
|
6043
|
+
payload: import_zod16.z.object({ taskId: import_zod16.z.string() }),
|
|
6044
|
+
timestamp: import_zod16.z.number()
|
|
5750
6045
|
})
|
|
5751
6046
|
]);
|
|
5752
6047
|
var TaskBridgeEventName = ((TaskBridgeEventName2) => {
|
|
@@ -5755,21 +6050,21 @@ var TaskBridgeEventName = ((TaskBridgeEventName2) => {
|
|
|
5755
6050
|
TaskBridgeEventName2[TaskBridgeEventName2["TaskInteractive"] = "taskInteractive" /* TaskInteractive */] = "TaskInteractive";
|
|
5756
6051
|
return TaskBridgeEventName2;
|
|
5757
6052
|
})(TaskBridgeEventName || {});
|
|
5758
|
-
var taskBridgeEventSchema =
|
|
5759
|
-
|
|
5760
|
-
type:
|
|
5761
|
-
taskId:
|
|
5762
|
-
action:
|
|
6053
|
+
var taskBridgeEventSchema = import_zod16.z.discriminatedUnion("type", [
|
|
6054
|
+
import_zod16.z.object({
|
|
6055
|
+
type: import_zod16.z.literal(TaskBridgeEventName.Message),
|
|
6056
|
+
taskId: import_zod16.z.string(),
|
|
6057
|
+
action: import_zod16.z.string(),
|
|
5763
6058
|
message: clineMessageSchema
|
|
5764
6059
|
}),
|
|
5765
|
-
|
|
5766
|
-
type:
|
|
5767
|
-
taskId:
|
|
5768
|
-
mode:
|
|
6060
|
+
import_zod16.z.object({
|
|
6061
|
+
type: import_zod16.z.literal(TaskBridgeEventName.TaskModeSwitched),
|
|
6062
|
+
taskId: import_zod16.z.string(),
|
|
6063
|
+
mode: import_zod16.z.string()
|
|
5769
6064
|
}),
|
|
5770
|
-
|
|
5771
|
-
type:
|
|
5772
|
-
taskId:
|
|
6065
|
+
import_zod16.z.object({
|
|
6066
|
+
type: import_zod16.z.literal(TaskBridgeEventName.TaskInteractive),
|
|
6067
|
+
taskId: import_zod16.z.string()
|
|
5773
6068
|
})
|
|
5774
6069
|
]);
|
|
5775
6070
|
var TaskBridgeCommandName = /* @__PURE__ */ ((TaskBridgeCommandName2) => {
|
|
@@ -5778,35 +6073,35 @@ var TaskBridgeCommandName = /* @__PURE__ */ ((TaskBridgeCommandName2) => {
|
|
|
5778
6073
|
TaskBridgeCommandName2["DenyAsk"] = "deny_ask";
|
|
5779
6074
|
return TaskBridgeCommandName2;
|
|
5780
6075
|
})(TaskBridgeCommandName || {});
|
|
5781
|
-
var taskBridgeCommandSchema =
|
|
5782
|
-
|
|
5783
|
-
type:
|
|
5784
|
-
taskId:
|
|
5785
|
-
payload:
|
|
5786
|
-
text:
|
|
5787
|
-
images:
|
|
5788
|
-
mode:
|
|
5789
|
-
providerProfile:
|
|
6076
|
+
var taskBridgeCommandSchema = import_zod16.z.discriminatedUnion("type", [
|
|
6077
|
+
import_zod16.z.object({
|
|
6078
|
+
type: import_zod16.z.literal("message" /* Message */),
|
|
6079
|
+
taskId: import_zod16.z.string(),
|
|
6080
|
+
payload: import_zod16.z.object({
|
|
6081
|
+
text: import_zod16.z.string(),
|
|
6082
|
+
images: import_zod16.z.array(import_zod16.z.string()).optional(),
|
|
6083
|
+
mode: import_zod16.z.string().optional(),
|
|
6084
|
+
providerProfile: import_zod16.z.string().optional()
|
|
5790
6085
|
}),
|
|
5791
|
-
timestamp:
|
|
6086
|
+
timestamp: import_zod16.z.number()
|
|
5792
6087
|
}),
|
|
5793
|
-
|
|
5794
|
-
type:
|
|
5795
|
-
taskId:
|
|
5796
|
-
payload:
|
|
5797
|
-
text:
|
|
5798
|
-
images:
|
|
6088
|
+
import_zod16.z.object({
|
|
6089
|
+
type: import_zod16.z.literal("approve_ask" /* ApproveAsk */),
|
|
6090
|
+
taskId: import_zod16.z.string(),
|
|
6091
|
+
payload: import_zod16.z.object({
|
|
6092
|
+
text: import_zod16.z.string().optional(),
|
|
6093
|
+
images: import_zod16.z.array(import_zod16.z.string()).optional()
|
|
5799
6094
|
}),
|
|
5800
|
-
timestamp:
|
|
6095
|
+
timestamp: import_zod16.z.number()
|
|
5801
6096
|
}),
|
|
5802
|
-
|
|
5803
|
-
type:
|
|
5804
|
-
taskId:
|
|
5805
|
-
payload:
|
|
5806
|
-
text:
|
|
5807
|
-
images:
|
|
6097
|
+
import_zod16.z.object({
|
|
6098
|
+
type: import_zod16.z.literal("deny_ask" /* DenyAsk */),
|
|
6099
|
+
taskId: import_zod16.z.string(),
|
|
6100
|
+
payload: import_zod16.z.object({
|
|
6101
|
+
text: import_zod16.z.string().optional(),
|
|
6102
|
+
images: import_zod16.z.array(import_zod16.z.string()).optional()
|
|
5808
6103
|
}),
|
|
5809
|
-
timestamp:
|
|
6104
|
+
timestamp: import_zod16.z.number()
|
|
5810
6105
|
})
|
|
5811
6106
|
]);
|
|
5812
6107
|
var ExtensionSocketEvents = /* @__PURE__ */ ((ExtensionSocketEvents2) => {
|
|
@@ -5829,25 +6124,25 @@ var TaskSocketEvents = /* @__PURE__ */ ((TaskSocketEvents2) => {
|
|
|
5829
6124
|
TaskSocketEvents2["RELAYED_COMMAND"] = "task:relayed_command";
|
|
5830
6125
|
return TaskSocketEvents2;
|
|
5831
6126
|
})(TaskSocketEvents || {});
|
|
5832
|
-
var usageStatsSchema =
|
|
5833
|
-
success:
|
|
5834
|
-
data:
|
|
5835
|
-
dates:
|
|
6127
|
+
var usageStatsSchema = import_zod16.z.object({
|
|
6128
|
+
success: import_zod16.z.boolean(),
|
|
6129
|
+
data: import_zod16.z.object({
|
|
6130
|
+
dates: import_zod16.z.array(import_zod16.z.string()),
|
|
5836
6131
|
// Array of date strings
|
|
5837
|
-
tasks:
|
|
6132
|
+
tasks: import_zod16.z.array(import_zod16.z.number()),
|
|
5838
6133
|
// Array of task counts
|
|
5839
|
-
tokens:
|
|
6134
|
+
tokens: import_zod16.z.array(import_zod16.z.number()),
|
|
5840
6135
|
// Array of token counts
|
|
5841
|
-
costs:
|
|
6136
|
+
costs: import_zod16.z.array(import_zod16.z.number()),
|
|
5842
6137
|
// Array of costs in USD
|
|
5843
|
-
totals:
|
|
5844
|
-
tasks:
|
|
5845
|
-
tokens:
|
|
5846
|
-
cost:
|
|
6138
|
+
totals: import_zod16.z.object({
|
|
6139
|
+
tasks: import_zod16.z.number(),
|
|
6140
|
+
tokens: import_zod16.z.number(),
|
|
6141
|
+
cost: import_zod16.z.number()
|
|
5847
6142
|
// Total cost in USD
|
|
5848
6143
|
})
|
|
5849
6144
|
}),
|
|
5850
|
-
period:
|
|
6145
|
+
period: import_zod16.z.number()
|
|
5851
6146
|
// Period in days (e.g., 30)
|
|
5852
6147
|
});
|
|
5853
6148
|
|
|
@@ -5858,18 +6153,18 @@ var COOKIE_CONSENT_EVENTS = {
|
|
|
5858
6153
|
};
|
|
5859
6154
|
|
|
5860
6155
|
// src/followup.ts
|
|
5861
|
-
var
|
|
5862
|
-
var suggestionItemSchema =
|
|
5863
|
-
answer:
|
|
5864
|
-
mode:
|
|
6156
|
+
var import_zod17 = require("zod");
|
|
6157
|
+
var suggestionItemSchema = import_zod17.z.object({
|
|
6158
|
+
answer: import_zod17.z.string(),
|
|
6159
|
+
mode: import_zod17.z.string().optional()
|
|
5865
6160
|
});
|
|
5866
|
-
var followUpDataSchema =
|
|
5867
|
-
question:
|
|
5868
|
-
suggest:
|
|
6161
|
+
var followUpDataSchema = import_zod17.z.object({
|
|
6162
|
+
question: import_zod17.z.string().optional(),
|
|
6163
|
+
suggest: import_zod17.z.array(suggestionItemSchema).optional()
|
|
5869
6164
|
});
|
|
5870
6165
|
|
|
5871
6166
|
// src/ipc.ts
|
|
5872
|
-
var
|
|
6167
|
+
var import_zod18 = require("zod");
|
|
5873
6168
|
var IpcMessageType = /* @__PURE__ */ ((IpcMessageType2) => {
|
|
5874
6169
|
IpcMessageType2["Connect"] = "Connect";
|
|
5875
6170
|
IpcMessageType2["Disconnect"] = "Disconnect";
|
|
@@ -5883,84 +6178,92 @@ var IpcOrigin = /* @__PURE__ */ ((IpcOrigin2) => {
|
|
|
5883
6178
|
IpcOrigin2["Server"] = "server";
|
|
5884
6179
|
return IpcOrigin2;
|
|
5885
6180
|
})(IpcOrigin || {});
|
|
5886
|
-
var ackSchema =
|
|
5887
|
-
clientId:
|
|
5888
|
-
pid:
|
|
5889
|
-
ppid:
|
|
6181
|
+
var ackSchema = import_zod18.z.object({
|
|
6182
|
+
clientId: import_zod18.z.string(),
|
|
6183
|
+
pid: import_zod18.z.number(),
|
|
6184
|
+
ppid: import_zod18.z.number()
|
|
5890
6185
|
});
|
|
5891
6186
|
var TaskCommandName = /* @__PURE__ */ ((TaskCommandName2) => {
|
|
5892
6187
|
TaskCommandName2["StartNewTask"] = "StartNewTask";
|
|
5893
6188
|
TaskCommandName2["CancelTask"] = "CancelTask";
|
|
5894
6189
|
TaskCommandName2["CloseTask"] = "CloseTask";
|
|
5895
6190
|
TaskCommandName2["ResumeTask"] = "ResumeTask";
|
|
6191
|
+
TaskCommandName2["SendMessage"] = "SendMessage";
|
|
5896
6192
|
return TaskCommandName2;
|
|
5897
6193
|
})(TaskCommandName || {});
|
|
5898
|
-
var taskCommandSchema =
|
|
5899
|
-
|
|
5900
|
-
commandName:
|
|
5901
|
-
data:
|
|
6194
|
+
var taskCommandSchema = import_zod18.z.discriminatedUnion("commandName", [
|
|
6195
|
+
import_zod18.z.object({
|
|
6196
|
+
commandName: import_zod18.z.literal("StartNewTask" /* StartNewTask */),
|
|
6197
|
+
data: import_zod18.z.object({
|
|
5902
6198
|
configuration: rooCodeSettingsSchema,
|
|
5903
|
-
text:
|
|
5904
|
-
images:
|
|
5905
|
-
newTab:
|
|
6199
|
+
text: import_zod18.z.string(),
|
|
6200
|
+
images: import_zod18.z.array(import_zod18.z.string()).optional(),
|
|
6201
|
+
newTab: import_zod18.z.boolean().optional()
|
|
5906
6202
|
})
|
|
5907
6203
|
}),
|
|
5908
|
-
|
|
5909
|
-
commandName:
|
|
5910
|
-
data:
|
|
6204
|
+
import_zod18.z.object({
|
|
6205
|
+
commandName: import_zod18.z.literal("CancelTask" /* CancelTask */),
|
|
6206
|
+
data: import_zod18.z.string()
|
|
6207
|
+
}),
|
|
6208
|
+
import_zod18.z.object({
|
|
6209
|
+
commandName: import_zod18.z.literal("CloseTask" /* CloseTask */),
|
|
6210
|
+
data: import_zod18.z.string()
|
|
5911
6211
|
}),
|
|
5912
|
-
|
|
5913
|
-
commandName:
|
|
5914
|
-
data:
|
|
6212
|
+
import_zod18.z.object({
|
|
6213
|
+
commandName: import_zod18.z.literal("ResumeTask" /* ResumeTask */),
|
|
6214
|
+
data: import_zod18.z.string()
|
|
5915
6215
|
}),
|
|
5916
|
-
|
|
5917
|
-
commandName:
|
|
5918
|
-
data:
|
|
6216
|
+
import_zod18.z.object({
|
|
6217
|
+
commandName: import_zod18.z.literal("SendMessage" /* SendMessage */),
|
|
6218
|
+
data: import_zod18.z.object({
|
|
6219
|
+
text: import_zod18.z.string().optional(),
|
|
6220
|
+
images: import_zod18.z.array(import_zod18.z.string()).optional()
|
|
6221
|
+
})
|
|
5919
6222
|
})
|
|
5920
6223
|
]);
|
|
5921
|
-
var ipcMessageSchema =
|
|
5922
|
-
|
|
5923
|
-
type:
|
|
5924
|
-
origin:
|
|
6224
|
+
var ipcMessageSchema = import_zod18.z.discriminatedUnion("type", [
|
|
6225
|
+
import_zod18.z.object({
|
|
6226
|
+
type: import_zod18.z.literal("Ack" /* Ack */),
|
|
6227
|
+
origin: import_zod18.z.literal("server" /* Server */),
|
|
5925
6228
|
data: ackSchema
|
|
5926
6229
|
}),
|
|
5927
|
-
|
|
5928
|
-
type:
|
|
5929
|
-
origin:
|
|
5930
|
-
clientId:
|
|
6230
|
+
import_zod18.z.object({
|
|
6231
|
+
type: import_zod18.z.literal("TaskCommand" /* TaskCommand */),
|
|
6232
|
+
origin: import_zod18.z.literal("client" /* Client */),
|
|
6233
|
+
clientId: import_zod18.z.string(),
|
|
5931
6234
|
data: taskCommandSchema
|
|
5932
6235
|
}),
|
|
5933
|
-
|
|
5934
|
-
type:
|
|
5935
|
-
origin:
|
|
5936
|
-
relayClientId:
|
|
6236
|
+
import_zod18.z.object({
|
|
6237
|
+
type: import_zod18.z.literal("TaskEvent" /* TaskEvent */),
|
|
6238
|
+
origin: import_zod18.z.literal("server" /* Server */),
|
|
6239
|
+
relayClientId: import_zod18.z.string().optional(),
|
|
5937
6240
|
data: taskEventSchema
|
|
5938
6241
|
})
|
|
5939
6242
|
]);
|
|
5940
6243
|
|
|
5941
6244
|
// src/mcp.ts
|
|
5942
|
-
var
|
|
5943
|
-
var mcpExecutionStatusSchema =
|
|
5944
|
-
|
|
5945
|
-
executionId:
|
|
5946
|
-
status:
|
|
5947
|
-
serverName:
|
|
5948
|
-
toolName:
|
|
6245
|
+
var import_zod19 = require("zod");
|
|
6246
|
+
var mcpExecutionStatusSchema = import_zod19.z.discriminatedUnion("status", [
|
|
6247
|
+
import_zod19.z.object({
|
|
6248
|
+
executionId: import_zod19.z.string(),
|
|
6249
|
+
status: import_zod19.z.literal("started"),
|
|
6250
|
+
serverName: import_zod19.z.string(),
|
|
6251
|
+
toolName: import_zod19.z.string()
|
|
5949
6252
|
}),
|
|
5950
|
-
|
|
5951
|
-
executionId:
|
|
5952
|
-
status:
|
|
5953
|
-
response:
|
|
6253
|
+
import_zod19.z.object({
|
|
6254
|
+
executionId: import_zod19.z.string(),
|
|
6255
|
+
status: import_zod19.z.literal("output"),
|
|
6256
|
+
response: import_zod19.z.string()
|
|
5954
6257
|
}),
|
|
5955
|
-
|
|
5956
|
-
executionId:
|
|
5957
|
-
status:
|
|
5958
|
-
response:
|
|
6258
|
+
import_zod19.z.object({
|
|
6259
|
+
executionId: import_zod19.z.string(),
|
|
6260
|
+
status: import_zod19.z.literal("completed"),
|
|
6261
|
+
response: import_zod19.z.string().optional()
|
|
5959
6262
|
}),
|
|
5960
|
-
|
|
5961
|
-
executionId:
|
|
5962
|
-
status:
|
|
5963
|
-
error:
|
|
6263
|
+
import_zod19.z.object({
|
|
6264
|
+
executionId: import_zod19.z.string(),
|
|
6265
|
+
status: import_zod19.z.literal("error"),
|
|
6266
|
+
error: import_zod19.z.string().optional()
|
|
5964
6267
|
})
|
|
5965
6268
|
]);
|
|
5966
6269
|
|
|
@@ -5970,40 +6273,40 @@ function shouldUseSingleFileRead(modelId) {
|
|
|
5970
6273
|
}
|
|
5971
6274
|
|
|
5972
6275
|
// src/todo.ts
|
|
5973
|
-
var
|
|
5974
|
-
var todoStatusSchema =
|
|
5975
|
-
var todoItemSchema =
|
|
5976
|
-
id:
|
|
5977
|
-
content:
|
|
6276
|
+
var import_zod20 = require("zod");
|
|
6277
|
+
var todoStatusSchema = import_zod20.z.enum(["pending", "in_progress", "completed"]);
|
|
6278
|
+
var todoItemSchema = import_zod20.z.object({
|
|
6279
|
+
id: import_zod20.z.string(),
|
|
6280
|
+
content: import_zod20.z.string(),
|
|
5978
6281
|
status: todoStatusSchema
|
|
5979
6282
|
});
|
|
5980
6283
|
|
|
5981
6284
|
// src/terminal.ts
|
|
5982
|
-
var
|
|
5983
|
-
var commandExecutionStatusSchema =
|
|
5984
|
-
|
|
5985
|
-
executionId:
|
|
5986
|
-
status:
|
|
5987
|
-
pid:
|
|
5988
|
-
command:
|
|
6285
|
+
var import_zod21 = require("zod");
|
|
6286
|
+
var commandExecutionStatusSchema = import_zod21.z.discriminatedUnion("status", [
|
|
6287
|
+
import_zod21.z.object({
|
|
6288
|
+
executionId: import_zod21.z.string(),
|
|
6289
|
+
status: import_zod21.z.literal("started"),
|
|
6290
|
+
pid: import_zod21.z.number().optional(),
|
|
6291
|
+
command: import_zod21.z.string()
|
|
5989
6292
|
}),
|
|
5990
|
-
|
|
5991
|
-
executionId:
|
|
5992
|
-
status:
|
|
5993
|
-
output:
|
|
6293
|
+
import_zod21.z.object({
|
|
6294
|
+
executionId: import_zod21.z.string(),
|
|
6295
|
+
status: import_zod21.z.literal("output"),
|
|
6296
|
+
output: import_zod21.z.string()
|
|
5994
6297
|
}),
|
|
5995
|
-
|
|
5996
|
-
executionId:
|
|
5997
|
-
status:
|
|
5998
|
-
exitCode:
|
|
6298
|
+
import_zod21.z.object({
|
|
6299
|
+
executionId: import_zod21.z.string(),
|
|
6300
|
+
status: import_zod21.z.literal("exited"),
|
|
6301
|
+
exitCode: import_zod21.z.number().optional()
|
|
5999
6302
|
}),
|
|
6000
|
-
|
|
6001
|
-
executionId:
|
|
6002
|
-
status:
|
|
6303
|
+
import_zod21.z.object({
|
|
6304
|
+
executionId: import_zod21.z.string(),
|
|
6305
|
+
status: import_zod21.z.literal("fallback")
|
|
6003
6306
|
}),
|
|
6004
|
-
|
|
6005
|
-
executionId:
|
|
6006
|
-
status:
|
|
6307
|
+
import_zod21.z.object({
|
|
6308
|
+
executionId: import_zod21.z.string(),
|
|
6309
|
+
status: import_zod21.z.literal("timeout")
|
|
6007
6310
|
})
|
|
6008
6311
|
]);
|
|
6009
6312
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -6014,6 +6317,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6014
6317
|
BEDROCK_1M_CONTEXT_MODEL_IDS,
|
|
6015
6318
|
BEDROCK_DEFAULT_CONTEXT,
|
|
6016
6319
|
BEDROCK_DEFAULT_TEMPERATURE,
|
|
6320
|
+
BEDROCK_GLOBAL_INFERENCE_MODEL_IDS,
|
|
6017
6321
|
BEDROCK_MAX_TOKENS,
|
|
6018
6322
|
BEDROCK_REGIONS,
|
|
6019
6323
|
CLAUDE_CODE_DEFAULT_MAX_OUTPUT_TOKENS,
|
|
@@ -6022,6 +6326,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6022
6326
|
COOKIE_CONSENT_EVENTS,
|
|
6023
6327
|
ConnectionState,
|
|
6024
6328
|
DEEP_SEEK_DEFAULT_TEMPERATURE,
|
|
6329
|
+
DEFAULT_CHECKPOINT_TIMEOUT_SECONDS,
|
|
6025
6330
|
DEFAULT_CONSECUTIVE_MISTAKE_LIMIT,
|
|
6026
6331
|
DEFAULT_MODES,
|
|
6027
6332
|
DEFAULT_TERMINAL_OUTPUT_CHARACTER_LIMIT,
|
|
@@ -6051,15 +6356,16 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6051
6356
|
IO_INTELLIGENCE_CACHE_DURATION,
|
|
6052
6357
|
IpcMessageType,
|
|
6053
6358
|
IpcOrigin,
|
|
6054
|
-
LITELLM_COMPUTER_USE_MODELS,
|
|
6055
6359
|
LMSTUDIO_DEFAULT_TEMPERATURE,
|
|
6360
|
+
MAX_CHECKPOINT_TIMEOUT_SECONDS,
|
|
6361
|
+
MINIMAX_DEFAULT_TEMPERATURE,
|
|
6362
|
+
MIN_CHECKPOINT_TIMEOUT_SECONDS,
|
|
6056
6363
|
MISTRAL_DEFAULT_TEMPERATURE,
|
|
6057
6364
|
MODELS_BY_PROVIDER,
|
|
6058
6365
|
MOONSHOT_DEFAULT_TEMPERATURE,
|
|
6059
6366
|
OPENAI_AZURE_AI_INFERENCE_PATH,
|
|
6060
6367
|
OPENAI_NATIVE_DEFAULT_TEMPERATURE,
|
|
6061
6368
|
OPENROUTER_DEFAULT_PROVIDER_NAME,
|
|
6062
|
-
OPEN_ROUTER_COMPUTER_USE_MODELS,
|
|
6063
6369
|
OPEN_ROUTER_PROMPT_CACHING_MODELS,
|
|
6064
6370
|
OPEN_ROUTER_REASONING_BUDGET_MODELS,
|
|
6065
6371
|
OPEN_ROUTER_REQUIRED_REASONING_BUDGET_MODELS,
|
|
@@ -6067,6 +6373,9 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6067
6373
|
ORGANIZATION_DEFAULT,
|
|
6068
6374
|
PROVIDER_SETTINGS_KEYS,
|
|
6069
6375
|
RooCodeEventName,
|
|
6376
|
+
RooModelSchema,
|
|
6377
|
+
RooModelsResponseSchema,
|
|
6378
|
+
RooPricingSchema,
|
|
6070
6379
|
SECRET_STATE_KEYS,
|
|
6071
6380
|
TaskBridgeCommandName,
|
|
6072
6381
|
TaskBridgeEventName,
|
|
@@ -6091,6 +6400,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6091
6400
|
cerebrasDefaultModelId,
|
|
6092
6401
|
cerebrasModels,
|
|
6093
6402
|
chutesDefaultModelId,
|
|
6403
|
+
chutesDefaultModelInfo,
|
|
6094
6404
|
chutesModels,
|
|
6095
6405
|
claudeCodeDefaultModelId,
|
|
6096
6406
|
claudeCodeModels,
|
|
@@ -6139,6 +6449,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6139
6449
|
getApiProtocol,
|
|
6140
6450
|
getClaudeCodeModelId,
|
|
6141
6451
|
getModelId,
|
|
6452
|
+
getProviderDefaultModelId,
|
|
6142
6453
|
gitPropertiesSchema,
|
|
6143
6454
|
glamaDefaultModelId,
|
|
6144
6455
|
glamaDefaultModelInfo,
|
|
@@ -6168,6 +6479,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6168
6479
|
isLanguage,
|
|
6169
6480
|
isLocalProvider,
|
|
6170
6481
|
isModelParameter,
|
|
6482
|
+
isNonBlockingAsk,
|
|
6171
6483
|
isProviderName,
|
|
6172
6484
|
isResumableAsk,
|
|
6173
6485
|
isSecretStateKey,
|
|
@@ -6187,6 +6499,8 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6187
6499
|
mcpInstallationMethodSchema,
|
|
6188
6500
|
mcpMarketplaceItemSchema,
|
|
6189
6501
|
mcpParameterSchema,
|
|
6502
|
+
minimaxDefaultModelId,
|
|
6503
|
+
minimaxModels,
|
|
6190
6504
|
mistralDefaultModelId,
|
|
6191
6505
|
mistralModels,
|
|
6192
6506
|
modeConfigSchema,
|
|
@@ -6198,6 +6512,7 @@ var commandExecutionStatusSchema = import_zod20.z.discriminatedUnion("status", [
|
|
|
6198
6512
|
modelParametersSchema,
|
|
6199
6513
|
moonshotDefaultModelId,
|
|
6200
6514
|
moonshotModels,
|
|
6515
|
+
nonBlockingAsks,
|
|
6201
6516
|
ollamaDefaultModelId,
|
|
6202
6517
|
ollamaDefaultModelInfo,
|
|
6203
6518
|
openAiModelInfoSaneDefaults,
|