AgentsInFlow
AgentsInFlow

Diagrams

28 diagram engines rendered inline. Write syntax in a code fence, see the result immediately.

Overview

AgentsInFlow ships with 28 diagram engines that render directly inside the editor. Diagrams work everywhere content appears: ticket descriptions, notes, dashboard widgets, and assistant chat. Each engine has its own syntax, but the workflow is always the same — wrap your diagram code in a fenced code block tagged with the engine name, and the rendered diagram appears inline.

[Screenshot: Mermaid flowchart rendered inline inside a ticket description editor]

All 28 diagram types support zoom — pinch, scroll-wheel, and click-to-expand — across every context: dashboard widgets, markdown editors, ticket details, and file editors.


Architecture & Structure

Nine engines cover system design, UML, and database modeling.

EngineCode fence tagBest for
Structurizr DSLstructurizrC4 models (context, container, component, code)
PlantUML C4c4plantumlC4 models with PlantUML syntax
D2d2General-purpose architecture with auto-layout
GraphvizgraphvizDependency graphs, call graphs, DAGs
PlantUMLplantumlClass, component, and deployment diagrams
UMletumletQuick UML sketches — class, activity, state
NomnomlnomnomlSimple class and object diagrams
ERDerdEntity-relationship diagrams
DBMLdbmlDatabase schema modeling with constraints

Behavioral & Flow

Four engines for sequences, flowcharts, business processes, and activity workflows.

EngineCode fence tagBest for
MermaidmermaidFlowcharts, sequence diagrams, state machines, Gantt charts
BPMNbpmnBusiness process modeling — swimlanes, gateways, events
ActdiagactdiagActivity diagrams with step-by-step workflows
SeqdiagseqdiagSequence diagrams with focused, simple syntax

Network & Infrastructure

Four engines for network topology, packet layouts, server racks, and block diagrams.

EngineCode fence tagBest for
NwdiagnwdiagNetwork topology — hosts, subnets, connections
PacketdiagpacketdiagPacket structure and protocol field layouts
RackdiagrackdiagServer rack layouts and hardware placement
BlockdiagblockdiagBlock diagrams for system overviews

Hardware & Electrical

Four engines for timing diagrams, byte layouts, HDL symbols, and wiring harnesses.

EngineCode fence tagBest for
WaveDromwavedromDigital timing diagrams and waveforms
BytefieldbytefieldBinary data structure and protocol byte layouts
SymbolatorsymbolatorHDL symbol diagrams from VHDL/Verilog
WireVizwirevizWiring harness and cable assembly docs

Visual & Freeform

Five engines for hand-drawn sketches, ASCII art conversion, and precise technical illustrations.

EngineCode fence tagBest for
ExcalidrawexcalidrawHand-drawn style — whiteboard sketches, freeform layouts
SvgbobsvgbobASCII art to SVG — quick inline diagrams from text art
PikchrpikchrPrecise technical diagrams with explicit positioning
DitaaditaaASCII art to diagram — boxes and arrows from text
TikZtikzPublication-quality technical and mathematical diagrams

Data Visualization

Three engines for statistical charts and data-driven graphics. ECharts is the preferred engine for charts — see Editor & Diagrams for interactive chart widget details.

EngineCode fence tagBest for
Apache EChartsechartsBar, line, pie, scatter, area, donut charts (preferred)
VegavegaComplex data visualizations with full grammar of graphics
Vega-LitevegaliteConcise statistical charts — bar, line, scatter, heatmap

Writing Diagram Syntax

Create a fenced code block and set the language tag to the engine name. The renderer picks it up automatically.

Mermaid — Flowchart

```mermaid
graph TD
  A[Start] --> B{Decision}
  B -->|Yes| C[Action]
  B -->|No| D[End]
  C --> D
```

D2 — Architecture

```d2
web: Web Server
api: API Gateway
db: PostgreSQL

web -> api: REST
api -> db: queries
```

PlantUML — Sequence

```plantuml
@startuml
Client -> Server: Request
Server -> Database: Query
Database --> Server: Result
Server --> Client: Response
@enduml
```

Graphviz — Dependency Graph

```graphviz
digraph {
  rankdir=LR
  A -> B -> C
  A -> D -> C
}
```

The app canvas uses a dark background. All diagram engines automatically apply dark-safe themes so lines, text, and labels remain readable.


Live Preview

Diagrams render inline as you type. The editor detects the code fence language tag, compiles the source through the matching engine, and replaces the code block with the rendered SVG or canvas output. Editing the source updates the preview in real time.

[Screenshot: Split view showing Mermaid source code on the left and rendered diagram on the right]
1

Open a code fence block and set the language tag (e.g. mermaid)

2

Write or paste your diagram syntax

3

Close the code fence — the rendered diagram appears immediately

4

Click the diagram to toggle back to source for editing


Diagrams in Tickets & Dashboards

Diagrams are not limited to the editor. They render anywhere markdown content is displayed.

Ticket Descriptions

Add a diagram code fence to any ticket description or note. When the ticket is viewed on the Kanban board or in the inspector, the diagram renders inline with full zoom support.

[Screenshot: Ticket inspector showing a D2 architecture diagram rendered inside the description field]

Dashboard Widgets

Dashboard widgets accept diagram content directly. Create a widget with the diagram content type, specify the engine language and source, and the diagram renders inside the widget grid. Widgets are resizable and the diagram scales accordingly.

[Screenshot: Dashboard grid with two diagram widgets — a Mermaid sequence diagram and a Graphviz dependency graph side by side]

Assistant Chat

AI assistants can generate diagrams directly in chat responses. When an assistant produces a code fence with a recognized engine tag, the diagram renders inline in the conversation. This is useful for architecture discussions, flow explanations, and design reviews.

Diagrams in dashboard widgets and ticket descriptions support the same zoom and interaction controls as the editor. See Work Management for ticket details and Editor & Diagrams for editor-specific features.


Selecting the Right Engine

Use this quick reference to pick the best engine for your task.

Use caseRecommended engine
System architecture (containers, services)structurizr
Code-level structure (classes, modules)plantuml
Sequence / async flowsmermaid
State machinesmermaid or plantuml
Database schemaerd or dbml
Dependency / call graphsgraphviz
Network topologynwdiag
Quick sketch / whiteboardexcalidraw
Statistical charts / metricsecharts
Complex data grammarvegalite

Exporting Diagrams

Every rendered diagram can be exported for use outside AgentsInFlow. Right-click (or long-press on touch) a rendered diagram to open the context menu.

  • Copy as SVG — vector output, ideal for documents and presentations
  • Copy as PNG — raster output for quick sharing in chat or email
  • Copy source — copies the raw diagram syntax to your clipboard
  • Save to file — exports the diagram as an SVG or PNG file to disk
[Screenshot: Context menu on a rendered diagram showing Copy as SVG, Copy as PNG, Copy source, and Save to file options]