← 返回 Skills 市场
Token Usage
作者
PanthroCorp
· GitHub ↗
· v0.2.2
· MIT-0
181
总下载
0
收藏
0
当前安装
3
版本数
在 OpenClaw 中安装
/install panthrocorp-token-usage
功能描述
Multi-agent token burn analysis across all registered OpenClaw agents
安全使用建议
This skill is coherent with its purpose: it reads OpenClaw agent session files (~/.openclaw/agents/*/sessions/sessions.json), produces aggregated reports, and appends one history line to ~/.openclaw/workspace/memory/token-usage-history.ndjson. It does not request credentials, install software, or send data externally. Before installing or allowing autonomous use, decide whether you are comfortable with the skill creating/appending the local history file (it will do so on every run). If you want to be cautious: (1) inspect the sessions.json files to confirm they don't contain unexpected sensitive data, (2) run the skill manually once rather than allowing autonomous invocation, or (3) disable autonomous invocation for the skill so it cannot run without your explicit request.
功能分析
Type: OpenClaw Skill
Name: panthrocorp-token-usage
Version: 0.2.2
The skill is a utility designed to analyze and report on token usage and costs across OpenClaw agents. It reads local session data from `~/.openclaw/agents/` and writes history/logs to the local workspace memory. The instructions in `SKILL.md` are focused entirely on data aggregation and reporting, with no evidence of network access, credential theft, or unauthorized execution.
能力评估
Purpose & Capability
The skill's name/description align with its actions: it enumerates ~/.openclaw/agents/, reads sessions/sessions.json, aggregates token and cost fields, and reports summaries. There are no unrelated required binaries, env vars, or installs.
Instruction Scope
Instructions are narrowly scoped to files under the user's OpenClaw home (~/.openclaw). The only non-reporting action is appending one JSON line to ~/.openclaw/workspace/memory/token-usage-history.ndjson (persistence described in Step 7). The SKILL.md explicitly states that the append runs every time the skill runs — this is expected for a history feature but worth noting.
Install Mechanism
Instruction-only skill with no install steps and no code files — minimal surface area and nothing new is written to disk beyond the declared history file append.
Credentials
The skill requests no environment variables, no credentials, and no external config paths beyond the OpenClaw workspace; required access is proportional to the stated task.
Persistence & Privilege
The skill persists a single NDJSON record to ~/.openclaw/workspace/memory/token-usage-history.ndjson on every run. always:false (not force-enabled) and no external network activity are good, but because model invocation is allowed by default, an autonomously-invoked run could write this history without a separate explicit user prompt.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install panthrocorp-token-usage - 安装完成后,直接呼叫该 Skill 的名称或使用
/panthrocorp-token-usage触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.2.2
**Adds persistent structured usage history and data export**
- Appends every run's analysis as a compact JSON line to `token-usage-history.ndjson` for historical tracking (runs automatically).
- Specifies new line-by-line schema: per-agent, per-category stats and combined totals, with explicit nulls where data is absent.
- Clarifies that logging to `token-diet-log.md` is still user-optional.
- Updates permissions to reflect new always-on write for the history file.
- Bumps version to 0.2.2.
v0.2.1
panthrocorp-token-usage 0.2.1
- Updated skill instructions and documentation with improved example values and formatting in SKILL.md.
- Clarified sample session keys and agent names to be more generic and representative.
- Made minor text and formatting updates to documentation for improved consistency.
v0.2.0
- Initial release of Token Usage analysis skill for OpenClaw agents.
- Analyzes and aggregates token usage and costs across all registered agents.
- Supports dynamic agent discovery, grouping by session category, time window filtering, and anomaly flagging.
- Presents per-agent breakdown tables with category-level stats and flags for high-cost and suspected wasted usage.
- Provides a combined total summary and top 3 categories by cost and token volume.
- Optionally writes a concise Markdown log report when requested.
元数据
常见问题
Token Usage 是什么?
Multi-agent token burn analysis across all registered OpenClaw agents. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 181 次。
如何安装 Token Usage?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install panthrocorp-token-usage」即可一键安装,无需额外配置。
Token Usage 是免费的吗?
是的,Token Usage 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Token Usage 支持哪些平台?
Token Usage 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(linux)。
谁开发了 Token Usage?
由 PanthroCorp(@panthrocorp)开发并维护,当前版本 v0.2.2。
推荐 Skills