Skip to content

[Model] Add VaultGemma via Transformers modeling backend - #49803

Merged
hmellor merged 3 commits into
vllm-project:mainfrom
hmellor:add-vault-gemma
Jul 25, 2026
Merged

[Model] Add VaultGemma via Transformers modeling backend#49803
hmellor merged 3 commits into
vllm-project:mainfrom
hmellor:add-vault-gemma

Conversation

@hmellor

@hmellor hmellor commented Jul 25, 2026

Copy link
Copy Markdown
Member
  • Fixes bug in EngineArgs where full attention models were being treated as sliding if both of these conditions were true:
    • Has layer_types with all full_attention (therefore is_interleaved=False)
    • Has sliding_window: int present in the config
  • Adds VaultGemma (which exhibited this) to the model registry via the Transformers modeling backend

Closes #49795

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@mergify

mergify Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Documentation preview: https://vllm--49803.org.readthedocs.build/en/49803/

@mergify mergify Bot added documentation Improvements or additions to documentation new-model Requests to new models qwen Related to Qwen models labels Jul 25, 2026
@hmellor

hmellor commented Jul 25, 2026

Copy link
Copy Markdown
Member Author

cc @lucianommartins for Gemma

@hmellor
hmellor enabled auto-merge (squash) July 25, 2026 11:06
@hmellor hmellor added the ready ONLY add when PR is ready to merge/full CI is needed label Jul 25, 2026
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
@hmellor
hmellor merged commit 26d725c into vllm-project:main Jul 25, 2026
100 checks passed
@hmellor
hmellor deleted the add-vault-gemma branch July 25, 2026 16:54
iboiko-habana pushed a commit to vllm-project/vllm-gaudi that referenced this pull request Jul 28, 2026
…e is_interleaved helper removed upstream (#1641)

## Root cause
Upstream vLLM PR #49803 (commit 26d725c334) removed the `is_interleaved`
helper from `vllm.transformers_utils.config`, inlining the check at its
former
call sites. The HPU model runner still imported that symbol at module
load, so
`EngineCore` / worker init crashed with
`ImportError: cannot import name 'is_interleaved' from
'vllm.transformers_utils.config'`
across run_unit_tests, data_parallel, pd_disaggregate and ~50 e2e
load/generate jobs.

## Upstream PR
vllm-project/vllm#49803
Removed `is_interleaved` from `vllm.transformers_utils.config` and
inlined the
layer-type check at its call sites.

## Fix
Define a local `is_interleaved(config)` helper in
`vllm_gaudi/v1/worker/hpu_model_runner.py` (identical behaviour to the
removed
upstream helper: True when the text config declares more than one
distinct
layer type) and drop the now-dead top-level import.

## Bug 2: set use_replayssm on HPUMambaMixer2

- **State machine id**: granite_4_h_hpumambamixer2_use_replayssm_missing
- **Commit**: c219434891d11dfdeb4760c3ea0eda8b8364a21d
- **vllm pin (this fix)**: 439f336212227833e126526d3c5f3ef3968dfbf5
- **Root cause**: Upstream vLLM PR #48018 (ReplaySSM) added
`self.use_replayssm` / `self.replayssm_buffer_len` to
`MambaMixer2.__init__`, read by the inherited `get_state_shape()` /
`get_state_dtype()` during EngineCore init. `HPUMambaMixer2` overrides
`__init__` and never set them, so Granite-4-H crashed with
`AttributeError: 'HPUMambaMixer2' object has no attribute
'use_replayssm'`.
- **Upstream**: vllm-project/vllm#48018
- **Fix**: Set `use_replayssm=False` and `replayssm_buffer_len=None` in
the HPU `__init__` (HPU has no replay decode kernel; conv+SSM path is
non-replay).
- **Verification**: HPU re-verify of full stack PASS against
vllm@439f336212227833e126526d3c5f3ef3968dfbf5 (granite-4.0-h-small e2e
load/generate; both fixes exercised, EngineCore init clean, coherent
generations).

---------

Signed-off-by: Paweł Olejniczak <pawelx.olejniczak@intel.com>
libinta pushed a commit to libinta/vllm-gaudi that referenced this pull request Jul 28, 2026
…e is_interleaved helper removed upstream (vllm-project#1641)

## Root cause
Upstream vLLM PR #49803 (commit 26d725c334) removed the `is_interleaved`
helper from `vllm.transformers_utils.config`, inlining the check at its
former
call sites. The HPU model runner still imported that symbol at module
load, so
`EngineCore` / worker init crashed with
`ImportError: cannot import name 'is_interleaved' from
'vllm.transformers_utils.config'`
across run_unit_tests, data_parallel, pd_disaggregate and ~50 e2e
load/generate jobs.

## Upstream PR
vllm-project/vllm#49803
Removed `is_interleaved` from `vllm.transformers_utils.config` and
inlined the
layer-type check at its call sites.

## Fix
Define a local `is_interleaved(config)` helper in
`vllm_gaudi/v1/worker/hpu_model_runner.py` (identical behaviour to the
removed
upstream helper: True when the text config declares more than one
distinct
layer type) and drop the now-dead top-level import.

## Bug 2: set use_replayssm on HPUMambaMixer2

- **State machine id**: granite_4_h_hpumambamixer2_use_replayssm_missing
- **Commit**: c219434891d11dfdeb4760c3ea0eda8b8364a21d
- **vllm pin (this fix)**: 439f336212227833e126526d3c5f3ef3968dfbf5
- **Root cause**: Upstream vLLM PR #48018 (ReplaySSM) added
`self.use_replayssm` / `self.replayssm_buffer_len` to
`MambaMixer2.__init__`, read by the inherited `get_state_shape()` /
`get_state_dtype()` during EngineCore init. `HPUMambaMixer2` overrides
`__init__` and never set them, so Granite-4-H crashed with
`AttributeError: 'HPUMambaMixer2' object has no attribute
'use_replayssm'`.
- **Upstream**: vllm-project/vllm#48018
- **Fix**: Set `use_replayssm=False` and `replayssm_buffer_len=None` in
the HPU `__init__` (HPU has no replay decode kernel; conv+SSM path is
non-replay).
- **Verification**: HPU re-verify of full stack PASS against
vllm@439f336212227833e126526d3c5f3ef3968dfbf5 (granite-4.0-h-small e2e
load/generate; both fixes exercised, EngineCore init clean, coherent
generations).

---------

Signed-off-by: Paweł Olejniczak <pawelx.olejniczak@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation new-model Requests to new models qwen Related to Qwen models ready ONLY add when PR is ready to merge/full CI is needed

Projects

Development

Successfully merging this pull request may close these issues.

[Bug]: Blank output on google/vaultgemma-1b when context falls outside the last 512 tokens

2 participants