gode is a tiny OpenAI-compatible coding assistant CLI written as a single Go file. It keeps the interaction loop, tool execution, and terminal UI in one place so you can read the whole program end-to-end.
Other languages: 中文
- Interactive prompt with a compact REPL-style loop
- OpenAI-compatible chat completions (configurable API URL and model)
- Built-in tools: read, write, edit, glob, grep, bash
- Simple rendering for emphasis and tool call previews
- Single-file, standard library only
- Transparent tooling: tools are declared once and executed directly
- Minimal configuration surface area
- Terminal-first UX with predictable output
go run .Build an executable:
Windows:
go build -o gode.exe ..\gode.exemacOS:
go build -o gode ../godeLinux:
go build -o gode ../godeCommands:
- /q or exit to quit
- /c to clear the conversation
Create a .env file (see .env.example) and set:
- OPENAI_API_KEY
- API_URL (optional, defaults to OpenAI-compatible endpoint)
- MODEL (optional, defaults to gpt-5.2-codex)
Inspired by 1rgs/nanocode: Minimal Claude Code alternative. Single Python file, zero dependencies, ~250 lines.
