mlsanityData to 7 Oct 2026

Optimizing Small Language Models for NL2SQL via Chain-of-Thought Fine-Tuning

arXiv 2603.22942 ↗First posted 24 Mar 2026cs.AIcited by 1

On the map: LLM reasoning → Knowledge- and tool-augmented reasoning

Abstract (arXiv)

Translating Natural Language to SQL (NL2SQL) remains a critical bottleneck for democratization of data in enterprises. Although Large Language Models (LLMs) like Gemini 2.5 and other LLMs have demonstrated impressive zero-shot capabilities, their high inference costs limit deployment at scale. This paper explores the efficacy of fine-tuning both large and small language models on NL2SQL tasks. Our research reveals a counter-intuitive scaling phenomenon. Fine-tuning large models (Gemini 2.5 Flash/Lite) on standard datasets yields negligible returns, often leading to overfitting on complex queries. Conversely, small models (Qwen) show significant gains. Fine-tuning improved the small model baseline from 36% to 45%, and further enriching the dataset with explicit Chain-of-Thought (CoT) reasoning surged accuracy to 54.5%(Fig 2). While this is still lower than the accuracy of large models like Gemini 2.5 , it does serve the business goal of significant cost reduction, latency in inference time and also meeting the business critical performance accuracy threshold.This paper demonstrates that transferring reasoning patterns enables compute-efficient smaller models to approach production-grade performance.

Key facts. Cited by 1 paper in the map (data through 7 Oct 2026). Placed in Knowledge- and tool-augmented reasoning, one of 17 directions in LLM reasoning. Builds on 7 of its 8 references that are in the map. First posted on arXiv 24 Mar 2026.

Builds on

7 of 8 references.

References · 7

  1. 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,302
  2. 2023Qwen Technical Reportcited by 3,273
  3. 2024Gemini 1.5: Unlocking multimodal understanding across millions of tokens of contextcited by 3,175
  4. 2018Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Taskcited by 1,120
  5. 2019RAT-SQL: Relation-Aware Schema Encoding and Linking for Text-to-SQL Parserscited by 420
  6. 2022Teaching Small Language Models to Reasoncited by 279
  7. 2023A comprehensive evaluation of ChatGPT's zero-shot Text-to-SQL capabilitycited by 118

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2026: 1.

1 paper.

Similar, not cited

Close in wording, no citation either way

  1. 2025SLM-SQL: An Exploration of Small Language Models for Text-to-SQL
  2. 2023Interleaving Pre-Trained Language Models and Large Language Models for Zero-Shot NL2SQL Generation
  3. 2025LearNAT: Learning NL2SQL with AST-guided Task Decomposition for Large Language Models
  4. 2024LR-SQL: A Supervised Fine-Tuning Method for Text2SQL Tasks under Low-Resource Scenarios
  5. 2025Do LLMs Align with My Task? Evaluating Text-to-SQL via Dataset Alignment
  6. 2025Think2SQL: Reinforce LLM Reasoning Capabilities for Text2SQL
  7. 2025Rethinking Agentic Workflows: Evaluating Inference-Based Test-Time Scaling Strategies in Text2SQL Tasks
  8. 2026LLM NL2SQL Robustness: Surface Noise vs. Linguistic Variation in Traditional and Agentic Settings