title: Using Coqui
Navigate to Coqui and click on the Get Started button.
Coqui.ai has been discontinued, but enthusiasts can still set up Coqui locally by following the instructions below.
Coqui Local Branch has not yet been merged.
Create a directory for Coqui and navigate to it:
mkdir ~/coqui && cd ~/coqui
Download and install Miniconda:
curl https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-arm64.sh -o miniconda3.sh
chmod +x ./miniconda3.sh
./miniconda3.sh
Create a Conda environment and install Python 3.10:
conda create --name coqui python=3.10
conda activate coqui
Clone the Coqui TTS repository:
git clone https://github.com/coqui-ai/TTS.git
Install dependencies:
brew install mecab espeak
pip install numpy==1.21.6 flask_cors
conda install scipy scikit-learn Cython
Navigate to the cloned TTS directory and install Coqui TTS:
cd TTS && make install
Run the local Coqui TTS server:
python3 TTS/server/server.py --model_name tts_models/en/vctk/vits
Pull the Coqui TTS Docker image:
docker pull ghcr.io/coqui-ai/tts --platform linux/amd64
Run the Coqui TTS container:
docker run --rm -it -p 5002:5002 --entrypoint /bin/bash ghcr.io/coqui-ai/tts
Inside the container, install Flask CORS and run the server:
pip install flask_cors
python3 TTS/server/server.py --model_name tts_models/en/vctk/vits
To ensure that the Coqui server allows cross-origin resource sharing (CORS), add the following lines to Flask app in /TTS/server/server.py :
from flask_cors import CORS
CORS(app)
Settings -> Text-to-Speech -> TTS Backend -> Coqui
Settings -> Text-to-Speech -> Coqui -> Voice ID