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 skills/openknots/okcode/architecture-diagramnpx skills add OpenKnots/okcode --skill architecture-diagramgit clone --depth 1 https://github.com/OpenKnots/okcodeWrote 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/openknots/okcode/architecture-diagram)<a href="https://agentmods.dev/skills/openknots/okcode/architecture-diagram"><img src="https://agentmods.dev/badge/skills/openknots/okcode/architecture-diagram.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 | $0.00012 | $0.01329 |
| Opus 5 | $0.00006 | $0.00665 |
| Sonnet 5 | $0.00002 | $0.00266 |
| Haiku 4.5 | $0.00001 | $0.00133 |
Grade A, and why
architecture-diagram 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 4d 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 — 130 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Architecture Diagram Generator
When to use this skill
- When the user asks for an architecture diagram, system diagram, or component visualization.
- When updating READMEs that would benefit from visual architecture documentation.
- When comparing architectural alternatives visually (like the telemetry-architecture-comparison pattern).
- When the user wants to visualize data flow, package dependencies, or tech stack layers.
What this skill does
Generates publication-quality PNG architecture diagrams using Python + matplotlib. Diagrams use a consistent visual language: colored rounded boxes for components, styled arrows for data flow, dashed boundaries for service groups, and score badges for comparisons.
Implementation
Step 1: Identify the diagram type
Determine which diagram pattern fits the request:
| Pattern | When to use | Example |
|---|---|---|
| High-level architecture | Full system overview with all components | high-level-architecture.png |
| Request/event flow | Show how data moves through a pipeline | server-request-flow.png |
| Package dependencies | Show import/dependency relationships | package-dependencies.png |
| Event flow | Show event sourcing or pub/sub patterns | orchestration-event-flow.png |
| Tech stack | Layered technology overview | tech-stack.png |
| Architecture comparison | Compare N alternatives with scores | telemetry-style comparison grid |
Step 2: Use or extend the generator script
The diagram generator lives at scripts/generate-architecture-diagrams.py. It provides reusable primitives:
from generate_architecture_diagrams import (
draw_box, # Rounded colored rectangle with label + sublabel
draw_arrow, # Styled arrow with optional label and curve
draw_boundary, # Dashed service/group boundary
draw_badge, # Colored score circle
new_fig, # Create a new figure with standard theme
save, # Save to assets/diagrams/
THEME, # Consistent color palette
Box, Arrow, # Dataclasses for components
)
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.
- 4d ago First seen · 130 lines · 12 tokens per session scan A 69f5b653624c
architecture-diagram is a skill published in the GitHub repository OpenKnots/okcode (24 stars, last pushed 3mo ago), licensed MIT. It adds 12 tokens to every session and 1,329 once invoked, about $0.0001 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 skills, from other repositories
diagramming-expert
Master of text-based visual communication using ASCII art, Unicode box-drawing, and structured diagram notation. Creates clear, maintainable diagrams for systems, processes, hierarchies, relationships, and psychological structures. Proactively generates diagrams to enhance understanding. Activate on visualization…
architecture-diagram
Dark-themed SVG architecture/cloud/infra diagrams as HTML.
svg-press
Teaches agents how to hand-craft self-contained SVG diagrams that render correctly in browsers, tags, and Playwright PDF/PNG. Covers containment math, viewBox sizing, arrow construction, text hierarchy, KDCube brand color tokens, semantic zone fills, badges, the PNG inspection loop, writepng parameters, multi-diagram…
mermaid-diagrams
Create software diagrams using Mermaid syntax. Use when users need to create, visualize, or document software through diagrams including class diagrams, sequence diagrams, flowcharts, ERDs, C4 architecture diagrams, state diagrams, git graphs, and other diagram types. Triggers include requests to diagram, visualize…
fin-arch-diagram
生成研究/项目架构图、流程图、层次图(swimlane / processflow / hierarchytree)。适合 PPT 汇报、技术文档、综述插图。输出风格接近 draw.io,可选 graphviz(高质量)/ matplotlib(零依赖)双后端。.
visual-assets-generation
Generate visual assets (ASCII art, diagrams, banners) for repos and documentation.