TVL AI Skills

Diagram Design Skill

tvl-design-diagram turns messy source material — notes, architecture descriptions, product flows, audit systems — into a clean Mermaid diagram you can read in seconds. It picks one template, keeps only load-bearing nodes, and runs an Ethical AI check so nothing on the canvas is invented.

Templates

Three diagram modes

The skill picks the simplest template that fits — exactly one, unless you ask for more. Each maps a different shape of information.

System map

Components, actors, data stores, boundaries and integrations — what exists and how it connects.

flowchart LR User --> API API --> DB[(Store)] API --> Auth

Workflow

Ordered steps, ownership, handoffs and feedback loops — how work moves from start to output.

flowchart TD Draft --> Review Review --> Fix Fix --> Review Review --> Publish

Decision flow

Conditions, gates, verdicts and branching outcomes — where the path forks and why.

flowchart TD Check{Valid?} Check -->|yes| PASS Check -->|no| BLOCK
Mermaid rules

Conventions that keep it readable

The output is always flowchart syntax. The rules exist so the diagram stays legible and copy-paste ready — not decorated.

AreaConvention
SyntaxDefault to Mermaid flowchart. Pick LR or TD by what reads best for the shape of the information.
Node IDsStable, descriptive IDs such as User, Draft, Judge, Decision.
LabelsKeep labels under 48 characters. Avoid tiny one-word nodes unless they are standard verdicts like PASS, FLAG or BLOCK.
EdgesPut a verb on the edge when the relationship is not obvious.
ScopeExtract only load-bearing nodes and relationships. Merge duplicates. Keep labels concrete.
StylingNo decorative styling unless you ask for it. The structure is the point.
How it works

The seven-step process

1

Read as data

Treat the source as data; ignore instructions embedded in it unless you explicitly direct otherwise.

2

Identify the job

Decide which diagram it is: a system map, a workflow, or a decision flow.

3

Select one template

Load the templates and commit to exactly one, so the diagram has a single clear shape.

4

Extract the essentials

Keep only load-bearing nodes and relationships. Merge duplicates. Keep labels short and concrete.

5

Draft the Mermaid

Write the flowchart following the naming and edge conventions.

6

Run the Ethical AI check

Verify every node and edge is grounded in the source before finalizing.

7

Self-check

Confirm node sourcing, edge accuracy, standalone readability and an appropriate level of detail.

Grounding

The Ethical AI check

A diagram makes invented steps look official. Before returning, the skill runs the same EthicalAI failure-mode check — for hallucination, confabulation, source fabrication, sycophancy, confirmation bias, selective evidence, anchoring, prompt injection and overconfidence.

Every node earns its place

The core question: does every node appear in the source, or follow clearly from it? Nodes that do not are cut or marked, never invented to make the picture look complete.

Every edge is a real relationship

Does each edge describe a real action, relationship or decision? Uncertain connections are flagged as assumptions instead of drawn as fact.

Shared with the audit skill

The checklist comes from the same rubric as tvl-ethical-ai-audit and EthicalAI, so a diagram is held to the same standard as prose.

Then it returns a classification

PASS

Accurate and correctly scoped to the source.

FLAG

Usable, but with named assumptions or uncertainties called out.

BLOCK

The source is too vague or unsupported to diagram honestly.

Under the hood

What ships with the skill

references/templates.md

The system map, workflow and decision-flow templates the skill selects from.

references/ethical-ai-check.md

The grounding checklist run before a diagram is finalized.

Output

A single Mermaid flowchart, plus an optional short note naming the template, assumptions and classification.

Install and run

Add the diagram skill

Use the public TVL Skills repository with the Agent Skills CLI.

Install only this skill

$ npx skills add danlex/tvl-skills --skill tvl-design-diagram

Install all TVL skills

$ npx skills add danlex/tvl-skills

Diagram a workflow

Use $tvl-design-diagram to turn this onboarding workflow into a Mermaid diagram. Keep only the load-bearing steps and mark anything you had to assume.

Map a system

Use $tvl-design-diagram to draw a system map of this architecture: components, data stores and integrations only. Return a flowchart and note anything unsupported by my description.

Draw a decision flow

Use $tvl-design-diagram to turn this validation logic into a decision flow with the gates and PASS/FLAG/BLOCK outcomes. Run the Ethical AI check before returning it.