用于python的简单tts(文本到语音)代理
ttsbroker的Python项目详细描述
ttsbroker
用于python的简单tts(文本到语音)代理
许可证:apache license 2.0
警告:有关缓存、存储和重新分发,请参阅TTS提供程序许可证 以及使用tts引擎生成的音频文件的播放权限。
该模块包含以下提供程序:
gcloud:google cloud tts(需要云服务帐户密钥),需要 oauth2client python模块
polly:amazon polly(需要aws api密钥),需要boto3 python模块
Watson:IBM Watson(需要Watson服务凭据)
用法示例:
fromttsbrokerimportTTSEngineasTTSEe=TTSE(cache_dir='/data/cache/gcloud',cache_format='ogg',device=0,gain=0,provider='gcloud')e.set_key('client_service_key.json')e.say('test number one',gain=2)e.say('test number two',provider_options={'voice':'en-US-Wavenet-E'})
(c)2018年Altertech集团,https://www.altertech.com/