@juspay/neurolink 12.33.0 → 12.34.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/CHANGELOG.md +6 -2
- package/dist/adapters/providerImageAdapter.js +13 -0
- package/dist/browser/neurolink.min.js +18 -18
- package/dist/constants/contextWindows.js +28 -0
- package/dist/constants/enums.d.ts +21 -0
- package/dist/constants/enums.js +30 -0
- package/dist/constants/tokens.d.ts +3 -0
- package/dist/constants/tokens.js +3 -0
- package/dist/evaluation/EvaluatorFactory.js +3 -3
- package/dist/evaluation/EvaluatorRegistry.js +1 -1
- package/dist/evaluation/ragasEvaluator.js +1 -1
- package/dist/middleware/utils/guardrailsUtils.js +1 -1
- package/dist/models/manifests/anthropic.js +33 -1
- package/dist/providers/catalog/xai.json +17 -3
- package/dist/providers/googleVertex/client.js +0 -2
- package/dist/providers/litellm/client.js +2 -2
- package/dist/providers/openAI/client.js +1 -1
- package/dist/providers/openRouter/client.js +1 -1
- package/dist/utils/modelChoices.js +0 -9
- package/dist/utils/pricing.js +5 -0
- package/dist/utils/providerHealth.js +7 -9
- package/dist/utils/tokenLimits.js +9 -0
- package/dist/workflow/workflows/multiJudgeWorkflow.js +2 -2
- package/docs-site/static/search-index.json +10 -10
- package/package.json +3 -2
|
@@ -83,6 +83,10 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
83
83
|
voyage: {
|
|
84
84
|
// Voyage embeddings: max input tokens vary 16K-32K per model
|
|
85
85
|
_default: 32_000,
|
|
86
|
+
"voyage-4": 32_000,
|
|
87
|
+
"voyage-4-large": 32_000,
|
|
88
|
+
"voyage-4-lite": 32_000,
|
|
89
|
+
"voyage-code-4": 32_000,
|
|
86
90
|
"voyage-3.5": 32_000,
|
|
87
91
|
"voyage-3.5-lite": 32_000,
|
|
88
92
|
"voyage-3-large": 32_000,
|
|
@@ -111,6 +115,10 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
111
115
|
},
|
|
112
116
|
anthropic: {
|
|
113
117
|
_default: 200_000,
|
|
118
|
+
// Claude 5.5 / 5.1 (Sep 2026) — 1M context window, confirmed on
|
|
119
|
+
// platform.claude.com/docs/en/about-claude/models/overview
|
|
120
|
+
"claude-opus-5-5": 1_000_000,
|
|
121
|
+
"claude-fable-5-1": 1_000_000,
|
|
114
122
|
// Claude 5 (mid 2026) — 1M context window
|
|
115
123
|
"claude-sonnet-5": 1_000_000,
|
|
116
124
|
// Claude 4.6 (Feb 2026) — 1M context window
|
|
@@ -134,6 +142,11 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
134
142
|
},
|
|
135
143
|
openai: {
|
|
136
144
|
_default: 128_000,
|
|
145
|
+
// GPT-6 family (Sep 2026) — 1.05M context, per
|
|
146
|
+
// developers.openai.com/api/docs/models
|
|
147
|
+
"gpt-6-astra": 1_050_000,
|
|
148
|
+
"gpt-6-sol": 1_050_000,
|
|
149
|
+
"gpt-6-luna": 1_050_000,
|
|
137
150
|
// GPT-5.4 family — 1.05M context
|
|
138
151
|
"gpt-5.4": 1_050_000,
|
|
139
152
|
"gpt-5.4-mini": 400_000,
|
|
@@ -202,6 +215,8 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
202
215
|
vertex: {
|
|
203
216
|
_default: 1_048_576,
|
|
204
217
|
// Claude on Vertex
|
|
218
|
+
"claude-opus-5-5": 1_000_000,
|
|
219
|
+
"claude-fable-5-1": 1_000_000,
|
|
205
220
|
"claude-sonnet-5": 1_000_000,
|
|
206
221
|
"claude-opus-4-6": 1_000_000,
|
|
207
222
|
"claude-sonnet-4-6": 1_000_000,
|
|
@@ -238,6 +253,9 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
238
253
|
},
|
|
239
254
|
bedrock: {
|
|
240
255
|
_default: 200_000,
|
|
256
|
+
// Claude 5.5 / 5.1 (Sep 2026)
|
|
257
|
+
"anthropic.claude-opus-5-5": 1_000_000,
|
|
258
|
+
"anthropic.claude-fable-5-1": 1_000_000,
|
|
241
259
|
// Claude 4.6
|
|
242
260
|
"anthropic.claude-opus-4-6-v1": 1_000_000,
|
|
243
261
|
"anthropic.claude-sonnet-4-6": 1_000_000,
|
|
@@ -263,6 +281,16 @@ export const MODEL_CONTEXT_WINDOWS = {
|
|
|
263
281
|
},
|
|
264
282
|
azure: {
|
|
265
283
|
_default: 128_000,
|
|
284
|
+
// GPT-6 family (Sep 2026) — 1.05M context, per
|
|
285
|
+
// learn.microsoft.com/azure/ai-foundry/openai/concepts/models
|
|
286
|
+
"gpt-6-astra": 1_050_000,
|
|
287
|
+
"gpt-6-sol": 1_050_000,
|
|
288
|
+
"gpt-6-luna": 1_050_000,
|
|
289
|
+
// GPT-5.6 / GPT-5.5 — Azure-only as of Sep 2026, same 1.05M context
|
|
290
|
+
"gpt-5.6-sol": 1_050_000,
|
|
291
|
+
"gpt-5.6-terra": 1_050_000,
|
|
292
|
+
"gpt-5.6-luna": 1_050_000,
|
|
293
|
+
"gpt-5.5": 1_050_000,
|
|
266
294
|
// GPT-5.4
|
|
267
295
|
"gpt-5.4": 1_050_000,
|
|
268
296
|
"gpt-5.4-mini": 400_000,
|
|
@@ -180,6 +180,9 @@ export declare enum BedrockModels {
|
|
|
180
180
|
* Supported Models for OpenAI
|
|
181
181
|
*/
|
|
182
182
|
export declare enum OpenAIModels {
|
|
183
|
+
GPT_6_ASTRA = "gpt-6-astra",
|
|
184
|
+
GPT_6_SOL = "gpt-6-sol",
|
|
185
|
+
GPT_6_LUNA = "gpt-6-luna",
|
|
183
186
|
GPT_5_3_CODEX = "gpt-5.3-codex",
|
|
184
187
|
GPT_5_4 = "gpt-5.4",
|
|
185
188
|
GPT_5_4_MINI = "gpt-5.4-mini",
|
|
@@ -228,6 +231,13 @@ export declare enum OpenAIModels {
|
|
|
228
231
|
* Note: Azure uses deployment names, these are model identifiers
|
|
229
232
|
*/
|
|
230
233
|
export declare enum AzureOpenAIModels {
|
|
234
|
+
GPT_6_ASTRA = "gpt-6-astra",
|
|
235
|
+
GPT_6_SOL = "gpt-6-sol",
|
|
236
|
+
GPT_6_LUNA = "gpt-6-luna",
|
|
237
|
+
GPT_5_6_SOL = "gpt-5.6-sol",
|
|
238
|
+
GPT_5_6_TERRA = "gpt-5.6-terra",
|
|
239
|
+
GPT_5_6_LUNA = "gpt-5.6-luna",
|
|
240
|
+
GPT_5_5 = "gpt-5.5",
|
|
231
241
|
GPT_5_2 = "gpt-5.2",
|
|
232
242
|
GPT_5_2_CHAT = "gpt-5.2-chat",
|
|
233
243
|
GPT_5_2_PRO = "gpt-5.2-pro",
|
|
@@ -355,6 +365,8 @@ export declare enum AnthropicModels {
|
|
|
355
365
|
CLAUDE_OPUS_5 = "claude-opus-5",
|
|
356
366
|
CLAUDE_SONNET_5 = "claude-sonnet-5",
|
|
357
367
|
CLAUDE_FABLE_5 = "claude-fable-5",
|
|
368
|
+
CLAUDE_OPUS_5_5 = "claude-opus-5-5",
|
|
369
|
+
CLAUDE_FABLE_5_1 = "claude-fable-5-1",
|
|
358
370
|
CLAUDE_OPUS_4_8 = "claude-opus-4-8",
|
|
359
371
|
CLAUDE_OPUS_4_7 = "claude-opus-4-7",
|
|
360
372
|
CLAUDE_OPUS_4_6 = "claude-opus-4-6",
|
|
@@ -650,6 +662,14 @@ export declare enum CohereModels {
|
|
|
650
662
|
* @see https://docs.voyageai.com/docs/embeddings
|
|
651
663
|
*/
|
|
652
664
|
export declare enum VoyageModels {
|
|
665
|
+
/** Voyage 4 — latest general-purpose flagship */
|
|
666
|
+
VOYAGE_4 = "voyage-4",
|
|
667
|
+
/** Voyage 4 Large — largest / highest quality */
|
|
668
|
+
VOYAGE_4_LARGE = "voyage-4-large",
|
|
669
|
+
/** Voyage 4 Lite — smaller / cheaper */
|
|
670
|
+
VOYAGE_4_LITE = "voyage-4-lite",
|
|
671
|
+
/** Voyage Code 4 — code-tuned */
|
|
672
|
+
VOYAGE_CODE_4 = "voyage-code-4",
|
|
653
673
|
/** Voyage 3.5 — latest general-purpose (default) */
|
|
654
674
|
VOYAGE_3_5 = "voyage-3.5",
|
|
655
675
|
/** Voyage 3.5 Lite — smaller / cheaper */
|
|
@@ -1042,6 +1062,7 @@ export declare enum UpstageModels {
|
|
|
1042
1062
|
SYN_PRO_251021 = "syn-pro-251021"
|
|
1043
1063
|
}
|
|
1044
1064
|
export declare enum XaiModels {
|
|
1065
|
+
GROK_4_7 = "grok-4.7",
|
|
1045
1066
|
GROK_4_6 = "grok-4.6",
|
|
1046
1067
|
GROK_4_5 = "grok-4.5",
|
|
1047
1068
|
GROK_4_3 = "grok-4.3",
|
package/dist/constants/enums.js
CHANGED
|
@@ -257,6 +257,11 @@ export var BedrockModels;
|
|
|
257
257
|
*/
|
|
258
258
|
export var OpenAIModels;
|
|
259
259
|
(function (OpenAIModels) {
|
|
260
|
+
// GPT-6 Series (Released September 2026) - current flagship family, per
|
|
261
|
+
// developers.openai.com/api/docs/models
|
|
262
|
+
OpenAIModels["GPT_6_ASTRA"] = "gpt-6-astra";
|
|
263
|
+
OpenAIModels["GPT_6_SOL"] = "gpt-6-sol";
|
|
264
|
+
OpenAIModels["GPT_6_LUNA"] = "gpt-6-luna";
|
|
260
265
|
// GPT-5.3 Series (Released February 2026) - Latest coding models
|
|
261
266
|
OpenAIModels["GPT_5_3_CODEX"] = "gpt-5.3-codex";
|
|
262
267
|
// GPT-5.4 Series (Released March 2026) - Latest flagship models
|
|
@@ -318,6 +323,18 @@ export var OpenAIModels;
|
|
|
318
323
|
*/
|
|
319
324
|
export var AzureOpenAIModels;
|
|
320
325
|
(function (AzureOpenAIModels) {
|
|
326
|
+
// GPT-6 Series (September 2026) - current flagship family, confirmed on
|
|
327
|
+
// Azure OpenAI (learn.microsoft.com/azure/ai-foundry/openai/concepts/models)
|
|
328
|
+
AzureOpenAIModels["GPT_6_ASTRA"] = "gpt-6-astra";
|
|
329
|
+
AzureOpenAIModels["GPT_6_SOL"] = "gpt-6-sol";
|
|
330
|
+
AzureOpenAIModels["GPT_6_LUNA"] = "gpt-6-luna";
|
|
331
|
+
// GPT-5.6 Series (Azure-only as of Sep 2026 — retired from the OpenAI-direct
|
|
332
|
+
// catalog, still documented on Azure OpenAI)
|
|
333
|
+
AzureOpenAIModels["GPT_5_6_SOL"] = "gpt-5.6-sol";
|
|
334
|
+
AzureOpenAIModels["GPT_5_6_TERRA"] = "gpt-5.6-terra";
|
|
335
|
+
AzureOpenAIModels["GPT_5_6_LUNA"] = "gpt-5.6-luna";
|
|
336
|
+
// GPT-5.5 (Azure-only as of Sep 2026 — same situation as GPT-5.6 above)
|
|
337
|
+
AzureOpenAIModels["GPT_5_5"] = "gpt-5.5";
|
|
321
338
|
// GPT-5.2 Series (Latest - December 2025)
|
|
322
339
|
AzureOpenAIModels["GPT_5_2"] = "gpt-5.2";
|
|
323
340
|
AzureOpenAIModels["GPT_5_2_CHAT"] = "gpt-5.2-chat";
|
|
@@ -482,6 +499,10 @@ export var AnthropicModels;
|
|
|
482
499
|
AnthropicModels["CLAUDE_OPUS_5"] = "claude-opus-5";
|
|
483
500
|
AnthropicModels["CLAUDE_SONNET_5"] = "claude-sonnet-5";
|
|
484
501
|
AnthropicModels["CLAUDE_FABLE_5"] = "claude-fable-5";
|
|
502
|
+
// Claude 5.5 / 5.1 Series (September 2026) — confirmed on
|
|
503
|
+
// platform.claude.com/docs/en/about-claude/models/overview
|
|
504
|
+
AnthropicModels["CLAUDE_OPUS_5_5"] = "claude-opus-5-5";
|
|
505
|
+
AnthropicModels["CLAUDE_FABLE_5_1"] = "claude-fable-5-1";
|
|
485
506
|
// Claude 4.7 / 4.8 Series
|
|
486
507
|
AnthropicModels["CLAUDE_OPUS_4_8"] = "claude-opus-4-8";
|
|
487
508
|
AnthropicModels["CLAUDE_OPUS_4_7"] = "claude-opus-4-7";
|
|
@@ -868,6 +889,14 @@ export var CohereModels;
|
|
|
868
889
|
*/
|
|
869
890
|
export var VoyageModels;
|
|
870
891
|
(function (VoyageModels) {
|
|
892
|
+
/** Voyage 4 — latest general-purpose flagship */
|
|
893
|
+
VoyageModels["VOYAGE_4"] = "voyage-4";
|
|
894
|
+
/** Voyage 4 Large — largest / highest quality */
|
|
895
|
+
VoyageModels["VOYAGE_4_LARGE"] = "voyage-4-large";
|
|
896
|
+
/** Voyage 4 Lite — smaller / cheaper */
|
|
897
|
+
VoyageModels["VOYAGE_4_LITE"] = "voyage-4-lite";
|
|
898
|
+
/** Voyage Code 4 — code-tuned */
|
|
899
|
+
VoyageModels["VOYAGE_CODE_4"] = "voyage-code-4";
|
|
871
900
|
/** Voyage 3.5 — latest general-purpose (default) */
|
|
872
901
|
VoyageModels["VOYAGE_3_5"] = "voyage-3.5";
|
|
873
902
|
/** Voyage 3.5 Lite — smaller / cheaper */
|
|
@@ -1290,6 +1319,7 @@ export var UpstageModels;
|
|
|
1290
1319
|
})(UpstageModels || (UpstageModels = {}));
|
|
1291
1320
|
export var XaiModels;
|
|
1292
1321
|
(function (XaiModels) {
|
|
1322
|
+
XaiModels["GROK_4_7"] = "grok-4.7";
|
|
1293
1323
|
XaiModels["GROK_4_6"] = "grok-4.6";
|
|
1294
1324
|
XaiModels["GROK_4_5"] = "grok-4.5";
|
|
1295
1325
|
XaiModels["GROK_4_3"] = "grok-4.3";
|
|
@@ -71,6 +71,9 @@ export declare const PROVIDER_TOKEN_LIMITS: {
|
|
|
71
71
|
};
|
|
72
72
|
/** OpenAI model limits */
|
|
73
73
|
readonly OPENAI: {
|
|
74
|
+
readonly "gpt-6-astra": 128000;
|
|
75
|
+
readonly "gpt-6-sol": 128000;
|
|
76
|
+
readonly "gpt-6-luna": 128000;
|
|
74
77
|
readonly "gpt-5.4": 128000;
|
|
75
78
|
readonly "gpt-5.4-mini": 128000;
|
|
76
79
|
readonly "gpt-5.4-nano": 128000;
|
package/dist/constants/tokens.js
CHANGED
|
@@ -57,7 +57,7 @@ export class EvaluatorFactory extends BaseFactory {
|
|
|
57
57
|
const mergedConfig = {
|
|
58
58
|
threshold: 7,
|
|
59
59
|
evaluationStrategy: "ragas",
|
|
60
|
-
evaluationModel: process.env.NEUROLINK_RAGAS_EVALUATION_MODEL || "gemini-
|
|
60
|
+
evaluationModel: process.env.NEUROLINK_RAGAS_EVALUATION_MODEL || "gemini-2.5-flash",
|
|
61
61
|
provider: process.env.NEUROLINK_RAGAS_EVALUATION_PROVIDER || "vertex",
|
|
62
62
|
...config,
|
|
63
63
|
};
|
|
@@ -95,7 +95,7 @@ export class EvaluatorFactory extends BaseFactory {
|
|
|
95
95
|
const mergedConfig = {
|
|
96
96
|
threshold: 5,
|
|
97
97
|
evaluationStrategy: "ragas",
|
|
98
|
-
evaluationModel: process.env.NEUROLINK_RAGAS_EVALUATION_MODEL || "gemini-
|
|
98
|
+
evaluationModel: process.env.NEUROLINK_RAGAS_EVALUATION_MODEL || "gemini-2.5-flash",
|
|
99
99
|
provider: process.env.NEUROLINK_RAGAS_EVALUATION_PROVIDER || "vertex",
|
|
100
100
|
...config,
|
|
101
101
|
};
|
|
@@ -114,7 +114,7 @@ export class EvaluatorFactory extends BaseFactory {
|
|
|
114
114
|
const mergedConfig = {
|
|
115
115
|
threshold: 6,
|
|
116
116
|
evaluationStrategy: "ragas",
|
|
117
|
-
evaluationModel: "gemini-
|
|
117
|
+
evaluationModel: "gemini-2.5-flash",
|
|
118
118
|
provider: "vertex",
|
|
119
119
|
...config,
|
|
120
120
|
};
|
|
@@ -73,7 +73,7 @@ export class EvaluatorRegistry extends BaseRegistry {
|
|
|
73
73
|
name: "RAGAS Evaluator",
|
|
74
74
|
description: "RAGAS-style LLM-as-judge evaluation with relevance, accuracy, and completeness metrics",
|
|
75
75
|
requiresLLM: true,
|
|
76
|
-
defaultModel: "gemini-
|
|
76
|
+
defaultModel: "gemini-2.5-flash",
|
|
77
77
|
defaultProvider: "vertex",
|
|
78
78
|
version: "1.0.0",
|
|
79
79
|
features: [
|
|
@@ -18,7 +18,7 @@ export class RAGASEvaluator {
|
|
|
18
18
|
this.evaluationModel =
|
|
19
19
|
evaluationModel ||
|
|
20
20
|
process.env.NEUROLINK_RAGAS_EVALUATION_MODEL ||
|
|
21
|
-
"gemini-
|
|
21
|
+
"gemini-2.5-flash";
|
|
22
22
|
this.providerName =
|
|
23
23
|
providerName ||
|
|
24
24
|
process.env.NEUROLINK_RAGAS_EVALUATION_PROVIDER ||
|
|
@@ -113,7 +113,7 @@ params, config) {
|
|
|
113
113
|
*/
|
|
114
114
|
export async function performPrecallEvaluation(config, userInput) {
|
|
115
115
|
try {
|
|
116
|
-
const provider = await AIProviderFactory.createProvider(config.provider || "google-ai", config.evaluationModel || "gemini-
|
|
116
|
+
const provider = await AIProviderFactory.createProvider(config.provider || "google-ai", config.evaluationModel || "gemini-2.5-flash");
|
|
117
117
|
const evaluationPrompt = config.evaluationPrompt || DEFAULT_EVALUATION_PROMPT;
|
|
118
118
|
const prompt = evaluationPrompt.replace("{USER_INPUT}", userInput);
|
|
119
119
|
const result = await provider.generate({
|
|
@@ -23,11 +23,43 @@ export const anthropicManifest = {
|
|
|
23
23
|
},
|
|
24
24
|
],
|
|
25
25
|
models: {
|
|
26
|
+
"claude-opus-5-5": {
|
|
27
|
+
aliases: ["opus-5.5"],
|
|
28
|
+
displayName: "Claude Opus 5.5",
|
|
29
|
+
contextWindow: 1_000_000,
|
|
30
|
+
maxOutputTokens: 128_000,
|
|
31
|
+
// No pricingPerMTok DELIBERATELY: PRICING.anthropic already carries
|
|
32
|
+
// real rates for this id (input 4.0/output 20.0 per MTok) — see the
|
|
33
|
+
// claude-sonnet-5 comment below for why this defers to that table.
|
|
34
|
+
vision: true,
|
|
35
|
+
functionCalling: true,
|
|
36
|
+
reasoning: true,
|
|
37
|
+
jsonMode: true,
|
|
38
|
+
samplingParams: false, // matches SAMPLING_PARAM_REJECTING_FAMILIES /opus[-_.]?5(?![0-9])/i
|
|
39
|
+
},
|
|
40
|
+
"claude-fable-5-1": {
|
|
41
|
+
aliases: ["fable-5.1"],
|
|
42
|
+
displayName: "Claude Fable 5.1",
|
|
43
|
+
contextWindow: 1_000_000,
|
|
44
|
+
maxOutputTokens: 128_000,
|
|
45
|
+
// No pricingPerMTok DELIBERATELY: PRICING.anthropic already carries
|
|
46
|
+
// real rates for this id (input 10.0/output 50.0 per MTok) — see the
|
|
47
|
+
// claude-sonnet-5 comment below for why this defers to that table.
|
|
48
|
+
vision: true,
|
|
49
|
+
functionCalling: true,
|
|
50
|
+
reasoning: true,
|
|
51
|
+
jsonMode: true,
|
|
52
|
+
samplingParams: false, // matches SAMPLING_PARAM_REJECTING_FAMILIES /fable/i
|
|
53
|
+
},
|
|
26
54
|
"claude-sonnet-5": {
|
|
27
55
|
aliases: ["sonnet-5", "claude-sonnet"],
|
|
28
56
|
displayName: "Claude Sonnet 5",
|
|
29
57
|
contextWindow: 1_000_000,
|
|
30
|
-
|
|
58
|
+
// Was 64_000; corrected to 128_000 to match the official spec
|
|
59
|
+
// (platform.claude.com/docs/en/about-claude/models/overview) and the
|
|
60
|
+
// matching fix in getClaudeMaxOutputTokens (tokenLimits.ts), which this
|
|
61
|
+
// manifest's own header comment names as the authoritative source.
|
|
62
|
+
maxOutputTokens: 128_000,
|
|
31
63
|
// No pricingPerMTok DELIBERATELY: PRICING.anthropic carries real
|
|
32
64
|
// rates for this id, and findRates() is manifest-first with a legacy
|
|
33
65
|
// fallback — omitting the rate here defers to that table instead of
|
|
@@ -9,10 +9,24 @@
|
|
|
9
9
|
},
|
|
10
10
|
"models": {
|
|
11
11
|
"default": "grok-4.6",
|
|
12
|
-
"fallbacks": [
|
|
12
|
+
"fallbacks": [
|
|
13
|
+
"grok-4.6",
|
|
14
|
+
"grok-4.5",
|
|
15
|
+
"grok-4.3",
|
|
16
|
+
"grok-3",
|
|
17
|
+
"grok-3-mini",
|
|
18
|
+
"grok-4.7"
|
|
19
|
+
],
|
|
13
20
|
"defaultContextWindow": 131072,
|
|
14
21
|
"defaultMaxOutputTokens": 4096,
|
|
15
22
|
"catalog": {
|
|
23
|
+
"grok-4.7": {
|
|
24
|
+
"enumMember": "GROK_4_7",
|
|
25
|
+
"contextWindow": 500000,
|
|
26
|
+
"vision": true,
|
|
27
|
+
"status": "production",
|
|
28
|
+
"description": "Grok 4.7 — xAI's newest flagship as of 2026-09-27 (text + image input); not yet the SDK default, see docs.x.ai/developers/grok-4-7"
|
|
29
|
+
},
|
|
16
30
|
"grok-4.6": {
|
|
17
31
|
"enumMember": "GROK_4_6",
|
|
18
32
|
"contextWindow": 131072,
|
|
@@ -71,7 +85,7 @@
|
|
|
71
85
|
}
|
|
72
86
|
},
|
|
73
87
|
"visionModel": "grok-4.6",
|
|
74
|
-
"topModels": ["grok-4.6", "grok-4.5", "grok-4.3", "grok-3"]
|
|
88
|
+
"topModels": ["grok-4.6", "grok-4.5", "grok-4.3", "grok-3", "grok-4.7"]
|
|
75
89
|
},
|
|
76
90
|
"capabilities": {
|
|
77
91
|
"text": true,
|
|
@@ -114,7 +128,7 @@
|
|
|
114
128
|
},
|
|
115
129
|
"liveMatrix": {
|
|
116
130
|
"date": "2026-08-30",
|
|
117
|
-
"result": "grok-2-latest, grok-2-vision-latest and grok-beta are rejected as invalid models. The grok-4.x line replaces them: 4.3/4.5/4.6 all answer, and all three read a 64x64 PNG correctly, so vision moved there from the retired grok-2-vision-latest. An earlier probe with an 8x8 PNG reported no vision — that was xAI answering 'Invalid PNG image', a complaint about the file rather than the capability. grok-3 and grok-3-mini are kept because they still serve, even though xAI's /models roster omits them: roster absence is not evidence of death here."
|
|
131
|
+
"result": "grok-2-latest, grok-2-vision-latest and grok-beta are rejected as invalid models. The grok-4.x line replaces them: 4.3/4.5/4.6 all answer, and all three read a 64x64 PNG correctly, so vision moved there from the retired grok-2-vision-latest. An earlier probe with an 8x8 PNG reported no vision — that was xAI answering 'Invalid PNG image', a complaint about the file rather than the capability. grok-3 and grok-3-mini are kept because they still serve, even though xAI's /models roster omits them: roster absence is not evidence of death here. grok-4.7 added 2026-09-27 from docs.x.ai/developers/grok-4-7 and docs.x.ai/developers/pricing (official docs review only — no xAI API key was available in this environment, so unlike the rest of this file it has not been roster/chat-probed live; context 500,000 tokens and text+image input are as published, and it is deliberately left with no pricingPerMTok, matching grok-4.6/4.5/4.3, because its real rate is tiered by prompt length ($2/$0.50/$6 per 1M below 200k tokens, $4/$1/$12 at or above) and the schema's pricingPerMTok field can only hold one flat rate)."
|
|
118
132
|
},
|
|
119
133
|
"addedInPR": "https://github.com/juspay/neurolink/pull/1587"
|
|
120
134
|
}
|
|
@@ -6480,8 +6480,6 @@ export class GoogleVertexProvider extends BaseProvider {
|
|
|
6480
6480
|
"gemini-2.5-flash-lite",
|
|
6481
6481
|
"gemini-2.0-flash-001",
|
|
6482
6482
|
"gemini-2.0-flash-lite",
|
|
6483
|
-
"gemini-1.5-pro",
|
|
6484
|
-
"gemini-1.5-flash",
|
|
6485
6483
|
],
|
|
6486
6484
|
claude: [
|
|
6487
6485
|
"claude-sonnet-4-5@20250929",
|
|
@@ -13,7 +13,7 @@ import { createTimeoutController } from "../../utils/timeout.js";
|
|
|
13
13
|
import { stripTrailingSlash } from "../openaiChatCompletionsClient.js";
|
|
14
14
|
import { OpenAIChatCompletionsProvider } from "../openaiChatCompletionsBase.js";
|
|
15
15
|
const streamTracer = trace.getTracer("neurolink.provider.litellm");
|
|
16
|
-
const FALLBACK_LITELLM_MODEL = "openai/gpt-
|
|
16
|
+
const FALLBACK_LITELLM_MODEL = "openai/gpt-5.4-mini";
|
|
17
17
|
const getLiteLLMConfig = () => ({
|
|
18
18
|
baseURL: process.env.LITELLM_BASE_URL || "http://localhost:4000",
|
|
19
19
|
apiKey: process.env.LITELLM_API_KEY || "sk-anything",
|
|
@@ -243,7 +243,7 @@ export class LiteLLMProvider extends OpenAIChatCompletionsProvider {
|
|
|
243
243
|
.map((m) => m.trim())
|
|
244
244
|
.filter((m) => m.length > 0) || [
|
|
245
245
|
"openai/gpt-4o",
|
|
246
|
-
"anthropic/claude-
|
|
246
|
+
"anthropic/claude-haiku-4-5-20251001",
|
|
247
247
|
"meta-llama/llama-3.1-8b-instruct",
|
|
248
248
|
"google/gemini-2.5-flash",
|
|
249
249
|
]);
|
|
@@ -44,7 +44,7 @@ const resolveOpenAIBaseURL = (credentialBaseURL, envBaseURL) => {
|
|
|
44
44
|
return resolved;
|
|
45
45
|
};
|
|
46
46
|
const getOpenAIApiKey = () => validateApiKey(createOpenAIConfig());
|
|
47
|
-
const getOpenAIModel = () => getProviderModel("OPENAI_MODEL", "gpt-
|
|
47
|
+
const getOpenAIModel = () => getProviderModel("OPENAI_MODEL", "gpt-5.4");
|
|
48
48
|
const streamTracer = trace.getTracer("neurolink.provider.openai");
|
|
49
49
|
/**
|
|
50
50
|
* OpenAI Provider — direct HTTP, no AI SDK.
|
|
@@ -278,7 +278,7 @@ export class OpenRouterProvider extends OpenAIChatCompletionsProvider {
|
|
|
278
278
|
"openai/gpt-4-turbo",
|
|
279
279
|
// Google models
|
|
280
280
|
"google/gemini-2.0-flash",
|
|
281
|
-
"google/gemini-
|
|
281
|
+
"google/gemini-2.5-pro",
|
|
282
282
|
// Meta Llama models
|
|
283
283
|
"meta-llama/llama-3.1-70b-instruct",
|
|
284
284
|
"meta-llama/llama-3.1-8b-instruct",
|
|
@@ -103,14 +103,6 @@ const TOP_MODELS_CONFIG = {
|
|
|
103
103
|
model: GoogleAIModels.GEMINI_3_PRO_PREVIEW,
|
|
104
104
|
description: "Latest preview",
|
|
105
105
|
},
|
|
106
|
-
{
|
|
107
|
-
model: GoogleAIModels.GEMINI_1_5_PRO,
|
|
108
|
-
description: "Previous generation",
|
|
109
|
-
},
|
|
110
|
-
{
|
|
111
|
-
model: GoogleAIModels.GEMINI_1_5_FLASH,
|
|
112
|
-
description: "Legacy fast model",
|
|
113
|
-
},
|
|
114
106
|
],
|
|
115
107
|
[AIProviderName.VERTEX]: [
|
|
116
108
|
{
|
|
@@ -126,7 +118,6 @@ const TOP_MODELS_CONFIG = {
|
|
|
126
118
|
model: VertexModels.GEMINI_2_0_FLASH,
|
|
127
119
|
description: "Stable production model",
|
|
128
120
|
},
|
|
129
|
-
{ model: VertexModels.GEMINI_1_5_PRO, description: "Previous generation" },
|
|
130
121
|
{
|
|
131
122
|
model: VertexModels.CLAUDE_3_5_SONNET,
|
|
132
123
|
description: "Claude 3.5 on Vertex",
|
package/dist/utils/pricing.js
CHANGED
|
@@ -685,6 +685,11 @@ const PRICING = {
|
|
|
685
685
|
// Voyage bills per million input tokens — output dimension is the
|
|
686
686
|
// embedding vector, not generated tokens. We charge to input only.
|
|
687
687
|
_default: { input: 0.18 / 1_000_000, output: 0 },
|
|
688
|
+
// Voyage 4 family — docs.voyageai.com/docs/embeddings pricing table
|
|
689
|
+
"voyage-4": { input: 0.06 / 1_000_000, output: 0 },
|
|
690
|
+
"voyage-4-large": { input: 0.12 / 1_000_000, output: 0 },
|
|
691
|
+
"voyage-4-lite": { input: 0.02 / 1_000_000, output: 0 },
|
|
692
|
+
"voyage-code-4": { input: 0.12 / 1_000_000, output: 0 },
|
|
688
693
|
"voyage-3.5": { input: 0.06 / 1_000_000, output: 0 },
|
|
689
694
|
"voyage-3.5-lite": { input: 0.02 / 1_000_000, output: 0 },
|
|
690
695
|
"voyage-3-large": { input: 0.18 / 1_000_000, output: 0 },
|
|
@@ -423,7 +423,7 @@ export class ProviderHealthChecker {
|
|
|
423
423
|
healthStatus.recommendations.push(`Available models for ${providerName} (using dual provider architecture):\n` +
|
|
424
424
|
` Google Models (via vertex provider):\n` +
|
|
425
425
|
` • gemini-2.5-pro, gemini-2.5-flash, gemini-2.5-flash-lite\n` +
|
|
426
|
-
` • gemini-2.0-flash-001, gemini-
|
|
426
|
+
` • gemini-2.0-flash-001, gemini-2.0-flash-lite\n` +
|
|
427
427
|
` Anthropic Models (via vertexAnthropic provider):\n` +
|
|
428
428
|
` • claude-sonnet-4@20250514, claude-opus-4@20250514\n` +
|
|
429
429
|
` • claude-3-5-sonnet-20241022, claude-3-5-haiku-20241022\n` +
|
|
@@ -771,7 +771,7 @@ export class ProviderHealthChecker {
|
|
|
771
771
|
return new URL("/v1/models", this.getLiteLLMBaseUrl()).toString();
|
|
772
772
|
}
|
|
773
773
|
static getConfiguredLiteLLMModel() {
|
|
774
|
-
return process.env.LITELLM_MODEL || "openai/gpt-
|
|
774
|
+
return process.env.LITELLM_MODEL || "openai/gpt-5.4-mini";
|
|
775
775
|
}
|
|
776
776
|
static getOllamaBaseUrl() {
|
|
777
777
|
return (process.env.OLLAMA_BASE_URL ||
|
|
@@ -914,7 +914,7 @@ export class ProviderHealthChecker {
|
|
|
914
914
|
return { ran: false, failed: false };
|
|
915
915
|
}
|
|
916
916
|
// Only pin the availability check to a specific model when the user
|
|
917
|
-
// explicitly configured one. The fallback default ("openai/gpt-
|
|
917
|
+
// explicitly configured one. The fallback default ("openai/gpt-5.4-mini")
|
|
918
918
|
// is a guess, not configuration — proxies that serve a different model
|
|
919
919
|
// set (every self-hosted gateway) were reported "Not configured" here
|
|
920
920
|
// while generate/stream against them worked fine with explicit models.
|
|
@@ -1002,9 +1002,9 @@ export class ProviderHealthChecker {
|
|
|
1002
1002
|
];
|
|
1003
1003
|
case AIProviderName.GOOGLE_AI:
|
|
1004
1004
|
return [
|
|
1005
|
-
GoogleAIModels.GEMINI_1_5_PRO,
|
|
1006
|
-
GoogleAIModels.GEMINI_1_5_FLASH,
|
|
1007
1005
|
GoogleAIModels.GEMINI_2_5_PRO,
|
|
1006
|
+
GoogleAIModels.GEMINI_2_5_FLASH,
|
|
1007
|
+
GoogleAIModels.GEMINI_2_0_FLASH_001,
|
|
1008
1008
|
];
|
|
1009
1009
|
case AIProviderName.VERTEX:
|
|
1010
1010
|
return [
|
|
@@ -1013,8 +1013,6 @@ export class ProviderHealthChecker {
|
|
|
1013
1013
|
GoogleAIModels.GEMINI_2_5_FLASH,
|
|
1014
1014
|
GoogleAIModels.GEMINI_2_5_FLASH_LITE,
|
|
1015
1015
|
GoogleAIModels.GEMINI_2_0_FLASH_001,
|
|
1016
|
-
GoogleAIModels.GEMINI_1_5_PRO,
|
|
1017
|
-
GoogleAIModels.GEMINI_1_5_FLASH,
|
|
1018
1016
|
// Anthropic models (via vertexAnthropic provider)
|
|
1019
1017
|
"claude-sonnet-4@20250514",
|
|
1020
1018
|
"claude-opus-4@20250514",
|
|
@@ -1030,8 +1028,8 @@ export class ProviderHealthChecker {
|
|
|
1030
1028
|
return [OpenAIModels.GPT_4O, OpenAIModels.GPT_4O_MINI, "gpt-35-turbo"];
|
|
1031
1029
|
case AIProviderName.LITELLM:
|
|
1032
1030
|
return [
|
|
1033
|
-
"openai/gpt-
|
|
1034
|
-
"anthropic/claude-
|
|
1031
|
+
"openai/gpt-5.4-mini",
|
|
1032
|
+
"anthropic/claude-haiku-4-5-20251001",
|
|
1035
1033
|
"google/gemini-2.5-flash",
|
|
1036
1034
|
];
|
|
1037
1035
|
case AIProviderName.OLLAMA: {
|
|
@@ -119,6 +119,15 @@ export function getClaudeMaxOutputTokens(model) {
|
|
|
119
119
|
if (/sonnet[-_.]?4/.test(m) || /haiku[-_.]?4/.test(m)) {
|
|
120
120
|
return 64000;
|
|
121
121
|
}
|
|
122
|
+
// Claude 5.x family (Opus 5 / Opus 5.5 / Sonnet 5 / Fable 5.1 / Mythos):
|
|
123
|
+
// all confirmed at 128K standard max output on
|
|
124
|
+
// platform.claude.com/docs/en/about-claude/models/overview. The
|
|
125
|
+
// (?![0-9]) guard keeps this off dated 4.x ids like "opus-4-5-20251101"
|
|
126
|
+
// (Opus 4.5, not Opus 5), where the family word sits before the "4", not
|
|
127
|
+
// directly before this "5".
|
|
128
|
+
if (/(?:opus|sonnet|fable|mythos)[-_.]?5(?![0-9])/.test(m)) {
|
|
129
|
+
return 128000;
|
|
130
|
+
}
|
|
122
131
|
// Claude 3.7 Sonnet supports 64K output.
|
|
123
132
|
if (/3[-_.]?7[-_.]?sonnet/.test(m)) {
|
|
124
133
|
return 64000;
|
|
@@ -277,8 +277,8 @@ export function createMultiJudgeWorkflow(modelCount, judgeCount) {
|
|
|
277
277
|
},
|
|
278
278
|
{
|
|
279
279
|
provider: AIProviderName.GOOGLE_AI,
|
|
280
|
-
model: "gemini-
|
|
281
|
-
label: "Gemini
|
|
280
|
+
model: "gemini-2.5-flash",
|
|
281
|
+
label: "Gemini 2.5 Flash",
|
|
282
282
|
weight: 0.8,
|
|
283
283
|
temperature: 0.7,
|
|
284
284
|
},
|