diff --git a/chat_template.jinja b/chat_template.jinja
new file mode 100644
index 0000000000000000000000000000000000000000..73e9d7f5d08ed620f25bb59ab8d6602e45780c22
--- /dev/null
+++ b/chat_template.jinja
@@ -0,0 +1,120 @@
+{% set default_thinking_sys %}You are an expert reasoner with extensive experience in all areas. You approach problems through systematic thinking and rigorous reasoning. Your response should reflect deep understanding and precise logical thinking, making your solution path and reasoning clear to others. Please put your thinking process within ... tags.{% endset %}
+{%- set tool_instruction %}Your response should consist of a reasoning step (**thought**) followed immediately by a function call in valid JSON format. Wrap each function call using the `<|action_start|><|plugin|>` and `<|action_end|>` tags.
+
+**Format example:**
+
+```
+(Your thought goes here...)
+
+<|action_start|><|plugin|>
+{
+ "name": "tool_name",
+ "parameters": {
+ "parameter1": "value1",
+ "parameter2": "value2"
+ }
+}
+<|action_end|>
+```
+
+# External Tools
+You have access to these tools:
+{% if tools %}{{ tools | tojson(indent=2) }}{% else %}[]{% endif %}{% endset %}
+{%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}
+{%- for message in messages[::-1] %}
+ {%- set index = (messages|length - 1) - loop.index0 %}
+ {%- if ns.multi_step_tool and message.role == "user" %}
+ {%- set ns.multi_step_tool = false %}
+ {%- set ns.last_query_index = index %}
+ {%- endif %}
+{%- endfor %}
+{%- for message in messages %}
+ {%- set role = message.role if message.role != 'tool' else 'environment' %}
+ {%- set reasoning_content = '' %}
+ {%- set content = message.content %}
+ {%- set ns.tool_calls = '' %}
+ {%- if role == 'assistant' %}
+ {%- if message.reasoning_content is string %}
+ {%- set reasoning_content = message.reasoning_content %}
+ {%- elif '' in content %}
+ {%- set reasoning_content = content.split('')[0].strip().split('')[-1].strip() %}
+ {%- set content = content.split('')[-1].lstrip('
+') %}
+ {%- endif %}
+ {%- if message.tool_calls %}
+ {%- for tool_call in message.tool_calls %}
+ {%- if not loop.first %}
+ {%- set ns.tool_calls = ns.tool_calls + '
+' %}
+ {%- endif %}
+ {%- if tool_call.function %}
+ {%- set tool_call = tool_call.function %}
+ {%- endif %}
+ {%- set ns.tool_calls = ns.tool_calls + '<|action_start|><|plugin|>
+{"name": "' + tool_call.name + '", "parameters": ' %}
+ {%- if tool_call.arguments is string %}
+ {%- set ns.tool_calls = ns.tool_calls + tool_call.arguments %}
+ {%- else %}
+ {%- set ns.tool_calls = ns.tool_calls + tool_call.arguments | tojson %}
+ {%- endif %}
+ {%- set ns.tool_calls = ns.tool_calls + '}
+<|action_end|>' %}
+ {%- endfor %}
+ {%- endif %}
+ {%- set reasoning_content = '
+' + reasoning_content.strip('
+') + '
+
+' %}
+ {%- endif %}
+ {%- if not content is string %}
+ {%- set ns.content = '' %}
+ {%- for _content in message.content %}
+ {%- if _content.type == 'image' %}
+ {%- set ns.content = ns.content ~ '
+' %}
+ {%- elif _content.type == 'video' %}
+ {%- set ns.content = ns.content ~ '
+