Skip to content

AxAIService

Interface: AxAIService

Methods

chat()

chat(req, options?): Promise<AxChatResponse | ReadableStream<AxChatResponse>>

Parameters

req: Readonly<AxChatRequest>

options?: Readonly<AxAIPromptConfig & AxAIServiceActionOptions>

Returns

Promise<AxChatResponse | ReadableStream<AxChatResponse>>

Defined in

src/ax/ai/types.ts:189


embed()

embed(req, options?): Promise<AxEmbedResponse>

Parameters

req: Readonly<AxEmbedRequest>

options?: Readonly<AxAIServiceActionOptions>

Returns

Promise<AxEmbedResponse>

Defined in

src/ax/ai/types.ts:193


getEmbedModelInfo()

getEmbedModelInfo(): undefined | Readonly<AxModelInfoWithProvider>

Returns

undefined | Readonly<AxModelInfoWithProvider>

Defined in

src/ax/ai/types.ts:184


getFeatures()

getFeatures(): object

Returns

object

functions

functions: boolean

streaming

streaming: boolean

Defined in

src/ax/ai/types.ts:186


getModelConfig()

getModelConfig(): Readonly<AxModelConfig>

Returns

Readonly<AxModelConfig>

Defined in

src/ax/ai/types.ts:185


getModelInfo()

getModelInfo(): Readonly<AxModelInfoWithProvider>

Returns

Readonly<AxModelInfoWithProvider>

Defined in

src/ax/ai/types.ts:183


getModelMap()

getModelMap(): undefined | AxAIModelMap

Returns

undefined | AxAIModelMap

Defined in

src/ax/ai/types.ts:187


getName()

getName(): string

Returns

string

Defined in

src/ax/ai/types.ts:182


setOptions()

setOptions(options): void

Parameters

options: Readonly<AxAIServiceOptions>

Returns

void

Defined in

src/ax/ai/types.ts:198