Ratchet-files skill shrinks oversized files gradually instead of rejecting commits
Overview
A solo founder releases ratchet-files, a skill that prompts an agent to shrink any file over 5,000 tokens a little with each commit until it passes the limit, rather than blocking the commit.
The skill extends Matt Pocock's pre-commit check, which rejects such files outright. The author says the gradual approach lets the limit be added to any repo without a large refactor first. Tokens are counted as bytes divided by four.
Written by AI from the articles below · updated Oct 18, 11:59 PM ET
Check the sources:
Article timeline
The articles in this story. Times are ET.
David@dzhngXRatchet files: a skill that shrinks oversized files gradually instead of rejecting commitsAIThe author built a skill called ratchet-files, an extension of Matt Pocock's pre-commit idea that blocks files over 5,000 tokens, where tokens are bytes divided by four. Instead of hard rejection, the skill prompts the agent to shrink each offending file a little with every commit until it falls under the limit, so the limit can be added to any repo without forcing a large refactor.
Heat Trend
Not enough continuous observations to show a trend yet.