context-crusher

Installation
SKILL.md

Context Crusher Skill

The most expensive tokens in agent work are the ones nobody reads: 300 identical JSON rows when the schema plus three samples would do, a log where one error hides among four hundred heartbeats, a file pasted whole for one relevant section. This skill crushes those structurally — schema + head/tail samples + numeric stats for JSON arrays, dedupe-with-counts plus guaranteed error-line survival for logs, head/tail windowing for text — with a deterministic stdlib script, no model call, no summarization risk. The information that defines meaning survives; the repetition that defines cost doesn't.

What This Skill Produces

  • The crushed artifact — the compressed version, with its token math in the header (~6,000 → ~130 is typical for uniform JSON)
  • The crush decision — what to crush, what to keep raw, and what to link instead of load
  • The escape hatch — every crush names how to fetch the original when a detail turns out to matter
  • The pipeline habit — where in the agent's workflow the crush step belongs (between tool and context, always)

Required Inputs

Ask for these if not provided:

  • The payload — the JSON/log/text (or its path), and roughly how it will be used ("I need the error" vs. "I need every row" are opposite answers)
  • The repetition question — is this data uniform (crushable to schema+stats) or is each row genuinely distinct (crushing loses signal — keep or filter instead)?
  • The journey stage — one-shot analysis (crush hard) vs. data the conversation will keep querying (crush to an index, keep the original fetchable)

Programmatic Helper

Installs
2
GitHub Stars
1.3K
First Seen
Aug 13, 2026
context-crusher — mohitagw15856/pm-claude-skills