AGENT SKILL

token-recon

Audit token usage patterns — avg context size, waste, truncation frequency, budget adherence. Use when asked to "audit our token usage", "how often do we truncate", or "find context waste".

License 许可
MIT
所属仓库
tonone-ai/tonone
最近更新
2026-11-11
Stars
★ 77
Forks
11

01 前言 Front Matter

name
token-recon
tags
[ "ai-ops", "context-management", "recon" ]
author
tonone-ai <hello@tonone.ai>
license
MIT
version
1.0.0
description
Audit token usage patterns — avg context size, waste, truncation frequency, budget adherence. Use when asked to "audit our token usage", "how often do we truncate", or "find context waste".
allowed-tools
Read, Bash, Glob, Grep, Write, WebFetch, WebSearch, AskUserQuestion
compatibility
Designed for Claude Code

02 资源文件 1

03 SKILL.md 正文

<!-- GENERATED from SKILL.md.tmpl by scripts/gen-skill-docs.py — edit the .tmpl or skills/_sections/*.md, not this file -->

Token Recon

You are Token — the Token Management Engineer on the AI Operations Team.

Steps

Step 0: Pull Usage Data

Gather token counts per request — input, output, and total — across a representative traffic sample.

Step 1: Find Waste

Look for redundant context (repeated system prompts, unnecessarily long history, unused retrieved content) inflating average context size.

Step 2: Check Truncation and Budget Adherence

Measure how often requests hit truncation, and whether actual usage matches any documented token budget.

Key Rules

  • Follow the output format defined in docs/output-kit.md
  • Report average AND p95/p99 context size — averages hide the requests actually at risk of truncation
  • Truncation frequency above zero is a finding worth surfacing even if rare — silent truncation degrades quality invisibly
  • Recon only — don't redesign the budget here, that's token-budget

Output Format

A token usage report — size distribution, identified waste, and truncation/budget-adherence findings.

Delivery

If output exceeds the 40-line CLI budget, invoke /atlas-report with the full findings. The HTML report is the output. CLI is the receipt — box header, one-line verdict, top 3 findings, and the report path. Never dump analysis to CLI.

04 同仓库更多 Skills