~/KLAIR
- 18 Devlogs
- 17 Total hours
~/KLAIR is a free-to-use discord bot packed with exceptional AI features and some fun mini games!
~/KLAIR is a free-to-use discord bot packed with exceptional AI features and some fun mini games!
Spent a few minutes just adding comments to the code so it becomes more understandable. Some of the examples of comments I’ve added are in the screenshot I’ve attached.
The bot is practically completed at this point. I’ll spend a few more minutes writing the README.md file and creating a showcase video for the bot.
So, if you were trying to ask the bot a question in the VC and there was some background noise, the bot would glitch out and sometimes fill its buffer of holding the audio chunks of the users.
Now, I have fixed this issue and added a “End Session” button so that the user can get the summary of their conversation without waiting for 3 mins inactivity in the VC.
**Most of the voice handling and AI stuff was implemented using Gemini 3.1 Pro as I don’t have an idea on how to manage audio chunks and stuff. **
Oof! This took wayyyy too long to implement. Now, instead of typing your queries / prompts, you can actually talk to the bot! It creates a private voice channel (only you and the bot) and you can ask it questions. It’s instantaneous too! I honestly love this feature!
I can’t show the full working of this command in a screenshot so, the full demo of this command, (including all the other commands) will be in the showcasing video that I’ll create. Stay tuned for that!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS
IT GOES AGAINST THEIR TOS.
Sometimes, even the simplest of explanations of concepts might start feeling hard to understand. This is where ELI5, or Explain Like I’m 5 comes to play! Simply, tell the bot what concept you want to get explained and it will do exactly that for you in a simple, fun way!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
This is also pretty self-explanatory. You pass it on a claim that you want to get fact checked and get a response. However, since the model doesn’t have access to the internet (as Google Search tool with Gemini isn’t included in the free tier of Google Cloud Projects), the user is always informed at the end of a message that the bot can make mistakes.
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
It’s pretty self-explanatory. You pass it on a sentence (or multiple sentences) and tell it your desired sentence type (default being normal) and it converts your sentence into the desired sentence type while ensuring no there are no grammar, spelling or any other mistakes in the output!.
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Now, if an error occurs, the bot will tell the user something has happened rather than just ghosting the user. I forgot to implement this error handling in the last update so, here it is!
Now, you aren’t required to type /ask all the type to ask the bot a question! Simply do KLAIR, <question> and the bot will respond with a generated response!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Ask the AI (Gemini’s Latest Flash Lite model - Gemini 3.5 Flash Lite) any question and it will answer it! This is the first AI feature and there are many more AI features to come!
Earlier, I was testing out the normal Gemini Flash Model (Gemini 3.6 Flash) but I quickly reached a problem- Rate Limits! Previously, Google had a really high rate limit for their AI Models in the free tier however, they have since significantly reduced that. And this sucks! 1500 RPD down to 20 RPD for the Flash model is INSANITY!
In order to not get rate limited after only 20 requests, I took the decision to use a much dumber AI model.
It’s on Discord though, I’m pretty sure if users need a more in-depth or accurate answer, they’ll probably go to the actual AI website rather than ask the bot.
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
You just pass it on a question and it generates a random prediction of whether something will happen or not!
PS. even though the description says the question must end with a “?”, it isn’t required for it to end with it!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Basically the Cat Image Displaying Command but instead of cat it displays an image of a dog!
Fetches an API and displays a useless fact! Some of these are actually kinda interesting though!
Fetches an API and displays the price of the cryptocurrency the user has asked for. I don’t know why someone would need to know the price of a crypto on Discord, but hey! At least, the option is there!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
It’s pretty self-explanatory. You type /cat and it fetches a cat image from a free API and sends it on discord!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Nim is a strategic mini game. There are 15 rocks in total. In each turn, the player can take away 1, 2 or 3 rocks. The bot will also randomly take away some number of rocks. In order to win you need to make the opponent take the last rock. If you take the last rock, you lose!
This mini game is actually really fun to play!
Had to use Gemini 3.1 Pro to fix some bugs because somehow I can never make a fully working mini game by myself. (I guess it’s just skill issue lol.)
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Okay this mini game took WAYYY TOO LONG! It took like almost an hour just to fetch the word and display it and another hour to actually make the mini game working.
Unscramble button opens up a Modal for the user to input their guess.idk how this took 2 hours to make but at least it works!
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
aghhh being sick isn’t fun. i wasn’t able to code for 3 days cuz i was sick :( anyways
The mini game is self-explanatory. You just guess whether the coin flip came out to be heads or tails! This shouldn’t have taken 40 mins but somehow it did. (maybe cuz i’m still sick and recovering but who knows?)
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
So, just spent like an hour working on this. The main challenge I faced was to retrieve the guess submission from the user. I wasn’t able to do that so I required the help of my friend Gemini 3.1 Pro (High) in Antigravity IDE to do that for me.
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
So, Just spend a couple of minutes implementing a working rock paper scissors mini game.
button feature to ask for the user’s choice.Math.Random() function to select its own choice.Will spend some more time refining its style later but the actual mini game is complete for now.
NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.
Bot is being developed using Discord.js . What has been added till now:
ready output whenever the Discord Bot has successfully logged in.ping command that replies with “Pong!” (just for testing).NOTE: I’m using a modified version of discord ONLY to show some useful information (like which device I’m using [see members list], what the previous messages were of the bot [see chat, message logger is enabled]. I DO NOT CONDONE THE USAGE OF MODIFIED VERSIONS OF DISCORD AS IT GOES AGAINST THEIR TOS.