본문으로 건너뛰기

Interface: LLM<AdditionalChatOptions>

Unified language model interface

Type parameters

NameType
AdditionalChatOptionsextends Record<string, unknown> = Record<string, unknown>

Hierarchy

  • LLMChat<AdditionalChatOptions>

    LLM

Implemented by

Properties

metadata

metadata: LLMMetadata

Defined in

packages/core/src/llm/types.ts:46

Methods

chat

chat(params): Promise<AsyncIterable<ChatResponseChunk>>

Get a chat response from the LLM

Parameters

NameType
paramsLLMChatParamsStreaming<AdditionalChatOptions>

Returns

Promise<AsyncIterable<ChatResponseChunk>>

Overrides

LLMChat.chat

Defined in

packages/core/src/llm/types.ts:50

chat(params): Promise<ChatResponse>

Parameters

NameType
paramsLLMChatParamsNonStreaming<AdditionalChatOptions>

Returns

Promise<ChatResponse>

Overrides

LLMChat.chat

Defined in

packages/core/src/llm/types.ts:53


complete

complete(params): Promise<AsyncIterable<CompletionResponse>>

Get a prompt completion from the LLM

Parameters

NameType
paramsLLMCompletionParamsStreaming

Returns

Promise<AsyncIterable<CompletionResponse>>

Defined in

packages/core/src/llm/types.ts:60

complete(params): Promise<CompletionResponse>

Parameters

NameType
paramsLLMCompletionParamsNonStreaming

Returns

Promise<CompletionResponse>

Defined in

packages/core/src/llm/types.ts:63