remove bing
This commit is contained in:
parent
9e92a0c509
commit
bd28d92e7d
1 changed files with 1 additions and 10 deletions
|
@ -34,21 +34,12 @@ async def transcribesphinx(inter: disnake.ApplicationCommandInteraction, message
|
|||
try:
|
||||
await inter.response.defer(ephemeral='true')
|
||||
await message.attachments[0].save("audio.ogg")
|
||||
# WARNING Google is propritary, consider disabling however sphynix is currently not very good so this provides an option
|
||||
await inter.edit_original_message(content=st.recognize_google(prepaudio("audio.ogg")))
|
||||
os.remove("audio.ogg")
|
||||
os.remove("audio.wav")
|
||||
except Exception as e:
|
||||
await inter.edit_original_message(content=f'an error appears to have occoured please report it to the developer: {e}')
|
||||
|
||||
@bot.message_command(name="Transcrible Using Bing")
|
||||
async def transcribesphinx(inter: disnake.ApplicationCommandInteraction, message: disnake.Message):
|
||||
try:
|
||||
await inter.response.defer(ephemeral='true')
|
||||
await message.attachments[0].save("audio.ogg")
|
||||
await inter.edit_original_message(content=st.recognize_bing(prepaudio("audio.ogg")))
|
||||
os.remove("audio.ogg")
|
||||
os.remove("audio.wav")
|
||||
except Exception as e:
|
||||
await inter.edit_original_message(content=f'an error appears to have occoured please report it to the developer: {e}')
|
||||
|
||||
bot.run(os.getenv("TOKEN"))
|
Loading…
Reference in a new issue