All projects

NL2SQL / Enterprise Data Intelligence

AskDB

Conversational NL2SQL system translating plain English inquiries into validated database queries via domain intent classification, contextual schema grounding, and strict SELECT-only AST security gates.

AskDB product interface
94% First-Pass
SQL Accuracy
100% SELECT-Only AST
Security Policy
3-Attempt Error Repair
Self-Healing
Table + Graph + Summary
Output Modes

Architecture & Overview

Engineering intelligence around real operational constraints.

An enterprise database intelligence assistant enabling non-technical stakeholders to talk directly with relational databases in plain English. The architecture begins with a domain classifier that routes the question to the correct module (e.g., federations, societies, banks). It then dynamically retrieves relevant table DDL schemas, enterprise business logic rules, and curated gold-standard SQL pairs from a Qdrant semantic store. After SQL synthesis, a hardened AST-based security gate verifies the query is strictly a read-only SELECT statement, and an automated 3-attempt self-correction loop catches syntax or execution errors before rendering synchronized data tables, dynamic charts, and natural language summaries.

Execution Lifecycle

How the System Works End-to-End

01

Module & Intent Classification

Analyzes incoming plain-English business inquiries and classifies them across relevant domains (banks, federations, societies, operational databases).

02

Dynamic Context & Schema Grounding

Semantically retrieves matching table DDL schemas, enterprise business rules, column aliases, and curated few-shot training query pairs from Qdrant.

03

Dialect-Specific SQL Synthesis

Feeds the grounded context into the LLM to generate precise, optimized SQL queries matching the target database dialect.

04

AST Security Gate & Repair Loop

An AST parser validates that the generated SQL is strictly a read-only SELECT query, blocking any mutations or injections, with an automated 3-attempt self-healing repair loop on errors.

05

Synchronized Multi-Modal Presentation

Executes the query and simultaneously delivers a structured data table, interactive charts/visualizations, and an executive natural-language summary.

Security Architecture & Presentation Layer

Intent routing across federations, cooperative societies, and banking modules
AST-level SQL inspection enforcing strict SELECT-only permissions with zero write/mutation access
3-attempt automated dialect self-repair loop resolving missing joins or column mismatches
Dynamic visualization engine transforming tabular outputs into bar, line, and pie charts

Engineering Highlights

Capabilities & Guardrails

Domain intent classification routing queries across federations, societies, and banking modules
Semantic retrieval of annotated DDL schemas, business rules, and gold-standard SQL pairs using Qdrant
Hardened security gate enforcing strict read-only SELECT execution with zero write permissions
Automated 3-attempt SQL repair loop resolving dialect-specific syntax errors and schema mismatches
Synchronized multi-modal response rendering interactive data tables, graphs, and narrative summaries

Product Screenshots

A closer look at the interface

Continue exploring

View all selected work