Asterisk voip how to – making speech enabled company IVR with queues

April 23, 2015

This IVR demo dial plan demonstrates how you can make a simple and functional speech enabled IVR for your company.
You will need the LumenVox Speech Engine for Asterisk installed in order to run this voice application.

IVR speech application is developed using Visual Dialplan for Asterisk and pre-configured to be used with Elastix PBX.
The output of the Visual Dialplan is standard Asterisk extensions.conf code and grammar files, automatically deployed and loaded to the Asterisk server. However, you will need to manually place the sound files used in this demo in the /var/lib/asterisk/sounds/ folder.

The first step is to have installed and running three pieces of software:

1. Elastix PBX

Download the Elastix PBX ISO package and follow on screen instructions to install it.
We recommend installation on virtual machine rather than dedicating complete PC for this test.
Besides Asterisk GUI, the ISO will install Linux OS, MySQL database, Asterisk core PBX etc.

2. Visual Dialplan

Visual Dialplan is intuitive and easy to use tool for the dial plan development.

Download Visual Dialplan here: Visual Dialplan download

3. LumenVox automated speech recognizer

The LumenVox automated speech recognizer is a software solution that converts spoken audio into text, providing users with a more efficient means of input. A Speech recognizer compares spoken input to a list of phrases to be recognized, called a grammar. The grammar is used to constrain the search, enabling the recognizer to return the text that represents the best match. This text is then used to drive the next steps of your speech-enabled application.
More details about this software and download options can be found at LumenVox web site.

 

Contexts description

vdp-inbound/vdp-outbound context
The entry point for this dial plan is the vdp-inbound context.
This context (vdp-inbound) is the default entry point for all incoming calls for Free PBX, so we decided to use the default context to start our IVR dial plan.
The only purpose of this context is to accept calls coming to DID (extension) 6789 and to forward those calls to the IVR-mainmenu context.
In case you want to handle outgoing calls with the same IVR dial plan, like we decided to do in this demo, you should use vdp-outbound context with the same dial plan logic like vdp-inbound context.
In other words, if you dial 6789 from your phone registered at Free PBX or you dial your Free PBX number and DID 6789, your call will go to IVR-mainmenu context.

Image

IVR-mainmenu context
In this context the caller hears the main IVR menu and needs to choose one of the following options:
0) Company representative,
1) Company latest news ,
2) Customer support,
3) Sales department

or to enter three digits number to dial the company extension (_XXX dial plan pattern).

The choice can be done by typing the number on the phone keypad or by simply saying the option.

If caller picks option 0 (say ‘Company representative’ or type in 0), dial-plan passes the call directly to the company representative.
If caller choose option 1 (say ‘Company latest news’), dial-plan plays the latest company news.
If caller picks option 2 (say ‘Customer support’), dial-plan passes the call to the CustomerSupport context.
If caller choose option 3 (say ‘Sales department’), dial-plan passes the call to the SalesDepartment context.

In case the caller entered three digits number, or said three digits, the dial plan will dial the three digits company extension and the phone on that extension will ring. If nobody answers or the line is busy, the voice mail application will be called and the caller will leave the voicemail.

In case of choosing invalid option, for example if caller enters 4, the dial plan will go back to the beginning of this context and the caller will be presented with IVR options again.

CustomerSupport context
In this context the caller hears the support IVR menu and needs to choose one of the following IVR options:
1) Standard product user (goes to standard product users queue),
2) Professional product user (goes to professional product users queue)
3) Go back to the main IVR menu (IVR-mainmenu context)

In this case, exceptions such as timeout and invalid extension are also handled.

Image

SalesDepartment context
In this context the caller is presented with the sales IVR menu and needs to choose one of the following options:
1) Individual licensing (goes to sales queue for individual users),
2) Enterprise licensing (goes to sales queue for enterprise users)
3) Go back to the main IVR menu (IVR-mainmenu context)

Image

ASR grammars

menu
#ABNF 1.0;
language en-US;
mode voice;
tag-format <semantics/1.0.2006>;
root $mainmenu;

