Instructions to use yashcse21/text2sql-llama1b-adapters with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use yashcse21/text2sql-llama1b-adapters with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] hf download yashcse21/text2sql-llama1b-adapters --local-dir text2sql-llama1b-adapters
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Atomic Chat
Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: llama3.2
|
| 3 |
+
base_model: mlx-community/Llama-3.2-1B-Instruct-bf16
|
| 4 |
+
tags: [text-to-sql, lora, mlx, reasoning]
|
| 5 |
+
library_name: mlx
|
| 6 |
+
---
|
| 7 |
+
|
| 8 |
+
# Text-to-SQL · adapters
|
| 9 |
+
|
| 10 |
+
MLX LoRA adapter fine-tuned from
|
| 11 |
+
`mlx-community/Llama-3.2-1B-Instruct-bf16` to turn a natural-language question + a `CREATE TABLE` schema into a
|
| 12 |
+
schema-faithful SQLite `SELECT` (reasoning models emit `Reasoning: … / SQL: …`).
|
| 13 |
+
|
| 14 |
+
```python
|
| 15 |
+
# download the adapter, then:
|
| 16 |
+
from mlx_lm import load
|
| 17 |
+
model, tok = load("mlx-community/Llama-3.2-1B-Instruct-bf16", adapter_path="<downloaded-adapter-dir>")
|
| 18 |
+
```
|
| 19 |
+
|
| 20 |
+
Pair generation with a deterministic AST guardrail (single read-only SELECT).
|
| 21 |
+
See the project repo for the data pipeline, study, and evaluation.
|