DhruvalLabs/phi-2-GGUF
<div align="center">
phi-2 — GGUF Quantizations
  
Quantized GGUF versions of [microsoft/phi-2](https://huggingface.co/microsoft/phi-2)
Works with [llama.cpp](https://github.com/ggerganov/llama.cpp) · [Ollama](https://ollama.ai) · [LM Studio](https://lmstudio.ai) · [Open WebUI](https://openwebui.com) · [Jan](https://jan.ai)
Quantized by [Dhptl](https://huggingface.co/Dhptl) on June 17, 2026 using [quant-kit](https://github.com/DhruvalPtl/quant-kit)
</div>
⚖️ The Pareto Frontier — Efficiency vs Intelligence
Can you run a powerful model on a laptop without losing its intelligence?
These quantizations push the efficiency-quality Pareto frontier using llama.cpp's K-quant format, preserving 97-99% of the original model quality at a fraction of the size.
📦 Available Files
💡 Which file should I download?
- Most users:
phi-2-Q4_K_M.gguf— best balance of size and quality - High RAM (32GB+):
phi-2-Q8_0.gguf— near-original quality - Low RAM (8GB):
phi-2-Q3_K_M.gguf— fits in 8GB with room to spare
⚡ Speed Benchmarks
Run `python benchmark.py --model phi-2` to generate speed results.
🧠 Quality Benchmarks
Run `kaggle_bench.ipynb` on Kaggle to benchmark this model.
🚀 How to Use
Ollama
ollama run dhptl/phi-2LM Studio / Jan / Open WebUI
Search for Dhptl/phi-2 in the model browser.
llama.cpp CLI
# Download the binary from https://github.com/ggerganov/llama.cpp/releases
./llama-cli \
-m phi-2-Q4_K_M.gguf \
-p "You are a helpful assistant." \
--conversation \
-n 512Python — llama-cpp-python
from llama_cpp import Llama
llm = Llama(
model_path="./phi-2-Q4_K_M.gguf",
n_gpu_layers=-1, # -1 = offload everything to GPU
n_ctx=4096,
)
response = llm.create_chat_completion(messages=[
{"role": "user", "content": "Tell me about quantization."}
])
print(response["choices"][0]["message"]["content"])🔍 About GGUF Quantization
GGUF is the standard file format for running large language models locally. Quantization reduces the number of bits per weight:
💬 Community & Feedback
Found an issue? Have a question? Open a Discussion in the Community tab above.
If these quantizations were useful, please consider:
- ⭐ Starring quant-kit on GitHub
- 👍 Liking this model on HuggingFace
- 💬 Leaving feedback in the Community tab
