Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions vllm/config/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -484,6 +484,17 @@ def __post_init__(
)

self.hf_config = hf_config

# Ensure Gemma2 configs have hidden_act for backward compatibility.
# GGUF configs may only have hidden_activation; model code expects both.
if (
hasattr(hf_config, "model_type")
and hf_config.model_type == "gemma2"
and not hasattr(hf_config, "hidden_act")
and hasattr(hf_config, "hidden_activation")
):
hf_config.hidden_act = hf_config.hidden_activation

if dict_overrides:
self._apply_dict_overrides(hf_config, dict_overrides)
self.hf_text_config = get_hf_text_config(self.hf_config)
Expand Down