token-audit

token-audit is a skill for Claude Code, Codex from ils15/pantheon-legacy. It costs 22 tokens per session (1,278 once invoked), scanned A, original, MIT.

A repository check for files that give coding agents instructions or background context. It measures repeated information and identifies places where that context can be shortened.

In plain words
What is it for?
Use it to find duplicated instructions across agent files, memory notes, skills, and project documentation.
Why use it?
It helps reduce unnecessary text that agents must read, leaving more context for the actual task.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: reads .claude/ paths; mentions CLAUDE.md; mentions AGENTS.md.

Good fit Use it to find duplicated instructions across agent files, memory notes, skills, and project documentation.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ils15/pantheon-legacy/token-audit
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ils15/pantheon-legacy --skill token-audit
Clone the repo
git clone --depth 1 https://github.com/ils15/pantheon-legacy

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for token-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/ils15/pantheon-legacy/token-audit/github.svg)](https://agentmods.dev/skills/ils15/pantheon-legacy/token-audit)
Your own site
<a href="https://agentmods.dev/skills/ils15/pantheon-legacy/token-audit"><img src="https://agentmods.dev/badge/skills/ils15/pantheon-legacy/token-audit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for token-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/ils15/pantheon-legacy/token-audit"><img src="https://agentmods.dev/badge/skills/ils15/pantheon-legacy/token-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,278 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 2 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Agent Snooping · line 63
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • medium Agent Snooping · line 63
    Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
    Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.01278
Opus 5 $0.00011 $0.00639
Sonnet 5 $0.00004 $0.00256
Haiku 4.5 $0.00002 $0.00128

Measured 8d ago against content hash 1d36efffd3af, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

token-audit scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Enumerates other installed skillslowAgent snooping

Other skills' SKILL.md files reveal prompts, capabilities and secrets that should be invisible to peers.

find .github/skills .claude/skills .opencode/skills -name "SKILL.md" 2>/dev/null | xargs wc -l 2>/dev/null

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

skills/token-audit/SKILL.md · 148 lines

How it starts

The opening of the file, as written. The whole thing — 148 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Token Audit — Repository Context Optimization

Purpose

When Pantheon is installed in a new repository, run this skill to audit and optimize all AI context files for token efficiency.

Step 1: Discover Context Files

Scan the repository for ALL files that contribute to AI context:

# Auto-loaded files (every invocation)
AGENTS.md
CLAUDE.md
.gemini/AGENTS.md
.github/copilot-instructions.md
.github/instructions/*.md
.claude/CLAUDE.md
.cursor/rules/*.mdc
.windsurfrules
.kilocode/rules/*.md
.clinerules
.opencode/agents/*.agent.md

# Memory bank
docs/memory-bank/*.md
docs/adr/*.md

# Skills (lazy-load)
.github/skills/*/SKILL.md
.claude/skills/*/SKILL.md
.opencode/skills/*/SKILL.md

Step 2: Build Redundancy Map

Read all discovered files and map what information appears where:

Information Found in files Lines duplicated
Tech stack AGENTS.md, 00-overview.md, copilot-instructions.md ~15
Run commands AGENTS.md, 03-tech-context.md, commands.md ~10
Agent roles AGENTS.md, copilot-instructions.md, zeus.agent.md ~20
CI/CD rules AGENTS.md, copilot-instructions.md, .github/workflows ~12
Coding standards copilot-instructions.md, instructions/*.md ~25

Step 3: Measure Baseline

Count lines and estimate tokens:

# Auto-loaded context (every invocation)
wc -l AGENTS.md .github/copilot-instructions.md /memories/repo/*.md 2>/dev/null

# On-demand context (read by agents)
wc -l docs/memory-bank/*.md 2>/dev/null

# Skills (lazy-load)
find .github/skills .claude/skills .opencode/skills -name "SKILL.md" 2>/dev/null | xargs wc -l 2>/dev/null

# Agent definitions
wc -l .github/agents/*.agent.md .opencode/agents/*.agent.md .claude/agents/*.agent.md 2>/dev/null

Estimate: 1 line ≈ 4 tokens (markdown average)

Step 4: Identify Red Flags

Check for content that should NOT be auto-loaded. Use specific patterns, not generic keywords:

  • Wave delivery tables: Wave 1:, Wave 2:, ## Wave, wave-by-wave (NOT "DAG Waves" pattern)
  • Delivery history: delivered:, what was delivered, delivery history, delivery log
  • Progress metrics: [0-9]+% complete, commit count, commits: [0-9] (NOT in progress-log.md)
  • Last-updated dates: **Last Updated**:, <!-- last.updated: (git has this)
  • Cleanup logs: deleted X lines of dead code, legacy cleanup, cleaned up X
  • Duplicated tech stack: same phrase in >3 files (use long phrases, not single words)
  • Files exceeding line limits: AGENTS.md >80, memory-bank >100
  • Empty or near-empty files that waste discovery overhead

Read the full file on GitHub · 148 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 148 lines · 22 tokens per session scan A 1d36efffd3af

Subscribe to this mod's changes

token-audit is a skill published in the GitHub repository ils15/pantheon-legacy (10 stars, last pushed 8d ago), licensed MIT. It adds 22 tokens to every session and 1,278 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (enumerates other installed skills). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

media-ingest

Ingest video, audio, PDF, book, screenshot, and GitHub repo content into the brain. Multi-format handling with entity extraction and backlink propagation. Covers video-ingest, youtube-ingest, and book-ingest subtypes.

garrytan/gbrain · 52 tokens

mem0-oss-to-platform

Plan and then execute a migration of a project from the mem0 open-source / self-hosted SDK (the local Memory class) to the mem0 Platform / hosted / managed SDK (the MemoryClient class). Use this whenever a developer wants to move, switch, or migrate their mem0 usage off OSS/self-hosted to the hosted API — e.g.…

mem0ai/mem0 · 273 tokens

Cortex

Operate Cortex, the LifeOS memory system — the typed Knowledge Archive (People, Companies, Ideas, Research with typed related: links) plus recall of prior work sessions, ISAs, and conversations. Search, add, harvest, develop, ingest, distill, graph-navigate, recall. USE WHEN cortex, knowledge, knowledge base, search…

danielmiessler/LifeOS · 196 tokens

memory

Use when the user asks to remember, recall, forget, update, search, or inspect durable OpenSquilla memory, including profile facts in USER.md and long-term notes in MEMORY.md or memory//.md.

opensquilla/opensquilla · 44 tokens

ha-data-stores

Map of Hope Agent's local data stores and safe read-only query workflow. Use when the user asks where Hope Agent stores data, wants to inspect sessions/messages/memory/logs/background jobs/knowledge indexes/settings, asks the model to query local app data, or debugging requires checking persisted state. Trigger…

shiwenwen/hope-agent · 115 tokens

establishing-project-context

Use when the user asks to establish shared project language, or project work exposes a conflicting, renamed, or deprecated domain term that needs active semantic modeling. Routine small tasks stay on the fast path.

GanyuanRan/Aegis · 45 tokens