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.
npx skills add chen3feng/agent-skills --skill safe-markdown-auto-fixgit clone --depth 1 https://github.com/chen3feng/agent-skillsWrote 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.
[](https://agentmods.dev/skills/chen3feng/agent-skills/safe-markdown-auto-fix)<a href="https://agentmods.dev/skills/chen3feng/agent-skills/safe-markdown-auto-fix"><img src="https://agentmods.dev/badge/skills/chen3feng/agent-skills/safe-markdown-auto-fix/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/chen3feng/agent-skills/safe-markdown-auto-fix"><img src="https://agentmods.dev/badge/skills/chen3feng/agent-skills/safe-markdown-auto-fix.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00026 | $0.00875 |
| Opus 5.5 | $0.00010 | $0.00350 |
| Sonnet 5.5 | $0.00005 | $0.00175 |
| Haiku 4.5 | $0.00003 | $0.00088 |
Grade A, and why
safe-markdown-auto-fix 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 3mo 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.
How it starts
The opening of the file, as written. The whole thing — 100 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Safe Markdown auto-fix
When to use
You're writing (or reviewing) a regex-based fixer for Markdown —
spacing rules, typography, terminology normalization. Applies to any
lint-and-fix tool, including the cndocstyle package shipped with
cn-doc-style-guide.
Problem
A naive re.sub over the whole file will cheerfully mangle:
- Fenced code blocks (
): inserting "helpful" spaces in the middle of a Python string breaks the program. - Inline code spans (
`foo_bar`): adding space around_ruins identifiers. - Link URLs (
[text](https://…)): even reading URLs as prose produces false positives like "space between CJK and ASCII" inside a percent-encoded path. - HTML tags / comments:
<img alt="你好World">is prose inside HTML, but the tag itself must stay intact.
Solution
Always tokenize the file into "protected" and "prose" regions before applying any substitution. A minimal protection list:
PROTECT = [
# fenced code blocks, greedy across lines
re.compile(r"```[\s\S]*?```", re.MULTILINE),
# indented code blocks (4+ leading spaces at start of line)
re.compile(r"(?:^|\n)(?: {4,}|\t).+", re.MULTILINE),
# inline code
re.compile(r"`[^`\n]+`"),
# link / image URLs — keep the URL, allow fixing the text
re.compile(r"\]\([^)\n]+\)"),
# raw HTML tags and comments
re.compile(r"<!--[\s\S]*?-->"),
re.compile(r"<[a-zA-Z/][^>]*>"),
]
Then:
- Walk the text, carving out every match into a
placeholder(e.g.\x00PROTECT_N\x00) and storing the original. - Run your prose-level substitutions on the placeholder-laced text.
- Restore placeholders.
For a fixer it's also important to:
- Default to dry-run. Print a unified diff; require
--applyto write. - Be idempotent. Running the tool twice must not change output.
- Fail closed. If in doubt (ambiguous context, mixed-script identifiers), leave the text untouched and log a warning rather than silently "correcting" it.
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.
- 3mo ago First seen · 100 lines · 26 tokens per session scan A c2b9a322f12b
safe-markdown-auto-fix is a skill published in the GitHub repository chen3feng/agent-skills (5 stars, last pushed 6mo ago), licensed Apache-2.0. It adds 26 tokens to every session and 875 once invoked, about $0.0001 per session on Opus 5.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-08-31.
safe-markdown-auto-fix compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| safe-markdown-auto-fixchen3feng/agent-skills | Skill | 5 | 6mo ago | Apache-2.0 | A | 26 | Claude Code, Codex |
| create-payment-credentialvercel/eve | Skill | 6.1k | today | Apache-2.0 | A | 23 | Claude Code, Codex |
| investigatevercel/eve | Skill | 6.1k | today | Apache-2.0 | A | 25 | Claude Code, Codex |
| reviewvercel/eve | Skill | 6.1k | today | Apache-2.0 | A | 31 | Claude Code, Codex |
| hypothesis-validationvercel/eve | Skill | 6.1k | today | Apache-2.0 | A | 28 | Claude Code, Codex |
| web-scrapingharehare/mq | Skill | 1.1k | today | MIT | A | 89 | Claude Code, Codex |
| regex-masteryalibaba/anolisa | Skill | 688 | 8d ago | Apache-2.0 | A | 60 | Claude Code, Codex |