Memo-SQL: Structured Decomposition and Experience-Driven Self-Correction for Training-Free NL2SQL

Yang Zerui, Weichuan Wang, Yanwei Xu, Linqi Song, Yudai Matsuda, Wei Han, Bo Bai


Abstract
Existing NL2SQL systems face two critical limitations : (1) they rely on in-context learning with only correct examples, overlooking the rich signal in historical error–fix pairs that could guide more robust self-correction; and (2) test-time scaling (TTS) approaches often decompose questions arbitrarily, producing near-identical SQL candidates across runs and diminishing ensemble gains. Moreover, these methods suffer from a stark accuracy–efficiency trade-off: high performance demands excessive computation, while fast variants compromise quality. We present Memo-SQL, a training-free framework that addresses these issues through two simple ideas: structured decomposition and experience-aware self-correction. Instead of leaving decomposition to chance, we apply three clear strategies, entity-wise, hierarchical, and atomic sequential, to encourage diverse reasoning. For correction, we build a dynamic memory of both successful queries and historical error–fix pairs, and use retrieval-augmented prompting to bring relevant examples into context at inference time, no fine-tuning or external APIs required. On BIRD, Memo-SQL achieves 68.5% execution accuracy, setting a new state of the art among open, zero-fine-tuning methods, while using over 10× fewer resources than prior TTS approaches.
Anthology ID:
2026.findings-acl.253
Volume:
Findings of the Association for Computational Linguistics: ACL 2026
Month:
July
Year:
2026
Address:
San Diego, California, United States
Editors:
Maria Liakata, Viviane P. Moreira, Jiajun Zhang, David Jurgens
Venue:
Findings
SIG:
Publisher:
Association for Computational Linguistics
Note:
Pages:
5130–5148
Language:
URL:
https://preview.aclanthology.org/ingest-acl/2026.findings-acl.253/
DOI:
Bibkey:
Cite (ACL):
Yang Zerui, Weichuan Wang, Yanwei Xu, Linqi Song, Yudai Matsuda, Wei Han, and Bo Bai. 2026. Memo-SQL: Structured Decomposition and Experience-Driven Self-Correction for Training-Free NL2SQL. In Findings of the Association for Computational Linguistics: ACL 2026, pages 5130–5148, San Diego, California, United States. Association for Computational Linguistics.
Cite (Informal):
Memo-SQL: Structured Decomposition and Experience-Driven Self-Correction for Training-Free NL2SQL (Zerui et al., Findings 2026)
Copy Citation:
PDF:
https://preview.aclanthology.org/ingest-acl/2026.findings-acl.253.pdf
Checklist:
 2026.findings-acl.253.checklist.pdf