$news = (News) {out=”1″};
$support =(Customer [Support]) {out=”2″};
$sales =(Sales [Department]) {out=”3″};
$agent = (Operator [Company] [Representative]) {out=”0″};

$mainmenu = ($news | $support | $sales | $agent ) {out = rules.latest()};

support
#ABNF 1.0;
language en-US;
mode voice;
tag-format <semantics/1.0.2006>;
root $support;

$standard= (Standard [product]) {out=”1″};
$proffessional = (Professional [Product]) {out=”2″};
$mainmenu = (Main menu [back]) {out=”3″};

$support = ($standard | $proffessional | $mainmenu ) {out = rules.latest()};

digits
#ABNF 1.0 UTF-8;

language en-US;

mode voice;

tag-format <lumenvox/1.0>;

root $Digits;

$Digit = (ONE:”1″        |
TWO:”2″        |
THREE:”3″      |
FOUR:”4″       |
FIVE:”5″       |
SIX:”6″        |
SEVEN:”7″      |
EIGHT:”8″      |
NINE:”9″       |
(ZERO | O | OH):”0″ );

$Digits = {$=”} ($Digit {$+=$$})<3>; //Limit return string to exactly 3 digits
 

Leave a response »



---------------------------------------------------

Asterisk voip how to – create simple speech enabled call router

February 23, 2014

This Call Router dial plan applicationdemonstrates one method of asking for names and routing calls to the appropriate extension based on that name. Besides Asterisk PBX, you will also need the LumenVox Speech Engine for Asterisk installed in order to run this voice application.

This voice application is developed using Visual Dialplan for Asterisk and pre-configured to be used with FreePBX or any other Asterisk GUI that includes FreePBX (AsteriskNOW, Elastix, PIAF, trixbox).

The output of the Visual Dialplan is standard Asterisk extensions.conf code and grammar files, automatically deployed and loaded to the Asterisk server. However, you will need to manually place the sound files used in this demo in the /var/lib/asterisk/sounds/ folder.

The first step is to have installed and running three pieces of software:

1. Asterisk PBX

There are several Asterisk GUIs on the market.

We recommend Elastix GUI. Download it here.

Download the Elastix PBX ISO package and follow on screen instructions to install it.
We recommend installation on virtual machine rather than dedicating complete PC for this test.
Besides Asterisk GUI, the ISO will install Linux OS, MySQL database, Asterisk core PBX etc.

2. Visual Dialplan

Visual Dialplan is intuitive and easy to use tool for the dial plan development.

It comes with several ready to use dial plan examples, including several speech enabled dial plan examples.
You can start by trying and modifying one of the samples or you can start with the example we use in this article.

Download Visual Dialplan here: Visual Dialplan download

3. LumenVox automated speech recognizer

The LumenVox automated speech recognizer is a software solution that converts spoken audio into text, providing users with a more efficient means of input. A Speech recognizer compares spoken input to a list of phrases to be recognized, called a grammar. The grammar is used to constrain the search, enabling the recognizer to return the text that represents the best match. This text is then used to drive the next steps of your speech-enabled application.
More details about this software and download options can be found at LumenVox web site.

 

Contexts description

Call Router context
This is the entry point for the Call Router demo dial plan. Dial plan accept calls coming to DID (extension) 789 and creates a speech port. Then the directory grammar is loaded and SpeechBackground application executed to perform the speech recognition while playing the sayname voice prompt. And last the the grammar is deactivated.

Dial plan checks SPEECH(results) to ensure there was at least one result (i.e. we actually received spoken input).

If not, we play the no input prompt and ask the caller to say something. Now that we know there was input, we save the recognized extension to the variable DIALTHIS and print some log messages to the console. Then dial plan runs a few checks on the confidence score. If it was really low (below 400), we will reject the utterance and ask the user to repeat what was said. If it was between 400 and 700, we launch the confirmation macro, passing the recognized result as the argument. If the user confirms by saying yes, or if the confidence score was above 700, we send the user to the specified extension.

Image

 

Macro/Subroutine description

