[SRILM User List] help with keyword spotting

Andreas Stolcke stolcke at icsi.berkeley.edu
Thu Jun 14 09:21:37 PDT 2012


The lattice-tool -write-ngram-index option was created for keyword (and 
keyphrase) spotting, but would typically be used with word-based 
lattices.  However, you could write a phone ngram index (using fairly 
high -order value) and then do approximate matching of your 
pronunciation against this index.    The output format is described in 
the man page.

In your case you might do better writing out a phone confusion network 
(lattice-tool -write-mesh) and then match against that.

Either way, you won't find a complete ready-made solution.  You have to 
postprocess the lattice-tool output using an appropriate matching function.

Andreas

On 6/14/2012 2:55 AM, NEETI SONTH wrote:
> Andreas
> I want to do keyword-spotting in srilm. I have a lattice-file in 
> htk-format generated from a single sentence utterance. The 
> lattice-file is phonetic lattice. Now I want to search/spot a word in 
> the lattice-file. I have the phonetic decomposition of the word I am 
> spotting for. Can you brief me with the necessary steps and srilm 
> commands for the same?
> I tried using *lattice-tool  -read-htk -in-lattice <filename1> -ppl 
> <sentence.file>* .
>
> *sentence.file *just contains the keyword I am spotting for. But what 
> I observed from one of your other user-mails, that *-ppl* only works 
> when the phonetic decomposition of the keyword exactly matches with 
> that of a path in the lattice. However, it is highly improbable that : 
> when I speak, the lattice file generated has a phonetic path which 
> exactly matches with the phonetic decomposition of the keyword.
> How then would we spot a keyword?
> I also want to know how *" -write-ngram-index" option *helps in 
> keyword spotting?
> Please help.
> thanks
>
> with regards,
> Neeti Sonth
>
>
> On Wed, Jun 13, 2012 at 11:33 AM, Andreas Stolcke 
> <stolcke at icsi.berkeley.edu <mailto:stolcke at icsi.berkeley.edu>> wrote:
>
>     On 6/9/2012 3:46 AM, NEETI SONTH wrote:
>>
>>
>>>             Hi.
>>
>>     When I run the command 'lattice-tool -max-time 4 -write-ngrams
>>     <filename> -in-lattice-list <filename2>'
>>        the command limits the maximum time of operation for just the
>>     first lattice file in the list of lattice files. For remaining
>>     lattice-files, it doesnt limit the time of operation. The command
>>     says "LIMITS THE MAXIMUM TIME OF OPERATION PER LATTICE" ... So
>>     why isnt it doing so???
>>
>>     thanks.
>>     Neeti Sonth
>>
>
>     It seems that in Linux and compatible systems, unlike in Solaris,
>     where the code was originally developed, the SIGALRM handler needs
>     to use sigsetjmp/siglongjmp()  instead of just plain
>     setjmp/longjmp, or else subsequent alarms won't invoke the handler
>     due to signal mask modification. The effect was that lattice-tool
>     -timeout would work only for the first lattice triggering the
>     timeout on Linux and Cygwin systems.
>
>     The attached patch should fix the problem.
>
>     Andreas
>
>
>
>


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.speech.sri.com/pipermail/srilm-user/attachments/20120614/43778317/attachment.html>


More information about the SRILM-User mailing list