Ask questions about your data in plain English — get real SQL, real results, and an AI-generated summary, all running against a live database. Built as a portfolio project to demonstrate SQL fluency, LLM integration, and safe database interaction patterns.
- You type a question in plain English (e.g. "Which suburb had the highest CAGR?")
- The app reads the live database schema automatically (no hardcoded table definitions)
- An LLM (Nvidia Nemotron via OpenRouter) generates a SQL query from your question + the real schema
- The query is checked against a safety filter (blocks anything that isn't a pure
SELECT) - The query runs against a live Turso (libSQL/SQLite) database
- Results are shown as a table, summarized in plain English, and made explorable via an interactive drag-and-drop chart builder (PyGWalker)
- Turso — serverless SQLite (libSQL), chosen to demonstrate range beyond Postgres-based tools (Supabase, Neon) used elsewhere in this portfolio
- OpenRouter + Nvidia Nemotron — free-tier LLM access, consistent with the rest of this portfolio's AI integrations
- PyGWalker — turns raw query results into an interactive, Tableau-style visual explorer with zero extra code per chart
- Dynamic schema detection — the app queries
sqlite_masterandPRAGMA table_infoat runtime, so it adapts automatically to whatever tables exist — no code changes needed to point it at new data
- Only
SELECTstatements are ever executed — the app blocksDROP,DELETE,UPDATE,INSERT,ALTER,TRUNCATE,CREATE, andREPLACEbefore running anything - Generated queries are always shown to the user before/alongside results, so nothing runs silently
Python · Streamlit · Turso (libSQL) · OpenRouter API · PyGWalker · pandas
pip install -r requirements.txtCreate a .env file:
TURSO_DATABASE_URL=libsql://your-database-url.turso.io
TURSO_AUTH_TOKEN=your_token_here
OPENROUTER_API_KEY=your_openrouter_key_here
Run:
python -m streamlit run app.py- Which suburb had the highest CAGR?
- Compare Mickleham and Kalkallo prices over time
- What's the average median price across all suburbs in 2026?
Khoshaba Odeesho — github.com/Assyrian91 · LinkedIn