Addressing Data Scarcity: Augmentation Strategies in Text-to-SQL

  • Felipe Aníbal Nunes Brito Universidade de São Paulo (USP)
  • Kelly Rosa Braghetto Universidade de São Paulo (USP)

Resumo


This work explores data augmentation as a strategy to overcome the scarcity of training data for Text-to-SQL translation models in low-resource domains. Six synthetic data generation strategies were applied to a novel dataset containing questions and SQL queries on Brazilian educational and geographic data. Experiments fine-tuning the LLM Mistral 7B demonstrated that using synthetic training data yields superior performance compared to using only original data. Furthermore, combining two augmented datasets allowed for even greater performance gains across several standard literature metrics, in addition to enabling the model to translate queries of greater structural complexity that were not handled by the models without augmented data.
Palavras-chave: Data augmentation, Text-to-SQL, LLM, Brazilian Portuguese

Referências

Androutsopoulos, I., Ritchie, G. D., and Thanisch, P. (1995). Natural language interfaces to databases-an introduction. Natural language engineering, 1(1):29–81.

Cai, Q., Liang, H., Xu, C., Xie, T., Zhang, W., and Cui, B. (2025). Text2SQL-flow: A robust SQL-aware data augmentation framework for text-to-SQL. arXiv preprint arXiv:2511.10192.

Dai, H., Liu, Z., Liao, W., Huang, X., Cao, Y., Wu, Z., Zhao, L., Xu, S., Liu, W., et al. (2023). AugGPT: Leveraging ChatGPT for text data augmentation. IEEE Transactions on Big Data.

de Paiva, V., Rademaker, A., and de Melo, G. (2012). OpenWordNet-PT: An open brazilian wordnet for reasoning. In Proceedings of the 6th Global Wordnet Conference (GWC 2012), pages 353–360. The Global Wordnet Association.

Dettmers, T., Pagnoni, A., Holtzman, A., and Zettlemoyer, L. (2023). QLoRA: Efficient finetuning of quantized LLMs. In Advances in Neural Information Processing Systems (NeurIPS).

Edunov, S., Ott, M., Auli, M., and Grangier, D. (2018). Understanding back-translation at scale. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 489–500. ACL.

Feng, S. Y., Gangal, V., Wei, J., Chandar, S., Vosoughi, S., Mitamura, T., and Hovy, E. (2021). A survey of data augmentation approaches for natural language processing. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 968–988.

Honnibal, M., Montani, I., Van Landeghem, S., and Boyd, A. (2020). spaCy: Industrialstrength Natural Language Processing in Python. [link].

Hu, E. J., Shen, Y., Wallis, P., et al. (2021). LoRA: Low-rank adaptation of large language models. In International Conference on Learning Representations (ICLR).

Jiang, A. Q., Sablayrolles, A., Mensch, A., et al. (2023). Mistral 7b. arXiv preprint arXiv:2310.06825.

José, M. A. and Cozman, F. G. (2021). mRAT-SQL+GAP: A Portuguese Text-to-SQL Transformer, page 511–525. Springer International Publishing.

Katsogiannis-Meimarakis, G. and Koutrika, G. (2023). A survey on deep learning approaches for text-to-SQL. The VLDB Journal, 32(4):905–936.

Li, J., Hui, B., Qu, G., Yang, J., Li, B., Li, B., Wang, B., Qin, B., Geng, R., Huo, N., et al. (2023). Can LLM already serve as a database interface? a big bench for large-scale database grounded text-to-SQLs. Advances in Neural Information Processing Systems, 36:42330–42357.

Li, Y., Hu, Y., et al. (2021). Data augmentation for text-to-SQL. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing.

Magueresse, A., Vincent, C., and Meignier, S. (2020). Low-resource languages: a review of past work and future challenges. arXiv preprint arXiv:2006.07264.

Mallinson, J., Sennrich, R., and Lapata, M. (2017). Paraphrasing revisited with neural machine translation. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics, pages 881–893.

Miller, G. A. (1995). Wordnet: a lexical database for english. Communications of the ACM, 38(11):39–41.

Petroni, F., Rocktäschel, T., Lewis, P., et al. (2019). Language models as knowledge bases? In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing.

PostGIS Steering Committee (2023). PostGIS 3.4.0 Developer Guide. [link].

Reid, M., Savinov, N., Teplyashin, D., et al. (2024). Gemini 1.5: Unlocking multimodal understanding across millions of tokens of context. arXiv preprint arXiv:2403.05530.

Salazar, J., Liang, D., Nguyen, T. Q., and Kirchhoff, K. (2020). Masked language model scoring. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2699–2712. ACL.

Sennrich, R., Haddow, B., and Birch, A. (2016). Improving neural machine translation models with monolingual data. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics.

Souza, F., Nogueira, R., and Lotufo, R. (2020). BERTimbau: Pretrained BERT models for brazilian portuguese. In 9th Brazilian Conference on Intelligent Systems (BRACIS).

Sun, R., Arik, S. Ö., Nakhost, H., Dai, H., Sinha, R., Yin, P., and Pfister, T. (2024). SQL-PaLM: Improved large language model adaptation for text-to-sql. Transactions on Machine Learning Research.

Wang, H., Guo, L., Liang, Y., Liu, L., and Huang, J. (2025). GPT-Based text-to-SQL for spatial databases. ISPRS International Journal of Geo-Information, 14(8).

Wei, J. and Zou, K. (2019). EDA: Easy data augmentation techniques for boosting performance on text classification tasks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing.

Yamate, B. Y., Neubauer, T. R., Fantinato, M., and Peres, S. M. (2025). Text-to-SQL oriented to the process mining domain: A PT-EN dataset for query translation. arXiv preprint arXiv:2509.09684.

Yu, T., Zhang, R., Yang, K., Yasunaga, M., Wang, D., Li, Z., Ma, J., Li, I., Yao, Q., Roman, S., et al. (2018). Spider: A large-scale hierarchical dataset for complex semantic parsing and text-to-sql task. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 3911–3921.

Zhong, V., Xiong, C., and Socher, R. (2017). Seq2sql: Generating structured queries from natural language using reinforcement learning. arXiv preprint arXiv:1709.00103.
Publicado
08/09/2026
ANÍBAL NUNES BRITO, Felipe; BRAGHETTO, Kelly Rosa. Addressing Data Scarcity: Augmentation Strategies in Text-to-SQL. In: SIMPÓSIO BRASILEIRO DE BANCO DE DADOS (SBBD), 41. , 2026, São Carlos/SP. Anais [...]. Porto Alegre: Sociedade Brasileira de Computação, 2026 . p. 603-616. ISSN 2763-8979. DOI: https://doi.org/10.5753/sbbd.2026.249271.