Baidu Text-to-Speech


The baidu text-to-speech platform uses Baidu TTS engine to read a text with natural sounding voices.

To get started, add the following lines to your configuration.yaml:

#Example configuration.yaml entry
tts:
  - platform: baidu
    app_id: YOUR_APPID
    api_key: YOUR_APIKEY
    secret_key: YOUR_SECRETKEY

Configuration Variables

app_id

(string)(Required)The App ID for the use this service, must be already registered on Baidu.

api_key

(string)(Required)The API key from Baidu.

secret_key

(string)(Required)The secret key from Baidu.

speed

(int)(Optional)Audio speed from 0 to 9.

Default value: 5

pitch

(int)(Optional)Audio pitch from 0 to 9.

Default value: 5

volume

(int)(Optional)Audio volume from 0 to 15.

Default value: 5

person

(int)(Optional)Voice type. You choose one from 0, 1, 3 or 4.

Default value: 0