Class References
Function References
- text
- textOptions
- combineStrategies
- convertMessagesToModelMessages
- convertZodToJsonSchema
- createReplayStream
- embedding
- generateMessageId
- maxIterations
- messages
- modelMessageToUIMessage
- modelMessagesToUIMessages
- normalizeToUIMessage
- parsePartialJSON
- summarize
- toServerSentEventsStream
- toServerSentEventsResponse
- toolDefinition
- uiMessageToModelMessages
- realtimeToken
- untilFinishReason
Interface References
- AIAdapter
- AIAdapterConfig
- AgentLoopState
- AudioPart
- AudioVisualization
- BaseStreamChunk
- TextCompletionChunk
- TextOptions
- ChunkRecording
- ChunkStrategy
- ClientTool
- ContentPartSource
- ContentStreamChunk
- DefaultMessageMetadataByModality
- DocumentPart
- DoneStreamChunk
- EmbeddingOptions
- EmbeddingResult
- ErrorStreamChunk
- ImagePart
- InternalToolCallState
- JSONParser
- ModelMessage
- ProcessorResult
- ProcessorState
- RealtimeAdapter
- RealtimeClientOptions
- RealtimeConnection
- RealtimeMessage
- RealtimeSessionConfig
- RealtimeToken
- RealtimeTokenAdapter
- RealtimeTokenOptions
- ResponseFormat
- ServerTool
- StreamProcessorEvents
- StreamProcessorHandlers
- StreamProcessorOptions
- SummarizationOptions
- SummarizationResult
- TextPart
- ThinkingPart
- ThinkingStreamChunk
- Tool
- ToolCall
- ToolCallPart
- ToolCallStreamChunk
- ToolConfig
- ToolDefinition
- ToolDefinitionConfig
- ToolDefinitionInstance
- ToolInputAvailableStreamChunk
- ToolResultPart
- ToolResultStreamChunk
- UIMessage
- VideoPart
Type Alias References
- AgentLoopStrategy
- AnyClientTool
- TextStreamOptionsForModel
- TextStreamOptionsUnion
- ConstrainedContent
- ConstrainedModelMessage
- ContentPart
- ContentPartForModalities
- ExtractModalitiesForModel
- ExtractModelsFromAdapter
- InferToolInput
- InferToolName
- InferToolOutput
- MessagePart
- RealtimeEvent
- RealtimeMessagePart
- RealtimeMode
- RealtimeStatus
- ModalitiesArrayToUnion
- Modality
- StreamChunk
- ToolCallState
- ToolResultState
Variable References
TTSResult
Defined in: packages/ai/src/types.ts:2976
Result of text-to-speech generation.
Properties#
alignment?#
optional alignment?: TTSAlignment;Defined in: packages/ai/src/types.ts:2991
Character- or word-level timings, present when timestamps: true was requested. Use this rather than duration to find where speech ends.
artifacts?#
optional artifacts?: PersistedArtifactRef[];Defined in: packages/ai/src/types.ts:3002
Persisted artifact references for generated assets, when available
audio#
audio: string;Defined in: packages/ai/src/types.ts:2982
Base64-encoded audio data
contentType?#
optional contentType?: string;Defined in: packages/ai/src/types.ts:2998
Content type of the audio (e.g., 'audio/mp3')
duration?#
optional duration?: number;Defined in: packages/ai/src/types.ts:2986
Duration of the audio file in seconds, if available
format#
format: string;Defined in: packages/ai/src/types.ts:2984
Audio format of the generated audio
id#
id: string;Defined in: packages/ai/src/types.ts:2978
Unique identifier for the generation
model#
model: string;Defined in: packages/ai/src/types.ts:2980
Model used for generation
segments?#
optional segments?: TTSSegment[];Defined in: packages/ai/src/types.ts:2996
Per-turn (or per-utterance) spans of the audio, present when timestamps: true was requested and the provider reports segmentation.
usage?#
optional usage?: TokenUsage<ProviderUsageDetails>;Defined in: packages/ai/src/types.ts:3000
Token usage information (if provided by the adapter)