LLMs ·

SQLCoder 7B v2

Parameters
6.7B
Architecture
Dense
Max context
16K tokens
License
cc-by-sa-4.0
Released
2024-02

How to run it

Quantized files · GGUF

Works in LM Studio, llama.cpp, Jan and Ollama. No sign-in needed.

huggingface.co/defog/sqlcoder-7b-2 (opens in a new tab)

ollama run hf.co/defog/sqlcoder-7b-2

Original weights · Hugging Face

Full-precision files from Defog, for fine-tuning, vLLM, Transformers.

huggingface.co/defog/sqlcoder-7b-2 (opens in a new tab)

No sign-in needed.

Memory needed

Weights plus KV cache and runtime overhead. Leave a little extra free for the operating system and other apps.

Quantization Quality Weights Total at 8K context Total at 16K context Download
Q2_K Low 2.7 GB 7.6 GB 11.9 GB GGUF files (opens in a new tab)
Q3_K_M Low 3.3 GB 8.2 GB 12.5 GB GGUF files (opens in a new tab)
Q4_K_M Good 4.1 GB 9.0 GB 13.3 GB GGUF files (opens in a new tab)
Q5_K_M High 4.8 GB 9.7 GB 14.0 GB GGUF (opens in a new tab)
Q6_K High 5.5 GB 10.4 GB 14.7 GB GGUF files (opens in a new tab)
Q8_0 Very high 7.1 GB 12.0 GB 16.3 GB GGUF files (opens in a new tab)
F16 Full 13.5 GB 18.4 GB 22.7 GB Original weights (opens in a new tab)

Best hardware for SQLCoder 7B v2

The least expensive GPU in our catalog that runs it without offloading is the Intel Arc A580 (launch price $179) at Q2_K.

Grade · points Hardware Quant Memory Speed Fit
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 AMD Radeon RX 9070 XT Q8_0 12.8 GB / 16.0 GB 51.1 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 4090 F16 19.6 GB / 24.0 GB 43.1 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 4070 Ti SUPER Q8_0 12.8 GB / 16.0 GB 62.3 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 4080 SUPER Q8_0 12.8 GB / 16.0 GB 68.2 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 5060 Ti 16GB Q8_0 12.8 GB / 16.0 GB 41.5 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 5070 Ti Q8_0 12.8 GB / 16.0 GB 83.1 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 5080 Q8_0 12.8 GB / 16.0 GB 89.0 tok/s Runs well
68 ptsGood (B) · 68 of 100 points: Model quality 13.1/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 NVIDIA GeForce RTX 4060 Ti 16GB Q5_K_M 10.5 GB / 16.0 GB 43.3 tok/s Runs well
67 ptsGood (B) · 67 of 100 points: Model quality 13.5/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 14.4/15 NVIDIA GeForce RTX 5090 F16 20.0 GB / 32.0 GB 76.6 tok/s Runs well
67 ptsGood (B) · 67 of 100 points: Model quality 12.8/45, Memory fit 25.0/25, Speed 15.0/15, Memory use 15.0/15 Intel Arc B580 Q4_K_M 9.6 GB / 12.0 GB 63.4 tok/s Runs well

Check it on your own hardware

Estimates come from published hardware specs and our open formulas, not from running the model on your machine. Real speed varies with runtime, drivers and settings. Numbers marked “Measured” come from a linked benchmark.