All skills
agents365-ai avatar

/mermaid-skill

@72ee04b

Generate Mermaid diagrams (.mmd) and export to PNG/SVG/PDF using mmdc CLI or Kroki API. USE THIS SKILL when user mentions diagram, flowchart, sequence diagram, class diagram, ER diagram, state machine, architecture, visualize, git graph, 画图, 架构图, 流程图, 时序图, 类图, ER图, 甘特图, 状态机. PROACTIVELY USE when explaining ANY system with 3+ components, API flows, authentication sequences, class hierarchies, database schemas, or state machines. Supports 17+ diagram types with fully automatic layout.

Use this Skill: https://skilld.dev/gh/agents365-ai/365-skills/mermaid-skill

This session only. Nothing lands on disk.

referenceCLASS-ER.md

≈518 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Class & ER Diagram Syntax

Class Diagram

Basic Structure

classDiagram
  class User {
    +String name
    +String email
    -String passwordHash
    +login() bool
    +logout()
  }

  class Order {
    +int id
    +Date createdAt
    +float total
    +place()
    +cancel()
  }

  User "1" --> "*" Order : places

Visibility Modifiers

Symbol Meaning
+ Public
- Private
# Protected
~ Package/Internal

Relationships

Syntax Type Meaning
<|-- Inheritance extends
*-- Composition owns (lifecycle)
o-- Aggregation has (independent)
--> Association uses
..> Dependency depends on
..|> Realization implements

Cardinality

classDiagram
  User "1" --> "*" Order : places
  Order "1" --> "1..*" OrderItem : contains
  Product "0..*" --> "0..*" Category : belongs to
Notation Meaning
1 Exactly one
0..1 Zero or one
* Many
1..* One or more
n..m Range

ER Diagram

Basic Structure

erDiagram
  USER ||--o{ ORDER : places
  ORDER ||--|{ ORDER_ITEM : contains
  PRODUCT ||--o{ ORDER_ITEM : "included in"

  USER {
    int id PK
    string name
    string email
    datetime created_at
  }

  ORDER {
    int id PK
    int user_id FK
    float total
    string status
  }

  ORDER_ITEM {
    int order_id FK
    int product_id FK
    int quantity
  }

Relationship Notation

Left Right Meaning
|| || One to one
|| o{ One to zero or many
|| |{ One to one or many
o| o{ Zero or one to zero or many

Attribute Types

erDiagram
  PRODUCT {
    int id PK "Primary key"
    string name "Product name"
    float price
    int category_id FK "Foreign key"
    string sku UK "Unique key"
  }

Markers: PK (primary), FK (foreign), UK (unique)

Source: SKILL.md on GitHub

1 warning17d3 checks · Risk SAFE
  • Gen Agent Trust Hub17d

    The skill is safe to use but involves external network communication with kroki.io to validate or render diagrams, and it runs standard command-line tools locally.

  • Socket17d

    No alerts

  • Snyk17d

    Risk: MEDIUM · 1 issue

Signed by skilld at 72ee04b. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 14 hours ago.

Activeupdated 3 weeks ago
homepage
https://github.com/Agents365-ai/365-skills
version
1.3.0

README badge

README badge for agents365-ai/365-skills/mermaid-skill