This version of Deepseek R1 is optimized for tool usage with Cline and Roo Code.
tools
1.5b
7b
8b
14b
32b
70b
8,354 Pulls Updated 5 weeks ago
1359ed816427 · 689B
{{- if .Tools }}
<available_tools>
{{- range .Tools }}
{{ .Function }}
{{- end }}
</available_tools>
{{- end }}
{{- if .System }}<|Assistant|>{{ .System }}<|end▁of▁sentence|>{{ end }}
{{- range $i, $_ := .Messages }}
{{- $last := eq (len (slice $.Messages $i)) 1 }}
{{- if eq .Role "user" }}<|User|>{{ .Content }}
{{- else if eq .Role "assistant" }}<|Assistant|>{{ .Content }}{{- if not $last }}<|end▁of▁sentence|>{{- end }}
{{- else if eq .Role "tool" }}<|User|><tool_response>{{ .Content }}</tool_response>
{{- if not $last }}<|end▁of▁sentence|>{{- end }}
{{- end }}
{{- if and $last (ne .Role "assistant") }}<|Assistant|>{{- end }}
{{- end }}