AI Agent Hub
Back to skills
Agent Token-Saving Workflow Optimizer icon

Agent Token-Saving Workflow Optimizer

AI Agent Updated 2026.08.30

Paste the following prompt into your AI chat to install this skill:

Please follow https://skillhub.cn/install/skillhub.md to install @user_8d4ddd46/token-saving.

About this skill

Problem

In multi-turn, multi-tool, multi-document agent tasks, token waste often comes from repeated retrieval, verbose planning, dumping long tool output into context, and over-expanded step reasoning. This skill adds workflow constraints instead of replacing model capability: it makes output, loading, and validation decisions explicit to avoid useless tokens.

How It Works

  • Routing: one-step tasks answer directly; two-to-three-step tasks plan internally then execute; tasks with three or more steps use plan -> pilot -> execute.
  • Parallelism and deduplication: independent tool calls are issued in parallel; already retrieved data is not searched or read again.
  • CoD reasoning: in compressible scenarios, each step stays within <=5 words, with the answer after ####.
  • Context management: tool output above 500 tokens keeps key conclusions; long content may be written to workspace after user confirmation and referenced by path; complex tasks maintain progress.md.
  • Memory injection: if missing memory is detected, it reads memory-inject.md, asks for confirmation, and writes to soul_md or agent_md.

Boundaries

Do not use it for simple Q&A or very short contexts. When anti-hallucination, high precision, creativity, first execution, or visible reasoning is required, validation takes priority over saving tokens. It does not modify conversation history; it mainly affects the agent output side. For data volume, aggregate no more than 200K characters and paginate 10-20 items per page.

Use Cases

  • In 10+ turn multi-tool conversations, let the agent call search, read, and analysis tools in parallel, merge results, and avoid repeated retrieval.
  • When analyzing long documents, truncate tool output above 500 tokens to key conclusions and track task progress in progress.md.
  • Before multi-step data aggregation, use plan, pilot, and execute to validate a small sample first and reduce wasted context.
  • In long conversations, write confirmed materials to workspace and reference them by path instead of loading full text repeatedly.

Best For

  • Engineers building multi-tool agent apps: need fewer repeated tool calls and less redundant output in 3+ step tasks.
  • Developers maintaining long-conversation assistants: need context control by truncating tool output and maintaining progress.md.
  • Data analytics engineers producing reports: need to aggregate results from multi-turn retrieval and document reading without token bloat.
  • Team leads managing enterprise knowledge-base assistants: need automatic routing, parallel tool calls, and path-referenced materials for complex tasks.