Skip to main content

Code agents and assistants

Turing-complete autocorrect, vibe-coding, …

2021-10-14 — 2026-11-16

quality 8.2

Wherein Coding Agents Are Classified by Search Method—from Vanilla Grep to Aider’s Tree-Sitter Graphs—and Editing Primitives—such as Hashline Tags or Unified Diffs—are Evaluated for Their Ability to Manage Side Effects.

faster pussycat
language
machine learning
making things
neural nets
NLP
signal processing
slop
stringology
UI

Large Language Models are text writing machines, and code is text. These machines are, it turns out, great at writing code by default, and we can make them even better. Here I take notes on the practicalities of getting these rather clever program synthesis machines to be a net plus for my life. A cousin to neural automata.

This page is mostly AI slop, i.e. LLM-expanded version of my notes from some recent exploratory projects. However, it is useful slop, so I am publishing it now rather than waiting for a more polished version.

Terms to know: harness and agent and executor.

Also related: Running backends offline on a Mac, automatic mathematical agents.

It helps to structure coding agents around the particular part of the agent design space that works best with code.

Harnesses run sequentially by default, often using automatic verification to determine when they have succeeded and may stop (“Did the tests pass?”). That propensity is shaped by the way we (typically) write code: It produces side effects—the code itself is a side effect from the perspective of the conversation—so it is more difficult to dispatch 50 coding agents without causing them to step on each other’s toes the way we can, for example, fan out fifty proof attempts in a maths loop.

There is a lot of variation within coding agents, however; for example, in how each finds the needed code, how each changes it, and how much we trade-off ease-of-observation (which we gloss as observability) for power.

Agents can also differ in which model they use.

Here, I explore some coding agents, some of which I find tolerable.

General advice:

CautionDownsides

I am vaguely concerned about how much of the world’s source code now gets uploaded to a handful of model endpoints servers, with the potential for abuse scaling with the size of the giant fatberg of latent expertise and corporate know-how. Nonetheless, the developer arms race is real, so let’s all ignore that and keep flushing our code into their pipes, eh?

Figure 1

2 Tools

In coding there are a few distinctive activities an agent needs to have competence in; surely the most essential is actually editing the files containing the code. Those code editing tools the agent has are odd. Depending upon the executor shipped with the harness, intended changes might get dispatched to several different editing tools, each with its own input format and quirks.

Formats in circulation:

