Documentation
¶
Overview ¶
Command golder is the CLI entry point for the golder agent. It parses flags, overlays config.toml, and dispatches to one of the run modes — interactive REPL, headless print, session listing, or the internal sub-agent RPC server:
golder # interactive REPL (on a TTY) golder -p "read README and summarize" # print mode: final text golder -p "..." --output-format stream-json # line-delimited JSON events golder session export|list|resume <id> # session sharing golder update # binary self-update
The provider is resolved from --model against the built-in OpenAI-compatible gateways (OpenRouter by default, Ollama for local models), with the API key taken from the environment. The process exit code reflects success (0) or failure (1), so the command composes cleanly in pipelines. All run-assembly, REPL, headless, and config logic lives under internal/cli/*; this file keeps only flag parsing (cliOptions), config overlay (applyFileConfig), and the dispatch seam that wires those subpackages together.