Add kimi-k2 tool parser (#20789)

Signed-off-by: wangzhengtao <wangzhengtao@moonshot.cn>
Co-authored-by: wangzhengtao <wangzhengtao@moonshot.cn>
Co-authored-by: wangzhengtao <wangzhengtao@msh.team>
This commit is contained in:
bigmoyan
2025-07-11 10:36:23 +08:00
committed by GitHub
parent cf75cd2098
commit 0cf893cae1
4 changed files with 576 additions and 2 deletions

View File

@@ -1143,7 +1143,7 @@ class ModelConfig:
if not hasattr(self.hf_text_config, "model_type"):
return False
elif self.hf_text_config.model_type in \
('deepseek_v2', 'deepseek_v3', 'deepseek_mtp'):
('deepseek_v2', 'deepseek_v3', 'deepseek_mtp', 'kimi_k2'):
return self.hf_text_config.kv_lora_rank is not None
elif self.hf_text_config.model_type == 'eagle':
# if the model is an EAGLE module, check for the