The economical
coding agent.

Saves tokens, brain cycles, computer power, and your privacy.

╶──╮ ╶──┤ 3code v0.8.4 the economical coding agent ╶──╯ provider zaicode model glm-5.3 type a prompt. :help for commands. :q or Ctrl-D to exit. ❯  

Why 3code

AI coding is stuck between two bills you can't control: subscriptions priced like enterprise software, and API meters that tax every exploratory prompt. 3code starts from a simpler premise- the cheapest token is the one you never send.

So it sweats the unglamorous wins. Prompt and context optimizations most agents skip, and an algorithm that keeps long sessions from bloating. In the runs below, other agents burn up to 4.6x the tokens for the same tasks.

The savings don't stop at the invoice. A 3.2 MB binary that sips RAM and CPU keeps the laptop cool through long runs, and the quiet unixy interface keeps you in the work: a token bar and a thinking ticker say what a turn costs while it happens, then get out of the way.

The essentials ship in the box- web search, sandboxing, every platform- and a resumed session picks up with the provider's cache still hot. Skills and command line tools extend it when a task wants more, and cost nothing when it doesn't.

Get started

Get a provider

use your existing subscription

Tip: you can use expensive models on small subscriptions with 3code. Leave the task and it will continue automatically when your 5h window resets.

Nearly everything else that speaks the OpenAI protocol works too- Kimi and DeepSeek (subscription or API), OpenRouter, local servers like Ollama, and many more. If your provider isn't on a card above, chances are it just works.

More providers

Install 3code and enter your API key

$ mkdir -p ~/.local/bin && curl -fsSL https://3code.capocasa.dev/i64 | tar xz -C $_ 3code
$ mkdir -p ~/.local/bin && curl -fsSL https://3code.capocasa.dev/a64 | tar xz -C $_ 3code
$ mkdir -p ~/.local/bin && curl -fsSL https://3code.capocasa.dev/osx | tar xz -C $_ 3code
> irm https://3code.capocasa.dev/install.ps1 | iex
$ curl -fsSL https://3code.capocasa.dev/t | tar xz -C $PREFIX/bin 3code
$ mkdir myprojectdir
$ cd myprojectdir
$ 3code
  ╶──╮
  ╶──┤    3code v0.8.4   the economical coding agent
  ╶──╯

  no provider configured. let's add one. (ctrl+d to quit)
  supported: deepinfra, ovh, nvidia, nebius, fireworks

  api key              : ************************
  provider name or url : nvidia
  verifying... ok
  saved to ~/.config/3code/config

Run your first prompt

❯ Build me a Hello World program in Nim

The 3E in 3code

Carlo Capocasa

3code exists, and was made the way it is, because of a few very simple observations about AI coding- made from far away Munich, Germany, where most hype is quickly drowned in a perfectly tapped quart mug of Lager.

  1. AI programming leads to a real dilemma- you can't really afford it (it's subsidized from very high marketing budgets), but you can't afford to do without it.
  2. The subsidy is a real problem because it leads to unpredictability. Growth and enshittification- never questioned in the valley- lead to real distrust of technology as such in the rest of the world. AI is just an extreme example.
  3. The solution is efficiency and bargaining- you need to make every token count, and that's something the main AI companies just are not doing- they are optimizing for maximum performance to be impressive.
  4. The main AI companies are completely unable to shift towards efficiency in any meaningful way- it's company DNA.

The purpose of 3code is to find and use simple, common sense measures to be as token efficient as possible with existing providers, and make it as seamless as possible to switch providers to increase your bargaining power. Switching from Claude to Codex is still a big step- style is different, skills stop working. If you are used to GLM and the z.ai coding plan is down, you can just swap in mistral in the same session. This drives prices down.

3code also adheres to my- Carlo's- ideas about what good software is. Not minimalism, economy: the features it takes to be genuinely usable, at the smallest footprint that permits them. You shouldn't have to install a web search plugin or worry about sandboxing, but you shouldn't spend tokens on sandboxing either. One binary, native on Linux, OSX, and Windows, Android via termux, more platforms coming up. And a fancy unixy interface- proper scrollback, honest exit codes, non-interactive use for scripts, and just two dynamic lines when you're at the prompt. Inspired by curl's progress.

