[Asterisk-Users] Sphinx2

Mojo with Horan & Company, LLC mojo at horanappraisals.com
Wed Apr 26 14:48:16 MST 2006


Ya, we do, but it's ugly.   If you'd care to follow along here's what I did:

I set up sphinx2 like at 
http://turnkey-solution.com/asterisk-sphinx.html including the 
sphinx-netserver.pl and sphinx-netclient.pl, but didn't worry about 
their perl snippet at the end. I followed their suggestions regarding 
replacing the default hmm/6k acoustic model.

To make the dictionary, I made a list of people we want included in a 
text file, for example:
PIZZA EXPRESS
SUBWAY
MCDONALDS

and went to the dictionary-creating link referenced in the howto: 
http://www.speech.cs.cmu.edu/tools/lmtool.html -- uploaded my new text 
file and got back a dictionary file to install as per the howto.  Note 
the instructions regarding modifying sphinx-netserver.pl to use the 
dictionary you just made.  Also note that sphinx-netserver.pl and 
sphinx-netclient.pl have some line-wrap problems and won't run as copied 
from their page without backspacing some lines back together.  For 
example, in sphinx-netserver.pl were two lines that read:

$MAX_CLIENTS_PER_CHILD = 50; #number of clients each child
should process

and the "should process" was part of the prior line's comment and needed 
to be brought up there or deleted entirely.

I then created a file I called number_map that consists of two 
tab-separated columns.  The fist column contains exactly the same data 
as the dictionary file you made earlier, and the second column contains 
the number to dial:
PIZZA EXPRESS<tab>9664638<enter>
SUBWAY<tab>7477827<enter>
etc...

number_map goes in the agi-bin directory along with voice_dir.php, my 
php agi interface to the whole deal.  voice_dir.php refers to sounds 
"hcllc-voicedir-sayname" -- this contains "Please say the name of the 
person you wish to call" and "hcllc-voicedir-name-unconfigured" which 
contains something like "That name is unconfigured at present".

at http://horanappraisals.com/asterisk/voice_dir you'll find number_map 
and voice_dir.php to be both placed into your agi directory.

hope this helps!  Sorry it's so kludgey, there's only a few people in 
our office, so we can be fairly confident everyone knows how to use it 
safely.

Moj



Ronald Wiplinger wrote:
> I have a gateway, which I call from my mobile phone (free of charge, 
> since it is the same phone company).
> This gateway gives me a dial tone. I can than dial to any extension 
> number or even other gateways, ....
> 
> It is getting more a trouble to remember all the numbers, or to key in 
> all the long phone numbers when you got the dialtone.
> 
> I was thinking of using for this Sphinx2. How can I implement that? I 
> should dial to a "sphinx2" extension number, what could be 111 and than 
> I say the name of the user I want to call to.
> 
> Example:
> 1. dialing the gateway
> 2. waiting for the dialtone
> 3. key in 111
> 4. waiting for the prompt
> 5. say the users name:  "Peter"
> 6. call Peter's number:    2345678
> 
> Has anybody done something like that (partially) before?
> 
> 
> bye
> 
> Ronald Wiplinger
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
> 
> Asterisk-Users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
> 

-- 
Mojo <mojo at horanappraisals.com>
Office Manger, Horan & Company, LLC
(907) 747-6666 x112



More information about the asterisk-users mailing list