[Fix] Move "model_config" as keyword args in chat_utils.py (#18098)

Signed-off-by: Linkun <github@lkchen.net>
This commit is contained in:
lkchen
2025-05-13 23:27:26 -07:00
committed by GitHub
parent 33011318c2
commit 6685890d11
6 changed files with 42 additions and 23 deletions
+3 -3
View File
@@ -731,11 +731,11 @@ class LLM:
tokenizer = self.get_tokenizer(lora_request)
model_config = self.llm_engine.get_model_config()
resolved_content_format = resolve_chat_template_content_format(
model_config,
chat_template,
tools,
chat_template_content_format,
tokenizer,
model_config=model_config,
)
_chat_template_kwargs: dict[str, Any] = dict(
@@ -767,9 +767,9 @@ class LLM:
)
else:
prompt_str = apply_hf_chat_template(
model_config,
tokenizer,
tokenizer=tokenizer,
conversation=conversation,
model_config=model_config,
**_chat_template_kwargs,
)
# Special tokens are already included in chat templates so