chat-template-generation / templates /falcon-chat.jinja2
tjtanaa's picture
init streamlit chat-template ui
7a664fd
raw
history blame
357 Bytes
{% for message in messages %}
{% if not loop.first %}
{{ '\n' }}
{% endif %}
{% if message['role'] == 'system' %}
{{ 'System: ' }}
{% elif message['role'] == 'user' %}
{{ 'User: ' }}
{% elif message['role'] == 'assistant' %}
{{ 'Falcon: ' }}
{% endif %}
{{ message['content'] }}
{% endfor %}
{% if add_generation_prompt %}
{{ '\n' + 'Falcon:' }}
{% endif %}