Instructions to use OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4 with MLX:
# Make sure mlx-vlm is installed # pip install --upgrade mlx-vlm from mlx_vlm import load, generate from mlx_vlm.prompt_utils import apply_chat_template from mlx_vlm.utils import load_config # Load the model model, processor = load("OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4") config = load_config("OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4") # Prepare input image = ["http://images.cocodataset.org/val2017/000000039769.jpg"] prompt = "Describe this image." # Apply chat template formatted_prompt = apply_chat_template( processor, config, prompt, num_images=1 ) # Generate output output = generate(model, processor, formatted_prompt, image) print(output) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4 with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4"
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4 with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4
Run Hermes
hermes
DiffusionGemma 26B-A4B-it — MXFP4 (Osaurus / vMLX)
Native MLX MXFP4 quantization of google/diffusiongemma-26B-A4B-it — a
block-diffusion language model (NOT autoregressive): text generates as
256-token canvases refined by iterative denoising. 30-layer Gemma-4-style
MoE, 128 experts top-8, 26B total / ~4B active parameters.
Runs natively in Osaurus on Apple Silicon via the vmlx-swift block-diffusion engine.
Quantization
- Attention + routed MoE experts: MXFP4 (group 32)
- Dense MLP + router projections: MXFP8 (group 32)
- Embeddings, norms, self-conditioning, vision tower: fp16 passthrough
- 15 shards, ~15 GB on disk, peak runtime RSS ≈ 12.7 GB (M5 Max)
Capabilities
| Text generation | ✅ block diffusion (~37 tok/s @ bundle default 48 steps, ~74 tok/s @ 16 steps, M5 Max) |
| Vision (single/multi image) | ✅ Gemma-4 unified vision tower, 280 soft tokens/image |
| Tool calling | ✅ Gemma-4 format <|tool_call>call:name{...}<tool_call|> |
| Reasoning channel | ✅ harmony <|channel>thought…<channel|> |
| Audio | ❌ not in this checkpoint (no audio_config) |
| Video | ❌ no video_token_id |
Generation contract
All diffusion sampling parameters live in generation_config.json and are
honored by the runtime: max_denoising_steps=48, entropy bound 0.1,
temperature schedule 0.8→0.4, stability 1, confidence 0.005,
eos_token_id=[1, 106, 50], pad 0. Wire temperature/top_p are ignored
by design — the denoising schedule is bundle-owned. Speed/quality is
controlled by the denoising-step budget (Osaurus exposes this as a server
setting, default 16 ≈ 2× faster than the bundle default and verified
coherent; below 12 quality degrades).
The chat template (chat_template.jinja) ships in this repo, including
tool-call and thinking-channel rendering.
Known behavior
Very terse prompts under greedy denoising can occasionally converge to an empty (EOS-first) canvas — inherent to the reference sampling algorithm with random canvas initialization; retry or rephrase.
- Downloads last month
- 246
Quantized
Model tree for OsaurusAI/diffusiongemma-26B-A4B-it-MXFP4
Base model
google/diffusiongemma-26B-A4B-it