LanguageModelToolTokenizationOptions

Options related to tokenization for a tool invocation.

Online Documentation

Properties

Link copied to clipboard
abstract var tokenBudget: Int

If known, the maximum number of tokens the tool should emit in its result.

Functions

Link copied to clipboard
abstract fun countTokens(text: String, token: CancellationToken = definedExternally): PromiseLike<JsInt>

Count the number of tokens in a message using the model specific tokenizer-logic.