@juspay/neurolink 9.67.2 → 9.68.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.
@@ -212,7 +212,6 @@ export type StreamLoopArgs = {
212
212
  maxSteps: number;
213
213
  modelId: string;
214
214
  url: string;
215
- apiKey: string;
216
215
  fetchImpl: typeof fetch;
217
216
  abortSignal: AbortSignal | undefined;
218
217
  options: StreamOptions;
@@ -248,3 +247,23 @@ export type OpenAICompatBuildBodyArgs = {
248
247
  streaming: boolean;
249
248
  responseFormat?: OpenAICompatResponseFormat;
250
249
  };
250
+ /**
251
+ * Per-stream lifecycle listeners returned from an OpenAIChatCompletionsProvider
252
+ * subclass's `onStreamStart` hook. Every property is optional — provide only
253
+ * what the subclass cares about. Used by LiteLLM to wire an OTel span around
254
+ * the deferred analytics promises.
255
+ */
256
+ export type OpenAICompatStreamLifecycleListeners = {
257
+ /** Fired once the deferred usage promise resolves with the final aggregated token counts. */
258
+ onUsage?: (usage: {
259
+ promptTokens: number;
260
+ completionTokens: number;
261
+ totalTokens: number;
262
+ }) => void;
263
+ /**
264
+ * Fired once the deferred finish promise resolves. `reason` is "stop",
265
+ * "length", "tool-calls", "content-filter", or "error". When the loop
266
+ * errored, the upstream cause is passed as `capturedError`.
267
+ */
268
+ onFinish?: (reason: string, capturedError?: unknown) => void;
269
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@juspay/neurolink",
3
- "version": "9.67.2",
3
+ "version": "9.68.0",
4
4
  "packageManager": "pnpm@10.15.1",
5
5
  "description": "Universal AI Development Platform with working MCP integration, multi-provider support, voice (TTS/STT/realtime), and professional CLI. 58+ external MCP servers discoverable, multimodal file processing, RAG pipelines. Build, test, and deploy AI applications with 21+ providers: OpenAI, Anthropic, Google AI Studio, Google Vertex, AWS Bedrock, Azure OpenAI, Mistral, LiteLLM, SageMaker, Hugging Face, Ollama, OpenAI-compatible, OpenRouter, DeepSeek, NVIDIA NIM, LM Studio, llama.cpp, plus voice (OpenAI TTS, ElevenLabs, Deepgram, Azure Speech).",
6
6
  "author": {