tools: Skill for Claude Code

.claude/skills/text-parsers/SKILL.md

text-parsers is a skill for Claude Code from adamw7/tools. It costs 116 tokens per session (4,073 once invoked), scanned C, original, MIT.

Repository instructions for maintaining text readers that parse Markdown, YAML front matter, file imports, and shell commands. They focus on shared readers and the unusual inputs that have caused bugs.

In plain words
What is it for?
Use them when changing MarkdownDocument, MarkdownText, ImportGraph, CommandTokens, FrontMatter, or the code that reads Claude configuration files.
Why use it?
They help prevent different parts of the project from interpreting the same document differently. They also point developers to known failure cases instead of making them rediscover them.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions CLAUDE.md; mentions Claude Code.

This is adamw7/tools's own configuration. It tells Claude Code how to work on tools itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything tools configures →

View source ↗ adamw7/tools
Reuse

Borrowing it

Nothing to install: this file belongs to adamw7/tools. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/adamw7/tools/main/.claude/skills/text-parsers/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/adamw7/tools

Made for: Claude Code.

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 text-parsers

README.md
[![agentmods](https://agentmods.dev/badge/skills/adamw7/tools/text-parsers.svg)](https://agentmods.dev/skills/adamw7/tools/text-parsers)
Your own site
<a href="https://agentmods.dev/skills/adamw7/tools/text-parsers"><img src="https://agentmods.dev/badge/skills/adamw7/tools/text-parsers.svg" alt="Measured on agentmods" height="20"></a>
Per session 116 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,073 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.00116 $0.04073
Opus 5 $0.00058 $0.02037
Sonnet 5 $0.00023 $0.00815
Haiku 4.5 $0.00012 $0.00407

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

Security

Grade C, and why

text-parsers scanned grade C with 1 finding 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 8d 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.

Hidden instructionshighPrompt injection

Directives inside HTML comments, invisible characters or bidirectional overrides are read by the model and not by the person reviewing the file.

``` ``<!--`` ``` sample opened a comment nothing closed. A run nothing closes is ordinary text and the scan carries on past it, so an odd backtick neither swallows the line nor hides a real span later on it. - `write` re
.claude/skills/text-parsers/SKILL.md · 241 lines

How it starts

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

Text Parsers Skill

The claude-code-enforcer rules and the adopt conformer read Markdown, YAML front matter, @path imports and shell hook commands with small readers of their own. Those readers carry the largest share of this repository's shipped defects: FrontMatter and CommandTokens have each been fixed in six or seven separate commits, MarkdownDocument in four or five — several of those twice over, once in the reader and once in the copy ClaudeMdConformer used to carry, which is why the Markdown reader now lives in markdown-common with a single caller-facing copy.

Every one of those fixes was the same thing — real input the reader had not been written for. This skill is the accumulated list, so the next change starts from it instead of rediscovering it.

The one rule that matters most

Change the shared reader, never the caller. MarkdownDocument, FrontMatter, MarkdownText and CommandTokens exist so every rule agrees on what a fence, a key, a code span and a token are. A rule that re-derives one of those locally is how the readers drifted in the first place — a fix landed in one place and the other two callers kept the bug.

Concretely: commit #560 fixed three rules at once (memoryImports, validateFileReferences, forbiddenTokens) because the comment mask they all share was only being consulted by heading detection. The fix was one method exposed on MarkdownDocument, not three patches.

The readers and their invariants

MarkdownDocument

Parses lines plus two masks — fenced code, and HTML comment — once at construction, so structural checks share them.

Invariant Why
A fence closes only on a run of the same character, at least as long, carrying no info string Docs about Markdown nest fences: ~~~ inside ```, ```java inside ````. Closing on the first character ends the block early, then reads the real closer as a fresh opening one and masks the rest of the file as code.
A heading is ATX — #{1,6} then whitespace or end of line #1 rule: run mvn install is prose. Read as an H1 it ends the section above and that section gets reported empty.
Headings are recognised outside fences and outside comments A commented-out section must not satisfy the check that demands it.
Comment state is tracked from every delimiter on the line, not the first characters Superseded: <!-- opens a block. <!-- a --> <!-- b ends open. Both were missed by a startsWith/contains pair.
A comment inside a fence is sample text — the fence wins Ordering matters: commentMask takes insideFence as input.
Fences and indented code are marked in one left-to-right pass, not one after the other Each decides what the other may read. A lone ``` shown four columns in is an indented sample, not an opening fence; marking fences first opens a block nothing closes and masks the rest of the file as code.
The code indent is measured from the enclosing list item's content, not the margin A list item indents its own continuation paragraphs. Measuring from the margin read every such paragraph as code, so a module named only there counted as unmentioned and a forbidden token written there was never seen.
containsInProse skips comments and fences, both directions A commented-out mention must neither satisfy a required-token check nor trip a forbidden-token one.
A blank line and a commented-out line do not settle whether a section has a body A section whose only content is commented out reads as empty, which is what commenting it out meant.

Read the full file on GitHub · 241 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 8d ago First seen · 241 lines · 116 tokens per session scan C d2cecd932e94

Subscribe to this mod's changes

text-parsers is a skill published in the GitHub repository adamw7/tools (11 stars, last pushed today), licensed MIT. It adds 116 tokens to every session and 4,073 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it C with 1 finding (hidden instructions). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

data-report

Turns CSV, Excel, or JSON data into a polished visual report page.

nexu-io/open-design · 18 tokens

file-to-markdown

Turn almost any file into Markdown plus metadata — PDF, Office, HTML, email, archives, images, audio/video, 1000+ formats — powered by Apache Tika, either via the tika-app CLI (zero setup, one file) or a running tika-server (curl, warm process, many calls). Leads with rmeta (structured, embedded-item-aware output) as…

apache/tika · 147 tokens

obsidian

Obsidian vault: search/read/write notes, backlinks, Bases, Canvas.

steipete/agent-scripts · 19 tokens

docetl

Build and run LLM-powered data processing pipelines with DocETL. Use when users say "docetl", want to analyze unstructured data, process documents, extract information, or run ETL tasks on text. Helps with data collection, pipeline creation, execution, and optimization.

ucbepic/docetl · 59 tokens

loopx-doc-registry

Use when a connected LoopX project is asked to read, remember, record, index, register, or use a durable project material such as a Lark/wiki/design doc, research note, SOP, owner packet, migration report, benchmark paper, or external material source. Use even when the user does not mention LoopX or doc registry.

huangruiteng/loopx · 74 tokens

build-with-tinybase

Scaffold, extend, and verify reactive local-first JavaScript or TypeScript applications with TinyBase. Use when choosing TinyBase for in-memory tabular or key-value state, generating an app with create-tinybase, adding schemas or UI bindings, configuring browser or database persistence, configuring MergeableStore…

tinyplex/tinybase · 76 tokens