docs: make Chinese README the default
CI / Change detection (push) Has been cancelled
Sync to CNB / sync (push) Has been cancelled
Auto-close harvested PRs / close (push) Has been cancelled
CI / Version drift (push) Has been cancelled
cargo-deny / cargo-deny (advisories) (push) Has been cancelled
cargo-deny / cargo-deny (bans licenses sources) (push) Has been cancelled
CI / Documentation (push) Has been cancelled
Security audit / cargo-audit (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Workflow RLM cache (push) Has been cancelled
CI / Test (macos-latest) (push) Has been cancelled
CI / Test (ubuntu-latest) (push) Has been cancelled
CI / Test (windows-latest) (push) Has been cancelled
CI / npm wrapper smoke (push) Has been cancelled
CI / Mobile runtime smoke (push) Has been cancelled
CI / Workflow lint (push) Has been cancelled

This commit is contained in:
wehub-resource-sync
2026-07-13 09:52:52 +00:00
parent d68f003000
commit ed21c6a37d
+33 -69
View File
@@ -1,36 +1,35 @@
<!-- WEHUB_ZH_README -->
> [!NOTE]
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
> [English](./README.en.md) · [原始项目](https://github.com/Hmbown/CodeWhale) · [上游 README](https://github.com/Hmbown/CodeWhale/blob/HEAD/README.md)
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
<!-- source: README.md sha256:561a074b0e36 -->
# CodeWhale
A coding agent for your terminal. Works with any model; open models first.
一个运行在终端里的编程智能体。适配任意模型;开放模型优先。
You give it a provider, a model, and a task. It reads code, edits files, runs
commands, checks the results, and keeps going until the task is done or it
needs you. TUI for interactive work, `codewhale exec` for scripts and CI.
Rust, MIT, runs entirely on your machine.
你给它一个 provider、一个模型和一个任务。它读代码、改文件、跑命令、检查结果,一直做到任务完成或需要你介入为止。交互式工作用 TUI,脚本和 CI 用 `codewhale exec`。Rust 编写,MIT 许可,完全在你自己的机器上运行。
It started as `deepseek-tui`. The community that formed around it needed more
providers, so now DeepSeek, Claude, GPT, Kimi, GLM, and 30+ others run through
the same runtime and tools.
它最初叫 `deepseek-tui`。围绕它形成的社区需要更多 provider,于是现在 DeepSeek、Claude、GPT、Kimi、GLM 以及其他 30 多个模型都跑在同一套运行时和工具之上。
[简体中文](README.zh-CN.md) · [日本語](README.ja-JP.md) · [Tiếng Việt](README.vi.md) · [한국어](README.ko-KR.md) · [Español](README.es-419.md) · [Português](README.pt-BR.md) · [codewhale.net](https://codewhale.net/) · [Docs](docs) · [Changelog](CHANGELOG.md)
[English](README.md) · [日本語](README.ja-JP.md) · [Tiếng Việt](README.vi.md) · [한국어](README.ko-KR.md) · [Español](README.es-419.md) · [Português](README.pt-BR.md) · [codewhale.net](https://codewhale.net/) · [Docs](docs) · [Changelog](CHANGELOG.md)
[![CI](https://github.com/Hmbown/CodeWhale/actions/workflows/ci.yml/badge.svg)](https://github.com/Hmbown/CodeWhale/actions/workflows/ci.yml)
[![crates.io](https://img.shields.io/crates/v/codewhale-cli?label=crates.io)](https://crates.io/crates/codewhale-cli)
[![npm](https://img.shields.io/npm/v/codewhale?label=npm)](https://www.npmjs.com/package/codewhale)
![CodeWhale running in a terminal](assets/screenshot.png)
![CodeWhale 在终端中运行](assets/screenshot.png)
## Install
## 安装
```bash
npm install -g codewhale
```
Cargo, Docker, Nix, Scoop, prebuilt archives, Android/Termux, and a CNB mirror
for users who cannot reach GitHub are covered in
[docs/INSTALL.md](docs/INSTALL.md). Coming from `deepseek-tui`? Your config and
sessions carry over — see [docs/REBRAND.md](docs/REBRAND.md).
CargoDockerNixScoop、预编译归档、Android/Termux,以及面向无法访问 GitHub 用户的 CNB 镜像,均见 [docs/INSTALL.md](docs/INSTALL.md)。从 `deepseek-tui` 迁移过来?你的配置和会话可以直接沿用——见 [docs/REBRAND.md](docs/REBRAND.md)。
## Use
## 使用
```bash
codewhale auth set --provider deepseek # or export ANTHROPIC_API_KEY, etc.
@@ -38,68 +37,33 @@ codewhale # open the TUI
codewhale exec "fix the failing test" # headless
```
In the TUI: `/model` switches provider and model together, `/fleet` runs a
team of workers, `/restore` undoes a turn, `Tab` cycles Plan / Act / Operate,
`Shift+Tab` cycles the Ask / Auto-Review / Full Access approval posture, and
`!` runs a shell command through the normal approval path.
TUI 中:`/model` 同时切换 provider 和模型,`/fleet` 运行一组 worker`/restore` 撤销某一轮,`Tab` 在 Plan / Act / Operate 之间循环切换,`Shift+Tab` 在 Ask / Auto-Review / Full Access 审批姿态之间循环切换,`!` 让 shell 命令经由正常的审批路径运行。
## What it does
## 它做什么
- Resolves your provider + model choice to a concrete route: endpoint, wire
protocol, context limit, price. Context budgets and cost display come from
the real route; an unknown price shows as unknown, not $0.
([docs/PROVIDERS.md](docs/PROVIDERS.md))
- Talks to hosted open-model providers (`deepseek`, `openrouter`, `moonshot`,
`zai`, `minimax`, `nvidia-nim`, …), to your own `vllm` / `sglang` / `ollama`
with no key, and to Anthropic natively over the Messages API with thinking
and prompt caching.
- Runs multiple workers durably: Fleet records work in an append-only ledger,
so runs survive restarts and `fleet resume` picks up where things stopped.
Workflow plans bigger jobs into resumable, verifiable lanes.
([docs/FLEET.md](docs/FLEET.md))
- Gates risk in code, not vibes: three modes (Plan is read-only), a separate
approval posture, OS sandboxing (Seatbelt, Landlock + seccomp, bwrap),
hooks that can allow/deny/ask per tool call, and side-git snapshots so
`/restore` never touches your real history.
- Lets a repo declare its own law: `.codewhale/constitution.json` invariants
compile into write holds that even Full Access can't skip.
([docs/CONFIGURATION.md](docs/CONFIGURATION.md))
- Speaks MCP in both directions, loads reusable skills, exposes HTTP/SSE and
ACP runtime APIs, and backs a community
[VS Code GUI](https://github.com/HengQuWorld/CodeWhale-VSCode).
- The TUI shows work as receipts you can inspect, keeps one live row moving,
has a real context inspector, 12 themes, reduced-motion and ASCII-safe
modes, and ships in English, 简体中文, 日本語, Tiếng Việt, Español,
Português, 한국어, and partial 繁體中文.
- 把你选定的 provider + 模型解析为一条具体路由:端点、传输协议、上下文上限、价格。上下文预算与费用显示都取自真实路由;价格未知时就显示未知,而不是 $0。([docs/PROVIDERS.md](docs/PROVIDERS.md)
- 可连接托管的开放模型 provider(`deepseek``openrouter``moonshot``zai``minimax``nvidia-nim` 等),可无 key 直连你自己的 `vllm` / `sglang` / `ollama`,也能通过 Messages API 原生对接 Anthropic,支持 thinking 与 prompt 缓存。
- 以可持久化的方式运行多个 worker:Fleet 把工作记录在只追加的账本里,运行不会因重启而丢失,`fleet resume` 能从中断处继续。Workflow 把更大的任务规划成可恢复、可验证的 lane。([docs/FLEET.md](docs/FLEET.md)
- 风险把关靠代码,不靠感觉:三种模式(Plan 为只读)、独立的审批姿态、操作系统级沙箱(Seatbelt、Landlock + seccomp、bwrap)、可对每次工具调用做 allow/deny/ask 决策的 hooks,以及 side-git 快照——`/restore` 永远不会碰你真正的提交历史。
- 允许仓库声明自己的法律:`.codewhale/constitution.json` 中的不变量会编译成写入拦截,连 Full Access 也无法跳过。([docs/CONFIGURATION.md](docs/CONFIGURATION.md)
- 双向支持 MCP,可加载可复用的 skills,对外提供 HTTP/SSE 与 ACP 运行时 API,并支撑社区维护的 [VS Code GUI](https://github.com/HengQuWorld/CodeWhale-VSCode)。
- TUI 把工作显示为可逐条查验的回执,同一时间只让一行保持动态,内置真实的上下文查看器、12 套主题、减弱动效与 ASCII 安全模式,界面语言覆盖英语、简体中文、日语、越南语、西班牙语、葡萄牙语和韩语,繁体中文为部分翻译。
Everything else — configuration, keybindings, sandbox details, architecture —
is in [docs](docs) and on [codewhale.net](https://codewhale.net/).
其余内容——配置、键位绑定、沙箱细节、架构——见 [docs](docs) 与 [codewhale.net](https://codewhale.net/)。
## Contributing
## 贡献
All feedback is a gift. Issues, PRs, repro steps, logs, feature requests, and
first contributions are all real project work here. When a PR can't merge
as-is, maintainers harvest what works and the author stays credited — in the
commit, the changelog, and [docs/CONTRIBUTORS.md](docs/CONTRIBUTORS.md). If a
model or provider you use is missing, or something breaks on your machine,
telling us is the most useful thing you can do.
所有反馈都是礼物。Issue、PR、复现步骤、日志、功能请求和第一次贡献,在这里都算真实的项目工作。当一个 PR 无法原样合并时,维护者会吸收其中可用的部分,作者的署名会保留——在提交、更新日志和 [docs/CONTRIBUTORS.md](docs/CONTRIBUTORS.md) 中。如果你在用的某个模型或 provider 还不支持,或者有什么东西在你机器上坏了,告诉我们就是你能做的最有用的事。
- [Open issues](https://github.com/Hmbown/CodeWhale/issues) — good first
contributions live here
- [CONTRIBUTING.md](CONTRIBUTING.md) — dev setup and PR flow
- [docs/CONTRIBUTORS.md](docs/CONTRIBUTORS.md) — everyone who has shaped this
- [开放 issue](https://github.com/Hmbown/CodeWhale/issues) —— 适合入门的贡献在这里
- [CONTRIBUTING.md](CONTRIBUTING.md) —— 开发环境搭建与 PR 流程
- [docs/CONTRIBUTORS.md](docs/CONTRIBUTORS.md) —— 每一位塑造过这个项目的人
- [Buy me a coffee](https://www.buymeacoffee.com/hmbown)
Thanks to [DeepSeek](https://github.com/deepseek-ai) for the models and support
that started the project, [DataWhale](https://github.com/datawhalechina) 🐋 for
welcoming us into the Whale Brother family, and
[OpenWarp](https://github.com/zerx-lab/warp) and
[Open Design](https://github.com/nexu-io/open-design) for collaborating on the
terminal-agent experience.
感谢 [DeepSeek](https://github.com/deepseek-ai) 提供让项目起步的模型与支持,感谢 [DataWhale](https://github.com/datawhalechina) 🐋 欢迎我们加入“鲸兄弟”大家庭,也感谢 [OpenWarp](https://github.com/zerx-lab/warp) 与 [Open Design](https://github.com/nexu-io/open-design) 在终端智能体体验上的协作。
## License
## 许可证
[MIT](LICENSE). Independent community project; not affiliated with any model
provider.
[MIT](LICENSE)。独立的社区项目,与任何模型 provider 均无隶属关系。
[![Star History Chart](https://api.star-history.com/chart?repos=Hmbown/CodeWhale&type=date&legend=top-left)](https://www.star-history.com/?repos=Hmbown%2FCodeWhale&type=date)