LanguageModelChat
Represents a language model for making chat requests.
See also
Properties
Functions
Link copied to clipboard
abstract fun countTokens(text: JsAny, token: CancellationToken = definedExternally): PromiseLike<JsInt>
Count the number of tokens in a message using the model specific tokenizer-logic.
Link copied to clipboard
abstract fun sendRequest( messages: ReadonlyArray<LanguageModelChatMessage>, options: LanguageModelChatRequestOptions = definedExternally, token: CancellationToken = definedExternally): PromiseLike<LanguageModelChatResponse>
Make a chat request using a language model.