Open zjffdu opened 4 months ago
@zjffdu Thanks for writing the issues. Why it has to be a list of messages? Why not form them into a single prompt and send it to them? This tutorial should explain how you can form it.
If it make things easy, we can consider to provide you a simple component to help you form it:
<SYS> You are a helpful assistant.</SYS>
User: Who won the World Series in 2020?
You: The Los Angeles Dodgers won the World Series in 2020.
User: Who was the MVP?
You:
This is how research papers form their prompt.
Additionally, We can create a GeneratorMessages
, which takes a list of chat turns as input instead of prompt_kwargs
and prompt template. The extend on modelclient
will be simple enough. If the community wants to write a proposal on this approach, this can be a great way to extend but without complicated the prompt-only approach.
This does mean you don't use the trained User/assistant tokens (<|im_start|>user\n
et cetera) we've seen reduced performance on a fair number of tasks (especially dialogue tasks) when formatting the input into a single message
Is your feature request related to a problem? Please describe. Currently I can only pass one string to Generator, but openai support a list of message which is what I want.
Describe the solution you'd like I'd like to support a list of messages like following:
Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.
Additional context Add any other context or screenshots about the feature request here.