Safetensors
renruilong's picture
Add scripts and checkpoints (CosFly-Track release) (#85)
284878d
raw
history blame contribute delete
475 Bytes
{% for message in messages %}{{'<|im_start|>' + message['role'] + '
'}}{% if message['content'] is string %}{{ message['content'] }}{% else %}{% for content in message['content'] %}{% if content['type'] == 'image' %}{{ '<image>
' }}{% elif content['type'] == 'video' %}{{ '<video>
' }}{% elif content['type'] == 'text' %}{{ content['text'] }}{% endif %}{% endfor %}{% endif %}{{'<|im_end|>
'}}{% endfor %}{% if add_generation_prompt %}{{'<|im_start|>assistant
' }}{% endif %}