This commit is contained in:
Paillat
2022-12-06 21:38:59 +01:00
3 changed files with 21 additions and 6 deletions

13
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,13 @@
# These are supported funding model platforms
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: ['https://www.buymeacoffee.com/paillat']

View File

@@ -5,7 +5,7 @@ Botator is a discord bot that binds openai's gpt3 AI with discord. You will be a
# Adding the bot to your discord server
In order to add the bot to your discord server, you will need an OpenAI API key. You can create an account and take one [here](https://beta.openai.com/account/api-keys)
You can add the bot to your server by clcking [here](https://discord.com/api/oauth2/authorize?client_id=1046051875755134996&permissions=2214808576&scope=applications.commands%20bot)
You can add the bot to your server by clicking [here](https://discord.com/api/oauth2/authorize?client_id=1046051875755134996&permissions=2214808576&scope=applications.commands%20bot). **PLEASE NOTE THAT WEH ARE NOT RESPOSIBLE FOR ANY MISUSE YOU'LL DO WITH THE BOT.**
Then, run the following commands to set your bot up:
@@ -49,6 +49,8 @@ You can always disable the bot by doing **/disable** and delete your api key fro
- [ ] Organize code in COGs
- [ ] Add a log and updates channel option and a way for devs to send messages to that channel on all servers.
- [ ] Add uses count reset after 24h
- [ ] Add moderation.
- [ ] add way to consider the answers to the bot's messages.
<!--
# Docker

View File

@@ -294,11 +294,11 @@ async def on_message(message):
else :
debug("The message has been sent in the wrong channel")
return
#check if the bot hasn't been used more than 200 times in the last 24 hours (uses_count_today)
#check if the bot hasn't been used more than 5000 times in the last 24 hours (uses_count_today)
c.execute("SELECT uses_count_today FROM data WHERE guild_id = ?", (message.guild.id,))
if c.fetchone()[0] >= 200:
debug("The bot has been used more than 200 times in the last 24 hours in this guild")
await message.channel.send("The bot has been used more than 200 times in the last 24 hours in this guild. Please try again in 24h.")
if c.fetchone()[0] >= 5000:
debug("The bot has been used more than 4000 times in the last 24 hours in this guild")
await message.channel.send("The bot has been used more than 5000 times in the last 24 hours in this guild. Please try again in 24h.")
return
#add 1 to the uses_count_today
#show that the bot is typing