重要前提
安装AI Skills的关键前提是:必须科学上网,且开启TUN模式,这一点至关重要,直接决定安装能否顺利完成,在此郑重提醒三遍:科学上网,科学上网,科学上网。查看完整安装教程 →
rtk-optimizer by florianbruniaux/claude-code-ultimate-guide
npx skills add https://github.com/florianbruniaux/claude-code-ultimate-guide --skill rtk-optimizer用途:自动为高冗长命令建议 RTK 封装器,以减少令牌消耗。
git log → rtk git log (减少 92.3%)git status → rtk git status (减少 76.0%)find → rtk find (减少 76.3%)广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
git diff → rtk git diff (减少 55.9%)cat <large-file> → rtk read <file> (减少 62.5%)pnpm list → rtk pnpm list (减少 82%)pnpm test / vitest run → rtk vitest run (减少 90%)cargo test → rtk cargo test (减少 90%)cargo build → rtk cargo build (减少 80%)cargo clippy → rtk cargo clippy (减少 80%)pytest → rtk python pytest (减少 90%)go test → rtk go test (减少 90%)gh pr view → rtk gh pr view (减少 87%)gh pr checks → rtk gh pr checks (减少 79%)ls → rtk ls (压缩输出)grep → rtk grep (过滤输出)用户:"显示 git 历史记录" 技能:检测到 git log → 建议 rtk git log → 解释节省 92.3% 令牌
用户:"查找所有 markdown 文件" 技能:检测到 find → 建议 rtk find "*.md" . → 解释节省 76.3%
首次使用前,请验证 RTK 是否已安装:
rtk --version # 应输出:rtk 0.16.0+
如果未安装:
# Homebrew (macOS/Linux)
brew install rtk-ai/tap/rtk
# Cargo (所有平台)
cargo install rtk
# 当用户请求高冗长命令时:
1. 确认请求
2. 建议 RTK 优化:
"我将使用 `rtk git log` 来减少约 92% 的令牌使用量"
3. 执行 RTK 命令
4. 跟踪节省量(可选):
"节省了约 13K 令牌(基线:14K,RTK:1K)"
可选:跟踪会话期间的累计节省量:
# 在会话结束时
rtk gain # 显示会话期间的总令牌节省量(基于 SQLite)
通过 CLAUDE.md 启用:
## 令牌优化
对高冗长命令使用 RTK (Rust Token Killer):
- git 操作 (log, status, diff)
- 包管理器 (pnpm, npm)
- 构建工具 (cargo, go)
- 测试框架 (vitest, pytest)
- 文件查找和读取
基于实际测试:
git log: 13,994 字符 → 1,076 字符 (减少 92.3%)git status: 100 字符 → 24 字符 (减少 76.0%)find: 780 字符 → 185 字符 (减少 76.3%)git diff: 15,815 字符 → 6,982 字符 (减少 55.9%)read file: 163,587 字符 → 61,339 字符 (减少 62.5%)平均:减少 72.6% 令牌
对以下情况使用 RTK:git 工作流、文件操作、测试框架、构建工具、包管理器 对以下情况跳过 RTK:小输出、快速探索、交互式命令
docs/resource-evaluations/rtk-evaluation.mdexamples/claude-md/rtk-optimized.md每周安装数
57
仓库
GitHub 星标数
2.3K
首次出现
2026年3月1日
安全审计
安装于
opencode52
gemini-cli52
github-copilot52
amp51
codex51
kimi-cli51
Purpose : Automatically suggest RTK wrappers for high-verbosity commands to reduce token consumption.
git log → rtk git log (92.3% reduction)git status → rtk git status (76.0% reduction)find → rtk find (76.3% reduction)git diff → rtk git diff (55.9% reduction)cat <large-file> → rtk read <file> (62.5% reduction)pnpm list → rtk pnpm list (82% reduction)pnpm test / vitest run → rtk vitest run (90% reduction)cargo test → rtk cargo test (90% reduction)cargo build → rtk cargo build (80% reduction)cargo clippy → rtk cargo clippy (80% reduction)pytest → rtk python pytest (90% reduction)go test → rtk go test (90% reduction)gh pr view → rtk gh pr view (87% reduction)gh pr checks → rtk gh pr checks (79% reduction)ls → rtk ls (condensed output)grep → rtk grep (filtered output)User : "Show me the git history" Skill : Detects git log → Suggests rtk git log → Explains 92.3% token savings
User : "Find all markdown files" Skill : Detects find → Suggests rtk find "*.md" . → Explains 76.3% savings
Before first use, verify RTK is installed:
rtk --version # Should output: rtk 0.16.0+
If not installed:
# Homebrew (macOS/Linux)
brew install rtk-ai/tap/rtk
# Cargo (all platforms)
cargo install rtk
# When user requests high-verbosity command:
1. Acknowledge request
2. Suggest RTK optimization:
"I'll use `rtk git log` to reduce token usage by ~92%"
3. Execute RTK command
4. Track savings (optional):
"Saved ~13K tokens (baseline: 14K, RTK: 1K)"
Optional: Track cumulative savings across session:
# At session end
rtk gain # Shows total token savings for session (SQLite-backed)
Enable via CLAUDE.md:
## Token Optimization
Use RTK (Rust Token Killer) for high-verbosity commands:
- git operations (log, status, diff)
- package managers (pnpm, npm)
- build tools (cargo, go)
- test frameworks (vitest, pytest)
- file finding and reading
Based on real-world testing:
git log: 13,994 chars → 1,076 chars (92.3% reduction)git status: 100 chars → 24 chars (76.0% reduction)find: 780 chars → 185 chars (76.3% reduction)git diff: 15,815 chars → 6,982 chars (55.9% reduction)read file: 163,587 chars → 61,339 chars (62.5% reduction)Average: 72.6% token reduction
Use RTK for : git workflows, file operations, test frameworks, build tools, package managers Skip RTK for : small outputs, quick exploration, interactive commands
docs/resource-evaluations/rtk-evaluation.mdexamples/claude-md/rtk-optimized.mdWeekly Installs
57
Repository
GitHub Stars
2.3K
First Seen
Mar 1, 2026
Security Audits
Gen Agent Trust HubWarnSocketPassSnykPass
Installed on
opencode52
gemini-cli52
github-copilot52
amp51
codex51
kimi-cli51
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
125,600 周安装
CocoIndex:AI实时数据转换与向量索引构建框架,支持增量处理与多数据库
207 周安装
TDD 工作流指南:红绿重构循环、三定律与实践原则 | 测试驱动开发
207 周安装
Python asyncio 异步编程教程:async/await 并发、事件循环、任务管理与实战应用
207 周安装
Nansen CLI:分析Polymarket交易员活动与盈亏的区块链工具
210 周安装
Rust 云原生开发指南:领域约束、设计模式与关键 Crate 实践
219 周安装
fp-ts错误处理实战:TypeScript类型安全的Either与TaskEither模式
53 周安装