Skip to content
diagram-patterns logo

Diagram Selection & Patterns

diagram-patterns

Decision guidance for selecting the right diagram type and tool. Provides patterns for common visualization scenarios, tool comparison, and best practices.

SKILL.md

Full skill instructions

Diagram Selection & Patterns

Interactive Diagram Selection

Use AskUserQuestion to understand requirements and recommend the optimal diagram type and tool:

# Question 1: Primary Purpose (MCP: CLI best practices - scope selection)
question: "What are you trying to visualize?"
header: "Purpose"
options:
  - label: "System Architecture (Recommended)"
    description: "Components, services, containers, deployment"
  - label: "Process/​Workflow"
    description: "Steps, decisions, activities, state transitions"
  - label: "Data Structures"
    description: "Classes, entities, relationships, schemas"
  - label: "Interactions"
    description: "Sequence of calls, messages, API flows"

# Question 2: Tool Constraints (MCP: CLI best practices - output format)
question: "Do you have tool or platform constraints?"
header: "Tool"
options:
  - label: "GitHub/​GitLab Markdown (Recommended)"
    description: "Use Mermaid - native rendering, no setup"
  - label: "Maximum Customization"
    description: "Use PlantUML - more styling, sprites, icons"
  - label: "Enterprise Architecture"
    description: "Use PlantUML - C4, ArchiMate support"
  - label: "No Preference"
    description: "I'll recommend based on diagram type"

Use these responses to apply the decision tree and recommend the appropriate diagram type and tool.

Overview

This skill helps you choose the right diagram type and tool for your visualization needs. Use this when you need to decide:

  1. Which diagram type best represents your information
  2. Which tool (Mermaid or PlantUML) to use
  3. How to structure the diagram for clarity

Diagram Type Decision Tree

START
  |
  +-- Interactions over time? --> SEQUENCE DIAGRAM
  |
  +-- Object/​class structure? --> CLASS DIAGRAM
  |
  +-- Database schema? --> ER DIAGRAM
  |
  +-- State transitions? --> STATE DIAGRAM
  |
  +-- Process/​workflow? --> FLOWCHART or ACTIVITY DIAGRAM
  |
  +-- System architecture?
  |     |
  |     +-- High-level context? --> C4 CONTEXT
  |     +-- Containers/​services? --> C4 CONTAINER or COMPONENT
  |     +-- Infrastructure? --> DEPLOYMENT DIAGRAM
  |
  +-- Project timeline? --> GANTT CHART
  |
  +-- Git branching? --> GIT GRAPH (Mermaid only)
  |
  +-- Hierarchical ideas? --> MINDMAP (PlantUML only)
  |
  +-- Data structure? --> JSON DIAGRAM (PlantUML only)

Tool Selection Guide

Quick Decision Matrix

NeedRecommended ToolReason
GitHub/​GitLab renderingMermaidNative support
Complex C4 modelsPlantUMLMature, better rendering
Simple sequence/​classMermaidSimpler syntax
MindMapsPlantUMLOnly option
JSON visualizationPlantUMLOnly option
GitGraphMermaidOnly option
ER diagramsMermaidBetter default rendering
State diagramsMermaidCleaner output
Maximum customizationPlantUMLMore styling options
Zero setupMermaidBrowser-based
Enterprise architecturePlantUMLBetter ArchiMate, C4

Detailed Comparison

FeatureMermaidPlantUML
SetupNone (browser)Java + GraphViz
Markdown integrationNative (GitHub, GitLab)Requires image embedding
Learning curveGentleSteeper
CustomizationLimitedExtensive
C4 supportExperimentalMature
Diagram types~1015+
JSON/​MindMapNoYes
GitGraphYesNo

When to Choose Mermaid

  • Documentation that lives in GitHub/​GitLab repos
  • Quick diagrams that need no setup
  • Teams with mixed technical backgrounds
  • Simple to moderately complex diagrams

When to Choose PlantUML

  • Complex enterprise architecture (C4, ArchiMate)
  • Maximum control over appearance
  • Specialized diagrams (MindMap, JSON, WBS)
  • Need for sprites/​icons

Quick Reference: Choosing Diagram Type

QuestionIf Yes, Use
Showing message flow between systems?Sequence
Modeling OOP classes and relationships?Class
Documenting database tables?ER
Showing valid state transitions?State
Depicting a process or algorithm?Flowchart
High-level system overview?C4 Context
Service/​container architecture?C4 Container
Timeline or schedule?Gantt
Git branching strategy?Git Graph
Brainstorming hierarchy?MindMap

