This is a simple server application that processes audio from Twilio Media Streams and generates real-time transcripts using Bodhi.
Please note: This demo is unidirectional, meaning you won't receive any response during the call. However, you'll be able to view live transcripts on your console.
For detailed configuration and response information, refer to the Bodhi documentation.
- Create your virtualenv
python3 -m venv venv
. - Run
source venv/bin/activate
. - Run
pip3 install -r requirements.txt
. - Run
python3 streaming.py
.
- Access the Twilio console to get a
<TWILIO-PHONE-NUMBER>
. - Run the server (listening on port 8080).
- Edit the
streams.xml
file in thetemplates
directory and add your tunnel/server URL aswss://<server url>
. - Change webhook URL in incoming config Twilio phone number config.