Lune

ICLR2026顶会

LearNAT: Learning NL2SQL with AST-guided Task Decomposition for Large Language Models

Weibin Liao, Xin Gao, Tianyu Jia, Rihong Qiu, Yifan Zhu, Yang Lin, Xinyu Ma, Junfeng Zhao, Yasha Wang

摘要

Natural Language to SQL (NL2SQL) has emerged as a critical task for enabling seamless interaction with databases. Recent advancements in Large Language Models (LLMs) have demonstrated remarkable performance in this domain. However, existing NL2SQL methods predominantly rely on closed-source LLMs leveraging prompt engineering, while open-source models typically require fine-tuning to acquire domain-specific knowledge. Despite these efforts, opensource LLMs struggle with complex NL2SQL tasks due to the indirect expression of user query objectives and the semantic gap between user queries and database schemas. Inspired by the application of reinforcement learning in mathematical problem-solving to encourage step-by-step reasoning in LLMs, we propose LearNAT (Learning NL2SQL with AST-guided Task Decomposition), a novel framework that improves the performance of open-source LLMs on complex NL2SQL tasks through task decomposition and reinforcement learning. LearNAT introduces three key components: (1) a Decomposition Synthesis Procedure that leverages Abstract Syntax Trees (ASTs) to guide efficient search and pruning strategies for task decomposition, (2) Margin-aware Reinforcement Learning, which employs fine-grained step-level optimization via DPO with AST margins, and (3) Adaptive Demonstration Reasoning, a mechanism for dynamically selecting relevant examples to enhance decomposition capabilities. Extensive experiments on two benchmark datasets, Spider and BIRD, demonstrate that LearNAT enables a 7B-parameter open-source LLM to achieve performance comparable to GPT-4, while offering improved efficiency and accessibility. Our work marks a significant step toward democratizing NL2SQL capabilities, illustrating that carefully designed task decomposition strategies can narrow the performance gap between open-source and closed-source models. Furthermore, the proposed approach not only advances the state-of-the-art in NL2SQL but also provides valuable insights into enhancing LLMs' reasoning abilities for complex structured prediction tasks.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 6 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • ProMed: Shapley Information Gain Guided Reinforcement Learning for Proactive Medical LLMs 引用了 Direct Preference Optimization: Your Language Model is Secretly a Reward Model
  • ProMed: Shapley Information Gain Guided Reinforcement Learning for Proactive Medical LLMs 引用了 Magical: Medical Lay Language Generation via Semantic Invariance and Layperson-tailored Adaptation
  • Direct Preference Optimization: Your Language Model is Secretly a Reward Model 引用了 Training language models to follow instructions with human feedback
  • Large Language Models are Zero-Shot Reasoners 引用了 Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • Large Language Models are Zero-Shot Reasoners 引用了 Training language models to follow instructions with human feedback
  • HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face 引用了 Large Language Models are Zero-Shot Reasoners
  • HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face 引用了 Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
  • HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging Face 引用了 Training language models to follow instructions with human feedback
  • Chain-of-Thought Prompting Elicits Reasoning in Large Language Models 引用了 Training language models to follow instructions with human feedback
  • 3DS: Medical Domain Adaptation of LLMs via Decomposed Difficulty-based Data Selection 引用了 ProMed: Shapley Information Gain Guided Reinforcement Learning for Proactive Medical LLMs
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper6

  1. ProMed: Shapley Information Gain Guided Reinforcement Learning for Proactive Medical LLMsHongxin Ding, Baixiang Huang, Yue Fang, Weibin Liao 等ACL 2026 · 10 次引用
  2. Magical: Medical Lay Language Generation via Semantic Invariance and Layperson-tailored AdaptationWeibin Liao, Tianlong Wang, Yinghao Zhu, Yasha Wang 等NeurIPS 2025 · 7 次引用
  3. APEX-SQL: Talking to the data via Agentic Exploration for Text-to-SQLBowen Cao, Weibin Liao, Yushi Sun, Dong Fang 等KDD 2026 · 7 次引用
  4. 3DS: Medical Domain Adaptation of LLMs via Decomposed Difficulty-based Data SelectionHongxin Ding, Yue Fang, Runchuan Zhu, Xinke Jiang 等EMNLP 2025 · 1 次引用
  5. LEAF-SQL: Level-Wise Exploration with Adaptive Fine-Graining for Text-to-SQL Skeleton PredictionZhao Tan, Xiping Liu, Qing Shu, Qizhi Wan 等ICDE 2026

它引用的 Paper21

  1. Training language models to follow instructions with human feedbackLong Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida 等NeurIPS 2022 · 24,707 次引用
  2. Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma 等NeurIPS 2022 · 22,562 次引用
  3. Direct Preference Optimization: Your Language Model is Secretly a Reward ModelRafael Rafailov, Archit Sharma, Eric Mitchell, Christopher D. Manning 等NeurIPS 2023 · 10,924 次引用
  4. Large Language Models are Zero-Shot ReasonersTakeshi Kojima, Shixiang Shane Gu, Machel Reid, Yutaka Matsuo 等NeurIPS 2022 · 8,168 次引用
  5. HuggingGPT: Solving AI Tasks with ChatGPT and its Friends in Hugging FaceYongliang Shen, Kaitao Song, Xu Tan, Dongsheng Li 等NeurIPS 2023 · 1,778 次引用

相关 Paper

  1. STaR-SQL: Self-Taught Reasoner for Text-to-SQLMingqian He, Yongliang Shen, Wenqi Zhang, Qiuying Peng 等ACL 2025
  2. ReEx-SQL: Reasoning with Execution-Aware Reinforcement Learning for Text-to-SQLYaxun Dai, Wenxuan Xie, Xialie Zhuang, Tianyu Yang 等ACL 2026 · 8 次引用
  3. OpenSQL: Data-Efficient Text-to-SQL for Open-Source LLMs via Synthesized Intermediate SupervisionRuilin Hu, Yuyu Luo, Guoliang Li, Shuangqiao Wu 等VLDB 2026 · 4 次引用
  4. DIN-SQL: Decomposed In-Context Learning of Text-to-SQL with Self-CorrectionMohammadreza Pourreza, Davood RafieiNeurIPS 2023 · 909 次引用
  5. DB-Explore: Automated Database Exploration and Instruction Synthesis for Text-to-SQLHaoyuan Ma, Yongliang Shen, Hengwei Liu, Wenqi Zhang 等EMNLP Findings 2025 · 2 次引用
黄昏的海面,两侧是细线勾勒的悬崖