[Bugfix] Add missing get_language_model to new MLLMs (#17300)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
This commit is contained in:
Cyrus Leung
2025-04-28 19:09:57 +08:00
committed by GitHub
parent fb1c933ade
commit 344e193b7d
2 changed files with 6 additions and 0 deletions

View File

@@ -369,6 +369,9 @@ class KimiVLForConditionalGeneration(nn.Module, SupportsMultiModal):
return self.multi_modal_projector(
torch.cat(image_features)).split(lengths)
def get_language_model(self) -> torch.nn.Module:
return self.language_model
def get_multimodal_embeddings(self,
**kwargs: object) -> Optional[NestedTensors]:
# Validate the multimodal input keyword arguments