Views
No views yet
llama-cli -hf nphearum/Gemma-4-e2b-CodeX-Distill-v1-GGUF --jinjallama-mtmd-cli -hf nphearum/Gemma-4-e2b-CodeX-Distill-v1-GGUF --jinjagemma-4-e2b-it.Q8_0.gguf — Quantized model (Q8_0 for high quality)gemma-4-e2b-it.BF16-mmproj.gguf — Multimodal projection (required for full functionality)1llama-server \
2 -m gemma-4-e2b-it.Q8_0.gguf \
3 --port 53281 \
4 -c 131072 \
5 --parallel 1 \
6 --flash-attn on \
7 --no-context-shift \
8 -ngl -1 \
9 --jinja \
10 --chat-template-kwargs "{\"enable_thinking\": true}" \
11 --mmproj gemma-4-e2b-it.BF16-mmproj.gguf-c 131072 → Enables long context (131k tokens)--flash-attn on → Faster attention (requires compatible GPU)-ngl -1 → Offload all layers to GPU--jinja → Enables chat template rendering--chat-template-kwargs → Activates thinking mode--mmproj → Required for multimodal projection1curl http://localhost:53281/v1/chat/completions \
2 -H "Content-Type: application/json" \
3 -d '{
4 "messages": [
5 {"role": "user", "content": "Write a Python function to reverse a linked list"}
6 ]
7 }'enable_thinking=true, the model may:Modelfile:1FROM ./gemma-4-e2b-it.Q8_0.gguf
2
3PARAMETER num_ctx 131072
4PARAMETER num_gpu -1
5PARAMETER stop "<end_of_turn>"
6
7TEMPLATE """{{ if .System }}<start_of_turn>system
8{{ .System }}<end_of_turn>
9{{ end }}{{ if .Prompt }}<start_of_turn>user
10{{ .Prompt }}<end_of_turn>
11<start_of_turn>model
12{{ end }}"""
13
14# Optional: enable reasoning-style outputs
15SYSTEM "You are a highly capable coding assistant with strong reasoning ability."1ollama create gemma-4-codex -f Modelfile
2ollama run gemma-4-codex| Use Case | Context | GPU Layers | Notes |
|---|---|---|---|
| Coding assistant | 32k–64k | Full (-1) | Best balance |
| Long reasoning | 131k | Full | Needs high VRAM |
| Low VRAM setup | 8k–16k | Partial | Disable flash-attn |