Yesterday I wrote a new coding agent (CodeGoLLM)

I thought it would be interesting to see how small I could get a working terminal based coding agent.

So I booted up Codex CLI and started throwing prompts.

The result is this:

This is a fully working coding agent, much like Codex CLI. (but of course I’m sure far less capable, even if surprisingly so in its own way)

Built with Go so it doesn’t take a year to compile and yet performs super fast.

It works with OpenAI API and Ollama.

It can:

  • read, write, edit and run arbitrary bash commands
  • it presents code deltas and commands for you to review and approve
  • it maintains an evolving context summary beyond the last X interactions so it uses tokens more efficiently
  • it maintains a session for the current working directory
  • it is guardrailed to the current directory (best efforts!)
  • you can interrupt the agent and set it off in a different direction

I think the fun stat here is the number of lines of code, using CodeGollm as a baseline:

  • Codex repo is 250x bigger
  • Pi-mono coding agent (known for its small size) is 7x bigger

What I learnt doing this is:

  • The fundamentals of all this remain pretty straightforward.
  • You really can achieve an awful lot with a small harness
  • Codex CLI will happily build you something you can replace it with
  • Model size really matters - Gemma 4 was a perhaps predictable disaster, but gpt-4.1-mini can code pretty well, despite not racking up internal reasoning!

You probably won’t be using this because of course I can’t build something to compete with Codex CLI in a day and there is no ChatGPT auth, but I thought it interesting to share . Give it a :star: on GitHub if you enjoyed this … have fun building!

I’ve added ChatGPT auth to CodeGollm based on this conversation:

This is still experimental.

A demo built with codegollm with ChatGPT auth - animated skimmer navigating over undulating landscape … cheesy but working code.

This is all getting very meta.

I have codex CLI building codegllm building demo … :sweat_smile:

This project is still evolving.

Disappointed with Gemma 4 performance I decided to see if adding reasoning with Ollama would help (after all, I had “great success” with it here: > clai: your useful command line helper! - #4 by merefield)

Unfortunately it didn’t much :sweat_smile: , but this is still useful for any Ollama models and might work well with larger models.

gpt-5.4-mini with medium reasoning still shows off the capabilities of this coding agent well, however, and it’s very cost effective. The OpenAI models are just so awesome for this stuff, even mini :flexed_biceps:

I’ve since updated the system prompt slightly though I’ve not properly evaluated that yet, but it definitely still works!

This was almost one-shotted apart from the tinted glass: