[Python] How to specify the voice name in python/gTTS?

Discussão em 'Python' iniciado por Stack, Novembro 30, 2024.

  1. Stack

    Stack Membro Participativo

    I have this python script on macOS:

    from gtts import gTTS

    text = """
    bla bla bla
    bla bla bla
    """

    tts = gTTS(text, lang='en')
    tts.save("MyFile.mp3")


    this works perfectly but it uses a voice that I don't want.

    I want this voice called en-US-Journey-D that I see on the google gtts page.

    Is there a way to specify the voice name on the python script?

    I am not finding any documentation about it.

    Continue reading...

Compartilhe esta Página