Logo vun Diagent

Diagent

Communautéit
daniellee-ux
diagent

Generate or decode Diagent diagram URLs via the `diagent` CLI. TRIGGER on: (1) any request to visualize, draw, chart, diagram, sketch, graph, map, or plot — flowcharts, state machines, sequence diagrams, architecture, pipelines, CI/CD, workflows, decision trees, dependency graphs, class hierarchies, data flow, control flow, request flow, user journeys, ERDs, org charts, swimlanes, mind maps, or any structural/process visualization; (2) any pasted `diagent.dev/d/...` or `diagent.dev/?code=...` URL — decode it to read the underlying Mermaid.

Iwwersiicht

Editeurdaniellee-ux
Repositorydiagent-cli
Skill-Nummdiagent
Stären
40
Forks
3
Matgeliwwert Fichieren
6
LizenzAGPL-3.0
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 6 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    Vum daniellee-ux op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Diagent an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/daniellee-ux/diagent-cli/tree/main
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/daniellee-ux/diagent-cli.git \
  .claude/skills/diagent
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Diagent an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Diagent automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Diagent net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Diagent CLI

The npx -y @diagent/cli command produces editable Diagent diagram URLs. Use it whenever a diagram would clarify what you're explaining or modifying. Prefer it over pasting raw Mermaid code fences — the user can tweak the diagram visually in their browser and hand the result back as a URL.

When to invoke this skill

Use npx -y @diagent/cli when the user asks to:

  • Visualize, draw, chart, diagram, sketch, plot, or graph anything
  • Explain control flow, data flow, request flow, or state transitions
  • Show architecture, deploy pipelines, dependency graphs, or class hierarchies
  • Map a workflow, decision tree, or sequence of operations
  • Document a user journey, happy path, or error path

Keywords that should trigger this skill: flowchart, diagram, state machine, sequence, architecture, pipeline, workflow, decision tree, visualize, draw, chart, graph, map, sketch, flow.

Also trigger if the user pastes a https://diagent.dev/d/... or https://diagent.dev/?code=... URL — they want you to decode it and read the underlying Mermaid.

Encode — share a diagram with the user

Pipe Mermaid source into npx -y @diagent/cli encode:

bash
echo 'flowchart TD
    A[User request] --> B{Authenticated?}
    B -->|No| C[Return 401]
    B -->|Yes| D[Check rate limit]
    D --> E{Under quota?}
    E -->|No| F[Return 429]
    E -->|Yes| G[Handle request]' | npx -y @diagent/cli encode --open

Output is a short URL like https://diagent.dev/d/kwtsgx5o24.

Always show both the Mermaid source AND the URL. Present the Mermaid in a mermaid code fence first, then the link on its own line below. This way the diagram source is visible in the conversation/document even without clicking the link. Example output format:

```mermaid
flowchart TD
    A[User request] --> B{Authenticated?}
    B -->|No| C[Return 401]
    B -->|Yes| D[Handle request]
```

