CoolFace
Modelpublic

onekq-ai/OneSQL-v0.1-Qwen-32B-GGUF

sourceHugging Faceapache-2.0updated 2y agoView on Hugging Face
1likes566downloads
Model Card

Introduction

This model is the GGUF version of OneSQL-v0.1-Qwen-32B. You can also find it on Ollama.

Performances

The original model has an EX score of 63.33 on the BIRD leaderboard. Below is our self-evaluation for each quantization.

QuantizationEX score
Q2_K47.78
Q3KS50.26
Q3KM51.50
Q3KL51.24
Q4_146.54
Q4KS52.47
Q4_K_M53.79
Q5_050.23
Q5_148.36
Q5KS51.93
Q5KM50.66
Q6_K52.89
Q8_050.33

Quick start

To use this model, craft your prompt to start with your database schema in the form of CREATE TABLE, followed by your natural language query preceded by --. Make sure your prompt ends with SELECT in order for the model to finish the query for you. There is no need to set other parameters like temperature or max token limit.

sh
PROMPT="CREATE TABLE students (
    id INTEGER PRIMARY KEY,
    name TEXT,
    age INTEGER,
    grade TEXT
);

-- Find the three youngest students
SELECT "

ollama run onekq-ai/OneSQL-v0.1-Qwen:32B-Q4_K_M "$PROMPT"

The model response is the finished SQL query without SELECT

sql
* FROM students ORDER BY age ASC LIMIT 3

Caveats

  • —The performance drop from the original model is due to quantization itself, and the lack of beam search support in llama.cpp framework. Use at your own discretion.
  • —The Q4_0 quantization suffers from repetitive output token, hence is not recommended for usage.