import { b as CreateProviderOptions, C as ChatProvider, a as ChatProviderWithExtraOptions, E as EmbedProvider, c as EmbedProviderWithExtraOptions, I as ImageProvider, M as ModelProvider, d as ModelProviderWithExtraOptions, S as SpeechProvider, e as SpeechProviderWithExtraOptions, T as TranscriptionProvider, f as TranscriptionProviderWithExtraOptions } from '../types-DW1hvH0W.js'; import '@xsai/shared'; declare const createChatProvider: (options: CreateProviderOptions) => ChatProvider; declare const createChatProviderWithExtraOptions: (options: CreateProviderOptions) => ChatProviderWithExtraOptions; declare const createEmbedProvider: (options: CreateProviderOptions) => EmbedProvider; declare const createEmbedProviderWithExtraOptions: (options: CreateProviderOptions) => EmbedProviderWithExtraOptions; declare const createImageProvider: (options: CreateProviderOptions) => ImageProvider; declare const createModelProvider: (options: CreateProviderOptions) => ModelProvider; declare const createModelProviderWithExtraOptions: (options: Omit) => ModelProviderWithExtraOptions; declare const createSpeechProvider: (options: CreateProviderOptions) => SpeechProvider; declare const createSpeechProviderWithExtraOptions: (options: CreateProviderOptions) => SpeechProviderWithExtraOptions; declare const createTranscriptionProvider: (options: CreateProviderOptions) => TranscriptionProvider; declare const createTranscriptionProviderWithExtraOptions: (options: CreateProviderOptions) => TranscriptionProviderWithExtraOptions; /** Convert a union type to an intersection type. Inspired by [this Stack Overflow answer](https://stackoverflow.com/a/50375286/2172153). @example ``` import type {UnionToIntersection} from 'type-fest'; type Union = {the(): void} | {great(arg: string): void} | {escape: boolean}; type Intersection = UnionToIntersection; //=> {the(): void} & {great(arg: string): void} & {escape: boolean} ``` @category Type */ type UnionToIntersection = ( // `extends unknown` is always going to be the case and is used to convert the // `Union` into a [distributive conditional // type](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-8.html#distributive-conditional-types). Union extends unknown // The union type is used as the only argument to a function since the union // of function arguments is an intersection. ? (distributedUnion: Union) => void // This won't happen. : never // Infer the `Intersection` type since TypeScript represents the positional // arguments of unions of functions as an intersection of the union. ) extends ((mergedIntersection: infer Intersection) => void) // The `& Union` is to ensure result of `UnionToIntersection` is always assignable to `A | B` ? Intersection & Union : never; declare const merge: (...arr: T) => UnionToIntersection; export { ChatProvider, ChatProviderWithExtraOptions, CreateProviderOptions, EmbedProvider, EmbedProviderWithExtraOptions, ImageProvider, ModelProvider, ModelProviderWithExtraOptions, SpeechProvider, SpeechProviderWithExtraOptions, TranscriptionProvider, TranscriptionProviderWithExtraOptions, createChatProvider, createChatProviderWithExtraOptions, createEmbedProvider, createEmbedProviderWithExtraOptions, createImageProvider, createModelProvider, createModelProviderWithExtraOptions, createSpeechProvider, createSpeechProviderWithExtraOptions, createTranscriptionProvider, createTranscriptionProviderWithExtraOptions, merge };