Skip to main content

✎ DesignCore

License: MIT Python 3.11+ CI

🌐 Project website

Verified diagrams for documentation — draw.io, Mermaid, or Excalidraw, from a spec your AI agent can actually be trusted to write.

DesignCore turns a coordinate-free graph spec into a verified diagram, where the model never places a shape and nothing counts as finished until it has actually rendered. It ships three agent skills (architecture-diagram, flow-diagram, concept-sketch) that carry the judgment layer on top.


🧭 What "verified" means

The spec compiled cleanly, every backend rendered successfully, and deterministic structural/density/geometry checks passed.

It does not mean the diagram is visually correct or that it communicates well — judgment about content stays with you.


⚖️ The two rules

Rule Enforcement
1️⃣ The model never writes coordinates. x, y, width, height, position are rejected at parse time. Geometry comes from Graphviz — always.
2️⃣ No diagram is complete without a successful render. A missing backend raises BackendMissing naming its install command; a spec never degrades quietly into an unverified result.

LLMs are good at structure and bad at pixels. DesignCore splits the job along exactly that line: judgment lives in the skills, mechanism lives in the package.


🚀 Install

Requires uv.

# As an installable CLI tool (from GitHub today; PyPI pending)
uv tool install git+https://github.com/BlinkVoid/DesignCore.git

# Or from a clone, for development
git clone https://github.com/BlinkVoid/DesignCore.git && cd DesignCore
uv sync
uv run designcore doctor

Render backends

designcore doctor reports what's available and names the exact install command for anything missing:

backend used for
mmdc (mermaid-cli) rendering Mermaid
dot (graphviz) computing all node geometry
drawio (snap) exporting .drawio to SVG/PNG
node the Excalidraw SVG export helper

The Excalidraw helper needs its own dependencies once:

npm install --prefix src/designcore/render/js
🔧 Platform notes & portability caveats

Verified on Linux. Full detail in docs/plans/2026-08-16-render-backend-findings.md.

backend caveat
dot (graphviz) No sudo? Graphviz installs fine via apt-get download + dpkg -x into ~/.local with a GVBINDIR wrapper
drawio (snap) Strict snap confinement: exports must run under $HOME, never /tmp; wrapper already injects --no-sandbox; headless export via xvfb-run -a
mmdc Bundled Chromium may fail under AppArmor's userns restriction; renderer prefers a system browser, falls back to --no-sandbox only when none exists
Excalidraw helper jsdom shims load before @excalidraw/utils

macOS/Windows are untested for 0.1; spec/lint are pure Python — the risk sits entirely in the external backends.


🛠️ Commands

command does
designcore new <id> --kind <kind> scaffold a spec with the question: prompt
designcore render <id> compile → lay out → render → lint, and record a manifest entry
designcore lint <id> structural, density, and geometry checks over spec and render
designcore check validate diagrams.yaml against what is on disk (content-fingerprinted, clone-safe)
designcore doctor report backend availability + install commands

--root points at the diagram directory (default docs/diagrams). render also takes --format, and the choice is sticky: an explicit flag wins over the manifest's recorded format, which wins over the excalidraw default. A diagram has one format and one manifest entry at a time — switching format replaces the entry, and check reports the abandoned files as orphans.

💡 Mermaid is the right choice when the diagram lives in markdown: it renders natively on GitHub and diffs as text. See skills/_shared/references/format-selection.md.


📐 How it fits together

.spec.yaml ──► parse_spec ──► layout_spec (Graphviz) ──┬──► emit_* ──► source file
                                                       │                  │
   rejects coordinates                                 │                  ▼
   at parse time                                       │              render_* ──► svg + png
                                                       │                  │
                                                       └────────────── lint ◄┘
                                                                          │
                                                                     diagrams.yaml

Judgment lives in the skills; mechanism lives in the package. The package makes no aesthetic decisions, and the skills compute no geometry.


📁 Example

A worked example lives in examples/docs/diagrams/: one spec, its excalidraw render, and a populated manifest.

uv run designcore render designcore-pipeline --root examples/docs/diagrams

📚 Further reading

doc contents
ARCHITECTURE.md layer map and module layout
docs/plans/2026-08-16-designcore-design.md the design spec — and why each decision was made
docs/plans/2026-08-16-render-backend-findings.md what each render backend actually does on real hardware

📄 License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

designcore-0.1.0.tar.gz (283.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

designcore-0.1.0-py3-none-any.whl (44.5 kB view details)

Uploaded Python 3

File details

Details for the file designcore-0.1.0.tar.gz.

File metadata

  • Download URL: designcore-0.1.0.tar.gz
  • Upload date:
  • Size: 283.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for designcore-0.1.0.tar.gz
Algorithm Hash digest
SHA256 60170129f03a6d7fbaa529153f6f62d1b3c8a82f4f376ae2de486c7ea4b327f7
MD5 3639177c756b60826efaf8aa04079a63
BLAKE2b-256 9e111486efbde1d0c4c138509f1f760f3c7d198c86726a5910125797daa10114

See more details on using hashes here.

Provenance

The following attestation bundles were made for designcore-0.1.0.tar.gz:

Publisher: publish-pypi.yml on BlinkVoid/DesignCore

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file designcore-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: designcore-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 44.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for designcore-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 de1273abc59c06bb707f697936697ea369a5049f48d42a7c175d33c40b55413c
MD5 e1dacc27e3eb37ff11ce6639fcb38a63
BLAKE2b-256 d16b2e8c8aa64e788b8bd9377d1462ec028d8e51ddcfd75a14727c37c896e62a

See more details on using hashes here.

Provenance

The following attestation bundles were made for designcore-0.1.0-py3-none-any.whl:

Publisher: publish-pypi.yml on BlinkVoid/DesignCore

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page