@juspay/neurolink 12.10.0 → 12.11.1
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 +3 -3
- package/dist/browser/neurolink.min.js +353 -351
- package/dist/constants/enums.d.ts +77 -0
- package/dist/constants/enums.js +82 -0
- package/dist/core/modules/GenerationHandler.d.ts +15 -3
- package/dist/core/modules/GenerationHandler.js +172 -14
- package/dist/providers/catalog/baseten.json +263 -0
- package/dist/providers/catalog/gmicloud.json +64 -0
- package/dist/providers/catalog/inception-labs.json +75 -0
- package/dist/providers/catalog/index.generated.d.ts +1 -1
- package/dist/providers/catalog/index.generated.js +15 -0
- package/dist/providers/catalog/io-intelligence.json +463 -0
- package/dist/providers/catalog/schema.d.ts +1 -1
- package/dist/providers/catalog/upstage.json +165 -0
- package/dist/providers/openaiChatCompletionsClient.js +18 -1
- package/dist/proxy/globalInstaller.js +8 -1
- package/dist/types/generate.d.ts +17 -0
- package/dist/types/openaiCompatible.d.ts +5 -1
- package/dist/types/providerCatalog.generated.d.ts +2 -2
- package/dist/types/providers.d.ts +20 -0
- package/package.json +6 -2
package/dist/types/generate.d.ts
CHANGED
|
@@ -1540,3 +1540,20 @@ export type ModelAliasConfig = {
|
|
|
1540
1540
|
export type GenerateOptionsNormalized = GenerateOptions & {
|
|
1541
1541
|
input: NonNullable<GenerateOptions["input"]>;
|
|
1542
1542
|
};
|
|
1543
|
+
/**
|
|
1544
|
+
* Per-call configuration for GenerationHandler's AI-SDK loop invocation,
|
|
1545
|
+
* shared by the initial call and every fallback retry so they cannot drift.
|
|
1546
|
+
*/
|
|
1547
|
+
export type GenerationCallConfig = {
|
|
1548
|
+
shouldUseTools: boolean;
|
|
1549
|
+
includeStructuredOutput: boolean;
|
|
1550
|
+
/** Anchor for the turn deadline — the ORIGINAL executeGeneration start,
|
|
1551
|
+
* shared across fallback/provider retries so they can't refresh the
|
|
1552
|
+
* wall-clock budget. */
|
|
1553
|
+
turnStartMs: number;
|
|
1554
|
+
/** Structured-output fallback retry: also spell the JSON Schema out in the
|
|
1555
|
+
* system prompt, for vendors that ignore `response_format`. */
|
|
1556
|
+
promptJsonInstruction?: boolean;
|
|
1557
|
+
/** Set on the single toolChoice:"none" re-ask so it can never recurse. */
|
|
1558
|
+
isToolReask?: boolean;
|
|
1559
|
+
};
|
|
@@ -150,13 +150,17 @@ export type OpenAICompatChatStreamChunk = {
|
|
|
150
150
|
choices: OpenAICompatStreamChunkChoice[];
|
|
151
151
|
usage?: OpenAICompatUsage;
|
|
152
152
|
};
|
|
153
|
+
export type OpenAICompatErrorMessage = string | ReadonlyArray<{
|
|
154
|
+
msg?: string;
|
|
155
|
+
}>;
|
|
153
156
|
export type OpenAICompatErrorBody = {
|
|
154
157
|
error?: {
|
|
155
|
-
message?:
|
|
158
|
+
message?: OpenAICompatErrorMessage;
|
|
156
159
|
type?: string;
|
|
157
160
|
code?: string | number;
|
|
158
161
|
param?: string | null;
|
|
159
162
|
};
|
|
163
|
+
detail?: string;
|
|
160
164
|
};
|
|
161
165
|
export type OpenAICompatConfig = {
|
|
162
166
|
provider: string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export type CatalogProviderName = "cerebras" | "cloudflare" | "fireworks" | "groq" | "mistral" | "perplexity" | "sambanova" | "together-ai" | "xai";
|
|
2
|
-
export type CatalogCredentialKey = "cerebras" | "cloudflare" | "fireworks" | "groq" | "mistral" | "perplexity" | "sambanova" | "together" | "xai";
|
|
1
|
+
export type CatalogProviderName = "baseten" | "cerebras" | "cloudflare" | "fireworks" | "gmicloud" | "groq" | "inception-labs" | "io-intelligence" | "mistral" | "perplexity" | "sambanova" | "together-ai" | "upstage" | "xai";
|
|
2
|
+
export type CatalogCredentialKey = "baseten" | "cerebras" | "cloudflare" | "fireworks" | "gmicloud" | "groq" | "inceptionLabs" | "ioIntelligence" | "mistral" | "perplexity" | "sambanova" | "together" | "upstage" | "xai";
|
|
@@ -166,6 +166,10 @@ export type NeurolinkCredentials = {
|
|
|
166
166
|
apiKey?: string;
|
|
167
167
|
baseURL?: string;
|
|
168
168
|
};
|
|
169
|
+
baseten?: {
|
|
170
|
+
apiKey?: string;
|
|
171
|
+
baseURL?: string;
|
|
172
|
+
};
|
|
169
173
|
cerebras?: {
|
|
170
174
|
apiKey?: string;
|
|
171
175
|
baseURL?: string;
|
|
@@ -179,10 +183,22 @@ export type NeurolinkCredentials = {
|
|
|
179
183
|
apiKey?: string;
|
|
180
184
|
baseURL?: string;
|
|
181
185
|
};
|
|
186
|
+
gmicloud?: {
|
|
187
|
+
apiKey?: string;
|
|
188
|
+
baseURL?: string;
|
|
189
|
+
};
|
|
182
190
|
groq?: {
|
|
183
191
|
apiKey?: string;
|
|
184
192
|
baseURL?: string;
|
|
185
193
|
};
|
|
194
|
+
inceptionLabs?: {
|
|
195
|
+
apiKey?: string;
|
|
196
|
+
baseURL?: string;
|
|
197
|
+
};
|
|
198
|
+
ioIntelligence?: {
|
|
199
|
+
apiKey?: string;
|
|
200
|
+
baseURL?: string;
|
|
201
|
+
};
|
|
186
202
|
mistral?: {
|
|
187
203
|
apiKey?: string;
|
|
188
204
|
baseURL?: string;
|
|
@@ -199,6 +215,10 @@ export type NeurolinkCredentials = {
|
|
|
199
215
|
apiKey?: string;
|
|
200
216
|
baseURL?: string;
|
|
201
217
|
};
|
|
218
|
+
upstage?: {
|
|
219
|
+
apiKey?: string;
|
|
220
|
+
baseURL?: string;
|
|
221
|
+
};
|
|
202
222
|
xai?: {
|
|
203
223
|
apiKey?: string;
|
|
204
224
|
baseURL?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@juspay/neurolink",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.11.1",
|
|
4
4
|
"packageManager": "pnpm@10.15.1",
|
|
5
5
|
"description": "TypeScript AI SDK with 24+ LLM providers behind one consistent API. MCP-native (connect any MCP server), voice TTS/STT/realtime, RAG, agents, memory, context compaction. OpenAI · Anthropic · Gemini · Bedrock · Azure · Ollama · DeepSeek · NVIDIA NIM and more.",
|
|
6
6
|
"author": {
|
|
@@ -635,7 +635,11 @@
|
|
|
635
635
|
"@xmldom/xmldom@<0.9.12": ">=0.9.12",
|
|
636
636
|
"protobufjs@<7.6.5": ">=7.6.5",
|
|
637
637
|
"brace-expansion@>=5.0.0 <5.0.9": ">=5.0.9",
|
|
638
|
-
"@opentelemetry/core@>=2.0.0 <2.8.0": ">=2.8.0"
|
|
638
|
+
"@opentelemetry/core@>=2.0.0 <2.8.0": ">=2.8.0",
|
|
639
|
+
"qs": "6.16.0",
|
|
640
|
+
"fastify": "5.12.1",
|
|
641
|
+
"fast-uri": "3.1.6",
|
|
642
|
+
"@xmldom/xmldom": "0.9.12"
|
|
639
643
|
},
|
|
640
644
|
"patchedDependencies": {
|
|
641
645
|
"mammoth@1.12.0": "patches/mammoth@1.12.0.patch"
|