CallRouter-confirm macro/subroutine
The confirmation macro is used when the application receives input that has a middling confidence score. The macro will ask the user to confirm what he or she said. There are three prompts used in this case: confirm990.gsm, confirm991.gsm, and confirm992.gsm. The macro knows which one to play based on the CONFIRMPROMPT variable, made by combining the word “confirm” with the recognized extension.

Image

Create Call Router for your own company

If you want to add more employees to Call Router list you will have to change grammar and sound prompts. Grammars are files that contain a list of words and phrases to be recognized. They consist of a list of rules. Each rule contains tokens which will match those rules. A special rule called the root rule exists. It must be matched for the grammar to be matched.

Grammar used in Call Router dial plan:

#ABNF 1.0;
language en-US;
mode voice;
tag-format <semantics/1.0.2006>;
root $company_directory;

$tom = (Tom [Smith]) {out=”990″};
$joe = ((Joe | Joseph) [Jones]) {out=”991″};
$bob = ((Bob | Robert | Bobby) [Johnson]) {out=”992″};

$company_directory = ($tom | $joe | $bob ) {out = rules.latest()};

If you want to add for example Melisa to your Call Router list you will have to change Grammar to look like this (text added in blue):

#ABNF 1.0;
language en-US;
mode voice;
tag-format <semantics/1.0.2006>;
root $company_directory;

