SmolDocling-256M-preview-mlx-fp16 / chat_template.json
ahishamm's picture
Update chat_template.json
0b84106 verified
raw
history blame contribute delete
510 Bytes
{
"chat_template": "<|im_start|>{% for message in messages %}{{ message['role'] | capitalize }}:{% if message['content'] is string %}{{ message['content'] }{% else %}{% if message['content'][0]['type'] == 'image' %}{{ ':' }}{% else %}{{ ': ' }}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{ line['text'] }}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}{% endif %}<end_of_utterance>{% endfor %}{% if add_generation_prompt %}Assistant:{% endif %}"
}