Architecture diagrams that never go stale
Your AI agent writes a few lines of text. Plotwork draws a clean, on-brand diagram and redraws it when the code changes.
A person asks their agent: Draw our checkout from infra/checkout.tf.
Works in the agent you use, and everywhere your docs live
- Claude Code
- Cursor
- VS Code
- Codex
- Windsurf
- GitHub Copilot
- GitHub
- GitHub Actions
- GitLab
- Azure Pipelines
- Notion
- Slack
- Microsoft Teams
Your wiki's diagram is already wrong. Plotwork's is drawn from the code.
From your code to a diagram in three steps
An AI agent writes orders.diagram, 9 lines of Plotwork, and sends it to the draw_diagram tool.
Step 1
Connect your agent
Add the MCP server to Claude Code, Cursor, Codex or any agent. It runs on your machine with no key.
Step 2
Point it at your code
Terraform, OpenAPI, SQL and more become diagrams with official cloud icons, in one call.
Step 3
Diagrams stay current
GitHub Actions or Azure Pipelines spots a diagram that drifted from the code and opens the pull request that redraws it.
What Plotwork does
From the first diagram on your machine to every repository in the company.
Import
Draw from the code you already have
Terraform, OpenAPI, SQL, Kubernetes and 29 more formats become diagrams with the provider's own icons, in one call.
Read the importing guideDiagrams worth putting in the docs
Real output from the engine, with official AWS, Azure and Google Cloud icons, in light and dark.
Questions, answered
Short answers for developers and platform teams. Each one links to the docs page that proves it.
What is Plotwork?
A small text language and a renderer for 29 kinds of diagram: flow, sequence, database schema, git graph, Gantt chart, class diagram, state, timeline, user journey, mind map, treemap, share chart, quadrant chart, layered architecture, C4 diagram, matrix, Sankey diagram, XY chart, tree, swimlane, requirement diagram, block diagram, packet diagram, kanban board, radar chart, use case diagram, Venn diagram, fishbone diagram and Wardley map. An agent writes a few lines of source, the tools check them and say exactly what to fix, and the same source draws a picture in light and dark.
Quick startWhich diagrams can it draw?
29 kinds: flow, sequence, database schema, git graph, Gantt chart, class diagram, state, timeline, user journey, mind map, treemap, share chart, quadrant chart, layered architecture, C4 diagram, matrix, Sankey diagram, XY chart, tree, swimlane, requirement diagram, block diagram, packet diagram, kanban board, radar chart, use case diagram, Venn diagram, fishbone diagram and Wardley map. A flow diagram covers architecture and process, a sequence diagram protocols and code flows, and a schema diagram database tables and their relations. Each kind takes a closed set of words, and the theme owns every colour.
Quick startWhere does it render?
In GitHub and VS Code Markdown, in light and dark. The tools write a picture block into your Markdown file with the source collapsed underneath, so the diagram shows without a plugin.
Quick startCan it draw AWS, Azure and Google Cloud architecture diagrams?
Yes. Group a diagram by account, region, network and subnet, then give each service a node with the icon for its product. The AWS, Azure and Google Cloud icons are drawn as each company publishes them and belong to their owners. A product without an official icon gets a glyph for its kind of service. The checks warn when a node named after a product has no icon, and say what to add.
Cloud architecture guideWhich architecture diagrams can I start from?
Ready-made, checked patterns for common systems, among them a three-tier network, a two-zone network with a replicated database, a hub and spoke network, a serverless API, microservices behind an API gateway, a container platform, an event-driven pipeline, a data lake and a starter database schema. An agent finds one, renames its parts and gets a diagram that already passes every check. Many come in an AWS, Azure or Google Cloud version.
Architecture patternsHow do I keep diagrams as code in a README or GitHub Markdown?
Write the diagram as text in a diagram fence in your Markdown file, then sync the file. The sync draws light and dark SVG files next to it and puts a picture block under the fence with the source folded away, so GitHub and the VS Code preview show the picture and the text stays in the file. A check mode fails when a picture is stale, so CI keeps them current. An agent can do the same with the sync_markdown tool.
Markdown and GitHubHow is it different from Mermaid, and can I convert my Mermaid diagrams?
The output is a static SVG file in your repository, so it needs no JavaScript to display and the same source always gives the same bytes, which keeps a diff small. The theme owns every colour, so no diagram carries styling of its own, and every mistake comes back with a line, a column and a hint. A converter turns Mermaid flowchart, sequence, ER, git, Gantt, class, state, timeline, journey, mind map, treemap, pie, quadrant, C4, sankey, XY chart, tree view, requirement, block, packet, kanban, radar, use case, Venn, Ishikawa, Wardley map, architecture and ZenUML diagrams into Plotwork, and reports anything it cannot carry over. A Mermaid type that Plotwork does not draw stays Mermaid: the converter names it and says what to do instead.
Migrating from MermaidWhat is the MCP server, and how do I connect Claude Code?
It gives an AI agent read-only diagram tools over the Model Context Protocol: read the syntax, draw and check a diagram, convert Mermaid, choose icons and sync a Markdown file. In Claude Code, run the one command below. It starts the server on your machine with no key, and needs Node 22 or newer. Cursor, VS Code and Claude Desktop connect the same way. The same tools are also a REST API.
claude mcp add plotwork -- npx -y @buun_group/plotwork-mcp@0.12.0Does it need a sign-in?
Not to run it on your machine. The local server needs no key, no sign-in and no account, because every tool is a read-only computation over what you send it. The hosted server asks for an API key from your account, or a browser sign-in, so each caller has its own limit.
MCP overviewCan an agent see the picture?
MCP clients get the SVG as text, and an outline that describes the same diagram in words, so an agent can check it says what was meant. PNG output for clients that cannot show SVG is planned.
MCP overviewStill have a question?
Draw your first diagram in five minutes
Free for one person, on your own machine. Pro for teams at $9 a month.