Skip to main content
Source Code: src/gaia/cli.py
GAIA provides a comprehensive command-line interface (CLI) for interacting with AI models and agents. The CLI allows you to query models directly, manage chat sessions, and access various utilities without writing code.

Platform Support

Windows 11

Full GUI and CLI support

Linux

Full GUI and CLI support via source installation (Ubuntu/Debian)

Quick Start

  1. Follow the Quickstart to install GAIA
  2. Open PowerShell and run gaia to launch the Agent UI, or gaia --cli for terminal chat
  3. GAIA automatically starts Lemonade Server when needed, or start manually:
lemonade-server serve

Top-Level Flags

Running gaia with no subcommand launches the Agent UI by default:
gaia            # Launches Agent UI on port 4200
gaia --ui       # Same — explicit flag
gaia --cli      # Launch interactive CLI chat instead
FlagDescription
--uiLaunch the Agent UI (browser-based chat interface) — this is the default
--ui-port <port>Port for the Agent UI server (default: 4200)
--ui-dist <path>Serve an alternative prebuilt Agent UI bundle (e.g., a PR preview) instead of the one shipped in the installed package
--cliLaunch interactive CLI chat
--base-url <url>Use a remote Lemonade server (e.g. https://host:13305/api/v1). Also accepted as a global option on most subcommands (e.g. gaia chat --base-url ...).
Examples:
gaia
gaia chat --ui continues to work as an alias. The Agent UI requires an AMD Ryzen AI Max (Strix Halo) or an AMD Radeon GPU with ≥ 24 GB VRAM. If your device is not supported, a dismissible warning banner will appear in the UI.

Agent step limit

Agents stop after a maximum number of reasoning/tool steps. The default is 50, applied consistently across the CLI, the Agent UI, and background runs.
  • Per-invocation: pass --max-steps <n> to any agent command (e.g. gaia browse --max-steps 80). gaia blender uses --steps <n>.
  • Fleet-wide: set the GAIA_AGENT_MAX_STEPS environment variable to change the default for every agent at once, without per-command flags.
# Raise the limit for every agent in this shell
export GAIA_AGENT_MAX_STEPS=80
gaia browse "research the latest AMD Ryzen AI news"
A few agents intentionally override the default (e.g. the Code agent uses 100 for multi-file generation). An invalid GAIA_AGENT_MAX_STEPS value (non-integer or ≤ 0) fails fast with an actionable error rather than silently capping agents.

Per-tool execution timeout

Each tool call is bounded so a hung tool (e.g. a stuck connector or network request) surfaces an actionable error instead of leaving the agent — and the UI — stuck indefinitely. The default is 180 seconds per tool.
  • Fleet-wide: set GAIA_AGENT_TOOL_TIMEOUT (seconds) to change the default for every tool at once.
# Allow long-running tools more headroom in this shell
export GAIA_AGENT_TOOL_TIMEOUT=300
Tools that legitimately run longer opt out in code via @tool(timeout=...) — for example image generation, which may need to download a model on first use. An invalid GAIA_AGENT_TOOL_TIMEOUT value (non-numeric or ≤ 0) fails fast with an actionable error rather than silently removing the guard.

Initialization

Init Command

New users start here! The gaia init command is the easiest way to get GAIA running.
Initialize GAIA with a single command: installs Lemonade Server and downloads required models.
gaia init [OPTIONS]
Options:
OptionTypeDefaultDescription
--profile, -pstringchatProfile to initialize (minimal, sd, chat, code, rag, vlm, npu, all)
--minimalflagfalseShortcut for --profile minimal
--skip-modelsflagfalseSkip model downloads (only install Lemonade)
--skip-lemonadeflagfalseSkip Lemonade installation check (for CI with pre-installed Lemonade)
--force-reinstallflagfalseForce reinstall even if compatible version exists
--force-modelsflagfalseForce re-download models (deletes then re-downloads each model)
--yes, -yflagfalseSkip confirmation prompts (non-interactive)
--verboseflagfalseEnable verbose output
--remoteflagfalseUse remote Lemonade Server (skip local install/start, download models via API). Auto-detected when LEMONADE_BASE_URL is set to a non-localhost URL.
Available Profiles: The --profile flag accepts one of the following values (see src/gaia/cli.py for the canonical choices list):
ProfileModelsDescriptionApprox Size
minimalGemma-4-E4B-it-GGUFFast setup with Gemma 4 E4B multimodal model~3 GB
sdSDXL-Turbo, Gemma-4-E4B-it-GGUFImage generation with multi-modal AI (LLM + SD)~10 GB
chatGemma-4-E4B-it-GGUF, nomic-embed-text-v2-moe-GGUFInteractive chat with RAG and vision support~4 GB
codeGemma-4-E4B-it-GGUFAutonomous coding assistant~3 GB
ragGemma-4-E4B-it-GGUF, nomic-embed-text-v2-moe-GGUFDocument Q&A with retrieval~4 GB
vlmGemma-4-E4B-it-GGUFVision pipeline for document and image extraction~3 GB
npugemma4-it-e2b-FLMRyzen AI NPU acceleration via FLM backend (requires XDNA2 NPU)~3 GB
allAll modelsAll models for all agents~26 GB
The talk, blender, jira, and docker agents all rely on the chat profile — there is no dedicated profile for each. Run gaia init --profile chat (or all) to prepare their dependencies.
gaia llm quick queries use the global default model (Gemma-4-E4B-it-GGUF).
Examples:
gaia init
What It Does: GAIA works with Lemonade Server in two modes:
  • Local — Lemonade runs on the same machine (default)
  • Remote — Lemonade runs on another machine; enable with --remote or by setting LEMONADE_BASE_URL
  1. Checks Lemonade Server - Detects if installed and verifies version compatibility
  2. Installs/Upgrades Lemonade - Downloads and installs from GitHub releases (Windows/Linux only). Automatically uninstalls old version if version mismatch detected.
  3. Starts Server - Ensures Lemonade server is running, prompts to start if not
  4. Downloads Models - Pulls required models for the selected profile
  5. Verifies Setup - Tests each model with inference to detect corrupted downloads
Platform Support: Automatic installation supports Windows (MSI) and Linux (DEB) only. macOS users should install Lemonade Server manually from lemonade-server.ai.
Automatic Upgrade: If your installed Lemonade version doesn’t match the expected version, gaia init will offer to automatically uninstall the old version and install the correct one.
Corrupted Model Detection: gaia init verifies each model with a quick inference test. If a model fails verification (e.g., corrupted download), you’ll see instructions to manually delete and re-download it, or use gaia init --force-models to force re-download all models.

Install Command

Install individual GAIA components.
gaia install [OPTIONS]
Options:
OptionTypeDescription
--lemonadeflagInstall Lemonade Server
--yes, -yflagSkip confirmation prompts
Examples:
gaia install --lemonade
If a different version of Lemonade is already installed, you’ll be prompted to uninstall first.

Uninstall Command

Tiered cleanup of GAIA components. By default, the OS-native uninstall (Add or Remove Programs, drag to Trash, apt remove) only removes the app — user data in ~/.gaia/ is preserved. This command lets you escalate cleanup as far as you want.
gaia uninstall [OPTIONS]
Options:
OptionTypeDescription
--venvflagRemove the Python environment (~/.gaia/venv/)
--purgeflagRemove venv + chats + documents + config + logs
--purge-lemonadeflagAlso remove Lemonade Server (requires --purge)
--purge-modelsflagAlso remove downloaded Lemonade models (requires --purge)
--purge-hf-cacheflagAlso remove ~/.cache/huggingface/ (requires --purge)
--dry-runflagShow what would be removed without deleting anything
--yes, -yflagSkip confirmation prompts
Examples:
gaia uninstall --dry-run
--purge permanently deletes your chat history, uploaded documents, and configuration. Use --dry-run first to preview what will be removed.

Kill Command

Stop running GAIA services.
gaia kill [OPTIONS]
Options:
OptionTypeDescription
--lemonadeflagKill Lemonade Server and child processes
--portintegerKill process on specific port
Examples:
gaia kill --lemonade
On Windows, --lemonade also kills orphaned llama-server.exe and lemonade-tray.exe processes.

Agent Command

Author, version, validate, and share GAIA agents.

Developer workflow: init, version, test

Scaffold a new agent package, bump its version, and run the quality gates that publishing requires. The scaffold mirrors the canonical hub package layout (hub/agents/python/summarize/).
gaia agent init <name> [--language python|cpp] [--output DIR] [--force]
gaia agent version <patch|minor|major> [--path DIR]
gaia agent test [--lint | --live] [--path DIR] [--timeout SECONDS]
init scaffolds a package directory named after <name>:
  • Python: gaia-agent.yaml, pyproject.toml (with the gaia.agent entry point), a gaia_agent_<id>/ package (__init__.py + agent.py skeleton), tests/test_agent.py, and README.md.
  • C++: gaia-agent.yaml, CMakeLists.txt, src/agent.cpp, tests/, and README.md.
OptionTypeDescription
namestringAgent id/name — lowercase, hyphens allowed (positional, required)
--languagechoicepython (default) or cpp
--output, -ostringParent directory to create the package in (default: current dir)
--forceflagOverwrite an existing package directory
version bumps the SemVer in gaia-agent.yaml and keeps pyproject.toml / __init__.py in sync. test runs quality gates in two modes:
ModeLLM required?Checks
--lint (default)No (CI-safe)Manifest valid + complete, package structure, Python sources parse + imports resolve, black + isort clean (Python); manifest + structure (C++)
--liveYes (Lemonade Server)Agent answers each declared conversation_starter within --timeout without crashing
The publish workflow requires --lint to pass; --live is recommended but not enforced. Examples:
gaia agent init my-agent
cd my-agent
gaia agent test --lint

Lifecycle: configure, health, status

Manage an installed agent: set per-agent configuration, verify it loads, and inspect its state. Configuration is persisted under ~/.gaia/agents/<id>/config.json and survives restarts.
gaia agent configure <id> [--model NAME] [--set KEY=VALUE ...] [--replace] [--show]
gaia agent health <id>
gaia agent status [<id>]
configure writes per-agent settings (e.g. a preferred model). --set values are JSON-decoded when possible (--set temperature=0.2 stores a number, --set verbose=true a boolean), otherwise kept as strings. Settings merge into the existing config by default; pass --replace to overwrite it wholesale, or --show to print the current config without changing it. health verifies that an installed agent actually loads — its registration resolves and its entry point imports. It reports one of healthy, degraded (loads but something optional is off, e.g. a corrupt config), error (a required piece fails to load), or not_installed, and exits non-zero for error / not_installed so scripts can gate on it. status aggregates installed version, health, config summary, and source for one agent — or every discovered agent when <id> is omitted.
OptionApplies toDescription
idallAgent id (positional; optional for status, required otherwise)
--modelconfigurePreferred model, stored as the model setting
--set KEY=VALUEconfigureSet an arbitrary setting (repeatable)
--replaceconfigureReplace the whole config instead of merging
--showconfigurePrint the current config and exit
Examples:
gaia agent configure chat --model Qwen3.5-35B-A3B-GGUF

Distribution: pack, publish, login

Build a distributable wheel from a Python agent package, then dual-publish it to the Agent Hub (R2, the source for the Hub UI) and PyPI (the source for pip install).
gaia agent login [--hub-token TOKEN | --hub] [--pypi-token TOKEN | --pypi]
gaia agent pack [PATH] [--output DIR]
gaia agent publish [PATH] [--output DIR] [--hub-url URL] [--skip-r2] [--skip-pypi]
pack runs python -m build --wheel against the package’s pyproject.toml, writing gaia_agent_<id>-<version>-py3-none-any.whl to dist/ and printing its SHA-256. Python agents only — native (C++) agents ship a CMake-built binary, not a wheel. publish packs the wheel and uploads it to both targets. R2 receives a multipart POST (gaia-agent.yaml + wheel) authenticated with a Bearer token; PyPI receives a twine upload authenticated with an API token. Both enforce version immutability — bump the version with gaia agent version before re-publishing. login stores publisher tokens in your OS keyring. Tokens may also be supplied via the GAIA_HUB_TOKEN and PYPI_TOKEN environment variables (useful in CI), which take precedence over the keyring.
OptionApplies toDescription
PATHpack, publishAgent package directory (positional, default: current dir)
--output, -opack, publishOutput directory for the wheel (default: <package>/dist)
--hub-urlpublishR2 Worker origin (default: GAIA_HUB_URL or https://hub.amd-gaia.ai)
--skip-r2publishPublish to PyPI only
--skip-pypipublishPublish to R2 only
--hub-token / --hubloginStore the R2 Hub token (pass a value, or --hub to be prompted)
--pypi-token / --pypiloginStore the PyPI token (pass a value, or --pypi to be prompted)
The packaging toolchain (build, twine) ships in the publish extra:
pip install "amd-gaia[publish]"
Examples:
gaia agent pack hub/agents/python/summarize/
Installing a published agent
The two publish targets back two install paths, and both register the agent the same way — via the gaia.agent entry point, so the registry discovers it automatically:
From PyPI (pip)
pip install gaia-agent-summarize          # one agent
pip install "amd-gaia[agents]"            # every AMD production agent
The Hub (R2) path is the Agent UI’s discover/install panel, which downloads the wheel from R2 into ~/.gaia/agents/<id>/ (POST /api/agents/install, backed by gaia.hub.installer). Use it when browsing the Hub UI; use pip install for scripted or headless setups.
Automated PyPI publishing (CI)
.github/workflows/publish_agents.yml builds every production agent wheel and publishes it to PyPI on a version tag (v*). Its matrix is derived from the agents extra in setup.py (via util/list_agent_packages.py), so adding an agent there is all it takes to start publishing it. The workflow uploads with pypa/gh-action-pypi-publish using the PYPI_API_TOKEN secret and skip-existing: true, so an unchanged agent version is a no-op rather than an error — PyPI enforces version immutability natively.

Sharing: export, import

Export every custom agent installed under ~/.gaia/agents/ into a single .zip bundle, and import a bundle produced on another machine.
gaia agent export [--output PATH]
gaia agent import PATH [--yes]
Export options:
OptionTypeDescription
--output <path>stringDestination .zip file (default: ~/.gaia/export.zip)
Import options:
OptionTypeDescription
pathstringPath to the .zip bundle to import (positional, required)
--yes, -yflagSkip the interactive trust prompt (required in non-interactive/CI contexts)
Examples:
gaia agent export
Exported bundles contain your agent source files as-is. Any API keys or credentials present in agent.py will be included. Review bundles before sharing.
Importing a bundle runs third-party Python code on your machine. gaia agent import shows the agent IDs in the bundle and requires explicit y/yes confirmation (or --yes) before proceeding.

Core Commands

LLM Direct Query

The fastest way to interact with AI models - no server management required.
gaia llm QUERY [OPTIONS]
Options:
OptionTypeDefaultDescription
--modelstringClient defaultSpecify the model to use
--max-tokensinteger512Maximum tokens to generate
--no-streamflagfalseDisable streaming response
Examples:
gaia llm "What is machine learning?"
The lemonade server must be running. If not available, the command will provide instructions on how to start it.

Chat Command

Start an interactive conversation or send a single message with conversation history.
gaia chat [MESSAGE] [OPTIONS]
Modes:
  • No message: Starts interactive chat session
  • Message provided: Sends single message and exits
Options:
OptionTypeDefaultDescription
--query, -qstring-Single query to execute
--modelstringauto-selected by agentOverride the model used by ChatAgent (None means let the agent pick; see ChatAgentConfig.model_id)
--index, -ipath(s)-PDF document(s) to index for RAG
--watch, -wpath(s)-Directories to monitor for new documents
--chunk-sizeinteger500Document chunk size for RAG
--max-chunksinteger3Maximum chunks to retrieve for RAG
--max-indexed-filesinteger100Maximum number of files to keep indexed. Evicts least-recently-accessed files when LRU eviction is enabled; rejects new files when disabled.
--max-total-chunksinteger10000Maximum total chunks across all indexed files. Same eviction behavior as --max-indexed-files.
--allowed-pathspath(s)-Restrict RAG/file tools to these directories (security sandbox)
--stats, --show-statsflagfalseShow performance statistics
--streamflagfalseEnable streaming responses
--show-promptsflagfalseDisplay prompts sent to LLM
--debugflagfalseEnable debug output
--list-toolsflagfalseList available tools and exit
--uiflagfalseLaunch the Chat Web UI (browser-based interface on port 4200)
--ui-portinteger4200Port for the Agent UI server (used with --ui)
--ui-distpath-Serve an alternative prebuilt Agent UI bundle (e.g., a PR preview) instead of the one shipped in the package
Examples:
gaia chat
Interactive Commands: During a chat session, use these special commands:
CommandDescription
/clearClear conversation history
/historyShow conversation history
/systemShow current system prompt configuration
/modelShow current model information
/promptShow complete formatted prompt sent to LLM
/statsShow performance statistics (tokens/sec, latency, token counts)
/helpShow available commands
quit, exit, byeEnd the chat session

Specialized Agent Commands

Use focused agent commands when you want a smaller tool surface than the full chat agent.
gaia browse [OPTIONS]
gaia analyze [OPTIONS]
Options:
OptionTypeDefaultDescription
--query, -qstring-Single query to execute
--modelstringauto-selected by agentOverride the model used by the agent
--allowed-pathspath(s)-Restrict local file paths used by agent tools
--stats, --show-statsflagfalseShow performance statistics
--streamflagfalseEnable streaming responses
--show-promptsflagfalseDisplay prompts sent to LLM
--debugflagfalseEnable debug output
--list-toolsflagfalseList available tools and exit
Examples:
gaia browse --query "Search the web for AMD GAIA documentation"

Prompt Command

Send a single prompt to a GAIA agent.
gaia prompt "MESSAGE" [OPTIONS]
Options:
OptionTypeDefaultDescription
--modelstringautoModel ID to use (default: auto-selected by each agent)
--max-tokensinteger512Maximum tokens to generate
--statsflagfalseShow performance statistics
Examples:
gaia prompt "What is the weather like today?"

Specialized Agents

Code Agent

Code Development

AI-powered code generation, analysis, and linting for Python/TypeScript
The Code Agent requires extended context. Start Lemonade with:
lemonade-server serve --ctx-size 32768
Features:
  • Intelligent Language Detection (Python/TypeScript)
  • Code Generation (functions, classes, unit tests)
  • Autonomous Workflow (planning → implementation → testing → verification)
  • Automatic Test Generation
  • Iterative Error Correction
  • Code Analysis with AST
  • Linting & Formatting
Quick Examples: Routing detects “Express” and uses TypeScript:
gaia-code "Create a REST API with Express and SQLite for managing products"
Routing detects “Django” and uses Python:
gaia-code "Create a Django REST API with authentication"
Routing detects “React” and uses TypeScript frontend:
gaia-code "Create a React dashboard with user management"
gaia-code --interactive
→ Full Code Agent Documentation

Code Index

gaia-code index builds and queries a local FAISS-backed semantic index over a repository. Embeddings run on AMD NPU/GPU through Lemonade Server. Requires the [rag] extras.
# Build / refresh the index for the current repo
gaia-code index

# Index a specific repo, capping discovery
gaia-code index --repo /path/to/repo --max-files 2000

# Semantic search
gaia-code index search "where do we mint JWT tokens"
gaia-code index search "auth flow" --scope code --top-k 5

# Inspect / wipe the cache
gaia-code index status
gaia-code index clear

# Interactive Q&A (CodeAgent + code_index tools)
gaia-code index chat
Common flags at the index level: --repo, --max-files, --model, --base-url, --no-lemonade-check, --use-claude, --use-chatgpt. → Full Code Index Documentation

Blender Agent

3D Scene Creation

Natural language 3D modeling and scene manipulation
Features:
  • Natural Language 3D Modeling
  • Interactive Planning
  • Object Management
  • Material Assignment
  • MCP Integration
Options:
OptionTypeDefaultDescription
--querystringCustom query to run instead of the built-in examples
--interactiveflagfalseContinuously input queries in interactive mode
--examplestringRun a specific built-in example (1-6); omit for interactive mode
--stepsinteger5Maximum number of steps per query
--output-dirpathoutputDirectory to save output files
--mcp-portinteger9876Port for the Blender MCP server
--debug-promptsflagfalseShow prompts sent to the LLM
--print-resultflagfalsePrint results to the console
Examples: Interactive Blender mode:
gaia blender --interactive
Create specific objects:
gaia blender --query "Create a red cube and blue sphere arranged in a line"
Run built-in examples:
gaia blender --example 2
→ Full Blender Agent Documentation

Email Command

Email Triage

Read, organize, and reply to Gmail with all email content processed locally on your machine.
gaia email -q "<query>"           # one-shot
gaia email -i                     # interactive REPL
gaia email -v -q "Triage my inbox"  # verbose logs for benchmarking
Options:
OptionTypeDefaultDescription
-q, --querystringSingle query to send to the agent (non-interactive).
-i, --interactiveflagfalseREPL loop until /quit.
-v, --verboseflagfalseEmit structured logs for every triage decision and tool call.
--debugflagfalseAdds full prompt + LLM-response logging (sensitive payloads in logs).
Setup: requires the Google connector. Run gaia connectors connect google first; you’ll be asked to grant Gmail and Calendar scopes. Privacy: all email body inference runs locally on Lemonade — the agent rejects any non-local LLM endpoint at startup. → Full Email Triage Agent Documentation

SD Command

Image Generation

Generate images using Stable Diffusion on Ryzen AI
gaia sd <prompt> [OPTIONS]
Options:
OptionTypeDefaultDescription
promptstring-Text description of the image to generate
-i, --interactiveflagfalseRun in interactive mode
--sd-modelstringSDXL-TurboModel: SDXL-Turbo (fast, good quality, default), SD-Turbo (faster, lower quality), SDXL-Base-1.0 (photorealistic, slow), SD-1.5
--sizestringautoImage size: 512x512, 768x768, 1024x1024 (auto-selected per model)
--stepsintegerautoInference steps (auto: 4 for Turbo, 20 for Base)
--cfg-scalefloatautoCFG scale (auto: 1.0 for Turbo, 7.5 for Base)
--output-dirpath.gaia/cache/sd/imagesDirectory to save images
--seedintegerrandomSeed for reproducibility
--no-openflagfalseSkip prompt to open image in viewer
Examples: Fast generation with default (SD-Turbo, ~13s):
gaia sd "a sunset over mountains"
Better quality with SDXL-Turbo (~17s):
gaia sd "cyberpunk city at night" --sd-model SDXL-Turbo
Photorealistic with SDXL-Base-1.0 (slow, ~9min):
gaia sd "portrait, photorealistic, detailed" --sd-model SDXL-Base-1.0
For automation (no prompts):
gaia sd "test image" --no-open
Interactive mode:
gaia sd -i
→ Full Image Generation Documentation

Talk Command

Voice Interaction

Speech-to-speech conversation with optional document Q&A
gaia talk [OPTIONS]
Options:
OptionTypeDefaultDescription
--modelstringautoModel ID to use (default: auto-selected by each agent)
--max-tokensinteger512Maximum tokens to generate
--no-ttsflagfalseDisable text-to-speech
--audio-device-indexintegerauto-detectAudio input device index
--whisper-model-sizestringbaseWhisper model [tiny, base, small, medium, large]
--silence-thresholdfloat0.5Silence threshold in seconds
--mic-thresholdfloat0.003Microphone amplitude threshold for voice detection (lower = more sensitive)
--statsflagfalseShow performance statistics
--index, -ipath-PDF document for voice Q&A
Examples:
gaia talk
→ Full Voice Interaction Guide

Jira Command

Jira / Atlassian

Natural-language interface for Jira, Confluence, and Compass using your Atlassian credentials (REST API).
gaia jira "Create a bug report for the login issue"
gaia jira --interactive
Options:
OptionTypeDefaultDescription
commandstringNatural-language command to execute (positional).
--interactiveflagfalseContinuous interactive mode.
--mcp-hoststringlocalhostMCP bridge host.
--mcp-portinteger8765MCP bridge port.
--verboseflagfalseVerbose output.
--debugflagfalseDebug logging.
→ Full Jira Guide

Docker Command

Docker

Natural-language interface for Docker containerization.
gaia docker "Create a Dockerfile for my Flask app"
gaia docker "Containerize this project" --directory ./myapp
Options:
OptionTypeDefaultDescription
commandstringNatural-language command to execute (positional).
--directorypathcurrent dirDirectory to analyze/containerize.
--verboseflagfalseVerbose output.
--debugflagfalseDebug logging.
→ Full Docker Guide

Summarize Command

Summarize meeting transcripts, emails, and PDFs.
gaia summarize --input ./meeting.vtt
gaia summarize --input ./inbox/ --type email --format both
Options:
OptionTypeDefaultDescription
-i, --inputpathInput file or directory (required unless --list-configs).
-o, --outputpathautoOutput file/directory (auto-adjusted to format).
-t, --typetranscript|email|pdf|autoautoInput type.
-f, --formatjson|pdf|email|bothjsonOutput format (both = json + pdf).
--stylesone or more stylesexecutive participants action_itemsbrief, detailed, bullets, executive, participants, action_items, all.
--max-tokensinteger1024Maximum tokens for the summary.
--email-tostringRecipients (comma-separated) for email output format.
--email-subjectstringautoEmail subject line.
--email-ccstringCC recipients (comma-separated).
--configpathUse a predefined configuration file from configs/.
--list-configsflagfalseList available configuration templates and exit.
--combined-promptflagfalseCombine styles into a single LLM call (experimental).
--no-viewerflagfalseDon’t auto-open the HTML viewer for JSON output.
--quietflagfalseMinimal output.
--verboseflagfalseDetailed/debug output.

Telegram Command

Telegram Adapter

Bridge a Telegram bot to GAIA so you can chat with your agents from Telegram.
gaia telegram start --token <BOT_TOKEN> --background
gaia telegram status
gaia telegram stop
Subcommands & options:
SubcommandOptionDefaultDescription
start--token (required)Telegram bot token.
start--allowed-usersallow allComma-separated user IDs permitted to interact.
start--backgroundfalseRun as a daemon (writes PID + health endpoint).
stop--forcefalseForce stop if graceful shutdown fails.
status--health-host127.0.0.1Health server host.
status--health-port8765Health server port.
→ Telegram Adapter Guide

API Server

API Server

OpenAI-compatible REST API for VSCode and IDE integrations

Quick Start

  1. Start Lemonade with extended context:
lemonade-server serve --ctx-size 32768
  1. Start GAIA API server:
gaia api start
  1. Test the server:
curl http://localhost:8080/health

Commands

gaia api start [OPTIONS]
Options:
  • --host - Server host (default: localhost)
  • --port - Server port (default: 8080).
    The gaia mcp docker bridge defaults to the same port — run them on different ports if you need both.
  • --debug - Enable debug logging
  • --show-prompts - Log the prompts sent to the LLM for every request (useful for debugging)
  • --streaming - Stream tokens to clients via SSE (OpenAI-style)
  • --step-through - Pause between agent steps for manual inspection (development aid)
Examples:Foreground:
gaia api start
With debug logging:
gaia api start --debug
Custom host/port:
gaia api start --host 0.0.0.0 --port 8888
Streaming mode with prompt logging:
gaia api start --streaming --show-prompts
→ Full API Server Documentation

MCP Client

MCP Client

Connect GAIA agents to external MCP servers
Configure MCP servers that your agents can connect to. Servers are saved to ~/.gaia/mcp_servers.json by default, or to a custom config file using --config.

Commands

Managing MCP servers (add / remove)

gaia mcp add and gaia mcp remove were removed in #977 — MCP servers are now configured through the connectors framework. Run gaia connectors --help for the current commands. gaia mcp list (below) still lists configured servers.

gaia mcp list

List all configured MCP servers.
gaia mcp list [--config PATH]
Options:
  • --config PATH - Custom config file path (default: ~/.gaia/mcp_servers.json)
Example:
# List from user config
gaia mcp list

# List from project config
gaia mcp list --config ./mcp_servers.json

gaia mcp tools

List tools available from a configured MCP server.
gaia mcp tools <server-name> [--config PATH]
Arguments:
  • <server-name> - Name of the server to query
Options:
  • --config PATH - Custom config file path (default: ~/.gaia/mcp_servers.json)
Example:
# List tools from time server
gaia mcp tools time

# List tools using project config
gaia mcp tools memory --config ./mcp_servers.json

gaia mcp test-client

Test connection to a configured MCP server.
gaia mcp test-client <server-name> [--config PATH]
Arguments:
  • <server-name> - Name of the server to test
Options:
  • --config PATH - Custom config file path (default: ~/.gaia/mcp_servers.json)
Example:
gaia mcp test-client time
→ Full MCP Client Guide

MCP Bridge

MCP Bridge

Expose GAIA agents as MCP servers
The MCP Bridge allows other applications to use GAIA agents as MCP servers.

Quick Start

Install MCP support:
uv pip install -e ".[mcp]"
Start MCP bridge:
gaia mcp start
Test basic functionality:
gaia mcp test --query "Hello from GAIA MCP!"

Commands

CommandDescription
startStart the MCP bridge server
statusCheck MCP server status
stopStop background MCP bridge server
testTest MCP bridge functionality (optionally against a specific --tool)
agentInvoke the MCP orchestrator agent (positional request arg + --domain, --context)
dockerStart the Docker MCP server (default port 8080)

gaia mcp start options

OptionDefaultDescription
--hostlocalhostBind address
--port8765Port for the MCP bridge
--auth-tokennoneIf set, require Authorization: Bearer <token> on every request
--no-streamingoffDisable SSE streaming; reply synchronously
--backgroundoffDetach; use gaia mcp stop to terminate
--log-filestdoutWrite logs to this path (useful with --background)
--verboseoffVerbose logging
--ctx-size32768Context window hint passed to Lemonade for loaded models

gaia mcp test options

OptionDefaultDescription
--queryrequiredText to send to the server
--toolgaia.chatWhich MCP tool to invoke when testing

gaia mcp agent

gaia mcp agent <request> [--domain DOMAIN] [--context CONTEXT]
Pass a natural-language request and, optionally, a --domain (e.g. jira, docker) and free-form --context string to steer the orchestrator.

gaia mcp docker options

--port defaults to 8080.
This is the same default as gaia api start — run them on different ports if you need both alive at once.
→ Full MCP Integration Guide

Connectors

Connectors

OAuth providers, MCP-server connectors, and per-agent scope grants
Manage external connectors (OAuth providers like Google/GitHub, MCP servers, API tokens) and control which agents may use them. Configure a connector once, then grant individual agents the scopes they need.
gaia connectors <subcommand> [OPTIONS]
Subcommands:
SubcommandDescription
list (alias status)List connectors in the catalog with their status (--json for machine-readable output)
connect <id>Authorize an OAuth connector (opens a browser); --scopes to request specific scopes
configure <id>Configure a connector — --set KEY=VALUE (repeatable) or --json '<object>' (e.g. MCP API keys, OAuth client creds)
test <id>Run a health check for a configured connector
disconnect <id>Remove credentials and reset a connector’s state
grants {list|grant|revoke}Manage per-agent scope grants (credential access)
activations {list|activate|deactivate}Manage per-agent MCP tool visibility (mcp_server connectors only)
Examples:
gaia connectors connect google
→ Connectors Guide · → Connectors SDK

Model Management

Download Command

Download all models required for GAIA agents with streaming progress.
gaia download [OPTIONS]
Options:
OptionTypeDefaultDescription
--agentstringallAgent to download models for
--listflagfalseList required models without downloading
--timeoutinteger1800Timeout per model in seconds
--hoststringlocalhostLemonade server host
--portinteger13305Lemonade server port
--clear-cacheflagfalseRemove cached download progress/metadata before running
Available Agents: chat, code, talk, rag, blender, jira, docker, vlm, minimal, mcp Examples: List all models:
gaia download --list
List models for specific agent:
gaia download --list --agent chat
Download all models:
gaia download
Download for specific agent:
gaia download --agent code
Example Output:
📥 Downloading 3 model(s) for 'chat'...

📥 Qwen3.5-35B-A3B-GGUF
   ⏳ [1/31] Qwen3.5-35B-A3B-Q4_K_M.gguf: 3.5 GB/17.7 GB (20%)
   ...
   ✅ Download complete

✅ nomic-embed-text-v2-moe-GGUF (already downloaded)

==================================================
📊 Download Summary:
   ✅ Downloaded: 2
   ⏭️  Skipped (already available): 1
==================================================

Pull Command

To download individual models, use the Lemonade Server CLI directly:
lemonade-server pull MODEL_NAME [OPTIONS]
Use lemonade-server list to see all available models and their download status.

Evaluation Commands

Evaluation Framework

Systematic testing, benchmarking, and model comparison
Tools for:
  • Agent eval benchmark (scenario-based, end-to-end)
  • Auto-fixing failures with Claude Code
  • Report generation
  • Performance-log visualization
Quick Examples: Run the agent eval benchmark:
gaia eval agent                                    # Run all scenarios
gaia eval agent --category mcp_reliability         # Run MCP reliability scenarios only
gaia eval agent --scenario mcp_simple_tool_call    # Run a single scenario
gaia eval agent --iterations 5                     # Run each scenario 5 times for reliability measurement
gaia eval agent --fix                              # Auto-fix failures with Claude Code
gaia eval agent --compare run1/scorecard.json run2/scorecard.json  # Compare runs
Generate a report:
gaia report -d ./eval_results
Visualize llama.cpp performance logs:
gaia perf-vis ./logs/llama-server.log
→ Full Evaluation Guide

Agent Eval

Agent Eval Benchmark

Scenario-based end-to-end testing of the GAIA Agent UI
Run automated multi-turn conversation tests against the live Agent UI. The eval agent (Claude Code) simulates user personas, drives conversations via MCP, and judges every response across 7 scoring dimensions.
gaia eval agent [OPTIONS]
Options:
OptionTypeDefaultDescription
--scenariostringallRun a specific scenario by ID
--categorystringallRun all scenarios in a category
--backendstringhttp://localhost:4200Agent UI backend URL
--modelstringclaude-sonnet-4-6Judge/simulator model
--budgetstring2.00Maximum USD spend per scenario
--timeoutinteger900Per-scenario timeout in seconds (auto-scaled for complex scenarios)
--audit-onlyflagfalseRun architecture audit without LLM calls (free)
--generate-corpusflagfalseRegenerate corpus documents and validate manifest.json
--fixflagfalseAuto-invoke Claude Code to diagnose and repair failures, then re-evaluate
--max-fix-iterationsinteger3Maximum repair cycles in --fix mode
--target-pass-ratefloat0.90Stop fix iterations when judged pass rate reaches this threshold
--comparestring(s)Compare two scorecard files, or one scorecard against saved baseline
--save-baselineflagfalseSave this run’s scorecard as eval/results/baseline.json
--capture-sessionstringConvert an Agent UI session (by UUID) into a YAML scenario file
--scenario-dirstringAdditional scenario directory to scan (repeatable)
--corpus-dirstringAdditional corpus directory to scan (repeatable)
--tagstringRun only scenarios with this tag (repeatable, OR logic)
--output-formatchoiceOutput format: json, markdown, or junit
Examples:
gaia eval agent --scenario simple_factual_rag
The eval agent requires Claude Code CLI (claude command), an Anthropic API key, and the Agent UI backend running. See the Agent Eval Guide for full setup instructions.
→ Full Agent Eval Guide · → Scenario Authoring · → CI/CD Integration

Email Throughput Benchmark

Measure end-to-end email-triage throughput (tokens/sec), time-to-first-token, and pipeline latency for an on-device model. Direct-drives the email agent over the committed synthetic corpus and harvests metrics from the agent’s per-step stats. The committed bar is ≥10 tok/s (snappy-UX stretch ~30 tok/s); the benchmark is non-gating — a miss is reported, not failed.
gaia eval benchmark [OPTIONS]
Options:
OptionTypeDefaultDescription
--modelstrGemma-4-E4B-it-GGUFLemonade model id to benchmark
--limitint50Target message count steered to the triage call (effective = min(limit, corpus size))
--experimentsint1Repeat count per model; >1 prints a variance report
--mbox-pathstrstub fixtureMBOX corpus to triage
--ground-truthstrfixture’sGround-truth JSON for quality scoring
--backendstragent defaultLemonade base URL
--output-dirstrWrite scorecard.json / summary.md / variance.json
--comparepathCompare throughput against a saved baseline (non-gating)
--save-baselineflagoffSave this run’s scorecard as the throughput baseline
gaia eval benchmark --model Gemma-4-E4B-it-GGUF --limit 50
Runs from a GAIA repo checkout (it drives the synthetic corpus in tests/fixtures/email/) and needs Lemonade serving the target model. Run at most one gaia eval process at a time against a single Lemonade server.

Performance Visualization

Plot llama.cpp server performance metrics from one or more log files. Plots are saved as images; pass --show to also display them interactively.
gaia perf-vis LOG_PATH [LOG_PATH ...] [--show]
Options:
OptionTypeDefaultDescription
log_pathspath(s)-One or more llama.cpp server log files to visualize
--showflagfalseDisplay plots interactively in addition to saving images
Examples:
gaia perf-vis ./logs/llama-server.log

Memory

Agent Memory Guide

Persistent second brain — remembers facts, preferences, and workflows across sessions
Manage agent memory: run day-zero onboarding and view memory statistics.

Commands

Show aggregate memory statistics.
gaia memory status
Output includes:
  • Knowledge entries by category (fact, preference, error, skill) and context
  • Conversation count and session history
  • Tool call success rates and error counts
  • Upcoming and overdue time-sensitive items
  • Database size
→ Full Memory Guide · → Memory SDK Reference

Utility Commands

Stats Command

View performance statistics from the most recent model run.
gaia stats [OPTIONS]

Test Commands

Run various tests for development and troubleshooting.
gaia test --test-type TYPE [OPTIONS]
Test Types:
  • tts-preprocessing - Test TTS text preprocessing
  • tts-streaming - Test TTS streaming playback
  • tts-audio-file - Test TTS audio file generation
Options:
  • --test-text - Text to use for TTS tests
  • --output-audio-file - Output file path (default: output.wav)
Examples:Test preprocessing:
gaia test --test-type tts-preprocessing --test-text "Hello, world!"
Test streaming:
gaia test --test-type tts-streaming --test-text "Testing streaming"
Generate audio file:
gaia test --test-type tts-audio-file \
  --test-text "Save this as audio" \
  --output-audio-file speech.wav

YouTube Utilities

Download transcripts from YouTube videos.
gaia youtube --download-transcript URL [--output-path PATH]
Options:
  • --download-transcript - YouTube URL to download transcript from
  • --output-path - Output file path (defaults to transcript_.txt)
Example:
gaia youtube \
  --download-transcript "https://youtube.com/watch?v=..." \
  --output-path transcript.txt

Cache Command

Inspect or clear GAIA’s on-disk caches (document-Q7 metadata, chat history, context7 library docs, etc.). Caches live under ~/.gaia/cache/ (Windows: %LOCALAPPDATA%/gaia/cache/).
gaia cache {status,clear} [OPTIONS]
Actions:
ActionDescription
statusPrint size and location of each cache directory
clearRemove cache contents (scoped by flags below)
Flags for clear:
FlagDescription
--allRemove every cache directory (safe: preserves models under ~/.gaia/models/)
--context7Clear only the Context7 MCP library-docs cache
Examples:
gaia cache status

Kill Command

Terminate processes running on specific ports.
gaia kill [OPTIONS]
Options:
OptionTypeDescription
--portintegerPort number to kill process on
--lemonadeflagKill Lemonade server (port 13305)
Examples:
gaia kill --lemonade
This command will:
  • Find the process ID (PID) bound to the specified port
  • Forcefully terminate that process
  • Provide feedback about success or failure

Diagnostics Command

Bundle system info and logs into a tarball for bug reports.
gaia diagnostics [OPTIONS]
Options:
OptionTypeDefaultDescription
--outputpath~/.gaia/diagnostics-<YYYYMMDD-HHMMSS>.tgzDestination path for the tarball
--no-logsflagfalseOmit log files (useful for public bug reports)
Examples:
gaia diagnostics
# → ~/.gaia/diagnostics-20260422-173000.tgz
The bundle includes:
  • System info snapshot (uname -a, distro, relevant env vars, all TCP listeners via ss -tlnp)
  • State files from ~/.gaia/ (config, session data — no chat content)
  • Log files: ~/.gaia/gaia.log and ~/.gaia/electron-main.log (omitted with --no-logs)

Global Options

All commands support these global options:
OptionTypeDefaultDescription
--logging-levelstringINFOLogging verbosity [DEBUG, INFO, WARNING, ERROR, CRITICAL]
-v, --versionflag-Show program’s version and exit

Troubleshooting

If you get connection errors, ensure Lemonade server is running:
lemonade-server serve
Check available system memory (16GB+ recommended)Verify model compatibility:
gaia download --list
Pre-download models:
gaia download
Install additional models: See Features Guide
List available devices:
gaia test --test-type asr-list-audio-devices
Verify microphone permissions in Windows settingsTry different audio device indices if default doesn’t work
For optimal NPU performance:
  • Disable discrete GPUs in Device Manager
  • Ensure NPU drivers are up to date
  • Monitor system resources during execution
For more help, see:

See Also

Code Agent

Python/TypeScript development

Blender Agent

3D scene creation

Voice Interaction

Speech-to-speech conversation

API Server

OpenAI-compatible REST API

MCP Integration

Model Context Protocol

Evaluation Framework

Testing and benchmarking

Agent Memory

Persistent memory across sessions