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

Option for changing base language? #53

Closed molesquirrel closed 1 year ago

molesquirrel commented 1 year ago

I saw an earlier issue regarding language support, but more simply, is there a way to set the default language (or multiple languages) used for the speech recognition?

mbarretol commented 1 year ago

This is how you change the english default language: addSpeechEvent(client, { lang: "pl-PL" }). Make sure that the language format is correct for your desired language.

molesquirrel commented 1 year ago

Thanks! I see the Google cloud at least appears to support multiple languages at once; is there a known format for entering in more than one language using the above advice?

On Fri, Mar 31, 2023, 7:29 AM Narco121 @.***> wrote:

This is how you change the english default language: addSpeechEvent(client, { lang: "pl-PL" }). Make sure that the language format is correct for your desired language.

— Reply to this email directly, view it on GitHub https://github.com/Rei-x/discord-speech-recognition/issues/53#issuecomment-1491048678, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAVQNLRZAQLOXZ6KACSTVNTW6YCKXANCNFSM6AAAAAAWMWVVDA . You are receiving this because you authored the thread.Message ID: @.***>

mbarretol commented 1 year ago

No you can only set one language at a time with english as the default language. If you want support for multiple languages, you have to customize the code yourself.