File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -2486,16 +2486,21 @@ class MoondreamChatHanlder(Llava15ChatHandler):
2486
2486
"{% if message.content is iterable %}"
2487
2487
"{% for content in message.content %}"
2488
2488
"{% if content.type == 'image_url' %}"
2489
+ "{% if content.image_url is string %}"
2489
2490
"{{ content.image_url }}\n \n "
2490
2491
"{% endif %}"
2492
+ "{% if content.image_url is mapping %}"
2493
+ "{{ content.image_url.url }}\n \n "
2494
+ "{% endif %}"
2495
+ "{% endif %}"
2491
2496
"{% if content.type == 'text' %}"
2492
2497
"Question: {{ content.text }}\n \n "
2493
2498
"{% endif %}"
2494
2499
"{% endfor %}"
2495
2500
"{% endif %}"
2496
2501
"{% endif %}"
2497
2502
"{% if message.role == 'assistant' %}"
2498
- "Answer:{{ message.content }}"
2503
+ "Answer:{{ message.content }}\n \n "
2499
2504
"{% endif %}"
2500
2505
"{% endfor %}"
2501
2506
"{% if add_generation_prompt %}"
You can’t perform that action at this time.
0 commit comments