Skip to content

Coding agents

Your agent plans the change and marks the Ruby methods it wants written with # TODO: implement <name>. Gerald writes each one on your machine, runs the tests that name it, and keeps only the methods that pass. Anything it cannot make pass stays marked for the agent. The agent never sees a failed attempt, so it spends no tokens reviewing one.

Terminal window
gerald install

The first time, it signs you in and downloads the model. Then it sets up every supported agent it finds on your PATH. Name one to choose (gerald install claude), or add --project to set up only the current project.

Agent What is added Before each prompt
Claude Code fill tool, loaded at start Hook fills marked files first
Codex fill tool, approved to run Hook fills marked files first. Approve it once: run /hooks in Codex
OpenCode fill tool Not yet. OpenCode has no hook Gerald can use

Start a new agent session afterwards.

The agent starts the model the first time it has a method to write, so that first method waits for it to load. Later ones reuse it. The model stops after 15 minutes without a request and starts again when needed. Several sessions share one model.

You want Do this
See whether it is running gerald status, the Serving line
Stop it now gerald off
A different idle time Set GERALD_IDLE_MINUTES in the agent’s environment; 0 keeps it running
Run it yourself gerald serve in a terminal. Agents use that one

The background model needs a saved sign-in. With session-only sign-in, run gerald serve --session-only in a terminal.

There are two ways in, and they share one engine.

  • Before the prompt. A hook fills changed files that have markers before the agent starts, and tells the agent what it did in one short note. It works on up to five files and stops after 75 seconds.
  • During the session. When the agent decides which methods to write, it calls the fill tool. A file the hook already handled answers at once.

Gerald runs your project’s own tests: RSpec or Minitest, through Bundler when there is a Gemfile, and only the examples that name each method. With no tests to run it writes nothing.

You want Do this
Off for now gerald off. gerald on to resume; gerald status shows which
Off for one run Start the agent with GERALD_OFF=1
Off everywhere gerald uninstall

When Gerald is off, agents see no Gerald tool, the hook prints nothing and the background model is stopped. The session costs what it would without Gerald.

gerald install edits the agent’s own configuration.

Agent Every project With --project
Claude Code User MCP server gerald; hook in ~/.claude/settings.json .mcp.json and .claude/settings.json
Codex ~/.codex/config.toml and hooks.json (or $CODEX_HOME) .codex/
OpenCode ~/.config/opencode/opencode.json opencode.json

Gerald only edits plain JSON. For an OpenCode .jsonc file, add it yourself:

Terminal window
opencode mcp add gerald -- gerald mcp --tools fill

Gerald uses port 8080. To use another, edit the command gerald install wrote in the agent’s configuration:

gerald mcp --tools fill --port 9090
gerald fill --hook --port 9090
  • Ruby only: .rb and .rake files.
  • One method per marker, up to 512 tokens.
  • One request at a time; a busy model is retried for about 30 seconds.

Gerald and its model stay on loopback; nothing leaves your machine through Gerald. The agent itself reads your repository and sends it to its own provider, under its own settings.