mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-19 16:22:10 +00:00
Tst
This commit is contained in:
@@ -292,7 +292,7 @@ logger.info("Done")
|
|||||||
# *=========================================== Create Client
|
# *=========================================== Create Client
|
||||||
logger.info("Creating discord bot")
|
logger.info("Creating discord bot")
|
||||||
client = commands.Bot(intents=intents, command_prefix="$")
|
client = commands.Bot(intents=intents, command_prefix="$")
|
||||||
client.add_cog(voice_recognition.Transcriber(client))
|
client.load_extension("voice_recognition")
|
||||||
logger.info("Done")
|
logger.info("Done")
|
||||||
logger.info("Creating flask app")
|
logger.info("Creating flask app")
|
||||||
logger.info("Done")
|
logger.info("Done")
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ class Transcriber(commands.Cog):
|
|||||||
if channel is not None:
|
if channel is not None:
|
||||||
await channel.send(f'Witaj u Nas {member.mention}.')
|
await channel.send(f'Witaj u Nas {member.mention}.')
|
||||||
|
|
||||||
@commands.command()
|
@commands.hybrid_command()
|
||||||
async def witaj(self, ctx, *, member: discord.Member = None):
|
async def witaj(self, ctx, *, member: discord.Member = None):
|
||||||
"""Says hello"""
|
"""Says hello"""
|
||||||
member = member or ctx.author
|
member = member or ctx.author
|
||||||
@@ -49,3 +49,6 @@ class Transcriber(commands.Cog):
|
|||||||
)
|
)
|
||||||
for utterance in transcript.utterances:
|
for utterance in transcript.utterances:
|
||||||
print(f"Speaker {utterance.speaker}: {utterance.text}")
|
print(f"Speaker {utterance.speaker}: {utterance.text}")
|
||||||
|
|
||||||
|
def setup(bot):
|
||||||
|
bot.add_cog(Transcriber(bot))
|
||||||
Reference in New Issue
Block a user