token-optimization

token-optimization is a skill for Claude Code from claude-dev-suite/claude-dev-suite. It costs 110 tokens per session (1,623 once invoked), scanned A, original, MIT.

Guidance for reducing the amount of text and data exchanged with tool servers and coding agents. It covers loading information only when needed, requesting small results, and reusing available context.

In plain words
What is it for?
Use it when designing agent workflows, choosing tool parameters, or reviewing interactions for unnecessary output.
Why use it?
It helps avoid unnecessary processing, slower tool calls, and wasted context when working with external tools.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Good fit Use it when designing agent workflows, choosing tool parameters, or reviewing interactions for unnecessary output.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/claude-dev-suite/claude-dev-suite/token-optimization
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 claude-dev-suite/claude-dev-suite --skill token-optimization
Clone the repo
git clone --depth 1 https://github.com/claude-dev-suite/claude-dev-suite

Made for: Claude Code.

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-optimization

README.md
[![agentmods](https://agentmods.dev/badge/skills/claude-dev-suite/claude-dev-suite/token-optimization/github.svg)](https://agentmods.dev/skills/claude-dev-suite/claude-dev-suite/token-optimization)
Your own site
<a href="https://agentmods.dev/skills/claude-dev-suite/claude-dev-suite/token-optimization"><img src="https://agentmods.dev/badge/skills/claude-dev-suite/claude-dev-suite/token-optimization/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-optimization

Your own site · 80×15
<a href="https://agentmods.dev/skills/claude-dev-suite/claude-dev-suite/token-optimization"><img src="https://agentmods.dev/badge/skills/claude-dev-suite/claude-dev-suite/token-optimization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 110 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,623 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
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.00110 $0.01623
Opus 5.5 $0.00044 $0.00649
Sonnet 5.5 $0.00022 $0.00325
Haiku 4.5 $0.00011 $0.00162

Measured 1mo ago against content hash 0694e339f89d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

token-optimization scanned grade A with 0 findings 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 1mo 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/best-practices/token-optimization/SKILL.md · 213 lines

How it starts

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

Token Optimization Best Practices

Deep Knowledge: Use mcp__documentation__fetch_docs with technology: token-optimization for comprehensive documentation.

Guidelines for minimizing token consumption in MCP server and external tool interactions.

When NOT to Use This Skill

This skill focuses on API/tool call optimization. Do NOT use for:

  • Runtime performance - Use performance skill for speed optimization
  • Code minification - Use build tools (Vite, Webpack, etc.)
  • Database query optimization - Use database-specific skills
  • Algorithm efficiency - Use computer science fundamentals
  • Prompt engineering - This is about tool usage, not prompt design

General Principles

Principle Description
Lazy Loading Load information only when strictly necessary
Minimal Output Request only needed data, use limit and compact parameters
Progressive Detail Start with overview/summary, drill down only if needed
Cache First Check if information is already in context before external calls

Anti-Patterns

Anti-Pattern Why It's Bad Token-Efficient Solution
**SELECT *** Returns unnecessary columns Specify exact columns needed
No LIMIT clause Returns entire dataset Always add LIMIT (e.g., 100)
Full schema requests Returns massive specs Use compact=true or format="summary"
Recursive documentation fetch Fetches entire doc tree Use search_docs with specific query
Fetching full logs Returns thousands of lines Use tail_logs or find_errors with limit
Copy-paste documentation Duplicates content Summarize and reference, don't quote verbatim
No pagination Returns all results at once Use offset/limit for large datasets
Full API schema exploration Multi-MB specifications Get endpoint list first, details on-demand

Read the full file on GitHub · 213 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. 1mo ago First seen · 213 lines · 110 tokens per session scan A 0694e339f89d

Subscribe to this mod's changes

token-optimization is a skill published in the GitHub repository claude-dev-suite/claude-dev-suite (42 stars, last pushed 5d ago), licensed MIT. It adds 110 tokens to every session and 1,623 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.