NexusSQL: Production SQL Agent for 100+ Table Databases with SQLAS Evaluation
Authors/Creators
Description
Enterprise databases routinely contain hundreds to thousands of tables, yet existing Text-to-SQL systems were designed for academic benchmarks with small schemas (Spider: avg 5.3 tables/DB). Injecting a full 200-table schema into a single LLM prompt requires ≈41,300 tokens per query, a 21× cost multiplier that is economically infeasible at production scale. Equally critical, no standardized evaluation framework exists for SQL agents: existing frameworks measure only binary execution accuracy, leaving safety, quality, and schema retrieval quality unmeasured. We present two complementary systems. NexusSQL is a production full-stack SQL agent (ReactJS + FastAPI) that handles 100+ table schemas through a four-layer adaptive retrieval pipeline (BM25 sparse retrieval, dense embedding retrieval, Reciprocal Rank Fusion (RRF), and FK-graph expansion), reducing prompt token usage by 95.3% versus full-schema injection while maintaining competitive execution accuracy. SQLAS is the first standardized evaluation framework for SQL agents, providing SQL-specific metrics no existing framework offers: execution accuracy, schema retrieval F1, a three-dimensional AND-logic verdict (correctness / quality / safety), and 15 named failure categories with actionable remediation hints.
Files
ICDE2027_NexusSQL_SQLAS.pdf
Files
(1.7 MB)
| Name | Size | Download all |
|---|---|---|
|
md5:a2b8fbf67bc4ca32da9ad476a480b033
|
1.7 MB | Preview Download |
Additional details
Dates
- Updated
-
2026-05-15
Software
- Repository URL
- https://github.com/thepradip/NexusSQL
- Programming language
- Python
- Development Status
- Active