@roo-code/types 1.53.0 → 1.55.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.js CHANGED
@@ -457,7 +457,9 @@ var providerNames = [
457
457
  "sambanova",
458
458
  "zai",
459
459
  "fireworks",
460
- "io-intelligence"
460
+ "featherless",
461
+ "io-intelligence",
462
+ "roo"
461
463
  ];
462
464
  var providerNamesSchema = z8.enum(providerNames);
463
465
  var providerSettingsEntrySchema = z8.object({
@@ -639,10 +641,16 @@ var zaiSchema = apiModelIdProviderModelSchema.extend({
639
641
  var fireworksSchema = apiModelIdProviderModelSchema.extend({
640
642
  fireworksApiKey: z8.string().optional()
641
643
  });
644
+ var featherlessSchema = apiModelIdProviderModelSchema.extend({
645
+ featherlessApiKey: z8.string().optional()
646
+ });
642
647
  var ioIntelligenceSchema = apiModelIdProviderModelSchema.extend({
643
648
  ioIntelligenceModelId: z8.string().optional(),
644
649
  ioIntelligenceApiKey: z8.string().optional()
645
650
  });
651
+ var rooSchema = apiModelIdProviderModelSchema.extend({
652
+ // No additional fields needed - uses cloud authentication
653
+ });
646
654
  var defaultSchema = z8.object({
647
655
  apiProvider: z8.undefined()
648
656
  });
@@ -677,7 +685,9 @@ var providerSettingsSchemaDiscriminated = z8.discriminatedUnion("apiProvider", [
677
685
  sambaNovaSchema.merge(z8.object({ apiProvider: z8.literal("sambanova") })),
678
686
  zaiSchema.merge(z8.object({ apiProvider: z8.literal("zai") })),
679
687
  fireworksSchema.merge(z8.object({ apiProvider: z8.literal("fireworks") })),
688
+ featherlessSchema.merge(z8.object({ apiProvider: z8.literal("featherless") })),
680
689
  ioIntelligenceSchema.merge(z8.object({ apiProvider: z8.literal("io-intelligence") })),
690
+ rooSchema.merge(z8.object({ apiProvider: z8.literal("roo") })),
681
691
  defaultSchema
682
692
  ]);
683
693
  var providerSettingsSchema = z8.object({
@@ -712,7 +722,9 @@ var providerSettingsSchema = z8.object({
712
722
  ...sambaNovaSchema.shape,
713
723
  ...zaiSchema.shape,
714
724
  ...fireworksSchema.shape,
725
+ ...featherlessSchema.shape,
715
726
  ...ioIntelligenceSchema.shape,
727
+ ...rooSchema.shape,
716
728
  ...codebaseIndexProviderSchema.shape
717
729
  });
718
730
  var providerSettingsWithIdSchema = providerSettingsSchema.extend({ id: z8.string().optional() });
@@ -1198,6 +1210,7 @@ var SECRET_STATE_KEYS = [
1198
1210
  "openAiNativeApiKey",
1199
1211
  "cerebrasApiKey",
1200
1212
  "deepSeekApiKey",
1213
+ "doubaoApiKey",
1201
1214
  "moonshotApiKey",
1202
1215
  "mistralApiKey",
1203
1216
  "unboundApiKey",
@@ -1213,7 +1226,9 @@ var SECRET_STATE_KEYS = [
1213
1226
  "codebaseIndexMistralApiKey",
1214
1227
  "huggingFaceApiKey",
1215
1228
  "sambaNovaApiKey",
1229
+ "zaiApiKey",
1216
1230
  "fireworksApiKey",
1231
+ "featherlessApiKey",
1217
1232
  "ioIntelligenceApiKey"
1218
1233
  ];
1219
1234
  var isSecretStateKey = (key) => SECRET_STATE_KEYS.includes(key);
@@ -1434,6 +1449,21 @@ var mcpExecutionStatusSchema = z16.discriminatedUnion("status", [
1434
1449
  })
1435
1450
  ]);
1436
1451
 
1452
+ // src/single-file-read-models.ts
1453
+ var SINGLE_FILE_READ_MODELS = /* @__PURE__ */ new Set(["roo/sonic"]);
1454
+ function shouldUseSingleFileRead(modelId) {
1455
+ if (SINGLE_FILE_READ_MODELS.has(modelId)) {
1456
+ return true;
1457
+ }
1458
+ const patterns = Array.from(SINGLE_FILE_READ_MODELS);
1459
+ for (const pattern of patterns) {
1460
+ if (pattern.endsWith("*") && modelId.startsWith(pattern.slice(0, -1))) {
1461
+ return true;
1462
+ }
1463
+ }
1464
+ return false;
1465
+ }
1466
+
1437
1467
  // src/task.ts
1438
1468
  import { z as z17 } from "zod";
1439
1469
  var TaskStatus = /* @__PURE__ */ ((TaskStatus2) => {
@@ -3989,6 +4019,18 @@ var vscodeLlmModels = {
3989
4019
  supportsToolCalling: true,
3990
4020
  maxInputTokens: 81638
3991
4021
  },
4022
+ "claude-4-sonnet": {
4023
+ contextWindow: 128e3,
4024
+ supportsImages: true,
4025
+ supportsPromptCache: false,
4026
+ inputPrice: 0,
4027
+ outputPrice: 0,
4028
+ family: "claude-sonnet-4",
4029
+ version: "claude-sonnet-4",
4030
+ name: "Claude Sonnet 4",
4031
+ supportsToolCalling: true,
4032
+ maxInputTokens: 111836
4033
+ },
3992
4034
  "gemini-2.0-flash-001": {
3993
4035
  contextWindow: 127827,
3994
4036
  supportsImages: true,
@@ -4002,7 +4044,7 @@ var vscodeLlmModels = {
4002
4044
  maxInputTokens: 127827
4003
4045
  },
4004
4046
  "gemini-2.5-pro": {
4005
- contextWindow: 63830,
4047
+ contextWindow: 128e3,
4006
4048
  supportsImages: true,
4007
4049
  supportsPromptCache: false,
4008
4050
  inputPrice: 0,
@@ -4011,10 +4053,10 @@ var vscodeLlmModels = {
4011
4053
  version: "gemini-2.5-pro-preview-03-25",
4012
4054
  name: "Gemini 2.5 Pro (Preview)",
4013
4055
  supportsToolCalling: true,
4014
- maxInputTokens: 63830
4056
+ maxInputTokens: 108637
4015
4057
  },
4016
4058
  "o4-mini": {
4017
- contextWindow: 111446,
4059
+ contextWindow: 128e3,
4018
4060
  supportsImages: false,
4019
4061
  supportsPromptCache: false,
4020
4062
  inputPrice: 0,
@@ -4023,10 +4065,10 @@ var vscodeLlmModels = {
4023
4065
  version: "o4-mini-2025-04-16",
4024
4066
  name: "o4-mini (Preview)",
4025
4067
  supportsToolCalling: true,
4026
- maxInputTokens: 111446
4068
+ maxInputTokens: 111452
4027
4069
  },
4028
4070
  "gpt-4.1": {
4029
- contextWindow: 111446,
4071
+ contextWindow: 128e3,
4030
4072
  supportsImages: true,
4031
4073
  supportsPromptCache: false,
4032
4074
  inputPrice: 0,
@@ -4035,7 +4077,31 @@ var vscodeLlmModels = {
4035
4077
  version: "gpt-4.1-2025-04-14",
4036
4078
  name: "GPT-4.1 (Preview)",
4037
4079
  supportsToolCalling: true,
4038
- maxInputTokens: 111446
4080
+ maxInputTokens: 111452
4081
+ },
4082
+ "gpt-5-mini": {
4083
+ contextWindow: 128e3,
4084
+ supportsImages: true,
4085
+ supportsPromptCache: false,
4086
+ inputPrice: 0,
4087
+ outputPrice: 0,
4088
+ family: "gpt-5-mini",
4089
+ version: "gpt-5-mini",
4090
+ name: "GPT-5 mini (Preview)",
4091
+ supportsToolCalling: true,
4092
+ maxInputTokens: 108637
4093
+ },
4094
+ "gpt-5": {
4095
+ contextWindow: 128e3,
4096
+ supportsImages: true,
4097
+ supportsPromptCache: false,
4098
+ inputPrice: 0,
4099
+ outputPrice: 0,
4100
+ family: "gpt-5",
4101
+ version: "gpt-5",
4102
+ name: "GPT-5 (Preview)",
4103
+ supportsToolCalling: true,
4104
+ maxInputTokens: 108637
4039
4105
  }
4040
4106
  };
4041
4107
 
@@ -4350,6 +4416,70 @@ var fireworksModels = {
4350
4416
  description: "OpenAI gpt-oss-120b: Production-grade, general-purpose model that fits on a single H100 GPU. Features complex reasoning, configurable effort, full chain-of-thought transparency, and supports function calling, tool use, and structured outputs."
4351
4417
  }
4352
4418
  };
4419
+
4420
+ // src/providers/roo.ts
4421
+ var rooDefaultModelId = "roo/sonic";
4422
+ var rooModels = {
4423
+ "roo/sonic": {
4424
+ maxTokens: 16384,
4425
+ contextWindow: 262144,
4426
+ supportsImages: false,
4427
+ supportsPromptCache: true,
4428
+ inputPrice: 0,
4429
+ outputPrice: 0,
4430
+ description: "A stealth reasoning model that is blazing fast and excels at agentic coding, accessible for free through Roo Code Cloud for a limited time. (Note: prompts and completions are logged by the model creator and used to improve the model.)"
4431
+ }
4432
+ };
4433
+
4434
+ // src/providers/featherless.ts
4435
+ var featherlessModels = {
4436
+ "deepseek-ai/DeepSeek-V3-0324": {
4437
+ maxTokens: 4096,
4438
+ contextWindow: 32678,
4439
+ supportsImages: false,
4440
+ supportsPromptCache: false,
4441
+ inputPrice: 0,
4442
+ outputPrice: 0,
4443
+ description: "DeepSeek V3 0324 model."
4444
+ },
4445
+ "deepseek-ai/DeepSeek-R1-0528": {
4446
+ maxTokens: 4096,
4447
+ contextWindow: 32678,
4448
+ supportsImages: false,
4449
+ supportsPromptCache: false,
4450
+ inputPrice: 0,
4451
+ outputPrice: 0,
4452
+ description: "DeepSeek R1 0528 model."
4453
+ },
4454
+ "moonshotai/Kimi-K2-Instruct": {
4455
+ maxTokens: 4096,
4456
+ contextWindow: 32678,
4457
+ supportsImages: false,
4458
+ supportsPromptCache: false,
4459
+ inputPrice: 0,
4460
+ outputPrice: 0,
4461
+ description: "Kimi K2 Instruct model."
4462
+ },
4463
+ "openai/gpt-oss-120b": {
4464
+ maxTokens: 4096,
4465
+ contextWindow: 32678,
4466
+ supportsImages: false,
4467
+ supportsPromptCache: false,
4468
+ inputPrice: 0,
4469
+ outputPrice: 0,
4470
+ description: "GPT-OSS 120B model."
4471
+ },
4472
+ "Qwen/Qwen3-Coder-480B-A35B-Instruct": {
4473
+ maxTokens: 4096,
4474
+ contextWindow: 32678,
4475
+ supportsImages: false,
4476
+ supportsPromptCache: false,
4477
+ inputPrice: 0,
4478
+ outputPrice: 0,
4479
+ description: "Qwen3 Coder 480B A35B Instruct model."
4480
+ }
4481
+ };
4482
+ var featherlessDefaultModelId = "deepseek-ai/DeepSeek-R1-0528";
4353
4483
  export {
4354
4484
  ANTHROPIC_DEFAULT_MAX_TOKENS,
4355
4485
  ANTHROPIC_STYLE_PROVIDERS,
@@ -4400,6 +4530,7 @@ export {
4400
4530
  PROVIDER_SETTINGS_KEYS,
4401
4531
  RooCodeEventName,
4402
4532
  SECRET_STATE_KEYS,
4533
+ SINGLE_FILE_READ_MODELS,
4403
4534
  TaskCommandName,
4404
4535
  TaskStatus,
4405
4536
  TelemetryEventName,
@@ -4447,6 +4578,8 @@ export {
4447
4578
  experimentIdsSchema,
4448
4579
  experimentsSchema,
4449
4580
  extendedReasoningEffortsSchema,
4581
+ featherlessDefaultModelId,
4582
+ featherlessModels,
4450
4583
  fireworksDefaultModelId,
4451
4584
  fireworksModels,
4452
4585
  followUpDataSchema,
@@ -4525,8 +4658,11 @@ export {
4525
4658
  rooCodeEventsSchema,
4526
4659
  rooCodeSettingsSchema,
4527
4660
  rooCodeTelemetryEventSchema,
4661
+ rooDefaultModelId,
4662
+ rooModels,
4528
4663
  sambaNovaDefaultModelId,
4529
4664
  sambaNovaModels,
4665
+ shouldUseSingleFileRead,
4530
4666
  staticAppPropertiesSchema,
4531
4667
  suggestionItemSchema,
4532
4668
  taskCommandSchema,