Audium Knowledge Base

Knowledgebase Home | Contact Knowledgebase Home | Contact
Search the Knowledgebase Jump to ID Browse by Category
How can I tell which mode (voice/DTMF) was used by the caller?
Categories: Audium Studio (3.4.x)
Article ID: 139
Last updated: February 28, 2006
User Opinions
No users have voted.

How would you rate this answer?
Helpful
Not helpful
SUMMARY

This article explains how to, at runtime, determine whether an input from the caller was entered via voice or DTMF.

SYMPTOMS

Developer is creating an Audium application where it is necessary to know the caller's input method at runtime.

RESOLUTION

A Form element should be used when the application will need to make a decision at runtime based on the caller's input method.  Form elements store the input mode that the caller used in element data named "nbestInputmode1" (or "nbestInputmodeX", where X is the index of the n-best utterance you are interested in).

To branch the callflow based on the input mode, you can write a Java class for a Decision element that examines the form element's "nBestInputMode1" variable, to see if it is set to "dtmf" or "voice".  An even simpler approach would be to write an XML decision that checks this element data to determine which input mode was used by the caller.
Visitor Comments
  1. Comment #1 (Posted by AudiumVance)
    You may wish to determine the inputmode when a max nomatch exit state is followed from a Form element. This functionality is beyond the scope of the built-in Form element, but you could create a custom voice element that does this. Please see the VoiceXML output of the Form element (in particular, the "filled" block) for an example of how to capture the standard application variables, one of which is "inputmode". This "script" portion of the "filled" block assembles the completeNBestStr, which includes the inputmode information. If you were to create your own custom voice element, you may not need all of this functionality; the key point here is that the inputmode can be found via the application.lastresult$[i].inputmode standard application variable. For more information about standard application variables, please refer to section 5.1.5 of the VoiceXML 2.0 specification. In order to capture the inputmode during a maxnomatch, the value of this variable would need to be passed back to Audium Call Services via a submit in the final nomatch catch block.
     
Related Questions
Attachments
No attachments were found.

Copyright (c) 2005 Audium Corporation. All rights reserved.
Audium Home | Audium Support Center Home | Audium Customer Care Home