Skip to content

[BUG]: Gemma 4 is not supported on Dynamo vLLM backend ≤1.1.0-dev.1 #7942

Description

@ritazh

Describe the Bug

Gemma 4 (google/gemma-4-31b-it) cannot be served on Dynamo ≤1.1.0-dev.1 because the bundled vLLM 0.17.1 lacks a native gemma4 model implementation. It falls back to the generic TransformersMultiModalForCausalLM which fails during weight loading with ValueError: There is no module or parameter named 'model.language_model.layers.0.layer_scalar' in TransformersMultiModalForCausalLM.

Upgrading to transformers 5.x (which adds gemma4 architecture recognition) alone is insufficient, and upgrading vLLM in-container to ≥0.19 breaks the Dynamo integration layer ModuleNotFoundError: No module named 'vllm.inputs.data'.

A Dynamo release built against vLLM ≥0.19 (which adds native Gemma 4 support) is needed to unblock this.

Steps to Reproduce

Deployed this

apiVersion: nvidia.com/v1alpha1
kind: DynamoGraphDeployment
metadata:
  name: gemma4-31b-agg
spec:
  backendFramework: vllm
  pvcs:
    - name: pvc-lustre
      create: false
  services:
    Frontend:
      envFromSecret: hf-token-secret
      componentType: frontend
      replicas: 1
      volumeMounts:
        - name: pvc-lustre
          mountPoint: /model-cache
      extraPodSpec:
        mainContainer:
          startupProbe:
            httpGet:
              path: /health
              port: 8000
            periodSeconds: 10
            timeoutSeconds: 1800
            failureThreshold: 60
          image: nvcr.io/nvidia/ai-dynamo/vllm-runtime:1.1.0-dev.1
          command:
            - /bin/sh
            - -c
          args:
            - python3 -m dynamo.frontend --router-mode kv --no-kv-events --http-port 8000
      envs:
        - name: HF_HOME
          value: /model-cache
    VllmDecodeWorker:
      envFromSecret: hf-token-secret
      componentType: worker
      replicas: 1
      resources:
        limits:
          gpu: "1"
        requests:
          gpu: "1"
      volumeMounts:
        - mountPoint: /model-cache
          name: pvc-lustre
          useAsCompilationCache: false
      extraPodSpec:
        mainContainer:
          startupProbe:
            httpGet:
              path: /health
              port: 9090
            periodSeconds: 10
            timeoutSeconds: 10
            failureThreshold: 120
          image: nvcr.io/nvidia/ai-dynamo/vllm-runtime:1.1.0-dev.1
          env:
            - name: HF_HOME
              value: /model-cache
            # Workaround for vllm/vllm#35772: FlashInfer allreduce can hang during
            # CUDA graph capture with TP>1. Fixed in vllm/vllm#35793 (default changed
            # to trtllm). The 1.0 container ships vLLM 0.16.0, so set explicitly.
            - name: VLLM_FLASHINFER_ALLREDUCE_BACKEND
              value: "trtllm"
          workingDir: /workspace/examples/backends/vllm
          command:
            - /bin/sh
            - -c
          args:
            - pip install "vllm>=0.19" && pip install --no-deps "transformers>=5" "huggingface_hub>=0.37" && python3 -m dynamo.vllm --model google/gemma-4-31b-it --tensor-parallel-size 1 --max-model-len 8192 --enable-multimodal --enforce-eager

Expected Behavior

Model deployed and can serve requests

Actual Behavior

vllmdecodeworker pod CrashLoopBackOff

Environment

  • k8s version: v1.33.6
  • 2× H100 80GB

Additional Context

No response

Screenshots

No response

Metadata

Metadata

Assignees

Labels

backend::vllmRelates to the vllm backendbugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions