Token Optimization

v1.1.0

Reduce OpenClaw per-turn prompt costs by 70%+ through file splitting, prompt caching, context pruning, and model routing. Tested on production setup with 69...

0· 425·1 current·1 all-time
MIT-0
Download zip
LicenseMIT-0 · Free to use, modify, and redistribute. No attribution required.
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
The skill's purpose (workspace splitting, prompt caching, pruning, model routing) matches the steps in SKILL.md. However, the registry metadata declares no required binaries/configs while the SKILL.md explicitly requires OpenClaw 2026.3.x, the ability to edit ~/.openclaw/workspace files and openclaw.json, and uses CLI commands (e.g., session_status, openclaw gateway restart, wc, mv, cat). That mismatch is operational (the guide assumes an OpenClaw runtime) but not malicious.
!
Instruction Scope
Instructions tell the operator to read, move, and delete workspace files (~/.openclaw/workspace/*), edit openclaw.json, and restart the gateway. These are expected for this purpose but carry operational risk: deleting/moving BOOTSTRAP.md or other files can change runtime behavior; adding caching/pruning rules that allow 'exec' and 'read' can cause command outputs and file contents to be cached and re-sent to models (potential data exposure). The guide also recommends heartbeat intervals to keep cache warm (operational cost/behavior implications).
Install Mechanism
No install spec or bundled code — instruction-only. This minimizes supply-chain risk because nothing is downloaded or executed by the skill itself.
Credentials
The skill requests no environment variables or external credentials. It references Anthropic/OpenRouter providers but assumes the host already has provider creds configured; it does not ask for new secrets, which is proportional for its stated task.
Persistence & Privilege
The skill is not always-enabled and is user-invocable only. It directs changes to local agent config and workspace files (openclaw.json, workspace/*.md), which is normal for an optimization guide but means it will persist changes across runs if you apply them — make backups and test in staging.
Assessment
This is a coherent, instruction-only optimization guide, but take precautions before applying it: 1) Back up your ~/.openclaw/workspace and openclaw.json (don't rely on the mv .bak as your only copy). 2) Test changes in a staging or non-production agent first — splitting/removing BOOTSTRAP.md or shrinking AGENTS.md can unintentionally change behavior. 3) Be cautious about caching command outputs or file contents: allowing 'exec' and 'read' to be cached may store sensitive data in prompts that could later be sent to models or logs. 4) Understand heartbeat recommendations — they keep caches warm but can increase calls/costs. 5) Ensure you have the OpenClaw CLI/tools available (session_status, openclaw gateway restart) — the registry metadata doesn't list these but SKILL.md assumes them. If you want further review, provide your current openclaw.json and a list of workspace files (or test changes on a copy) so I can point out exact edits and potential impacts.

Like a lobster shell, security has layers — review code before you run it.

latestvk979ky93c9grn1jxtqhr51zh8d832gzj

License

MIT-0
Free to use, modify, and redistribute. No attribution required.

Comments