mirror of
https://github.com/Paillat-dev/Botator.git
synced 2026-01-02 09:16:19 +00:00
Update code.py
This commit is contained in:
@@ -399,9 +399,6 @@ async def on_message(message):
|
|||||||
presence_penalty=float(presence_penalty),
|
presence_penalty=float(presence_penalty),
|
||||||
stop=[" Human:", " AI:", "AI:", "Human:"] )
|
stop=[" Human:", " AI:", "AI:", "Human:"] )
|
||||||
#send the response
|
#send the response
|
||||||
#wait a random amount of time between 0 and 2 seconds in order to make the bot look more human
|
|
||||||
#dont show that the bot is typing anymore
|
|
||||||
await asyncio.sleep(random.randint(0, 2))
|
|
||||||
if response["choices"][0] ["text"] != "":
|
if response["choices"][0] ["text"] != "":
|
||||||
#check if tts is enabled in the database
|
#check if tts is enabled in the database
|
||||||
c.execute("SELECT tts FROM data WHERE guild_id = ?", (message.guild.id,))
|
c.execute("SELECT tts FROM data WHERE guild_id = ?", (message.guild.id,))
|
||||||
|
|||||||
Reference in New Issue
Block a user