Instructions to use CraneAILabs/ganda-gemma-1b-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use CraneAILabs/ganda-gemma-1b-GGUF with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="CraneAILabs/ganda-gemma-1b-GGUF") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("CraneAILabs/ganda-gemma-1b-GGUF") model = AutoModelForCausalLM.from_pretrained("CraneAILabs/ganda-gemma-1b-GGUF", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use CraneAILabs/ganda-gemma-1b-GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf CraneAILabs/ganda-gemma-1b-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 CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf CraneAILabs/ganda-gemma-1b-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 CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
Use Docker
docker model run hf.co/CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use CraneAILabs/ganda-gemma-1b-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "CraneAILabs/ganda-gemma-1b-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "CraneAILabs/ganda-gemma-1b-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
- SGLang
How to use CraneAILabs/ganda-gemma-1b-GGUF with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "CraneAILabs/ganda-gemma-1b-GGUF" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "CraneAILabs/ganda-gemma-1b-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "CraneAILabs/ganda-gemma-1b-GGUF" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "CraneAILabs/ganda-gemma-1b-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use CraneAILabs/ganda-gemma-1b-GGUF with Ollama:
ollama run hf.co/CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
- Unsloth Studio
How to use CraneAILabs/ganda-gemma-1b-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 CraneAILabs/ganda-gemma-1b-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 CraneAILabs/ganda-gemma-1b-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for CraneAILabs/ganda-gemma-1b-GGUF to start chatting
- Docker Model Runner
How to use CraneAILabs/ganda-gemma-1b-GGUF with Docker Model Runner:
docker model run hf.co/CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
- Lemonade
How to use CraneAILabs/ganda-gemma-1b-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull CraneAILabs/ganda-gemma-1b-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.ganda-gemma-1b-GGUF-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Ganda Gemma 1B
A fine-tuned Gemma 3 1B instruction model specialized for English-to-Luganda translation and Luganda conversational AI. The model accepts input in both English and Luganda but outputs responses exclusively in Luganda.
📊 Translation Performance
Model Comparison
| Model | Parameters | BLEU | chrF++ | Efficiency* |
|---|---|---|---|---|
| Gemma 3 4B | 4B | 1.1 | 20.05 | 0.28 |
| Gemma 3 27B | 27B | 3.65 | 31.37 | 0.14 |
| GPT-5 Mini | N/A | 5.14 | 36.55 | N/A |
| Ganda Gemma 1B | 1B | 6.99 | 40.32 | 6.99 |
| Gemini 2.0 Flash | Large | 7.94 | 43.38 | N/A |
*Efficiency = BLEU Score ÷ Parameters (in billions)
Key Performance Insights
🎯 Efficiency Leader: Achieves 6.99 BLEU per billion parameters (highest efficiency ratio)
🚀 Size Advantage: Outperforms Gemma 3 4B (4x larger) by 535% on BLEU score
💎 Competitive Quality: Achieves similar performance to GPT-5 Mini with known 1B parameter count
⚡ Practical Deployment: Runs efficiently on consumer hardware while maintaining quality
Evaluation Details
- Dataset: FLORES-200 English→Luganda (1,012 translation pairs)
- Metrics: BLEU (bilingual evaluation understudy) and chrF++ (character F-score)
- Evaluation: Zero-shot translation performance
🚀 Quick Start
from transformers import AutoModelForCausalLM, AutoTokenizer
# Load model and tokenizer
model = AutoModelForCausalLM.from_pretrained("CraneAILabs/ganda-gemma-1b")
tokenizer = AutoTokenizer.from_pretrained("CraneAILabs/ganda-gemma-1b")
# Translate to Luganda
prompt = "Translate to Luganda: Hello, how are you today?"
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_length=100, temperature=0.3)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(response)
🌍 Language Capabilities
- Input Languages: English + Luganda
- Output Language: Luganda only
- Primary Focus: English-to-Luganda translation and Luganda conversation
🎯 Capabilities
- Translation: English-to-Luganda translation
- Conversational AI: Natural dialogue in Luganda
- Summarization: Text summarization in Luganda
- Writing: Creative and informational writing in Luganda
- Question Answering: General knowledge responses in Luganda
💻 Usage Examples
Basic Translation
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("CraneAILabs/ganda-gemma-1b")
tokenizer = AutoTokenizer.from_pretrained("CraneAILabs/ganda-gemma-1b")
# English to Luganda translation
prompt = "Translate to Luganda: Welcome to our school"
inputs = tokenizer(prompt, return_tensors="pt")
with torch.no_grad():
outputs = model.generate(
**inputs,
max_length=100,
temperature=0.3,
do_sample=True,
pad_token_id=tokenizer.eos_token_id
)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(response)
Luganda Conversation
# Direct Luganda conversation
prompt = "Oli otya! Osobola okuntuyamba leero?"
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_length=100, temperature=0.3)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(response)
Using the Pipeline
from transformers import pipeline
# Create a text generation pipeline
generator = pipeline(
"text-generation",
model="CraneAILabs/ganda-gemma-1b",
tokenizer="CraneAILabs/ganda-gemma-1b",
device=0 if torch.cuda.is_available() else -1
)
# Generate Luganda text
result = generator(
"Translate to Luganda: Welcome to our school",
max_length=100,
temperature=0.3,
do_sample=True
)
print(result[0]['generated_text'])
Ollama Usage
# Run with different quantizations
ollama run crane-ai-labs/ganda-gemma-1b:q4-k-m # Recommended balance
ollama run crane-ai-labs/ganda-gemma-1b:q8-0 # Higher quality
ollama run crane-ai-labs/ganda-gemma-1b:q4-k-s # Smaller size
ollama run crane-ai-labs/ganda-gemma-1b:f16 # Original quality
🚀 GGUF Advantages
- Fast CPU Inference: Optimized for CPU-only environments
- Memory Efficient: Multiple quantization levels available
- Easy Integration: Works with llama.cpp, Ollama, and other GGUF-compatible tools
- Cross-Platform: Supports Windows, macOS, and Linux
📦 Available Quantizations
| Quantization | File Size | Memory Usage | Quality | Use Case |
|---|---|---|---|---|
| F16 | ~2.0GB | ~3.5GB | Best | GPU inference |
| Q8_0 | ~1.1GB | ~2.0GB | High | High-end CPU |
| Q4_K_M | ~600MB | ~1.2GB | Good | Recommended |
| Q4_K_S | ~550MB | ~1.1GB | Decent | Low memory |
| Q4_0 | ~550MB | ~1.0GB | Basic | Very low memory |
🔗 Related Models
- Original Model: CraneAILabs/ganda-gemma-1b - Full precision HuggingFace model
- Mobile (LiteRT): CraneAILabs/ganda-gemma-1b-litert - Optimized for Android/iOS
📄 License
This model is released under the Gemma Terms of Use. Please review the terms before use.
Built with ❤️ by Crane AI Labs
Ganda Gemma - Your helpful Luganda AI companion, optimized for CPU!
- Downloads last month
- 105
2-bit
3-bit
4-bit
5-bit
8-bit
16-bit
32-bit