$tom = (Tom [Smith]) {out=”990″};
$joe = ((Joe | Joseph) [Jones]) {out=”991″};
$bob = ((Bob | Robert | Bobby) [Johnson]) {out=”992″};
$melisa = ((Melisa [Mel]) {out=”994″};

$company_directory = ($tom | $joe | $bob | $melisa ) {out = rules.latest()};

You will also need to add the sound prompt confirm994.gsm to your Asterisk sound folder.

 

Leave a response »



---------------------------------------------------

Asterisk voip how to – create simple speech enabled dial plan

November 20, 2013

Did you ever wanted to create IVR that recognize caller’s voice?
I guess you did but there are too many questions that are immediately coming to your mind when thinking about caller’s voice recognition – what software do I need to recognize voice, how to program it, do I need some additional hardware besides Asterisk PBX etc.

However, the truth is that creating speech enable dial plans is much more easier than it looks like at first glance.
Of course, to make it easy you would need the right set of tools.

In this article we will discuss how you can create simple speech enabled dial plan, and will create Hello Worlds dial plan that recognizes caller voice.
You can also download already created dial plan that will be used here: Download hello-world speech enabled dial plan

If you have any trouble loading the dial plan, contact us and we’ll gladly work with you to help you set it up.

The first step is to have installed and running three pieces of software:

1. Asterisk PBX

Asterisk PBX is available in two major distributions – standalone Asterisk PBX without GUI, and Asterisk PBX with a GUI.
We recommend Asterisk PBX with a GUI since it is much easier to set it up through the GUI comparing to manual files configuration under Linux.

There are several Asterisk GUIs on the market (Elastix, PIAF, AsteriskNOW etc.) but we do recommend Elastix GUI. Download it here.

Download the Elastix PBX ISO package and follow on screen instructions to install it.
We recommend installation on virtual machine rather than dedicating complete PC for this test.
After you are learn more, you can always switch to dedicated PC.

Besides Asterisk GUI, the ISO will install Linux OS, MySQL database, Asterisk core PBX etc.

2. Visual Dialplan

Visual Dialplan is intuitive and easy to use tool for the dial plan development. It is especially good choice in case of speech enabled dial plans development since it comes with ASR (Automatic Speech Recognition) Grammar editor and integrates ASR grammar with the dial plan during the deployment process. This last functionality will significantly speed up your speech enabled dial plan development and deployment.
Also, there is no need to know Linux or to have some Asterisk experience to use Visual Dialplan and create complex dial plans.

Visual Dialplan comes with several ready to use dial plan examples, including several speech enabled dial plan examples.
You can start by trying and modifying one of the samples or you can start with the example we use in this article.

Download Visual Dialplan here: Visual Dialplan download

3. LumenVox automated speech recognizer

The LumenVox automated speech recognizer is a software solution that converts spoken audio into text, providing users with a more efficient means of input. A Speech recognizer compares spoken input to a list of phrases to be recognized, called a grammar. The grammar is used to constrain the search, enabling the recognizer to return the text that represents the best match. This text is then used to drive the next steps of your speech-enabled application.

This is the last piece of the software you would need to create speech enabled dial plans.
More details about this software and download options can be found at LumenVox web site.

 

Create hello-world speech enabled dial plan

This dial plan is developed using Visual Dialplan for Asterisk and pre-configured to be used with Elastix or any other compatible Asterisk GUI (AsteriskNOW, PIAF, trixbox etc.).

The output of the Visual Dialplan is standard Asterisk extensions conf code and grammar files, automatically deployed and loaded to the Asterisk server.
However, you will still need to manually place the sound files used in this dial plan in the /var/lib/asterisk/sounds/ folder.

Contexts description

The entry point for this dial plan is the vdp-inbound or vdp-outbound context.

This dialplan will play the welcome message and ask the caller to select the sex.
Depending on the caller’s input the say block will play number one or number two (1 for mail or 2 for female).

Speech enabled dial plan

Complete ASR logic is in the ASR-select-sex context.

ASR logic

Each speech recognition action sets two variables, first is the value of the recognized word and the second is the score of the recognition (number between 1 and 100).

ASR-select-sex context plays hello-world voice file and listen to the user input. If the user input is ‘0’ i.e. user didn’t say anything, it will `play did-not-get-it` voice file and repeat the question again.

The dial plan will then check if the speech score (recognition score) is higher than “sex-treshold” value and proceed if it is and set variable “sex-value” to 1 or 2 depending on the caller input (1 in case the user said “male”, 2 in case the user said “female”), or ask the user to repeat the entry if the recognized score is below the threshold (poor recognition).

After this the context will return control to the vdp-inbound context to evaluate the GotoIf expression.

If expression returns true say block will say 1 and if false it will say 2.

ASR grammar

The ASR grammar in this dial plan is very simple – we will instruct engine to recognize just two words, “Male” and “Female”.
In case the “Male” word is recognized, the “sex” variable will be set to “1”.
In case the “Female” word is recognized, the “sex” variable will be set to”2″.

sex
#ABNF 1.0 UTF-8;
language en-US;
mode voice;
tag-format ;
root $sex;

$Male = (Male);
$Female = (Female);
$sex = $Male {$=”1″;}|$Female {$=”2″;};

 

Deployment

The output of Visual Dialplan is standard Asterisk code (extension.conf) and standard ASR grammar file.

Simply select “Dialplan” and then “Deploy” from the main many and Visual Dialplan will SSH to your remote Asterisk server, deploy the dial plan and grammar files, and reload it into the Asterisk PBX. 

You’ll be presented with a box to confirm the remote deployment. Just click yes and few seconds later a confirmation window will appear.

Make sure you validate your Asterisk dial plan before you deploy it to Asterisk server. This will make the whole process go a lot smoother.

Download hello-world speech enabled dial plan here

Leave a response »



---------------------------------------------------

Asterisk voip how to – create office dial plan

November 14, 2013

In this article we will discuss how small to mid size company may have implement its dial plan.

The dial plan will provide basic capabilities of IVR, inbound and outbound calling, voicemail, DISA and other standard PBX functionality used in small to mid size companies.

If you are interested in company IVR only, check this article: Asterisk voip how to make company IVR

For this purpose you will need the following two software products – Asterisk open source PBX and Apstel Visual Dialplan.

Asterisk PBX is free, open source PBX, while Visual Dialplan is commercial software but its trial version can be freely downloaded and comes with all major functionality that we need to create this dial plan.

1. Download and install Asterisk PBX

Asterisk PBX is available in two major distributions – as a standalone Asterisk PBX without GUI, and Asterisk PBX with a GUI.
We recommend you to use Asterisk PBX with a GUI since it is significantly easier to set it all up through the GUI comparing to manual edit of configuration files at Linux OS.

You can find several Asterisk GUIs on the market (Elastix, PIAF, AsteriskNOW etc.) but we do recommend Elastix GUI.

After you download the Elastix PBX ISO package, run it on some virtual machine and follow on screen instructions.
The ISO will install all you need – Linux OS, MySQL database, Asterisk PBX, Elastix GUI etc.

2. Download and install Visual Dialplan

Visual Dialplan is intuitive and easy to use tool for dial plan development. There is no need to know Linux or to have some Asterisk experience to use it and create complex dial plans. It also comes with several ready to use dial plan examples.

Download Visual Dialplan here: Visual Dialplan download

 

Asterisk voip how to – create office dial plan

Now that we have both software components up and running, Elastix GUI and Visual Dialplan, we can proceed and create office dial plan.

The dial plan is broken into contexts, separated parts of the dial plan where each part has its own functionality.

We will create the following contexts:

sip

This context is intended for placing the SIP outbound calls and for checking voicemail.
Outbound calls are all calls initiated from the SIP endpoint (voip phone) to other SIP endpoints or outside world.

Asterisk voip how to - SIP outbound context

The first entry component matches all the extensions (each voip phone has its own extension number) in the following format 1XX (e.g. 100, 101, 102 … 199).

Calls that land on these extensions will be forwarded to the dial-ext context, which is used to dial the SIP endpoint.

Second entry point component matches the extension *1 and invokes the voicemail main application (administrative voicemail application). The caller is sent to the administrative interface for the voice mailbox based on the caller ID number. For example, the employee on extension 101 will be sent to the administrative voicemail application for the voice mailbox 101.

The third entry point component matches all other extensions and dials that number over the DAHDI channel from group 1 (DAHDI/g1/${EXTEN}).

dial-ext

This context is used for dialing the local extensions.

Asterisk PBX - Dialing local extensions

After the call is logged for debugging purposes (Log component), appropriate Sip extension is dialed.
In case of the busy, unavailable or no answer response, the call is sent to the voice mailbox for the dialed extension.

dial-in

This context accepts all incoming calls coming through the DAHDI lines.
Basically it is simple company IVR call flow.

Visual Dialplan - incoming calls

All inbound calls (landing the S extension) are first answered and presented with a welcome message, after which the main menu is played and caller input is expected.

The caller can choose from one of the following options:
0 – A call is sent to the dial-attendant context in order to dial employee based on the caller ID number.
1 – A call is sent to the dial-employee context to allow the caller to choose the employee extension that should be dialed dial.
2 – Allow employees to check the voicemail. A call is sent to the VoicemailMain application, without parameters, meaning that the application will ask the caller for both mailbox number and password.
3 – Allow employees to dial out. The call I sent to the DISA (Direct Inward Dialing Application) application. The caller is expected to type the password 123 after which he is allowed to dial-out as if he was using the local SIP phone.

If no choice I made by the caller within the RESP_TOUT (10 seconds), the call is hanged up.
In case the caller hangs up the caller, before making any choice, a debug message I logged using the Log component.

dial-attendant

This context dials one of the employees based on the caller’s area code.

Asterisk GUI - dialing employees based on caller area code

This very simple context sets the first four digits of the caller ID number to the area_code channel variable.
The select-attendant macro is call with the area_code value in order to find appropriate employee.
The last step of this context is dialing the SIP endpoint returned as a result of the previous macro call.

dial-employee

This context enables external caller to reach an extension.

The caller is prompted to type in the three digit extension of the employee he wishes to reach. If caller types the valid extension, the call is sent to the dial-ext context, otherwise the call is terminated.

Global variables

DIAL_TOUT
Dial timeout – 20sec.

DIGIT_TOUT
Digit timeout – 3sec.

RESP_TOUT
Response timeout – 10sec.

Channel variables

attendant
Selected Sip extension for this call. This variable is set by the select-attendant macro.

area_code
This variable holds the first four digits of the caller ID number.

mailbox
Default mailbox for the SIP peer.

Macros/subroutines

select-attendant

This macro selects extension based on the first four digits of the caller ID. The associated extension is read from the database.

If no value is passed in the area_code argument, this macro will read the default extension. If the value of the area_code argument is not empty, the macro will read the associated extension for that area code.
After the value is read from the database, the macro returns the control to the calling context.

Note:
In order to function properly, sample dialplan requires that some of the resources are already configured in the Asterisk server (i.e. SIP endpoints, voice mailboxes, sound files …).

 

Deploy the dial plan

The output of Visual Dialplan is standard Asterisk code (extension.conf).
Please find below the output of the dial plan described above.

You can use this code and deploy it to your Asterisk server manually or you can use Visual Dialplan and deploy it from Visual Dialplan automatically, with a single press of a button.

Simply select “Dialplan” and then “Deploy” from the main many and Visual Dialplan will SSH to your remote Asterisk server, deploy the dial plan, and reload it into the Asterisk PBX. You’ll be presented with a box to confirm the remote deployment. Just click yes and few seconds later a confirmation window will appear.

Make sure you validate your Asterisk dial plan before you deploy it to Asterisk server. This will make the whole process go a lot smoother.

Here are the URLs for download:

Download Visual Dialplan here: Visual Dialplan download

There is no need to download dial plan used in this article since it is already provided with Visual Dialplan – just load dial plan titled “04_quick_office.vdp” (Small office dial plan example).

If you still want to do this manually, here is the code you would need to copy-paste into your extensions.conf file and then reload the dialplan at Asterisk server.


; ------------
; Generated with Visual Dialplan.

[general]
static=yes
writeprotect=no
priorityjumping=no
autofallthrough=yes
clearglobalvars=no

[globals]
; Dial timeout - 20sec.
DIAL_TOUT=20
; Digit timeout - 3sec.
DIGIT_TOUT=3
; Response timeout - 10sec.
RESP_TOUT=10

; Context for the SIP outbound calls.
[sip]

exten => _1XX,1,Goto(dial-ext,${EXTEN},1)
exten => *1,1,Set(mailbox=${CALLERID(number)})
exten => *1,n,VoicemailMain(${mailbox})
exten => *1,n,Hangup()
exten => _X.,1,Dial(Zap/g1/${EXTEN},${DIAL_TOUT},HrS(600)TWK)

; Context used for dialing the local extensions.
[dial-ext]

exten => _1XX,1,Log(DEBUG,Dialing local extension ${EXTEN})
exten => _1XX,n,Dial(SIP/${EXTEN},${DIAL_TOUT},htwk)
exten => _1XX,n,GotoIf($["${DIALSTATUS}" = "CHANUNAVAIL"]?lbl_dial-ext_1:)
exten => _1XX,n,GotoIf($["${DIALSTATUS}" = "NOANSWER"]?lbl_dial-ext_1:)
exten => _1XX,n,GotoIf($["${DIALSTATUS}" = "BUSY"]?lbl_dial-ext_1:)
exten => _1XX,n(lbl_dial-ext_0),Hangup()
exten => _1XX,n(lbl_dial-ext_1),MailboxExists(${EXTEN})
exten => _1XX,n,GotoIf($["${VMBOXEXISTSSTATUS}" = "FAILED"]?lbl_dial-ext_2:)
exten => _1XX,n,VoiceMail(${EXTEN},u)
exten => _1XX,n,GotoIf($["${VMSTATUS}" = "FAILED"]?lbl_dial-ext_3:)
exten => _1XX,n,Goto(lbl_dial-ext_0)
exten => _1XX,n(lbl_dial-ext_3),Log(ERROR,Caller ${CALLERID(all)}
failed to leave a voicemail for ${EXTEN} mailbox.)
exten => _1XX,n,Goto(lbl_dial-ext_0)
exten => _1XX,n(lbl_dial-ext_2),Hangup()

; Context for incoming external (zap) calls.
[dial-in]

exten => s,1,Answer()
exten => s,n,Playback(welcome)
exten => s,n(lbl_dial-in_0),Set(TIMEOUT(response)=10)
exten => s,n,Set(TIMEOUT(digit)=3)
exten => s,n,Background(main-menu,m)
exten => s,n,WaitExten(${RESP_TOUT})
exten => s,n,Hangup()
exten => 0,1,Goto(dial-attendant,s,1)
exten => h,1,Log(VERBOSE,Caller ${CALLERID(all)} hung up.)
exten => h,n,Hangup()
exten => 2,1,VoicemailMain()
exten => 2,n,Goto(s,lbl_dial-in_0)
exten => 1,1,Goto(dial-employee,s,1)
exten => 3,1,DISA(123,sip)

; Dial attendant.
[dial-attendant]

exten => s,1,Set(area_code=${CALLERID(number):0:4})
exten => s,n,Macro(select-attendant,${area_code})
exten => s,n,RetryDial(,5,2,SIP/${attendant},${DIAL_TOUT},A(attendant-msg)hm()twk)

; Dial employee.
[dial-employee]

exten => s,1,Set(TIMEOUT(response)=${RESP_TOUT})
exten => s,n,Set(TIMEOUT(digit)=${DIGIT_TOUT})
exten => s,n,Background(select-emp)
exten => s,n,WaitExten(${RESP_TOUT})
exten => s,n,Playback(goodbye)
exten => s,n,Hangup()
exten => _1XX,1,Goto(dial-ext,${EXTEN},1)

; This macro selects attendant based on the first four digit of the caller ID.
[macro-select-attendant]

exten => s,1,GotoIf($["${LEN(${ARG1})}" = "0"]?:lbl_macro-select-attendant_0)
exten => s,n,Set(attendant=${DB(attendant/default)})
exten => s,n(lbl_macro-select-attendant_1),MacroExit()
exten => s,n(lbl_macro-select-attendant_0),Set(attendant=${DB(attendant/${ARG1})})
exten => s,n,Goto(lbl_macro-select-attendant_1)
; ------------

Leave a response »



---------------------------------------------------

Asterisk voip how to – making company IVR

October 22, 2013

Article by Apstel LLC

IVR (Interactive Voice Response) is technology that automates interactions with telephone callers.

Enterprises are increasingly turning to IVR to reduce the cost of common sales, service, collections, inquiry and support calls to and from their company.

In this article, asterisk voip how to make company IVR, we will discuss about Asterisk and how to create IVR without prior knowledge of Asterisk nor dial plan (call flow) development.

The two pieces of software you would need are Asterisk open source PBX and Apstel Visual Dialplan.
Asterisk PBX is open source project, free to use, and Apstel Visual Dialplan is commercial software but it can be downloaded free of charge and used free of charged since the trial limit is set to some high level and the tool can be used to develop simple and moderate IVRs for free.

1. How to download and install Asterisk PBX

Asterisk PBX can be downloaded as a standalone Asterisk PBX without GUI, which we do not recommend you to use since it is designed for advanced users, or as a Asterisk PBX with GUI which is the right way to proceed.

There are several Asterisk GUIs, all free and open source, so pick one of the following: Elastix, AsteriskNOW or PBX In Flash. My personal recommendation would be Elastix. After succesful download, run it on spare PC or at some virtual machine. Each of these Asterisk GUIs is downloaded as ISO image and will require separate machine (or virtual machine) to install. Installation is simple as following on screen instructions.

2. How to download and install Apstel Visual Dialplan

Apstel Visual Dialplan is easy to use tool for dial plan (call flow) development. It is intuitive tool, you do not need to have prior dial plan experience to create IVR. In addition, it comes with several ready to use dial plan examples. One of provided examples is IVR dial plan ;).

