Skip to content

Commit 2e1354a

Browse files
committed
docs(readme): lead with install, condense the feature highlights
Put the curl/npm install at the very top and trim the body to the features worth scanning — tournaments, rewind, cross-session memory, MCP, subagents, hooks — since most readers won't go deep.
1 parent e1e8139 commit 2e1354a

1 file changed

Lines changed: 46 additions & 63 deletions

File tree

README.md

Lines changed: 46 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -1,107 +1,90 @@
11
<h1 align="center">codebase</h1>
22

33
<p align="center">
4-
<strong>An AI coding agent for builders.</strong><br/>
5-
Lives in your terminal. Reads your project, writes code, runs commands, ships work.
4+
<strong>An AI coding agent that lives in your terminal.</strong><br/>
5+
Any LLM. Reads your project, writes code, runs commands, ships work.
66
</p>
77

88
<p align="center">
99
<a href="https://www.npmjs.com/package/codebase-cli"><img alt="npm" src="https://img.shields.io/npm/v/codebase-cli?style=flat-square" /></a>
1010
<a href="https://github.com/codebase-foundation/codebase-cli/blob/master/LICENSE"><img alt="license" src="https://img.shields.io/badge/license-MIT-blue?style=flat-square" /></a>
1111
</p>
1212

13-
<p align="center">
14-
Built on <strong><a href="https://github.com/earendil-works/pi">pi</a></strong> &mdash;
15-
the agent loop, provider adapters, and session protocol that make this whole
16-
thing tick. <a href="https://github.com/earendil-works/pi">Go give them a star.</a>
17-
</p>
13+
## Install
1814

19-
---
15+
Requires **Node.js ≥ 20**.
2016

21-
## Two ways to run it
17+
```sh
18+
# macOS / Linux
19+
curl -fsSL https://codebase.design/install.sh | sh
2220

23-
**Bring your own LLM.** Drop an API key in your shell and go — Anthropic, OpenAI, Groq, OpenRouter, Mistral, Ollama, any OpenAI-compatible endpoint.
21+
# Windows (PowerShell)
22+
irm https://codebase.design/install.ps1 | iex
2423

25-
```sh
26-
ANTHROPIC_API_KEY=sk-ant-... codebase
27-
# or
28-
OPENAI_API_KEY=sk-... codebase
24+
# any platform, with npm
25+
npm i -g codebase-cli
2926
```
3027

31-
**Sign in to [codebase.design](https://codebase.design) and skip key wrangling.** One auth, every model.
32-
33-
- **Free tier** — try open-weight models (MiniMax, Qwen, Llama, etc.) with a **10-turn taste** so you can kick the tires before paying anyone for anything. No API keys to set up.
34-
- **Paid account** — uncaps the open-weights, adds the frontier models (Claude Opus / Sonnet, GPT-5, …), higher rate limits, and longer context windows. One subscription replaces N provider bills.
28+
Then, in any project:
3529

3630
```sh
37-
codebase auth login
31+
cd your-project
3832
codebase
3933
```
4034

41-
Switch between models any time with `/model` (interactive picker) or `/model <id>`.
35+
Type, hit enter. It reads files, edits code, runs tests, and shows its work. `/help` lists everything.
4236

43-
## Install
37+
## Pick your LLM
4438

45-
Requires **Node.js ≥ 20**.
39+
**Bring your own key** — Anthropic, OpenAI, Groq, OpenRouter, Mistral, Ollama, or any OpenAI-compatible endpoint:
4640

4741
```sh
48-
# one-liner (macOS / Linux)
49-
curl -fsSL https://codebase.design/install.sh | sh
50-
51-
# Windows (PowerShell)
52-
irm https://codebase.design/install.ps1 | iex
53-
54-
# any platform
55-
npm i -g codebase-cli
42+
ANTHROPIC_API_KEY=sk-ant-... codebase # or OPENAI_API_KEY, GROQ_API_KEY, …
5643
```
5744

58-
## Quick start
45+
**Or sign in once** and skip the key wrangling — [codebase.design](https://codebase.design) gives you a free taste of open-weight models, and a paid account uncaps those plus the frontier models (Claude Opus/Sonnet, GPT-5, …) behind one bill. First run walks you through it; it even auto-detects a local LLM (LM Studio / Ollama / vLLM).
5946

6047
```sh
61-
cd your-project
62-
codebase
48+
codebase auth login
6349
```
6450

65-
Type. Hit enter. The agent reads files, runs tests, edits code, and shows you what it did. Slash `/help` for the rest.
51+
Swap models live with `/model`. Set reasoning depth with `/effort`.
52+
53+
## What makes it good
6654

67-
A few things worth knowing:
55+
- **🏁 Tournaments.** `/tournament <task>` races several agents on the same change in isolated worktrees, a judge ranks them, you merge the winner. `--models opus,sonnet,haiku` pits models head-to-head on *your* code.
56+
- **↺ Rewind anything.** `/rewind` rolls the conversation *and* the files back to before any earlier prompt — a bad turn fully un-happens. Every edit is checkpointed.
57+
- **🧠 Remembers across sessions.** Pulls durable facts (your prefs, project decisions, the rules you set) out of a session in the background so the next one starts informed. `#note` to add one by hand.
58+
- **🔌 MCP.** Connect external tool servers (filesystem, Postgres, git, fetch, …) over stdio or remote HTTP, OAuth and all. Their tools splice straight into the agent.
59+
- **🤖 Subagents.** Fan out read-only researchers or write-capable workers that keep their tool-noise out of your main context — each can run in its own git worktree, on its own model and reasoning level.
60+
- **🪝 Hooks.** Shell commands on lifecycle events (pre/post tool, edit, prompt, session start/end) — run a formatter on save, block secrets, commit on exit.
61+
- **🌐 SSH.** Run commands on enrolled remote hosts by name, behind the same safety validator as the local shell.
6862

