AI Skill Hub 强烈推荐:Tokenless优化工具 是一款优质的AI工具。AI 综合评分 8.5 分,在同类工具中表现稳健。如果你正在寻找可靠的AI工具解决方案,这是一个值得深入了解的选择。
Tokenless优化工具 是一款基于 Rust 开发的开源工具,专注于 LLM、token、优化 等核心功能。作为 GitHub 开源项目,它拥有活跃的社区支持和持续的版本迭代,代码完全透明可审计,支持本地部署以保护数据隐私。无论是个人使用还是集成到企业工作流,都能提供稳定可靠的解决方案。
Tokenless优化工具 是一款基于 Rust 开发的开源工具,专注于 LLM、token、优化 等核心功能。作为 GitHub 开源项目,它拥有活跃的社区支持和持续的版本迭代,代码完全透明可审计,支持本地部署以保护数据隐私。无论是个人使用还是集成到企业工作流,都能提供稳定可靠的解决方案。
# 方式一:cargo install(推荐) cargo install tokenless # 方式二:从源码编译 git clone https://github.com/TokenFleet-AI/tokenless cd tokenless cargo build --release # 二进制在 ./target/release/tokenless
# 查看帮助 tokenless --help # 基本运行 tokenless [options] <input> # 详细使用说明请查阅文档 # https://github.com/TokenFleet-AI/tokenless
# tokenless 配置说明 # 查看配置选项 tokenless --config-example > config.yml # 常见配置项 # output_dir: ./output # log_level: info # workers: 4 # 环境变量(覆盖配置文件) export TOKENLESS_CONFIG="/path/to/config.yml"
cargo install or source buildcargo install rtk). Core compression works without it.git clone https://github.com/TokenFleet-AI/tokenless && cd tokenless && make setup
| Target | Description |
|---|---|
make build | Build tokenless (release mode) |
make test | Run all tests |
make lint | Run fmt + clippy + cargo-audit |
make fmt | Format code |
make clean | Clean build artifacts |
```bash
tokenless demo # Run all 4 compression demos with embedded test data
```
```
tokenless env-check --tool Shell # Check specific tool
tokenless env-check --all # Check all tools
tokenless env-check --tool Shell --fix # Auto-fix missing deps
tokenless init
tokenless init # Project-level: hooks + --project tag for per-project stats
tokenless init --global # Global: hooks for all projects, auto-detect project at runtime
tokenless init --agent cursor # Install for Cursor editor
Auto-installs hooks into .claude/settings.json (or the equivalent for other agents). Once installed, all shell commands are automatically rewritten and responses compressed — zero manual steps after init.
Project-level vs Global:
| Mode | Command | --project in hooks | Stats behavior |
|---|---|---|---|
| Project-level | tokenless init | ✅ Written (detected from dir) | Stats attributed to this project only |
| Global | tokenless init --global | ❌ Omitted | Auto-detects project per invocation |
Use project-level init when you want per-project statistics isolation (e.g., tokenless stats summary shows only this project's savings). Use global init for a fire-and-forget setup across all repositories.
See user guide §4 for all 12 agents and manual configuration.
tokenless: command not found — Ensure ~/.local/bin/ is on your PATH (see Quick Start).tokenless stats experimental-on first.tokenless init and restart your agent.tokenless stats enable.tokenless 是一个专为提升 AI Agent 效率而设计的工具,旨在通过高效的压缩技术优化 Token 使用。本项目基于 Rust 开发,能够显著降低与 Claude、Cursor 等 AI 工具交互时的 Token 消耗,帮助开发者在保持上下文语义完整性的同时,实现更低成本、更高性能的 AI 自动化工作流。
在使用 tokenless 之前,请确保您的开发环境已安装 Rust toolchain(版本需 >= 1.89,支持 Rust 2024 edition),以便通过 `cargo install` 或源码进行构建。此外,若需要使用命令重写功能,建议安装 RTK binary(可通过 `cargo install rtk` 完成);若仅需核心压缩功能,则无需 RTK。
您可以通过克隆仓库并使用 Makefile 进行快速安装。首先执行 `git clone https://github.com/TokenFleet-AI/tokenless && cd tokenless && make setup` 完成环境初始化。构建时,可以使用 `make build` 生成 Release 模式的可执行文件,使用 `make test` 运行测试,或通过 `make lint` 进行代码规范检查(包含 fmt、clippy 和 cargo-audit)。
tokenless 提供命令行界面(CLI)供开发者调用。您可以直接通过命令行工具执行压缩或解压操作。对于初学者,建议参考 Quick Start 指南,了解如何通过 CLI 进行基础的命令交互,并确保已将生成的二进制文件路径添加到系统的 PATH 环境变量中,以便随时调用。
tokenless 支持通过环境变量进行精细化配置。例如,您可以通过设置 `TOKENLESS_DIFF_THRESHOLD` 来调整差异阈值(默认值为 0.7)。此外,内置的 `env-check` 命令可以帮助您检查工具链状态,支持针对特定工具(如 Shell)进行环境检测,并能通过 `--fix` 参数自动修复缺失的依赖项。
tokenless 支持一键集成到主流 AI Agent 中,如 Claude Code、Cursor 和 Windsurf。通过运行 `tokenless init`,您可以实现项目级(带 `--project` 标签以区分统计数据)或全局级的 Hooks 注入。针对 Cursor 编辑器,使用 `tokenless init --agent cursor` 可自动将 Hooks 安装至 `.claude/settings.json` 或同等配置文件中。
在使用过程中,若遇到 `tokenless: command not found` 错误,请检查 `~/.local/bin/` 是否已加入 PATH;若 TUI 或 MCP 提示“experimental feature”错误,请先运行 `tokenless stats experimental-on` 开启实验性功能。如果 Hooks 未生效,请重新运行 `tokenless init` 并重启您的 Agent。若统计数据为空,请确保已正确配置数据采集。
高效的LLM代币成本优化工具
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ Apache 2.0 — 宽松开源协议,可商用,需保留版权声明和 NOTICE 文件,含专利授权条款。
总体来看,Tokenless优化工具 是一款质量优秀的AI工具,在同类工具中具备一定竞争力。AI Skill Hub 将持续追踪其更新动态,建议收藏备用,结合自身场景选择合适时机引入使用。
| 原始名称 | tokenless |
| 原始描述 | 开源AI工具:LLM token optimization toolkit — slash token costs by 60-90% with schema/respons。⭐8 · Rust |
| Topics | LLMtoken优化 |
| GitHub | https://github.com/TokenFleet-AI/tokenless |
| License | Apache-2.0 |
| 语言 | Rust |
收录时间:2026-06-24 · 更新时间:2026-06-26 · License:Apache-2.0 · AI Skill Hub 不对第三方内容的准确性作法律背书。