References

For detailed patterns and examples, see:

ReferenceContentWhen to Load
sequence-class-patterns.mdAPI flows, auth, async, domain models, repositoriesCreating sequence/​class diagrams
er-state-flow-patterns.mdBlog/​e-commerce schemas, order lifecycle, decision treesCreating ER/​state/​flow diagrams
c4-patterns.mdC4 context/​container, tool recommendationsCreating architecture diagrams
best-practices.mdGeneral guidelines, diagram tips, anti-patternsImproving diagram quality

Delegation

For detailed syntax reference:

  • Mermaid syntax: Invoke visualization:mermaid-syntax skill
  • PlantUML syntax: Invoke visualization:plantuml-syntax skill

Test Scenarios

Scenario 1: Choosing a diagram type

Query: "What diagram should I use to show API request flow?"

Expected: Skill activates, recommends sequence diagram, provides tool comparison

Scenario 2: Tool selection

Query: "Should I use Mermaid or PlantUML for C4 diagrams?"

Expected: Skill activates, recommends PlantUML for complex C4, Mermaid for simple context

Scenario 3: Pattern lookup

Query: "Show me an authentication sequence diagram pattern"

Expected: Skill activates, directs to sequence-class-patterns.md reference


Last Updated: 2025-12-28

Version History

  • v1.1.0 (2025-12-28): Refactored to progressive disclosure - extracted patterns to references/
  • v1.0.0 (2025-12-26): Initial release

More Productivity & Planning skills

brainstorming logo
Productivity & Planning

brainstorming

Structured design dialogue that validates ideas before implementation begins.

295.4K 385.7K
View
ui-ux-pro-max logo
Productivity & Planning

ui-ux-pro-max

Comprehensive design intelligence for web and mobile UI/UX across 10 technology stacks.

133.1K 383.9K
View
writing-plans logo
Productivity & Planning

writing-plans

Comprehensive implementation plans for multi-step tasks, breaking down specs into bite-sized, testable steps.

295.4K 268K
View
using-superpowers logo
Productivity & Planning

using-superpowers

Introduction to the obra skills system with mandatory skill invocation rules and best practices.

295.4K 259.8K
View
executing-plans logo
Productivity & Planning

executing-plans

Execute a written implementation plan with critical review and task checkpoints.

295.4K 229.1K
View
dispatching-parallel-agents logo
Productivity & Planning

dispatching-parallel-agents

Delegate independent tasks to specialized agents working concurrently with isolated context.

295.4K 206.3K
View
using-git-worktrees logo
Productivity & Planning

using-git-worktrees

Isolated git worktrees with smart directory selection and safety verification.

295.4K 205.2K
View
webapp-testing logo
Productivity & Planning

webapp-testing

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.

179.7K 170.6K
View
content-strategy logo
Productivity & Planning

content-strategy

Plan searchable and shareable content that drives traffic, builds authority, and generates leads.

53.3K 150.9K
View
repo-intake-and-plan logo
Productivity & Planning

repo-intake-and-plan

README-first repository scanner that extracts commands and classifies reproduction candidates without executing them.

497 139.6K
View
marketing-ideas logo
Productivity & Planning

marketing-ideas

Brainstorm and prioritize marketing strategies tailored to your SaaS stage, budget, and goals.

53.3K 137.2K
View
site-architecture logo
Productivity & Planning

site-architecture

Plan and optimize your website's page hierarchy, navigation, URL structure, and internal linking.

53.3K 112.8K
View

Productivity AI tools

Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View
SaveDay logo
Productivity

SaveDay

Capture, organize, and utilize your knowledge effortlessly.

Free
View
A
Productivity

Any Summary

Instant Summaries of Audio & Video Interviews with AnySummary

Freemium
View
M
Productivity

Map This

Transform PDFs into engaging mind maps.

Freemium
View
ChatPDF logo
Productivity

ChatPDF

Chat with any PDF instantly

Free
View
I
Productivity

intellisay

Create an optimal daily plan using your voice

Paid
View
A
Productivity

Aurora AI

A productivity platform to centralize organizational knowledge and workflows with contextual AI assistance.

Paid
View
AskYourPDF logo
Productivity

AskYourPDF

AskYourPDF Pricing Plans: Tailored to Your Needs

Free
View