← 返回 Skills 市场
e2e5g

Token省钱管家

作者 e2e5g · GitHub ↗ · v2.2.0 · MIT-0
cross-platform ✓ 安全检测通过
127
总下载
0
收藏
0
当前安装
3
版本数
在 OpenClaw 中安装
/install token-cost-controller
功能描述
OpenClaw Token省钱管家 - 智能缓存、动态路由、实时监控,运行时自动优化,降低70%成本消耗。当用户询问成本优化、Token节省、缓存策略、模型路由或需要成本监控时使用。
安全使用建议
This skill appears to be what it says: a local cost controller that stores state under .openclaw/data and detects local models with 'ollama list'. Before installing, consider: 1) Provenance — the package is from an unknown source and contains version metadata mismatch (files v2.1.1 vs registry v2.2.0); prefer packages from trusted authors. 2) Inspect repository locally — review install.js and the data files (controls.json, cache.json, cost-history.json) to ensure no unexpected behavior. 3) Data sensitivity — the skill will store usage/cost data and disabled/paused skill lists on disk; if that information is sensitive, run it in an isolated environment or change the dataDir. 4) Execution risk — it runs a fixed shell command to probe local models; this is expected but confirm your environment's PATH and that 'ollama' is trusted. 5) Network/credentials — the skill requests no credentials and makes no outbound network calls in the provided code, but if you modify it to integrate external alerting or telemetry, review that addition carefully. If you want higher assurance, run it in a sandbox or container and/or ask the author for a vetted release/source origin.
功能分析
Type: OpenClaw Skill Name: token-cost-controller Version: 2.2.0 The skill bundle provides legitimate token cost management, caching, and model routing functionality for the OpenClaw agent. It implements statistical anomaly detection and local state management within a dedicated data directory. While it utilizes 'child_process.exec' in 'lib/model-router.js' to check for local 'ollama' availability, the command is hardcoded and does not incorporate unsanitized user input, posing no significant injection risk. No evidence of data exfiltration, malicious prompt injection, or unauthorized persistence was found.
能力评估
Purpose & Capability
Name/description (token cost control, caching, routing, monitoring) match the included code and CLI. The package implements caching, cost monitoring, model routing, and proactive controls. Minor metadata/version mismatch: registry lists v2.2.0 while files declare v2.1.1 — a non-security but provenance inconsistency to note.
Instruction Scope
SKILL.md only instructs when to use the skill (cost optimization) and basic CLI examples; it does not ask the agent to read unrelated system state or secrets. However the README suggests running install.js and the code persists data to disk (controls.json, cache.json, cost-history.json). '自动告警' in docs refers to internal alerts stored in files, not an external alerting service — a minor documentation vs behavior mismatch.
Install Mechanism
There is no external install spec in the registry. The repository includes a local install.js that creates a .openclaw/data directory and initializes controls.json. No remote downloads, no package dependencies, and no archives or third-party installers are used.
Credentials
The skill requests no environment variables or credentials. It does execute a fixed shell command ('ollama list ...') to detect local models (via child_process.exec), which is expected for its local-model-detection feature. The command is hard-coded and not built from untrusted input, so this is proportionate to its purpose. Note: the skill writes usage/cost data and control state to local files which may contain sensitive consumption information.
Persistence & Privilege
always:false and user-invocable:true. The skill persists only to its own directory (.openclaw/data) and does not modify other skills or global agent configurations. Its level of persistence is proportional to its monitoring/control purpose.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install token-cost-controller
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /token-cost-controller 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v2.2.0
**token-cost-controller v2.2.0** Major update with significant internal refactoring and streamlined features. - Simplified core codebase: removed budget manager, context compressor, and token optimizer modules. - Merged functionality and improved structure under main files and a new `lib/index.js` entry. - Updated documentation to reflect a leaner skill version, focusing on intelligent caching, dynamic routing, and cost monitoring. - Improved maintainability by cleaning up legacy test scripts and redundant modules. - Configuration and CLI remain compatible with prior usage; advanced optimization and compression now handled externally or by other modules.
v2.1.1
token-cost-controller v2.1.1 - 修改描述文案,将「Token成本控制管家」优化为「Token省钱管家」以增强易懂性和亲和力。 - 统一文档内名称与标识,从「Token成本控制管家」更新为「Token省钱管家」。 - 其余内容未做调整,功能无变动,仅文本与品牌表述优化。
v2.1.0
v2.1.0: 异步CLI调用、Ring Buffer固定内存、安全缓存Key、动态异常检测、性能全面优化
元数据
Slug token-cost-controller
版本 2.2.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 3
常见问题

Token省钱管家 是什么?

OpenClaw Token省钱管家 - 智能缓存、动态路由、实时监控,运行时自动优化,降低70%成本消耗。当用户询问成本优化、Token节省、缓存策略、模型路由或需要成本监控时使用。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 127 次。

如何安装 Token省钱管家?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install token-cost-controller」即可一键安装,无需额外配置。

Token省钱管家 是免费的吗?

是的,Token省钱管家 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Token省钱管家 支持哪些平台?

Token省钱管家 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Token省钱管家?

由 e2e5g(@e2e5g)开发并维护,当前版本 v2.2.0。

💬 留言讨论