AgentNLQ: A General-Purpose Agent for Natural Language to SQL
Olena Bogdanov, Yeunji Jung, Chandra Dhir, Pareekshitreddy Gaddam, Saurabh Jain, Lakshmi Tumati, Vijay Parthasarathy, Anup Shirgaonkar

TL;DR
This paper introduces AgentNLQ, a multi-agent system leveraging large language models to improve natural language to SQL conversion, achieving high accuracy on the BIRD benchmark.
Contribution
The study presents a novel multi-agent orchestrator, schema enrichment techniques, and demonstrates improved accuracy and generalizability in NL2SQL tasks.
Findings
Achieved 78.1% semantic accuracy on BIRD benchmark.
Developed a multi-agent orchestrator with self-correcting capabilities.
Enhanced schema representation improves SQL generation accuracy.
Abstract
Natural language to SQL (NL2SQL) conversion is an important problem for researchers and enterprises due to the ubiquitous importance of relational databases in broad-ranging practical problems. Despite the rapid advancements in the capabilities of LLMs, NL2SQL has not reached parity in accuracy with human expert SQL writers, hence needing additional improvements in NL2SQL algorithms. This study presents a new multi-agent method for NL2SQL that achieves 78.1% semantic accuracy on the BIg Bench for LaRge-scale Database (BIRD) benchmark. Our method leverages a semantically enriched representation of user-provided schema, adds user-provided business rules, and produces accurate SQL queries. The main contributions of this study are (a) We designed an optimized new orchestrator in a multi-agent solution that uses LLMs to plan, orchestrate, reflect, and self-correct to generate accurate SQL…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
