Skip to content

Feature Request: Add support for Gemma4-12b unified vision and audio projectors #2002

Description

@aadametz

Prerequisites

  • I am running the latest code. Mention the version if possible as well.
  • I carefully followed the README.md.
  • I searched using keywords relevant to my issue to make sure that I am creating a new issue that is not already open (or closed).
  • I reviewed the Discussions, and have a new and useful enhancement to share.

Feature Description

Google, with their Gemma4 12b model, introduced new types of vision and audio projectors:
clip.vision.projector_type = gemma4uv
clip.audio.projector_type = gemma4ua

From the model card:

The "Unified" in Gemma 4 12B Unified refers to its encoder-free architecture. Other Gemma 4 models use dedicated encoders to process multimodal data before passing it to the LLM. Gemma 4 12B eliminates these encoders entirely, projecting raw image patches and audio waveforms directly into the LLM's embedding space through lightweight linear layers. This unified approach means all modalities flow straight into a single decoder-only transformer, reducing multimodal latency and allowing the entire model to be fine-tuned in one pass.

Now, llama-server exits with this error:

clip_init: failed to load model 'C:\Models\Gemma4-12b-QAT\mmproj-F32.gguf': load_hparams: unknown projector type: gemma4uv
mtmd_init_from_file: error: Failed to load CLIP model from C:\Models\Gemma4-12b-QAT\mmproj-F32.gguf

The model in question and the mmproj file for it:
Google's official model page for Gemma-4-12b-it-QAT-Q4_0-GGUF on HuggingFace

Motivation

12b model is the largest of Gemma4 family models which support audio input - it would be good to have it working. Also, Google might stick to this audio/vision projectors approach in their upcoming models.

Possible Implementation

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions