Skip to content

erdify Documentation

erdify parses your model files using AST (Abstract Syntax Tree) and generates comprehensive ERD diagrams in PlantUML format. It supports SQLModel, SQLAlchemy 2.0, Django ORM, Pydantic and standard-library dataclasses, plus SQL DDL files via the optional erdify[sql] extra — no database connection required. This documentation covers installation, usage, framework support and viewing the generated diagrams.

Contents

  • Installation — install via pip, uv, pipx or run with uvx
  • Quickstart — the handful of commands you'll use most, with links to the details
  • Features — the full matrix of what erdify recognizes when parsing your models
  • CLI & Python API — command-line options, running as a module, and the Python API (incl. programmatic access)
  • Output Formats — PlantUML and Mermaid, --format, output naming
  • Filtering & Key Inference--exclude, --exclude-paths, --sources, and --infer-keys
  • Viewing the Diagram — render online, locally with PlantUML, or in VS Code
  • CI/CD & pre-commit — keep ERDs up to date in CI and via pre-commit hooks
  • Frameworks Overview — the five frameworks side by side, how each is detected, and a worked example with the generated PlantUML
  • Django ORM — Django-specific parsing details (FK mapping, type mapping, enums, abstract bases, db_table)
  • SQL DDL — generate ERDs from .sql files via the optional erdify[sql] extra (CREATE TABLE, foreign keys, enums)