Here is the URL to download Apstel Visual Dialplanhttp://www.apstel.com/download-visual-dialplan-professional/

 

How to start you company IVR development

Now that you have both software products installed, Asterisk PBX and Visual Dialplan, we can proceed and create the IVR.

The easiest way to start is to use the IVR example provided with Visual Dialplan. Select “File” then “Open Sample…” from Visual Dialplan menu and load 05_simple-ivr.vdp dial plan sample.

IVR application is developed using Apstel Visual Dialplan and pre-configured to be used with Elastix or any other compatible Asterisk GUI (AsteriskNOW, PBX in Flash, trixbox).

The output of the Visual Dialplan is standard Asterisk dial plan (extensions.conf file), automatically deployed and loaded to the Asterisk PBX. However, you will need to manually place the sound files in the /var/lib/asterisk/sounds/  folder so the Asterisk PBX can use it.

IVR dial plan application consists of four contexts: vdp-inbound (vdp-outbound), IVR-mainmenuCustomerSupport and SalesDepartment.

vdp-inbound/vdp-outbound context
The entry point for this dial plan is the vdp-inbound context.
This context (vdp-inbound) is the default entry point for all incoming calls to Elastix PBX, so we decided to use the default context to start our IVR dial plan.
The only purpose of this context is to accept calls coming to DID (extension) 6789 and to forward those calls to the IVR-mainmenu context.
In case you want to handle outgoing calls with the same IVR dial plan, like we decided to do in this demo, you should use vdp-outbound context with the same dial plan logic like vdp-inbound context.
In other words, if you dial 6789 from your phone registered at Elastix PBX or you dial your Elastix PBX external number and DID 6789, your call will go to IVR-mainmenu context.

