Agent skill

Recursive Context Pruning Token Budgeting

by sickn33 in sickn33/agentic-awesome-skills

Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses.

MITAuto-check passedBusiness, Finance & HR

Install Recursive Context Pruning Token Budgeting

skills CLI
$ npx skills add sickn33/agentic-awesome-skills --skill recursive-context-pruning-token-budgeting -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install sickn33/agentic-awesome-skills recursive-context-pruning-token-budgeting --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/sickn33/agentic-awesome-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/recursive-context-pruning-token-budgeting .claude/skills/recursive-context-pruning-token-budgeting && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
recursive-context-pruning-token-budgeting
GitHub stars
47k
Used in
1 other repo
Token cost
~1.2k tokens
SKILL.md length
497 words
Files
1
Skills in repo
1,394
Repo updated
First seen
Licence
MIT

At a glance

Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses.

  • Works in 5 steps: Metadata Sharding → Token Budget Allocation → Atomic Output Filtering → …
  • Tasks that involve Budgeting and forecasting
  • SKILL.md covers Overview, When to Use This Skill, How It Works and Examples, plus 5 more sections
  • Needs VITE_FIREBASE_API_KEY

What it does

Recursive Context Pruning Token Budgeting is an agent skill from sickn33/agentic-awesome-skills. Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses.

Its SKILL.md is about 1.2k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Business, Finance & HR, covering Budgeting and forecasting and LLM cost and token optimization. The repository describes itself as: AAS Core is the local, agent-first control plane for complete catalog discovery, agent-owned selection, stack validation, and planning, backed by 2,400+ agentic skills. Includes… The licence is MIT.

When your agent uses it

  • Tasks that involve Budgeting and forecasting
  • Tasks that involve LLM cost and token optimization

Example prompts

  • “Use the recursive-context-pruning-token-budgeting skill to optimiz AI agent performance by pruning redundant context, managing token usage, and…”
  • “/recursive-context-pruning-token-budgeting”

Requirements

  • A credential in VITE_FIREBASE_API_KEY

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. Metadata Sharding
  2. Token Budget Allocation
  3. Atomic Output Filtering
  4. Ambiguity Check
  5. Abstractive Compression

What it can do on your machine

Read from SKILL.md and the folder at commit 1e53ce2. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are javascript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • VITE_FIREBASE_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Recursive Context Pruning Token Budgeting loads about 1.2k tokens when it runs. Until then it costs about 45 tokens; SKILL.md has 497 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~45
When it runs · the whole SKILL.md, loaded when a task matches
~1.2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from sickn33/agentic-awesome-skills at commit 1e53ce2, republished under its MIT licence (© sickn33). 497 words, ~1,155 tokens.

