Download chat_template.jinja from hf-tiny-v2/tiny-random-Phi4MultimodalModel: direct link, hf CLI and curl.
- Browser
- Download file 649 Bytes
-
https://huggingface.co/hf-tiny-v2/tiny-random-Phi4MultimodalModel/resolve/main/chat_template.jinja
- Command line
-
hf download hf://hf-tiny-v2/tiny-random-Phi4MultimodalModel/chat_template.jinja
-
curl -L -o chat_template.jinja https://huggingface.co/hf-tiny-v2/tiny-random-Phi4MultimodalModel/resolve/main/chat_template.jinja
649 Bytes
| {% for message in messages %}{{ '<|' + message['role'] + '|>' }}{% if message['content'] is string %}{{ message['content'] }}{% else %}{% for content in message['content'] %}{% if content['type'] == 'image' %}{{ '<|image|>' }}{% elif content['type'] == 'audio' %}{{ '<|audio|>' }}{% elif content['type'] == 'text' %}{{ content['text'] }}{% endif %}{% endfor %}{% endif %}{% if message['role'] == 'system' and 'tools' in message and message['tools'] is not none %}{{ '<|tool|>' + message['tools'] + '<|/tool|>' + '<|end|>' }}{% endif %}{{ '<|end|>' }}{% endfor %}{% if add_generation_prompt %}{{ '<|assistant|>' }}{% else %}{{ eos_token }}{% endif %} |