Creating Asterisk PBX IVR

IVR-mainmenu context

In this context the caller hears the main IVR menu and needs to choose one of the following options:
0) Company representative,
1) Company latest news ,
2) Customer support,
3) Sales department
or three digit number to dial company extension (_XXX dial plan pattern).

If caller picks option 0, dial-plan passes the call directly to the company representative.
If caller choose option 1, dial-plan plays the latest company news.
If caller picks option 2, dial-plan passes the call to the CustomerSupport context.
If caller choose option 3, dial-plan passes the call to the SalesDepartment context.
In case the caller enters three digits number, dial plan will dial the three digits company extension and the phone on that extension will ring. If nobody answers or the line is busy, the voice mail application will be called and the caller will leave the voicemail.

In case of choosing invalid option, for example if caller enters 4, the dial plan will go back to the beginning of this context and the caller will be presented with IVR options again.

IVR Main Menu

CustomerSupport context

In this context the caller hears the support IVR menu and needs to choose one of the following IVR options:
1) Standard product user (goes to standard product users queue),
2) Professional product user (goes to professional product users queue)
3) Go back to the main IVR menu (IVR-mainmenu context)

In this case, exceptions such as timeout and invalid extension are also handled.

Asterisk voip how to make IVR for customer support

SalesDepartment context

