← Back to Skills Marketplace
OpenClaw Token Usage
by
Lu Yanqiang
· GitHub ↗
· v1.2.0
· MIT-0
159
Downloads
0
Stars
0
Active Installs
3
Versions
Install in OpenClaw
/install openclaw-token-usage
Description
Inspect token usage from local OpenClaw transcripts across a specified time range. Use when the user asks how many tokens were consumed in OpenClaw, GitHub C...
Usage Guidance
This skill appears to do what it says: it reads OpenClaw transcript files from your home directory and summarizes token usage locally. Before running, confirm the transcript path (~/.openclaw/agents/...) is where you keep the data you want analyzed, and that you are comfortable running a third‑party Python script on those files. The script can write JSON/CSV/markdown to paths you supply—verify output paths to avoid overwriting important files. If you need extra assurance, inspect the remainder of the script (the truncated portion) yourself for any network calls or subprocess invocations; if no network calls are present, running it locally is low-risk. Also ensure your Python environment supports zoneinfo or pass a simple tz like UTC/UTC+8 as advised in SKILL.md.
Capability Analysis
Type: OpenClaw Skill
Name: openclaw-token-usage
Version: 1.2.0
The skill bundle provides a utility for aggregating and reporting token usage from local OpenClaw transcript files. The Python script (report_openclaw_token_usage.py) reads JSONL files from the ~/.openclaw/agents/ directory, calculates metrics like input/output tokens and cache usage, and generates reports in text, JSON, CSV, or Markdown formats. The code uses standard libraries, lacks network or suspicious execution capabilities, and the instructions in SKILL.md are strictly aligned with the stated purpose of usage monitoring.
Capability Assessment
Purpose & Capability
The name/description promise (inspect token usage from local OpenClaw transcripts) matches the bundled Python script which reads ~/.openclaw/agents/*/sessions/, parses transcript JSONL, aggregates token metrics, and emits summaries/CSV/JSON/markdown. There are no unrelated binaries, credentials, or config paths requested.
Instruction Scope
SKILL.md tells the agent to run the included script with time range, tz, and optional scope filters; the script implementation confines itself to reading transcript files under the user's OpenClaw directory and producing local outputs. There are no instructions to read unrelated system files, environment variables, or to send data to external endpoints.
Install Mechanism
No install spec is present (instruction-only with a bundled script). No remote downloads or archive extraction are used. Risk is limited to local execution of the provided Python script.
Credentials
The skill requests no environment variables or credentials. It accesses files only under the user's home OpenClaw paths (sessions and sessions.json), which is proportionate to its stated purpose.
Persistence & Privilege
The skill is not always-enabled and uses normal agent invocation. It does not request persistent system-wide privileges or modify other skills' configuration in the reviewed code.
How to Use
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install openclaw-token-usage - After installation, invoke the skill by name or use
/openclaw-token-usage - Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.2.0
Add markdown report output with auto-generated findings; keep JSON/CSV/session exports.
v1.1.0
Add Top N session ranking, session-level totals, and CSV directory export support.
v1.0.0
Initial release: transcript-based token usage reporting by time range, day, agent, and model.
Metadata
Frequently Asked Questions
What is OpenClaw Token Usage?
Inspect token usage from local OpenClaw transcripts across a specified time range. Use when the user asks how many tokens were consumed in OpenClaw, GitHub C... It is an AI Agent Skill for Claude Code / OpenClaw, with 159 downloads so far.
How do I install OpenClaw Token Usage?
Run "/install openclaw-token-usage" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is OpenClaw Token Usage free?
Yes, OpenClaw Token Usage is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does OpenClaw Token Usage support?
OpenClaw Token Usage is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created OpenClaw Token Usage?
It is built and maintained by Lu Yanqiang (@lujohn74); the current version is v1.2.0.
More Skills