ai 3.2.0 → 3.2.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/dist/index.d.mts CHANGED
@@ -1,9 +1,10 @@
1
- import { JSONValue, CreateMessage, FunctionCall as FunctionCall$1, AssistantMessage, DataMessage } from '@ai-sdk/ui-utils';
2
- export { AssistantMessage, AssistantStatus, ChatRequest, ChatRequestOptions, CreateMessage, DataMessage, Function, FunctionCall, FunctionCallHandler, IdGenerator, JSONValue, Message, RequestOptions, StreamPart, Tool, ToolCall, ToolCallHandler, ToolChoice, ToolInvocation, UseAssistantOptions, formatStreamPart, parseComplexResponse, parseStreamPart, readDataStream } from '@ai-sdk/ui-utils';
1
+ import { DeepPartial, JSONValue, CreateMessage, FunctionCall as FunctionCall$1, AssistantMessage, DataMessage } from '@ai-sdk/ui-utils';
2
+ export { AssistantMessage, AssistantStatus, ChatRequest, ChatRequestOptions, CreateMessage, DataMessage, DeepPartial, Function, FunctionCall, FunctionCallHandler, IdGenerator, JSONValue, Message, RequestOptions, StreamPart, Tool, ToolCall, ToolCallHandler, ToolChoice, ToolInvocation, UseAssistantOptions, formatStreamPart, parseComplexResponse, parseStreamPart, readDataStream } from '@ai-sdk/ui-utils';
3
3
  import { EmbeddingModelV1, EmbeddingModelV1Embedding, LanguageModelV1, LanguageModelV1FinishReason, LanguageModelV1LogProbs, LanguageModelV1CallWarning } from '@ai-sdk/provider';
4
4
  export { APICallError, EmptyResponseBodyError, InvalidArgumentError, InvalidDataContentError, InvalidPromptError, InvalidResponseDataError, InvalidToolArgumentsError, JSONParseError, LoadAPIKeyError, NoObjectGeneratedError, NoSuchToolError, RetryError, ToolCallParseError, TypeValidationError, UnsupportedFunctionalityError, UnsupportedJSONSchemaError } from '@ai-sdk/provider';
5
5
  import { z } from 'zod';
6
- import { ServerResponse } from 'node:http';
6
+ import { ServerResponse } from 'http';
7
+ import { ServerResponse as ServerResponse$1 } from 'node:http';
7
8
  import { AssistantStream } from 'openai/lib/AssistantStream';
8
9
  import { Run } from 'openai/resources/beta/threads/runs/runs';
9
10
 
@@ -524,6 +525,11 @@ declare class GenerateObjectResult<T> {
524
525
  };
525
526
  logprobs: LogProbs | undefined;
526
527
  });
528
+ /**
529
+ Converts the object to a JSON response.
530
+ The response will have a status code of 200 and a content type of `application/json; charset=utf-8`.
531
+ */
532
+ toJsonResponse(init?: ResponseInit): Response;
527
533
  }
