Skip to content
Back to skills

Caveman Compress

ASecurity

Trigger: /caveman:compress <filepath>, compress memory file. Compress prose files while preserving technical content and backups.

  • 3 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 6, 2026
ai-agentspythonshellsqlsecurity

Security analysis

A100/100

Pro scans all 11 files and shows the line behind each finding

Scanned November 20, 2026

npx -y skills add Snakeblack/ospec-workflow --skill caveman-compress --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Caveman Compress?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Caveman Compress
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/snakeblack-caveman-compress/badge)](https://www.skillsdirectory.com/skills/snakeblack-caveman-compress)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: caveman-compress
description: "Trigger: /caveman:compress <filepath>, compress memory file. Compress prose files while preserving technical content and backups."
license: MIT AND Commons-Clause
metadata:
  author: "julius-brussee, manuel-retamozo-garcia"
  version: "1.0"
---

## Activation Contract

Load only when the user explicitly asks to compress a natural-language file or invokes `/caveman:compress <filepath>`.

## Hard Rules

- Compress only prose files: `.md`, `.txt`, or extensionless memory files.
- Never compress source, config, lock, env, SQL, shell, HTML, XML, JSON, YAML, TOML, CSS, or generated files.
- Preserve exactly: fenced code blocks, inline code, URLs, markdown links, file paths, commands, technical names, proper nouns, dates, versions, numbers, and frontmatter.
- Preserve markdown heading text, list nesting, table structure, and numbering.
- Back up the original beside the file as `<filename>.original.md` before overwriting.
- Never compress an `.original.md` backup.
- If unsure whether text is code or prose, leave it unchanged.

## Decision Gates

| Condition | Action |
| --- | --- |
| Supported prose file | Compress prose outside protected regions. |
| Unsupported file type | Stop and report unsupported file. |
| Existing `.original.md` target | Stop unless user explicitly confirms overwrite. |
| Validation fails | Report failure; leave original untouched. |

## Execution Steps

1. Resolve the target path from the user command.
2. Validate file type and backup path.
3. Prefer the local script in `skills/caveman-compress/scripts/` when available: run `python -m scripts <absolute_filepath>` from `skills/caveman-compress`.
4. Compress by removing filler, hedging, pleasantries, redundant phrasing, and duplicate examples.
5. Validate protected regions stayed byte-identical before writing.

## Output Contract

Return the target path, backup path, compression status, and any validation failures.

## References

- `README.md` - usage details and examples.
- `SECURITY.md` - safety model for subprocess and file I/O.

Files in this skill

  • README.md5.1 KB
  • SECURITY.md1.5 KB
  • SKILL.md2 KB
  • scripts/__init__.py224 B
  • scripts/__main__.py30 B
  • scripts/benchmark.py2.2 KB
  • scripts/cli.py1.6 KB
  • scripts/compress.py6.8 KB
  • scripts/detect.py4.1 KB
  • scripts/test_caveman.py5.2 KB
  • scripts/validate.py4.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.