@pensar/apex 0.0.28-canary.0 → 0.0.29-canary.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/build/benchmark.js +110 -60
- package/build/index.js +110 -60
- package/build/pentest.js +110 -60
- package/build/quicktest.js +110 -60
- package/build/swarm.js +110 -60
- package/package.json +1 -1
package/build/benchmark.js
CHANGED
|
@@ -121014,8 +121014,8 @@ function createAnthropic(options = {}) {
|
|
|
121014
121014
|
}
|
|
121015
121015
|
var anthropic = createAnthropic();
|
|
121016
121016
|
|
|
121017
|
-
// src/core/ai/models.ts
|
|
121018
|
-
var
|
|
121017
|
+
// src/core/ai/models/anthropic.ts
|
|
121018
|
+
var ANTHROPIC_MODELS = [
|
|
121019
121019
|
{
|
|
121020
121020
|
id: "claude-haiku-4-5",
|
|
121021
121021
|
name: "Claude Haiku 4.5",
|
|
@@ -121099,55 +121099,11 @@ var AVAILABLE_MODELS = [
|
|
|
121099
121099
|
name: "Claude 3 Haiku (2024-03-07)",
|
|
121100
121100
|
provider: "anthropic",
|
|
121101
121101
|
contextLength: 200000
|
|
121102
|
-
}
|
|
121103
|
-
|
|
121104
|
-
|
|
121105
|
-
|
|
121106
|
-
|
|
121107
|
-
contextLength: 128000
|
|
121108
|
-
},
|
|
121109
|
-
{
|
|
121110
|
-
id: "gpt-4o",
|
|
121111
|
-
name: "GPT-4o",
|
|
121112
|
-
provider: "openai",
|
|
121113
|
-
contextLength: 128000
|
|
121114
|
-
},
|
|
121115
|
-
{
|
|
121116
|
-
id: "gpt-4o-mini",
|
|
121117
|
-
name: "GPT-4o Mini",
|
|
121118
|
-
provider: "openai",
|
|
121119
|
-
contextLength: 128000
|
|
121120
|
-
},
|
|
121121
|
-
{
|
|
121122
|
-
id: "gpt-4-turbo",
|
|
121123
|
-
name: "GPT-4 Turbo",
|
|
121124
|
-
provider: "openai",
|
|
121125
|
-
contextLength: 128000
|
|
121126
|
-
},
|
|
121127
|
-
{
|
|
121128
|
-
id: "gpt-4",
|
|
121129
|
-
name: "GPT-4",
|
|
121130
|
-
provider: "openai",
|
|
121131
|
-
contextLength: 8192
|
|
121132
|
-
},
|
|
121133
|
-
{
|
|
121134
|
-
id: "gpt-3.5-turbo",
|
|
121135
|
-
name: "GPT-3.5 Turbo",
|
|
121136
|
-
provider: "openai",
|
|
121137
|
-
contextLength: 16385
|
|
121138
|
-
},
|
|
121139
|
-
{
|
|
121140
|
-
id: "o1",
|
|
121141
|
-
name: "O1",
|
|
121142
|
-
provider: "openai",
|
|
121143
|
-
contextLength: 200000
|
|
121144
|
-
},
|
|
121145
|
-
{
|
|
121146
|
-
id: "o1-mini",
|
|
121147
|
-
name: "O1 Mini",
|
|
121148
|
-
provider: "openai",
|
|
121149
|
-
contextLength: 128000
|
|
121150
|
-
},
|
|
121102
|
+
}
|
|
121103
|
+
];
|
|
121104
|
+
|
|
121105
|
+
// src/core/ai/models/openrouter.ts
|
|
121106
|
+
var OPENROUTER_MODELS = [
|
|
121151
121107
|
{
|
|
121152
121108
|
id: "anthropic/claude-haiku-4.5",
|
|
121153
121109
|
name: "Claude Haiku 4.5 (OpenRouter)",
|
|
@@ -121267,28 +121223,62 @@ var AVAILABLE_MODELS = [
|
|
|
121267
121223
|
name: "Qwen 3 32B Instruct",
|
|
121268
121224
|
provider: "openrouter",
|
|
121269
121225
|
contextLength: 256000
|
|
121226
|
+
}
|
|
121227
|
+
];
|
|
121228
|
+
|
|
121229
|
+
// src/core/ai/models/bedrock.ts
|
|
121230
|
+
var BEDROCK_MODELS = [
|
|
121231
|
+
{
|
|
121232
|
+
id: "anthropic.claude-3-haiku-20240307-v1:0",
|
|
121233
|
+
name: "Claude 3 Haiku (Bedrock)",
|
|
121234
|
+
provider: "bedrock",
|
|
121235
|
+
contextLength: 200000
|
|
121270
121236
|
},
|
|
121271
121237
|
{
|
|
121272
|
-
id: "anthropic.claude-3-5-
|
|
121273
|
-
name: "Claude 3.5
|
|
121238
|
+
id: "anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
121239
|
+
name: "Claude 3.5 Haiku (Bedrock)",
|
|
121274
121240
|
provider: "bedrock",
|
|
121275
121241
|
contextLength: 200000
|
|
121276
121242
|
},
|
|
121277
121243
|
{
|
|
121278
|
-
id: "anthropic.claude-3-
|
|
121279
|
-
name: "Claude 3
|
|
121244
|
+
id: "anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
121245
|
+
name: "Claude 3.7 Sonnet (Bedrock)",
|
|
121280
121246
|
provider: "bedrock",
|
|
121281
121247
|
contextLength: 200000
|
|
121282
121248
|
},
|
|
121283
121249
|
{
|
|
121284
|
-
id: "anthropic.claude-
|
|
121285
|
-
name: "Claude
|
|
121250
|
+
id: "anthropic.claude-haiku-4-5-20251001-v1:0",
|
|
121251
|
+
name: "Claude Haiku 4.5 (Bedrock)",
|
|
121286
121252
|
provider: "bedrock",
|
|
121287
121253
|
contextLength: 200000
|
|
121288
121254
|
},
|
|
121289
121255
|
{
|
|
121290
|
-
id: "anthropic.claude-
|
|
121291
|
-
name: "Claude
|
|
121256
|
+
id: "anthropic.claude-opus-4-1-20250805-v1:0",
|
|
121257
|
+
name: "Claude Opus 4.1 (Bedrock)",
|
|
121258
|
+
provider: "bedrock",
|
|
121259
|
+
contextLength: 200000
|
|
121260
|
+
},
|
|
121261
|
+
{
|
|
121262
|
+
id: "anthropic.claude-opus-4-5-20251101-v1:0",
|
|
121263
|
+
name: "Claude Opus 4.5 (Bedrock)",
|
|
121264
|
+
provider: "bedrock",
|
|
121265
|
+
contextLength: 200000
|
|
121266
|
+
},
|
|
121267
|
+
{
|
|
121268
|
+
id: "anthropic.claude-opus-4-20250514-v1:0",
|
|
121269
|
+
name: "Claude Opus 4 (Bedrock)",
|
|
121270
|
+
provider: "bedrock",
|
|
121271
|
+
contextLength: 200000
|
|
121272
|
+
},
|
|
121273
|
+
{
|
|
121274
|
+
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
121275
|
+
name: "Claude Sonnet 4.5 (Bedrock)",
|
|
121276
|
+
provider: "bedrock",
|
|
121277
|
+
contextLength: 200000
|
|
121278
|
+
},
|
|
121279
|
+
{
|
|
121280
|
+
id: "anthropic.claude-sonnet-4-20250514-v1:0",
|
|
121281
|
+
name: "Claude Sonnet 4 (Bedrock)",
|
|
121292
121282
|
provider: "bedrock",
|
|
121293
121283
|
contextLength: 200000
|
|
121294
121284
|
},
|
|
@@ -121329,6 +121319,66 @@ var AVAILABLE_MODELS = [
|
|
|
121329
121319
|
contextLength: 128000
|
|
121330
121320
|
}
|
|
121331
121321
|
];
|
|
121322
|
+
|
|
121323
|
+
// src/core/ai/models/openai.ts
|
|
121324
|
+
var OPENAI_MODELS = [
|
|
121325
|
+
{
|
|
121326
|
+
id: "gpt-4.5-turbo",
|
|
121327
|
+
name: "GPT-4.5 Turbo",
|
|
121328
|
+
provider: "openai",
|
|
121329
|
+
contextLength: 128000
|
|
121330
|
+
},
|
|
121331
|
+
{
|
|
121332
|
+
id: "gpt-4o",
|
|
121333
|
+
name: "GPT-4o",
|
|
121334
|
+
provider: "openai",
|
|
121335
|
+
contextLength: 128000
|
|
121336
|
+
},
|
|
121337
|
+
{
|
|
121338
|
+
id: "gpt-4o-mini",
|
|
121339
|
+
name: "GPT-4o Mini",
|
|
121340
|
+
provider: "openai",
|
|
121341
|
+
contextLength: 128000
|
|
121342
|
+
},
|
|
121343
|
+
{
|
|
121344
|
+
id: "gpt-4-turbo",
|
|
121345
|
+
name: "GPT-4 Turbo",
|
|
121346
|
+
provider: "openai",
|
|
121347
|
+
contextLength: 128000
|
|
121348
|
+
},
|
|
121349
|
+
{
|
|
121350
|
+
id: "gpt-4",
|
|
121351
|
+
name: "GPT-4",
|
|
121352
|
+
provider: "openai",
|
|
121353
|
+
contextLength: 8192
|
|
121354
|
+
},
|
|
121355
|
+
{
|
|
121356
|
+
id: "gpt-3.5-turbo",
|
|
121357
|
+
name: "GPT-3.5 Turbo",
|
|
121358
|
+
provider: "openai",
|
|
121359
|
+
contextLength: 16385
|
|
121360
|
+
},
|
|
121361
|
+
{
|
|
121362
|
+
id: "o1",
|
|
121363
|
+
name: "O1",
|
|
121364
|
+
provider: "openai",
|
|
121365
|
+
contextLength: 200000
|
|
121366
|
+
},
|
|
121367
|
+
{
|
|
121368
|
+
id: "o1-mini",
|
|
121369
|
+
name: "O1 Mini",
|
|
121370
|
+
provider: "openai",
|
|
121371
|
+
contextLength: 128000
|
|
121372
|
+
}
|
|
121373
|
+
];
|
|
121374
|
+
|
|
121375
|
+
// src/core/ai/models/index.ts
|
|
121376
|
+
var AVAILABLE_MODELS = [
|
|
121377
|
+
...ANTHROPIC_MODELS,
|
|
121378
|
+
...OPENROUTER_MODELS,
|
|
121379
|
+
...BEDROCK_MODELS,
|
|
121380
|
+
...OPENAI_MODELS
|
|
121381
|
+
];
|
|
121332
121382
|
function getModelInfo(model) {
|
|
121333
121383
|
return AVAILABLE_MODELS.find((m) => m.id === model) ?? {
|
|
121334
121384
|
id: model,
|
|
@@ -121345,7 +121395,7 @@ function getProviderModel(model, authConfig) {
|
|
|
121345
121395
|
const openRouterAPIKey = authConfig?.openRouterAPIKey || process.env.OPENROUTER_API_KEY;
|
|
121346
121396
|
const bedrockAccessKeyId = authConfig?.bedrock?.accessKeyId || process.env.AWS_ACCESS_KEY_ID;
|
|
121347
121397
|
const bedrockSecretAccessKey = authConfig?.bedrock?.secretAccessKey || process.env.AWS_SECRET_ACCESS_KEY;
|
|
121348
|
-
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION
|
|
121398
|
+
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION;
|
|
121349
121399
|
const localBaseURL = authConfig?.local?.baseURL || process.env.LOCAL_MODEL_URL || "http://127.0.0.1:1234/v1";
|
|
121350
121400
|
let providerModel;
|
|
121351
121401
|
switch (provider) {
|
package/build/index.js
CHANGED
|
@@ -27213,8 +27213,8 @@ import os2 from "os";
|
|
|
27213
27213
|
// src/tui/agentProvider.tsx
|
|
27214
27214
|
var import_react10 = __toESM(require_react(), 1);
|
|
27215
27215
|
|
|
27216
|
-
// src/core/ai/models.ts
|
|
27217
|
-
var
|
|
27216
|
+
// src/core/ai/models/anthropic.ts
|
|
27217
|
+
var ANTHROPIC_MODELS = [
|
|
27218
27218
|
{
|
|
27219
27219
|
id: "claude-haiku-4-5",
|
|
27220
27220
|
name: "Claude Haiku 4.5",
|
|
@@ -27298,55 +27298,11 @@ var AVAILABLE_MODELS = [
|
|
|
27298
27298
|
name: "Claude 3 Haiku (2024-03-07)",
|
|
27299
27299
|
provider: "anthropic",
|
|
27300
27300
|
contextLength: 200000
|
|
27301
|
-
}
|
|
27302
|
-
|
|
27303
|
-
|
|
27304
|
-
|
|
27305
|
-
|
|
27306
|
-
contextLength: 128000
|
|
27307
|
-
},
|
|
27308
|
-
{
|
|
27309
|
-
id: "gpt-4o",
|
|
27310
|
-
name: "GPT-4o",
|
|
27311
|
-
provider: "openai",
|
|
27312
|
-
contextLength: 128000
|
|
27313
|
-
},
|
|
27314
|
-
{
|
|
27315
|
-
id: "gpt-4o-mini",
|
|
27316
|
-
name: "GPT-4o Mini",
|
|
27317
|
-
provider: "openai",
|
|
27318
|
-
contextLength: 128000
|
|
27319
|
-
},
|
|
27320
|
-
{
|
|
27321
|
-
id: "gpt-4-turbo",
|
|
27322
|
-
name: "GPT-4 Turbo",
|
|
27323
|
-
provider: "openai",
|
|
27324
|
-
contextLength: 128000
|
|
27325
|
-
},
|
|
27326
|
-
{
|
|
27327
|
-
id: "gpt-4",
|
|
27328
|
-
name: "GPT-4",
|
|
27329
|
-
provider: "openai",
|
|
27330
|
-
contextLength: 8192
|
|
27331
|
-
},
|
|
27332
|
-
{
|
|
27333
|
-
id: "gpt-3.5-turbo",
|
|
27334
|
-
name: "GPT-3.5 Turbo",
|
|
27335
|
-
provider: "openai",
|
|
27336
|
-
contextLength: 16385
|
|
27337
|
-
},
|
|
27338
|
-
{
|
|
27339
|
-
id: "o1",
|
|
27340
|
-
name: "O1",
|
|
27341
|
-
provider: "openai",
|
|
27342
|
-
contextLength: 200000
|
|
27343
|
-
},
|
|
27344
|
-
{
|
|
27345
|
-
id: "o1-mini",
|
|
27346
|
-
name: "O1 Mini",
|
|
27347
|
-
provider: "openai",
|
|
27348
|
-
contextLength: 128000
|
|
27349
|
-
},
|
|
27301
|
+
}
|
|
27302
|
+
];
|
|
27303
|
+
|
|
27304
|
+
// src/core/ai/models/openrouter.ts
|
|
27305
|
+
var OPENROUTER_MODELS = [
|
|
27350
27306
|
{
|
|
27351
27307
|
id: "anthropic/claude-haiku-4.5",
|
|
27352
27308
|
name: "Claude Haiku 4.5 (OpenRouter)",
|
|
@@ -27466,28 +27422,62 @@ var AVAILABLE_MODELS = [
|
|
|
27466
27422
|
name: "Qwen 3 32B Instruct",
|
|
27467
27423
|
provider: "openrouter",
|
|
27468
27424
|
contextLength: 256000
|
|
27425
|
+
}
|
|
27426
|
+
];
|
|
27427
|
+
|
|
27428
|
+
// src/core/ai/models/bedrock.ts
|
|
27429
|
+
var BEDROCK_MODELS = [
|
|
27430
|
+
{
|
|
27431
|
+
id: "anthropic.claude-3-haiku-20240307-v1:0",
|
|
27432
|
+
name: "Claude 3 Haiku (Bedrock)",
|
|
27433
|
+
provider: "bedrock",
|
|
27434
|
+
contextLength: 200000
|
|
27469
27435
|
},
|
|
27470
27436
|
{
|
|
27471
|
-
id: "anthropic.claude-3-5-
|
|
27472
|
-
name: "Claude 3.5
|
|
27437
|
+
id: "anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
27438
|
+
name: "Claude 3.5 Haiku (Bedrock)",
|
|
27473
27439
|
provider: "bedrock",
|
|
27474
27440
|
contextLength: 200000
|
|
27475
27441
|
},
|
|
27476
27442
|
{
|
|
27477
|
-
id: "anthropic.claude-3-
|
|
27478
|
-
name: "Claude 3
|
|
27443
|
+
id: "anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
27444
|
+
name: "Claude 3.7 Sonnet (Bedrock)",
|
|
27479
27445
|
provider: "bedrock",
|
|
27480
27446
|
contextLength: 200000
|
|
27481
27447
|
},
|
|
27482
27448
|
{
|
|
27483
|
-
id: "anthropic.claude-
|
|
27484
|
-
name: "Claude
|
|
27449
|
+
id: "anthropic.claude-haiku-4-5-20251001-v1:0",
|
|
27450
|
+
name: "Claude Haiku 4.5 (Bedrock)",
|
|
27485
27451
|
provider: "bedrock",
|
|
27486
27452
|
contextLength: 200000
|
|
27487
27453
|
},
|
|
27488
27454
|
{
|
|
27489
|
-
id: "anthropic.claude-
|
|
27490
|
-
name: "Claude
|
|
27455
|
+
id: "anthropic.claude-opus-4-1-20250805-v1:0",
|
|
27456
|
+
name: "Claude Opus 4.1 (Bedrock)",
|
|
27457
|
+
provider: "bedrock",
|
|
27458
|
+
contextLength: 200000
|
|
27459
|
+
},
|
|
27460
|
+
{
|
|
27461
|
+
id: "anthropic.claude-opus-4-5-20251101-v1:0",
|
|
27462
|
+
name: "Claude Opus 4.5 (Bedrock)",
|
|
27463
|
+
provider: "bedrock",
|
|
27464
|
+
contextLength: 200000
|
|
27465
|
+
},
|
|
27466
|
+
{
|
|
27467
|
+
id: "anthropic.claude-opus-4-20250514-v1:0",
|
|
27468
|
+
name: "Claude Opus 4 (Bedrock)",
|
|
27469
|
+
provider: "bedrock",
|
|
27470
|
+
contextLength: 200000
|
|
27471
|
+
},
|
|
27472
|
+
{
|
|
27473
|
+
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
27474
|
+
name: "Claude Sonnet 4.5 (Bedrock)",
|
|
27475
|
+
provider: "bedrock",
|
|
27476
|
+
contextLength: 200000
|
|
27477
|
+
},
|
|
27478
|
+
{
|
|
27479
|
+
id: "anthropic.claude-sonnet-4-20250514-v1:0",
|
|
27480
|
+
name: "Claude Sonnet 4 (Bedrock)",
|
|
27491
27481
|
provider: "bedrock",
|
|
27492
27482
|
contextLength: 200000
|
|
27493
27483
|
},
|
|
@@ -27528,6 +27518,66 @@ var AVAILABLE_MODELS = [
|
|
|
27528
27518
|
contextLength: 128000
|
|
27529
27519
|
}
|
|
27530
27520
|
];
|
|
27521
|
+
|
|
27522
|
+
// src/core/ai/models/openai.ts
|
|
27523
|
+
var OPENAI_MODELS = [
|
|
27524
|
+
{
|
|
27525
|
+
id: "gpt-4.5-turbo",
|
|
27526
|
+
name: "GPT-4.5 Turbo",
|
|
27527
|
+
provider: "openai",
|
|
27528
|
+
contextLength: 128000
|
|
27529
|
+
},
|
|
27530
|
+
{
|
|
27531
|
+
id: "gpt-4o",
|
|
27532
|
+
name: "GPT-4o",
|
|
27533
|
+
provider: "openai",
|
|
27534
|
+
contextLength: 128000
|
|
27535
|
+
},
|
|
27536
|
+
{
|
|
27537
|
+
id: "gpt-4o-mini",
|
|
27538
|
+
name: "GPT-4o Mini",
|
|
27539
|
+
provider: "openai",
|
|
27540
|
+
contextLength: 128000
|
|
27541
|
+
},
|
|
27542
|
+
{
|
|
27543
|
+
id: "gpt-4-turbo",
|
|
27544
|
+
name: "GPT-4 Turbo",
|
|
27545
|
+
provider: "openai",
|
|
27546
|
+
contextLength: 128000
|
|
27547
|
+
},
|
|
27548
|
+
{
|
|
27549
|
+
id: "gpt-4",
|
|
27550
|
+
name: "GPT-4",
|
|
27551
|
+
provider: "openai",
|
|
27552
|
+
contextLength: 8192
|
|
27553
|
+
},
|
|
27554
|
+
{
|
|
27555
|
+
id: "gpt-3.5-turbo",
|
|
27556
|
+
name: "GPT-3.5 Turbo",
|
|
27557
|
+
provider: "openai",
|
|
27558
|
+
contextLength: 16385
|
|
27559
|
+
},
|
|
27560
|
+
{
|
|
27561
|
+
id: "o1",
|
|
27562
|
+
name: "O1",
|
|
27563
|
+
provider: "openai",
|
|
27564
|
+
contextLength: 200000
|
|
27565
|
+
},
|
|
27566
|
+
{
|
|
27567
|
+
id: "o1-mini",
|
|
27568
|
+
name: "O1 Mini",
|
|
27569
|
+
provider: "openai",
|
|
27570
|
+
contextLength: 128000
|
|
27571
|
+
}
|
|
27572
|
+
];
|
|
27573
|
+
|
|
27574
|
+
// src/core/ai/models/index.ts
|
|
27575
|
+
var AVAILABLE_MODELS = [
|
|
27576
|
+
...ANTHROPIC_MODELS,
|
|
27577
|
+
...OPENROUTER_MODELS,
|
|
27578
|
+
...BEDROCK_MODELS,
|
|
27579
|
+
...OPENAI_MODELS
|
|
27580
|
+
];
|
|
27531
27581
|
function getModelInfo(model) {
|
|
27532
27582
|
return AVAILABLE_MODELS.find((m) => m.id === model) ?? {
|
|
27533
27583
|
id: model,
|
|
@@ -64633,7 +64683,7 @@ function getProviderModel(model, authConfig) {
|
|
|
64633
64683
|
const openRouterAPIKey = authConfig?.openRouterAPIKey || process.env.OPENROUTER_API_KEY;
|
|
64634
64684
|
const bedrockAccessKeyId = authConfig?.bedrock?.accessKeyId || process.env.AWS_ACCESS_KEY_ID;
|
|
64635
64685
|
const bedrockSecretAccessKey = authConfig?.bedrock?.secretAccessKey || process.env.AWS_SECRET_ACCESS_KEY;
|
|
64636
|
-
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION
|
|
64686
|
+
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION;
|
|
64637
64687
|
const localBaseURL = authConfig?.local?.baseURL || process.env.LOCAL_MODEL_URL || "http://127.0.0.1:1234/v1";
|
|
64638
64688
|
let providerModel;
|
|
64639
64689
|
switch (provider) {
|
package/build/pentest.js
CHANGED
|
@@ -39333,8 +39333,8 @@ function createAnthropic(options = {}) {
|
|
|
39333
39333
|
}
|
|
39334
39334
|
var anthropic = createAnthropic();
|
|
39335
39335
|
|
|
39336
|
-
// src/core/ai/models.ts
|
|
39337
|
-
var
|
|
39336
|
+
// src/core/ai/models/anthropic.ts
|
|
39337
|
+
var ANTHROPIC_MODELS = [
|
|
39338
39338
|
{
|
|
39339
39339
|
id: "claude-haiku-4-5",
|
|
39340
39340
|
name: "Claude Haiku 4.5",
|
|
@@ -39418,55 +39418,11 @@ var AVAILABLE_MODELS = [
|
|
|
39418
39418
|
name: "Claude 3 Haiku (2024-03-07)",
|
|
39419
39419
|
provider: "anthropic",
|
|
39420
39420
|
contextLength: 200000
|
|
39421
|
-
}
|
|
39422
|
-
|
|
39423
|
-
|
|
39424
|
-
|
|
39425
|
-
|
|
39426
|
-
contextLength: 128000
|
|
39427
|
-
},
|
|
39428
|
-
{
|
|
39429
|
-
id: "gpt-4o",
|
|
39430
|
-
name: "GPT-4o",
|
|
39431
|
-
provider: "openai",
|
|
39432
|
-
contextLength: 128000
|
|
39433
|
-
},
|
|
39434
|
-
{
|
|
39435
|
-
id: "gpt-4o-mini",
|
|
39436
|
-
name: "GPT-4o Mini",
|
|
39437
|
-
provider: "openai",
|
|
39438
|
-
contextLength: 128000
|
|
39439
|
-
},
|
|
39440
|
-
{
|
|
39441
|
-
id: "gpt-4-turbo",
|
|
39442
|
-
name: "GPT-4 Turbo",
|
|
39443
|
-
provider: "openai",
|
|
39444
|
-
contextLength: 128000
|
|
39445
|
-
},
|
|
39446
|
-
{
|
|
39447
|
-
id: "gpt-4",
|
|
39448
|
-
name: "GPT-4",
|
|
39449
|
-
provider: "openai",
|
|
39450
|
-
contextLength: 8192
|
|
39451
|
-
},
|
|
39452
|
-
{
|
|
39453
|
-
id: "gpt-3.5-turbo",
|
|
39454
|
-
name: "GPT-3.5 Turbo",
|
|
39455
|
-
provider: "openai",
|
|
39456
|
-
contextLength: 16385
|
|
39457
|
-
},
|
|
39458
|
-
{
|
|
39459
|
-
id: "o1",
|
|
39460
|
-
name: "O1",
|
|
39461
|
-
provider: "openai",
|
|
39462
|
-
contextLength: 200000
|
|
39463
|
-
},
|
|
39464
|
-
{
|
|
39465
|
-
id: "o1-mini",
|
|
39466
|
-
name: "O1 Mini",
|
|
39467
|
-
provider: "openai",
|
|
39468
|
-
contextLength: 128000
|
|
39469
|
-
},
|
|
39421
|
+
}
|
|
39422
|
+
];
|
|
39423
|
+
|
|
39424
|
+
// src/core/ai/models/openrouter.ts
|
|
39425
|
+
var OPENROUTER_MODELS = [
|
|
39470
39426
|
{
|
|
39471
39427
|
id: "anthropic/claude-haiku-4.5",
|
|
39472
39428
|
name: "Claude Haiku 4.5 (OpenRouter)",
|
|
@@ -39586,28 +39542,62 @@ var AVAILABLE_MODELS = [
|
|
|
39586
39542
|
name: "Qwen 3 32B Instruct",
|
|
39587
39543
|
provider: "openrouter",
|
|
39588
39544
|
contextLength: 256000
|
|
39545
|
+
}
|
|
39546
|
+
];
|
|
39547
|
+
|
|
39548
|
+
// src/core/ai/models/bedrock.ts
|
|
39549
|
+
var BEDROCK_MODELS = [
|
|
39550
|
+
{
|
|
39551
|
+
id: "anthropic.claude-3-haiku-20240307-v1:0",
|
|
39552
|
+
name: "Claude 3 Haiku (Bedrock)",
|
|
39553
|
+
provider: "bedrock",
|
|
39554
|
+
contextLength: 200000
|
|
39589
39555
|
},
|
|
39590
39556
|
{
|
|
39591
|
-
id: "anthropic.claude-3-5-
|
|
39592
|
-
name: "Claude 3.5
|
|
39557
|
+
id: "anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
39558
|
+
name: "Claude 3.5 Haiku (Bedrock)",
|
|
39593
39559
|
provider: "bedrock",
|
|
39594
39560
|
contextLength: 200000
|
|
39595
39561
|
},
|
|
39596
39562
|
{
|
|
39597
|
-
id: "anthropic.claude-3-
|
|
39598
|
-
name: "Claude 3
|
|
39563
|
+
id: "anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
39564
|
+
name: "Claude 3.7 Sonnet (Bedrock)",
|
|
39599
39565
|
provider: "bedrock",
|
|
39600
39566
|
contextLength: 200000
|
|
39601
39567
|
},
|
|
39602
39568
|
{
|
|
39603
|
-
id: "anthropic.claude-
|
|
39604
|
-
name: "Claude
|
|
39569
|
+
id: "anthropic.claude-haiku-4-5-20251001-v1:0",
|
|
39570
|
+
name: "Claude Haiku 4.5 (Bedrock)",
|
|
39605
39571
|
provider: "bedrock",
|
|
39606
39572
|
contextLength: 200000
|
|
39607
39573
|
},
|
|
39608
39574
|
{
|
|
39609
|
-
id: "anthropic.claude-
|
|
39610
|
-
name: "Claude
|
|
39575
|
+
id: "anthropic.claude-opus-4-1-20250805-v1:0",
|
|
39576
|
+
name: "Claude Opus 4.1 (Bedrock)",
|
|
39577
|
+
provider: "bedrock",
|
|
39578
|
+
contextLength: 200000
|
|
39579
|
+
},
|
|
39580
|
+
{
|
|
39581
|
+
id: "anthropic.claude-opus-4-5-20251101-v1:0",
|
|
39582
|
+
name: "Claude Opus 4.5 (Bedrock)",
|
|
39583
|
+
provider: "bedrock",
|
|
39584
|
+
contextLength: 200000
|
|
39585
|
+
},
|
|
39586
|
+
{
|
|
39587
|
+
id: "anthropic.claude-opus-4-20250514-v1:0",
|
|
39588
|
+
name: "Claude Opus 4 (Bedrock)",
|
|
39589
|
+
provider: "bedrock",
|
|
39590
|
+
contextLength: 200000
|
|
39591
|
+
},
|
|
39592
|
+
{
|
|
39593
|
+
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
39594
|
+
name: "Claude Sonnet 4.5 (Bedrock)",
|
|
39595
|
+
provider: "bedrock",
|
|
39596
|
+
contextLength: 200000
|
|
39597
|
+
},
|
|
39598
|
+
{
|
|
39599
|
+
id: "anthropic.claude-sonnet-4-20250514-v1:0",
|
|
39600
|
+
name: "Claude Sonnet 4 (Bedrock)",
|
|
39611
39601
|
provider: "bedrock",
|
|
39612
39602
|
contextLength: 200000
|
|
39613
39603
|
},
|
|
@@ -39648,6 +39638,66 @@ var AVAILABLE_MODELS = [
|
|
|
39648
39638
|
contextLength: 128000
|
|
39649
39639
|
}
|
|
39650
39640
|
];
|
|
39641
|
+
|
|
39642
|
+
// src/core/ai/models/openai.ts
|
|
39643
|
+
var OPENAI_MODELS = [
|
|
39644
|
+
{
|
|
39645
|
+
id: "gpt-4.5-turbo",
|
|
39646
|
+
name: "GPT-4.5 Turbo",
|
|
39647
|
+
provider: "openai",
|
|
39648
|
+
contextLength: 128000
|
|
39649
|
+
},
|
|
39650
|
+
{
|
|
39651
|
+
id: "gpt-4o",
|
|
39652
|
+
name: "GPT-4o",
|
|
39653
|
+
provider: "openai",
|
|
39654
|
+
contextLength: 128000
|
|
39655
|
+
},
|
|
39656
|
+
{
|
|
39657
|
+
id: "gpt-4o-mini",
|
|
39658
|
+
name: "GPT-4o Mini",
|
|
39659
|
+
provider: "openai",
|
|
39660
|
+
contextLength: 128000
|
|
39661
|
+
},
|
|
39662
|
+
{
|
|
39663
|
+
id: "gpt-4-turbo",
|
|
39664
|
+
name: "GPT-4 Turbo",
|
|
39665
|
+
provider: "openai",
|
|
39666
|
+
contextLength: 128000
|
|
39667
|
+
},
|
|
39668
|
+
{
|
|
39669
|
+
id: "gpt-4",
|
|
39670
|
+
name: "GPT-4",
|
|
39671
|
+
provider: "openai",
|
|
39672
|
+
contextLength: 8192
|
|
39673
|
+
},
|
|
39674
|
+
{
|
|
39675
|
+
id: "gpt-3.5-turbo",
|
|
39676
|
+
name: "GPT-3.5 Turbo",
|
|
39677
|
+
provider: "openai",
|
|
39678
|
+
contextLength: 16385
|
|
39679
|
+
},
|
|
39680
|
+
{
|
|
39681
|
+
id: "o1",
|
|
39682
|
+
name: "O1",
|
|
39683
|
+
provider: "openai",
|
|
39684
|
+
contextLength: 200000
|
|
39685
|
+
},
|
|
39686
|
+
{
|
|
39687
|
+
id: "o1-mini",
|
|
39688
|
+
name: "O1 Mini",
|
|
39689
|
+
provider: "openai",
|
|
39690
|
+
contextLength: 128000
|
|
39691
|
+
}
|
|
39692
|
+
];
|
|
39693
|
+
|
|
39694
|
+
// src/core/ai/models/index.ts
|
|
39695
|
+
var AVAILABLE_MODELS = [
|
|
39696
|
+
...ANTHROPIC_MODELS,
|
|
39697
|
+
...OPENROUTER_MODELS,
|
|
39698
|
+
...BEDROCK_MODELS,
|
|
39699
|
+
...OPENAI_MODELS
|
|
39700
|
+
];
|
|
39651
39701
|
function getModelInfo(model) {
|
|
39652
39702
|
return AVAILABLE_MODELS.find((m) => m.id === model) ?? {
|
|
39653
39703
|
id: model,
|
|
@@ -39664,7 +39714,7 @@ function getProviderModel(model, authConfig) {
|
|
|
39664
39714
|
const openRouterAPIKey = authConfig?.openRouterAPIKey || process.env.OPENROUTER_API_KEY;
|
|
39665
39715
|
const bedrockAccessKeyId = authConfig?.bedrock?.accessKeyId || process.env.AWS_ACCESS_KEY_ID;
|
|
39666
39716
|
const bedrockSecretAccessKey = authConfig?.bedrock?.secretAccessKey || process.env.AWS_SECRET_ACCESS_KEY;
|
|
39667
|
-
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION
|
|
39717
|
+
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION;
|
|
39668
39718
|
const localBaseURL = authConfig?.local?.baseURL || process.env.LOCAL_MODEL_URL || "http://127.0.0.1:1234/v1";
|
|
39669
39719
|
let providerModel;
|
|
39670
39720
|
switch (provider) {
|
package/build/quicktest.js
CHANGED
|
@@ -39333,8 +39333,8 @@ function createAnthropic(options = {}) {
|
|
|
39333
39333
|
}
|
|
39334
39334
|
var anthropic = createAnthropic();
|
|
39335
39335
|
|
|
39336
|
-
// src/core/ai/models.ts
|
|
39337
|
-
var
|
|
39336
|
+
// src/core/ai/models/anthropic.ts
|
|
39337
|
+
var ANTHROPIC_MODELS = [
|
|
39338
39338
|
{
|
|
39339
39339
|
id: "claude-haiku-4-5",
|
|
39340
39340
|
name: "Claude Haiku 4.5",
|
|
@@ -39418,55 +39418,11 @@ var AVAILABLE_MODELS = [
|
|
|
39418
39418
|
name: "Claude 3 Haiku (2024-03-07)",
|
|
39419
39419
|
provider: "anthropic",
|
|
39420
39420
|
contextLength: 200000
|
|
39421
|
-
}
|
|
39422
|
-
|
|
39423
|
-
|
|
39424
|
-
|
|
39425
|
-
|
|
39426
|
-
contextLength: 128000
|
|
39427
|
-
},
|
|
39428
|
-
{
|
|
39429
|
-
id: "gpt-4o",
|
|
39430
|
-
name: "GPT-4o",
|
|
39431
|
-
provider: "openai",
|
|
39432
|
-
contextLength: 128000
|
|
39433
|
-
},
|
|
39434
|
-
{
|
|
39435
|
-
id: "gpt-4o-mini",
|
|
39436
|
-
name: "GPT-4o Mini",
|
|
39437
|
-
provider: "openai",
|
|
39438
|
-
contextLength: 128000
|
|
39439
|
-
},
|
|
39440
|
-
{
|
|
39441
|
-
id: "gpt-4-turbo",
|
|
39442
|
-
name: "GPT-4 Turbo",
|
|
39443
|
-
provider: "openai",
|
|
39444
|
-
contextLength: 128000
|
|
39445
|
-
},
|
|
39446
|
-
{
|
|
39447
|
-
id: "gpt-4",
|
|
39448
|
-
name: "GPT-4",
|
|
39449
|
-
provider: "openai",
|
|
39450
|
-
contextLength: 8192
|
|
39451
|
-
},
|
|
39452
|
-
{
|
|
39453
|
-
id: "gpt-3.5-turbo",
|
|
39454
|
-
name: "GPT-3.5 Turbo",
|
|
39455
|
-
provider: "openai",
|
|
39456
|
-
contextLength: 16385
|
|
39457
|
-
},
|
|
39458
|
-
{
|
|
39459
|
-
id: "o1",
|
|
39460
|
-
name: "O1",
|
|
39461
|
-
provider: "openai",
|
|
39462
|
-
contextLength: 200000
|
|
39463
|
-
},
|
|
39464
|
-
{
|
|
39465
|
-
id: "o1-mini",
|
|
39466
|
-
name: "O1 Mini",
|
|
39467
|
-
provider: "openai",
|
|
39468
|
-
contextLength: 128000
|
|
39469
|
-
},
|
|
39421
|
+
}
|
|
39422
|
+
];
|
|
39423
|
+
|
|
39424
|
+
// src/core/ai/models/openrouter.ts
|
|
39425
|
+
var OPENROUTER_MODELS = [
|
|
39470
39426
|
{
|
|
39471
39427
|
id: "anthropic/claude-haiku-4.5",
|
|
39472
39428
|
name: "Claude Haiku 4.5 (OpenRouter)",
|
|
@@ -39586,28 +39542,62 @@ var AVAILABLE_MODELS = [
|
|
|
39586
39542
|
name: "Qwen 3 32B Instruct",
|
|
39587
39543
|
provider: "openrouter",
|
|
39588
39544
|
contextLength: 256000
|
|
39545
|
+
}
|
|
39546
|
+
];
|
|
39547
|
+
|
|
39548
|
+
// src/core/ai/models/bedrock.ts
|
|
39549
|
+
var BEDROCK_MODELS = [
|
|
39550
|
+
{
|
|
39551
|
+
id: "anthropic.claude-3-haiku-20240307-v1:0",
|
|
39552
|
+
name: "Claude 3 Haiku (Bedrock)",
|
|
39553
|
+
provider: "bedrock",
|
|
39554
|
+
contextLength: 200000
|
|
39589
39555
|
},
|
|
39590
39556
|
{
|
|
39591
|
-
id: "anthropic.claude-3-5-
|
|
39592
|
-
name: "Claude 3.5
|
|
39557
|
+
id: "anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
39558
|
+
name: "Claude 3.5 Haiku (Bedrock)",
|
|
39593
39559
|
provider: "bedrock",
|
|
39594
39560
|
contextLength: 200000
|
|
39595
39561
|
},
|
|
39596
39562
|
{
|
|
39597
|
-
id: "anthropic.claude-3-
|
|
39598
|
-
name: "Claude 3
|
|
39563
|
+
id: "anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
39564
|
+
name: "Claude 3.7 Sonnet (Bedrock)",
|
|
39599
39565
|
provider: "bedrock",
|
|
39600
39566
|
contextLength: 200000
|
|
39601
39567
|
},
|
|
39602
39568
|
{
|
|
39603
|
-
id: "anthropic.claude-
|
|
39604
|
-
name: "Claude
|
|
39569
|
+
id: "anthropic.claude-haiku-4-5-20251001-v1:0",
|
|
39570
|
+
name: "Claude Haiku 4.5 (Bedrock)",
|
|
39605
39571
|
provider: "bedrock",
|
|
39606
39572
|
contextLength: 200000
|
|
39607
39573
|
},
|
|
39608
39574
|
{
|
|
39609
|
-
id: "anthropic.claude-
|
|
39610
|
-
name: "Claude
|
|
39575
|
+
id: "anthropic.claude-opus-4-1-20250805-v1:0",
|
|
39576
|
+
name: "Claude Opus 4.1 (Bedrock)",
|
|
39577
|
+
provider: "bedrock",
|
|
39578
|
+
contextLength: 200000
|
|
39579
|
+
},
|
|
39580
|
+
{
|
|
39581
|
+
id: "anthropic.claude-opus-4-5-20251101-v1:0",
|
|
39582
|
+
name: "Claude Opus 4.5 (Bedrock)",
|
|
39583
|
+
provider: "bedrock",
|
|
39584
|
+
contextLength: 200000
|
|
39585
|
+
},
|
|
39586
|
+
{
|
|
39587
|
+
id: "anthropic.claude-opus-4-20250514-v1:0",
|
|
39588
|
+
name: "Claude Opus 4 (Bedrock)",
|
|
39589
|
+
provider: "bedrock",
|
|
39590
|
+
contextLength: 200000
|
|
39591
|
+
},
|
|
39592
|
+
{
|
|
39593
|
+
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
39594
|
+
name: "Claude Sonnet 4.5 (Bedrock)",
|
|
39595
|
+
provider: "bedrock",
|
|
39596
|
+
contextLength: 200000
|
|
39597
|
+
},
|
|
39598
|
+
{
|
|
39599
|
+
id: "anthropic.claude-sonnet-4-20250514-v1:0",
|
|
39600
|
+
name: "Claude Sonnet 4 (Bedrock)",
|
|
39611
39601
|
provider: "bedrock",
|
|
39612
39602
|
contextLength: 200000
|
|
39613
39603
|
},
|
|
@@ -39648,6 +39638,66 @@ var AVAILABLE_MODELS = [
|
|
|
39648
39638
|
contextLength: 128000
|
|
39649
39639
|
}
|
|
39650
39640
|
];
|
|
39641
|
+
|
|
39642
|
+
// src/core/ai/models/openai.ts
|
|
39643
|
+
var OPENAI_MODELS = [
|
|
39644
|
+
{
|
|
39645
|
+
id: "gpt-4.5-turbo",
|
|
39646
|
+
name: "GPT-4.5 Turbo",
|
|
39647
|
+
provider: "openai",
|
|
39648
|
+
contextLength: 128000
|
|
39649
|
+
},
|
|
39650
|
+
{
|
|
39651
|
+
id: "gpt-4o",
|
|
39652
|
+
name: "GPT-4o",
|
|
39653
|
+
provider: "openai",
|
|
39654
|
+
contextLength: 128000
|
|
39655
|
+
},
|
|
39656
|
+
{
|
|
39657
|
+
id: "gpt-4o-mini",
|
|
39658
|
+
name: "GPT-4o Mini",
|
|
39659
|
+
provider: "openai",
|
|
39660
|
+
contextLength: 128000
|
|
39661
|
+
},
|
|
39662
|
+
{
|
|
39663
|
+
id: "gpt-4-turbo",
|
|
39664
|
+
name: "GPT-4 Turbo",
|
|
39665
|
+
provider: "openai",
|
|
39666
|
+
contextLength: 128000
|
|
39667
|
+
},
|
|
39668
|
+
{
|
|
39669
|
+
id: "gpt-4",
|
|
39670
|
+
name: "GPT-4",
|
|
39671
|
+
provider: "openai",
|
|
39672
|
+
contextLength: 8192
|
|
39673
|
+
},
|
|
39674
|
+
{
|
|
39675
|
+
id: "gpt-3.5-turbo",
|
|
39676
|
+
name: "GPT-3.5 Turbo",
|
|
39677
|
+
provider: "openai",
|
|
39678
|
+
contextLength: 16385
|
|
39679
|
+
},
|
|
39680
|
+
{
|
|
39681
|
+
id: "o1",
|
|
39682
|
+
name: "O1",
|
|
39683
|
+
provider: "openai",
|
|
39684
|
+
contextLength: 200000
|
|
39685
|
+
},
|
|
39686
|
+
{
|
|
39687
|
+
id: "o1-mini",
|
|
39688
|
+
name: "O1 Mini",
|
|
39689
|
+
provider: "openai",
|
|
39690
|
+
contextLength: 128000
|
|
39691
|
+
}
|
|
39692
|
+
];
|
|
39693
|
+
|
|
39694
|
+
// src/core/ai/models/index.ts
|
|
39695
|
+
var AVAILABLE_MODELS = [
|
|
39696
|
+
...ANTHROPIC_MODELS,
|
|
39697
|
+
...OPENROUTER_MODELS,
|
|
39698
|
+
...BEDROCK_MODELS,
|
|
39699
|
+
...OPENAI_MODELS
|
|
39700
|
+
];
|
|
39651
39701
|
function getModelInfo(model) {
|
|
39652
39702
|
return AVAILABLE_MODELS.find((m) => m.id === model) ?? {
|
|
39653
39703
|
id: model,
|
|
@@ -39664,7 +39714,7 @@ function getProviderModel(model, authConfig) {
|
|
|
39664
39714
|
const openRouterAPIKey = authConfig?.openRouterAPIKey || process.env.OPENROUTER_API_KEY;
|
|
39665
39715
|
const bedrockAccessKeyId = authConfig?.bedrock?.accessKeyId || process.env.AWS_ACCESS_KEY_ID;
|
|
39666
39716
|
const bedrockSecretAccessKey = authConfig?.bedrock?.secretAccessKey || process.env.AWS_SECRET_ACCESS_KEY;
|
|
39667
|
-
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION
|
|
39717
|
+
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION;
|
|
39668
39718
|
const localBaseURL = authConfig?.local?.baseURL || process.env.LOCAL_MODEL_URL || "http://127.0.0.1:1234/v1";
|
|
39669
39719
|
let providerModel;
|
|
39670
39720
|
switch (provider) {
|
package/build/swarm.js
CHANGED
|
@@ -39333,8 +39333,8 @@ function createAnthropic(options = {}) {
|
|
|
39333
39333
|
}
|
|
39334
39334
|
var anthropic = createAnthropic();
|
|
39335
39335
|
|
|
39336
|
-
// src/core/ai/models.ts
|
|
39337
|
-
var
|
|
39336
|
+
// src/core/ai/models/anthropic.ts
|
|
39337
|
+
var ANTHROPIC_MODELS = [
|
|
39338
39338
|
{
|
|
39339
39339
|
id: "claude-haiku-4-5",
|
|
39340
39340
|
name: "Claude Haiku 4.5",
|
|
@@ -39418,55 +39418,11 @@ var AVAILABLE_MODELS = [
|
|
|
39418
39418
|
name: "Claude 3 Haiku (2024-03-07)",
|
|
39419
39419
|
provider: "anthropic",
|
|
39420
39420
|
contextLength: 200000
|
|
39421
|
-
}
|
|
39422
|
-
|
|
39423
|
-
|
|
39424
|
-
|
|
39425
|
-
|
|
39426
|
-
contextLength: 128000
|
|
39427
|
-
},
|
|
39428
|
-
{
|
|
39429
|
-
id: "gpt-4o",
|
|
39430
|
-
name: "GPT-4o",
|
|
39431
|
-
provider: "openai",
|
|
39432
|
-
contextLength: 128000
|
|
39433
|
-
},
|
|
39434
|
-
{
|
|
39435
|
-
id: "gpt-4o-mini",
|
|
39436
|
-
name: "GPT-4o Mini",
|
|
39437
|
-
provider: "openai",
|
|
39438
|
-
contextLength: 128000
|
|
39439
|
-
},
|
|
39440
|
-
{
|
|
39441
|
-
id: "gpt-4-turbo",
|
|
39442
|
-
name: "GPT-4 Turbo",
|
|
39443
|
-
provider: "openai",
|
|
39444
|
-
contextLength: 128000
|
|
39445
|
-
},
|
|
39446
|
-
{
|
|
39447
|
-
id: "gpt-4",
|
|
39448
|
-
name: "GPT-4",
|
|
39449
|
-
provider: "openai",
|
|
39450
|
-
contextLength: 8192
|
|
39451
|
-
},
|
|
39452
|
-
{
|
|
39453
|
-
id: "gpt-3.5-turbo",
|
|
39454
|
-
name: "GPT-3.5 Turbo",
|
|
39455
|
-
provider: "openai",
|
|
39456
|
-
contextLength: 16385
|
|
39457
|
-
},
|
|
39458
|
-
{
|
|
39459
|
-
id: "o1",
|
|
39460
|
-
name: "O1",
|
|
39461
|
-
provider: "openai",
|
|
39462
|
-
contextLength: 200000
|
|
39463
|
-
},
|
|
39464
|
-
{
|
|
39465
|
-
id: "o1-mini",
|
|
39466
|
-
name: "O1 Mini",
|
|
39467
|
-
provider: "openai",
|
|
39468
|
-
contextLength: 128000
|
|
39469
|
-
},
|
|
39421
|
+
}
|
|
39422
|
+
];
|
|
39423
|
+
|
|
39424
|
+
// src/core/ai/models/openrouter.ts
|
|
39425
|
+
var OPENROUTER_MODELS = [
|
|
39470
39426
|
{
|
|
39471
39427
|
id: "anthropic/claude-haiku-4.5",
|
|
39472
39428
|
name: "Claude Haiku 4.5 (OpenRouter)",
|
|
@@ -39586,28 +39542,62 @@ var AVAILABLE_MODELS = [
|
|
|
39586
39542
|
name: "Qwen 3 32B Instruct",
|
|
39587
39543
|
provider: "openrouter",
|
|
39588
39544
|
contextLength: 256000
|
|
39545
|
+
}
|
|
39546
|
+
];
|
|
39547
|
+
|
|
39548
|
+
// src/core/ai/models/bedrock.ts
|
|
39549
|
+
var BEDROCK_MODELS = [
|
|
39550
|
+
{
|
|
39551
|
+
id: "anthropic.claude-3-haiku-20240307-v1:0",
|
|
39552
|
+
name: "Claude 3 Haiku (Bedrock)",
|
|
39553
|
+
provider: "bedrock",
|
|
39554
|
+
contextLength: 200000
|
|
39589
39555
|
},
|
|
39590
39556
|
{
|
|
39591
|
-
id: "anthropic.claude-3-5-
|
|
39592
|
-
name: "Claude 3.5
|
|
39557
|
+
id: "anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
39558
|
+
name: "Claude 3.5 Haiku (Bedrock)",
|
|
39593
39559
|
provider: "bedrock",
|
|
39594
39560
|
contextLength: 200000
|
|
39595
39561
|
},
|
|
39596
39562
|
{
|
|
39597
|
-
id: "anthropic.claude-3-
|
|
39598
|
-
name: "Claude 3
|
|
39563
|
+
id: "anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
39564
|
+
name: "Claude 3.7 Sonnet (Bedrock)",
|
|
39599
39565
|
provider: "bedrock",
|
|
39600
39566
|
contextLength: 200000
|
|
39601
39567
|
},
|
|
39602
39568
|
{
|
|
39603
|
-
id: "anthropic.claude-
|
|
39604
|
-
name: "Claude
|
|
39569
|
+
id: "anthropic.claude-haiku-4-5-20251001-v1:0",
|
|
39570
|
+
name: "Claude Haiku 4.5 (Bedrock)",
|
|
39605
39571
|
provider: "bedrock",
|
|
39606
39572
|
contextLength: 200000
|
|
39607
39573
|
},
|
|
39608
39574
|
{
|
|
39609
|
-
id: "anthropic.claude-
|
|
39610
|
-
name: "Claude
|
|
39575
|
+
id: "anthropic.claude-opus-4-1-20250805-v1:0",
|
|
39576
|
+
name: "Claude Opus 4.1 (Bedrock)",
|
|
39577
|
+
provider: "bedrock",
|
|
39578
|
+
contextLength: 200000
|
|
39579
|
+
},
|
|
39580
|
+
{
|
|
39581
|
+
id: "anthropic.claude-opus-4-5-20251101-v1:0",
|
|
39582
|
+
name: "Claude Opus 4.5 (Bedrock)",
|
|
39583
|
+
provider: "bedrock",
|
|
39584
|
+
contextLength: 200000
|
|
39585
|
+
},
|
|
39586
|
+
{
|
|
39587
|
+
id: "anthropic.claude-opus-4-20250514-v1:0",
|
|
39588
|
+
name: "Claude Opus 4 (Bedrock)",
|
|
39589
|
+
provider: "bedrock",
|
|
39590
|
+
contextLength: 200000
|
|
39591
|
+
},
|
|
39592
|
+
{
|
|
39593
|
+
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
|
|
39594
|
+
name: "Claude Sonnet 4.5 (Bedrock)",
|
|
39595
|
+
provider: "bedrock",
|
|
39596
|
+
contextLength: 200000
|
|
39597
|
+
},
|
|
39598
|
+
{
|
|
39599
|
+
id: "anthropic.claude-sonnet-4-20250514-v1:0",
|
|
39600
|
+
name: "Claude Sonnet 4 (Bedrock)",
|
|
39611
39601
|
provider: "bedrock",
|
|
39612
39602
|
contextLength: 200000
|
|
39613
39603
|
},
|
|
@@ -39648,6 +39638,66 @@ var AVAILABLE_MODELS = [
|
|
|
39648
39638
|
contextLength: 128000
|
|
39649
39639
|
}
|
|
39650
39640
|
];
|
|
39641
|
+
|
|
39642
|
+
// src/core/ai/models/openai.ts
|
|
39643
|
+
var OPENAI_MODELS = [
|
|
39644
|
+
{
|
|
39645
|
+
id: "gpt-4.5-turbo",
|
|
39646
|
+
name: "GPT-4.5 Turbo",
|
|
39647
|
+
provider: "openai",
|
|
39648
|
+
contextLength: 128000
|
|
39649
|
+
},
|
|
39650
|
+
{
|
|
39651
|
+
id: "gpt-4o",
|
|
39652
|
+
name: "GPT-4o",
|
|
39653
|
+
provider: "openai",
|
|
39654
|
+
contextLength: 128000
|
|
39655
|
+
},
|
|
39656
|
+
{
|
|
39657
|
+
id: "gpt-4o-mini",
|
|
39658
|
+
name: "GPT-4o Mini",
|
|
39659
|
+
provider: "openai",
|
|
39660
|
+
contextLength: 128000
|
|
39661
|
+
},
|
|
39662
|
+
{
|
|
39663
|
+
id: "gpt-4-turbo",
|
|
39664
|
+
name: "GPT-4 Turbo",
|
|
39665
|
+
provider: "openai",
|
|
39666
|
+
contextLength: 128000
|
|
39667
|
+
},
|
|
39668
|
+
{
|
|
39669
|
+
id: "gpt-4",
|
|
39670
|
+
name: "GPT-4",
|
|
39671
|
+
provider: "openai",
|
|
39672
|
+
contextLength: 8192
|
|
39673
|
+
},
|
|
39674
|
+
{
|
|
39675
|
+
id: "gpt-3.5-turbo",
|
|
39676
|
+
name: "GPT-3.5 Turbo",
|
|
39677
|
+
provider: "openai",
|
|
39678
|
+
contextLength: 16385
|
|
39679
|
+
},
|
|
39680
|
+
{
|
|
39681
|
+
id: "o1",
|
|
39682
|
+
name: "O1",
|
|
39683
|
+
provider: "openai",
|
|
39684
|
+
contextLength: 200000
|
|
39685
|
+
},
|
|
39686
|
+
{
|
|
39687
|
+
id: "o1-mini",
|
|
39688
|
+
name: "O1 Mini",
|
|
39689
|
+
provider: "openai",
|
|
39690
|
+
contextLength: 128000
|
|
39691
|
+
}
|
|
39692
|
+
];
|
|
39693
|
+
|
|
39694
|
+
// src/core/ai/models/index.ts
|
|
39695
|
+
var AVAILABLE_MODELS = [
|
|
39696
|
+
...ANTHROPIC_MODELS,
|
|
39697
|
+
...OPENROUTER_MODELS,
|
|
39698
|
+
...BEDROCK_MODELS,
|
|
39699
|
+
...OPENAI_MODELS
|
|
39700
|
+
];
|
|
39651
39701
|
function getModelInfo(model) {
|
|
39652
39702
|
return AVAILABLE_MODELS.find((m) => m.id === model) ?? {
|
|
39653
39703
|
id: model,
|
|
@@ -39664,7 +39714,7 @@ function getProviderModel(model, authConfig) {
|
|
|
39664
39714
|
const openRouterAPIKey = authConfig?.openRouterAPIKey || process.env.OPENROUTER_API_KEY;
|
|
39665
39715
|
const bedrockAccessKeyId = authConfig?.bedrock?.accessKeyId || process.env.AWS_ACCESS_KEY_ID;
|
|
39666
39716
|
const bedrockSecretAccessKey = authConfig?.bedrock?.secretAccessKey || process.env.AWS_SECRET_ACCESS_KEY;
|
|
39667
|
-
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION
|
|
39717
|
+
const bedrockRegion = authConfig?.bedrock?.region || process.env.AWS_REGION;
|
|
39668
39718
|
const localBaseURL = authConfig?.local?.baseURL || process.env.LOCAL_MODEL_URL || "http://127.0.0.1:1234/v1";
|
|
39669
39719
|
let providerModel;
|
|
39670
39720
|
switch (provider) {
|