🤖 保存我的代币
卸载Claude Code任务以释放LLM API-为重要的事情保存令牌
  ](https://nodejs.org)
停止在免费LLM可以处理的任务上燃烧Claude令牌。受到启发 GSD(完成任务),但设计用于 保存您的Claude使用 通过智能地将工作卸载到免费的API层。
______________________________________________________________________
💡 问题
你喜欢GSD和Claude Code的工作流程,但是:
- 💸 代币成本加起来很快 -研究、规划、代码生成都会耗尽你的极限
- ⚡ 克劳德什么都做 -即使是免费LLM可以处理的简单任务
- 📊 无能见度 -您不知道每个任务使用了多少令牌
- 🔥 利率限制受到严重打击 -密集的工作流程会耗尽您的每日配额
如果克劳德可以委派给自由工人呢?
______________________________________________________________________
✨ 解决方案
保存我的令牌让克劳德 智能卸载任务 免费LLM API:
- 🎯 智能委托 -克劳德策划,自由球员执行
- 💰 代币节省 -使用Claude进行决策,使用免费LLM进行重物搬运
- 🚀 免费层API -Cerebras、Mistral(都有慷慨的免费等级)
- 📊 实时进度 -看看到底发生了什么(没有无声的悬挂)
- 🔄 智能缓存 -切勿为同一查询支付两次费用
- ⚡ 零配置 -插入任务文件,自动发现处理其余部分
运作原理
User: "Research AI trends and write a summary"
↓
Claude Code: "I'll delegate the research to free agents"
↓
Save My Tokens: Research task → Cerebras API (FREE) ✅
Writing task → Mistral API (FREE) ✅
↓
Claude Code: Reviews results, provides final polish
↓
Result: Task done. Claude tokens saved! 🎉克劳德没有在研究中燃烧10K代币,而是使用约100个代币来编排和审查自由代理的工作。
______________________________________________________________________
🎬 快速演示
安装:
# One command install
npx github:Dan-paull/save-my-tokens install
# Add API keys (all FREE tiers!)
# Cerebras: https://cerebras.ai (fast, generous free tier)
# Mistral: https://mistral.ai (free tier available)克劳德代码中的用法:
You: "Research the latest developments in quantum computing"
Claude: "I'll use the research tool to gather information"
[Behind the scenes: Save My Tokens routes to Cerebras - FREE]
🎯 Processing research request
🧠 Selected: cerebras (free tier)
🚀 Starting: cerebras/llama-3.3-70b
📡 Sending request to Cerebras API (FREE)
⏳ Waiting for response...
📥 Received 15KB, 1234 tokens in 3s
✅ Completed - Claude tokens saved: ~1000 tokens! 💰你的克劳德代币? 仅用于编排(约50个令牌),而不是完整的研究(约1000个令牌)。
______________________________________________________________________
💰 成本节约
保存我的代币之前(纯克劳德)
Research task: 1000 tokens
Code generation: 2000 tokens
Planning: 1500 tokens
Code review: 800 tokens
───────────────────────────────
Total per workflow: 5300 tokens
Daily limit: ~50,000 tokens (Sonnet)
Workflows/day: ~9 workflows保存我的代币后(Claude+免费API)
Research task: 50 tokens (orchestration) + FREE API
Code generation: 100 tokens (review) + FREE API
Planning: 75 tokens (coordination) + FREE API
Code review: 50 tokens (oversight) + FREE API
──────────────────────────────────────────────
Total per workflow: 275 tokens
Daily limit: ~50,000 tokens
Workflows/day: ~180 workflows结果:在相同的Claude代币预算下,工作流程增加了19倍! 🚀
______________________________________________________________________
📦 安装
先决条件
- Node.js 18+
- 克劳德代码(用于MCP集成)
- 免费API密钥 至少来自一家提供商(免费会员不需要信用卡!)
快速安装
# Install
npx github:Dan-paull/save-my-tokens install
# Get FREE API keys (no credit card required)
# Cerebras: https://cerebras.ai - Very fast, generous limits
# Mistral: https://mistral.ai - Good free tier
# Add to .env.savemytokens
nano .env.savemytokens
# Restart Claude Code
pkill -f "claude --"
# Done! Claude can now delegate to free agents! 🎉验证安装
npx github:Dan-paull/save-my-tokens status
npx github:Dan-paull/save-my-tokens test______________________________________________________________________
🎯 何时使用保存我的令牌
卸载以保存我的令牌:
- ✅ 研究和信息收集
- ✅ 代码生成(初稿)
- ✅ 建筑规划(多视角)
- ✅ 代码审查(初步分析)
- ✅ 文件编写
- ✅ 头脑风暴和构思
留在克劳德:
- ⭐ 最终决策
- ⭐ 需要上下文的复杂推理
- ⭐ 关键代码更改
- ⭐ 敏感信息处理
- ⭐ 需要项目完整背景的任务
战略: 让自由球员做重活,克劳德做最后的润色。
______________________________________________________________________
🎯 可用任务
| 任务 | 它的作用 | 代币节省 | 使用了自由代理 |
|---|---|---|---|
| 研究 | 信息收集、网络研究 | ~1000个令牌/任务 | Cerebras(快速)或Mistral |
| 编程 | 代码生成,初稿 | ~2000个令牌/任务 | Cerebras或Mistral |
| 规划 | 架构设计,多种策略 | ~1500个令牌/任务 | Mistral或Cerebras |
| 代码审查 | 初始代码分析 | ~800个令牌/任务 | Mistral或Cerebras |
所有任务都可以在中运行:
- 并联模式 -多个自由代理,提供不同的视角(研究、规划)
- 级联模式 -按顺序尝试自由代理,直到成功(编码、审核)
______________________________________________________________________
🚀 免费API提供商
以下所有供应商均提供 慷慨的免费等级 -无需信用卡:
Cerebras(推荐用于速度)
- 型号: 骆驼-3.3-70b
- 速度: 1800+代币/秒(极速!)
- 免费等级: 非常慷慨
- 最适合: 研究、快速编码任务
- 获取密钥: https://cerebras.ai
米斯特拉尔AI
- 型号: mistral小最新
- 速度: 快
- 免费等级: 可用
- 最适合: 平衡任务、计划、审查
- 获取密钥: https://mistral.ai
设置: 从Cerebras和/或Mistral获得免费API密钥,添加到 .env.savemytokens,你准备好了!
💡 马上就来: 在未来的版本中,将添加更多的免费套餐提供商!
______________________________________________________________________
🏗️ 建筑
┌─────────────────────────────────────────────────────────────┐
│ CLAUDE CODE │
│ (Orchestration, decision making, final review) │
│ Token usage: ~50-100 per task │
└────────────────────┬────────────────────────────────────────┘
│
│ MCP Protocol
▼
┌─────────────────────────────────────────────────────────────┐
│ FREE AGENTS MCP SERVER │
│ - Task routing & model selection │
│ - Real-time progress streaming │
│ - Smart caching (don't repeat work) │
│ - Automatic failover │
└────────────────────┬────────────────────────────────────────┘
│
┌────────────┴────────────┐
│ │
▼ ▼
┌─────────┐ ┌─────────┐
│Cerebras │ │ Mistral │
│ FREE │ │ FREE │
└─────────┘ └─────────┘
│ │
└────────────┬────────────┘
│
Heavy lifting done here
Claude tokens: SAVED! 💰______________________________________________________________________
💡 用法示例
研究任务
在保存我的代币之前:
You: "Research the top 10 AI coding assistants in 2025"
Claude: [Uses 1200 tokens doing all the research itself]使用Save My Tokens:
You: "Research the top 10 AI coding assistants in 2025"
Claude: "I'll use the research tool" [Uses 50 tokens]
↓
Free Agent (Cerebras): [Does research using FREE API]
↓
Claude: [Reviews and formats - 50 tokens]
Token savings: 1100 tokens! (92% reduction)代码生成
之前:
You: "Write a Python function to parse JSON with error handling"
Claude: [Uses 2000 tokens generating code]使用Save My Tokens:
You: "Write a Python function to parse JSON with error handling"
Claude: "I'll use the coding tool" [Uses 80 tokens]
↓
Free Agent (Cerebras or Mistral): [Generates code using FREE API]
↓
Claude: [Reviews and refines - 100 tokens]
Token savings: 1820 tokens! (91% reduction)______________________________________________________________________
📊 实时进度
看看到底发生了什么(不再怀疑它是否卡住了):
🎯 Processing research request
🧠 Analyzing available models
🧠 Selected: cerebras (FREE tier - fast!)
🚀 Starting: cerebras/llama-3.3-70b
🔄 Checking cache... (save even more!)
📡 Sending request to Cerebras API
⏳ Waiting for response...
📥 Received 15KB, 1234 tokens in 3s
✅ Completed: cerebras/llama-3.3-70b (3s)
💰 Claude tokens saved: ~1000 tokens
🎉 Success - Result ready for Claude to review!使用缓存:
🔄 Checking cache for: cerebras/llama-3.3-70b
⚡ Cache hit! Using cached result (instant)
💰 API call saved! Claude tokens saved!
🎉 Success (0s)______________________________________________________________________
🔧 配置
基本设置(.env.savemytokens)
# Get these keys FREE (no credit card):
# Cerebras (Recommended - very fast!)
CEREBRAS_API_KEY=your_free_key_here
CEREBRAS_MODEL=llama-3.3-70b
# Mistral
MISTRAL_API_KEY=your_free_key_here
MISTRAL_MODEL=mistral-small-latest
# Caching (save even more!)
SAVE_MY_TOKENS_CACHE_ENABLED=true
SAVE_MY_TOKENS_CACHE_DIR=./cache任务配置(tasks/\*.json)
自定义哪些自由代理处理哪些任务:
{
"task": "research",
"task_type": "information",
"run_multiple": true, // Use multiple agents for diverse perspectives
"models": [
{
"name": "cerebras-research",
"platform": "cerebras",
"model": "llama-3.3-70b"
},
{
"name": "mistral-research",
"platform": "mistral",
"model": "mistral-small-latest"
}
]
}______________________________________________________________________
🤝 受GSD启发
这个项目的灵感来自Paul Julius Martinez的 完成任务(GSD) 工作流程。
GSD问题:
- 🔥 GSD的生产力令人惊叹
- 💸 但它很快就会烧光克劳德代币
- 📊 复杂的项目可能会迅速耗尽每日限额
保存我的代币解决方案:
- ✅ 保持您喜欢的GSD工作流程
- ✅ 将繁重的任务卸载到免费的API
- ✅ 保存您的Claude代币用于编排和批判性思维
- ✅ 在相同的代币预算下,每天多10-20倍的工作流程
一起使用它们:
- 使用GSD进行项目编排
- 让GSD委托保存我的令牌以供执行
- 享受大规模扩展的Claude代码使用!
______________________________________________________________________
🎓 运作原理
智能委托模型
- 克劳德决定: 是否应该委派此任务?
- 保存我的令牌执行: 前往适当的免费API
- 实时进度: 看看发生了什么
- 克劳德评论: 最终抛光和整合
- 结果: 任务已完成,令牌已保存!
执行模式
并行模式 (研究、规划)
Claude delegates → Multiple free agents work simultaneously
→ Diverse perspectives returned
→ Claude synthesizes final answer
Token cost: 100 (orchestration) vs 2000 (doing it all)级联模式 (编码、审核)
Claude delegates → Try Agent 1 (Cerebras)
↓ (if fails)
→ Try Agent 2 (Mistral)
↓
✅ Success!
Token cost: 80 (orchestration) vs 2500 (doing it all)______________________________________________________________________
📝 文档
______________________________________________________________________
🙏 致谢
______________________________________________________________________
🤝 贡献
我们欢迎捐款!特别是:
- 新的免费提供商集成 -找到另一个免费的API?添加它!
- 任务模板 -代币节省的新用例
- 优化策略 -保存代币的更好方法
- 使用统计 -分享您的代币储蓄!
看 贡献.md
______________________________________________________________________
📄 许可证
MIT许可证-请参阅 许可证
______________________________________________________________________
💬 支持
入门指南:
- 安装指南
- 运行:
npx github:Dan-paull/save-my-tokens test - 检查:
npx github:Dan-paull/save-my-tokens status
有问题吗?
- 检查日志:
tail -f logs/mcp-server.log - 提出问题
______________________________________________________________________
🌟 明星这个Repo!
如果Save My Tokens保存了您的Claude代币,请给我们一颗星! ⭐
每一颗星星都激励我们添加更多的免费提供商,并节省更多的代币!
______________________________________________________________________
停止在免费LLM可以处理的任务上燃烧Claude令牌。把你的配额留到重要的事情上。 💰
开始使用→ |
