1 # this test describes operation of voicetags and texttags 2 # 3 # to run this script please be sure to prepare the input grammars 4 # 5 # grxmlcompile -par baseline11k.par -grxml bothtags5.grxml 6 # make_g2g -base bothtags5,addWords=100 -out bothtags5.g2g 7 # grxmlcompile -par baseline11k.par -grxml enroll.grxml 8 # make_g2g -base enroll -out enroll.g2g 9 # 10 # now from the srec/config/en.us directory run the script with the following command line: 11 # 12 # /system/bin/SRecTest -parfile baseline11k.par -tcp tcp/bothtags5.tcp -datapath audio/ >out_SHIP_bothtags5.txt 2>&1 13 # 14 # VOICETAGS PREPARATION 15 # let's load up the voice-enrollment "grammar" and refer to it as "ve" later 16 # ROOT is the name of the rule we activate in that grammar, no other rule should work anyways 17 context_load grammars/bothtags5.g2g BothTags trash not_ve 18 context_load grammars/enroll.g2g VoiceEnroll ROOT ve 19 ##context_load grammars/bothtags5,addWords=100 BothTags trash not_ve 20 ##context_load grammars/enroll VoiceEnroll ROOT ve 21 # 22 # VOICETAGS 23 # the pattern for voicetags is : 24 # (1) the we loadup the voice-enrollment grammar 25 # (2) the user utters the training token for the "voicetag" (sometimes loosely called nametag) 26 # (3) the voicetag "recognition result" from that training token is then added to a list of tags (for saving to disk)n 27 # (4) the voicetag is also added to the primary recognition grammar 28 context_use VoiceEnroll 29 recognize_nist v139/v139_024.nwv 0 0 VCE_Pete_Gonzalez 30 context_free VoiceEnroll 31 context_use BothTags 32 addword_from_last_nametag @Names VCE_Pete_Gonzalez 0 33 context_free BothTags 34 context_use VoiceEnroll 35 recognize_nist v139/v139_254.nwv 0 0 VCE_Andrew_Evans 36 context_free VoiceEnroll 37 context_use BothTags 38 addword_from_last_nametag @Names VCE_Andrew_Evans 0 39 context_free BothTags 40 context_use VoiceEnroll 41 recognize_nist v139/v139_127.nwv 0 0 VCE_Peter_Wilson 42 context_free VoiceEnroll 43 context_use BothTags 44 addword_from_last_nametag @Names VCE_Peter_Wilson 0 45 context_free BothTags 46 context_use VoiceEnroll 47 recognize_nist v139/v139_107.nwv 0 0 VCE_Edgar_Young 48 context_free VoiceEnroll 49 context_use BothTags 50 addword_from_last_nametag @Names VCE_Edgar_Young 0 51 context_free BothTags 52 context_use VoiceEnroll 53 recognize_nist v139/v139_248.nwv 0 0 VCE_John_Martinez 54 context_free VoiceEnroll 55 context_use BothTags 56 addword_from_last_nametag @Names VCE_John_Martinez 0 57 # 58 # TEXTTAGS 59 # The pattern for texttags is that we just add the texttag 60 # since pronunciation guessing is not always available we're specifying 61 # the pronunciation to be used for this text tag. 62 # If NULL appears in the transcription field (immediately after the name) 63 # then the phonetic transcription will be requested from the G2P 64 # (Grapheme-to-Phoneme) module at runtime. 65 # 66 addword @Names Jen_Parker NULL 0 V='Jen_Parker' 67 addword @Names Jennifer_Hernandez NULL 0 V='Jennifer_Hernandez' 68 addword @Names Barb_Baker NULL 0 V='Barb_Baker' 69 addword @Names Elaine NULL 0 V='Elaine' 70 addword @Names David NULL 0 V='David' 71 # 72 # RECOGNITION 73 # prepare the recognition context for recognition 74 context_compile 75 # 76 # ACTUAL RECOGNITION UTTERANCES 77 # 78 # These utterance test that we're able to recognize the voicetags 79 recognize_nist v139/v139_077.nwv 0 0 phone delete VCE_Pete_Gonzalez 80 recognize_nist v139/v139_040.nwv 0 0 phone delete VCE_Peter_Wilson 81 recognize_nist v139/v139_021.nwv 0 0 phone delete VCE_Edgar_Young 82 recognize_nist v139/v139_206.nwv 0 0 phone delete VCE_Andrew_Evans 83 recognize_nist v139/v139_103.nwv 0 0 phone delete VCE_John_Martinez 84 # 85 # CMD: context_reset 86 # These utterances test that we're able to recognize the texttags 87 recognize_nist v139/v139_113.nwv 0 0 phone delete Jen_Parker 88 recognize_nist v139/v139_067.nwv 0 0 phone delete Jennifer_Hernandez 89 recognize_nist v139/v139_202.nwv 0 0 phone delete Barb_Baker 90 recognize_nist v139/v139_007.nwv 0 0 phone delete Elaine 91 recognize_nist v139/v139_189.nwv 0 0 phone delete David 92 # 93 # 94 acousticstate_reset 95 recognize_nist m252/m252a12e.nwv 0 0 forward 96 recognize_nist m252/m252a22e.nwv 0 0 traffic 97 recognize_nist m252/m252a10e.nwv 0 0 changer 98 recognize_nist m252/m252a3fe.nwv 0 0 cd player 99 recognize_nist m252/m252a11e.nwv 0 0 traffic information 100 recognize_nist m252/m252a21e.nwv 0 0 traffic memory 101 recognize_nist m252/m252a24e.nwv 0 0 fahrenheit 102 context_free BothTags 103 context_unload VoiceEnroll 104 context_unload BothTags 105