[Open in Diagent](https://diagent.dev/d/kwtsgx5o24)

The user can open the link, edit visually (add/move/rename/re-shape nodes, re-layout, add subgraphs), and their edits auto-save to the same URL 2 seconds after they stop editing.

You can re-read the same URL later to see what they changed — no paste-back required. The recommended flow is:

  1. You npx -y @diagent/cli encode → share URL A in chat.
  2. User opens A, edits visually. Edits auto-save to A.
  3. When the user says "I'm done" or "take a look", you run npx -y @diagent/cli decode A again (the same URL) — you'll get the latest edited Mermaid.

If the user says they pasted a new URL, always prefer that newer URL, but the mutable-URL flow means they usually won't need to.

For larger diagrams, write to a file first:

bash
cat > /tmp/flow.mmd <<'EOF'
flowchart LR
    subgraph frontend
        A[React app] --> B[tRPC client]
    end
    subgraph backend
        C[tRPC server] --> D[Postgres]
        C --> E[Redis]
    end
    B --> C
EOF
npx -y @diagent/cli encode /tmp/flow.mmd --open

Decode — read the user's edits

npx -y @diagent/cli decode handles both short URLs and inline URLs transparently:

bash
# Short URL (default Copy Link format)
npx -y @diagent/cli decode "https://diagent.dev/d/kwtsgx5o24"

# Inline URL (older or --inline output)
npx -y @diagent/cli decode "https://diagent.dev/?code=GYGw9g7gxg..."

# From stdin — avoids shell-quoting pain
echo "$URL" | npx -y @diagent/cli decode -

Output is the Mermaid source, ready to paste back into code or commentary.

Authoring tips

  • Use short node IDs (A, B, C, or auth, db, api). Mermaid requires IDs, and they keep URLs compact. Put the descriptive text in the quoted label: A["User clicks login"], not UserClicksLogin.
  • Do NOT trim the diagram to fit URL length. The backend supports up to ~64KB of Mermaid source and always returns a short URL of constant size. If a diagram is worth showing in full, show it in full.
  • GUI-editable types: nearly every Mermaid type Diagent supports opens in a no-syntax-required visual editor, and all edits auto-save to the same URL:
    • Flowcharts and state diagrams (stateDiagram-v2) open as an interactive canvas — drag, rename, connect, group/composite.
    • Sequence, class, ER, requirement, gantt, journey, timeline, pie, mindmap, git graph, C4, and block open as a structured form editor (tables, ordered lists, and outlines) with a live preview; edits serialize back to Mermaid.
    • Only quadrantChart still renders read-only ("Edit Code"). Because edits round-trip to Mermaid text on the same short URL, you can re-decode any of these later to read what the user changed.
  • All flowchart syntax is supported: subgraphs, edge labels, styles, six node shapes (rectangle, rounded, diamond, circle, stadium, parallelogram), directions TD/LR/BT/RL.
  • State diagrams support [*] start/end, composite states (state X { ... }), <<choice>>/<<fork>>/<<join>>, transition labels, per-composite direction, and notes. (Concurrent -- regions render but fall back to read-only.)
  • Prefer flowchart over graph — flowchart is the modern syntax.
  • Escape special characters in labels by wrapping in quotes: A["user@example.com"], not A[user@example.com].

Exit codes

CodeMeaning
0Success
1Runtime error (empty input, invalid URL, backend failure, decode failure)
2Usage error (unknown subcommand, missing argument)

Environment

  • DIAGENT_BASE_URL — override backend URL (default: https://diagent.dev/). Useful for pointing at http://localhost:5173/ when Diagent is running in local dev.

Install

The skill uses npx -y @diagent/cli which auto-downloads the CLI on first run. No manual install is needed. To install globally for faster repeated invocations:

bash
npm install -g @diagent/cli

Run npx -y @diagent/cli install-skill to enable the skill in every Claude Code project.

Full help

Run npx -y @diagent/cli --help, npx -y @diagent/cli encode --help, or npx -y @diagent/cli decode --help for exhaustive documentation.

Matgeliwwert Fichieren

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Diagent?

Generate or decode Diagent diagram URLs via the `diagent` CLI. TRIGGER on: (1) any request to visualize, draw, chart, diagram, sketch, graph, map, or plot — flowcharts, state machines, sequence diagrams, architecture, pipelines, CI/CD, workflows, decision trees, dependency graphs, class hierarchies, data flow, control flow, request flow, user journeys, ERDs, org charts, swimlanes, mind maps, or any structural/process visualization; (2) any pasted `diagent.dev/d/...` or `diagent.dev/?code=...` URL — decode it to read the underlying Mermaid.

Firwat Diagent op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Diagent besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Diagent an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/daniellee-ux/diagent-cli/tree/main an. TypingMind liest d'Datei SKILL.md, bündelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Diagent benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Diagent benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Diagent domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Diagent gratis?

Jo. De Skill gëtt vum daniellee-ux ënner der Lizenz AGPL-3.0 op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