The SDK communicates with a Diatheke Server instance using
gRPC. Cobalt distributes a docker image that contains
the diathekesvr
binary and model files.
Contact Cobalt to get a link to the image file in AWS S3. This link will expire in two weeks, so be sure to download the file to your own server.
Download with the AWS CLI if you have it, or with curl:
URL="the url sent by Cobalt"
IMAGE_NAME="name you want to give the file (should end with the same extension as the url, usually bz2)"
curl $URL -L -o $IMAGE_NAME
Load the docker image
docker load < $IMAGE_NAME
This will output the name of the image (e.g. diatheke-demo-en_us-16
).
Start the diatheke service
docker run -p 9002:9002 --name cobalt diathekesvr-demo-en_us-16
That will start listening for grpc commands on port 9002. You can replace
--name cobalt
with any name you want to give the docker container.
The name simply provides a way to refer back to the running container.
To install the Diatheke SDK, use git to clone the sdk-diatheke repository:
git clone https://github.com/cobaltspeech/sdk-diatheke.git
The sdk-diatheke repo contains example code with subdirectories for various languages to build demo client applications. Simply follow the README instructions for each language to build and run the sample applications.