Last reviewed: November 2025. z3ed ships alongside the main editor in every *-ai preset and runs on Windows, macOS, and Linux.
z3ed exposes the same ROM-editing capabilities as the GUI but in a scriptable form. Use it to apply patches, inspect resources, run batch conversions, or drive the AI-assisted workflows that feed the in-editor proposals.
The AI features require at least one provider:
brew install ollama, run ollama serve, then set OLLAMA_MODEL=qwen2.5-coder:0.5b (the lightweight default used in CI) or any other supported model. Pass --ai_model "$OLLAMA_MODEL" on the CLI to override per-run.GEMINI_API_KEY before launching z3ed.If no provider is configured the CLI still works, but agent subcommands will fall back to manual plans.
| Task | Example |
|---|---|
| Apply an Asar patch | z3ed asar patch.asm --rom zelda3.sfc |
| Export all sprites from a dungeon | z3ed dungeon list-sprites --dungeon 2 --rom zelda3.sfc --format json |
| Inspect an overworld map | z3ed overworld describe-map --map 80 --rom zelda3.sfc |
| Dump palette data | z3ed palette export --rom zelda3.sfc --output palettes.json |
| Validate ROM headers | z3ed rom info --rom zelda3.sfc |
Pass --help after any command to see its flags. Most resource commands follow the <noun> <verb> convention (overworld set-tile, dungeon import-room, etc.).
overworld describe-map) and returns structured diffs. Plans store the command transcript, diffs, and metadata inside $XDG_DATA_HOME/yaze/proposals/ (or APPDATA%\yaze\proposals\). Review them before applying to non-sandbox ROMs.
--sandbox flag) so you can review patches safely.--log-file agent.log captures the provider transcript for auditing.--format json or --format yaml for downstream tooling.yaze_test – run ./build_ai/bin/yaze_test --unit after batch patches to confirm nothing regressed.--tui, press : to open the command palette, type part of a command, hit Enter, and the tool auto-fills the available flags.| Symptom | Fix |
|---|---|
agent chat hangs after a prompt | Ensure ollama serve or the Gemini API key is configured. |
libgrpc or absl missing | Re-run the *-ai preset; plain debug presets do not pull the agent stack. |
| CLI cannot find the ROM | Use absolute paths or set YAZE_DEFAULT_ROM=/path/to/zelda3.sfc. |
| Tool reports "command not found" | Run z3ed --help to refresh the command index; stale binaries from older builds lack new verbs. |
| Proposal diffs are empty | Provide --rom plus either --sandbox or --workspace so the agent knows where to stage files. |
docs/public/developer/testing-without-roms.md – ROM-less fixtures for CI.docs/public/developer/debugging-guide.md – logging and instrumentation tips shared between the GUI and CLI.docs/internal/agents/ – deep dives into the agent architecture and refactor plans (internal audience only).