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 agentmods add instructions/tanem/svg-injector/agents-mdgit clone --depth 1 https://github.com/tanem/svg-injectorWrote 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/instructions/tanem/svg-injector/agents-md)<a href="https://agentmods.dev/instructions/tanem/svg-injector/agents-md"><img src="https://agentmods.dev/badge/instructions/tanem/svg-injector/agents-md.svg" alt="Measured on agentmods" 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.02583 | $0.02583 |
| Opus 5 | $0.01291 | $0.01291 |
| Sonnet 5 | $0.00517 | $0.00517 |
| Haiku 4.5 | $0.00258 | $0.00258 |
Grade A, and why
svg-injector AGENTS.md 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 6d 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 — 203 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md
Rules for coding agents that the code and config don't already state. Keep it that way: a constraint that can live in a comment next to the thing it constrains belongs there, not here.
Writing
- NZ English everywhere ("colour", "behaviour", "initialise").
- Match a document's length to what it needs. Cover the substance, then stop: no filler sections, restated summaries or boilerplate.
- Simple, direct technical language. No marketing speak.
- Commit subjects are one capitalised line,
git log --onelinestyle. Add a body whenever the change had a reason the diff does not show: what it fixes, what it rules out, what constraint forced the shape it has. Mechanical changes need none. - No conventional-commit prefixes (
feat:,fix:,chore(deps):) in commit subjects or PR titles. Write a plain capitalised sentence. Nothing reads the prefix: the version bump comes from the PR label, and renovate is set tosemanticCommits: "disabled"to match. - PR titles are copied verbatim into the generated release notes, so write them as the changelog line you want readers to see.
- Hard-wrap commit message bodies at 72 columns;
git logdoes not reflow them. Do not hard-wrap PR or issue descriptions: GitHub reflows markdown, and its web editor leaves wrapped source ragged once anyone edits it. README.mdfollows standard-readme. Per-feature detail belongs inexamples/*/README.md, linked from there.README.mdstates current behaviour;MIGRATION.mdstates what changed and keeps the upgrade steps in full. Neither re-derives the other.- Code comments record non-obvious behaviour, constraints and decisions, not what the line already says.
Architecture
SVGInjector normalises its argument, then runs one pipeline per element:
split the sprite fragment off the URL, load, transform, swap.
svg-injector.tsowns theafterEachandafterAllaccounting. Every path out ofinjectElement, errors included, calls back exactly once. Add one that doesn't andafterAllsilently never fires.defer.tsenforces the callback timingsvg-injector.tsdocuments. A path already running inside an XHR event or a deferred task calls back directly, which is whyload-svg-uncached.tsand thehandleLoadedSvgerror paths hold nodefer.inject-element.tsis that per-element pipeline, and the only module that chooses a load path.parse-data-url.tsinterceptsdata:image/svg+xmlbefore any request is made, so data URLs never reach the XHR layer.load-svg-cached.tsandload-svg-uncached.tswrapmake-ajax-request.ts. The cache key is the URL with the fragment stripped, so every symbol taken from one sprite shares a single request.extract-symbol.ts,renumerate-svg-iri-elements.tsandeval-svg-scripts.tsare the transform steps, applied in that order.
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.
- 6d ago First seen · 203 lines · 2,583 tokens per session scan A 23bc0568a64b
svg-injector AGENTS.md is an instructions file published in the GitHub repository tanem/svg-injector (109 stars, last pushed 5d ago), licensed MIT. It adds 2,583 tokens to every session, about $0.0129 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-08-30.
Other instructions, from other repositories
react-svg AGENTS.md
AGENTS.md instructions for tanem/react-svg, covering agents.md, writing, architecture, build & test and releases.
react-svg CLAUDE.md
Claude Code instructions for tanem/react-svg, a project described as: :art: A React component that injects SVG into the DOM.
electron CLAUDE.md
Claude Code instructions for electron/electron, covering electron development guide, running nodemodules binaries, project overview, directory structure and build tools setup.
snag AGENTS.md
AGENTS.md instructions for p3bot/snag, covering agents.md, project overview, setup commands, clone repository and install dependencies.
mis-recursos-webdev AGENTS.md
AGENTS.md instructions for Alplox/mis-recursos-webdev, covering agents.md — mis recursos web dev, 📋 stack, 🏗️ estructura del proyecto, 🧠 source of truth and estructura del readme.
notes AGENTS.md
Instructions for sabertaz/notes, covering agents.md, project overview, development commands, content guidelines and commit guidelines.