Low-Token Context Harness & Cache Optimizer by Saki-AI

    1

    Reduce agent context overhead with static prompt-prefix guidance, deterministic tool-output truncation and progressive conversation compaction. Free from the creator of Saki-AI and Saki-Panel.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Low-Token Context Harness & Cache Optimizer by Saki-AI

    Example session with this skill installed

    Run the bundled context compressor demo. Show estimated context size before and after compaction, explain what it retains, and give me a simple integration plan.

    • Read your context and instructions
    • Compiled the low-token context harness

    Demo result

    Command: node scripts/context-compressor.cjs --demo

    MeasurementValue
    Compression appliedtrue
    Original estimated tokens1,470
    Compacted estimated tokens341
    Reduction in this synthetic fixture76.8%

    The bundled fixture keeps the original authentication-refactor task, a compressed background digest with the recorded file path and hash marker, and the recent rate-limiting and token-expiry exchanges. Repeated file content is summarized with an explicit truncation marker. These are fixture contents, not claims that the demo changed or tested your application.

    Integration plan

    1. Keep identity, tools and stable instructions at the front of your prompt.
    2. Move timestamps and changing workspace state to a dynamic tail.
    3. Truncate oversized tool results before storing them in message history.
    4. Call compactLoopMessages when context estimates exceed the configured threshold.
    5. Compare real provider usage and verify task continuity on representative sessions.

    This local helper estimates tokens and compresses messages. It does not guarantee the same savings on other workloads or create a provider-side cache.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Keep agents within their context budget

    A free, open-source context-engineering workflow extracted from Saki-AI. Built for developers working with SKILL.md-compatible coding agents and custom local or API-based agents.

    What you get

    • A standard SKILL.md workflow for static prompt prefixes and dynamic context tails.
    • A standalone Node.js helper for mixed CJK/Latin token estimates, tool-output truncation, background digests and progressive loop compaction.
    • Continuity reminders for user constraints, paths, recorded hashes and unresolved verification.
    • A runnable demo: node scripts/context-compressor.cjs --demo.

    Practical limits

    Token counts are estimates. Savings depend on the workload; prompt-cache hits depend on your model provider and integration. This helper does not configure provider caching. Review retained context before relying on compressed history.

    Free under Apache-2.0. No npm dependencies or API keys required for the helper.

    Explore both projects

    This free skill is shared by the creator of Saki-AI and Saki-Panel. Visit both repositories, try the projects, and consider giving both a GitHub star to support continued development.

    Token estimates are heuristic. Compaction is deterministic, not an LLM summary. Savings and cache hits depend on the workload and provider. Some history is omitted; review retained constraints and verification evidence.

    How to use

    1. 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. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    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 forever

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 15 days ago

    • Free with an Agensi account

    Requires

    Node.js 18+
    Python
    Node.js

    Permissions

    Terminal / Shell
    Read Files

    Runs locally via Node.js. Integration may read user-selected project files. No accounts, API keys or network calls required by the helper.

    Listed15 days ago

    What's inside

    Frequently Asked Questions

    A SKILL.md workflow, scripts/context-compressor.cjs and the Apache-2.0 license. The helper has no npm dependencies.

    No. CJK/Latin token counts are estimates. Use your model provider tokenizer and usage metrics for precise measurement.

    No fixed saving is guaranteed. The included synthetic demo reduced the local estimate from 1,470 to 341 tokens; real workloads vary.

    It explains stable-prefix design. Provider-specific caching must be configured and measured in your own integration.

    No. It retains the task and recent messages plus a bounded digest. Review constraints, file hashes and unresolved verification after compaction.

    Explore and star both projects: Saki-AI — https://github.com/EthanChan050430/Saki-AI and Saki-Panel — https://github.com/EthanChan050430/Saki-Panel.

    New in Agents & Orchestration