can i use edge tts package of python for my web application(how to create edge tts web app using edge tts) tutorial and If I am not capable why it is available for free in the internet.

TAYEB LAGHA 0 Reputation points
2024-10-27T14:16:20.27+00:00

Hi microsoft can I use edge tts for web application demo tutorial on youtube(commercial use) using fastapi and this code

import asyncio

import edge_tts

VOICES = ['en-US-AndrewNeural','es-US-AlonsoNeural','en-GB-RyanNeural' ]

TEXT = "Hi Ladies and Gentleman"

VOICE = VOICES[0]  # Choose a valid index from the VOICES list

OUTPUT_FILE = "test.mp3"

RATE = "-1%"  # Decrease the speech rate by 25%

async def amain() -> None:

    communicate = edge_tts.Communicate(TEXT, VOICE, rate=RATE)

    await communicate.save(OUTPUT_FILE)

loop = asyncio.get_event_loop_policy().get_event_loop()

try:

    loop.run_until_complete(amain())

finally:

    loop.close()

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
39,786 questions
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.