Blar-SQL: Faster, Stronger, Smaller NL2SQL

José Manuel Domínguez, Benjamín Errázuriz, Patricio Daher
1/4/2024
cs.CLcs.AI

No confident code implementation found for this paper.

Abstract

Large Language Models (LLMs) have gained considerable notoriety in the field of natural language to SQL tasks (NL2SQL). In this study, we show how task decomposition can greatly benefit LLMs in database understanding and query generation in order to answer human questions with an SQL query. We fined-tuned open source models, specifically Llama-2 and Code Llama, by combining 2 different models each designated to focus on one of two tasks in order to leverage each model's core competency to further increase the accuracy of the final SQL query. We propose a new framework to divide the schema into chunks in order to fit more information into a limited context. Our results are comparable with those obtained by GPT-4 at the same time being 135 times smaller, 90 times faster and more than 100 times cheaper than GPT-4.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{domnguez2024blarsql,
  title  = {Blar-SQL: Faster, Stronger, Smaller NL2SQL},
  author = {José Manuel Domínguez and Benjamín Errázuriz and Patricio Daher},
  year   = {2024},
  eprint = {2401.02997},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2401.02997v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2401.02997.svg)](https://codeofpaper.com/paper/2401.02997)

Discussion