AI assistants can write SQL.
But writing SQL is only a small part of working with a real database.
Most database work is investigation:
That is what I built DBeast for.
DBeast is a PostgreSQL MCP server that gives AI assistants structured DBA-style tools for understanding, analyzing, and troubleshooting PostgreSQL databases.
GitHub: https://github.com/snss10/DBeast
A lot of AI database integrations start with a simple tool:
execute_sql(query)
That is useful, but it is also incomplete.
A good database assistant should not just run SQL.
It should help you reason about the database.
It should inspect schemas, explain query plans, identify maintenance issues, detect security risks, analyze data quality, and help you understand the impact of changes before you make them.
That is the idea behind DBeast.
DBeast exposes 21 MCP tools for PostgreSQL across areas like:
Instead of giving the assistant one giant database tool, DBeast gives it focused tools that map to real DBA workflows.
I do not want AI assistants to be just SQL autocomplete.
I want them to become useful database copilots.
With DBeast, you can ask things like:
Show me how the sales schema is structured and generate an ERD.
Investigate why this dashboard query is slow and suggest indexes.
Review the public schema for maintenance issues, security risks, and data quality problems.
Compare table bloat, dead tuples, and index health across all schemas.
Find columns that may contain sensitive customer data.
Check replication lag and tell me if anything looks unhealthy.
That is much more useful than just:
Run this SQL.
DBeast is designed to be safe by default.
SELECT
queries can run with automatic row limits.
But write operations like:
INSERT
UPDATE
DELETE
DROP
TRUNCATE
are not executed directly.
They are analyzed as impact previews.
So instead of blindly running a risky query, your assistant can tell you:
The human stays in control.
DBeast runs as a local MCP server.
AI assistant -> DBeast MCP server -> PostgreSQL
Your assistant talks to DBeast through the Model Context Protocol. DBeast talks to PostgreSQL using asyncpg.
It works with:
git clone https://github.com/snss10/DBeast.git
cd DBeast
pip install -e .
Example MCP config:
{
"mcpServers": {
"dbeast": {
"type": "stdio",
"command": "python",
"args": ["/absolute/path/to/DBeast/src/server.py"],
"env": {
"DATABASE_URL": "postgresql://user:password@localhost:5432/mydb"
}
}
}
}
Then ask your assistant about your database.
DBeast may be useful if you:
This is an early release, and I would love feedback from:
I’m especially interested in:
GitHub: https://github.com/snss10/DBeast