Get Started - Asterisk PBX Users and Developers
These instructions will walk you through installing LumenVox speech recognition for Asterisk and
building a simple speech application in under an hour.
Before you install the LumenVox Speech Engine for Asterisk, you will want to make sure that
you have your Asterisk system up and running.
These instructions are written for Asterisk 1.4.13 on a Linux machine using Fedora Core 6. The
process is similar for other versions of Asterisk or Linux; our help documentation has full details
for those.
If this looks like a lot of text, don?t sweat it. There?s a lot to do ? the instructions cover
installing the software, testing it out, and running a few example programs so you can play around
with speech recognition immediately ? but if you follow the instructions, you will be done in no
time (less than an hour).
Want proof that it's really this fast?
Watch a timed video of the process, which you can use as a visual aide.
Download and Install LumenVox
5-15 Minutes
-
The easiest way to get the LumenVox speech recognition software is to set up Fedora Core to
use YUM to download and install it. First, download our GPG key from
http://www.lumenvox.com/packages/FC6/i386/RPM-GPG-KEY-LumenVox.gpg and copy it into
/etc/pki/rpm-gpg/
- Create a file called LumenVox.repo in /etc/yum.repos.d/
-
Edit that file and enter the following information:
###################################################
[LumenVox]
name=LumenVox Products for Fedora Core $releasever - $basearch
baseurl=http://www.LumenVox.com/packages/FC$releasever/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-LumenVox.gpg
###################################################
- Save and close the file.
-
From the command line, type yum install LumenVoxLicenseServer to download and
install the License Server.
-
Then type yum install LumenVoxSRE to download and install the Speech Engine.
- Once it has installed, logout of your system and log back in.
Installing a License
5-10 Minutes
-
The first thing you need to do is generate a file called Info.bts that
will save some information about your system. Go to the directory /opt/lumenvox/
licenseserver/bin/ and type ./getlvsystem_info to generate the
file (it is put in the same directory).
-
Open a Web browser and go to
http://www.lumenvox.com/customers/ and log in with your username
and password (e-mail us if you've misplaced it or didn't receive it).
-
Go to your Account Information and find your deployment (if you just have
one license it will be the only deployment you have). Click License Upload
-
In the License Upload screen, click Browse, select your Info.bts
file, and upload it.
-
Go back to your account screen and find that deployment ? the License Upload
link has turned into License Download. Click it and save the LicenseXXXX.bts
(XXXX is a 4-digit number) file to /opt/lumenvox/licenseserver/bin/
-
Go to /opt/lumenvox/licenseserver/bin/ and type ./license_mgr ?m /opt/
lumenvox/licenseserver/bin/LicenseXXXX.bts (be sure and replace XXXX with your 4-digit number).
Verify Installation
3-5 Minutes
-
First, ensure the License Server and Engine daemons are running. Type ps ?el | grep
LVSRE_SERVER to make sure that LVSRE_SERVER is running, and then do
ps ?el | grep license_server for the License Server.
-
There?s a really simple C++ application you can run to make sure the software is working. Go to
/opt/lumenvox/engine/examples/ and type make to build it
(you need gcc installed for this).
-
Once it has compiled, type ./example 127.0.0.1 to run it. You should get
back the following loop:
count=0, decode returns 10
Interpretation 1:
8587070707
- Press CTRL+C to exit the program.
Download and Install the Asterisk/LumenVox Connection
5-10 Minutes
- Go back to the customer portal at
http://www.lumenvox.com/customers/ and login.
- Click Your Software Downloads.
- Download the file labeled Asterisk 1.4 Connector.
- Extract the file by running tar ?xzvf and the name of the file you downloaded.
-
This creates a new directory, go into that directory and copy the file called
res_speech_lumenvox.so into /usr/lib/asterisk/modules/
- Copy the file called lumenvox.conf into /etc/asterisk/
-
Modify /etc/asterisk/modules.conf and make sure the line preload =>
res_speech.so is there and add the line load => res_speech_lumenvox.so
Run Your First Asterisk Speech Application
5 Minutes
-
Edit your dial plan (extensions.conf) and add the following context
[lumenvox-test]
exten => s,1,Answer
exten => s,n,Wait(1)
exten => s,n,SpeechCreate
exten => s,n,SpeechLoadGrammar(yesno|/opt/lumenvox/engine/Lang/BuiltinGrammars/ABNFBoolean.gram)
exten => s,n,SpeechActivateGrammar(yesno)
exten => s,n,SpeechBackground(beep)
exten => s,n,Verbose(1|Result was ${SPEECH_TEXT(0)})
exten => s,n,Verbose(1|Confidence was ${SPEECH_SCORE(0)})
-
Add a line into your default context to route a call to lumenvox-test,s,1
(e.g. to dial 1234 and have it go the demo application, add the line exten
=> 1234,1,Goto(lumenvox-test,s,1)
- Connect to the Asterisk console with asterisk ?vr
- Reload Asterisk by typing reload
-
Call the extension you set up (e.g. dial 1234). Say "Yes" or "No" at the beep ? the Asterisk
console will print the results ("true" for yes and "false" for no).
More Help
For a full reference on installing the LumenVox Speech Engine on an Asterisk
system, see our
Asterisk help document.
Asterisk Application Zone
One of the best ways to get started with speech development is to play around with sample
code. We have several small and open-source Asterisk speech applications in our
Asterisk Application Zone.
Asterisk Speech University
More video instructions are available to help you with your Asterisk speech application
development. A good starting point is
Asterisk Speech Development
101, the first in our Asterisk Speech University video series.
Digium References
Digium has several resources available for speech recognition users on Asterisk. To start
with, see the
documentation for the generic speech API, which is a complete reference for the speech commands
available in Asterisk.
Another helpful resource for Asterisk developers is the
Asterisk
Speech Recognition Mailing List. Subscribe to share information with other speech users,
or browse the archives to see common problems and questions.