cli

package
v0.0.80 Latest Latest
Warning

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

Go to latest
Published: May 7, 2026 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() *cobra.Command

Types

type Auth added in v0.0.79

type Auth auth.Auth

type Call added in v0.0.79

type Call struct {
	File   string `usage:"File to read input from" default:"" short:"f"`
	Output string `usage:"Output format (json, pretty)" default:"pretty" short:"o"`
	// contains filtered or unexported fields
}

func NewCall added in v0.0.79

func NewCall(n *Nanobot) *Call

func (*Call) Customize added in v0.0.79

func (e *Call) Customize(cmd *cobra.Command)

func (*Call) Run added in v0.0.79

func (e *Call) Run(cmd *cobra.Command, args []string) error

type Nanobot

type Nanobot struct {
	Debug                bool     `usage:"Enable debug logging"`
	Trace                bool     `usage:"Enable trace logging"`
	Env                  []string `usage:"Environment variables to set in the form of KEY=VALUE, or KEY to load from current environ" short:"e"`
	EnvFile              string   `usage:"Path to the environment file (default: ./nanobot.env)" default:"./nanobot.env"`
	EmptyEnv             bool     `usage:"Do not load environment variables from the environment by default"`
	DefaultModel         string   `usage:"Default model to use for completions" default:"gpt-4.1" env:"NANOBOT_DEFAULT_MODEL" name:"default-model"`
	DefaultMiniModel     string   `` /* 138-byte string literal not displayed */
	MaxConcurrency       int      `usage:"The maximum number of concurrent tasks in a parallel loop" default:"10" hidden:"true"`
	Chdir                string   `usage:"Change directory to this path before running the nanobot" default:"." short:"C"`
	State                string   `usage:"Path to the state file" default:"./nanobot.db"`
	ConfigPath           []string `` /* 150-byte string literal not displayed */
	ExcludeBuiltInAgents bool     `usage:"Exclude built-in agents from the configuration"`
	// contains filtered or unexported fields
}

func (*Nanobot) ConfigPaths added in v0.0.79

func (n *Nanobot) ConfigPaths() []string

func (*Nanobot) Customize

func (n *Nanobot) Customize(cmd *cobra.Command)

func (*Nanobot) DSN added in v0.0.79

func (n *Nanobot) DSN() string

func (*Nanobot) GetRuntime

func (n *Nanobot) GetRuntime(ctx context.Context, opts ...runtime.Options) (*runtime.Runtime, error)

func (*Nanobot) PersistentPre

func (n *Nanobot) PersistentPre(cmd *cobra.Command, _ []string) error

func (*Nanobot) ReadConfig added in v0.0.79

func (n *Nanobot) ReadConfig(ctx context.Context, cfgPaths []string, includeDefaultAgents bool, opts ...runtime.Options) (*types.Config, error)

func (*Nanobot) Run

func (n *Nanobot) Run(cmd *cobra.Command, _ []string) error

func (*Nanobot) RuntimeConfigDir added in v0.0.79

func (n *Nanobot) RuntimeConfigDir() string

type Run

type Run struct {
	Auth
	ListenAddress                string            `usage:"Address to listen on" default:"localhost:8080" short:"a"`
	DisableUI                    bool              `usage:"Disable the UI"`
	ForceFetchToolList           bool              `usage:"Always fetch tools when listing instead of using session cache"`
	HealthzPath                  string            `usage:"Path to serve healthz on"`
	AuditLogSendURL              string            `usage:"URL to send audit logs to"`
	AuditLogToken                string            `usage:"Token to send audit logs with"`
	AuditLogMetadata             map[string]string `usage:"Metadata to send with audit logs"`
	AuditLogBatchSize            int               `usage:"Batch size for sending audit logs" default:"1000"`
	AuditLogFlushIntervalSeconds int               `usage:"Interval for flushing audit logs" default:"5"`
	Roots                        []string          `usage:"Roots to expose the MCP server in the form of name:directory" short:"r"`
	EntrypointAgent              string            `usage:"ID of the agent to use for chat" name:"agent"`
	// contains filtered or unexported fields
}

func NewRun

func NewRun(n *Nanobot) *Run

func (*Run) Customize

func (r *Run) Customize(cmd *cobra.Command)

func (*Run) Run

func (r *Run) Run(cmd *cobra.Command, args []string) (err error)

type Sessions added in v0.0.79

type Sessions struct {
	Nanobot *Nanobot
	Output  string `usage:"Output format (json, yaml, table)" short:"o" default:"table"`
}

func NewSessions added in v0.0.79

func NewSessions(n *Nanobot) *Sessions

func (*Sessions) Customize added in v0.0.79

func (t *Sessions) Customize(cmd *cobra.Command)

func (*Sessions) Run added in v0.0.79

func (t *Sessions) Run(cmd *cobra.Command, args []string) error

type Targets added in v0.0.79

type Targets struct {
	MCPServer []string `usage:"Specific MCP server name to query (default: all)" short:"s" name:"mcp-server"`
	Output    string   `usage:"Output format (json, yaml, table)" short:"o" default:"table"`
	// contains filtered or unexported fields
}

func NewTargets added in v0.0.79

func NewTargets(n *Nanobot) *Targets

func (*Targets) Customize added in v0.0.79

func (t *Targets) Customize(cmd *cobra.Command)

func (*Targets) Run added in v0.0.79

func (t *Targets) Run(cmd *cobra.Command, args []string) error

Jump to

Keyboard shortcuts

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