modelpicker

package
v1.164.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2026 License: Apache-2.0 Imports: 6 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	ToolNameChangeModel = "change_model"
	ToolNameRevertModel = "revert_model"
)

Variables

This section is empty.

Functions

func CreateToolSet added in v1.60.0

func CreateToolSet(toolset latest.Toolset) (tools.ToolSet, error)

CreateToolSet is used by the tools registry.

Types

type ChangeModelArgs

type ChangeModelArgs struct {
	Model string `json:"model" jsonschema:"The model to switch to. Must be one of the available models."`
}

ChangeModelArgs are the arguments for the change_model tool.

type ToolSet added in v1.60.0

type ToolSet struct {
	// contains filtered or unexported fields
}

ToolSet provides tools for dynamically switching the agent's model mid-conversation.

func New added in v1.60.0

func New(models []string) *ToolSet

New creates a new ToolSet with the given list of allowed models.

func (*ToolSet) AllowedModels added in v1.60.0

func (t *ToolSet) AllowedModels() []string

AllowedModels returns the list of models this tool allows switching to.

func (*ToolSet) Instructions added in v1.60.0

func (t *ToolSet) Instructions() string

Instructions returns guidance for the LLM on when and how to use the model picker tools.

func (*ToolSet) Tools added in v1.60.0

func (t *ToolSet) Tools(context.Context) ([]tools.Tool, error)

Tools returns the change_model and revert_model tool definitions.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL