Trained with Unsloth - Ollama Modelfile
Browse files
Modelfile
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
|
| 2 |
+
FROM mistral-nemo-instruct-2407.Q4_0.gguf
|
| 3 |
+
TEMPLATE """
|
| 4 |
+
{{- range $i, $_ := .Messages }}
|
| 5 |
+
{{- if eq .Role "user" }}
|
| 6 |
+
{{- if and $.Tools (le (len (slice $.Messages $i)) 2) }}[AVAILABLE_TOOLS]{{ $.Tools }}[/AVAILABLE_TOOLS]
|
| 7 |
+
{{- end }}[INST]{{ if and $.System (eq (len (slice $.Messages $i)) 1) }}{{ $.System }}
|
| 8 |
+
|
| 9 |
+
{{ end }}{{ .Content }}[/INST]
|
| 10 |
+
{{- else if eq .Role "assistant" }}
|
| 11 |
+
{{- if .Content }} {{ .Content }}{{ if not (eq (len (slice $.Messages $i)) 1) }}</s>{{ end }}
|
| 12 |
+
{{- else if .ToolCalls }}[TOOL_CALLS][
|
| 13 |
+
{{- range .ToolCalls }}{"name": "{{ .Function.Name }}", "arguments": {{ .Function.Arguments }}}
|
| 14 |
+
{{- end }}]</s>
|
| 15 |
+
{{- end }}
|
| 16 |
+
{{- else if eq .Role "tool" }}[TOOL_RESULTS]{"content": {{ .Content }}}[/TOOL_RESULTS]
|
| 17 |
+
{{- end }}
|
| 18 |
+
{{- end }}"""
|
| 19 |
+
PARAMETER stop "[INST]"
|
| 20 |
+
PARAMETER stop "[/INST]"
|