ChartDB - The ERD Agent
Written by Nikos Vaggalis   
Thursday, 16 October 2025

ChartDB strikes back with a database agent that auto-magically draws database schemas for you.

Last February in Database Diagramming With ChartDB we looked at ChartDB as an open-source database diagrams editor that can be self-hosted or used in the Cloud which could:

  • Run a single query to instantly retrieve your database schema as JSON 
  • Generate the DDL script in the dialect of your choice
  • Finetune your database schema
  • Edit with features like undo, redo, create, manage tables & relationships.
  • Share your database with others
  • Get inspiration from a repository of ready made real world templates

This time it's going beyond manually drawing ERDs ands lets you create schemas using natural language just by describing what you need. In essence it enriched the standard UI with another option, that of the Agent.

Clicking on the Agent icon and choosing one of the default templates, such as "Design a database like Spotify", gets expanded to the prompt:

Design a database schema like Spotify with tables for users, artists, albums, tracks, playlists, and listening history

and voilĂ  there is your schema appearing:

You also get a nice description with it :

The database schema consists of seven tables:
users: Stores user information, including username, email, password, and timestamps for account creation and last login.
artists: Stores artist names, ensuring uniqueness.
....

I went a step beyond in trying to reverse engineer a popular Spring project up on GitHub:

Prompt:

Create the database of project spring-petclinic


Thus this means that you can get the underlying database schema of any application that is backed by a database and exposes its source.

Of course you can also make your own customized schemas by writing your manual prompts like

Design an e-shop for selling video games

As mentioned together with the diagram you get a high level description too, which in this case amongst others includes the following paragraph:

Primary keys are defined for each table, and foreign key constraints are used to establish relationships between tables. SERIAL is used for auto-incrementing primary keys. DECIMAL is used for monetary values. TIMESTAMP WITH TIME ZONE is used for storing timestamps. CHECK constraint is used to ensure rating values are within the valid range.

Finally you can export the DDL to import it into your database and get going from there.

As mentioned, ChartDB comes in two flavors, cloud-based or self-hosted. To host it yourself you can build it from source by cloning the Github repo or grab the docker image for convenience. 

chartdblogo

More Information

ChartDB ERD Agent

Related Articles

Database Diagramming With ChartDB 

 

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.

Banner


Europe Gets Its Own LLM
10/11/2025

EuroLLM is a fully open-sourced large language model made in Europe and built to support all twenty-four official EU languages.



C# Could Overtake Java in TIOBE Index
13/11/2025

C# 14, the latest Long Term Support release of the .NET language was released this week as part of .NET 10. Currently in fifth position in the TIOBE Index rankings it looks set to overtake Java and it [ ... ]


More News

pico book

 

Comments




or email your comment to: comments@i-programmer.info