compress

Compress CLAUDE.md, todos, and preferences into caveman format with backups.

2|1|Updated Mar 26, 2026
One-click install
npx skills add https://github.com/huangzida/skills --skill compress-huangzida
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: compress
Source: https://github.com/huangzida/skills/tree/main/compress
Command: npx skills add https://github.com/huangzida/skills --skill compress-huangzida

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires anthropic, and includes scripts (resource) components.

What problem does it solve?

Manual management of memory files for AI prompts leads to token bloat and slower responses. This skill compresses natural language content into caveman format while preserving essential substance, URLs, code blocks, and structure.

Core Features & Use Cases

  • Compression of CLAUDE.md, todos, and preferences into a compact caveman representation to save tokens and reduce prompt length.
  • Backup and overwrite workflow: original content is preserved in FILE.original.md, while the compressed version replaces the source.
  • Deterministic processing with validation: compression is followed by strict validation and retrial logic to ensure fidelity.

Quick Start

Run caveman compress on a target natural-language file to produce a compressed version and a backup.

Frequently Asked Questions about compress

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I reduce input tokens in my CLAUDE.md memory files?

You can compress natural language memory files into caveman format to reduce input tokens while preserving substance, URLs, code blocks, and file paths. This targets CLAUDE.md, todos, and preferences to shorten prompt length.

What is caveman format compression for markdown memory docs?

Caveman format compression is a technique that transforms natural language memory files into a compact representation to save tokens. It preserves essential substance, URLs, code blocks, headings, and file paths while reducing overall length.

Does the compression process keep a backup before overwriting the original file?

Yes, the compression workflow creates a backup of your original content in FILE.original.md before safely overwriting the source file with the compressed caveman format version.

How does validation work during markdown file compression?

Validation follows compression to ensure fidelity by checking the output against the source. It uses a deterministic CLI workflow with retry loops to guarantee the compressed file preserves essential substance and structure.

Can I use this to compress todos and preferences or just CLAUDE.md?

You can compress todos and preferences in addition to CLAUDE.md. The tool targets all these natural language memory files, applying deterministic processing to reduce tokens across your memory documentation.

What is the best way to automate token savings for AI prompt memory files?

The best way to automate token savings is running a deterministic CLI compression workflow on your memory files. It safely overwrites sources with compressed caveman format text and validates fidelity through retry loops.