|
| 1 | +# Codebuff |
| 2 | + |
| 3 | +Codebuff is a tool for editing codebases via natural-language instructions to Buffy (an expert AI programming assistant). |
| 4 | + |
| 5 | +## Goals |
| 6 | + |
| 7 | +- Make expert engineers faster (power-user focus). |
| 8 | +- Reduce time/effort for common programming tasks. |
| 9 | +- Improve via iteration/feedback (learn/adapt from usage). |
| 10 | + |
| 11 | +## Key Technologies |
| 12 | + |
| 13 | +- TypeScript monorepo (Bun workspaces) |
| 14 | +- Bun runtime + package manager |
| 15 | +- Next.js (web app + API routes) |
| 16 | +- Multiple LLM providers (Anthropic/OpenAI/Gemini/etc.) |
| 17 | + |
| 18 | +## Repo Map |
| 19 | + |
| 20 | +- `cli/` — TUI client (OpenTUI + React) and local UX |
| 21 | +- `sdk/` — JS/TS SDK used by the CLI and external users |
| 22 | +- `web/` — Next.js app + API routes (the "web API") |
| 23 | +- `packages/agent-runtime/` — agent runtime + tool handling (server-side) |
| 24 | +- `common/` — shared types, tools, schemas, utilities |
| 25 | +- `agents/` — main agents shipped with codebuff |
| 26 | +- `.agents/` — local agent templates (prompt + programmatic agents) |
| 27 | + |
| 28 | +## Docs |
| 29 | + |
| 30 | +- [`docs/architecture.md`](docs/architecture.md) — Package dependency graph, per-package details, key architectural patterns |
| 31 | +- [`docs/request-flow.md`](docs/request-flow.md) — Full request lifecycle from CLI through server and back |
| 32 | +- [`docs/error-schema.md`](docs/error-schema.md) — Server error response formats and client-side handling |
| 33 | +- [`docs/error-handling.md`](docs/error-handling.md) — ErrorOr pattern for return values |
| 34 | +- [`docs/development.md`](docs/development.md) — Dev setup, worktrees, logs, package management, DB migrations |
| 35 | +- [`docs/testing.md`](docs/testing.md) — Testing conventions, DI over mocking, tmux CLI testing |
| 36 | +- [`docs/environment-variables.md`](docs/environment-variables.md) — Env var rules, DI helpers, loading order |
| 37 | +- [`docs/agents-and-tools.md`](docs/agents-and-tools.md) — Agent system, shell shims, tool definitions, referral system |
| 38 | +- [`docs/git-guidelines.md`](docs/git-guidelines.md) — Git safety rules |
0 commit comments