When I developing WeChat mini program, I want to achieve the voice control. but the audio provided by WeChat client is silk.
I need to convert the silk file to some format can be recognized by 3rd voice detection service.
Some 3rd services support amr format. It's really great, because the size could be very small.
The steps as follows:
brew install ffmpeg --with-opencore-amr --with-speex
.ffmpeg -y -f s16le -ar 24000 -ac 1 -i "$1.pcm" -ar 8000 "${1%.*}.$2”
.