PluginBench
Skill
Fail
Audit score 45

token-budget-advisor

affaan-m/everything-claude-code

Let users choose response depth before you answer, controlling token usage upfront.

What is token-budget-advisor?

Token Budget Advisor intercepts requests to offer depth-level choices (25%, 50%, 75%, 100%) before responding. Use it when users explicitly mention tokens, budget, response length, or want to control answer detail.

  • Estimates input token count using heuristic rules (prose: words × 1.3; code: chars / 4)
  • Classifies prompt complexity (Simple, Medium, Medium-High, Complex, Creative) and calculates response window
  • Presents four depth options with estimated token counts before answering
  • Responds at the chosen level, adjusting detail, examples, and scope accordingly
  • Maintains user's depth choice silently across the session unless changed

How to install token-budget-advisor

npx skills add https://github.com/affaan-m/everything-claude-code --skill token-budget-advisor
Claude Code
Cursor
Windsurf
Cline

How to use token-budget-advisor

  1. 1.When user mentions tokens, budget, depth, or response length, estimate input tokens using the heuristic (prose: words × 1.3; code: chars / 4)
  2. 2.Classify the prompt complexity (Simple, Medium, Medium-High, Complex, or Creative)
  3. 3.Calculate the response window using the complexity multiplier range (e.g., Simple: 3×–8×)
  4. 4.Present the depth menu with estimated tokens for each level (25%, 50%, 75%, 100%) before answering
  5. 5.Wait for user to choose a level (1–4 or say a percentage/depth phrase)
  6. 6.Respond at the chosen level, adjusting detail, examples, and scope per the guidelines
  7. 7.For follow-up questions, maintain the chosen depth silently unless the user changes it

Use cases

Good for
  • User asks 'give me the short version' or 'brief answer' and you present depth options before responding
  • User mentions 'token budget' or 'how many tokens will this use?' and you estimate and offer choices
  • User says 'exhaustive answer' or '100% depth' and you skip the menu, responding fully
  • Follow-up questions in a session where depth was already chosen—maintain that level silently
  • Mixed-language requests ('dame la versión corta') where user controls response size
Who it's for
  • Users managing token limits or API costs
  • Developers wanting quick answers vs. thorough explanations
  • Anyone optimizing for response time or detail trade-offs
  • Teams with token budgets per session or project

token-budget-advisor FAQ

How accurate is the token estimation?

The skill uses heuristic estimation (~85–90% accuracy, ±15% variance) without a real tokenizer. Always show the precision disclaimer to set expectations.

What if the user already specified a depth level earlier?

Maintain that level silently for subsequent responses in the same session. Do not re-ask unless the user explicitly changes their preference.

Should I trigger this for 'token' in other contexts (auth, payment)?

No. Only trigger when 'token' refers to response size or token budget. Do not trigger for auth tokens, session tokens, or payment tokens.

What if the answer is trivially one line?

Do not trigger the skill. If the answer is obviously brief, just answer directly without offering depth options.

Can users skip the menu and signal a level directly?

Yes. If they say '25% depth', 'short version', 'exhaustive answer', or '100% depth', respond at that level immediately without asking.

Full instructions (SKILL.md)

Source of truth, from affaan-m/everything-claude-code.


name: token-budget-advisor description: >- Offers the user an informed choice about how much response depth to consume before answering. Use this skill when the user explicitly wants to control response length, depth, or token budget. TRIGGER when: "token budget", "token count", "token usage", "token limit", "response length", "answer depth", "short version", "brief answer", "detailed answer", "exhaustive answer", "respuesta corta vs larga", "cuántos tokens", "ahorrar tokens", "responde al 50%", "dame la versión corta", "quiero controlar cuánto usas", or clear variants where the user is explicitly asking to control answer size or depth. DO NOT TRIGGER when: user has already specified a level in the current session (maintain it), the request is clearly a one-word answer, or "token" refers to auth/session/payment tokens rather than response size. metadata: origin: community

Token Budget Advisor (TBA)

