Skill-injection layer silently strips bare $ immediately followed by a digit from SKILL.md content

Resolved 💬 0 comments Opened Jul 7, 2026 by Choppopotomus Closed Jul 13, 2026

When a skill is invoked, the text rendered into the conversation turn has any bare $ that is immediately followed by a digit (09, no {}) silently stripped — the $ and digit both vanish, with no error surfaced.

Confirmed via a live data-loss incident: a skill's awk snippet used substr($2,4,10) for date-field extraction. The file on disk (verified via direct Read) had the correct code, but the text injected into the conversation turn rendered as substr(,4,10) — silently missing the $2 argument. Executing the injected text verbatim (rather than the file) ran the corrupted awk command live and mass-deleted changelog entries.

Also reproduced with Postgres parameterized placeholders ($1, $2, $3) and with plain prose dollar amounts ($100/mo) — all three patterns lost the $ + digit sequence in the rendered turn while the source file was untouched.

Workaround in use: avoid bare $<digit> in skill markdown — wrap in braces/parens where the target syntax allows ($(N) for awk), or move parameterized code out of the skill prompt into an executed script file so the placeholders are never re-rendered through the injection pipeline.

Would help to know: is this a markdown-rendering step, a prompt-templating step, or something else in the injection pipeline? A repro skill can be provided on request.

View original on GitHub ↗