Skip to content

text-to-speech

Description

Note

More information about the service specification can be found in the Core concepts > Service documentation.

This service calls an api based on this repository: https://github.com/travisvn/openai-edge-tts.

The API is based on Edge-TTS and returns an mp3 audio file based on user-submitted text. The entry must be a json file contains the following fields: input: the text to be transcribed (optional) voice: open-API voice names. Default voice is in french (optional) speed: playback speed (0.25 to 4.0, default 1.2)

Example of an input file's contents: {"input": "Hello, world!", "voice": "echo", "speed": 1.5}

The API documentation is automatically generated by FastAPI using the OpenAPI standard. A user friendly interface provided by Swagger is available under the /docs route, where the endpoints of the service are described.

This service only has one route /compute that takes a text as input and returns a summary of the text using the Hugging Face library philschmid/bart-large-cnn-samsum.

Environment variables

Check the Core concepts > Service > Environment variables documentation for more details.

Run the tests with Python

Check the Core concepts > Service > Run the tests with Python documentation for more details.

Start the service locally

Check the Core concepts > Service > Start the service locally documentation for more details.