Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Architecture Diagrams from Code with Mermaid and C4

    1

    Generate C4-style, sequence and ER diagrams in Mermaid from a real repo, every node traced to a file, then drift-check old diagrams as ACCURATE, DRIFTED or MISSING.

    $7

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Architecture Diagrams from Code with Mermaid and C4

    Architecture Diagrams from Code with Mermaid and C4

    Example session with this skill installed

    Our docs/architecture folder is from last year. Check whether the diagrams still match this monorepo, fix what drifted, and add an ER diagram from the migrations. Keep it Mermaid so it renders on GitHub.

    • Read your context and instructions
    • Compiled the architecture diagrams from

    Architecture diagrams - shop-monorepo @ 4e1c9a2

    Verdict: DRIFTED Mode: DRIFT CHECK Format: Mermaid
    Defaults used: output location docs/architecture/

    Diagram status

    DiagramFileNodesVerdictNotes
    Containersdocs/architecture/02-containers.md7DRIFTEDsearch service removed, worker missing
    Checkout sequencedocs/architecture/10-seq-checkout.md5ACCURATEmatches handlers
    ER(none)-MISSINGmigrations/ has 9 tables

    Updated containers diagram

    flowchart LR
      user((Customer))
      subgraph system["shop-monorepo"]
        web[web<br/>Next.js]
        api[orders_api<br/>Express]
        worker[worker<br/>BullMQ]
        db[(postgres)]
        q[[redis queue]]
      end
      stripe{{Stripe API}}
      user -- HTTPS --> web
      web -- "REST /api/*" --> api
      api -- SQL --> db
      api -. "order.created" .-> q
      q -.-> worker
      worker -- HTTPS --> stripe
    

    Evidence (excerpt)

    IDElementEvidenceConf.
    N3workerdocker-compose.yml:31, apps/worker/src/index.ts:4HIGH
    E4api -> queueapps/api/src/orders/service.ts:52HIGH
    E6worker -> Stripeapps/worker/package.json (stripe), charge.ts:18HIGH

    Unconfirmed (not drawn)

    • analytics - only in a comment in apps/web/lib/track.ts

    Drift fixes

    • [stale] search - no service in compose, k8s or code since apps/search was deleted - remove node and 2 edges
    • [missing] worker + queue - add as above
    • [missing] ER view - generate 20-er.md from migrations/

    Next steps

    • Write 20-er.md, update 02-containers.md, record 4e1c9a2 as last verified
    • Render-tested with mmdc: 2 of 2 diagrams parse
    docker-compose.yml

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Architecture diagrams go stale fast, and diagrams an AI draws from scratch often include services, queues or vendors that the code does not have. This skill builds diagrams from the repository itself and requires a file path as evidence for every box and arrow.

    What it does:

    • Runs read-only discovery across docker-compose, Kubernetes manifests, Terraform, package manifests, entry points, routes, queue clients, external API clients and migrations
    • Builds an evidence table (path:line, confidence) and leaves out anything it cannot prove, listing it under "Unconfirmed"
    • Writes a small set of Mermaid diagrams: system context, containers, one component view, 1-3 sequence flows and an ER diagram from the schema
    • Applies size rules (about 15 nodes per diagram, split beyond 20), shape and edge conventions, and a legend on every diagram
    • Places files under docs/architecture/ with an index, an evidence file and a README embed, and records the commit they were verified against
    • Re-checks existing diagrams against the code and grades each one ACCURATE, DRIFTED or MISSING, with exact fixes
    • Includes a reference on current Mermaid syntax (flowchart, sequenceDiagram, erDiagram, C4, architecture-beta), GitHub and GitLab rendering, and mmdc/D2 validation commands

    Who it's for: developers, tech leads and technical writers who need onboarding docs, design-review material or an audit of architecture docs that are out of date.

    Honesty note: the diagrams describe the code at a single commit, not live production topology. The skill does not invent services, versions or vendors. Mermaid's C4 and architecture-beta types are experimental or beta, so the skill defaults to stable types and tells you to check the host's Mermaid version first.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Technical Documentation.

    Diagrams reflect what the repository declares at one commit, not live production. Services in other repos, console-created cloud resources, and runtime-only wiring cannot be seen. Rendering depends on the Mermaid version the host runs, so beta and experimental types need a version check. D2 and PlantUML do not render natively on GitHub.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 1 month ago

    Software
    @mermaid-js/mermaid-cliNode.jsGit

    Permissions

    Terminal / Shell
    Network Access
    Listed1 month ago

    What's inside

    Frequently Asked Questions

    SKILL.md (the workflow, verdict rules and output template) and references/diagram-syntax-and-rendering.md (Mermaid syntax skeletons, GitHub/GitLab rendering notes, size rules, validation commands, and sources). That is the whole package.

    Any agent that reads SKILL.md skills, such as Claude Code, Codex CLI, Cursor, VS Code Copilot and Gemini CLI. The agent needs file read access to the repo. Running shell searches and mermaid-cli is optional but improves results.

    Unzip the folder into your agent's skills directory (for example .claude/skills/ for Claude Code), then ask it to diagram the repo or check the existing architecture docs. To render-test, install mermaid-cli or use npx.

    It shows what the code and manifests declare at one commit. It cannot see runtime-only wiring, services in other repos, or managed infrastructure that is not in IaC. Very dynamic code, such as plugin loading or reflection, may end up under Unconfirmed.

    A plain prompt tends to produce a plausible picture. This skill makes the agent follow a fixed discovery checklist, prove every element with a file path, keep diagrams within size limits, follow consistent conventions, validate rendering, and grade old diagrams with a repeatable drift check.

    New in Technical Documentation