Text-to-SQL Analytics Assistant

Ask a business question in English. Get a grounded SQL query, a chart, and a short insight — over an 11-table music-store warehouse.

Try an example

Text-to-SQL Analytics Assistant

  • Natural-language question in · Grounded SQL + chart + insight out
  • Dataset: Chinook music store (DuckDB, 11 tables)
  • 95% execution accuracy on a 20-question benchmark

Pipeline

  1. Embed question → retrieve top-k relevant tables (sentence-transformers)
  2. LLM generates DuckDB SQL grounded on retrieved schema
  3. sqlglot validator blocks DDL/DML and enforces LIMIT
  4. DuckDB executes read-only
  5. LLM writes a short grounded narrative on the result

Model: qwen/qwen3.8-27b on Groq free tier · Source on GitHub