- Home
- Skills
- Prompt & Skill Engineering
- TokenSniper: Zero-Degradation Token Optimizer
Works with the AI Agents you already use
TokenSniper: Zero-Degradation Token Optimizer
by yuvalB
Eliminate agent chat noise and context waste without sacrificing quality. Enforces minimal diffs, line-range reads, and tri-mode routing: lean 3-5 bullet updates by default, deep explanations on demand.
Free
TokenSniper: Zero-Degradation Token Optimizer
Example session with this skill installed
Refactor the handleRequest function in api/server.ts to use the new AuthService, then explain why we're moving away from the legacy singleton.
- Read your context and instructions
- Compiled the tokensniper
- Refactored
handleRequestinapi/server.tsto injectAuthServicevia constructor DI, replacingAuth.getInstance(). - Removed unused
LegacyProviderimport frominternal/types.ts. - Verified
12/12integration tests passing intests/auth.spec.ts.
Architectural Reasoning: Dependency Injection vs. Singletons
Migrating away from the legacy Auth singleton resolves three core bottlenecks:
- Test Isolation: The singleton retained global state across test runs, leaking auth headers between tests. Scoped
AuthServiceinstances allow clean per-request mock injection. - Concurrency Safety: The legacy shared internal cache was not thread-safe, risking race conditions under high-volume token validation. Request-scoped services isolate execution context.
- Provider Extensibility: Hard-coding JWT logic inside a static singleton blocked OIDC adoption. Defining an
AuthServiceinterface lets us swap auth providers across environments without touching API handler logic.
Connects securely to your tools. The creator never sees your data.
About this skill
High token consumption, full-file reads, and verbose chat filler slow down agentic coding cycles and drain API budgets. This skill enforces an always-on execution meta-rule that eliminates structural waste, redundant prose, and unnecessary file rewrites without compromising code quality, edge-case safety, or technical rigor.
What it does
- Eliminates redundant narration by executing consecutive tool calls silently without intermediate verbal updates ("Now I will read...").
- Optimizes context window usage through targeted
grep/search queries and line-range reads instead of loading entire files. - Enforces lean reporting using a rigid 3–5 bullet summary format for routine code edits (files modified, verification status, critical warnings).
- Preserves deep reasoning via tri-mode routing that automatically lifts brevity limits whenever you ask "why", request an explanation, or submit a mixed edit + analysis prompt.
- Guarantees error transparency by surfacing full tracebacks and root causes on any build or test failure while compressing successful execution logs.
How it works
- Classify Request Mode: Automatically routes every prompt into Default Lean Mode (coding/execution), Full Explanation Mode (conceptual/architectural), or Hybrid Mode (minimal code status + deep explanation).
- Execute Efficiency Protocol: Takes the shortest reliable tool path, scoping searches and reading only relevant line ranges.
- Apply Targeted Diffs: Modifies only the exact lines required rather than rewriting whole files, keeping comments strictly to non-obvious invariants and edge cases.
- Enforce Output Contract: Delivers either a telegraphic 3–5 bullet status or a structured Markdown deep-dive based on detected intent.
Frameworks & tools
Platform-agnostic meta-rule compatible with Antigravity, Claude Code, Cursor, Windsurf, Cline, and custom tool-using LLM agents. Optimizes filesystem operations, code search utilities, diff editors, and test runners.
Why this beats prompting it yourself
Generic "be concise" instructions make agents lazy—causing them to truncate stack traces, skip verification steps, or give shallow answers to complex architectural questions. This skill pairs strict output contracts for routine edits with automatic brevity-release triggers for debugging and deep-dive explanations.
Use cases
- High-velocity coding & refactoring with minimal diffs and zero conversational filler.
- Large codebase exploration using targeted search and line-range reads to prevent context bloat.
- Automated test-fix loops that stay quiet on green runs and surface full root-cause logs on failures.
- Mixed execution + learning workflows where code changes stay concise while "why" questions get thorough breakdowns.
Known limitations
- Optimizes output tokens, tool-call chatter, and file-read context; does not restrict internal model reasoning/thinking tokens.
- Maximum context savings require an agent environment equipped with
grep/search and line-range file-reading tools.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Free to use
No account required to browse
Trust & safety
Security scan
Security scan passed 15 days ago
- Free with an Agensi account
Nothing to install. It runs in your AI agent.
Works out-of-the-box with any tool-using coding agent (Antigravity, Claude Code, Cursor, Windsurf). Zero external dependencies, scripts, or API keys required.
Permissions
Read and write file access are used strictly to perform targeted line-range code reads and apply minimal diffs instead of rewriting entire files.
What's inside
Creator
yuvalB
2 skills on Agensi
Frequently Asked Questions
New in Prompt & Skill Engineering
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Prompt & Skill Engineering.