Skip to content

Conversation

HardAndHeavy
Copy link

Added a missed opportunity to get a template from an environment variable.

@HardAndHeavy
Copy link
Author

HardAndHeavy commented Dec 1, 2024

The current template, when working through ollama, allowed the model to radically change the response embedded in the context. Up to the point of completely refusing to answer on the merits, although the context contained the necessary answer.

I can suggest a new template. With it, the model responds much more accurately and does not take liberties.
TEMPLATE=Use the following context as your learned knowledge, inside <context></context> XML tags. <context>{{CONTEXT}}</context>. When answer to user: the entire text that starts after the <context> tag and that ends before the </context> tag is the response; the <context> and </context> tags should not be included in the response; the answer must be transmitted to the user without changing the meaning, dates and numbers; if the context is empty, then ask for clarification; avoid mentioning that you obtained the information from the context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant