ToolChoice

@Serializable
sealed class ToolChoice(source)

Used to switch tool calling behavior of LLM

Inheritors

Types

Link copied to clipboard
@Serializable
object Auto : LLMParams.ToolChoice

LLM will automatically decide whether to call tools or to generate text

Link copied to clipboard
@Serializable
data class Named(val name: String) : LLMParams.ToolChoice

LLM will call the tool name as a response

Link copied to clipboard
@Serializable
object None : LLMParams.ToolChoice

LLM will not call tools at all, and only generate text

Link copied to clipboard
@Serializable
object Required : LLMParams.ToolChoice

LLM will only call tools