architecture-diagram

architecture-diagram is a skill for Claude Code from athola/claude-night-market. It costs 27 tokens per session (711 once invoked), scanned A, original, MIT.

A guide for creating a high-level Mermaid architecture diagram that shows how a codebase's major modules or plugins relate to one another.

In plain words
What is it for?
Use it for onboarding, documenting module relationships, and explaining architecture during code reviews.
Why use it?
It helps people understand a system's overall shape without reading every file or focusing on individual imports.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the cartograph plugin — 7 skills, 1 command shipped together

Good fit Use it for onboarding, documenting module relationships, and explaining architecture during code reviews.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/athola/claude-night-market/architecture-diagram
Install

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.

Any agent
npx skills add athola/claude-night-market --skill architecture-diagram
Clone the repo
git clone --depth 1 https://github.com/athola/claude-night-market

Made for: Claude Code.

Or install cartograph, the plugin that ships this one along with the rest of its 7 skills, 1 command.

Wrote 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.

agentmods badge for architecture-diagram

README.md
[![agentmods](https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-diagram/github.svg)](https://agentmods.dev/skills/athola/claude-night-market/architecture-diagram)
Your own site
<a href="https://agentmods.dev/skills/athola/claude-night-market/architecture-diagram"><img src="https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-diagram/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.

agentmods 80×15 button for architecture-diagram

Your own site · 80×15
<a href="https://agentmods.dev/skills/athola/claude-night-market/architecture-diagram"><img src="https://agentmods.dev/badge/skills/athola/claude-night-market/architecture-diagram.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 27 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 711 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00027 $0.00711
Opus 5 $0.00014 $0.00356
Sonnet 5 $0.00005 $0.00142
Haiku 4.5 $0.00003 $0.00071

Measured 9d ago against content hash cf0e917320b0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

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 9d 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.

plugins/cartograph/skills/architecture-diagram/SKILL.md · 108 lines

How it starts

The opening of the file, as written. The whole thing — 108 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Architecture Diagram

Generate a Mermaid flowchart showing high-level component relationships in a codebase.

When To Use

  • Visualizing how plugins/modules relate to each other
  • Onboarding to understand system structure
  • Documenting architecture for PR reviews
  • Answering "how does this system fit together?"

When NOT To Use

  • Import-level coupling (use cartograph:dependency-graph)
  • Runtime call paths (use cartograph:call-chain)

Workflow

Step 1: Explore the Codebase

Dispatch the codebase explorer agent to analyze the scope:

Agent(cartograph:codebase-explorer)
Prompt: Explore [scope] and return a structural model.
Focus on packages, modules, and their relationships
for an architecture diagram.

If no scope is provided, use the project root.

Step 2: Generate Mermaid Syntax

Transform the structural model into a Mermaid flowchart.

Rules for architecture diagrams:

  • Use flowchart TD (top-down) for hierarchical systems
  • Use flowchart LR (left-right) for pipeline/flow systems
  • Group related modules into subgraphs by package
  • Use descriptive edge labels for relationships
  • Limit to 15-20 nodes maximum (aggregate small modules)
  • Use shapes to distinguish component types:
    • [Rectangle] for modules/packages
    • ([Stadium]) for entry points/commands
    • [(Database)] for data stores
    • {Diamond} for decision points

Example output:

flowchart TD
    subgraph sanctum[Sanctum Plugin]
        commit[Commit Messages]
        pr[PR Preparation]
        workspace[Workspace Review]
    end

    subgraph leyline[Leyline Plugin]
        git[Git Platform]
        patterns[Error Patterns]
    end

    commit --> git
    pr --> workspace
    pr --> git
    workspace --> patterns

Step 3: Render via MCP

Call the Mermaid Chart MCP to render:

mcp__claude_ai_Mermaid_Chart__validate_and_render_mermaid_diagram
  prompt: "Architecture diagram of [scope]"
  mermaidCode: [generated syntax]
  diagramType: "flowchart"
  clientName: "claude-code"

Read the full file on GitHub · 108 lines

Changes

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.

  1. 9d ago First seen · 108 lines · 27 tokens per session scan A cf0e917320b0

Subscribe to this mod's changes

architecture-diagram is a skill published in the GitHub repository athola/claude-night-market (337 stars, last pushed 2d ago), licensed MIT. It adds 27 tokens to every session and 711 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-09-03.

Related

Other skills, from other repositories

chameleon

Match the house style when adding code to an existing codebase. Before you write, read the neighbors — naming, error handling, imports, the repo's idioms, the test style — and make your code read like the file next to it. Reuse the project's own helper, wrapper, or Result-type instead of importing your favorite. New…

ccplugins/awesome-claude-code-plugins · 168 tokens

explainer

Reviewable git hygiene for work you're about to commit or open a PR for. Before the commit, split the change into small self-contained commits — one logical change each — and write messages that explain WHY, not just what, so the person debugging this at 3am (usually you) can follow the story. Structure the diff so a…

ccplugins/awesome-claude-code-plugins · 155 tokens

fact-checker

Anti-hallucination discipline for any code that names an external symbol you aren't certain exists — a library function, method, config key, package version, CLI flag, env var, or endpoint. Before you call it, cite it, or import it, confirm it's real: grep the codebase, read the installed package's actual signature…

ccplugins/awesome-claude-code-plugins · 178 tokens

historian

Chesterton's Fence for code you're about to delete or refactor. Before you rip out a weird retry, a seemingly dead branch, an ugly workaround, or a "redundant" check whose purpose isn't obvious — find out why it exists first. git blame it, find the callers, read the linked issue/PR/commit. If you can't explain why the…

ccplugins/awesome-claude-code-plugins · 184 tokens

claudex-second-opinion

Suggests a cross-model second opinion after substantial or risky code changes. Use when a significant implementation, refactor, security-sensitive change, or uncertain bug fix has just been completed and is about to be committed or shipped. Advisory only — it recommends running /claudex:verdict; it never invokes Codex…

ccplugins/awesome-claude-code-plugins · 74 tokens

code-quality

Multi-language code quality standards and review for TypeScript, Python, Go, and Rust. Enforces type safety, security, performance, and maintainability. Use when writing, reviewing, or refactoring code. Includes review process, checklist, and Python PEP 8 deep-dive.

georgekhananaev/claude-skills-vault · 61 tokens