update templates to use messages

This commit is contained in:
Michael Yang
2024-08-27 11:34:30 -07:00
parent 69be940bf6
commit 413ae39f3c
19 changed files with 145 additions and 84 deletions

View File

@@ -1,6 +1,7 @@
{{ if .System }}System: {{ .System }}
{{ end }}{{ if .Prompt }}User: {{ .Prompt }}
{{ end }}Assistant: {{ .Response }}
{{- range .Messages }}
{{- if eq .Role "system" }}System:
{{- else if eq .Role "user" }}User:
{{- else if eq .Role "assistant" }}Assistant:
{{- end }} {{ .Content }}
{{ end }}Assistant: