Rei-x / discord-speech-recognition

Speech to text extension for discord.js
https://npmjs.com/package/discord-speech-recognition
MIT License
56 stars 22 forks source link

Recognizing voice input from DisTube's voice connection #58

Closed AceHanded closed 1 year ago

AceHanded commented 1 year ago

I know someone has previously reported a problem with voice recognition when using another library for connecting to voice, however the solution presented in that thread (uninstalling the @discordjs/voice package), doesn't seem to work for the DisTube library, when using its distube.voices.join(voiceChannel) method and setting the deafened status to false. The bot does join the voice channel correctly, but the client.on('speech') event never gets emitted with that voice connection. Any help regarding this problem would be greatly appreciated!

Rei-x commented 1 year ago

Hello!

I think you need to pass bot user id to group in speechOptions

addSpeechEvent(client, {
    group: client.user.id
});

Tell me if it fixed your issue!

AceHanded commented 1 year ago

Hi!

Thanks a million, that seemed to fix the issue :)