528
534
  /**
529
535
  * @deprecated Use `generateObject` instead.
@@ -532,22 +538,6 @@ declare const experimental_generateObject: typeof generateObject;
532
538
 
533
539
  type AsyncIterableStream<T> = AsyncIterable<T> & ReadableStream<T>;
534
540
 
535
- /**
536
- Create a type from an object with all keys and nested keys set to optional.
537
- The helper supports normal objects and Zod schemas (which are resolved automatically).
538
- It always recurses into arrays.
539
-
540
- Adopted from [type-fest](https://github.com/sindresorhus/type-fest/tree/main) PartialDeep.
541
- */
542
- type DeepPartial<T> = T extends null | undefined | string | number | boolean | symbol | bigint | void | Date | RegExp | ((...arguments_: any[]) => unknown) | (new (...arguments_: any[]) => unknown) ? T : T extends Map<infer KeyType, infer ValueType> ? PartialMap<KeyType, ValueType> : T extends Set<infer ItemType> ? PartialSet<ItemType> : T extends ReadonlyMap<infer KeyType, infer ValueType> ? PartialReadonlyMap<KeyType, ValueType> : T extends ReadonlySet<infer ItemType> ? PartialReadonlySet<ItemType> : T extends z.Schema<any> ? DeepPartial<T['_type']> : T extends object ? T extends ReadonlyArray<infer ItemType> ? ItemType[] extends T ? readonly ItemType[] extends T ? ReadonlyArray<DeepPartial<ItemType | undefined>> : Array<DeepPartial<ItemType | undefined>> : PartialObject<T> : PartialObject<T> : unknown;
543
- type PartialMap<KeyType, ValueType> = {} & Map<DeepPartial<KeyType>, DeepPartial<ValueType>>;
544
- type PartialSet<T> = {} & Set<DeepPartial<T>>;
545
- type PartialReadonlyMap<KeyType, ValueType> = {} & ReadonlyMap<DeepPartial<KeyType>, DeepPartial<ValueType>>;
546
- type PartialReadonlySet<T> = {} & ReadonlySet<DeepPartial<T>>;
547
- type PartialObject<ObjectType extends object> = {
548
- [KeyType in keyof ObjectType]?: DeepPartial<ObjectType[KeyType]>;
549
- };
550
-
551
541
  /**
552
542
  Generate a structured, typed object for a given prompt and schema using a language model.
553
543
 
@@ -655,6 +645,9 @@ type ObjectStreamInputPart = {
655
645
  type ObjectStreamPart<T> = ObjectStreamInputPart | {
656
646
  type: 'object';
657
647
  object: DeepPartial<T>;
648
+ } | {
649
+ type: 'text-delta';
650
+ textDelta: string;
658
651
  };
659
652
  /**
660
653
  The result of a `streamObject` call that contains the partial object stream and additional information.
@@ -691,8 +684,43 @@ declare class StreamObjectResult<T> {
691
684
  schema: z.Schema<T>;
692
685
  onFinish: Parameters<typeof streamObject<T>>[0]['onFinish'];
693
686
  });
687
+ /**
688
+ Stream of partial objects. It gets more complete as the stream progresses.
689
+
690
+ Note that the partial object is not validated.
691
+ If you want to be certain that the actual content matches your schema, you need to implement your own validation for partial results.
692
+ */
694
693
  get partialObjectStream(): AsyncIterableStream<DeepPartial<T>>;
694
+ /**
695
+ Text stream of the JSON representation of the generated object. It contains text chunks.
696
+ When the stream is finished, the object is valid JSON that can be parsed.
697
+ */
698
+ get textStream(): AsyncIterableStream<string>;
699
+ /**
700
+ Stream of different types of events, including partial objects, errors, and finish events.
701
+ */
695
702
  get fullStream(): AsyncIterableStream<ObjectStreamPart<T>>;
703
+ /**
704
+ Writes text delta output to a Node.js response-like object.
705
+ It sets a `Content-Type` header to `text/plain; charset=utf-8` and
706
+ writes each text delta as a separate chunk.
707
+
708
+ @param response A Node.js response-like object (ServerResponse).
709
+ @param init Optional headers and status code.
710
+ */
711
+ pipeTextStreamToResponse(response: ServerResponse, init?: {
712
+ headers?: Record<string, string>;
713
+ status?: number;
714
+ }): void;
715
+ /**
716
+ Creates a simple text stream response.
717
+ The response has a `Content-Type` header set to `text/plain; charset=utf-8`.
718
+ Each text delta is encoded as UTF-8 and sent as a separate chunk.
719
+ Non-text-delta events are ignored.
720
+
721
+ @param init Optional headers and status code.
722
+ */
723
+ toTextStreamResponse(init?: ResponseInit): Response;
696
724
  }
697
725
  /**
698
726
  * @deprecated Use `streamObject` instead.
@@ -1195,7 +1223,7 @@ declare class StreamTextResult<TOOLS extends Record<string, CoreTool>> {
1195
1223
  @param response A Node.js response-like object (ServerResponse).
1196
1224
  @param init Optional headers and status code.
1197
1225
  */
