Skip to content
← All articles
Project introduction

D2C OpenAI plugin — diagrams with PlantUML, Mermaid, and D2

Listen to the audio story

Drawing diagrams by just asking ChatGPT · 2:16 · AI-written script, synthetic voices

Transcript

Ava: A teammate describes a flow in chat, and ten minutes later you need a sequence diagram in your repo. What's the fastest way to get there?

Andrew: Honestly? A photo of the whiteboard and a lot of squinting.

Ava: Ha, that was Antoine's problem too. A whiteboard photo doesn't paste into a Markdown repo, and typing PlantUML from memory is slow. So he built D2C OpenAI Plugin, a ChatGPT plugin that turns a conversation into a real diagram without leaving the thread.

Andrew: What kind of diagrams are we talking about?

Ava: Three formats. PlantUML for UML sequences, classes and deployments. Mermaid for diagrams that GitHub shows natively. And D2 for modern, declarative system sketches. The point is text-native diagrams he can drop into blog posts, READMEs and design reviews.

Andrew: So how does it work in practice?

Ava: You name the diagram type in your request. The model writes the syntax, the plugin sends it to the right renderer, and you paste the result into your Markdown. Think of the plugin as a switchboard operator: it connects your request to the right drawing tool.

Andrew: Do you have an example?

Ava: A good one from the post: a PlantUML sequence with a user, a React app, FastAPI and Postgres, including the login and a cache miss path. Another asks for a Mermaid flowchart of a CI pipeline, from git push through lint, test, build image and deploy on AWS. And a D2 diagram of a homelab with Caddy on EC2, CloudWatch logs and Lambda alerts.

Andrew: That's quite a range from one chat box.

Ava: It is, and it fits the same habit as his later work with AIPRM prompt templates, just wired in as a plugin action. The post has a screenshot and an animated demo of diagrams appearing right in the ChatGPT thread.

Andrew: Has the idea moved on since the plugin era?

Ava: Yes. Antoine carried the same loop forward with uml-mcp, which brings diagram generation to Cursor and other M C P hosts. Same idea, new home.

Andrew: So the takeaway is that diagrams can be a conversation.

Ava: Exactly. Say what you want drawn, get text you can version and share. The full write-up has the demo and the example prompts if you want to try them.

D2C OpenAI plugin — diagrams with PlantUML, Mermaid, and D2
Table of contents

D2COpenAIPlugin is a ChatGPT plugin that turns conversation into PlantUML, Mermaid, or D2 without leaving the thread. I built it when OpenAI plugins were the main extension story — useful for architecture sketches, lab docs, and “draw this flow” moments in chat.

1. User story

A teammate describes a flow in chat; I need a sequence diagram in the repo ten minutes later. Before the plugin, that meant exporting a whiteboard photo or hand-typing PlantUML from memory. With D2C, the model emits syntax, the plugin renders it, and I paste the result into Markdown — same loop I use today with MCP, different host.

2. Why not only screenshots?

Whiteboards do not paste into Markdown repos. I wanted text-native diagrams I could drop into Hugo posts, GitHub READMEs, and design reviews — the same motivation as later Diagram prompts with ChatGPT and AIPRM, but wired as a plugin action instead of a pasted template.

3. Original workflow

In the original plugin workflow, the request named the diagram type explicitly, for example a PlantUML sequence for React, an API, Redis, and a database. The project documentation covers the service and its setup.

The model still hallucinates syntax sometimes; the plugin’s job is to route to the right renderer, not to guarantee perfect UML.

4. Demo

Static capture of the plugin surface in ChatGPT:

Plugin screenshot — diagram output in the ChatGPT thread

Animated walkthrough:

Demo animation — generating UML from chat

5. What it supports

FormatGood for
PlantUMLUML sequences, classes, deployments in docs
MermaidGitHub-native diagrams, quick flows
D2Modern declarative system sketches

6. Example prompts that worked

Sequence diagram in PlantUML: user, React app, FastAPI, Postgres — include login and cache miss path.
Mermaid flowchart: CI pipeline from git push to deploy on AWS — lint, test, build image, ECR, ECS.
D2 diagram: homelab — Caddy on EC2, CloudWatch logs, Lambda alerts (keep boxes readable).

7. Limits

  • Plugin platform churn — OpenAI’s plugin story moved; treat this as historical tooling plus repo reference.
  • Validation — always render locally (PlantUML server, Mermaid live editor) before publishing.
  • Secrets — never ask the model to diagram production credentials inline.

Successor-style work for editors: uml-mcp[1] for Cursor and MCP hosts.

References

  1. antoinebou12. (). uml-mcp. [Software repository] github.com.

References use this article’s publication date.