In this context the caller is presented with the sales IVR menu and needs to choose one of the following options:
1) Individual licensing (goes to sales queue for individual users),
2) Enterprise licensing (goes to sales queue for enterprise users)
3) Go back to the main IVR menu (IVR-mainmenu context)

IVR sales menu

The above IVR will surely not match your company IVR requirements so you would need to do some changes.
After you are happy with the updates, proceed to the dial plan deployment.
In order to be used, IVR needs to be deployed to the Asterisk PBX.

 

How to deploy IVR

Before deploying the dial plan you should first check it against errors.
To validate the dial plan select Validate button. This button can be found both in the title menu, and in the icons at the top of the window.

One very convenient feature of Visual Dialplan is the ability to remotely deploy Asterisk dial plan to Asterisk server. This is good option when you want to test your dial plans quickly.

Simply select “Dialplan” and then “Deploy” from the main many and Visual Dialplan will SSH to your remote Asterisk server, deploy the dial plan, and reload it into the Asterisk PBX. You’ll be presented with a box to confirm the remote deployment. Just click yes and few seconds later a confirmation window will appear.

Make sure you validate your Asterisk dial plan before you deploy it to Asterisk server. This will make the whole process go a lot smoother.

You can verify the deployed Asterisk dial plan by editing the file at Asterisk server,  or you can simply call 6789 and enjoy the IVR ;).

1 Comment »



---------------------------------------------------