# DeepClaude：用 DeepSeek V4 替代 Claude Code 后端，成本降至 1/17

## 项目简介

DeepClaude 是一个开源工具，通过替换 Claude Code 的 API 后端，将其强大的自主编码代理循环（工具调用、文件编辑、bash 执行、git 操作、子代理派生等）与 DeepSeek V4 Pro 模型结合。核心思路保持 Claude Code 的"身体"（工具框架），替换"大脑"（推理模型）。

## 成本优势

DeepSeek V4 Pro 在 LiveCodeBench 上得分 96.4%，但其输出价格仅为 **$0.87/M tokens**，而 Anthropic 的 Claude Opus 为 **$15/M tokens**，价格相差约 **17 倍**。

| 使用场景 | Anthropic 月费 | DeepClaude | 节省 |
|---------|--------------|-----------|------|
| 轻度使用（10天/月） | $200/月（封顶） | ~$20/月 | 90% |
| 重度使用（25天/月） | $200/月（封顶） | ~$50/月 | 75% |
| 自动循环模式 | $200/月（封顶） | ~$80/月 | 60% |

DeepSeek 的自动上下文缓存功能使代理循环极其廉价——首次请求后，系统提示和文件上下文缓存价格降至 $0.004/M tokens。

## 多后端支持

| 后端 | 输入/M | 输出/M | 服务器位置 |
|------|-------|-------|-----------|
| DeepSeek（默认） | $0.44 | $0.87 | 中国 |
| OpenRouter | $0.44 | $0.87 | 美国 |
| Fireworks AI | $1.74 | $3.48 | 美国 |
| Anthropic（原始） | $3.00 | $15.00 | 美国 |

## 使用方式

```bash
deepclaude                    # 默认用 DeepSeek V4 Pro 启动
deepclaude --backend or       # 换 OpenRouter
deepclaude --backend anthropic  # 回到原始 Claude
deepclaude --cost             # 查看价格对比
```

## 兼容性

**正常工作：** 文件读写编辑、bash/PowerShell 执行、文件搜索、多步工具循环、子代理派生、git 操作、/init 初始化。

**不支持或降级：** 图像/视觉输入（DeepSeek 的 Anthropic 兼容端点不支持图片）、长上下文方面部分降级。

---

## 参考链接

- [GitHub: aattaran/deepclaude](https://github.com/aattaran/deepclaude)
- [Hacker News 讨论](https://news.ycombinator.com/item?id=635)
