add audio tags
Browse files- chat_template.jinja +12 -7
chat_template.jinja
CHANGED
|
@@ -1,9 +1,14 @@
|
|
| 1 |
{% for m in messages %}
|
| 2 |
-
{
|
| 3 |
-
{
|
| 4 |
-
{%
|
| 5 |
-
{{
|
| 6 |
-
{%
|
| 7 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8 |
{% endif %}
|
| 9 |
-
{% endfor %}
|
|
|
|
|
|
| 1 |
{% for m in messages %}
|
| 2 |
+
<|im_start|>{{ m['role'] }}
|
| 3 |
+
{% for piece in m['content'] %}
|
| 4 |
+
{% if piece['type'] == 'text' %}
|
| 5 |
+
{{ piece['text'] }}
|
| 6 |
+
{% elif piece['type'] == 'audio' %}
|
| 7 |
+
<|audio_start|><|audio_pad|><|audio_end|>
|
| 8 |
+
{% elif piece['type'] == 'image' %}
|
| 9 |
+
<image>
|
| 10 |
+
{% elif piece['type'] == 'video' %}
|
| 11 |
+
<video>
|
| 12 |
{% endif %}
|
| 13 |
+
{% endfor %}<|im_end|>
|
| 14 |
+
{% endfor %}
|