Closed JohnnyRacer closed 1 year ago
Can you explain a concrete case here? You want text to speech? So you want deep-translator to output a speech a.k.a audio file?
Yes having the option to get the text to speech to an audio file since Google Translate already has this feature.
If you click on the speaker icon it will narrate the translation.
I see. This is not possible for deep-translator since it uses web scraping to determine the translation and not the google api itself. However, this could be achieved with any library for text-to-speech, for example this one or even better the gtts library
Just take a look at that example. Simply give the output translation from deep-translator to the library and let it handle the conversion for you. With that said, I won't consider this feature for deep-translator since the scope is different here (Well maybe using optional dependencies, then I would consider it)
Hello, is there a way to get the text to speech narration for a translation using Google Translate or other translators that support text to speech? There doesn't seem to be an issue that mentions this that I could find.