Instructions to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF", filename="gemma-4-31B-it-Q4_K_M.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
Use Docker
docker model run hf.co/lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
- Ollama
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with Ollama:
ollama run hf.co/lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
- Unsloth Studio
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF to start chatting
- Docker Model Runner
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with Docker Model Runner:
docker model run hf.co/lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
- Lemonade
How to use lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull lmcoleman/gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF-Q4_K_M
List all available models
lemonade list
gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF
Derivative of gemma-4-31B-it, quantized using MagicQuant hybrid evolutionary per-tensor search.
Base Model
This is a derivative of gemma-4-31B-it. All credit for the base model architecture and weights goes to the original authors. The base model's license applies to this derivative.
Quantization Method
Quantized using MagicQuant hybrid evolutionary per-tensor quantization, based on the methodology by magiccodingman:
- Tensors are classified into sensitivity groups (Embeddings, Head, Query, Key, Output, FFN Up/Down, MoE Experts, Router)
- An evolutionary search finds the optimal quantization type per group, balancing size vs. perplexity
- Q4/Q5/Q6 tier targets are produced with different size-quality tradeoffs
- Small-row tensors and sensitivity-critical layers (embeddings, output head, router) are kept at F32/F16/BF16
- This is NOT a uniform quantization -- each tensor group gets its own optimal type
GGUF Files
| File | Size | Quant |
|---|---|---|
| gemma-4-31B-it-Q4_K_M.gguf | 22.1 GB | Q4 hybrid |
| gemma-4-31B-it-Q5_K_M.gguf | 30.9 GB | Q5 hybrid |
| gemma-4-31B-it-Q6_K.gguf | 32.3 GB | Q6 hybrid |
Usage
LM Studio
- Download the GGUF file of your preferred quantization tier
- Place it in your LM Studio models directory
- Load the model in LM Studio -- it will auto-detect the chat template
- The model supports the base model's full context length
llama.cpp
# Interactive chat
llama-cli -m gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF-Q5.gguf -c 8192 --chat-template chatml -cnv
# Single prompt
llama-cli -m gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF-Q5.gguf -c 8192 -p "Your prompt here"
# Server mode
llama-server -m gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF-Q5.gguf -c 8192 --port 8080
Python (llama-cpp-python)
from llama_cpp import Llama
llm = Llama(model_path="./gemma-4-31B-Zeroclaw-ClaudeReasoning-GGUF-Q5.gguf", n_ctx=8192)
output = llm.create_chat_completion(
messages=[
{"role": "user", "content": "Hello, how are you?"}
]
)
print(output["choices"][0]["message"]["content"])
Caveats
- The base model's license (apache-2.0) applies to all derivative files
- Quantization reduces precision -- verify outputs for your specific use case
- The hybrid quantization assigns different precision to different tensor groups, which means quality characteristics may differ from uniform quantizations
Limitations
- Quantized models may exhibit subtle differences from the full-precision fine-tune
- This model inherits any limitations and biases present in the base model
Generated with MagicQuant
- Downloads last month
- 72
4-bit
5-bit
6-bit