md-language-check
When to use
Fire this skill before writing or saving any .md file under:
src/ (source of truth — skills, rules, commands, guidelines, templates, contexts)
dist/agent-src/ (condensed projection)
.augment/ (local agent projection)
agents/ (project-specific roadmaps, contexts, sessions)
Per language-and-tone § ".md files
are ALWAYS English" and § Detection heuristic, every .md file in those
trees must be English. Bilingual content lives only in labeled
DE: … · EN: … anchor blocks.
Do NOT use when:
- Editing project content outside the trees listed above (READMEs of
consumer projects, application docs that follow a different policy)
- Reviewing chat history files (
agents/runtime/.agent-chat-history is JSONL, not .md)
- Inspecting non-
.md files — the checker rejects them with a warning
Procedure
1. Identify the file(s) about to be saved
Collect the absolute or repo-relative path of every .md file the
agent is about to create or modify in this turn. Multiple files in
one turn → pass them all to a single invocation.
2. Run the checker
./scripts-run src/scripts/check_md_language <path> [<path> …] [--format json]
Exit codes:
0 → no German content detected, save proceeds
1 → violations found, save is blocked until they are resolved
or explicitly suppressed
3 → internal error (unreadable file, decode failure)
3. Resolve findings
For every violation:
| Kind |
Likely cause |
Fix |
umlaut |
German prose leaked into body text |
Translate the sentence to English |
de_word |
German function word in unquoted prose |
Translate; or move into a DE: … · EN: … block if intentional bilingual anchor |
If the line is meta-documentation that must quote German tokens
(e.g. the detection heuristic in language-and-tone.md itself),
append <!-- md-language-check: ignore --> at the end of that single
line — never as a wholesale silencer.
4. Re-run and confirm
After every fix, re-run the checker on the same paths. Save only
proceeds on exit 0.
Allowed escape hatches
- Labeled anchor block — lines starting with
DE: / - DE: /
* DE: (and the same for EN:) are skipped automatically. Use this
for intent-based opt-in / opt-out anchors.
- Fenced code blocks —
\`` … ```` content is exempt, so
shell snippets, JSON fixtures, and quoted user input in code
blocks pass through untouched.
- Inline code — backtick spans are stripped before scanning;
identifiers like
für_test inside backticks do not flag.
- Per-line marker — append
<!-- md-language-check: ignore -->
to a line that genuinely needs to quote a German token in body
prose (rare; reserved for the rules that document the heuristic).
Output format
- One-line summary:
clean or N violation(s) found
- Per violation:
file:line — kind \match`` plus the offending line
- Next action: translate, move into a
DE:/EN: block, add the
per-line ignore marker, or revert the change
Gotchas
- The checker scans
.md files only; passing a non-.md path emits a
warning and skips it
- The detection word list is intentionally short and conservative —
a clean run is necessary but not sufficient; the agent still
owns the final language judgement
- Frontmatter (
--- … --- at file head) is exempt; descriptions and
YAML keys can use international characters where the schema allows
Do NOT
- Do NOT silence the checker by deleting trigger words from
src/scripts/check_md_language.ts; extend the allow-list (anchor
blocks, ignore marker) instead
- Do NOT add the ignore marker to body prose just to push a save
through; the marker is for meta-documentation that quotes tokens,
not a generic mute
- Do NOT skip the gate "because the file is small" —
language-and-tone
§ Detection heuristic applies to every save under the four trees
Cloud Behavior
On cloud surfaces (Claude.ai Web, Skills API) the checker script is
not shipped, so this skill is inert — the agent applies the
heuristic from language-and-tone
manually before emitting the file.
1---2name: md-language-check3description: Use BEFORE saving any .md under .augment/, dist/agent-src*/, or agents/ — scans umlauts, German function words, and German phrases outside DE:/EN: anchor blocks. Hard gate per language-and-tone.4---56# md-language-check78## When to use910Fire this skill **before** writing or saving any `.md` file under:1112- `src/` (source of truth — skills, rules, commands, guidelines, templates, contexts)13- `dist/agent-src/` (condensed projection)14- `.augment/` (local agent projection)15- `agents/` (project-specific roadmaps, contexts, sessions)1617Per [`language-and-tone`](../../rules/language-and-tone.md) § "`.md` files18are ALWAYS English" and § Detection heuristic, every `.md` file in those19trees must be English. Bilingual content lives only in labeled20`DE: … · EN: …` anchor blocks.2122Do NOT use when:2324- Editing project content outside the trees listed above (READMEs of25 consumer projects, application docs that follow a different policy)26- Reviewing chat history files (`agents/runtime/.agent-chat-history` is JSONL, not `.md`)27- Inspecting non-`.md` files — the checker rejects them with a warning2829## Procedure3031### 1. Identify the file(s) about to be saved3233Collect the absolute or repo-relative path of every `.md` file the34agent is about to create or modify in this turn. Multiple files in35one turn → pass them all to a single invocation.3637### 2. Run the checker3839```bash40./scripts-run src/scripts/check_md_language <path> [<path> …] [--format json]41```4243Exit codes:4445- `0` → no German content detected, save proceeds46- `1` → violations found, save is **blocked** until they are resolved47 or explicitly suppressed48- `3` → internal error (unreadable file, decode failure)4950### 3. Resolve findings5152For every violation:5354| Kind | Likely cause | Fix |55|---|---|---|56| `umlaut` | German prose leaked into body text | Translate the sentence to English |57| `de_word` | German function word in unquoted prose | Translate; or move into a `DE: … · EN: …` block if intentional bilingual anchor |5859If the line is meta-documentation that **must** quote German tokens60(e.g. the detection heuristic in `language-and-tone.md` itself),61append `<!-- md-language-check: ignore -->` at the end of that single62line — never as a wholesale silencer.6364### 4. Re-run and confirm6566After every fix, re-run the checker on the same paths. Save only67proceeds on exit `0`.6869## Allowed escape hatches7071- **Labeled anchor block** — lines starting with `DE:` / `- DE:` /72 `* DE:` (and the same for `EN:`) are skipped automatically. Use this73 for intent-based opt-in / opt-out anchors.74- **Fenced code blocks** — `\`\`\` … \`\`\`` content is exempt, so75 shell snippets, JSON fixtures, and quoted user input in code76 blocks pass through untouched.77- **Inline code** — backtick spans are stripped before scanning;78 identifiers like `für_test` inside backticks do not flag.79- **Per-line marker** — append `<!-- md-language-check: ignore -->`80 to a line that genuinely needs to quote a German token in body81 prose (rare; reserved for the rules that document the heuristic).8283## Output format84851. One-line summary: `clean` or `N violation(s) found`862. Per violation: `file:line — kind \`match\`` plus the offending line873. Next action: translate, move into a `DE:`/`EN:` block, add the88 per-line ignore marker, or revert the change8990## Gotchas9192- The checker scans `.md` files only; passing a non-`.md` path emits a93 warning and skips it94- The detection word list is intentionally short and conservative —95 a clean run is **necessary but not sufficient**; the agent still96 owns the final language judgement97- Frontmatter (`--- … ---` at file head) is exempt; descriptions and98 YAML keys can use international characters where the schema allows99100## Do NOT101102- Do NOT silence the checker by deleting trigger words from103 `src/scripts/check_md_language.ts`; extend the allow-list (anchor104 blocks, ignore marker) instead105- Do NOT add the ignore marker to body prose just to push a save106 through; the marker is for meta-documentation that quotes tokens,107 not a generic mute108- Do NOT skip the gate "because the file is small" — `language-and-tone`109 § Detection heuristic applies to every save under the four trees110111## Cloud Behavior112113On cloud surfaces (Claude.ai Web, Skills API) the checker script is114not shipped, so this skill is **inert** — the agent applies the115heuristic from [`language-and-tone`](../../rules/language-and-tone.md)116manually before emitting the file.