machero / speech
Installs: 21
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 0
pkg:composer/machero/speech
This package is not auto-updated.
Last update: 2025-10-01 15:48:50 UTC
README
本项目是基于百度智能语音的SDK扩展封装为php的composer包
Install
composer require machero/speech
Use
$speech = new AipSpeech( config('baidu-speech.app_id'), config('baidu-speech.app_key'), config('baidu-speech.app_secret') ); $this->speech = $speech; /** * @apiparams $text 要合成的文本 * @apiparams $spd 语音的速度 * */ $mp3 = $this->speech->synthesis($text, $lang='zh', $ctp=1, $options=array('spd'=>3)); //具体请参考百度智能语音开发文档