OpenSearch-SQL: Enhancing Text-to-SQL with Dynamic Few-shot and Consistency Alignment
Xiangjin Xie, Guangwei Xu, Lingyan Zhao, Ruijie Guo

TL;DR
OpenSearch-SQL introduces a modular architecture with an alignment mechanism, dynamic few-shot learning, and structured reasoning to significantly improve Large Language Models' performance on Text-to-SQL tasks, achieving state-of-the-art results.
Contribution
It presents a novel framework combining alignment, intermediate language, and dynamic few-shot strategies, enhancing accuracy and robustness without additional model training.
Findings
Achieved 72.28% execution accuracy on the test set.
First place in R-VES and accuracy metrics at submission.
Demonstrated effectiveness and efficiency of the proposed methods.
Abstract
Although multi-agent collaborative Large Language Models (LLMs) have achieved significant breakthroughs in the Text-to-SQL task, their performance is still constrained by various factors. These factors include the incompleteness of the framework, failure to follow instructions, and model hallucination problems. To address these problems, we propose OpenSearch-SQL, which divides the Text-to-SQL task into four main modules: Preprocessing, Extraction, Generation, and Refinement, along with an Alignment module based on a consistency alignment mechanism. This architecture aligns the inputs and outputs of agents through the Alignment module, reducing failures in instruction following and hallucination. Additionally, we designed an intermediate language called SQL-Like and optimized the structured CoT based on SQL-Like. Meanwhile, we developed a dynamic few-shot strategy in the form of…
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.
Taxonomy
MethodsBalanced Selection
