Commit
·
a9f6593
1
Parent(s):
0681761
Update chat template
Browse files- chat_template.jinja +3 -3
chat_template.jinja
CHANGED
@@ -17,7 +17,7 @@
|
|
17 |
{{- "\nHere are the tools available to you in JSON format within <tool> and </tool> tags:\n" }}
|
18 |
{%- for tool in tools %}
|
19 |
{{- "<tool>" }}
|
20 |
-
{{- tool |
|
21 |
{{- "</tool>\n" }}
|
22 |
{%- endfor %}
|
23 |
|
@@ -105,7 +105,7 @@
|
|
105 |
{{- raise_exception('arguments or parameters are mandatory: ' ~ tool_call) }}
|
106 |
{%- endif %}
|
107 |
|
108 |
-
{{- "<tool_call>" }}{"name": "{{- tool_call.name }}", "arguments": {{ arguments |
|
109 |
|
110 |
{%- if not loop.last %}
|
111 |
{{- "\n" }}
|
@@ -120,7 +120,7 @@
|
|
120 |
{{- role_indicators['tool'] }}
|
121 |
{%- endif %}
|
122 |
{%- if msg.content is defined %}
|
123 |
-
{{- "<tool_result>" }}{"result": {{ msg.content |
|
124 |
{%- endif %}
|
125 |
{%- if loop.last or messages[i + 1].role != "tool" %}
|
126 |
{{- end_of_turn -}}
|
|
|
17 |
{{- "\nHere are the tools available to you in JSON format within <tool> and </tool> tags:\n" }}
|
18 |
{%- for tool in tools %}
|
19 |
{{- "<tool>" }}
|
20 |
+
{{- tool | safe }}
|
21 |
{{- "</tool>\n" }}
|
22 |
{%- endfor %}
|
23 |
|
|
|
105 |
{{- raise_exception('arguments or parameters are mandatory: ' ~ tool_call) }}
|
106 |
{%- endif %}
|
107 |
|
108 |
+
{{- "<tool_call>" }}{"name": "{{- tool_call.name }}", "arguments": {{ arguments | safe }}}{{- "</tool_call>" }}
|
109 |
|
110 |
{%- if not loop.last %}
|
111 |
{{- "\n" }}
|
|
|
120 |
{{- role_indicators['tool'] }}
|
121 |
{%- endif %}
|
122 |
{%- if msg.content is defined %}
|
123 |
+
{{- "<tool_result>" }}{"result": {{ msg.content | safe }}}{{- "</tool_result>" }}
|
124 |
{%- endif %}
|
125 |
{%- if loop.last or messages[i + 1].role != "tool" %}
|
126 |
{{- end_of_turn -}}
|