4 ms·
Did you somehow get it to play nice with multi-party chats, or does every user have their own private 1-1 room with the bot?
by apetresc 4y ago
Did you somehow get it to play nice with multi-party chats, or does every user have their own private 1-1 room with the bot?
- sureglymop 4y agoBoth work. I have an SQLite db where i save "rooms", "sessions" and "messages". So multiple users can contribute in the same chat session, where i pass the whole conversation history to the AI as context. Then there are commands to switch and delete sessions. When the bot is mentioned in a message, it gets the answer from the API in a different thread and shows a writing indicator. It also plays super nice with the Element Matrix client which supports tables and codeblocks. The openai API sends back markdown which i can parse into html and send like that. I want to clean up my code a bit and then open source the bot.