[Bugfix] add inject model_arch to hf_overrides (#2178)

Signed-off-by: rongfu.leng <lenronfu@gmail.com>
This commit is contained in:
rongfu.leng authored and GitHub committed 2026-03-25 19:05:28 +00:00
1 parent 29936a3edd
commit b569cb56b6
1 file changed
+8
+8
View File
@@ -125,6 +125,14 @@ class OmniEngineArgs(EngineArgs):
}
stage_connector_config["extra"]["stage_id"] = self.stage_id
# If model_arch is specified, inject it into hf_overrides so vLLM can
# resolve the architecture even when config.json lacks 'architectures'.
if self.model_arch:
if self.hf_overrides is None:
self.hf_overrides = {}
if isinstance(self.hf_overrides, dict):
self.hf_overrides.setdefault("architectures", [self.model_arch])
# Build the vLLM config first, then use it to create the Omni config.
model_config = super().create_model_config()