Microsoft logo

Skill

dot-quality

enforce quality standards on DOT diagrams

Covers QA Documentation Diagrams Graphviz Visual Design

Description

Use when enforcing quality standards on DOT diagrams — checking completeness, structure, and visual clarity before sharing or committing

SKILL.md

DOT Quality Standards

Overview

Every DOT diagram makes structural claims. Those claims must be verifiable, complete, and unambiguous. Quality enforcement ensures diagrams communicate correctly — not just render correctly.

Core principle: A diagram that renders without errors can still be wrong. Structural claims require titles, color requires legends, and shapes must match their semantic meaning.


The Iron Law

NO DIAGRAM WITHOUT A TITLE, NO COLOR WITHOUT A LEGEND

These are not suggestions. A diagram without a title is anonymous — reviewers cannot reference it. A diagram with unexplained color is ambiguous — different readers draw different conclusions.


Quality Checklist

Must Have — FAIL if missing

  • Graph has a label= attribute set to a meaningful title
  • labelloc=t is set (title appears at top, not bottom)
  • Every node has either a meaningful ID or an explicit label=
  • All edges convey accurate relationships (not aspirational or assumed)

Should Have — WARN if missing

  • rankdir is set explicitly (LR, TB, BT, or RL) — don't rely on defaults
  • Default node and edge attributes are declared at the top with node [...] and edge [...]
  • Shape vocabulary is consistent with the shape-meaning table below
  • If any color is used, a cluster_legend subgraph documents all colors used
  • Error and exception paths are drawn (not just the happy path)
  • External dependencies are shown, even if simplified

Nice to Have — INFO

  • fontname is set consistently (Helvetica or similar sans-serif)
  • nodesep and ranksep are tuned for readability
  • Cluster fill colors are distinct from node fill colors
  • A // comment explains any non-obvious structural choice

Line Count Targets

Diagram TypeTargetWARN atFAIL at
Overview / context30–80120200
Architecture (detail)80–150250400
Inline (single concept)10–305080
Quick sketch5–203560

Diagrams that exceed WARN thresholds should be split into overview + detail files.


Anti-Pattern Red Flags

FlagProblemFix
Floating nodeNode with no edges — forgotten or placeholderConnect it or remove it
Mystery colorColor used without legend entryAdd to legend or remove color
label=""Empty label — invisible nodeSet a meaningful label
Duplicate node IDsSame ID used for different conceptsRename to make IDs unique
All nodes same shapeShape vocabulary not being usedApply shape-meaning table
Edges without direction meaningArrow direction doesn't match data/control flowReverse or relabel edges
No titleAnonymous diagram — cannot be referencedAdd label= and labelloc=t

Shape Vocabulary Compliance

Shapes carry semantic meaning. Using the wrong shape creates ambiguity:

ShapeMeaningMisuse to Avoid
box / rectangleService, process, componentDon't use for data stores
cylinderDatabase, file store, queueDon't use for services
diamondDecision point, branchDon't use for processes
ellipseStart / end state, terminalDon't use for services
doublecircleFinal/accepted state (FSM)Reserve for state machines
parallelogramExternal system, I/ODon't use for internal services
noteAnnotation, documentation nodeDon't use for primary components
componentFan-out / fan-in coordinatorDon't use for simple steps
pointInitial state marker (FSM)Reserve for state machines only
folderFile group, repositoryDon't use for services

The Quality Gate

Run this 7-step check before every diagram is shared, committed, or embedded in documentation:

  1. Render checkdot -Tsvg diagram.dot > /dev/null — zero errors
  2. Title checkgrep 'label=' diagram.dot shows a non-empty title
  3. Color check — if any fillcolor or color attribute is set, cluster_legend exists
  4. Shape check — review each node shape against the Shape Vocabulary table
  5. Float check — every node has at least one edge (incoming or outgoing)
  6. Path check — error/failure paths are present, not just the happy path
  7. Size check — line count is within target range for the diagram type

© 2026 YourAI.tools. Every skill from an identity-verified publisher.

Independent catalog. Not affiliated with, endorsed by, or sponsored by Anthropic or any listed publisher. All trademarks belong to their respective owners.