# DiffusionGemma 26B-A4B-it INT8 Dynamic

Google's DiffusionGemma 26B-A4B-it, stored as 8-bit integers (INT8) so that it runs on Ampere GPUs such as the RTX 3090. The size drops from about 49 GB to about 26 GB.

Web page: https://aidenle.com/models/diffusiongemma-26b-int8-dynamic/. Source: [Hugging Face](https://huggingface.co/aidendle94/diffusiongemma-26B-A4B-it-INT8-dynamic). This guide describes a deployment that someone else published; reported results are attributed.

An INT8 build of a 26B block-diffusion mixture-of-experts model, about 26 GB in size. INT8 runs on Ampere GPUs, while FP8 needs Hopper or Ada hardware.

| Fact | Value |
|---|---|
| Hardware | 1–2× RTX 3090 (≥32GB) |
| Precision | INT8 W8A8 dynamic |
| Runtime | vLLM (DiffusionGemma branch) |
| Footprint | ~26GB (from ~49GB bf16) |

## In short

- DiffusionGemma fills in blocks of text instead of writing one token at a time (block diffusion).
- This build stays close to the 16-bit original: cosine similarity about 0.99996.
- Raise max_new_tokens from its default of 256 to about 8192, or thinking answers are cut off.

## Setup

1. Use an Ampere or newer GPU (two RTX 3090 GPUs tested). A single GPU needs at least 32 GB of VRAM (GPU memory).
2. Install vLLM from a branch that supports DiffusionGemma. Mainline vLLM does not include it, at least through the 0.14 nightly.
3. Serve with --trust-remote-code. Set --max-num-seqs to the number of requests you want at the same time. Pass the sampler overrides through --hf-overrides.
4. Turn on tool calling and thinking with --enable-auto-tool-choice --reasoning-parser gemma4 --tool-call-parser gemma4 and --default-chat-template-kwargs '{"enable_thinking": true}'. The reasoning comes back in message.reasoning.
5. Raise max_new_tokens to about 8192. Thinking mode alone needs at least 1024 tokens.
6. Lower --gpu-memory-utilization, for example to about 0.75 on 24 GB GPUs, to leave room for the sampler.
7. Optional: decode about 3 times faster, at some cost in quality, with --diffusion-config '{"canvas_length": 256, "max_denoising_steps": 16}'.

## The recipe

vLLM serve command:

```bash
vllm serve aidendle94/diffusiongemma-26B-A4B-it-INT8-dynamic \
  --trust-remote-code \
  --max-num-seqs 4 \
  --hf-overrides '{"diffusion_sampler": "entropy_bound", "diffusion_entropy_bound": 0.1}' \
  --override-generation-config '{"max_new_tokens": 8192}' \
  --enable-auto-tool-choice \
  --reasoning-parser gemma4 \
  --tool-call-parser gemma4 \
  --default-chat-template-kwargs '{"enable_thinking": true}'
```

## Technical details

- Use the bundled `chat_template.jinja` unchanged, or tool calls and reasoning may not parse.
