A comprehensive toolkit designed to drastically reduce token usage and API expenditures through intelligent context management and task-based model routing.
The fastest way to install a skill directly from the registry.
npx clawhub@latest install token-optimizer-qsmtco
Copy the skill folder to one of these locations
~/.openclaw/skills/ <project>/skills/ Priority: Workspace > Local > Bundled
Copy this prompt to OpenClaw to install it automatically.
Help me install token-optimizer-qsmtco using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).
Get the raw skill files in a ZIP archive.
The Token Optimizer is a specialized suite of utilities for developers looking to scale their AI agent deployments without incurring massive costs. By addressing the primary drivers of token bloat—such as excessive context loading and inefficient model selection—this skill provides the necessary scripts to automate cost-saving measures. It is a critical component for managing professional-grade Openclaw Skills where budget tracking and performance optimization are paramount.
This skill focuses on local file analysis to categorize user intent and system requirements, ensuring that every interaction uses the most cost-effective path. Whether you are running a single personal agent or a fleet of managed agents, the Token Optimizer provides the logic to swap expensive reasoning models for faster, cheaper alternatives when appropriate.
Install the toolkit by preparing your workspace and generating optimized configurations:
# Generate an optimized AGENTS.md with lazy loading support
python3 scripts/context_optimizer.py generate-agents
# Deploy the optimized heartbeat template to your workspace directory
cp assets/HEARTBEAT.template.md ~/.openclaw/workspace/HEARTBEAT.md
# Refresh live model pricing from OpenRouter (optional)
export OPENROUTER_API_KEY="your_key_here"
python3 scripts/token_tracker.py refresh-pricing
The skill utilizes several local files to manage state and optimization logic for Openclaw Skills:
| File | Purpose |
|---|---|
pricing.json |
A local database of model costs used for budget forecasting and routing. |
HEARTBEAT.md |
An optimized instruction file that governs periodic agent checks. |
AGENTS.md.optimized |
A template for agent definitions that implements conditional context loading. |
scripts/ |
Contains the Python logic for context analysis, routing, and tracking. |
Loading
A robust lifecycle management tool that prevents context loss by automatically persisting and restoring AI agent state across compactions and restarts.

A domain-restricted local search engine that provides authoritative technical documentation results without web spam.

An API-driven skill for managing product listings and metadata on Taobao and Goofish marketplaces.

A powerful typing performance monitor that integrates Monkeytype statistics and personalized improvement tips into your AI agent workflow.

tokenQrusher is a high-performance optimization system that drastically reduces AI agent token usage through intelligent context filtering and heartbeat management.

Manage and integrate a local, decentralized YaCy search engine into your AI workflows for private web searches.








































