Search

PythonReactSEOPDF
OpenClaw

skill-cost

Track per-skill token usage and costs from OpenClaw session logs. Use when user asks about skill-level spending, which skill costs the most, or wants a per-skill cost breakdown. IMPORTANT: This is a bash-tool skill. You MUST use the bash/shell tool to execute commands.

dzwalker0 source installs☆ 0 Repository starsv0.1.0

Installation

Follow the repository instructions for this skill and your agent. Review the files and dependencies before adding it to your workflow.

SkillHub CLI

skillhub install dzwalker/skill-cost

Inspect the source and compatibility requirements, then follow its installation steps.

Give your agent the source link and ask it to inspect instructions and dependencies before explaining the installation steps.

View source ↗Guides

Skill instructions

Skill Cost — USE BASH TOOL

You MUST use the bash or shell tool to run these commands. No other method works.

Commands

Per-skill cost report:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report

Last 7 days:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --days 7

Since a specific date:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --since 2026-03-01

JSON output:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --format json

Top skills by cost:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh ranking

Detail for a specific skill:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh detail poe-connector

Compare two skills:

bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh compare poe-connector web-search

DO NOT

  • Do NOT use sessions_spawn — it will fail
  • Do NOT use browser — it will fail
  • Do NOT use any approach other than bash tool — only bash works

How It Works

  1. Scans OpenClaw session JSONL files at ~/.openclaw/agents/*/sessions/
  2. Parses assistant messages for tool calls and token usage
  3. Attributes token usage to skills by matching bash command paths and tool names
  4. Aggregates and reports per-skill costs with model and daily breakdowns

Notes

  • No API keys required — reads directly from local session files
  • No external Python dependencies (stdlib only)
  • Skill attribution uses bash command paths and SKILL.md tool mappings
  • Tokens for multi-skill messages are proportionally split across skills
  • Usage not attributable to any skill is categorized as (built-in) or (conversation)

Source information

Source
github
Repository
openclaw/skills
Path
skills/dzwalker/skill-cost
Version
0.1.0
Commit
5bcd0b97444eb0cea9245f4ebcd8c4b8b558d8a7
Classification source
rules
Status
active
Visibility
public

These signals come from indexed source analysis and may lag behind changes. Check the current source files.

README

skill-cost

Which of my OpenClaw skills is burning the most money?

I've been running OpenClaw with a growing collection of skills — chat connectors, code generators, grid monitors, you name it. The monthly bill kept climbing and I had no idea which skill was the culprit. The existing cost trackers on ClawHub (session-cost, openclaw-cost-tracker, tokenmeter) all break down spending by model, but none of them answer the question I actually care about:

"Is it my poe-connector or my web-search that's eating all my tokens?"

So I built skill-cost — a dead-simple, zero-dependency tool that reads your local OpenClaw session logs and tells you exactly how much each skill is costing you.

What It Does

────────────────────────────────────────────────────────────
Skill                      Calls     Tokens       Cost     %
────────────────────────────────────────────────────────────
(conversation)               420       6.2M     $14.20   45%
web-search                   180       2.8M      $5.60   18%
poe-connector                95       1.5M      $4.20   13%
github-tools                 72       1.1M      $3.30   10%
(built-in)                    48     780.0K      $2.10    7%
code-runner                  32     520.0K      $1.56    5%
file-utils                   18     290.0K      $0.87    3%
────────────────────────────────────────────────────────────
Total                        857      13.2M     $31.83  100%

Now I know: web-search and poe-connector are my money pits. Time to optimize (or at least stop blaming the small ones).

Install

# If you're using ClawHub:
clawhub install dzwalker/skill-cost

# Or manually:
git clone https://github.com/dzwalker/skill-cost.git ~/.openclaw/workspace/skills/skill-cost

No pip install needed — pure Python stdlib, zero external dependencies.

Usage

All commands go through the wrapper script:

# Full per-skill cost report
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost....

Extracted content

SKILL.md
# Skill Cost — USE BASH TOOL

**You MUST use the `bash` or `shell` tool to run these commands. No other method works.**

## Commands

Per-skill cost report:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report
```

Last 7 days:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --days 7
```

Since a specific date:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --since 2026-03-01
```

JSON output:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh report --format json
```

Top skills by cost:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh ranking
```

Detail for a specific skill:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh detail poe-connector
```

Compare two skills:
```bash
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost.sh compare poe-connector web-search
```

## DO NOT

- Do NOT use `sessions_spawn` — it will fail
- Do NOT use browser — it will fail
- Do NOT use any approach other than `bash` tool — only bash works

## How It Works

1. Scans OpenClaw session JSONL files at `~/.openclaw/agents/*/sessions/`
2. Parses assistant messages for tool calls and token usage
3. Attributes token usage to skills by matching bash command paths and tool names
4. Aggregates and reports per-skill costs with model and daily breakdowns

## Notes

- No API keys required — reads directly from local session files
- No external Python dependencies (stdlib only)
- Skill attribution uses bash command paths and SKILL.md tool mappings
- Tokens for multi-skill messages are proportionally split across skills
- Usage not attributable to any skill is categorized as (built-in) or (conversation)
README
# skill-cost

**Which of my OpenClaw skills is burning the most money?**

I've been running OpenClaw with a growing collection of skills — chat connectors, code generators, grid monitors, you name it. The monthly bill kept climbing and I had no idea which skill was the culprit. The existing cost trackers on ClawHub (session-cost, openclaw-cost-tracker, tokenmeter) all break down spending by *model*, but none of them answer the question I actually care about:

> *"Is it my poe-connector or my web-search that's eating all my tokens?"*

So I built **skill-cost** — a dead-simple, zero-dependency tool that reads your local OpenClaw session logs and tells you exactly how much each skill is costing you.

## What It Does

```
────────────────────────────────────────────────────────────
Skill                      Calls     Tokens       Cost     %
────────────────────────────────────────────────────────────
(conversation)               420       6.2M     $14.20   45%
web-search                   180       2.8M      $5.60   18%
poe-connector                95       1.5M      $4.20   13%
github-tools                 72       1.1M      $3.30   10%
(built-in)                    48     780.0K      $2.10    7%
code-runner                  32     520.0K      $1.56    5%
file-utils                   18     290.0K      $0.87    3%
────────────────────────────────────────────────────────────
Total                        857      13.2M     $31.83  100%
```

Now I know: web-search and poe-connector are my money pits. Time to optimize (or at least stop blaming the small ones).

## Install

```bash
# If you're using ClawHub:
clawhub install dzwalker/skill-cost

# Or manually:
git clone https://github.com/dzwalker/skill-cost.git ~/.openclaw/workspace/skills/skill-cost
```

No pip install needed — pure Python stdlib, zero external dependencies.

## Usage

All commands go through the wrapper script:

```bash
# Full per-skill cost report
bash ~/.openclaw/workspace/skills/skill-cost/skill-cost....

Related skills

OpenClaw

bambu-studio-ai

heyixuan2

Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pi...

OpenClaw

geo-optimization

capt-marbles

Generative Engine Optimization (GEO) for AI search visibility. Optimize content to appear in ChatGPT, Perplexity, Claude, and Google AI Overviews. Use when optimizing websites, pages, or content for LLM discove...

OpenClaw

0protocol

0isone

Agents can sign plugins, rotate credentials without losing identity, and publicly attest to behavior.