Ask your data.
Trust the answer.

BoloDB is a multi-tenant text-to-SQL web application powered by DeepSeek v4 Flash via OpenRouter. Connect any SQL database, ask questions in plain English, and get instant answers with charts, confidence levels, and automatic self-repair. Manage workspaces with role-based access control.

Documentation

Architecture Overview

Browser (SvelteKit 5 frontend, frontend/src) │ HTTP / SSE streaming (JWT cookie auth, X-Workspace-Id, X-Db-Id) ▼ FastAPI backend (backend/app) │ ├── controllers/query.py ── the question→answer pipeline (the heart) ├── llm.py ──────────────── the ONLY file that talks to OpenRouter (DeepSeek v4 Flash) ├── schema_link.py ──────── scores tables, picks what the AI sees ├── sqlvalidate.py ──────── static AST validation against real schema ├── repair.py ───────────── self-repair loop with schema-retry ├── semantic.py ─────────── semantic layer catalog & inference ├── database.py ─────────── DB introspection & read-only execution ├── dialects.py ─────────── per-dialect traits (PostgreSQL, MySQL, Oracle, Snowflake...) ├── pgdatabase/ ─────────── async PostgreSQL persistence (knowledge, users, workspaces) └── permissions.py ──────── RBAC — 21 capabilities across 7 resources