Upload
ashwani-sharma
View
36
Download
2
Embed Size (px)
Citation preview
‘ APDRP-UP’Product Information( APDRP-UP-Grammar Design )
Prepared by: Karthik .R
Date: 6th May 2011 Version: 1.0
DISTRIBUTION LIST
Recipient LocationRole (Review / Sign-off)
Aman Soi HCL Sign Off
Suresh Menon HCL Sign Off
Nishanth AGC Networks Review
Prashant Rai AGC Networks Review
AMENDMENT HISTORY
Issue No. Date Background Information
v1.0 29/04/2011 First draft
REFERENCES
Ref. Document Version Issued Author
1 Prompts.xlsx
2 IVR Revised_CCC_IVR_workflow architecture by Ajay Singh.vsd
P a g e | 2
CONTENTS
1. FUNDAMENTALS...............................................................................................................................................41.1 INTRODUCTION...........................................................................................................................................................................41.2 WHAT IS A GRAMMAR?..............................................................................................................................................................41.3 DOCUMENT PURPOSE.................................................................................................................................................................41.4 TARGET PLATFORMS..................................................................................................................................................................51.5 SEMANTIC INTERPRETATION......................................................................................................................................................51.6 GRAMMAR DELIVERY................................................................................................................................................................51.7 VERSION CONTROLS...................................................................................................................................................................51.8 GRAMMAR FORMAT AND STANDARDS.......................................................................................................................................61.9 GRAMMAR INVOCATION.............................................................................................................................................................71.10 PRE-TUNED SETTINGS................................................................................................................................................................81.11 USE OF REGULAR EXPRESSION..................................................................................................................................................81.12 DOCUMENTATION CROSS-REFERENCING...................................................................................................................................81.13 GRAMMAR NAMING CONVENTION.............................................................................................................................................81.14 LANGUAGE.................................................................................................................................................................................9
2. DIALOGUE SPECIFIC STATIC GRAMMAR SPECIFICATION...................................................................102.1 INTRODUCTION.........................................................................................................................................................................102.2 WELCOME_NU (SPEECH).........................................................................................................................................................102.3 WELCOME (DTMF)..................................................................................................................................................................102.4 LANGUAGE_NU (SPEECH).......................................................................................................................................................112.5 LANGUAGE (DTMF)................................................................................................................................................................112.6 MAINMENU_NU (SPEECH)......................................................................................................................................................122.7 MAINMENU (DTMF)...............................................................................................................................................................122.8 CUSTID1_NU (SPEECH)...........................................................................................................................................................132.9 CUSTID1 (DTMF)....................................................................................................................................................................142.10 CUSTID2_NU (SPEECH)...........................................................................................................................................................142.11 CUSTID2 (DTMF)....................................................................................................................................................................142.12 KNO_NU (SPEECH).................................................................................................................................................................152.13 KNO (DTMF)..........................................................................................................................................................................152.14 KNOCONFIRMATION2_NU (SPEECH)......................................................................................................................................162.15 KNOCONFIRMATION2 (DTMF)...............................................................................................................................................162.16 BILLINFO1_NU (SPEECH)........................................................................................................................................................172.17 BILLINFO1 (DTMF).................................................................................................................................................................172.18 BILLINFO2 (DTMF).................................................................................................................................................................182.19 FAX_EMAIL_DEMAND _NU (SPEECH)....................................................................................................................................182.20 FAX_EMAIL_DEMAND (DTMF)...............................................................................................................................................192.21 MAINMENURETURN_NU (SPEECH).........................................................................................................................................192.22 MAINMENURETURN (DTMF)..................................................................................................................................................20
P a g e | 3
1.1. FFUNDAMENTALSUNDAMENTALS
1.1 Introduction
This document provides the detailed design for the speech recognition and DTMF grammars that will be utilised by
APDRP-UP IP IVR application designed by the HCL.
1.2 What is a grammar?
As an IVR call progresses callers are asked to provide responses to specific questions, the application will dictate if
responses can be spoken, provided as Touch Tone™ or either. A grammar is the entity (a text file) that describes
the gamut of responses that are valid for a given question, for example, in response to a confirmation the grammar
may specify “yes” and “no” as acceptable spoken responses or “1” and “2” as acceptable DTMF inputs, any other
response (spoken or DTMF) would be an out-of-grammar response and handled accordingly by the IVR
application. The grammar returns one of three responses to the application:
an in-grammar result with a confidence score, the caller input was considered to match a grammar entry,
where an N-Best list length greater than one is specified the grammar could return multiple hypothesis in
descending order of confidence
a no-match which occurs when the caller has provided some input but the input could not be matched against
a grammar entry
a no-input which occurs when no caller input was detected
1.3 Document Purpose
The purpose of this document is to describe the name and scope of each grammar including common grammars
(such as yes/no) that are utilised by call flow specific grammars. It describes parameters specific to grammars such
as confidence thresholds, N-Best list lengths and the Semantic Interpretation of utterances. This document should
be read in conjunction with both the Prompt Script and the IVR Application design.
P a g e | 4
1.4 Target Platforms
This design assumes that the speech recogniser will be the Nuance Recognizer version 9.0. The target voice
browser is assumed to be the Cisco IP IVR with a VoiceXML 2.0 compliant browser. Integration with ASR is
assumed to be using the Media Resource Control Protocol (MRCP) version 1.0.
1.5 Semantic Interpretation
Semantic Interpretation describes the return value from the grammar back to the application, for example a
confirmation grammar that supports “Yes” and also the synonym “Correct” will only return “YES” regardless of
the caller utterance. This becomes more important with more complex grammars.
The grammar will be responsible for all semantic interpretation, the application will not utilise the VoiceXML
shadow variable $.utterance for interpretation purposes.
The grammar will always return the primary interpretation in $.value with any additional fields required to support
the IVR application being returned in grammar specific variables.
The grammar will utilise the XML <tag> XXX</tag> form to ensure data returned does not create badly formed XML.
1.6 Grammar Delivery
Only one type of grammars will be used by the IVR application, static content grammar. All grammars will be
served to the Cisco IP IVR using standard requests. Static grammars will be served using non-encrypted
connections as their content will not contain any customer specific data. Only the Directed dialog format of
grammar will be supplied as per the Prompt provided.
1.7 Version Controls
1.7.1 Development
Version control of grammar and associated files will be managed using standard source code control techniques
throughout grammar development activity.
P a g e | 5
1.7.2 Runtime
In order to allow maximum flexibility during a rollout and also to support the modular nature of the IVR
application (different components or elements of the application may be delivered or modified independently of
other components that collectively form the overall application) the grammars can be installed under different
server paths. For example, the path for DTMF grammar
/grammars/static/DTMF/
This approach will allow the segregation of grammar files for different languages (or sub-releases if necessary with
deeper path structures)
1.7.3 Version Numbers
All grammar files will contain the document version number in a <meta> tag with an attribute named “version” and an
“X.Y” format numeric version number, for example:
<meta name=”version” content=”0.1” />
1.8 Grammar Format and Standards
All grammar files will utilise the XML form of the W3C Speech Recognition Grammar Specification1 (SRGS)
standard. Grammars will be designed and implemented to re-use as much as possible, for example where the Call
flow Design implements a confirmation that extends the typical responses of yes/no to include one or more phrases
specific to the question being asked, the grammar invoked by the application will contain a reference to the global
yes/no grammar and extend with entries specific to the dialogue state. Grammar files will be standard 8 bit ASCII
text files.
All grammar files will contain the following header:
<?xml version="1.0" encoding ="iso-8859-1"?>
<!DOCTYPE grammar PUBLIC "-//W3C//DTD GRAMMAR 1.0//EN"
"http://www.w3.org/TR/speech-grammar/grammar.dtd">
<grammar version="1.0" xmlns="http://www.w3.org/2001/06/grammar"
1 See http://www.w3.org/TR/speech-grammar/
P a g e | 6
xml:lang="en-IN" root="main_rule">
(or)
<grammar version="1.0" xmlns="http://www.w3.org/2001/06/grammar"
xml:lang="hi-IN" root="main_rule">
The root rule will be named as per the grammar file heading in all cases, this will ensure compatibility with existing
grammar files from other projects.
In addition to the version number (see above) all grammar files will contain two <meta> tags with an attributes named
“author” and an “maintainer” for example:
<meta name=”author” content=”Karthik.R” />
<meta name=”maintainer” content=”[email protected]” />
All grammar files will contain the following copyright statement:
<!--
Copyright (c) 2008 AGC Networks Ltd, All Rights Reserved.
This code is confidential to AGC Networks Ltd and shall not be
disclosed outside without the prior written permission of the VP of Application Delivery.
In the event that such disclosure is permitted the code shall not be
copied or distributed other than on a need-to-know basis and any
recipients may be required to sign a confidentiality undertaking in favour of AGC Networks Ltd.
-->
1.9 Grammar Invocation
All grammars will be invoked with the “mode” attribute set in the VoiceXML payload, regardless of the grammar
type.
P a g e | 7
When invoking a voice grammar the <grammar> tag will contain at a minimum:
<grammar src=“URI” mode=“voice” />
When invoking a DTMF grammar the <grammar> tag will contain at a minimum:
<grammar src=“URI” mode=“dtmf” />
Explicitly setting the grammar mode will ensure that default voice browser settings do not need to be assumed, this
is important given the quantity and distribution of CISCO IP IVR systems that are required to support the business.
1.10 Pre-tuned Settings
Various recognition parameters cannot be fully configured until calls have been received from callers not involved
in the project delivery (and therefore not influenced by prior knowledge of how to behave etc.) that can be analysed
to determine grammar performance against real-world caller behaviour and environmental conditions.
This requires that pre-tuned settings are specified for recogniser confidence threshold settings and N Best list
lengths. This document therefore describes settings that are based on a combination of designer experience and
real-world analysis.
It is expected that these values will change as the project develops and during regular ongoing tuning cycles.
“Sensitivity” suitable for the telephony environment, the value should initially be set to 0.2 and modified if required.
1.11 Use of Regular Expression
Where a grammar can return one or more values from a very large list (i.e. an 8 digit account number), a regular
expression will be used to describe the gamut of possible interpretations. Regular expressions are provided in
addition to a full written description.
1.12 Documentation Cross-Referencing
This document cannot be read in isolation, it is intrinsically linked to both the IVR Application Prompt documents
(see References above).
P a g e | 8
1.13 Grammar Naming Convention
The grammar file names will follow the convention:
XXXXXX.grxml if it is a DTMF application
XXXXXX_NU.grxml in case of a Voice grammar
where XXXXXX is the Prompt name reference, NU refers the Voice respectively, for example
“Fax_Email_Demand_NU” (white space is not permitted in the filename). The file suffix will be grxml in all cases.
1.14 Language
Unless explicitly stated, all grammars will be written for Indian English & Hindi speakers.
P a g e | 9
2.2. DDIALOGUEIALOGUE SPECIFICSPECIFIC S STATICTATIC G GRAMMARRAMMAR S SPECIFICATIONPECIFICATION
2.1 Introduction
This section describes the static grammars that are aligned with individual dialogue stated within the application.
These grammars typically reference the global grammars and extend them where necessary in support of the Call
flow and Prompt scripts.
The grammar filenames cross reference the Prompt Script file.
2.2 Welcome_NU (Speech)
Grammar Name: Welcome_NU.grxml voice
Description: A grammar to handle a response to the “Welcome to Paschimanchal Vidyut Vitran Nigam Ltd. say "HINDI" for continuing in Hindi else say "ENGLISH" question
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
option “English”, “Hindi”
Public Rules
main_rule Language selection option
Sample Expressions main_rule
English Option = “English”
Hindi Option = “Hindi”
2.3 Welcome (DTMF)
Grammar Name: Welcome.grxml dtmf
Description: A grammar to handle response to the “Welcome to Paschimanchal Vidyut Vitran Nigam Ltd.Press"1" for continuing in Hindi else press"2" for English” question
P a g e | 10
Grammar Name: Welcome.grxml dtmf
Caching: Permitted
Semantic Interpretation
Option “English”, “Hindi”
Public Rules
main_rule Respond to a prompt such as “Press"1" for continuing in Hindi else press"2" for English.”
Sample Expressions main_rule
1 Option = “English”
2 Option = “Hindi”
2.4 Language_NU (Speech)
Grammar Name: Language_NU.grxml voice
Description: A grammar to handle Yes/No responses
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “Change”, “Continue”
Public Rules
main_rule Respond to a prompt such as “Your preferred language is X. Do you want to change it in Y. say 'Yes' to change else say 'NO' to continue”
Sample Expressions main_rule
Yes Option “Change”
No Option = “Continue”
2.5 Language (DTMF)
Grammar Name: Language.grxml dtmf
Description: A grammar to handle Yes/No responses
P a g e | 11
Grammar Name: Language.grxml dtmf
Caching: Permitted
Semantic Interpretation
Option “Change”, “Continue”
Public Rules
main_rule Respond to a prompt such as “Your preferred language is X. Do you want to change it. Press "1" to change it in Y else press 0 to continue.”
Sample Expressions main_rule
1 Option = “Change”
0 Option = “Continue”
P a g e | 12
2.6 MainMenu_NU (Speech)
Grammar Name: MainMenu_NU.grxml voice
Description: A grammar to allow the caller to say their preferred menu option to traverse through the menu
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “ NoSupply”, “ AttributeChange” , “NewConnection” ,”BillMeter”
Public Rules
main_rule Respond to a prompt such as “Press "1" or say 'One' for No Supply, Press "2" or say "2" for Attribute Change, Press "3" or say "3" for New Connection. Press "4" or say "4" for Meter related complaint and Bill related info or complaint.”
Sample Expressions main_rule
New Connection Option = “NoSupply”
Bill/Meter Option = “AttributeChanges”
AttributeChanges
Option = “NewConnection”
NoSupply Option = “BillMeter”
2.7 MainMenu (DTMF)
Grammar Name: MainMenu.grxml dtmf
Description: A grammar to allow the caller to select their preferred menu option to traverse through the menu
Caching: Permitted
Semantic Interpretation
option “ NoSupply”, “ AttributeChange” , “NewConnection” ,”BillMeter”
Public Rules
main_rule Respond to a prompt such as “Press "1" for No Supply, Press "2" for Attribute
P a g e | 13
Grammar Name: MainMenu.grxml dtmf
Change, Press "3" for New Connection, Press "4" for Meter related complaint and Bill related info or complaint.”
Sample Expressions main_rule
1 Option = “NoSupply”
2 Option = “AttributeChanges”
3 Option = “NewConnection”
4 Option = “BillMeter”
2.8 CustID1_NU (Speech)
Grammar Name: CustID1_NU.grxml voice
Description: A grammar to allow the caller to say Yes to confirm or say No to reject the played out Customer ID
Caching: Permitted
Settings
Confidence: 0.5
N-Best 1
Semantic Interpretation
option “One”, “Two”
Public Rules
main_rule Respond to a prompt such as “Press "1" or say "Yes" if you have Customer ID else press"2" or say "NO"
Sample Expressions main_rule
Yes option = “One”
No option = “Two”
P a g e | 14
2.9 CustID1 (DTMF)
Grammar Name: CustID1.grxml dtmf
Description: A grammar to allow the caller to select 1 to confirm or press 2 to reject the played out Customer ID
Caching: Permitted
Semantic Interpretation
option “One”, “Two”
Public Rules
main_rule Respond to a prompt such as “Press "1" if you have Customer ID else press"2"
Sample Expressions main_rule
1 option = “One”
2 option = “Two”
P a g e | 15
2.10 CustID2_NU (Speech)
Grammar Name: CustID2_NU.grxml voice
Description: A grammar to capture an account number for caller Identification
Caching: Permitted
Settings
Confidence: 0.3
N-Best 1
Semantic Interpretation
Option \d{8}
Public Rules
main_rule Respond to a prompt such as “Enter your Customer ID printed on Left side of your electricity bill”
Sample Expressions main_rule
one two three four five six seven eight option = “12345678”
2.11 CustID2 (DTMF)
Grammar Name: CustID2.grxml dtmf
Description: A grammar to capture an account number for caller Identification
Caching: Permitted
Semantic Interpretation
option \d{8}
Public Rules
main_rule Respond to a prompt such as “Enter your Customer ID printed on Left side of your electricity bill”
Sample Expressions main_rule
12345678 option = “12345678”
P a g e | 16
2.12 KNO_NU (Speech)
Grammar Name: KNO_NU.grxml voice
Description: A grammar to capture an account number for caller Identification
Caching: Permitted
Settings
Confidence: 0.4
N-Best 1
Semantic Interpretation
Option \d{8}
Public Rules
main_rule Respond to a prompt such as “Enter your KNO or Customer ID printed on Left side of your electricity bill”
Sample Expressions main_rule
one two three four five six seven eight Option = “12345678”
2.13 KNO (DTMF)
Grammar Name: KNO.grxml dtmf
Description: A grammar to capture an account number for caller Identification
Caching: Permitted
Semantic Interpretation
Option \d{8}
Public Rules
main_rule Respond to a prompt such as “Enter your KNO or Customer ID printed on Left side of your electricity bill”
Sample Expressions main_rule
12345678 Option = “12345678”
P a g e | 17
2.14 KNOconfirmation2_NU (Speech)
Grammar Name: KNOconfirmation2_NU.grxml Voice
Description: A grammar to handle Yes/No responses in a response to the caller KNO number
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “YES”, “NO”
Public Rules
main_rule Respond to a prompt such as “To confirm Say "Yes" or say "NO”
Sample Expressions main_rule
Yes Option = “YES”
No Option = “NO”
2.15 KNOconfirmation2 (DTMF)
Grammar Name: KNOconfirmation2.grxml dtmf
Description: A grammar to handle Yes/No responses in a response to the caller KNO number
Caching: Permitted
Semantic Interpretation
Option “YES”, “NO”
Public Rules
main_rule Respond to a prompt such as “Please press 1, otherwise press 2.”
Sample Expressions main_rule
1 Option = “YES”
2 Option = “NO”
P a g e | 18
2.16 Billinfo1_NU (Speech)
Grammar Name: Billinfo1_NU.grxml voice
Description: A grammar to handle responses from the caller the response may be bill related information or the bill related complaint
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “Bill_Information”, “Bill_Complaint”
Public Rules
main_rule Respond to a prompt such as “Press"1" for Bill Related info and "2" for Bill related complaints”
Sample Expressions main_rule
Bill information Option = “Bill_Information”
Bill Complaint Option = “Bill_Complaint”
2.17 Billinfo1 (DTMF)
Grammar Name: KNOconfirmation2.grxml dtmf
Description: A grammar to handle responses from the caller the response may be Press 1 for bill related information or Press 2 for bill related complaint
Caching: Permitted
Semantic Interpretation
Option “Bill_Information”, “Bill_Complaint”
Public Rules
main_rule Respond to a prompt such as “Please press 1, otherwise press 2.”
Sample Expressions main_rule
1 Option = “Bill_Information”
2 Option = “Bill_Complaint”
P a g e | 19
2.18 Billinfo2 (DTMF)
Grammar Name: Billinfo2.grxml dtmf
Description: A grammar to capture a single digit number for number of month which can be max 6 for customer bill information
Caching: Permitted
Semantic Interpretation
Option \d{1}
Public Rules
main_rule Respond to a prompt such as “You can enter max. 6 months .Please Enter no. of months for which bill is required.”
Sample Expressions main_rule
1 Option = “1”
2.19 Fax_Email_Demand _NU (Speech)
Grammar Name: Fax_Email_Demand _NU.grxml voice
Description: A grammar to handle responses from the caller ,the response may be bill on fax, bill on Email or Exit
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “Fax”, “Email”,” Exit”
Public Rules
main_rule Respond to a prompt such as “Say 1 for receiving bill on Fax.Say 2 for receiving bill on Email. Say 3 for exit out the menu.”
Sample Expressions main_rule
Bill on Fax/one Option = “Fax”
Bill on Email/two Option = “Email”
Exit/three Option = “Exit”
P a g e | 20
2.20 Fax_Email_Demand (DTMF)
Grammar Name: Fax_Email_Demand .grxml dtmf
Description: A grammar to handle responses from the caller ,the response may be press 1 for bill on fax, press 2 for bill on Email or press 3 for Exit
Caching: Permitted
Semantic Interpretation
Option “Fax”, “Email”,” Exit”
Public Rules
main_rule Respond to a prompt such as “Press "1" for receiving bill on fax. "2" for receiving Bill on Email. Press"3" for exit out the menu.”
Sample Expressions main_rule
1 Option = “Fax”
2 Option = “Email”
3 Option = “Exit”
2.21 MainMenureturn_NU (Speech)
Grammar Name: MainMenureturn _NU.grxml voice
Description: A grammar to handle responses from the caller, Say 9 to return to the main menu.
Caching: Permitted
Settings
Confidence: 0.6
N-Best 1
Semantic Interpretation
Option “MainMenu”
Public Rules
main_rule Respond to a prompt such as “Say 1 for receiving bill on Fax.Say 2 for receiving bill on Email. Say 3 for exit out the menu.”
Sample Expressions main_rule
MainMenu/nine Option = “MainMenu”
P a g e | 21
2.22 MainMenureturn (DTMF)
Grammar Name: MainMenureturn.grxml dtmf
Description: A grammar to handle responses from the caller , Press 9 to return to the main menu.
Caching: Permitted
Semantic Interpretation
Option “MainMenu”
Public Rules
main_rule Respond to a prompt such as “Press "1" for receiving bill on fax. "2" for receiving Bill on Email. Press"3" for exit out the menu.”
Sample Expressions main_rule
9 Option = “MainMenu”
P a g e | 22