Interface LanguageModelChat

Represents a language model for making chat requests.

See

lm.selectChatModels

Stubbed

interface LanguageModelChat {
    family: string;
    id: string;
    maxInputTokens: number;
    name: string;
    vendor: string;
    version: string;
    countTokens(text, token?): Thenable<number>;
    sendRequest(messages, options?, token?): Thenable<LanguageModelChatResponse>;
}

Properties

family: string

Opaque family-name of the language model. Values might be gpt-3.5-turbo, gpt4, phi2, or llama but they are defined by extensions contributing languages and subject to change.

id: string

Opaque identifier of the language model.

maxInputTokens: number

The maximum number of tokens that can be sent to the model in a single request.

name: string

Human-readable name of the language model.

vendor: string

A well-known identifier of the vendor of the language model. An example is copilot, but values are defined by extensions contributing chat models and need to be looked up with them.

version: string

Opaque version string of the model. This is defined by the extension contributing the language model and subject to change.

Methods