@juspay/neurolink 12.4.0 → 12.4.2
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/core/baseProvider.d.ts +1 -1
- package/dist/core/baseProvider.js +2 -2
- package/dist/evaluation/scorers/rule/formatScorer.js +1 -1
- package/dist/mcp/mcpRegistryClient.js +1 -1
- package/dist/middleware/utils/guardrailsUtils.js +1 -1
- package/dist/neurolink.js +2 -2
- package/dist/rag/ChunkerFactory.js +1 -1
- package/dist/server/websocket/WebSocketHandler.js +3 -3
- package/dist/workflow/config.d.ts +1 -1
- package/dist/workflow/config.js +1 -1
- package/dist/workflow/core/workflowRegistry.js +1 -1
- package/dist/workflow/core/workflowRunner.js +1 -1
- package/dist/workflow/utils/workflowMetrics.d.ts +1 -1
- package/dist/workflow/utils/workflowMetrics.js +1 -1
- package/package.json +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
## [12.4.
|
|
1
|
+
## [12.4.2](https://github.com/juspay/neurolink/compare/v12.4.1...v12.4.2) (2026-08-28)
|
|
2
2
|
|
|
3
|
-
###
|
|
3
|
+
### Bug Fixes
|
|
4
4
|
|
|
5
|
-
- **(
|
|
5
|
+
- **(tools):** make the onboarding gate check providerMatrix too ([9008532](https://github.com/juspay/neurolink/commit/9008532b823a9d7f64ae613ef8b6fd4d1274a50b)), closes [#1561](https://github.com/juspay/neurolink/issues/1561) [#1564](https://github.com/juspay/neurolink/issues/1564)
|
|
6
6
|
|
|
7
7
|
## [11.2.3](https://github.com/juspay/neurolink/compare/v11.2.2...v11.2.3) (2026-08-19)
|
|
8
8
|
|
|
@@ -341,7 +341,7 @@ export declare abstract class BaseProvider implements AIProvider {
|
|
|
341
341
|
/**
|
|
342
342
|
* Get AI SDK model with middleware applied
|
|
343
343
|
* This method wraps the base model with any configured middleware
|
|
344
|
-
* TODO(#
|
|
344
|
+
* TODO(#1576): Implement global level middlewares that can be used
|
|
345
345
|
*/
|
|
346
346
|
protected getAISDKModelWithMiddleware(options?: TextGenerationOptions | StreamOptions): Promise<LanguageModel>;
|
|
347
347
|
/**
|
|
@@ -102,7 +102,7 @@ export class BaseProvider {
|
|
|
102
102
|
modelName;
|
|
103
103
|
providerName;
|
|
104
104
|
defaultTimeout = 30000; // 30 seconds
|
|
105
|
-
middlewareOptions; // TODO(#
|
|
105
|
+
middlewareOptions; // TODO(#1576): Implement global level middlewares that can be used
|
|
106
106
|
// Tools are conditionally included based on centralized configuration
|
|
107
107
|
directTools = shouldDisableBuiltinTools()
|
|
108
108
|
? {}
|
|
@@ -1584,7 +1584,7 @@ export class BaseProvider {
|
|
|
1584
1584
|
/**
|
|
1585
1585
|
* Get AI SDK model with middleware applied
|
|
1586
1586
|
* This method wraps the base model with any configured middleware
|
|
1587
|
-
* TODO(#
|
|
1587
|
+
* TODO(#1576): Implement global level middlewares that can be used
|
|
1588
1588
|
*/
|
|
1589
1589
|
async getAISDKModelWithMiddleware(options = {}) {
|
|
1590
1590
|
// Get the base model
|
|
@@ -396,7 +396,7 @@ export class FormatScorer extends BaseRuleScorer {
|
|
|
396
396
|
// First check if it's valid JSON
|
|
397
397
|
try {
|
|
398
398
|
JSON.parse(text);
|
|
399
|
-
// TODO(#
|
|
399
|
+
// TODO(#1576): Implement full JSON Schema validation
|
|
400
400
|
// For now, just check it's valid JSON
|
|
401
401
|
return { passed: true, score: 1.0 };
|
|
402
402
|
}
|
|
@@ -318,7 +318,7 @@ export function applyContentFiltering(text, badWordsConfig, context = "unknown")
|
|
|
318
318
|
logger.debug(`[ContentFiltering:${context}] Applying regex pattern filtering with ${badWordsConfig.regexPatterns.length} patterns using replacement: "${replacementText}".`);
|
|
319
319
|
for (const pattern of badWordsConfig.regexPatterns) {
|
|
320
320
|
try {
|
|
321
|
-
// TODO(#
|
|
321
|
+
// TODO(#1576): Add blocking for overly complex or long patterns
|
|
322
322
|
if (pattern.length > 1000) {
|
|
323
323
|
logger.warn(`[ContentFiltering:${context}] Regex pattern exceeds max length (1000 chars): "${pattern.substring(0, 50)}..."`);
|
|
324
324
|
}
|
package/dist/neurolink.js
CHANGED
|
@@ -9283,7 +9283,7 @@ Current user's request: ${currentInput}`;
|
|
|
9283
9283
|
// ========================================
|
|
9284
9284
|
// ENHANCED: Tool Event Emission API
|
|
9285
9285
|
// ========================================
|
|
9286
|
-
// TODO(#
|
|
9286
|
+
// TODO(#1576): Add ToolExecutionEvent utility methods in future version
|
|
9287
9287
|
// Will provide structured event format for consistent tool event processing
|
|
9288
9288
|
/**
|
|
9289
9289
|
* Emit tool start event with execution tracking
|
|
@@ -9406,7 +9406,7 @@ Current user's request: ${currentInput}`;
|
|
|
9406
9406
|
clearCurrentStreamExecutions() {
|
|
9407
9407
|
this.currentStreamToolExecutions = [];
|
|
9408
9408
|
}
|
|
9409
|
-
// TODO(#
|
|
9409
|
+
// TODO(#1576): Add getToolExecutionEvents() method in future version
|
|
9410
9410
|
// Will return properly formatted ToolExecutionEvent objects for structured event processing
|
|
9411
9411
|
// ========================================
|
|
9412
9412
|
// Tool Registration API
|
|
@@ -177,7 +177,7 @@ export class ChunkerFactory extends BaseFactory {
|
|
|
177
177
|
}, DEFAULT_CHUNKER_METADATA.latex);
|
|
178
178
|
// Register semantic chunker (placeholder - uses recursive as fallback)
|
|
179
179
|
this.registerChunker("semantic", async (config) => {
|
|
180
|
-
// TODO(#
|
|
180
|
+
// TODO(#1576): Implement dedicated SemanticChunker with LLM support
|
|
181
181
|
// For now, fall back to RecursiveChunker with semantic defaults
|
|
182
182
|
const { RecursiveChunker } = await import("./chunkers/RecursiveChunker.js");
|
|
183
183
|
return new RecursiveChunker(config);
|
|
@@ -334,17 +334,17 @@ export function createAgentWebSocketHandler(_neurolink) {
|
|
|
334
334
|
// Register message routes
|
|
335
335
|
router.route("generate", async (connection, payload) => {
|
|
336
336
|
const { prompt, options: _options } = payload;
|
|
337
|
-
// TODO(#
|
|
337
|
+
// TODO(#1576): Implement generate using neurolink
|
|
338
338
|
return { type: "response", data: `Received: ${prompt}` };
|
|
339
339
|
});
|
|
340
340
|
router.route("stream", async (connection, payload) => {
|
|
341
341
|
const { prompt, options: _options } = payload;
|
|
342
|
-
// TODO(#
|
|
342
|
+
// TODO(#1576): Implement streaming using neurolink
|
|
343
343
|
return { type: "stream_start", data: { prompt } };
|
|
344
344
|
});
|
|
345
345
|
router.route("tool_call", async (connection, payload) => {
|
|
346
346
|
const { toolName, args: _args } = payload;
|
|
347
|
-
// TODO(#
|
|
347
|
+
// TODO(#1576): Implement tool call using neurolink
|
|
348
348
|
return { type: "tool_result", data: { toolName, result: null } };
|
|
349
349
|
});
|
|
350
350
|
return {
|
|
@@ -368,7 +368,7 @@ export declare function hasJudge(config: WorkflowConfig): boolean;
|
|
|
368
368
|
export declare function getAllJudges(config: WorkflowConfig): JudgeConfig[];
|
|
369
369
|
/**
|
|
370
370
|
* Calculate estimated workflow cost (placeholder)
|
|
371
|
-
* TODO(#
|
|
371
|
+
* TODO(#1576): Implement actual provider-specific pricing
|
|
372
372
|
* @param config - Workflow configuration
|
|
373
373
|
* @param estimatedTokens - Estimated number of tokens for the request
|
|
374
374
|
* @returns Estimated cost in USD
|
package/dist/workflow/config.js
CHANGED
|
@@ -383,7 +383,7 @@ export function getAllJudges(config) {
|
|
|
383
383
|
}
|
|
384
384
|
/**
|
|
385
385
|
* Calculate estimated workflow cost (placeholder)
|
|
386
|
-
* TODO(#
|
|
386
|
+
* TODO(#1576): Implement actual provider-specific pricing
|
|
387
387
|
* @param config - Workflow configuration
|
|
388
388
|
* @param estimatedTokens - Estimated number of tokens for the request
|
|
389
389
|
* @returns Estimated cost in USD
|
|
@@ -10,7 +10,7 @@ const functionTag = "WorkflowRegistry";
|
|
|
10
10
|
// ============================================================================
|
|
11
11
|
/**
|
|
12
12
|
* In-memory workflow registry
|
|
13
|
-
* TODO(#
|
|
13
|
+
* TODO(#1576): Consider persistent storage in future phases
|
|
14
14
|
*/
|
|
15
15
|
const workflowRegistry = new Map();
|
|
16
16
|
// ============================================================================
|
|
@@ -158,7 +158,7 @@ export async function runWorkflow(config, options) {
|
|
|
158
158
|
totalInputTokens: calculateInputTokens(ensembleResult.responses),
|
|
159
159
|
totalOutputTokens: calculateOutputTokens(ensembleResult.responses),
|
|
160
160
|
totalTokens: calculateTotalTokens(ensembleResult.responses),
|
|
161
|
-
byModel: [], // TODO(#
|
|
161
|
+
byModel: [], // TODO(#1576): Populate per-model breakdown
|
|
162
162
|
},
|
|
163
163
|
// Additional metadata
|
|
164
164
|
metadata: options.metadata,
|
|
@@ -46,7 +46,7 @@ export declare function calculateModelMetrics(responses: EnsembleResponse[]): Re
|
|
|
46
46
|
/**
|
|
47
47
|
* Calculate consensus level between responses
|
|
48
48
|
* NOTE: Placeholder implementation - uses response length similarity
|
|
49
|
-
* TODO(#
|
|
49
|
+
* TODO(#1576): Implement semantic similarity in Phase 2
|
|
50
50
|
*/
|
|
51
51
|
export declare function calculateConsensus(responses: EnsembleResponse[]): number;
|
|
52
52
|
/**
|
|
@@ -159,7 +159,7 @@ export function calculateModelMetrics(responses) {
|
|
|
159
159
|
/**
|
|
160
160
|
* Calculate consensus level between responses
|
|
161
161
|
* NOTE: Placeholder implementation - uses response length similarity
|
|
162
|
-
* TODO(#
|
|
162
|
+
* TODO(#1576): Implement semantic similarity in Phase 2
|
|
163
163
|
*/
|
|
164
164
|
export function calculateConsensus(responses) {
|
|
165
165
|
const successful = responses.filter((r) => r.status === "success");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@juspay/neurolink",
|
|
3
|
-
"version": "12.4.
|
|
3
|
+
"version": "12.4.2",
|
|
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": {
|
|
@@ -215,6 +215,7 @@
|
|
|
215
215
|
"test:archive:security": "pnpm exec tsx test/continuous-test-suite-archive-security.ts",
|
|
216
216
|
"test:office:security": "pnpm exec tsx test/continuous-test-suite-office-security.ts",
|
|
217
217
|
"test:model-pool": "pnpm exec tsx test/continuous-test-suite-model-pool.ts",
|
|
218
|
+
"test:agents": "pnpm exec tsx test/continuous-test-suite-agents.ts",
|
|
218
219
|
"test:classifier-router": "pnpm exec tsx test/continuous-test-suite-classifier-router.ts",
|
|
219
220
|
"test:vector-chroma": "pnpm exec tsx test/continuous-test-suite-vector-chroma.ts",
|
|
220
221
|
"test:vector-pgvector": "pnpm exec tsx test/continuous-test-suite-vector-pgvector.ts",
|