What problem does it solve?
Documenting the actual database schema behind an Entity Framework Core codebase requires manually tracing DbContext classes, Fluent API configurations, and migrations, which is slow and error-prone.
Core Features & Use Cases
- EF Core Model Extraction: Reads DbContext, DbSet declarations, IEntityTypeConfiguration classes, Fluent API mappings, and migrations to build an accurate persistence model.
- D2 Diagram Generation: Produces .d2 source files with sql_table nodes, cardinality-labeled edges, owned types, many-to-many join tables, indexes, and grouping by bounded context, schema, or namespace.
- Configurable Output: A mandatory questionnaire controls column detail, nullable markers, enum display, technical table visibility, layout engine, and output format.
- Use Case: A developer onboarding to a large ASP.NET Core project asks for an ERD of the main DbContext; the skill inspects the mappings and migrations, then delivers a renderable .d2 file plus the d2 CLI render command.
Quick Start
Ask the assistant to generate a D2 database diagram from the EF Core DbContext in this repository and render it to SVG.