The name is a small shtick that keeps me honest. The 3 stands for 3rd party- not beholden to any provider, MIT open source, binary built from source, no shenanigans possible- and that is what makes switching providers real bargaining power. It also stands for the three kinds of 3fficiency, one per card below.

Give it a spin and tell me what you think in https://community.3code.capocasa.dev!

E1
Token efficiency

Your bills are lower and your plan lasts longer. Free-tier tokens do real work, and you stop thinking twice before asking. Nothing else about your setup has to change: just swap the agent.

E2
Computer efficiency

No lap burn, longer battery life, and a machine that stays snappy even with dozens of agents running side by side.

E3
Ergonomics

No distractions, no gimmicks, and a learning curve so low you are productive in minutes. You stay focused, so more of what you build actually works.

Community

The forum is open at community.3code.capocasa.dev. Install help is available there, along with everything else: questions, frustrations, tips, or anything you made with 3code.

join the forum

Data to back it up

Independent agent benchmarks are rare- vendors benchmark their own tools on their own terms, so I run my own. The recipe: a 10-task subset of SWE-bench Verified, every agent through the same proxy on the same model, the same per-task time cap, vanilla configs. Small but honest, and the pattern repeats across rounds: 3code lands at or near the top, with tokens to spare.

A 40-task version is in the works.

SWE-bench Verified: tasks resolved
10-task subset, five agents on Z.ai GLM-5.3 via the same LiteLLM proxy, 600s per-task cap, vanilla configs
3code 7 / 10
pi 6 / 10
zcode 6 / 10
hermes 6 / 10
opencode 6 / 10
Total tokens
batch total across all 10 tasks
3code 4,209,360
pi 4,641,357
zcode 4,766,000
hermes 6,072,610
opencode 6,771,747

3code used 9% fewer tokens than pi and resolved one more task. Output tokens are the starkest gap: 71,751 for 3code vs 117,707 for pi- a 1.6× difference, and on a pay-per-token API that's money on every single turn.

Rerun: GLM-5.3, six agents incl Claude Code
same 10 tasks, 2026-09-05/06, rows ordered by total token use (prompt + output, cache-inclusive)
3code 5.1M · 9 / 10
pi 7.2M · 6 / 10
opencode 10.0M · 9 / 10
zcode 14.2M · 6 / 10
hermes 16.8M · 7 / 10
claude 23.1M · 8 / 10

Every agent hit 93–99% context-cache reads on the Z.ai coding plan, so spend tracks context volume: Claude Code processed 4.6× 3code's tokens to resolve one fewer task. 3code and opencode tie at 9/10, with 3code doing it at half the tokens. See the full report, grid and methodology.

Output tokens
batch total across all 10 tasks
3code 71,751
pi 117,707

Terse output is a design decision in 3code; pi's chattier reply style is a design decision in pi. On a pay-per-token API, that difference is money on every single turn.

Earlier round: GLM-5.2 vs opencode
same 10-task subset, same LiteLLM proxy
3code ~295k non-cached input
opencode ~1.45M non-cached input

On the same tasks with GLM-5.2, 3code yielded 4× savings vs opencode- 75% fewer tokens across the board- and resolved a task opencode failed. Zero eval errors, zero unresolved patches. See the blog post, full per-task data and methodology, and the GLM-5.2 round.

Technical Details

3code for companies

Carlo can help discover how to benefit from lower costs and more predictable AI assisted coding in your company.

schedule a call

Contributing

Patches welcome at github. Open an issue, send a PR, or just try the bleeding edge and report back.

Testing

Install the latest main branch build (no tagged release needed):

# macOS / Linux
$ curl -fsSL https://3code.capocasa.dev/main/install | sh
# Windows (PowerShell)
> irm https://3code.capocasa.dev/main/install.ps1 | iex
Founder led, founder held