Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Chat ¶
Chat runs an agent chat loop with tool support. This is the experimental version of chat that supports tool calling.
func GenerateInteractive ¶
func GenerateInteractive(cmd *cobra.Command, modelName string, wordWrap bool, options map[string]any, think *api.ThinkValue, hideThinking bool, keepAlive *api.Duration, yoloMode bool, enableWebsearch bool) error
GenerateInteractive runs an interactive agent session. This is called from cmd.go when --experimental flag is set. If yoloMode is true, all tool approvals are skipped. If enableWebsearch is true, the web search tool is registered.
Types ¶
type MultilineState ¶
type MultilineState int
MultilineState tracks the state of multiline input
const ( MultilineNone MultilineState = iota MultilineSystem )
type RunOptions ¶
type RunOptions struct {
Model string
Messages []api.Message
WordWrap bool
Format string
System string
Options map[string]any
KeepAlive *api.Duration
Think *api.ThinkValue
HideThinking bool
Verbose bool
// Agent fields (managed externally for session persistence)
Tools *tools.Registry
Approval *agent.ApprovalManager
// YoloMode skips all tool approval prompts
YoloMode bool
}
RunOptions contains options for running an interactive agent session.
Click to show internal directories.
Click to hide internal directories.