Downloads · 30 days
970
7% of all-time downloads
matrixportalx/gemma-3-1b-it-GGUF
gemma-3-1b-it-GGUF is a text generation model from matrixportalx. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as gemma.
This model was converted to GGUF format from google/gemma-3-1b-it using llama.cpp via the ggml.ai's all-gguf-same-where space. Refer to the original model card for more details on the model.
Downloads · 30 days
970
7% of all-time downloads
All-time downloads
13.2K
Public
Repo size
11.7 GB
Likes
0
Public
Click a slice to open those files.
.gguf11.7 GB · 100%
From the Hugging Face model README
This model was converted to GGUF format from google/gemma-3-1b-it using llama.cpp via the ggml.ai's all-gguf-same-where space.
Refer to the original model card for more details on the model.
Q4_K_M (Best balance of speed/quality)Q4_0 (Optimized for ARM CPUs)Q8_0 (Near-original quality)| 🚀 Download | 🔢 Type | 📝 Notes |
|---|---|---|
| Download | Basic quantization | |
| Download | Small size | |
| Download | Balanced quality | |
| Download | Better quality | |
| Download | Fast on ARM | |
| Download | Fast, recommended | |
| Download | Best balance | |
| Download | Good quality | |
| Download | Balanced | |
| Download | High quality | |
| Download | Very good quality | |
| Download | Fast, best quality | |
| Download | Maximum accuracy |
💡 Tip: Use F16 for maximum precision when quality is critical
GGUF (GPT-Generated Unified Format) is an efficient model file format developed by the llama.cpp team that:
Quantization converts model weights to lower precision data types (e.g., 4-bit integers instead of 32-bit floats) to:
# System updates
sudo apt update && sudo apt upgrade -y
# Dependencies
sudo apt install -y build-essential cmake python3-pip
# Clone and build llama.cpp
git clone https://github.com/ggerganov/llama.cpp
cd llama.cpp
make -j4
My automated quantization script produces models in this format:
https://huggingface.co/matrixportal/gemma-3-1b-it-GGUF/resolve/main/gemma-3-1b-it-q4_k_m.gguf
Download your quantized model directly:
wget https://huggingface.co/matrixportal/gemma-3-1b-it-GGUF/resolve/main/gemma-3-1b-it-q4_k_m.gguf
Basic usage:
./main -m gemma-3-1b-it-q4_k_m.gguf -p "Your prompt here" -n 128
Example with a creative writing prompt:
./main -m gemma-3-1b-it-q4_k_m.gguf -p "[INST] Write a short poem about AI quantization in the style of Shakespeare [/INST]" -n 256 -c 2048 -t 8 --temp 0.7
Advanced parameters:
./main -m gemma-3-1b-it-q4_k_m.gguf -p "Question: What is the GGUF format?
Answer:" -n 256 -c 2048 -t 8 --temp 0.7 --top-k 40 --top-p 0.9
Install the Python package:
pip install llama-cpp-python
Example script:
from llama_cpp import Llama
# Initialize the model
llm = Llama(
model_path="gemma-3-1b-it-q4_k_m.gguf",
n_ctx=2048,
n_threads=8
)
# Run inference
response = llm(
"[INST] Explain GGUF quantization to a beginner [/INST]",
max_tokens=256,
temperature=0.7,
top_p=0.9
)
print(response["choices"][0]["text"])
Hardware Utilization:
-t (typically CPU core count)Memory Optimization:
-c parameterSpeed/Accuracy Balance:
--temp 0 for consistent resultsQ: What quantization levels are available?
A: Common options include q4_0, q4_k_m, q5_0, q5_k_m, q8_0
Q: How much performance loss occurs with q4_k_m?
A: Typically 2-5% accuracy reduction but 4x smaller size
Q: How to enable GPU support?
A: Build with make LLAMA_CUBLAS=1 for NVIDIA GPUs