1198
- pipeAIStreamToResponse(response: ServerResponse, init?: {
1226
+ pipeAIStreamToResponse(response: ServerResponse$1, init?: {
1199
1227
  headers?: Record<string, string>;
1200
1228
  status?: number;
1201
1229
  }): void;
@@ -1207,7 +1235,7 @@ declare class StreamTextResult<TOOLS extends Record<string, CoreTool>> {
1207
1235
  @param response A Node.js response-like object (ServerResponse).
1208
1236
  @param init Optional headers and status code.
1209
1237
  */
1210
- pipeTextStreamToResponse(response: ServerResponse, init?: {
1238
+ pipeTextStreamToResponse(response: ServerResponse$1, init?: {
1211
1239
  headers?: Record<string, string>;
1212
1240
  status?: number;
1213
1241
  }): void;
@@ -2063,7 +2091,7 @@ declare class experimental_StreamData extends StreamData {
2063
2091
  /**
2064
2092
  * A utility function to stream a ReadableStream to a Node.js response-like object.
2065
2093
  */
2066
- declare function streamToResponse(res: ReadableStream, response: ServerResponse, init?: {
2094
+ declare function streamToResponse(res: ReadableStream, response: ServerResponse$1, init?: {
2067
2095
  headers?: Record<string, string>;
2068
2096
  status?: number;
2069
2097
  }, data?: StreamData): void;
@@ -2081,4 +2109,4 @@ declare const generateId: (size?: number | undefined) => string;
2081
2109
  */
2082
2110
  declare const nanoid: (size?: number | undefined) => string;
2083
2111
 
2084
- export { AIStream, AIStreamCallbacksAndOptions, AIStreamParser, AIStreamParserOptions, AWSBedrockAnthropicMessagesStream, AWSBedrockAnthropicStream, AWSBedrockCohereStream, AWSBedrockLlama2Stream, AWSBedrockStream, AnthropicStream, AssistantContent, AssistantResponse, CallWarning, CohereStream, CompletionUsage, CoreAssistantMessage, CoreMessage, CoreSystemMessage, CoreTool, CoreToolChoice, CoreToolMessage, CoreUserMessage, DataContent, DeepPartial, EmbedManyResult, EmbedResult, Embedding, EmbeddingModel, ExperimentalAssistantMessage, ExperimentalMessage, ExperimentalTool, ExperimentalToolMessage, ExperimentalUserMessage, FinishReason, FunctionCallPayload, GenerateObjectResult, GenerateTextResult, GoogleGenerativeAIStream, HuggingFaceStream, ImagePart, InkeepAIStreamCallbacksAndOptions, InkeepChatResultCallbacks, InkeepOnFinalMetadata, InkeepStream, InvalidMessageRoleError, InvalidModelIdError, langchainAdapter as LangChainAdapter, LangChainStream, LanguageModel, LogProbs, MistralStream, NoSuchModelError, NoSuchProviderError, ObjectStreamInputPart, ObjectStreamPart, OpenAIStream, OpenAIStreamCallbacks, ReplicateStream, StreamData, StreamObjectResult, StreamTextResult, StreamingTextResponse, TextPart$1 as TextPart, TextStreamPart, TokenUsage, ToolCallPart, ToolCallPayload, ToolContent, ToolResultPart, UserContent, convertDataContentToBase64String, convertDataContentToUint8Array, convertToCoreMessages, cosineSimilarity, createCallbacksTransformer, createEventStreamTransformer, createStreamDataTransformer, embed, embedMany, experimental_AssistantResponse, experimental_ModelRegistry, experimental_ProviderRegistry, experimental_StreamData, experimental_createModelRegistry, experimental_createProviderRegistry, experimental_generateObject, experimental_generateText, experimental_streamObject, experimental_streamText, generateId, generateObject, generateText, nanoid, readableFromAsyncIterable, streamObject, streamText, streamToResponse, tool, trimStartOfStreamHelper };
2112
+ export { AIStream, AIStreamCallbacksAndOptions, AIStreamParser, AIStreamParserOptions, AWSBedrockAnthropicMessagesStream, AWSBedrockAnthropicStream, AWSBedrockCohereStream, AWSBedrockLlama2Stream, AWSBedrockStream, AnthropicStream, AssistantContent, AssistantResponse, CallWarning, CohereStream, CompletionUsage, CoreAssistantMessage, CoreMessage, CoreSystemMessage, CoreTool, CoreToolChoice, CoreToolMessage, CoreUserMessage, DataContent, EmbedManyResult, EmbedResult, Embedding, EmbeddingModel, ExperimentalAssistantMessage, ExperimentalMessage, ExperimentalTool, ExperimentalToolMessage, ExperimentalUserMessage, FinishReason, FunctionCallPayload, GenerateObjectResult, GenerateTextResult, GoogleGenerativeAIStream, HuggingFaceStream, ImagePart, InkeepAIStreamCallbacksAndOptions, InkeepChatResultCallbacks, InkeepOnFinalMetadata, InkeepStream, InvalidMessageRoleError, InvalidModelIdError, langchainAdapter as LangChainAdapter, LangChainStream, LanguageModel, LogProbs, MistralStream, NoSuchModelError, NoSuchProviderError, ObjectStreamInputPart, ObjectStreamPart, OpenAIStream, OpenAIStreamCallbacks, ReplicateStream, StreamData, StreamObjectResult, StreamTextResult, StreamingTextResponse, TextPart$1 as TextPart, TextStreamPart, TokenUsage, ToolCallPart, ToolCallPayload, ToolContent, ToolResultPart, UserContent, convertDataContentToBase64String, convertDataContentToUint8Array, convertToCoreMessages, cosineSimilarity, createCallbacksTransformer, createEventStreamTransformer, createStreamDataTransformer, embed, embedMany, experimental_AssistantResponse, experimental_ModelRegistry, experimental_ProviderRegistry, experimental_StreamData, experimental_createModelRegistry, experimental_createProviderRegistry, experimental_generateObject, experimental_generateText, experimental_streamObject, experimental_streamText, generateId, generateObject, generateText, nanoid, readableFromAsyncIterable, streamObject, streamText, streamToResponse, tool, trimStartOfStreamHelper };
package/dist/index.d.ts CHANGED
@@ -1,9 +1,10 @@
1
- import { JSONValue, CreateMessage, FunctionCall as FunctionCall$1, AssistantMessage, DataMessage } from '@ai-sdk/ui-utils';
2
- export { AssistantMessage, AssistantStatus, ChatRequest, ChatRequestOptions, CreateMessage, DataMessage, Function, FunctionCall, FunctionCallHandler, IdGenerator, JSONValue, Message, RequestOptions, StreamPart, Tool, ToolCall, ToolCallHandler, ToolChoice, ToolInvocation, UseAssistantOptions, formatStreamPart, parseComplexResponse, parseStreamPart, readDataStream } from '@ai-sdk/ui-utils';
1
+ import { DeepPartial, JSONValue, CreateMessage, FunctionCall as FunctionCall$1, AssistantMessage, DataMessage } from '@ai-sdk/ui-utils';
2
+ export { AssistantMessage, AssistantStatus, ChatRequest, ChatRequestOptions, CreateMessage, DataMessage, DeepPartial, Function, FunctionCall, FunctionCallHandler, IdGenerator, JSONValue, Message, RequestOptions, StreamPart, Tool, ToolCall, ToolCallHandler, ToolChoice, ToolInvocation, UseAssistantOptions, formatStreamPart, parseComplexResponse, parseStreamPart, readDataStream } from '@ai-sdk/ui-utils';
3
3
  import { EmbeddingModelV1, EmbeddingModelV1Embedding, LanguageModelV1, LanguageModelV1FinishReason, LanguageModelV1LogProbs, LanguageModelV1CallWarning } from '@ai-sdk/provider';
4
4
  export { APICallError, EmptyResponseBodyError, InvalidArgumentError, InvalidDataContentError, InvalidPromptError, InvalidResponseDataError, InvalidToolArgumentsError, JSONParseError, LoadAPIKeyError, NoObjectGeneratedError, NoSuchToolError, RetryError, ToolCallParseError, TypeValidationError, UnsupportedFunctionalityError, UnsupportedJSONSchemaError } from '@ai-sdk/provider';
5
5
  import { z } from 'zod';
6
- import { ServerResponse } from 'node:http';
6
+ import { ServerResponse } from 'http';
7
+ import { ServerResponse as ServerResponse$1 } from 'node:http';
7
8
  import { AssistantStream } from 'openai/lib/AssistantStream';
8
9
  import { Run } from 'openai/resources/beta/threads/runs/runs';
9
10
 
@@ -524,6 +525,11 @@ declare class GenerateObjectResult<T> {
524
525
  };
525
526
  logprobs: LogProbs | undefined;
526
527
  });
528
+ /**
529
+ Converts the object to a JSON response.
530
+ The response will have a status code of 200 and a content type of `application/json; charset=utf-8`.
531
+ */
532
+ toJsonResponse(init?: ResponseInit): Response;
527
533
  }
528
534
  /**
529
535
  * @deprecated Use `generateObject` instead.
@@ -532,22 +538,6 @@ declare const experimental_generateObject: typeof generateObject;
532
538
 
533
539
  type AsyncIterableStream<T> = AsyncIterable<T> & ReadableStream<T>;
534
540
 
535
- /**
536
- Create a type from an object with all keys and nested keys set to optional.
537
- The helper supports normal objects and Zod schemas (which are resolved automatically).
538
- It always recurses into arrays.
539
-
540
- Adopted from [type-fest](https://github.com/sindresorhus/type-fest/tree/main) PartialDeep.
541
- */
542
- type DeepPartial<T> = T extends null | undefined | string | number | boolean | symbol | bigint | void | Date | RegExp | ((...arguments_: any[]) => unknown) | (new (...arguments_: any[]) => unknown) ? T : T extends Map<infer KeyType, infer ValueType> ? PartialMap<KeyType, ValueType> : T extends Set<infer ItemType> ? PartialSet<ItemType> : T extends ReadonlyMap<infer KeyType, infer ValueType> ? PartialReadonlyMap<KeyType, ValueType> : T extends ReadonlySet<infer ItemType> ? PartialReadonlySet<ItemType> : T extends z.Schema<any> ? DeepPartial<T['_type']> : T extends object ? T extends ReadonlyArray<infer ItemType> ? ItemType[] extends T ? readonly ItemType[] extends T ? ReadonlyArray<DeepPartial<ItemType | undefined>> : Array<DeepPartial<ItemType | undefined>> : PartialObject<T> : PartialObject<T> : unknown;
543
- type PartialMap<KeyType, ValueType> = {} & Map<DeepPartial<KeyType>, DeepPartial<ValueType>>;
544
- type PartialSet<T> = {} & Set<DeepPartial<T>>;
545
- type PartialReadonlyMap<KeyType, ValueType> = {} & ReadonlyMap<DeepPartial<KeyType>, DeepPartial<ValueType>>;
546
- type PartialReadonlySet<T> = {} & ReadonlySet<DeepPartial<T>>;
547
- type PartialObject<ObjectType extends object> = {
548
- [KeyType in keyof ObjectType]?: DeepPartial<ObjectType[KeyType]>;
549
- };
550
-
551
541
  /**
552
542
  Generate a structured, typed object for a given prompt and schema using a language model.
553
543
 
@@ -655,6 +645,9 @@ type ObjectStreamInputPart = {
655
645
  type ObjectStreamPart<T> = ObjectStreamInputPart | {
656
646
  type: 'object';
657
647
  object: DeepPartial<T>;
648
+ } | {
649
+ type: 'text-delta';
650
+ textDelta: string;
658
651
  };
659
652
  /**
660
653
  The result of a `streamObject` call that contains the partial object stream and additional information.
@@ -691,8 +684,43 @@ declare class StreamObjectResult<T> {
691
684
  schema: z.Schema<T>;
692
685
  onFinish: Parameters<typeof streamObject<T>>[0]['onFinish'];
693
686
  });
687
+ /**
688
+ Stream of partial objects. It gets more complete as the stream progresses.
689
+
690
+ Note that the partial object is not validated.
691
+ If you want to be certain that the actual content matches your schema, you need to implement your own validation for partial results.
692
+ */
694
693
  get partialObjectStream(): AsyncIterableStream<DeepPartial<T>>;
694
+ /**
695
+ Text stream of the JSON representation of the generated object. It contains text chunks.
696
+ When the stream is finished, the object is valid JSON that can be parsed.
697
+ */
698
+ get textStream(): AsyncIterableStream<string>;
699
+ /**
700
+ Stream of different types of events, including partial objects, errors, and finish events.
701
+ */
695
702
  get fullStream(): AsyncIterableStream<ObjectStreamPart<T>>;
703
+ /**
704
+ Writes text delta output to a Node.js response-like object.
705
+ It sets a `Content-Type` header to `text/plain; charset=utf-8` and
706
+ writes each text delta as a separate chunk.
707
+
708
+ @param response A Node.js response-like object (ServerResponse).
709
+ @param init Optional headers and status code.
710
+ */
711
+ pipeTextStreamToResponse(response: ServerResponse, init?: {
712
+ headers?: Record<string, string>;
713
+ status?: number;
714
+ }): void;
715
+ /**
716
+ Creates a simple text stream response.
717
+ The response has a `Content-Type` header set to `text/plain; charset=utf-8`.
718
+ Each text delta is encoded as UTF-8 and sent as a separate chunk.
719
+ Non-text-delta events are ignored.
720
+
721
+ @param init Optional headers and status code.
722
+ */
723
+ toTextStreamResponse(init?: ResponseInit): Response;
696
724
  }
697
725
  /**
698
726
  * @deprecated Use `streamObject` instead.
@@ -1195,7 +1223,7 @@ declare class StreamTextResult<TOOLS extends Record<string, CoreTool>> {
1195
1223
  @param response A Node.js response-like object (ServerResponse).
1196
1224
  @param init Optional headers and status code.
1197
1225
  */
1198
- pipeAIStreamToResponse(response: ServerResponse, init?: {
1226
+ pipeAIStreamToResponse(response: ServerResponse$1, init?: {
1199
1227
  headers?: Record<string, string>;
1200
1228
  status?: number;
1201
1229
  }): void;
@@ -1207,7 +1235,7 @@ declare class StreamTextResult<TOOLS extends Record<string, CoreTool>> {
1207
1235
  @param response A Node.js response-like object (ServerResponse).
1208
1236
  @param init Optional headers and status code.
1209
1237
  */
1210
- pipeTextStreamToResponse(response: ServerResponse, init?: {
1238
+ pipeTextStreamToResponse(response: ServerResponse$1, init?: {
1211
1239
  headers?: Record<string, string>;
1212
1240
  status?: number;
1213
1241
  }): void;
@@ -2063,7 +2091,7 @@ declare class experimental_StreamData extends StreamData {
2063
2091
  /**
2064
2092
  * A utility function to stream a ReadableStream to a Node.js response-like object.
2065
2093
  */
2066
- declare function streamToResponse(res: ReadableStream, response: ServerResponse, init?: {
2094
+ declare function streamToResponse(res: ReadableStream, response: ServerResponse$1, init?: {
2067
2095
  headers?: Record<string, string>;
2068
2096
  status?: number;
2069
2097
  }, data?: StreamData): void;
@@ -2081,4 +2109,4 @@ declare const generateId: (size?: number | undefined) => string;
2081
2109
  */
2082
2110
  declare const nanoid: (size?: number | undefined) => string;
2083
2111
 
2084
- export { AIStream, AIStreamCallbacksAndOptions, AIStreamParser, AIStreamParserOptions, AWSBedrockAnthropicMessagesStream, AWSBedrockAnthropicStream, AWSBedrockCohereStream, AWSBedrockLlama2Stream, AWSBedrockStream, AnthropicStream, AssistantContent, AssistantResponse, CallWarning, CohereStream, CompletionUsage, CoreAssistantMessage, CoreMessage, CoreSystemMessage, CoreTool, CoreToolChoice, CoreToolMessage, CoreUserMessage, DataContent, DeepPartial, EmbedManyResult, EmbedResult, Embedding, EmbeddingModel, ExperimentalAssistantMessage, ExperimentalMessage, ExperimentalTool, ExperimentalToolMessage, ExperimentalUserMessage, FinishReason, FunctionCallPayload, GenerateObjectResult, GenerateTextResult, GoogleGenerativeAIStream, HuggingFaceStream, ImagePart, InkeepAIStreamCallbacksAndOptions, InkeepChatResultCallbacks, InkeepOnFinalMetadata, InkeepStream, InvalidMessageRoleError, InvalidModelIdError, langchainAdapter as LangChainAdapter, LangChainStream, LanguageModel, LogProbs, MistralStream, NoSuchModelError, NoSuchProviderError, ObjectStreamInputPart, ObjectStreamPart, OpenAIStream, OpenAIStreamCallbacks, ReplicateStream, StreamData, StreamObjectResult, StreamTextResult, StreamingTextResponse, TextPart$1 as TextPart, TextStreamPart, TokenUsage, ToolCallPart, ToolCallPayload, ToolContent, ToolResultPart, UserContent, convertDataContentToBase64String, convertDataContentToUint8Array, convertToCoreMessages, cosineSimilarity, createCallbacksTransformer, createEventStreamTransformer, createStreamDataTransformer, embed, embedMany, experimental_AssistantResponse, experimental_ModelRegistry, experimental_ProviderRegistry, experimental_StreamData, experimental_createModelRegistry, experimental_createProviderRegistry, experimental_generateObject, experimental_generateText, experimental_streamObject, experimental_streamText, generateId, generateObject, generateText, nanoid, readableFromAsyncIterable, streamObject, streamText, streamToResponse, tool, trimStartOfStreamHelper };
2112
+ export { AIStream, AIStreamCallbacksAndOptions, AIStreamParser, AIStreamParserOptions, AWSBedrockAnthropicMessagesStream, AWSBedrockAnthropicStream, AWSBedrockCohereStream, AWSBedrockLlama2Stream, AWSBedrockStream, AnthropicStream, AssistantContent, AssistantResponse, CallWarning, CohereStream, CompletionUsage, CoreAssistantMessage, CoreMessage, CoreSystemMessage, CoreTool, CoreToolChoice, CoreToolMessage, CoreUserMessage, DataContent, EmbedManyResult, EmbedResult, Embedding, EmbeddingModel, ExperimentalAssistantMessage, ExperimentalMessage, ExperimentalTool, ExperimentalToolMessage, ExperimentalUserMessage, FinishReason, FunctionCallPayload, GenerateObjectResult, GenerateTextResult, GoogleGenerativeAIStream, HuggingFaceStream, ImagePart, InkeepAIStreamCallbacksAndOptions, InkeepChatResultCallbacks, InkeepOnFinalMetadata, InkeepStream, InvalidMessageRoleError, InvalidModelIdError, langchainAdapter as LangChainAdapter, LangChainStream, LanguageModel, LogProbs, MistralStream, NoSuchModelError, NoSuchProviderError, ObjectStreamInputPart, ObjectStreamPart, OpenAIStream, OpenAIStreamCallbacks, ReplicateStream, StreamData, StreamObjectResult, StreamTextResult, StreamingTextResponse, TextPart$1 as TextPart, TextStreamPart, TokenUsage, ToolCallPart, ToolCallPayload, ToolContent, ToolResultPart, UserContent, convertDataContentToBase64String, convertDataContentToUint8Array, convertToCoreMessages, cosineSimilarity, createCallbacksTransformer, createEventStreamTransformer, createStreamDataTransformer, embed, embedMany, experimental_AssistantResponse, experimental_ModelRegistry, experimental_ProviderRegistry, experimental_StreamData, experimental_createModelRegistry, experimental_createProviderRegistry, experimental_generateObject, experimental_generateText, experimental_streamObject, experimental_streamText, generateId, generateObject, generateText, nanoid, readableFromAsyncIterable, streamObject, streamText, streamToResponse, tool, trimStartOfStreamHelper };