[Model] Support Meituan LongCat-Flash && LongCat-Flash-MTP (#9824)

This commit is contained in:
Guoyuan Lin
2025-08-31 14:29:21 +08:00
committed by GitHub
parent fd5ce576a4
commit 5e194b2143
10 changed files with 1940 additions and 11 deletions

View File

@@ -307,7 +307,10 @@ class ModelRunner:
model_num_layers = (
self.model_config.num_nextn_predict_layers
if self.is_draft_worker and model_has_mtp_layers
else self.model_config.num_hidden_layers
else max(
self.model_config.num_hidden_layers,
self.model_config.num_attention_layers,
)
)
self.start_layer = getattr(self.model, "start_layer", 0)
self.end_layer = getattr(self.model, "end_layer", model_num_layers)