Generate architecture diagrams from Claude Code.
Keep working in Claude Code and get a diagram that a layout solver produced.
Add Lucid Train to Claude Code as an stdio MCP server and its diagram tools become available in your session as mcp__lucid__emit_diagram. Claude Code supplies a semantic graph of components and edges after reading your repository, and the ELK layout engine positions them, so you get a laid-out architecture diagram without leaving the terminal and without the model choosing coordinates.
Why not just ask for Mermaid
You can, and for a five-box flow it is the right answer. Two limits show up quickly: Mermaid's layout starts producing crossing edges and awkward spacing past roughly twenty to thirty nodes with only coarse direction hints to fight it, and there is no way to attach a real service logo to a node so every box looks alike. Both matter on a diagram of a real system and neither matters on a small one.
What changes with the MCP server
Claude Code still does the reading and the reasoning, which is what it is good at. It hands over a semantic graph rather than a picture, and a constraint solver does the arrangement. The diagram comes back with tier bands so dependency direction is visible, bundled service icons, and orthogonal routing.
Setup
Add it as a command-type MCP server in your Claude Code configuration. The tools appear namespaced as mcp__lucid__*.
Transport
Connections are stdio: the server runs as a local child process with piped stdin and stdout. Remote HTTP and SSE servers appear in the Connectors tab's registry search but cannot be connected, and that is a real limit rather than a configuration step you are missing. A remote server needs a local stdio bridge in front of it.
Or run Claude Code the other way round
Lucid Train can also drive Claude Code as its execution engine, alongside Codex, Cursor and OpenCode, selectable per tab with each CLI's permission model mapped onto one set of approval modes. Which direction suits depends on whether you want the canvas in front of you or the terminal.
Add the server
Questions
Related
- Architecture Diagram MCP ServerPoint your existing agent at it and get diagrams that a solver laid out rather than a language model.
- Architecture Diagrams in CursorStay in the editor, get a diagram a solver arranged.
- draw.io MCP Server AlternativeThe difference is who decides where the boxes go.
- Excalidraw MCP Server AlternativeSame format, no lock-in, and a solver does the arranging.