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 CodingFeng101/CanvasAnvil --skill diagram-skillgit clone --depth 1 https://github.com/CodingFeng101/CanvasAnvilWrote 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/codingfeng101/canvasanvil/diagram-skill)<a href="https://agentmods.dev/skills/codingfeng101/canvasanvil/diagram-skill"><img src="https://agentmods.dev/badge/skills/codingfeng101/canvasanvil/diagram-skill/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/codingfeng101/canvasanvil/diagram-skill"><img src="https://agentmods.dev/badge/skills/codingfeng101/canvasanvil/diagram-skill.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.00055 | $0.01399 |
| Opus 5.5 | $0.00022 | $0.00560 |
| Sonnet 5.5 | $0.00011 | $0.00280 |
| Haiku 4.5 | $0.00006 | $0.00140 |
Grade A, and why
diagram-skill 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 yesterday.
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 — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Diagram Skill
Trigger
Use when the user asks for a diagram, flowchart, architecture diagram, network diagram, ER diagram, BPMN diagram, or a cloud/infrastructure diagram, or mentions draw.io, diagrams.net, drawio, or a .drawio file.
Order
- Classify the request.
- Read the required references.
- Plan: in 1–3 sentences, say what the diagram shows, its layout kind, its groups and its main flow (for an edit, what changes and why). Show the plan to the user.
- Produce or modify draw.io XML, laid out on a grid for that layout kind.
- Write the XML to a
.drawiofile (a scratch file if file writes are limited). - Validate the structure with
scripts/validate-drawio-xml.mjs. - Check the layout with
scripts/check-layout.mjs. Fix every error it reports and run it again, keeping the arrangement while fixing. - Build an online editor URL and open it in the agent's built-in browser.
- Return the plan, the XML code, the
.drawiopath, the layout score and the online editor link.
Classification
prompts/display.md- new diagram
- major rewrite
- major relayout
- any case where local editing is fragile
prompts/edit.md- current XML exists
- change is small and precise
- ids can remain stable
prompts/append.md- earlier XML output was truncated
prompts/router.md- routing decision needed before generation
Required References
references/xml-rules.mdreferences/layout-rules.mdreferences/edit-rules.mdreferences/shape-library-index.mdreferences/shape-libraries/<library>.md
Read the library file before generating any library-backed diagram.
Do not guess undocumented shape-library prefixes or shape names.
XML Contract
- New diagrams should normally produce a full
<mxGraphModel>with<root>. - Every
mxCellis written flat inside<root>; nesting is expressed withparent. - Root cells must exist:
<mxCell id="0"/><mxCell id="1" parent="0"/>
- Every id must be unique;
0and1are reserved, never used for a shape or an edge. - Groups are real containers:
container=1(orswimlane), with members usingparent="<group id>"and coordinates relative to the group. - Edges use
parent="1", and theirsourceandtargetmust reference existing ids. - Preserve existing ids during local edits unless renaming is explicitly required.
- Escape XML attribute values correctly.
- Do not emit XML comments.
What ships with it
45 files 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.
- agents/openai.yaml 339 B
- package.json 260 B
- prompts/append.md 641 B
- prompts/display.md 2.0 KB
- prompts/edit.md 1.8 KB
- prompts/router.md 593 B
- references/edit-rules.md 1.3 KB
- references/layout-rules.md 4.6 KB
- references/shape-libraries/alibaba_cloud.md 7.9 KB
- references/shape-libraries/android.md 1.3 KB
- references/shape-libraries/arrows2.md 613 B
- references/shape-libraries/atlassian.md 663 B
- references/shape-libraries/aws4.md 22 KB
- references/shape-libraries/azure2.md 11 KB
- references/shape-libraries/basic.md 744 B
- references/shape-libraries/bpmn.md 1.2 KB
- references/shape-libraries/cabinets.md 1.5 KB
- references/shape-libraries/cisco19.md 4.7 KB
- references/shape-libraries/citrix.md 2.0 KB
- references/shape-libraries/electrical.md 825 B
- references/shape-libraries/floorplan.md 914 B
- references/shape-libraries/flowchart.md 869 B
- references/shape-libraries/fluidpower.md 3.0 KB
- references/shape-libraries/gcp2.md 5.8 KB
- references/shape-libraries/infographic.md 525 B
- references/shape-libraries/kubernetes.md 761 B
- references/shape-libraries/lean_mapping.md 585 B
- references/shape-libraries/material_design.md 5.3 KB
- references/shape-libraries/mscae.md 601 B
- references/shape-libraries/network.md 1.2 KB
- references/shape-libraries/openstack.md 786 B
- references/shape-libraries/pid.md 579 B
- references/shape-libraries/rack.md 1.1 KB
- references/shape-libraries/README.md 5.1 KB
- references/shape-libraries/salesforce.md 1.8 KB
- references/shape-libraries/sap.md 4.7 KB
- references/shape-libraries/sitemap.md 875 B
- references/shape-libraries/vvd.md 1.9 KB
- references/shape-libraries/webicons.md 2.5 KB
- references/shape-library-index.md 1.0 KB
- references/xml-rules.md 3.8 KB
- scripts/build-drawio-url.mjs 2.9 KB runs code
- scripts/check-layout.mjs 14 KB runs code
- scripts/validate-drawio-xml.mjs 2.9 KB runs code
- vendor/pako_deflate.min.cjs 27 KB runs code
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.
- yesterday Changed · +18 lines c1a5ba422e36
- 11d ago First seen · 109 lines · 55 tokens per session scan A 2e91f28d6ed6
diagram-skill is a skill published in the GitHub repository CodingFeng101/CanvasAnvil (160 stars, last pushed yesterday), licensed MIT. It adds 55 tokens to every session and 1,399 once invoked, about $0.0002 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-10-27.
diagram-skill compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| diagram-skillCodingFeng101/CanvasAnvil | Skill | 160 | yesterday | MIT | A | 55 | Codex |
| drawio-skillAgents365-ai/drawio-skill | Skill | 11k | 5d ago | MIT | A | 107 | Claude Code, Codex |
| cocosketchSnowflake-Labs/cocoplus | Skill | 727 | 2d ago | MIT | A | 20 | Claude Code |
| fin-arch-diagramcsmar432/finai-research | Skill | 109 | 3d ago | MIT | A | 72 | Cursor |
| bruce-drawiobruc3van/bruce-drawio | Skill | 114 | 2mo ago | MIT | A | 129 | Claude Code, Codex |
| FlowForgewentong2022-arch/flowforge-skill | Skill | 139 | 4mo ago | MIT | A | 153 | Claude Code |
| excalidrawAgents365-ai/365-skills | Skill | 100 | 4d ago | none | A | 73 | Claude Code |