Time to complete: 45–75 minutes
What you’ll build: A branded GAIA installer for Windows, macOS, or Ubuntu with the Example Agent preloaded
What you’ll learn: How bundled agents flow from a staging directory through
electron-builder into the first-launch seeder, plus how to share agents between existing GAIA installations without rebuilding an installer
What’s different about this playbook
This playbook is the end-to-end walkthrough for shipping a branded GAIA installer with your agent preloaded — useful whenpip install amd-gaia or enterprise silent-install isn’t the right fit. Take a working agent, drop it into the staging directory, run one npm command per OS, install the binary, and watch the seeder surface your agent in the Agent UI on first launch.
Two paths are covered:
- Path A — Branded installer. You build and ship a full GAIA installer with your agent preloaded. This is what OEM partners, enterprise teams, and community builders typically want.
- Path B — Share an existing agent. You already have GAIA installed on both sides and just want to move an agent between machines. No installer build.
Path A — Branded installer
The running example is the Example Agent — the same minimal Python agent that ships preloaded in the stock GAIA installer.1
Prerequisites
Who this path is for: OEM partners pre-loading GAIA on Ryzen AI hardware, enterprise teams distributing an internal-knowledge agent, and community builders sharing a branded specialty agent.What you need installed:All subsequent steps assume your working directory is
- Git
- Node.js 18+ and npm
- Python 3.10+ (for running the agent locally to verify it before packaging)
gaia/src/gaia/apps/webui/.2
Create the Example Agent
Create the bundled-agent staging directory and drop in a Python Create Why this location matters. The At install time the contents end up under
agent.py:build/bundled-agents/example-agent/agent.py:build/bundled-agents/example-agent/agent.py
build/bundled-agents/ directory is the build-time staging area picked up by the extraResources entry in electron-builder.yml:process.resourcesPath/agents/<agent-id>/ inside the installed app. On first launch, seedBundledAgents() in src/gaia/apps/webui/services/agent-seeder.cjs copies them into ~/.gaia/agents/<agent-id>/, writes a .seeded sentinel inside the agent directory, and records a marker at ~/.gaia/seeder/<agent-id>.seeded. The marker is what makes seeding one-time-per-machine: as long as it exists the agent is never seeded again — even if the user deletes the agent directory. Deleting a seeded agent is honored permanently.3
Build the installer
Pick your target platform. Each command builds the full GAIA Agent UI installer with your Example Agent baked in.Output:
- Windows
- macOS
- Ubuntu
Cross-compilation is not supported end-to-end today. Build each target on its native OS (or in a matching VM / CI runner).
4
Install and verify
- Windows
- macOS
- Ubuntu
- Double-click the
.exeindist-app/. - Accept the NSIS prompts through to completion.
- Launch GAIA from the Start Menu.
- Open the Agent UI. On first launch,
seedBundledAgents()copies every directory under<resources>/agents/into~/.gaia/agents/, writing a.seededsentinel in each agent directory and a per-agent marker under~/.gaia/seeder/so each agent is seeded at most once per machine. - Open the agent dropdown in the UI header — Example Agent should appear alongside the built-in agents.
- Select Example Agent and send “What are you an example of?”. It should introduce itself as the bundled example and point you at the custom-agent guide.
- Confirm
~/.gaia/agents/example-agent/agent.pyexists on the target machine. - Confirm
~/.gaia/agents/example-agent/.seededexists — if it’s missing, the seeder did not run; check the Electron main-process logs and~/.gaia/logs/seeder.log. - To force a fresh seed (for example after a bad or incomplete copy), delete both
~/.gaia/agents/example-agent/and the marker~/.gaia/seeder/example-agent.seeded, then relaunch. Deleting the agent directory alone will NOT re-seed — the surviving marker means “the user deleted this agent” and the seeder honors that permanently.
5
(Optional) Branding
Most users ship with the default GAIA branding and only customize the agent. If you want a branded installer, edit
src/gaia/apps/webui/electron-builder.yml before re-running the package:* command:productName→ user-facing app name (e.g.,Acme GAIA)appId→ your reverse-DNS namespace (e.g.,com.acme.gaia)
Path B — Share an existing agent
If you already have GAIA installed and want to move an agent to another machine — or share it with a teammate — you don’t need to build an installer. Use the agent bundle export/import flow instead. The bundle is a.zip containing your custom agents plus a bundle.json table of contents. Export on the source machine, import on the destination.
Export
export_custom_agents() in src/gaia/installer/export_import.py, which walks ~/.gaia/agents/ and writes a deterministic zip with a bundle.json manifest.
Import
import_agent_bundle() in src/gaia/installer/export_import.py. Each agent is staged in a temp directory and atomically moved into ~/.gaia/agents/<id>/, so a partial failure leaves previously-installed agents intact. Zip entries are validated for path traversal, absolute paths, symlinks, size, and entry count before anything touches disk.
When to use which path
Next steps
Custom Agents
Deep reference for agent authoring, manifest schema, tools, and MCP.
Code Signing
Per-platform signing secrets, CI integration, troubleshooting.
Agent UI
Desktop shell architecture, build pipeline, Electron integration.