Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Trim

ASecurity

Shorten docs, prompts, skills, or configs without losing meaning or behavior.

10 stars
0 votes
0 copies
0 views
Added 10/4/2026
ai-agentsgobashexpressdockergitsecuritydocumentation

Security Analysis

A100/100

Scanned 10/6/2026

$npx -y skills add fmind/dot --skill trim --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Trim?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Trim
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/fmind-trim/badge)](https://www.skillsdirectory.com/skills/fmind-trim)

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

Download with Pro
Files
SKILL.md
---
name: trim
description: "Shorten docs, prompts, skills, or configs without losing meaning or behavior."
license: MIT
metadata:
  kind: task
  author: Médéric HURIER (Fmind)
  source: github.com/fmind/dot/tree/main/skills/trim
  created: "2026-10-04"
  updated: "2026-10-05"
---

# Trim

Treat `/trim <path>` or "too verbose", "too complex", "simplify this" as a request to remove words, lines, and settings that carry nothing, while every fact, behavior, and the author's voice survive. Trimming is not summarizing: when the text is the deliverable (an article, a talk) and the user did not ask for a length, tighten sentences but keep its substance and length class. Arguments can set a target (`to 300 words`, `-40%`) or a scope. For code, [repository-maintenance](../repository-maintenance/SKILL.md) owns dead code and abstractions; apply these rules only with tests proving behavior.

## Workflow

1. **Measure**: record lines, words, and estimated tokens (characters / 4) before editing; for skill catalogs and instruction files also run `dot agent context --project . --details` (add `--source .` inside the fmind/dot checkout).

   ```bash
   wc -lwm <path>
   ```

1. **Map what must survive**: list each claim, rule, number, command, flag, link, warning, and authority boundary. For configuration, capture the effective result so the trim can prove it changed nothing: `mise cfg` and `mise settings`, `dprint resolved-config`, `ruff check --show-settings <file>`, `docker compose config`, `chezmoi cat <target>`, or `yq -o json` for plain data.
1. **Cut, in this order**:
   - **Duplication**: the same rule stated twice; keep it at its owner and link from elsewhere.
   - **Restated defaults**: settings equal to the installed tool's default, after verifying that default in its current docs or `--help` (defaults change between versions).
   - **Filler**: introductions, hedges, recaps, "note that", tool narration, history ("previously…"), and generic tutorials the reader's tools already know.
   - **Dead entries**: options for tools, paths, or features that no longer exist (prove absence with `rg` or `fd`).
   - **Verbose constructions**: lists that can be one sentence, sentences that can be a clause, examples that only repeat the rule.
1. **Never cut**: facts with their evidence, numbers and dates, exact commands and flags, non-obvious gotchas with their reason, security and authority boundaries, links and citations, required structure (frontmatter, anchored headings, generated-index markers), the documentation URL comment at the top of a configuration, comments explaining a non-default choice, and anything the user asked to keep. Preserve the author's voice and stance; do not rewrite into a different style.
1. **Prove equivalence**: re-capture the effective configuration and diff it (it must be identical); re-run affected checks and tests; for prose, walk the survival list and confirm each item is still present or deliberately dropped with a reason. Run the repository's formatter and link checks for edited files.
1. **Report**: before/after lines, words, and tokens with the percentage, the categories removed, and any candidate cut you kept because it looked load-bearing. Ask before removing anything ambiguous instead of guessing.

## Gotchas

- **Short is not simple**: replacing three explicit lines with a clever one-liner or a dense regular expression makes the file harder to maintain; prefer deleting to compressing.
- **Defaults drift**: a setting equal to today's default can still be intentional pinning; keep it when a comment or commit explains it.
- **Search before rewording shared phrases**: phrases reused verbatim across files (triggers, error messages, test fixtures) may be matched by tests or other agents; search before rewording.

## Documentation

- Companion skills: [repository-docs](../repository-docs/SKILL.md) (documentation ownership), [skillify](../skillify/SKILL.md) (skill size rules), [prompt-design](../prompt-design/SKILL.md) (application prompts).

Attribution

fmindfmind
View sourceSee grades on GitHubMore from fmind →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

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

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698431 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →