diagrams
Use when creating or updating diagrams, including architecture, infrastructure, sequence, flowchart, state, or entity-relationship diagrams.
- License 许可
- MIT
- 最近更新
- 2026-11-10
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- diagrams
- description
- Use when creating or updating diagrams, including architecture, infrastructure, sequence, flowchart, state, or entity-relationship diagrams.
03 SKILL.md 正文
Diagrams
Diagrams are code, rendered to PNG by default. Pick the tool whose strengths fit what the diagram must show; one request can need both.
- Python
diagrams: recognisable provider icons (AWS, GCP, Azure, Kubernetes, on-prem, SaaS), nested boundaries such as account, VPC, or cluster, and many-node topologies that Graphviz lays out without per-edge hints. - Mermaid: ordering over time (sequence, timeline, Gantt), control flow and decisions (flowchart, state), and data models (ER, class). Also any diagram that must render inline in Markdown.
Report a missing tool rather than installing it silently.
Python diagrams
Requires uv and Graphviz dot on PATH; without dot, rendering fails with
ExecutableNotFound.
Save the source as <name>.py next to the PNG it produces so the diagram can be
regenerated and diffed. Always pass show=False; otherwise the render opens an
image viewer.
from diagrams import Cluster, Diagram, Edge
from diagrams.aws.compute import EKS
from diagrams.aws.database import RDS
from diagrams.aws.network import ALB
from diagrams.aws.storage import S3
with Diagram("Service", filename="service", show=False, direction="LR",
graph_attr={"pad": "0.2"}):
with Cluster("VPC"):
alb = ALB("ALB")
app = EKS("App")
alb >> app >> Edge(label="SQL") >> RDS("RDS")
app >> S3("Assets")
uv run --with diagrams==0.25.1 python service.py # writes service.png
Guessed class names are the usual import failure. List a module's nodes before importing from it:
uv run --with diagrams==0.25.1 python -c \
"import diagrams.aws.network as m; print([n for n in dir(m) if n[0].isupper()])"
Providers include aws, gcp, azure, k8s, onprem, saas, and generic.
For anything without an icon, use diagrams.custom.Custom(label, "icon.png")
with a local image.
If the layout is poor, change direction, regroup with Cluster, or split the
diagram.
Other diagrams: Mermaid
Requires mmdc (Mermaid CLI). Save the source as <name>.mmd next to its PNG.
mmdc -i flow.mmd -o flow.png -b white -s 2 # white background, 2x scale
Done when
You have viewed the rendered PNG yourself and checked that labels are legible, no edges or nodes overlap, and every component the user named appears.
04 同仓库更多 Skills
writing-for-agents
Write or revise documents that agents consume, including skills, AGENTS.md, CLAUDE.md, specifications, prompts, and README files. Use when authoring or reviewing agent-facing instructions.
windows-test-rig
Drive libvirt Windows 11 test VMs on this host or other Linux hosts - list and select VMs, boot, reset to a clean snapshot, run PowerShell over SSH, launch GUI apps on the visible desktop, send keys, screenshot, and tunnel host services into the guest. Use when a change must be validated on real Windows, or when creating the VM on a new host.
unslop
Cut AI tells from any writing. Must always apply.
teach
Teach the user a new skill or concept, within this workspace.
subagent
Spawns pi as a separate subagent process for edits, verification, reviews, research, or any delegated task whenever the user mentions a subagent, asks to delegate work, or invokes /skill:subagent.
review
Run a read-only subagent review of the current branch diff against main or master.