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.
npx skills add itallstartedwithaidea/agent-skills --skill token-optimizationgit clone --depth 1 https://github.com/itallstartedwithaidea/agent-skillsWrote 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.
[](https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/token-optimization)<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/token-optimization"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/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.
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/token-optimization"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/token-optimization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00021 | $0.02322 |
| Opus 5.5 | $0.00008 | $0.00929 |
| Sonnet 5.5 | $0.00004 | $0.00464 |
| Haiku 4.5 | $0.00002 | $0.00232 |
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.
How it starts
The opening of the file, as written. The whole thing — 229 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Token Optimization
Part of Agent Skills™ by googleadsagent.ai™
Description
Token Optimization is the systematic reduction of token expenditure across agent operations without sacrificing output quality. In production AI systems, tokens are the fundamental unit of both cost and latency — every unnecessary token increases API bills and slows response times. This skill codifies the optimization techniques used in the Everything Claude Code ecosystem (150k+ stars) and the googleadsagent.ai™ production platform, where Buddy™ processes thousands of Google Ads analyses daily within strict cost budgets.
The optimization surface spans four dimensions: model selection (matching task complexity to model capability and cost), prompt compression (removing redundant tokens while preserving instruction fidelity), background processing (offloading expensive operations to async workflows), and caching (avoiding redundant computation for identical or similar inputs). Production systems that implement all four dimensions typically achieve 60-80% token cost reduction compared to naive implementations.
Token optimization is not about being cheap — it is about being efficient. An agent that wastes tokens on verbose system prompts or redundant tool outputs is not only expensive; it fills its context window faster, leaving less room for actual reasoning. Optimization improves both economics and quality simultaneously.
Use When
- Monthly API costs exceed budget targets for AI agent operations
- Response latency is above acceptable thresholds for user-facing agents
- Context windows are filling up before complex tasks can complete
- Multiple model tiers are available and you need intelligent routing
- Batch processing workloads generate high token volumes
- You need to scale agent usage without proportional cost increases
How It Works
graph TD
A[Incoming Task] --> B[Complexity Classifier]
B -->|Simple| C[Fast Model<br/>Haiku/Flash]
B -->|Medium| D[Balanced Model<br/>Sonnet/GPT-4o]
B -->|Complex| E[Premium Model<br/>Opus/o1]
C --> F[Prompt Compressor]
D --> F
E --> F
F --> G{Cache Hit?}
G -->|Yes| H[Return Cached Result]
G -->|No| I[Execute with Budget]
I --> J[Cache Result]
J --> K[Response]
H --> K
I --> L{Background Eligible?}
L -->|Yes| M[Async Queue]
M --> I
L -->|No| I
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.
- 1mo ago First seen · 229 lines · 21 tokens per session scan A d26c83b88cb3
token-optimization is a skill published in the GitHub repository itallstartedwithaidea/agent-skills (44 stars, last pushed 6mo ago), licensed MIT. It adds 21 tokens to every session and 2,322 once invoked, about $0.0001 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-08-30.
Other skills, from other repositories
tracking-health
Preventive audit of conversion tracking across all configured ad platforms — Meta pixels + CAPI, Google Ads conversion actions, and final-URL tracking-parameter consistency on every platform — with a GA4 cross-check. Use when the user asks to check tracking, audit conversion measurement, verify pixels / tags, check…
learn
Save a marketing diagnosis insight to the pro-diagnosis knowledge base so it is applied in future operations across all platforms. Use when the user runs /learn, explicitly teaches the agent a marketing insight, corrects the agent's analysis, or asks to remember/record an operational learning for next time. Also use…
adspirer-amazon-ads
Create and manage Amazon Ads through Adspirer — Sponsored Products, Sponsored Brands, and Sponsored Display, with ASIN targeting, search-term reports, ACoS, and bid optimization. Use for anything on Amazon Advertising or Seller/Vendor Central ads.
weekly-report
A skill that creates a weekly marketing-operations summary across connected platforms. It reviews logged actions and strategy information to produce a recap.
review-stack
Stack review of one or more third-party tools (OXC, TanStack, Vite, cf, Sentry, pnpm, Claude Code...) against current official best practices, or of what a dependency bump brings (bumped): one parallel subagent per tool, verified findings, one consolidated plan in chat. USE WHEN: user runs /review-stack or explicitly…
sealeap-amazon-product-targeting
An Amazon Ads planning skill for targeting product pages and categories, including competitor, complementary, upsell, and own-product traffic.