Update chat_template.jinja
#50
by
kallewooof
- opened
- chat_template.jinja +3 -3
chat_template.jinja
CHANGED
|
@@ -31,10 +31,10 @@
|
|
| 31 |
{%- elif message['content'] is string -%}
|
| 32 |
{{ message['content'] }}
|
| 33 |
{%- elif message['content'] is not none -%}
|
| 34 |
-
{
|
| 35 |
-
{
|
| 36 |
<|media_start|>image<|media_content|><|media_pad|><|media_end|>
|
| 37 |
-
{
|
| 38 |
{{ content['text'] }}
|
| 39 |
{%- endif -%}
|
| 40 |
{%- endfor -%}
|
|
|
|
| 31 |
{%- elif message['content'] is string -%}
|
| 32 |
{{ message['content'] }}
|
| 33 |
{%- elif message['content'] is not none -%}
|
| 34 |
+
{%- for content in message['content'] -%}
|
| 35 |
+
{%- if content['type'] == 'image' or 'image' in content or 'image_url' in content -%}
|
| 36 |
<|media_start|>image<|media_content|><|media_pad|><|media_end|>
|
| 37 |
+
{%- else -%}
|
| 38 |
{{ content['text'] }}
|
| 39 |
{%- endif -%}
|
| 40 |
{%- endfor -%}
|