File size: 1,464 Bytes
3b41371
 
a9e1348
 
 
 
 
 
 
3b41371
 
1e77383
3b41371
1e77383
3b41371
 
 
 
 
1e77383
3b41371
1e77383
 
 
 
 
 
3b41371
1e77383
3b41371
1e77383
3b41371
 
 
 
 
1e77383
3b41371
1e77383
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
library_name: transformers
tags:
- sql-generation
- falcon
- lora
- rag
- transformers
- text-to-sql
---

# Model Card for Falcon SQL Generator (LoRA Fine-Tuned)

A lightweight Falcon-1B model fine-tuned using LoRA on Spider-style SQL generation examples. The model takes in a user query and schema context and generates corresponding SQL queries. It supports few-shot prompting and can be integrated with retrieval-based systems.

## Model Details

### Model Description

This model is a fine-tuned version of `tiiuae/falcon-rw-1b` using Parameter-Efficient Fine-Tuning (LoRA) for the **text-to-SQL task**. It is trained on custom Spider-style examples that map natural language questions to valid SQL queries over a provided schema context.

- **Developed by:** revanth kumar
- **Finetuned by:**  revanth kumar
- **Model type:** Causal Language Model (AutoModelForCausalLM)
- **Language(s):** English (NL input) and SQL (output)
- **License:** Apache 2.0 (inherits from base Falcon model)
- **Finetuned from:** [tiiuae/falcon-rw-1b](https://huggingface.co/tiiuae/falcon-rw-1b)

### Model Sources

- **Repository:** [https://huggingface.co/nandini2455508/falcon-sql-lora](https://huggingface.co/nandini2455508/falcon-sql-lora)

## Uses

### Direct Use

This model can be directly used for **natural language to SQL generation**. It supports queries like:

```text
"List all employees earning more than 50000"
→ SELECT * FROM employees WHERE salary > 50000;