Case study · AI analytics SaaS

AskBase AI

Natural-language analytics for business databases

My role
Full Stack Developer
Domain
AI analytics SaaS
Delivered at
Nextbridge Limited
End-to-end pipeline
  1. UI
    • Next.js 15
    • React 19
    • Tailwind CSS
    • Recharts
    • Three.js
  2. APIMy work
    • FastAPI
    • Uvicorn
    • slowapi
  3. NL-to-SQL engineMy work
    • askbase
    • sqlglot
    • SQLAlchemy
    • Ollama
  4. Databases
    SQL
    • MySQL
    • PostgreSQL
    NoSQL
    • MongoDB
    • Firestore

Overview

AskBase AI lets a business ask questions about its own data in plain English. Clients connect a MySQL, PostgreSQL, MongoDB or Firestore database; each question is turned into a query by a locally hosted qwen2.5-coder model via Ollama, validated with sqlglot, run read-only, and answered through a conversational interface. The frontend is a Next.js 15 app with Recharts dashboards and a Three.js 3D chart view; the backend is a Python FastAPI service backed by the askbase NL→query engine.

What I did

  • Developed the full frontend in Next.js 15 (Turbopack) with React 19 and TypeScript, using Tailwind CSS for styling, Recharts for charts, Framer Motion for animation, and Three.js / React Three Fiber for a 3D chart view.
  • Built the Python FastAPI backend and the natural-language-to-SQL pipeline using the askbase package, SQLAlchemy (async), sqlglot for SQL parsing and validation, and slowapi for rate limiting.
  • Integrated locally hosted open-source models through Ollama (qwen2.5-coder for SQL generation and qwen2.5 instruct for chat), with multi-tenant isolation, read-only query execution and caching.
  • Wired up connections to MySQL/MariaDB, PostgreSQL, MongoDB (Motor) and Google Cloud Firestore, and packaged the whole system with Docker Compose for easy deployment.

Key features

  • Natural-language questions answered from live business databases
  • Connects to MySQL/MariaDB, PostgreSQL, MongoDB (Motor) and Google Cloud Firestore
  • Queries generated by qwen2.5-coder (SQL) and qwen2.5 instruct (chat) via Ollama
  • sqlglot validates and rewrites generated SQL before execution
  • Read-only query execution with rate limiting (slowapi) and result caching
  • Recharts dashboards, Framer Motion animations, and a Three.js 3D chart view
  • Docker Compose deployment for API, UI and a demo MySQL database