Caveman Input Compression
/install caveman-compress
Caveman Input Compression Skill
Identity
Compress natural language workspace files into caveman-speak (~45% fewer input tokens). Creates .original.md backup before overwriting.
Supported Files
Always safe to compress:
SOUL.md✅IDENTITY.md✅USER.md✅
Feature-flagged (requires env var set):
AGENTS.md🔒 (CAVEMAN_COMPRESS_AGENTS=1)HEARTBEAT.md🔒 (CAVEMAN_COMPRESS_HEARTBEAT=1)MEMORY.md🔒 (CAVEMAN_COMPRESS_MEMORY=1)
Security
- No shell=True in subprocess calls
- No user content as shell arguments
- Files >500KB rejected
.original.mdbackup created before overwrite- Aborts if backup already exists (prevents accidental overwrite)
API Fallback Chain
Models tried in order:
- claude CLI (desktop auth) - Primary
- MiniMax (OpenAI-compatible) - Requires
MINIMAX_BASE_URL+MINIMAX_API_KEY - DeepSeek (OpenAI-compatible) - Requires
DEEPSEEK_API_KEY
Uses subprocess + curl, no OpenAI SDK required.
Usage
# Compress a specific file
python3 -m skills.caveman_compress.scripts.compress /home/pi/.openclaw/workspace/SOUL.md
# Dry run (no write, just preview)
python3 -m skills.caveman_compress.scripts.compress --dry-run /home/pi/.openclaw/workspace/SOUL.md
# Feature flags (environment variables)
CAVEMAN_COMPRESS_AGENTS=1 /home/pi/.openclaw/workspace/scripts/caveman-enable.sh
Model Override
Set COMPRESSION_MODEL env var to use specific model:
COMPRESSION_MODEL=deepseek32 python3 -m skills.caveman_compress.scripts.compress SOUL.md
Default: deepseek32 (cheap, fast)
References
- Upstream: https://github.com/JuliusBrussee/caveman
- Paper: arXiv 2604.00025 — "Brevity Constraints Reverse Performance Hierarchies"
- Project: memory/projects/caveman-token-reducer/
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install caveman-compress - After installation, invoke the skill by name or use
/caveman-compress - Provide required inputs per the skill's parameter spec and get structured output
What is Caveman Input Compression?
Compress workspace bootstrap files into caveman-speak to reduce input tokens on every session load. Creates .original.md backups before overwriting. It is an AI Agent Skill for Claude Code / OpenClaw, with 85 downloads so far.
How do I install Caveman Input Compression?
Run "/install caveman-compress" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is Caveman Input Compression free?
Yes, Caveman Input Compression is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does Caveman Input Compression support?
Caveman Input Compression is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created Caveman Input Compression?
It is built and maintained by austrian_guy (@ether-btc); the current version is v0.1.0.