NLP Patterns

Learn more about Tomii Boi's parsing algorithm and what you can do with it.

Admin Portal Image

Patterns

In order to understand questions, Tomii Boi uses patterns written in a simple yet powerful mini-language. By default, all patterns have a 1 typo-tolerance, so you don't have to code for every possible spelling. Here are a few examples:

Pattern 1

"I'm new to the server." - With this pattern, the response will trigger anytime someone says the words "I'm new to the server."

Pattern 2

"new to + server." - This response will trigger any time the someone sends a message with the words "new to" and "server". Whats unique about this pattern is by separating patterns with a plus sign, the response can trigger for a bunch of different messages. For example, "I'm new to this server", or "This is my first time in this server, im new here."

Pattern 3

"new to + server + !(discord)" - Pattern 2 is very dynamic, allowing for many different trigger phrases. While this feature is very convenient it could cause false positive responses, which is where the pattern is triggered even though we don't want it to. In this example, adding "+ !(discord)" to our pattern

Categories

In the picture above you can see that each question is apart of a Category. Categories are a very powerful feature of Tomii Boi. Not only can they be used to organize questions, they can be used to control which Discord Servers and which channels IN those Discord Servers have access to the category. By using categories you can create enormous Q&A databases and control which servers and channels can access them with a click of a button. This makes it extremely easy to manage how Tomii Boi interacts with all of your Discord Servers and completely removes the pain of Server moderation and Bot management