v0.31.1

knadh/listmonkv0.31.1Jun 30, 2026by github-actions[bot]

AI Summary

This release significantly optimizes Gemma 4 performance on Apple Silicon by leveraging multi-token prediction (MTP), resulting in nearly 90% faster token generation, alongside updates to the MLX and llama.cpp engines.

Key Highlights

  • Gemma 4 is ~90% faster on Apple Silicon using multi-token prediction (MTP)
  • Updated MLX engine with new small-batch matmul kernel
  • Updated underlying llama.cpp engine to build 9840
  • Tightened Gemma 4 MoE model loading in MLX

New Features

  • Faster Gemma 4 generation on Apple Silicon (default enabled)

Full Release Notes

## Faster Gemma 4 on Apple Silicon

<img width="1037" height="485" alt="Screenshot 2026-06-30 at 5 25 29 PM" src="https://github.com/user-attachments/assets/547d5076-090f-43c4-a661-938e11abc955" />

Gemma 4 is now significantly faster in Ollama on Apple Silicon, generating tokens nearly 90% faster on average across a coding-agent benchmark by leveraging multi-token prediction (MTP). Ollama auto-tunes how many tokens to draft as it runs, so the speedup is on by default, requires no configuration, and does not change the model's output.

## What's Changed

- Tightened Gemma 4 MoE model loading in the MLX engine
- Updated the MLX engine to the latest version, including a new small-batch matmul kernel
- Updated the underlying llama.cpp engine to build 9840
- Improved Gemma 4 multi-token prediction (MTP) performance

**Full Changelog**: https://github.com/ollama/ollama/compare/v0.30.12...v0.31.1