merge data part to the text stream

Former-commit-id: 42c90c8183
This commit is contained in:
BUAADreamer
2024-04-25 19:58:47 +08:00
parent c50474869f
commit 56028422e8
6 changed files with 18 additions and 38 deletions

View File

@@ -1012,8 +1012,8 @@ _register_template(
_register_template(
name="llava",
format_user=StringFormatter(slots=["USER: {{content}} "]),
format_assistant=StringFormatter(slots=["ASSISTANT: {{content}}"]),
format_user=StringFormatter(slots=["USER: {{content}} ASSISTANT: "]),
format_assistant=StringFormatter(slots=["{{content}}", {"eos_token"}]),
default_system=(
"A chat between a curious user and an artificial intelligence assistant. "
"The assistant gives helpful, detailed, and polite answers to the user's questions."