trim

Trim a named file to its smallest form without losing actionable facts or changing behavior.

Updated Aug 10, 2026
One-click install
npx skills add https://github.com/ledtorch/coding-agent-workflow --skill trim-ledtorch
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: trim
Source: https://github.com/ledtorch/coding-agent-workflow/tree/main/skills/trim
Command: npx skills add https://github.com/ledtorch/coding-agent-workflow --skill trim-ledtorch

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Documentation and code files accumulate bloat over time — restated facts, embedded changelogs, dead references, and comments that earn nothing — making them hard to maintain and easy to misread. This Skill distills a named file to its smallest, highest-signal form while guaranteeing zero information loss and identical observable behavior. ## Core Features & Use Cases - Eleven bloat patterns with detection commands: Detects wall-of-text paragraphs, restated facts, decision archaeology, embedded changelogs, dead §refs, redundant CSS inheritance, Figma node ids, and finished todos using concrete grep/awk commands. - Zero-information-loss guarantee: Lists load-bearing facts before editing and verifies each one survives after rewriting, with mandatory link/anchor resolution checks. - Multi-file group trims: Builds a trim map across multiple targets so each fact gets exactly one home with one-line pointers elsewhere. - Use Case: A 400-line conventions doc has grown contradictory and repetitive. Run the trim command on it to get a proposed restructure, then a verified rewrite that cuts 40% of the lines while keeping every contract, guard, and file:line reference intact. ## Quick Start Ask the agent to trim references/development/conventions.md to its smallest form without losing any actionable facts.

Frequently Asked Questions about trim

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

FAQPage Schema
How do I reduce a bloated markdown documentation file without losing information?

Run the trim command on the target file, which first lists all load-bearing facts, detects eleven bloat patterns with grep commands, then rewrites the file and verifies every fact still appears. Files over 150 lines require approving a proposed structure before any rewrite.

How to remove redundant CSS declarations that restate inherited values?

The trim skill detects inherited-property declarations like color and font-size that an ancestor already provides, then proves redundancy with getComputedStyle comparison before deleting. It keeps declarations for teleported content, shared components, and theme-conditional ancestors.

Can I trim multiple files at once?

Yes, multiple targets are handled as one group trim, not separate solo trims. The skill builds a trim map first, giving each cross-file fact a single home with one-line pointers elsewhere, and orders edits so pointer files are trimmed after the fact's home file settles.

Does trimming a file ever change code behavior or public contracts?

No, observable behavior, public contracts, and types must come out identical — that is the defining test of the command. Code must still build and lint after trimming, and any symbol must be grep-verified as unused repo-wide before deletion.

What content is never cut during a documentation trim?

Known-gap warnings, unresolved TODOs, and guards against re-introducing removed things are never cut, since they exist because someone got it wrong once. Exact file:line references, contracts, invariants, and acceptance checks are also always preserved.