|
|
--- |
|
|
base_model: t5-small |
|
|
library_name: peft |
|
|
--- |
|
|
|
|
|
# Model Card for Model ID |
|
|
|
|
|
Convert natural language queries into SQL. |
|
|
|
|
|
|
|
|
|
|
|
## Model Details |
|
|
|
|
|
### Model Description |
|
|
|
|
|
A text-to-sql LoRA adapter for m5-small finetuned on the b-mc2/sql-create-context, Clinton/Text-to-sql-v1, and knowrohit07/know_sql datasets. |
|
|
|
|
|
|
|
|
|
|
|
- **Model type:** text-to-sql |
|
|
- **Language(s) (NLP):** Python (PyTorch) |
|
|
- **Finetuned from model:** m5-small |
|
|
|
|
|
### Model Sources [optional] |
|
|
|
|
|
<!-- Provide the basic links for the model. --> |
|
|
|
|
|
- **Repository:** [github: Text2sql-LoRA-T5-small](https://github.com/KookyGhost/Text2sql-LoRA-T5-small.git) |
|
|
|
|
|
## Training Details |
|
|
|
|
|
### Training Data |
|
|
|
|
|
[b-mc2/sql-create-context](https://huggingface.co/datasets/b-mc2/sql-create-context) |
|
|
|
|
|
[Clinton/Text-to-sql-v1](https://huggingface.co/datasets/Clinton/Text-to-sql-v1) |
|
|
|
|
|
[knowrohit07/know_sql](https://huggingface.co/datasets/knowrohit07/know_sql) |
|
|
|
|
|
Train-Eval-Test split: 8:1:1 |
|
|
|
|
|
#### Metrics |
|
|
|
|
|
<!-- These are the evaluation metrics being used, ideally with a description of why. --> |
|
|
|
|
|
[ROUGE](https://huggingface.co/metrics/rouge) |
|
|
|
|
|
### Results |
|
|
|
|
|
'rouge1': 0.9281907395888822, 'rouge2': 0.8917983416395394, 'rougeL': 0.9182615264948171, 'rougeLsum': 0.9191261027066355 |
|
|
|
|
|
#### Summary |
|
|
|
|
|
This adapter helps m5-small achieve a ROUGE score of over 90% on text to SQL tasks. |
|
|
|
|
|
|
|
|
## Environmental Impact |
|
|
|
|
|
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly --> |
|
|
|
|
|
Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700). |
|
|
|
|
|
- **Hardware Type:** RTX 4000 |
|
|
- **Hours used:** 2 |
|
|
- **Cloud Provider:** Paperspace |
|
|
|
|
|
|
|
|
- PEFT 0.6.2 |
|
|
|