Favicon of Vanna

Vanna

An open-source SQL agent you can self-host, with Ollama support, database permissions, and a web chat interface. MIT licensed; the project is archived.

Screenshot of Vanna website

Vanna is a self-hosted Python framework for building AI agents that answer database questions in plain language. It's for teams adding chat to analytics products or internal data tools, especially when each user needs different access to the data. The project is archived and no longer maintained. Its open-source code uses the MIT license.

The agent turns questions into SQL and returns interactive tables, Plotly charts, and written summaries. It supports follow-up questions and streams progress and results into an embeddable web interface. That interface works with React, Vue, or plain HTML, so teams can add database chat to an existing application.

User identity carries through to query execution. Vanna can filter queries according to each user's row-level permissions and connect to an application's existing authentication, including cookies, JWTs, and OAuth tokens. It also supports query auditing, per-user rate limiting, and stored conversation history.

You can use Ollama as the model backend or connect to cloud providers such as OpenAI, Anthropic, and Gemini. Database connections include PostgreSQL, MySQL, SQLite, Snowflake, BigQuery, DuckDB, and SQL Server. Self-hosting the framework doesn't make a connected cloud model or database local.

Vanna also offers a cloud option and optional hosted administration features. Those hosted services cover access control, tracing, vector storage for agent memory, file storage, audit logs, and retention of conversations and logs.

Similar to Vanna