Skip to main content

How to configure vicidial voice broadcast campaign with Google TTS

 

vicidial voice broadcast campaign with Google TTS


vicidial google text to speech




Google TTS agi:

Google TTS is open source as of dated jan 2021We will be using the asterisk agi provided by zaf.github to interact with google tts engine for text to speech .link to download agi 
https://zaf.github.io/asterisk-googletts/


  Step 1: Installing the Pre-requisites


Debian :-
apt-get install perl
apt install libwww-perl
sudo cpan install LWP::UserAgent
sudo cpan install LWP::Protocol::https
apt install sox
apt install mpg123
_____________________________


openSuse:-

zypper install perl

zypper install perl-libwww-perl

zypper install perl-LWP-Protocol-https

zypper install sox

zypper install mpg123

asterisk -rx  "module load format_sln.so"

(note format_sln might be pre loaded in most asterisk)


  Step 2:  Download the google tts AGI to asterisk server

link: https://zaf.github.io/asterisk-googletts/

git clone git://github.com/zaf/asterisk-googletts
or 
wget https://github.com/zaf/asterisk-googletts/zipball/master
unzip master
cd zaf-asterisk-googletts*

---now we need to copy the agi to asterisk agi-bin folder

cp googletts.agi /var/lib/asterisk/agi-bin/

chmod 755 /var/lib/asterisk/agi-bin/googletts.agi

  Step 3: Asterisk dialplan 

we need to write two dialplans.

  1. carrier dialplan

in default vicidial carrier dialplan , we need to add additional line which is used to set the vicidial lead fields as variable,which we are going use it for text to speech.

the agi name is agi-set_variables.agi provided by vicidial team


exten => _9X.,1,AGI(agi://127.0.0.1:4577/call_log)

exten => _9X.,n,AGI(agi-set_variables.agi)

exten => _9X.,n,Dial(SIP/SIPTRUNK/${EXTEN:1},,Tto)

exten => _9X.,n,Hangup()


  2. custom dialplan to playback the message with google tts agi.

Either you can write this dialplan in extensions.conf or write it in vicidial custom dialplan entry
exten => 668899,1,Answer()
exten => 668899,n,Wait(2)
exten => 668899,n,agi(googletts.agi,"hello, mr.${first_name} your credit card due date is ${date_of_birth}",en)
exten => 668899,n,agi(googletts.agi,"if already paid kindly discard this call, have a nice day",en)
exten => 668899,n,Hangup()

  Step 3 : Creating Voice broadcast campaign.

For creating the voice broadcast campaign in vicidial kindly check and follow the below link

add the 668899 as line extension in remote agents 


Dial plan variable By Vicidial









TTS language Supported by Google.







    Google TTS will not support huge call volume , they might block your IP if too many connections established.



For support reach me at skype:manish.kadiya

Comments

Popular posts from this blog

Vicidial Scratch installation Alma -9

Step 1 – Download the dependencies   hostnamectl set-hostname xxxxxx.xxxxx.xxx ### Use YOUR SubDomain vi /etc/hosts ##Change domain name for actual server ip (xxx.xxx.xxx.xxx   complete domain name    subdomain only) timedatectl set-timezone Asia/Kolkata yum check-update yum update -y yum -y install epel-release yum update -y yum install git -y yum install -y kernel* sudo dnf install kernel-devel-$(uname -r) -y #Disable SELINUX sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config     reboot Step 2 – Run the Script cd /usr/src/ git clone https://github.com/manish23k/vicidial-install-scripts cd vicidial-install-scripts chmod +x alma-rocky9-ast16.sh ./alma-rocky9-ast16.sh Or the Asterisk 18 version: chmod +x alma-rocky9-ast18.sh ./alma-rocky9-ast18.sh ####For PHP 8 use this script. chmod +x main-installer-php8.sh ./main-installer-php8.sh

How to delete old call logs and other logs in vicidial or goautodial.

Step 1 : SSH to the server using the Putty Step 2:   login to mysql by typing   mysql -p                    (if you dont know password try below command )               mysql -ucron -p1234 Step 3 : select the asterisk database by typing               use asterisk step 4: Run the below command to check total disk occupied by asterisk database                SELECT table_schema AS "asterisk", ROUND(SUM(data_length + index_length) / 1024 / 1024, 2) AS "Size (MB)" FROM information_schema.TABLES GROUP BY table_schema; Step 5 : Run the below command to check disk space consumed by each table in asterisk database SELECT table_name AS "Table", ROUND(((data_length + index_length) / 1024 / 1024), 2) AS "Size (MB)" FROM information_schema.TABLES WHERE table_schema = "asterisk" ORDER BY (data_length + inde...

Install the No-IP client (Dynamic Update Client) on AlmaLinux 9

 Install the No-IP client (Dynamic Update Client) on AlmaLinux 9 1. Install Required Packages First, install the necessary packages to compile the client from source. sudo dnf install gcc make wget tar 2. Download the No-IP DUC (Dynamic Update Client) Download the latest version of the No-IP DUC. cd /opt wget https://www.noip.com/client/linux/noip-duc-linux.tar.gz 3. Extract the Downloaded File Extract the downloaded tarball. tar -zxvf noip-duc-linux.tar.gz cd noip-2.1.9-1/ 4. Compile the Client Run the following commands to compile the client. sudo make install 5. Configure the No-IP Client After installation, you’ll be prompted to enter your No-IP account credentials (email and password) and choose the hostname(s) to update. If not, you can manually run the configuration: sudo /usr/local/bin/noip2 -C 6. Start the No-IP Client To start the client: sudo /usr/local/bin/noip2 7. Verify Installation To confirm that the No-IP DUC is running, use: sudo /usr/local/bin/noip2 -S 8. Set Up...