diff --git a/freeswitch/transcription-proxy/FSProxy.png b/freeswitch/transcription-proxy/FSProxy.png index e5de3d74..c1268655 100644 Binary files a/freeswitch/transcription-proxy/FSProxy.png and b/freeswitch/transcription-proxy/FSProxy.png differ diff --git a/freeswitch/transcription-proxy/README.md b/freeswitch/transcription-proxy/README.md index bb1064e5..e1cd1bcc 100644 --- a/freeswitch/transcription-proxy/README.md +++ b/freeswitch/transcription-proxy/README.md @@ -1,7 +1,9 @@ ![FSProxy](./FSProxy.png) -# FreeSWITCH Transcription Proxy -Proxy your SIP call via our FreeSWITCH docker and get the transcript of the call audio submitted to a websocket service. +# Voicegain SIP Media Stream B2BUA +Voicegain offers a highly scalable, reliable and fully contained SIP Media Stream B2BUA to address the challenge discussed above. This B2BUA is a containerized network element that is deployed in the same network as the premise-based contact center. From a SIP Protocol standpoint, this Media Stream Back-to-Back User Agent (B2BUA) acts as a transparent media relay while forking SIP RTP media streams to real-time Speech-to-Text.. + +Please refer to this link for more information https://www.voicegain.ai/post/accessing-real-time-media-streams-generative-ai ```Steps for setting up websocket service to receive transciption results in realtime``` # 1) Install required python pacakges @@ -38,9 +40,12 @@ python ws_server.py # 5) Modify config.ini for Freeswitch docker A sample config.ini can be found in this repository. ```ini -# This is the SIP proxy host where you will be sending SIP traffic to +# This is the SIP B2BUA host where you will be sending SIP traffic to FREESWITCH_HOST_DOMAIN=fs1lab.ascalon.ai +# If this value is present then this IP used as SIP trunk to make outbound calls +SIP_GATEWAY_IP=10.1.0.4:64793 # This is the final SIP destination domain where will be proxying to. +#if SIP_GATEWAY_IP is ip mentioned above then this below value will be ignored DESTINATION_DOMAIN=fs.ascalon.ai:5080 # this main voicegain API gateway URL VG_GATEWAY_URL=https://api.voicegain.ai/v1/asr/transcribe/async @@ -56,6 +61,10 @@ RIGHT_CHANNEL_NAME=CALLER2 #words - words with confidence and timing info [also sent over websocket] #segments -- segments (or partial hypotheses) [also sent over websocket, note that latency of segments is higher than that of words by about 300-500ms]] CONTENT_INCREMENTAL=words +DIALED_NUMBER_MAPPING=1233:4567 +SENSITIVITY=1 +AUDIO_CAPTURE=true +NOAUDIOTIMEOUT=31000 ``` # 6) Obtain FreeSWITCH proxy docker @@ -71,15 +80,15 @@ With host networking: -v option specifies local file path where config.ini is located this needs to be changed to where the file was copied. -m to limit memory usage by freewitch docker so below example puts 1GB limit ```sh -docker run -d --name fsproxy --network=host -m 1g -v /Path_to/config.ini:/etc/config.ini us-docker.pkg.dev/voicegain-prod/vg-customer-private/freeswitch-transcription-proxy:0.8.0 +docker run -d --name fsproxy --network=host -m 1g -v /Path_to/config.ini:/etc/config.ini us-docker.pkg.dev/voicegain-prod/vg-customer-private/freeswitch-transcription-proxy:0.14.6 ``` With bridge networking: ```sh -v option specifies local file path where config.ini is located this needs to be changed to where the file was copied. -docker run -d --name fsproxy -p -p 5060:5060/tcp -p 5060:5060/udp -v /Path_to/config.ini:/etc/config.ini us-docker.pkg.dev/voicegain-prod/vg-customer-private/freeswitch-transcription-proxy:0.8.0 +docker run -d --name fsproxy -p -p 5060:5060/tcp -p 5060:5060/udp -v /Path_to/config.ini:/etc/config.ini us-docker.pkg.dev/voicegain-prod/vg-customer-private/freeswitch-transcription-proxy:0.14.6 ``` -Note 1: Be cartefull with the path to the config.ini on Windows systems +Note 1: Be carefull with the path to the config.ini on Windows systems Note 2: If you get an error mentioning `parseConfigFile` and `Is a directory` the most likely the path to config.ini was incorrectly provided diff --git a/freeswitch/transcription-proxy/config.ini b/freeswitch/transcription-proxy/config.ini index 843a25e2..3d4cf643 100644 --- a/freeswitch/transcription-proxy/config.ini +++ b/freeswitch/transcription-proxy/config.ini @@ -7,3 +7,9 @@ WEBSOCKET_SERVER=wss://mydomain.com:8765 LEFT_CHANNEL_NAME=CALLER1 RIGHT_CHANNEL_NAME=CALLER2 CONTENT_INCREMENTAL=words +SIP_GATEWAY_IP=10.1.0.4:64793 +DIALED_NUMBER_MAPPING=1233:4567 +SENSITIVITY=1 +AUDIO_CAPTURE=true +NOAUDIOTIMEOUT=31000 +