Replies: 1 comment
-
The biggest challenge I found when trying to make this open ended and fully customizable is that different prompt templates use completely different structures (some have sys prompt, others don't) and adding all of the different possible options to the UI just made it impossible to configure anything. I think having a "custom" option for prompt template that allows you to input the system prefix/suffix, user prefix/suffix, and assistant prefix/suffix would be the best middle ground. It should just involve hooking up the correct ConfigFlow selectors and adding the "custom" template logic to the prompt formatting function. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
As there are about as many prompt formats as there are organizations producing LLMs, it would be helpful to be able to specify a custom prompt format when trying out new models.
I see two possible ways to make this work.
Use string replacement to replace the variables {{ system_prompt }} and {{ user_input }}.
As an example, Zephyr format would be "<|system|>\n{{ system_prompt }}<|endoftext|>\n<|user|>\n{{ user_input }}<|endoftext|>\n<|assistant|>/n"
OR
I believe both options are compatible with the currently available settings, so adding this feature theoretically shouldn't break anyone's existing configuration.
I'm going to try to code this myself, as it's a (at least seemingly) small change. I'm just rather new to HASS development.
Beta Was this translation helpful? Give feedback.
All reactions