69-
- `/model` — pick a model interactively, live list of what your account can hit
70-
- `/plan` — Q&A before the agent touches anything
71-
- `!cmd` — run a shell command without spending a turn
72-
- `@path` — pin a file into the next prompt
73-
- `\<Enter>` — multi-line input
74-
- **Type while the agent is working** — your prompt queues, fires when the current turn ends (`Ctrl-C` while busy clears the queue along with the turn)
75-
- **Ctrl-C** stops the current turn, twice fast exits
63+
…plus a fast differential TUI (clean copy-mode with `Ctrl-O`, image paste with `Ctrl-V`, history search with `Ctrl-R`, `$EDITOR` compose with `Ctrl-G`), **plan mode** for a cheap Q&A pass before editing, **auto-compaction** of long sessions, **multi-session resume** (`/resume`, `/rename`, `/tag`), **skills** & **output styles** as drop-in markdown, **45+ tools** behind one interface, and **effect-based permissions** you can teach with `/permissions`.
7664

77-
## What it does
65+
## Cheat sheet
66+
67+
```
68+
/model /effort /plan /tournament /rewind /resume /permissions /mcp /agents /help
69+
!cmd run a shell command without spending a turn
70+
@path pin a file into the next prompt
71+
#note save a memory · \<Enter> multi-line · Ctrl-C stop turn / exit
72+
```
7873

79-
- **Streaming responses.** Real-time token output, coalesced to 60 fps so the TUI doesn't thrash.
80-
- **Multi-turn agentic loop.** Tool call → result → next turn, automatically.
81-
- **Parallel tool execution.** Read-only tools (grep, glob, read, git status…) run concurrently within a turn.
82-
- **Project awareness.** Auto-loads `AGENTS.md`, `CLAUDE.md`, `CODEX.md`, or `.cursorrules` from the project root into the system prompt.
83-
- **Conversation compaction.** Long sessions automatically summarize older turns to stay under the context window.
84-
- **Session persistence.** Auto-resume from where you left off; `--new` for a clean slate.
85-
- **Plan mode.** A cheap-model Q&A pass surfaces the right plan before the expensive agent starts editing.
86-
- **Intent routing.** Chit-chat doesn't burn a full agent turn; complex asks roll into plan mode automatically.
87-
- **Subagent dispatch.** Spawn isolated research agents that keep their tool noise out of your main context.
74+
Type while it's working — your prompt queues and fires when the turn ends.
8875

89-
## Builder-focused defaults
76+
## Built on pi
9077

91-
- **Any LLM**, not just Anthropic. Provider choice is config.
92-
- **45+ tools** behind one small interface — adding one is mechanical.
93-
- **Effect-based permissions** instead of tool-name allowlists.
94-
- **Single immutable state** driven by a typed reducer — the UI is one render of one value.
95-
- **Multi-process safe OAuth** with lockfile-coordinated token refresh — run 10 instances of codebase at once and they share a single refresh per hour.
96-
- **Plain `npm i -g`**, no bundler lock-in.
78+
The agent loop, provider adapters, and session protocol come from
79+
**[pi](https://github.com/earendil-works/pi)** (MIT). Go give them a star.
9780

9881
## More
9982

100-
- [`.settings/`](.settings/)orientation: tenets, architecture, extending, testing
101-
- [`CLAUDE.md`](CLAUDE.md)quick reference for AI agents working in this repo
83+
- [`CLAUDE.md`](CLAUDE.md)full feature reference
84+
- [`.settings/`](.settings/)tenets, architecture, extending, testing
10285
- [`docs/MIGRATION_v1_to_v2.md`](docs/MIGRATION_v1_to_v2.md) — upgrading from the Go v1 binary
103-
- `/help` inside the CLI — every slash command and shortcut
86+
- `/help` inside the CLI — every command and shortcut
10487

10588
## License
10689

107-
MIT. Built on [pi-mono](https://github.com/earendil-works/pi) (MIT).
90+
MIT.

0 commit comments

Comments
 (0)