Intercept the response flow to offer the user a choice about response depth before Claude answers.

When to Use

  • User wants to control how long or detailed a response is
  • User mentions tokens, budget, depth, or response length
  • User says "short version", "tldr", "brief", "al 25%", "exhaustive", etc.
  • Any time the user wants to choose depth/detail level upfront

Do not trigger when: user already set a level this session (maintain it silently), or the answer is trivially one line.

How It Works

Step 1 — Estimate input tokens

Use the repository's canonical context-budget heuristics to estimate the prompt's token count mentally.

Use the same calibration guidance as context-budget:

  • prose: words × 1.3
  • code-heavy or mixed/code blocks: chars / 4

For mixed content, use the dominant content type and keep the estimate heuristic.

Step 2 — Estimate response size by complexity

Classify the prompt, then apply the multiplier range to get the full response window:

ComplexityMultiplier rangeExample prompts
Simple3× – 8×"What is X?", yes/no, single fact
Medium8× – 20×"How does X work?"
Medium-High10× – 25×Code request with context
Complex15× – 40×Multi-part analysis, comparisons, architecture
Creative10× – 30×Stories, essays, narrative writing

Response window = input_tokens × mult_min to input_tokens × mult_max (but don’t exceed your model’s configured output-token limit).

Step 3 — Present depth options

Present this block before answering, using the actual estimated numbers:

Analyzing your prompt...

Input: ~[N] tokens  |  Type: [type]  |  Complexity: [level]  |  Language: [lang]

Choose your depth level:

[1] Essential   (25%)  ->  ~[tokens]   Direct answer only, no preamble
[2] Moderate    (50%)  ->  ~[tokens]   Answer + context + 1 example
[3] Detailed    (75%)  ->  ~[tokens]   Full answer with alternatives
[4] Exhaustive (100%)  ->  ~[tokens]   Everything, no limits

Which level? (1-4 or say "25% depth", "50% depth", "75% depth", "100% depth")

Precision: heuristic estimate ~85-90% accuracy (±15%).

Level token estimates (within the response window):

  • 25% → min + (max - min) × 0.25
  • 50% → min + (max - min) × 0.50
  • 75% → min + (max - min) × 0.75
  • 100% → max

Step 4 — Respond at the chosen level

LevelTarget lengthIncludeOmit
25% Essential2-4 sentences maxDirect answer, key conclusionContext, examples, nuance, alternatives
50% Moderate1-3 paragraphsAnswer + necessary context + 1 exampleDeep analysis, edge cases, references
75% DetailedStructured responseMultiple examples, pros/cons, alternativesExtreme edge cases, exhaustive references
100% ExhaustiveNo restrictionEverything — full analysis, all code, all perspectivesNothing

Shortcuts — skip the question

If the user already signals a level, respond at that level immediately without asking:

What they sayLevel
"1" / "25% depth" / "short version" / "brief answer" / "tldr"25%
"2" / "50% depth" / "moderate depth" / "balanced answer"50%
"3" / "75% depth" / "detailed answer" / "thorough answer"75%
"4" / "100% depth" / "exhaustive answer" / "full deep dive"100%

If the user set a level earlier in the session, maintain it silently for subsequent responses unless they change it.

Precision note

This skill uses heuristic estimation — no real tokenizer. Accuracy ~85-90%, variance ±15%. Always show the disclaimer.

Examples

Triggers

  • "Give me the short version first."
  • "How many tokens will your answer use?"
  • "Respond at 50% depth."
  • "I want the exhaustive answer, not the summary."
  • "Dame la version corta y luego la detallada."

Does Not Trigger

  • "What is a JWT token?"
  • "The checkout flow uses a payment token."
  • "Is this normal?"
  • "Complete the refactor."
  • Follow-up questions after the user already chose a depth for the session

Source

Standalone skill from TBA — Token Budget Advisor for Claude Code. Original project also ships a Python estimator script, but this repository keeps the skill self-contained and heuristic-only.