AxAI
Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L184
Type Parameters
| Type Parameter | Default type |
|---|---|
TModelKey | string |
Implements
AxAIService<any,any,TModelKey>
Methods
chat()
chat(req: Readonly<AxChatRequest<TModelKey>>, options?: Readonly<AxAIServiceOptions>): Promise<
| AxChatResponse
| ReadableStream<AxChatResponse>>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L265
Parameters
| Parameter | Type |
|---|---|
req | Readonly<AxChatRequest<TModelKey>> |
options? | Readonly<AxAIServiceOptions> |
Returns
Promise<
| AxChatResponse
| ReadableStream<AxChatResponse>>
Implementation of
embed()
embed(req: Readonly<AxEmbedRequest<TModelKey>>, options?: Readonly<AxAIServiceOptions>): Promise<AxEmbedResponse>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L272
Parameters
| Parameter | Type |
|---|---|
req | Readonly<AxEmbedRequest<TModelKey>> |
options? | Readonly<AxAIServiceOptions> |
Returns
Promise<AxEmbedResponse>
Implementation of
getEstimatedCost()
getEstimatedCost(modelUsage?: AxModelUsage): number;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L261
Parameters
| Parameter | Type |
|---|---|
modelUsage? | AxModelUsage |
Returns
number
Implementation of
getFeatures()
getFeatures(model?: string): AxAIFeatures;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L237
Parameters
| Parameter | Type |
|---|---|
model? | string |
Returns
Implementation of
getId()
getId(): string;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L233
Returns
string
Implementation of
getLastUsedChatModel()
getLastUsedChatModel(): any;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L245
Returns
any
Implementation of
AxAIService.getLastUsedChatModel
getLastUsedEmbedModel()
getLastUsedEmbedModel(): any;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L249
Returns
any
Implementation of
AxAIService.getLastUsedEmbedModel
getLastUsedModelConfig()
getLastUsedModelConfig(): undefined | AxModelConfig;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L253
Returns
undefined | AxModelConfig
Implementation of
AxAIService.getLastUsedModelConfig
getLogger()
getLogger(): AxLoggerFunction;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L301
Returns
Implementation of
getMetrics()
getMetrics(): AxAIServiceMetrics;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L257
Returns
Implementation of
getModelList()
getModelList():
| undefined
| AxAIModelList<TModelKey>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L241
Returns
| undefined
| AxAIModelList<TModelKey>
Implementation of
getName()
getName(): string;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L229
Returns
string
Implementation of
getOptions()
getOptions(): Readonly<AxAIServiceOptions>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L297
Returns
Readonly<AxAIServiceOptions>
Implementation of
setOptions()
setOptions(options: Readonly<AxAIServiceOptions>): void;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L293
Parameters
| Parameter | Type |
|---|---|
options | Readonly<AxAIServiceOptions> |
Returns
void
Implementation of
speak()
speak(req: Readonly<AxSpeechRequest<TModelKey>>, options?: Readonly<AxAIServiceOptions>): Promise<AxChatAudioOutput>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L286
Parameters
| Parameter | Type |
|---|---|
req | Readonly<AxSpeechRequest<TModelKey>> |
options? | Readonly<AxAIServiceOptions> |
Returns
Promise<AxChatAudioOutput>
Implementation of
transcribe()
transcribe(req: Readonly<AxTranscriptionRequest<TModelKey>>, options?: Readonly<AxAIServiceOptions>): Promise<AxTranscriptionResponse>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L279
Parameters
| Parameter | Type |
|---|---|
req | Readonly<AxTranscriptionRequest<TModelKey>> |
options? | Readonly<AxAIServiceOptions> |
Returns
Promise<AxTranscriptionResponse>
Implementation of
create()
static create<T>(options: T): AxAI<InferTModelKey<T>>;Defined in: https://github.com/ax-llm/ax/blob/781623e58befc00a555cf73ccbac598a72bb700c/src/ax/ai/wrap.ts#L190
Type Parameters
| Type Parameter |
|---|
T extends AxAIArgs<any> |
Parameters
| Parameter | Type |
|---|---|
options | T |
Returns
AxAI<InferTModelKey<T>>