---
title: "Caveman"
description: "Your harness. Any model. Half the bill."
canonical: https://caveman.so/caveman
last-updated: 2026-10-07
---

# Caveman

Your harness. Any model. Half the bill.

Caveman wraps the coding agent you already run (Claude Code, Codex, OpenCode,
Gemini CLI, Qwen Code, Aider and 30+ more). It trims what every turn reads and
writes, and can hand each subagent task to the cheapest model that gets it
right. Free and open source (MIT).

## Install

```sh
npm i -g @caveman-ai/cli && caveman setup --install
caveman claude   # or codex · opencode · gemini · qwen · aider
```

## How it works

- **Reads less.** Logs, test output, JSON, diffs and web pages are compressed
  before the model reads them. The original stays on disk and the agent can ask
  for it. Whole sessions used 33.2% fewer input tokens (885,793 → 591,673) across
  6 tasks with 3 paired runs each, with 18 of 18 answers right in both groups.
- **Says less.** The skill removes filler from replies while keeping code,
  commands and errors byte for byte. 65% less readable output on a 10-prompt
  benchmark (range 22–87%). On long-horizon coding tasks, where most tokens are
  input and code, that is about 10% fewer tokens in total.
- **Picks the model.** Adaptive model selection gives each turn the cheapest model and effort that
  can do the job and keeps the frontier model for hard work. In a paired run on 85
  agentic coding tasks from SWE-Interact and SWE-Together, routed Claude Code cost 0.46× as much per task as always running
  Opus 5.5 at max effort, with the same solve rate within the confidence interval
  (interim run, list-price estimates). Routing needs a free Caveman account
  and a router key. If the router is missing, slow or fails, the task runs
  exactly as the agent asked.
- **Keeps the script.** Blocks keep the scripts agents keep rewriting in your
  repo, check them on every PR and hand them back. Pre-release.

## Any provider

Inside Claude Code the router hook can run non-Anthropic models on your own
OpenRouter key, for example `google/gemini-3.7-flash` or
`openrouter/deepseek/deepseek-v4-pro-0813`. The router works for GPT, Claude,
Gemini, DeepSeek, Grok, Mistral and Qwen.

## Adoption

More than 100,000 GitHub stars. #1 on Hacker News (904 points) and #1 on GitHub
Trending (July 2026).

- GitHub: https://github.com/JuliusBrussee/caveman
- Docs: https://docs.caveman.so
