Crabstero's New Solution for Pings and Mentions
/pingme
command. If you change your mind, you can run the command again to opt out. By default, pings are disabled unless you opt in.Mentions and Pings
Discord is a popular communication platform which allows people to communicate in real-time through text, audio, and video in online communities. In text channels, the rapid flow of messages can make it difficult to notice if someone is trying to reach out to you specifically.
Discord provides a pair of features to help with this problem: mentions and pings. If someone wants to get your attention, they can mention your username (e.g. @username
) in a message. Once the message is sent, the mention triggers a "ping", a push notification to draw your attention to the message. There are other features which can also generate pings, but mentions are the primary feature relevant to this blog post.
Since pings can be triggered easily and without limitations through mentions, they are naturally prone to abuse. Users can exploit mentions to spam notifications, disrupt conversations, or annoy others. A special mention known as @everyone
is especially abusable as it sends a ping to every member of the server it is sent in all at once. This type of abuse is common enough that there is a genre of custom emotes used to express frustration with nuisance pings.
One of my projects, Crabstero, is a Discord chat bot which reads messages in text channels, trains markov chains on them, and uses these chains to generate responses upon user request. Given mentions are a core and commonly used feature of Discord, Crabstero often encounters and includes mentions in its responses. Early in Crabstero's operational history, this led to feedback from some users who found the pings from Crabstero to be annoying and disruptive. In this context, the feedback was especially understandable given Crabstero's responses tend to be completely random and nonsense.
To address this, I implemented an allowed mentions filter on all responses from Crabstero which blocks mentions from generating pings. Problem solved, right?
As it turns out, not everyone found pings from Crabstero to be annoying. On the contrary, some users enjoyed random pings from Crabstero as a fun and unexpected way to engage with the bot. This put me at a crossroads, prompting me to consider how to address two competing goals: accommodating user preferences and maintaining simplicity.
The Pursuit of Simplicity
When I developed and launched Crabstero in 2020, Discord did not have a built-in command sytem for third-party bots. At the time, bots relied on a rudimentary method of recognizing commands called prefix characters. To execute a command in a bot, users would add a specific character, like !
or .
, to the beginning of their message. The bot would then monitor new messages for the prefix character to identify the command and respond.
While this system worked, it came with several drawbacks. One of the biggest problems was prefix conflicts: when two or more bots in the same server used the same prefix character. These conflicts would often lead to confusion as multiple bots would end up acting on the same message. Another major drawback was the lack of a system to help users navigate the commands offered by bots. Instead, users had to rely on external documentation and memorize commands. Although some bots implemented help menus and other related features to assist users within Discord itself, there was no standardized approach.
Given the state of bot commands at the time, I decided early on that one of my core goals for Crabstero would be simplicity. I wanted Crabstero to be a plug-and-play solution which was easy to set up and intuitive to use. With simplicity in mind, I made the decision early on to forgo implementing commands of any kind. Instead, I focused on building a set of default behaviors that would suit most users.
Things have changed significantly since then. In early 2021, Discord announced the introduction of slash commands, a new framework for bot developers which allows bots to register commands directly with the platform. Slash commands have been a fantastic addition which solves many of the prior issues with prefix characters. For example, when two different bots register the same command, they're clearly differentiated for the user, allowing them to chose which bot executes the command. Additionally, each command includes a description provided by the developer of what it does.
With slash commands simplifying the user experience for interacting with bots, adding commands to Crabstero no longer seemed it would undermine its core simplicity. This felt like the perfect opportunity to revisit the earlier challenge of addressing user preferences for pings.
Introducing Optional Pings from Crabstero
With that said, I have implemented Crabstero's first slash command: /pingme
. You can use it to choose whether or not to receive pings from Crabstero.
If you'd like to receive pings for messages from Crabstero which mention you, you can opt in by running the command. If you change your mind later, just run the command again and you will no longer receive pings.
These optional pings are opt-in, so if you prefer to continue not receiving notifications from Crabstero, no action is needed on your part.