discord-ai-bot
discord-ai-bot copied to clipboard
Properly format discord channels and pings
Describe the feature Currently the bot is incapable of pinging people despite frequently trying.
Currently before giving the message to the chatbot, you pre-process the discord tags like <#1082142594567516160>
and <@280411966126948353>
into #channel
and @user
, I suggest you add a step before sending the reply that goes the other way around.
Why do you think this feature should be implemented? Ping other members who are relevant to the conversation and have clickable channel mentions
Additional context I already implemented this on my fork, I would PR but I have made a ton of other changes that you probably don't want.
Here are the relevant lines https://github.com/CodeF53/sage/blob/006d5db453dc0119cc31d707390389a16f6b461f/src/aiRespond.ts#L127-L150, should be copy pasteable into your codebase
I thought about this, but I'm debating on whether or not this should be implemented, as the bot could perhaps say something like @hello and have it accidentally get replaced to a mention if someone in the server has that as their nickname, plus if the LLM modifies the name for example if the user told it to add a letter in every second word, then it won't detect it properly
To be honest, I do not see any viable use case other than spam pinging users. I could consider adding channel mentions but I need to get a reason