Text-to-speech service using Suno AI Bark model with multilingual voice presets.
cd services/modelBark
# Create virtual environment and install dependencies
python -m venv venv
source venv/bin/activate
pip install -r requirements.txtStart the service on port 5008:
./venv/bin/python app.pyFirst run downloads models (approximately 5GB, may take 5-10 minutes).
Health Check:
curl http://localhost:5008/healthGenerate speech:
curl -X POST http://localhost:5008/synthesize \
-H "Content-Type: application/json" \
-d '{
"text": "Hello, this is a test.",
"voice": "v2/en_speaker_6",
"output_filename": "output.wav"
}'Response:
{
"audio_file": "/path/to/output.wav",
"duration": 2.3,
"generation_time": 1.8
}List voices:
curl http://localhost:5008/voicesSupports 10+ voices in multiple languages (en, es, fr, de, zh, etc.).