John Squared
New Member
- Joined
- Jan 25, 2016
- Messages
- 8
- Reaction score
- 0
Hello,
I have a question regarding the Asterisk speech recognition that uses the Google API. How would I go about having the following dialplan work without requiring that # be pressed after the user says the number they want to dial? I see some vague references to this, but I am unsure how to go about implementing it. Been going crazy trying to figure this out, any help will be greatly appreciated.
Here's my dialplan:
[custom-voicedial]
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,agi(googletts.agi,"Please say one, plus the number you want to dial, followed by the pound sign",en)
exten => s,n(record),agi(speech-recog.agi,en-US)
exten => s,n,GotoIf($["${confidence}" > "0.8"]?success:retry)
exten => s,n(success),Goto(dial)
exten => s,n(retry),agi(googletts.agi,"Can you please repeat?",en)
exten => s,n,Goto(dial)
exten => s,n(dial),Noop(= Script returned: ${status} , ${id} , ${confidence} , ${utterance} =)$
exten => s,n,Set(NUM2CALL=${utterance})
exten => s,n,agi(googletts.agi,"${utterance}")
exten => s,n,Dial(SIP/flowrouteLA/"${NUM2CALL}")
exten => s,n,Hangup
Thanks!
I have a question regarding the Asterisk speech recognition that uses the Google API. How would I go about having the following dialplan work without requiring that # be pressed after the user says the number they want to dial? I see some vague references to this, but I am unsure how to go about implementing it. Been going crazy trying to figure this out, any help will be greatly appreciated.
Here's my dialplan:
[custom-voicedial]
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,agi(googletts.agi,"Please say one, plus the number you want to dial, followed by the pound sign",en)
exten => s,n(record),agi(speech-recog.agi,en-US)
exten => s,n,GotoIf($["${confidence}" > "0.8"]?success:retry)
exten => s,n(success),Goto(dial)
exten => s,n(retry),agi(googletts.agi,"Can you please repeat?",en)
exten => s,n,Goto(dial)
exten => s,n(dial),Noop(= Script returned: ${status} , ${id} , ${confidence} , ${utterance} =)$
exten => s,n,Set(NUM2CALL=${utterance})
exten => s,n,agi(googletts.agi,"${utterance}")
exten => s,n,Dial(SIP/flowrouteLA/"${NUM2CALL}")
exten => s,n,Hangup
Thanks!