Open lboklin opened 6 months ago
That's an interesting idea. There are a couple different suggestions here that I want to break down.
1 has been on my list to implement. My plan was to change the interface to take "!chaz" (or a custom name) as the prefix for commands instead of just "." And have it operate in a DM mode where it always responds like now, or only when directly queried. I already added support for "!chaz" style commands to the headjack library, as I switched to those commands for my other tool https://github.com/arcuru/pokem
2 is pretty reasonable, I'd thought about that as well. I was going to try experimenting with replacing "USER" with the names of participants in the conversation sent to the LLMs when running it in a room with multiple participants, as you suggested too. I suspect that the more sophisticated models will handle it fine but the others will struggle, some of them get confused with my "USER" and "ASSISTANT" labels already.
The OpenAI APIs have a "completion" and a "conversation" interface, but because I was lazy with the backend and am plugging everything into AIChat it is stuck using only the "completion" interface and I'm adding the labeling to fake the conversation myself.
3, deciding the right time to respond, is pretty interesting. I hadn't thought of that but I'd love to explore it.
When added to rooms that aren't DMs (either only the 2 participants or marked as a DM) then it won't respond until pinged. Either with a !chaz
command or mentioning it with @
So "1" from above is done.
I'm mainly keeping this open for 3. "Figure out when to respond in a chat"
Would be interesting to let chaz sit in on a conversation but only respond when it seems appropriate, such as when directly addressed, when certain topics or sentiments appear, or if it is implicitly pulled into the conversation.
However, it seems like currently it can't identify individual participants, with any new message being attributed simply to "User". For the feature request to make sense, each new message would have to include at least the author's username. That seems straight forward enough...
The big question is how the decision to butt in or not could be implemented. There would have to be another model in addition to the one generating responses: one that performs sentiment and content analysis in order to determine whether a response is warranted or not.
I do not know how well or not current models are able to handle multi-participant conversations, but I imagine they might do ok with the right guidance.