Download SKILL.mdSave it as .claude/skills/recursive-context-pruning-token-budgeting/SKILL.md (or your agent's skills folder).
name
recursive-context-pruning-token-budgeting
description
Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses.
category
prompt-engineering
risk
safe
source
self
source_repo
Kench001/antigravity-awesome-skills
source_type
self
date_added
2026-05-03
author
Kench001
tags
efficiency, token-optimization, brevity, context-management
tools
claude, cursor, gemini

Recursive Context Pruning & Token Budgeting

Overview

This skill implements a "Gatekeeper" logic to prevent context window bloat and unnecessary token expenditure. It ensures the agent only processes relevant data shards and adheres to an Atomic Precision protocol—delivering functional answers with zero conversational filler. By recursively summarizing state and stripping "bridge phrases," it maximizes the longevity and speed of long-running development workflows.

When to Use This Skill

  • Use when building multi-step agents to prevent repetition and "memory drift" in long conversations.
  • Use when working with large document sets or codebases to avoid dumping entire files into the prompt.
  • Use when you need purely functional output (code/logic) without "Sure! Here is your..." intros.

How It Works

Step 1: Metadata Sharding

Scan the available data for headers, summaries, and key indicators. Create a "map" of the context rather than injecting the full source. Never pull the entire file into the prompt unless a specific, narrowed fragment is requested.

Step 2: Token Budget Allocation

Calculate a "Safe Response Limit" based on the current context window. Allocate 30% for current logic processing, 20% for immediate output, and 50% for a future context buffer.

Step 3: Atomic Output Filtering

Strip all "Bridge Phrases" (e.g., "I've updated the code," "Based on your request," "Sure"). Start the response immediately with the solution or the code block.

Step 4: Ambiguity Check

Before executing Step 3, scan for missing critical variables (e.g., specific file names or environment types). If the prompt is too ambiguous, bypass the atomic output and generate exactly one concise question to resolve the blocker.

Step 5: Abstractive Compression

Summarize the current turn into a "compressed state string" (e.g., [Project: Feasify | State: Auth-Fixed | Remaining-Tasks: 2]) to discard redundant conversational data before the next prompt.

Examples

Example 1: Filtered Code Output (No Filler)
text
User: "Update the Firebase config to use environment variables."
javascript
const firebaseConfig = {
  apiKey: process.env.VITE_FIREBASE_API_KEY,
  authDomain: process.env.VITE_FIREBASE_AUTH_DOMAIN,
  projectId: process.env.VITE_FIREBASE_PROJECT_ID
};
Example 2: Essential Clarification
text
User: "Deploy the function."
text
"Specify environment: production or staging?"
Show full SKILL.md (198 more words)Show less

Best Practices

  • ✅ Direct Start: Place the code or answer at the very first character of the response.
  • ✅ Summarize-as-you-go: Turn 10 pages of discussion into 5 bullet points for the next turn.
  • ✅ Omit Signatures: Never end with "Let me know if you need more help."
  • ❌ No Bridge Phrases: Avoid "Here is the code," "Sure," or "I can help with that."
  • ❌ No Guessing: If input is missing, ask immediately rather than wasting tokens on a generic guess.

Limitations

  • This skill does not replace environment-specific validation, testing, or expert review.
  • Extreme brevity can occasionally hide important nuances; use concise inline comments (// crucial step) for critical notes.

Security & Safety Notes

  • Never prune safety headers, environment-specific security constraints, or system-level instructions during the compression stage.
  • Maintain original system instructions at the "Root" of the context to prevent context-loss-based jailbreaks.

Common Pitfalls

  • Problem: The response is so brief it lacks the context needed for implementation. Solution: Use concise inline code comments instead of separate paragraphs of text.

  • Problem: The agent loses the overarching goal due to over-compression. Solution: Always pin the "Primary Objective" to the top of every pruned prompt.

  • @atomic-precision-response - Specifically for removing conversational filler.
  • @context-sharding - For managing large-scale documentation mapping.

© sickn33, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/recursive-context-pruning-token-budgeting of sickn33/agentic-awesome-skills.

Open the folder on GitHubat commit 1e53ce2

Used in 1 other repository

We found 5 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in sickn33/agentic-awesome-skills, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Recursive Context Pruning Token Budgeting next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Recursive Context Pruning Token Budgeting compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Recursive Context Pruning Token Budgeting this skillsickn33/agentic-awesome-skills47k1 repos~1.2kAutomated safety check: PassMIT
Context Optimizationguanyang/open-agent-hub9732 repos~4kAutomated safety check: PassMIT
Cost Verification Auditorcuriositech/some_claude_skills2431 repos~1.4kAutomated safety check: NotesMIT
Longbridge Researchhelsome/folio2693 repos~2.1kAutomated safety check: PassMIT
Bet SizingJoelLewis/finance_skills205—~2.5kAutomated safety check: PassMIT
Dd LogsDataDog/pup1k—~1.3kAutomated safety check: PassApache-2.0

Similar skills

  • Context Optimization

    guanyang/open-agent-hub

    This skill should be used for improving context efficiency: context budgeting, observation masking, prefix or KV-cache strategy, partitioning, token-cost reduction, retrieval scoping, and extending…

    973 GitHub starsUsed in 2 repos~4k tokens
    Agent WorkflowsAuto-check passed
  • Cost Verification Auditor

    curiositech/some_claude_skills

    Audit LLM token cost estimates against actual API usage. An agent skill from curiositech/some_claude_skills.

    243 GitHub starsUsed in 1 repo~1.4k tokens
    AI & LLM EngineeringAuto-check: notes
  • Longbridge Research

    helsome/folio

    Institution ratings, consensus price targets, EPS/revenue forecasts, finance calendar, shareholder data, fund holders, insider trades (SEC Form 4), short interest, industry rankings, peer group…

    269 GitHub starsUsed in 3 repos~2.1k tokens
    Business, Finance & HRAuto-check passed
  • Bet Sizing

    JoelLewis/finance_skills

    Determine how much capital to allocate to individual positions within a portfolio.

    205 GitHub stars~2.5k tokensUpdated 2 mo ago
    Business, Finance & HRAuto-check passed
  • Dd Logs

    DataDog/pup

    Official

    Log management - search, pipelines, archives, and cost control.

    1k GitHub stars~1.3k tokensUpdated today
    Business, Finance & HRAuto-check passed
  • Cash Flow Forecast

    WellApp-ai/Well

    Forecast cash flow and runway for a Well workspace from booked invoices and collected bank transactions.

    345 GitHub stars~567 tokensUpdated 7 days ago
    Business, Finance & HRAuto-check passed

More from sickn33/agentic-awesome-skills

All 1,394 skills in this repo
  • Liuguang Banlan UI

    sickn33/agentic-awesome-skills

    Implements an interface in one of two named color modes, iridescent white or colorful black, from a parameterized starter that reports measured color intensity.

    47k GitHub starsUsed in 1 repo~2.5k tokens
    Auto-check passed
  • User Thoughts Memory

    sickn33/agentic-awesome-skills

    Saves a user's project decisions, rules and preferences into a project-local mdbase so later sessions and other agents can recover the intent.

    47k GitHub starsUsed in 1 repo~2.5k tokens
    Auto-check passed
  • Using LWC Memory and Graphs

    sickn33/agentic-awesome-skills

    Keeps project decisions, research and verified results available across coding-agent sessions through LWC memory, a document Wiki graph and a CodeGraph code index.

    47k GitHub starsUsed in 1 repo~2k tokens
    Auto-check passed
  • Find Complementary Founders

    sickn33/agentic-awesome-skills

    Guides an agent through assessing its own owner for cofounder fit, publishing an approved profile, and ranking complementary profiles other agents published for their owners.

    47k GitHub starsUsed in 1 repo~4.8k tokens
    Auto-check passed
  • Whatsapp Cloud API

    sickn33/agentic-awesome-skills

    Integracao com WhatsApp Business Cloud API (Meta). An agent skill from sickn33/agentic-awesome-skills.

    47k GitHub starsUsed in 2 repos~4.5k tokens
    Auto-check passed
  • Cline Pilot

    sickn33/agentic-awesome-skills

    Acts as a proxy for the Cline CLI, dispatching coding tasks one at a time, monitoring runs by hard evidence, relaying decisions to you and learning per-project preferences.

    47k GitHub starsUsed in 1 repo~4.6k tokens
    Auto-check passed

Questions about Recursive Context Pruning Token Budgeting

What does Recursive Context Pruning Token Budgeting do?

Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses. Recursive Context Pruning Token Budgeting is an agent skill from sickn33/agentic-awesome-skills. Optimizes AI agent performance by pruning redundant context, managing token usage, and enforcing ultra-concise, direct-to-value responses.

When should I use Recursive Context Pruning Token Budgeting?

Recursive Context Pruning Token Budgeting fits situations like: tasks that involve Budgeting and forecasting; tasks that involve LLM cost and token optimization.

How do I install Recursive Context Pruning Token Budgeting in Claude Code?

Run `npx skills add sickn33/agentic-awesome-skills --skill recursive-context-pruning-token-budgeting -a claude-code`. Or copy the skill folder (skills/recursive-context-pruning-token-budgeting in sickn33/agentic-awesome-skills) into .claude/skills/recursive-context-pruning-token-budgeting in your project. Claude Code loads it when a task matches its description.

How do I install Recursive Context Pruning Token Budgeting in Codex?

Run `npx skills add sickn33/agentic-awesome-skills --skill recursive-context-pruning-token-budgeting -a codex`. Or copy the skill folder (skills/recursive-context-pruning-token-budgeting in sickn33/agentic-awesome-skills) into .agents/skills/recursive-context-pruning-token-budgeting in your project. Codex loads it when a task matches its description.

Can I use Recursive Context Pruning Token Budgeting in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sickn33/agentic-awesome-skills --skill recursive-context-pruning-token-budgeting -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/recursive-context-pruning-token-budgeting, .gemini/skills/recursive-context-pruning-token-budgeting, .github/skills/recursive-context-pruning-token-budgeting and .opencode/skills/recursive-context-pruning-token-budgeting in your project.

What does Recursive Context Pruning Token Budgeting need to run?

Going by SKILL.md and its folder, Recursive Context Pruning Token Budgeting needs credentials named VITE_FIREBASE_API_KEY. Our summary lists: A credential in VITE_FIREBASE_API_KEY.

Does Recursive Context Pruning Token Budgeting access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Recursive Context Pruning Token Budgeting safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Recursive Context Pruning Token Budgeting use?

Recursive Context Pruning Token Budgeting is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Recursive Context Pruning Token Budgeting use?

About 1.2k tokens (SKILL.md is roughly 4.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Recursive Context Pruning Token Budgeting?

Skills that share tags, products or a category with Recursive Context Pruning Token Budgeting: Context Optimization (guanyang/open-agent-hub, 973 stars), Cost Verification Auditor (curiositech/some_claude_skills, 243 stars), Longbridge Research (helsome/folio, 269 stars) and Bet Sizing (JoelLewis/finance_skills, 205 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Recursive Context Pruning Token Budgeting?

sickn33 (a GitHub user) maintains it in sickn33/agentic-awesome-skills, which has 47,304 GitHub stars. The repository holds 1,394 skills in this directory. The repository was last updated on October 6, 2026.

Source: sickn33/agentic-awesome-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.