Whole-file rewrite
the model emits the entire new file. Robust (except on long files and with models that get lazy and write # ... rest unchanged ...).
Search/replace
the model quotes the old text exactly and supplies its replacement. e.g. Claude Code does this a whole bunch using a tool called str_replace, Aider’s has SEARCH/REPLACE blocks.
Diff
the model emits a patch in some dialect — e.g. Aider uses unified diff, or Codex uses some apply_patch format.
Hash-anchored lines
hashline, from omp. Every line the model reads or greps gets decorated with line number and a short content hash (2:f1| return "world";); the model edits by citing tags instead of quoting text. If the file has changed since the model read it, the tags stop matching and any edits using the stale data are refused.
Apply model
the main model writes a rough draft of the edit and a small fine-tuned model merges it into the file — This is what Cursor means by “instant apply.”

Good enough tooling turns even pre-agentic models into capable coders; Aider’s laziness benchmark moved GPT-4 Turbo from a score of 20% to 61% on 89 refactoring tasks by swapping search/replace blocks for unified diffs. Cursor’s instant apply was based on research showing that actually total rewrites were better on short (<400 line) files, at least at the time. JetBrains’ Diff-XYZ benchmarked various write formats, and generally recommended search/replace for larger models.

Can Bölük’s hashline write-up presents massive gains from the hashline format, although in contrived/synthetic scenarios. In particular, it doesn’t cover the small models I use locally.

There is a useful feature of the hashline format: Stale lines are detected and refused. This gets us observable optimistic concurrency for free, ameliorating the side-effect problem. Search/replace has a weaker form of the guard, too.

3 Cloud and commercial harnesses

The cloud-hosted and commercial editors. None has a serious local-model path. Where they differ from each other is mostly context — what each pulls into the window and how — with dispatch a distant second and observability an afterthought:

Context Dispatch Observability
Claude Code just-in-time grep/read, compaction, sub-agents one frontier model, plus Haiku screening bash full transcript, hooks
Cursor a trained embedding index alongside grep tiered, mostly hidden the diff, and not much else
Copilot whatever the editor has open, plus chat history fixed per surface the diff
Warp codebase embeddings mixed-model terminal history

3.1 Claude Code

anthropics/claude-code is a command-line tool — a nicely designed one that interacts gracefully with a normal IDE. I have little to say about it; it is too thoroughly documented elsewhere/everywhere and in any case moves too fast to be worth explaining. The hooks reference is a handy reference for one of the under-used extension points.

Sebastian Raschka points out that we can force Claude Code to use a local model with ollama launch claude (!).

3.2 Cursor

Cursor is another VS Code fork with its own AI engine and some extra UI affordances. My colleagues assure me it causes far fewer annoying psychoses and sidetracks than Copilot. Cloud by design, though — there is no serious local-model path here.

3.3 GitHub Copilot

GitHub Copilot now uses some generic off-the-shelf GPT model for code completions. The original Codex engine was strikingly good, and for my idiosyncratic purposes, the general-purpose models have matched it, even years later.

Figure 2: Looks like AI Safety is going fine in GitHub Copilot.

GitHub Copilot has a great workflow for automatic completions, and that’s what originally made me pay for it. Still acceptably useful, this bit.

The extra chat interfaces they have rolled out since are janky and only semi-reliable, at least in my experience. They are bad at following instructions, careless with indentation, and prone to forgetting they are supposed to edit code and instead talking about editing code. It’s a bit like coding with a drunk genius: occasionally brilliant, usually messy.

OpenAI squandered their early lead.

Pro-tip: behind a corporate firewall, Copilot needs a specific set of whitelist exceptions.

3.4 Warp

Warp is an all-in agentic terminal/IDE — mixed-model, codebase embeddings, MCP, the lot. Heavily hyped; I haven’t tried it.

4 Model-agnostic and offline harnesses

There is a cornucopia of coding agents now, overflowing to the point of choice paralysis — everyone writes their own agent. All, AFAICT, speak plain OpenAI-compatible HTTP, so I can point them at a commercial token host or a local server. Osaurus on localhost:1337, ds4-server on 127.0.0.1:8000, and Ollama on 11434 are the ones I like. With local models the model ability is a limiting factor.

Context Dispatch Observability
pi deliberately little — no sub-agents, no MCP, a sub-1000-token system prompt whatever we point it at everything: every byte of every exchange on disk
omp pi with everything put back — 31 tools, LSP on every write, sub-agents in isolated workspaces, opt-in agent-curated memory nine roles (smol, slow, plan, advisor, …) over 60+ providers, with fallback chains every sub-agent’s transcript live and steerable; sessions on disk
Aider a repo-map, plus the files we name one model a diff — one git commit per change
OpenCode LSP, MCP, plugins any of 75+ providers full session transcript
MiMo Code four memory files on four clocks, written by a subagent fan-out on planning turns structured memory, over an unindexed trace
Codex sandboxed by default; frugal with tokens profile-switchable the transcript
Goose MCP, skills, recipes many providers, or a subscription over ACP desktop or CLI transcript
Cline sub-agent teams, MCP, plan mode switchable at runtime sidebar, CLI or kanban board
Qwen Code sub-agents, MCP, plan mode, skills switchable at runtime CLI transcript
DeepSeek Harness whatever plugins are mounted; the standard set has sub-agents, skills, planning any configured provider or OpenAI-compatible endpoint an append-only session log, with a trajectory view

Some especially peculiar designs: pi is all-in on observability. omp is pi with everything bolted back on. Aider is all-in on minimalist near-deterministic interventions rather than agentic behaviour. MiMo Code is ultra-keen to handle long-horizon tasks. DeepSeek Harness makes every piece swappable.

4.1 OpenCode

OpenCode is IMO a generic terminal harness, but it codes just like the name suggests. It’s especially useful for coding, working even offline: point it at a local endpoint with a custom-provider baseURL and it wraps LSP, MCP, and a plugin system around the model. The official VS Code extension exists but looks shonky atm.

brew install anomalyco/tap/opencode

4.2 MiMo Code

Xiaomi’s MiMo Code (MIT) is a fork of OpenCode featuring many tweaks, especially for long-horizon scaling. It inherits OpenCode’s custom-provider faculties but likely works best with Xiaomi’s own model.

Unlike its competitors, the project produces structured memory:

  • Four memory files on four clocks, written by a subagent rather than the main agent: checkpoint.md (“this” session), MEMORY.md (“this” project), a cross-project preferences file (“this” user), and beneath it all an SQLite trace of every message, which presumably is useful for something.
  • The writer fires at roughly 20%, 45% and 70% of the context budget, keeping a “best, latest” summary of the session live.
  • Xiaomi uses a particular vocabulary for its reliability designs: Max mode (high-temperature fan out for candidate plans, pick with a low-temperature judge), Dynamic Workflow (a JavaScript dialect — agent(), parallel(), pipeline(), workflow() — that the agent emits and a sandbox runs deterministically), and Goal (the natural-language stopping condition).
  • Dream (weekly) and Distill (monthly) are the two background cadences for evolution. Distill mints skills, CLI commands and SOP docs from past sessions — audit .mimocode/ occasionally. Dream does… something else, I suppose.

4.3 Codex CLI

OpenAI’s Codex CLI (openai/codex, Apache-2.0) is a terminal harness and — surprisingly for OpenAI — open-source. Naming caveat: this Codex is the agent harness, not the lamented original Codex code model that powered early Copilot.

brew install --cask codex

It’s my favourite thing from OpenAI, specifically because it doesn’t need to plug into an OpenAI endpoint. We can instead point it at whatever we want, even a local model mode.

Codex seems to occupy a similar niche to OpenCode but deviates in two ways: First, it sandboxes by default — Apple Seatbelt on macOS, Landlock/seccomp on Linux — reducing the blast radius of rogue agents somewhat. Second, Sebastian Raschka clocked it as the most token-frugal of the three harnesses he measured (Codex < Qwen-Code < Claude Code), which matters especially with a slow or constrained local model. pi is likely even more frugal, at the price of a steeper learning curve.

Configuring Codex to use an open endpoint was not immediately obvious to me. The trick is to configure a ~/.codex/local.config.toml profile invoked as codex --profile local:

# ~/.codex/local.config.toml — overlaid on config.toml by `codex --profile local`
model_provider = "osaurus"      # our own provider id (see table below)
model          = "qwen3.6:35b"  # whatever the server is serving

[model_providers.osaurus]
name     = "Osaurus"
base_url = "http://localhost:1337/v1"    # OpenAI-compatible endpoint; swap for ds4 on 8000, omlx, etc.
wire_api = "chat"                        # these servers speak Chat Completions, not OpenAI's Responses API

There are pre-defined model provider entries for openai/ollama/lmstudio.

Note that the project-level profile .codex/config.toml ignores model_provider/openai_base_url for trust reasons. Interestingly, Raschka also found Qwen3.6 scoring better under Codex than under its parent company’s own Qwen-Code.

4.4 pi

earendil-works/pi (Mario Zechner / badlogic, MIT), a.k.a. Pi Coding Agent, is a generic minimalist harness. pi’s philosophy is idiosyncratic enough that I introduced it in the LLM Agents page as a whole alternate way of doing agent things. What matters here is that it runs offline and is the harness driving antirez’s famous ds4 on a Mac. There’s a learning curve, but notionally a rewarding one.

brew install pi-coding-agent

4.5 omp

omp (can1357/oh-my-pi, MIT), Oh My Pi, is Stencil Labs’ fork of pi. It inverts pi’s philosophy: Where pi ships an ultra-minimal system prompt and few features, omp is maximal, lithium-polymer-batteries included — 31 built-in tools, a language-server (LSP) client wired into every write, a debugger driver (DAP), ast-grep structural edits, a browser, desktop control, and a web search that chains 23 backends. Roughly 80k lines of Rust do the work other harnesses shell out for — ripgrep, a bash fork, and 58 coreutils run in-process, so a tool call costs no fork/exec. We dispatch by role: nine slots (default, smol for cheap fan-out, slow, plan, advisor, …), each with a fallback chain, across 60+ providers including local OpenAI-compatible servers.

brew install can1357/tap/omp

Its most novel idea is the hashline edit format, with the caveats there. Most of its other claims rest on screen recordings. Several land directly in the harness design space:

  • Sub-agents with visible traces. pi’s objection to sub-agents is that the child’s trace vanishes. omp runs each sub-agent in an isolated copy of the workspace (copy-on-write where the filesystem allows), keeps transcripts live in a panel where we can read, steer, or kill them, and has the child return a schema-checked object rather than prose. That answers the objection for the human watching; the parent model still sees only the returned object.
  • An advisor. A second model reads every turn and injects notes into the conversation, providing guidance or commentary on the main agent’s actions.
  • Stream rules. A regex match on the model’s output aborts the stream mid-token, injects the matching rule as a reminder, and retries from the same point. A regex is cheap, deterministic, and grossly under-powered for real security but nice to have.
  • Self-curated memory. The main agent maintains its own memory (retain, recall, learn, with lessons promotable into skills), with Hindsight as one backend. Off by default.

4.6 Aider

Aider (Aider-AI/aider, Apache-2.0) is “AI pair programming in your terminal.” aider is a git-native AI assistant in the following sense: we execute it inside a git repository, tell it which files we’re working on, and describe the change we want in plain English at a chat prompt. Aider sends the model those files (plus a repo-map of everything else so it has context), gets an edit back, and writes it straight to the files on disk — then commits each change as its own git commit with a generated message. So we never copy-paste code out of a chat window, and reviewing or undoing what the model did is just git diff and git revert.

That git-per-change discipline is the whole potato. Once we have decided on that, the rest of the workflow just falls into place. It is less an autonomous agent that wanders off and does ten things, more a tightly scoped tool kept in check using git affordances. Harper Reed’s workflow gives us the flavour.

For our purposes it is model-agnostic — point it at any OpenAI-compatible base_url, or use the ollama/ prefix for a local model — and the repo-map means a smaller local model still gets relevant context without us hand-feeding it files.

It has some nifty automations — linting and running the test suite after each change, then feeding the logs back to the model.

Slight variant: --watch-files mode leaves aider running while we work in our normal editor, watching for AI! / AI? comments we drop into the code and acting on them, so we never have to leave the IDE.

# Make a snake game. AI!
# What is the purpose of this method AI?

Less ambitious, less risky, elegant.

4.7 Goose

Goose (Apache-2.0) is a general-purpose harness — desktop app plus CLI, grown-up enough to have been adopted by the Linux Foundation. For coding specifically, it speaks the Agent Client Protocol, so it can back Zed or JetBrains as the agent behind the editor, and it also has some code plugins I haven’t tried yet.

4.8 Cline

Have you, like me, grown flabby on a diet of soft, cosy code editors? If so, and we want, say, VS Code agent sidebars, Cline (cline/cline, Apache-2.0) sees us, and it understands. That sidebar is where Cline began.

With Cline 2.0, the Cline team pulled the agent loop out of the extension into a standalone open-source harness, @cline/sdk, and the same engine now drives a terminal CLI, a JetBrains plugin, the VS Code sidebar, and a web-based multi-agent kanban board. The runtime has all the bells and whistles and rescue knives we’d expect to find strapped to a serious harness — subagent teams, MCP, scheduled cron agents, chat connectors for Slack/Telegram/Discord. They claim impressive performance on something called terminal-bench.

A little dynasty of editors descends from Cline, mostly forks of its old monolithic extension rather than consumers of the new @cline/sdk. Roo Code was the prominent one, and it added per-mode permission scoping, but it shut down in May 2026, and the community decamped to ZooCode. Kilo Code (MIT) forks that fork for its extension, and OpenCode for its CLI.

4.9 Qwen Code

Qwen Code is the Qwen team’s terminal coding agent — originally a fork of Google’s Gemini CLI, which has since gone its own way. It’s multi-protocol like the others in this section: OpenAI, Anthropic, Gemini, or Qwen APIs plus a local Ollama or vLLM endpoint, all switchable at runtime. It aims for Claude Code feature parity — subagents, MCP, plan mode, and the agentskills.io SKILL.md format. Not to be confused with Qwen-Agent, the Python harness library, which is a separate codebase that doesn’t natively consume skills or do that other fancy stuff.

brew install qwen-code

4.10 DeepSeek Harness

DeepSeek Harness (deepseek-ai/deepseek-harness, MIT), dsh for short, is DeepSeek’s open-source harness. It is a developer preview that warns of compatibility-breaking changes, and DeepSeek pitches it at harness developers. Its selling point is that everything is a plugin—the model, the tools, the sessions, the sandboxes, and the agent loop included. According to the docs, it supports other providers and custom OpenAI-compatible endpoints as well as the DeepSeek API.

npx @deepseek-ai/dsh web

That serves a Web UI on 127.0.0.1:3080. It ships with four modes, which are preset plugin sets:

  • Standard is the full coding agent: file editing, shell, file and web search, skills, planning, goals, sub-agents and workflows.
  • Code mode exposes the same tools through an SDK, so the model can chain several tool calls in one TypeScript program.
  • Minimal is persistent bash plus str_replace_editor, pitched as a way to benchmark models.
  • Creator is for building custom presets; the agent can inspect the running harness and mount plugins it wrote itself.

Every run goes to an append-only session log, which resume, fork, search and replay all read from.

The plugins are written in TypeScript. Going by the developer docs, a plugin is a module that exports an apply(ctx) function and lists the services it needs in inject; the loader waits until those services exist, then calls apply, and the plugin registers whatever it offers through ctx. A model-callable tool is one ctx.tools.register(defineTool({...})) call with a parameter schema and an execute function, which takes a couple of dozen lines in the tutorial. Composition is a cordis.yml listing the plugins to mount, plus patch files that insert or replace rows. There is a Python SDK, but it drives a bundled dsh process; the plugins it loads are still TypeScript packages. The plugin tutorials start from a source checkout rather than the npx install.

4.11 Pour one out for the departed (and the renamed)

Fauxpilot (the self-hosted Copilot clone, long dead), Cody (Sourcegraph moved on to Amp), Kiro (Amazon’s cloud-bound spec-driven IDE), Codeium (now Windsurf), Amazon CodeWhisperer (now Amazon Q Developer), Codestral Mamba, Llama Coder, replit-code and Code Llama — all had their moment.

5 Alternative frontends

5.1 Waku

Waku (egoist/waku, GPLv3) targets multi-session affordances by building a nice, native frontend. For once it is not a fucking electron app, but a native-ish desktop (Rust on GPUI, the framework behind Zed) — that drives whichever agent CLIs are installed: Claude Code, Codex, pi … Instead of ACP, Waku intercepts the native protocol of the agents (stream-json for Claude Code, JSON-RPC for the rest) to be the agent frontend, rather than interfering with the code editor. Sessions, transcripts and tool activity from every agent land in a unified timeline on local disk, which provides nifty cross-agent identifiability.

Bonus feature: checkpointing. Every prompt snapshots the working tree under a hidden git ref, so a rewind rolls back the code and the provider conversation together, much like Aider’s git-per-change discipline, but made universal.

6 Good coding models

Choosing a good tool-using model seems important for most agentic workflows. tl;dr generic agentic tool-use is reputedly unreliable in models below roughly the 30B class.

Online, the answer is easy: take whichever big frontier model is currently on top because unreliability is expensive. These dominate over local models unless we have eye-wateringly good local hardware.

Check the leaderboards: Terminal-Bench and SWE-bench Verified. Artificial Analysis tracks price and tokens-per-second alongside the scores.

Offline, VRAM constrains which models we can use. I have a set of models I use on a Mac.

Those picks are all autoregressive, in the sense of generating tokens one after another. A language diffusion model is a sufficiently different inference paradigm that might benefit from a different sort of interface entirely.

7 MCP

Model Context Protocol is a standard to enable an agent to access tools and data. Here are some fun code-specific servers — find more at the official MCP Registry or punkpeye/awesome-mcp-servers.

oraios/serena gives an agent LSP-style symbol navigation and refactoring across 30-odd languages. Since some heavy hitters (Claude Code) ship no codebase index of their own, Serena might beat groping by grep on a large repo:

uv tool install -p 3.13 serena-agent
serena init
claude mcp add serena -- serena start-mcp-server --context claude-code --project "$(pwd)"

For git and GitHub operations — repos, PRs, issues, Actions — the official GitHub MCP server does the job, though in the name of safety, it requires a personal access token and a running docker daemon:

claude mcp add github \
  -e GITHUB_PERSONAL_ACCESS_TOKEN=$GITHUB_PAT \
  -- docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN ghcr.io/github/github-mcp-server

For the well-known problem of models hallucinating outdated APIs, there are docs-fetcher servers (Context7, Git-MCP), but a plain web-search/reader (jina-reader) seems to do the job for me. Browser automation (Playwright MCP, Chrome DevTools MCP) helps debug web apps, but I have not used those, so I will not speak of them further.

For Apple-platform vibecoding — XcodeBuildMCP plus Apple’s own xcrun mcpbridge — see Vibecoding Apple apps.

8 Driving an agent from the editor

If we want the agent to live inside the editor rather than in a terminal beside it, the Agent Client Protocol is how they talk. Zed and JetBrains speak it natively, community bridges exist for Neovim, Emacs and VS Code, and on this page Goose ships a goose acp server while Claude Code and Codex have adapters. It is a frontend-layer concern.

9 Packing code for AI

Sometimes we just want to flatten a whole codebase into a single blob and paste it into a chat window or seed a fresh context. This matters less than it used to — an agent with the search tools above rarely needs the whole repo at once — but for that one-shot case it’s still handy, since a model can read one text file easily but finds a scatter of files more confusing.

yamadashy/repomix is the classic, also available online at repomix.com. simonw/files-to-prompt is another favourite (background), and my fork supports a handy alternative usage pattern:

files-to-prompt --since v1.2.0 --since-scope working
files-to-prompt --since HEAD --since-scope staged

Also handy for online usage: cyclotruc/gitingest / Gitingest — “Replace ‘hub’ with ‘ingest’ in any GitHub URL to get a prompt-friendly extract of a codebase”.

10 Workflows

OK, we have a harness. How do we use it? The vibe coding workflow using git worktrees has been formalized, e.g. in Crystal, which manages a multi-session Claude Code across them (one checkout per session) — this is how we regain some of the parallelism despite the executor doing real work, since the agents no longer collide in the same tree. Modern harnesses often incorporate such a workflow into their design.

ghuntley/groundhog builds a coding agent from first principles as a teaching exercise, written up here, and with an interesting approach to design docs (now paywalled).

11 Incoming

Figure 3

12 References

Beurer-Kellner, Fischer, and Vechev. 2022. “Prompting Is Programming: A Query Language For Large Language Models.”
Bubeck, Chandrasekaran, Eldan, et al. 2023. “Sparks of Artificial General Intelligence: Early Experiments with GPT-4.”
Din, Karidi, Choshen, et al. 2023. “Jump to Conclusions: Short-Cutting Transformers With Linear Transformations.”
Robeyns, Szummer, and Aitchison. 2025. “A Self-Improving Coding Agent.” arXiv.org.
Suzgun, Scales, Schärli, et al. 2022. “Challenging BIG-Bench Tasks and Whether Chain-of-Thought Can Solve Them.”
Wang, Wei, Schuurmans, et al. 2023. “Self-Consistency Improves Chain of Thought Reasoning in Language Models.”
Weller, Boratko, Naim, et al. 2025. “On the Theoretical Limitations of Embedding-Based Retrieval.”