A quick easy way to access MeloTTS through REST API calls.
Assuming you have docker installed and setup.
(This might take a bit because MeloTTS is a big dependency)
git clone git@github.com:timhagel/MeloTTS-Docker-API-Server.git
cd MeloTTS-Docker-API-Server
docker build -t timhagel/melotts-api-server .
docker pull timhagel/melotts-api-server
- EN - English
- ES - Spanish
- FR - French
- ZH - Chinese
- JP - Japanese
- KR - Korean
- EN-US - American English accent
- EN-BR - British English accent
- EN_INDIA - Indian English accent
- EN-AU - Australian English accent
- EN-Default - Default English accent
- Notice! Currently only English accents are working, and other accents are returning an error. This does not mean that other languages do not work!
docker run --name melotts-server -p 8888:8080 -e DEFAULT_SPEED=1 -e DEFAULT_LANGUAGE=EN -e DEFAULT_SPEAKER_ID=EN-Default timhagel/melotts-api-server
docker run --name melotts-server -p 8888:8080 --gpus=all -e DEFAULT_SPEED=1 -e DEFAULT_LANGUAGE=EN -e DEFAULT_SPEAKER_ID=EN-Default timhagel/melotts-api-server
localhost:8888/convert/tts
Response: .wav
{
"text": "Put input here"
}
curl http://localhost:8888/convert/tts \
--header "Content-Type: application/json" \
-d '{ "text": "Put input here" }' \
--output "example.wav"
Response: .wav
{
"text": "input",
"speed": "speed",
"language": "language",
"speaker_id": "speaker_id"
}
curl http://localhost:8888/convert/tts \
--header "Content-Type: application/json" \
-d '{
"text": "Put input here",
"speed": "0.5",
"language": "EN",
"speaker_id": "EN-BR"
}' \
--output "example.wav"
This is just an API server for the awesome work of MeloTTS from MyShell