Edmon02/gemma-4-12B-it-MLX
2
Gemma 4 12B Instruction-Tuned — MLX (Apple Silicon)
Local MLX quants of google/gemma-4-12B-it for native inference on Apple Silicon via mlx-vlm.
Also available: Edmon02/gemma-4-12B-it-GGUF for llama.cpp / LM Studio.
Why this repo exists
- One download hub for curated MLX quants (4bit, mxfp4, 6bit, 8bit).
- PLE-safe conversion from the official Google checkpoint with
mlx-vlm >= 0.6.0. - Documented recipes in gemma-4-12b-local.
Available quants
See `mlx-manifest.json` for the live file list.
Load a specific quant by downloading its subfolder or pointing load() at the local path.
Download
pip install -U mlx-vlm huggingface_hub
# Recommended quant (4bit)
huggingface-cli download Edmon02/gemma-4-12B-it-MLX 4bit/ --local-dir ./models/gemma-4-12b-mlxAccept the license on google/gemma-4-12B-it before using weights.
Quick start
Text chat (CLI)
python -m mlx_vlm.generate \
--model ./models/gemma-4-12b-mlx/4bit \
--prompt "List three benefits of encoder-free multimodal models." \
--max-tokens 256 --temperature 0.7Text chat (Python — use chat template)
Gemma 4 requires the chat template; generate() does not apply it automatically:
from mlx_vlm import generate, load
from mlx_vlm.prompt_utils import apply_chat_template
model, processor = load("./models/gemma-4-12b-mlx/4bit")
prompt = apply_chat_template(
processor,
model.config,
[{"role": "user", "content": "Hello!"}],
add_generation_prompt=True,
)
print(generate(model=model, processor=processor, prompt=prompt, max_tokens=256).text)Vision (image + text)
python -m mlx_vlm.generate \
--model ./models/gemma-4-12b-mlx/4bit \
--prompt "Describe this image in one sentence." \
--image photo.jpg \
--max-tokens 128Hardware guide
Provenance
Limitations
- Converted locally — validate quality on your tasks vs official BF16.
- Audio support depends on your
mlx-vlmversion; confirmprocessor_config.jsonis present. - Gated upstream — HF token + license acceptance required for
google/*repos.
Citation
@article{gemma_2026,
title={Gemma 4},
author={Google DeepMind},
year={2026},
url={https://blog.google/innovation-and-ai/technology/developers-tools/introducing-gemma-4-12B/}
}