Skip to content

Commit ff97068

Browse files
committed
feat: YAML frontmatter convention for chat templates
1 parent 8a30af3 commit ff97068

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

lua/gp/defaults.lua

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,23 +14,21 @@ M.code_system_prompt = "You are an AI working as a code editor.\n\n"
1414
.. "START AND END YOUR ANSWER WITH:\n\n```"
1515

1616
M.chat_template = [[
17+
---
1718
# topic: ?
18-
19-
- file: {{filename}}
2019
{{optional_headers}}
21-
Write your queries after {{user_prefix}}. Use `{{respond_shortcut}}` or :{{cmd_prefix}}ChatRespond to generate a response.
22-
Response generation can be terminated by using `{{stop_shortcut}}` or :{{cmd_prefix}}ChatStop command.
23-
Chats are saved automatically. To delete this chat, use `{{delete_shortcut}}` or :{{cmd_prefix}}ChatDelete.
24-
Be cautious of very long chats. Start a fresh chat by using `{{new_shortcut}}` or :{{cmd_prefix}}ChatNew.
25-
20+
# Write your queries after {{user_prefix}}. Use `{{respond_shortcut}}` or :{{cmd_prefix}}ChatRespond to generate a response.
21+
# Response generation can be terminated by using `{{stop_shortcut}}` or :{{cmd_prefix}}ChatStop command.
22+
# Chats are saved automatically. To delete this chat, use `{{delete_shortcut}}` or :{{cmd_prefix}}ChatDelete.
23+
# Be cautious of very long chats. Start a fresh chat by using `{{new_shortcut}}` or :{{cmd_prefix}}ChatNew.
2624
---
2725
2826
{{user_prefix}}
2927
]]
3028

3129
M.short_chat_template = [[
30+
---
3231
# topic: ?
33-
- file: {{filename}}
3432
---
3533
3634
{{user_prefix}}

0 commit comments

Comments
 (0)