Generate logical, application, or infrastructure architecture diagrams from a text based source file.
Catch overlapping diagram labels automatically in continuous integration before they ship in documents.
Export an infrastructure flow matrix as CSV, Markdown, or SVG for technical architecture documents.
Produce architecture diagrams in English or French with customizable theme colors.
| r0kshan/cairn | angelsswordstudios/angelssword-adventurers-creator | avacocloud/avaco-railway | |
|---|---|---|---|
| Stars | 37 | 37 | 37 |
| Language | JavaScript | JavaScript | JavaScript |
| Setup difficulty | easy | easy | moderate |
| Complexity | 3/5 | 2/5 | 3/5 |
| Audience | developer | general | ops devops |
Figures from each repo's GitHub metadata at analysis time.
Pre-release status, CLI and browser playground both ship template initializers for each diagram type.
Cairn is a command line tool for creating software architecture diagrams from written code instead of dragging shapes around in a graphical editor. It focuses specifically on three kinds of views used in technical architecture documents: logical, application, and infrastructure diagrams. It is built on top of Elkjs, a layout engine, and comes both as a CLI and as a browser based playground, both of which offer starter templates for each diagram type, live preview, and export to SVG and PNG images. The project explains its own reasoning: many teams still draw these diagrams by hand in tools like Drawio, which gives fine control but is slow to update and hard to keep consistent. Existing diagram as code tools exist, but on complex architecture diagrams with many connections they tend to produce layouts that are either too large or have overlapping labels that become unreadable, which does not work for formal documents that require clear logical, application, and infrastructure views. To address that, Cairn checks for label overlaps on every build and treats any overlap as a failure that can be caught in continuous integration, keeping each connection line and its label distinct and readable. It supports different layout dispositions for slides versus full pages, validates diagrams against typed rules for each view and reports clear, source located errors, and can export an infrastructure flow matrix as CSV, Markdown, or SVG, splitting protocol and port information and labeling each connection point by its network zone. Output can be generated in English or French, and colors can be customized per element type using built in or custom themes. The README is upfront that Cairn is not meant to replace general purpose diagramming tools: for flowcharts or sequence diagrams, tools like Mermaid or D2 are recommended instead, and for detailed C4-style software structure modeling, dedicated tools such as Structurizr or LikeC4 are suggested. The project is currently in a pre-release state, with the maintainer waiting on early user feedback and open issues before calling it stable.
Cairn is a command line diagram-as-code tool focused on logical, application, and infrastructure software architecture views, with overlap-free layouts and validation.
Mainly JavaScript. The stack also includes JavaScript, Elkjs, CLI.
Setup difficulty is rated easy, with roughly 30min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
double-check against the repo, no cap.