본문으로 건너뛰기
TakoAPI
스킬로 돌아가기

token-counter

mkhaytman87 제작

Coding Agents & IDEs
540clawskills.sh가 보고한 다운로드 수
2스타
1조회수
좋아요 0개로그인하면 이 스킬에 좋아요를 누를 수 있습니다
—아직 평가 없음
내 평가

요약

Track and analyze OpenClaw token usage across main, cron, and sub-agent sessions with category, client, model.

설명

이 스킬이 하는 일

Parses local OpenClaw session transcripts, metadata, and cron definitions to produce token usage reports. Breaks down consumption by category, client, model, and tool across main, cron, and sub-agent sessions. Supports per-session drilldowns, time-range filters, and JSON export.

Reads directly from local transcript files rather than requiring a dashboard or external service, so reports reflect actual recorded usage with no data leaving the machine.

사용 시점

  • Check where tokens went over the past week
  • Get a per-tool breakdown before optimizing a cron job
  • Export a 30-day usage snapshot for cost review
  • Drill into a single session to find a token spike
  • Save daily snapshots to track usage trends over time

예시 워크플로

입력

User asks: show me a breakdown of token usage by tool and category for the last 7 days

에이전트
  1. 1

    Run token-counter with --period 7d and --breakdown tools,category

  2. 2

    Parser reads session transcripts from $OPENCLAW_DATA_DIR/agents/main/sessions/*.jsonl

  3. 3

    Attribution logic splits assistant-message tokens across tool calls in each message

  4. 4

    Aggregates counts by tool name and session category

출력

Console report listing token totals per tool and per category for the 7-day window

설치

clawhub install mkhaytman87/token-counter

CLI 명령을 실행하거나, 프롬프트를 Claude Code, Cursor, Codex 등 사용하는 코딩 에이전트에 붙여넣으세요.

링크