markdown-compression

markdown-compression is a skill for Claude Code, Codex from attilaszasz/sdd-pilot. It costs 26 tokens per session (689 once invoked), scanned A, original, MIT.

A tool for safely shortening approved Markdown documents using fixed rules and validation checks.

In plain words
What is it for?
Use it to compress allowed README, documentation, research, analysis, or manual-test files, and to check whether a target path is permitted.
Why use it?
It makes documentation more compact while protecting files where rewriting could break project workflows or parser-sensitive formats.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions CLAUDE.md; mentions AGENTS.md; mentions Codex.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/attilaszasz/sdd-pilot/markdown-compression
Any agent
npx skills add attilaszasz/sdd-pilot --skill markdown-compression
Clone the repo
git clone --depth 1 https://github.com/attilaszasz/sdd-pilot

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for markdown-compression

README.md
[![agentmods](https://agentmods.dev/badge/skills/attilaszasz/sdd-pilot/markdown-compression.svg)](https://agentmods.dev/skills/attilaszasz/sdd-pilot/markdown-compression)
Your own site
<a href="https://agentmods.dev/skills/attilaszasz/sdd-pilot/markdown-compression"><img src="https://agentmods.dev/badge/skills/attilaszasz/sdd-pilot/markdown-compression.svg" alt="Measured on agentmods" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 689 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00026 $0.00689
Opus 5 $0.00013 $0.00345
Sonnet 5 $0.00005 $0.00138
Haiku 4.5 $0.00003 $0.00069

Measured 3d ago against content hash b12dce395579, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

markdown-compression scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.github/skills/markdown-compression/SKILL.md · 71 lines

How it starts

The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Markdown Compression

Use this only for safe narrative Markdown or explicitly gated governance prose. This is not a general rewrite tool.

Safe Targets

  • README.md
  • docs/**/*.md
  • specs/<feature>/research.md
  • specs/<feature>/analysis-report.md
  • specs/<feature>/manual-test.md

Gated Targets

  • .github/sddp/workflows/implement-tasks/WORKFLOW.md - exact manifest entry; compresses only prose inside <rules> and <workflow> blocks
  • all other governance files require a separate manifest entry and dry-run review before compression

Blocked Targets

  • project-instructions.md, AGENTS.md, CLAUDE.md
  • all unlisted workflow, agent, instruction, and wrapper Markdown under .github/, .agents/, .claude/, .windsurf/, .opencode/, .codex/
  • specs/prd.md, specs/sad.md, specs/dod.md, specs/project-plan.md, specs/adrs/*.md, specs/plan/*.md
  • feature-workspace parser-sensitive artifacts: spec.md, plan.md, tasks.md, qc-report.md, checklists/*.md, autopilot-log.md

Process

  1. Run node scripts/compress-markdown.mjs --check <path> to confirm the path is allowlisted or explicitly gated and validator-safe.
  2. For preview only, run node scripts/compress-markdown.mjs --stdout <path>; gated targets automatically use narrative-only mode.
  3. Review the proposed diff. For a manual narrative-only preview, add --narrative-only.
  4. To write the compressed file, run node scripts/compress-markdown.mjs <path>.
  5. Run node scripts/compress-markdown.mjs --idempotent <path> after writing and in CI.
  6. The script creates <name>.original.md once, then preserves it on later runs.
  7. If validation fails, stop. Do not write partial output.
  8. Symbolic-link paths are blocked; authorization uses the canonical target path.

Validation Guarantees

The validator preserves these elements exactly:

  • frontmatter
  • headings
  • fenced code blocks
  • inline code
  • bare URLs and Markdown links
  • requirement and task identifiers
  • table rows
  • checkbox lines
  • Markdown list prefixes and indented lines
  • HTML comment blocks
  • <rules> and <workflow> tag lines
  • every line outside gated narrative blocks
  • HTML blocks, tables, nested blockquotes, and ordered-parenthesis lists
  • original line endings

Read the full file on GitHub · 71 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 71 lines · 26 tokens per session scan A b12dce395579

Subscribe to this mod's changes

markdown-compression is a skill published in the GitHub repository attilaszasz/sdd-pilot (95 stars, last pushed yesterday), licensed MIT. It adds 26 tokens to every session and 689 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

code-review-hardening

Use this skill for rigorous, structured code review with a self-repair loop. Applies change-type-aware strategies (feat, fix, hotfix, refactor, migrate, docs). Findings are severity-classified, then auto-fixed where possible. Triggers on PR reviews, code review requests, or when reviewing any change set.

lindoelio/spec-driven-steroids · 70 tokens

contextual-stewardship

Use this skill when the user makes a technical decision, establishes a new pattern, defines business rules, or explicitly asks to remember or save a guideline. Also use this skill when you are about to implement a feature, write code, plan an architecture, or make a technical decision - you MUST retrieve contextual…

lindoelio/spec-driven-steroids · 104 tokens

project-guidelines-writer

Use this skill when the user wants repository guidance documents generated or refreshed, including AGENTS.md, CONTRIBUTING.md, STYLEGUIDE.md, TESTING.md, ARCHITECTURE.md, and SECURITY.md. It analyzes the repository, generates all six guideline files by default, prefers managed-section updates for existing files, and…

lindoelio/spec-driven-steroids · 80 tokens

quality-grading

Use this skill to grade code, specifications, or design documents across four quality dimensions using a 1-5 scoring scale. In grade-and-fix mode, the skill auto-improves artifacts scoring below 5 without prompting. Invoke when you want consistent quality assessment on design, implementation, or specification with…

lindoelio/spec-driven-steroids · 73 tokens

spec-driven-task-decomposer

Use this skill when approved requirements and design need to be decomposed into tasks.md for Phase 3 of a Spec-Driven change. It creates atomic, traceable implementation and testing tasks, validates the plan, and should not be used to design architecture or write implementation code.

lindoelio/spec-driven-steroids · 61 tokens

universal-live-check

Universal live-check framework for coding agents. Executes incremental, deterministic validation across all software domains (CLI, backend, frontend, mobile, embedded, libs). Change-type-aware (feat, fix, hotfix, refactor, migrate, docs). Triggers whenever an agent needs to validate code quality, run linting, perform…

lindoelio/spec-driven-steroids · 108 tokens