Jump to: navigation, search

Classification Interface

This interface provides the ability to classify and screen interaction content to help the orchestration logic determine what the customer wants.

Object Model

category

This object represents the result for an interaction classified against a given category. The name of the object will be "category". This object is accessible either through the classification.screen.done  or the classification.classify.done events and the categories property with those events. Another way is via the interaction object's categories property. This is the set of properties for the object:

Name

Access

Type

Default Value

Valid Values

Description

name

read only

string

none

 

This is the name of the screen rule.

id

read only

string

none

 

This is screen rule ID from UCS.

relevancy

read only

integer

none

1-100

This indicates the relevancy of the category with respect to the interaction that was classified.

screenrule

This object represents the result for an interaction screened against a given screen rule. The name of the object will be "screenrule". This object is accessible through the classification.screen.done event and the screenrule property of that event. This is the set of properties for the object:

Name

Access

Type

Default Value

Valid Values

Description

name

read only

string

none

 

This is the name of the screen rule

id

read only

string

none

 

This is screen rule ID from UCS.

match

read only

boolean

none

true, false

This indicates whether the interaction has met the conditions of the screen rule.

value

read only

string

none

 

This is the interaction content that has met the screen rules.

Action Elements

<classify>

This action takes the content of an interaction and classifies it into categories. This action is equivalent to the IRD function block "Classify".

Attribute Details

Name

Required

Type

Default Value

Valid Values

Description

requestid

false

location expression

none

Any valid location expression

This is the location for the request ID that is returned as part of this request. Any data model expression evaluating to a data model location. See SCXML Location Expressions for details. The location's value will be set to an internally generated unique string identifier to be associated with the action being sent. If this attribute is not specified, the event identifier is dropped. This identifier can be tested by the completion event handler to distinguish among several outstanding requests. If this attribute is not specified, the identifier can be acquired from the action completion event. Every request must receive a unique identifier.

server

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the name of the classification server to be used for classifying the content of this interaction. If not supplied, the functional module will use the first available server. See SCXML Legal Data Values and Value Expressions for details.

interactionid

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the _genesys.ixn.interactions[x].g_uid of the interaction that is to be classified. There is a special value that can be returned:

  • ECMAScript Null means the functional module will not use an interaction for the request.

SCXML Legal Data Values and Value Expressions for details.

root

true

value expression

none

Any value expression that returns a valid string

A value expression which returns the overall classification category that should be used for this action. SCXML Legal Data Values and Value Expressions for details.

confidence

false

value expression

75

Any value expression that returns a valid integer between 1 and 100

A value expression which returns the minimum relevancy each classification category must have in order for Classification Server to consider an interaction as belonging to that category. See SCXML Legal Data Values and Value Expressions for details.

fromudata

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the udata key name to use as the classified data source. If this attribute and the fromvar attribute are not supplied, then the data source will be Universal Contact Server's database. See SCXML Legal Data Values and Value Expressions

fromvar

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the ECMAScript variable name to be used as the classified data source. If this attribute and the fromudata attribute are not supplied then the data source will be Universal Contact Server's database. See SCXML Legal Data Values and Value Expressions for details.

allcategories

false

boolean expression

true

Any expression which returns a boolean (true, false)

A boolean expression which indicates whether or not all categories are to be used for this action. This attribute is mutually exclusive with the categories and subcategories attributes. See SCXML Conditional Expressions for details.

categories

false

value expression

none

Any expression that results in a valid string

A value expression which returns a set of comma-separated category names (ids) that is to be used to classify this interaction. For example, categories="'productx, update'" This attribute is mutually exclusive with the allcategories attribute. See SCXML Legal Data Values and Value Expressions for details.

subcategories

false

NMTOKEN

no

no, direct, all

This identifies how the Classification Server should handle parent and child categories when classifying the interaction:

  • no - The Classification Server considers only the categories you selected in the tree and does not include any child categories.
  • direct - The Classification Server considers only the direct children of the selected (parent) categories.
  • all - The Classification Server considers all children of the selected (parent) categories.

This attribute is mutually exclusive with the allcategories attribute.

attach

false

boolean

true

true and false

This indicates whether the classification results should be attached to the interaction as udata properties.

The following is an example:

<state id="do_classification">
    <datamodel>
	<data id="reqid"/>
    </datamodel>
    <onentry>
	<classification:classify requestid="_data.reqid" root="businessxcats"/>
    </onentry>
    <transition event="classification.classify.done" target="statex"/>
    <transition event="error.classification.classify" target="statey"/>
</state>
Children

None

Events

The following events can be generated as part of this action:

  • classification.classify.done - This event is sent when the request has been accepted by the system and the interaction has been classified.
  • error.classification.classify - This event is sent when the request has failed for some reason.

<screen>

This action takes the content of an interaction and screens it using a set of rules. This action is equivalent to the IRD function blocks "Screen" and "Multiscreen".

Attribute Details

Name

Required

Type

Default Value

Valid Values

Description

requestid

false

location expression

none

Any valid location expression

This is the location for the request ID that is returned as part of this request. Any data model expression evaluating to a data model location. See SCXML Location Expressions for details. The location's value will be set to an internally generated unique string identifier to be associated with the action being sent. If this attribute is not specified, the event identifier is dropped. This identifier can be tested by the completion event handler to distinguish among several outstanding requests. If this attribute is not specified, the identifier can be acquired from the action completion event. Every request must receive a unique identifier.

server

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the name of the classification server to be used for screening this interaction. If not supplied, the functional module will use the first available server. See SCXML Legal Data Values and Value Expressions for details.

interactionid

false

value expression

"0"

Any value expression that returns a valid string

A value expression which returns the _genesys.FMname.interactions[x].g_uid of the interaction that is to be screened. There is a special value that can be returned:

  • "0" means the functional module will use _genesys.FMname.interactions[0].g_uid as the related interaction.

SCXML Legal Data Values and Value Expressions for details.

language

false

value expression

English (US)

Any expression that returns a string with one of the following values: English (US), Spanish, Mandarin, Cantonese, Vietnamese, French, French (Canada), German, Italian, Japanese, Korean, Russian

A value expression which returns a string specifying a language in which screening should be done. See SCXML Legal Data Values and Value Expressions for details.

fromudata

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the udata key name to use as the screened data source. If this attribute and the fromvar attribute are not supplied, then the data source will be Universal Contact Server's database. See SCXML Legal Data Values and Value Expressions

fromvar

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the ECMAScript variable name to be used as the screened data source. If this attribute and the fromudata attribute are not supplied, then the data source will be Universal Contact Server's database. See SCXML Legal Data Values and Value Expressions for details.

allrules

false

boolean expression

true

Any expression which returns a boolean (true, false)

A boolean expression which returns whether or not all rules are to be used for this action. This attribute is mutually exclusive with the rules attribute. See SCXML Conditional Expressions for details.

rules

false

value expression

none

Any expression that results in a valid string

A value expression which returns a set of comma-separated rule names (ids) that is to be used to screen this interaction. For example, rules="'rule1, rulen'" This attribute is mutually exclusive with the allrules attributes. See SCXML Legal Data Values and Value Expressions for details.

results

false

NMTOKEN

rules

rules, matchpairs, categories, all

This identifies what results the Classification Server should return after the interaction has been screened:

  • rules - Returns screening rule IDs when a match is found.
  • matchpairs - Returns the matched pairs of screening rule IDs and specific strings of words in the interaction content that matched the screening rules.
  • categories - Returns the classification categories associated with the screening rules.
  • all - Returns screening rule IDs, key-value pairs, and categories

root

false

value expression

none

Any value expression that returns a valid string

A value expression which returns the overall screening category which should be used for this action. This is attribute is mandatory when the results attribute is either "categories" or "all". SCXML Legal Data Values and Value Expressions for details.

The following is an example:

<state id="do_screening">
    <datamodel>
	<data id="reqid"/>
	<data id="rulesetA" expr="Rule1, Rule2, Rule3"/>
    </datamodel>
    <onentry>
	<classification:screen requestid="_data.reqid" rules="_data.rulesetA"
	results="all" />
    </onentry>
    <transition event="classification.screen.done" target="statex"/>
    <transition event="error.classification.screen" target="statey"/>
</state>
Children

None

Events

The following events can be generated as part of this action:

  • classification.screen.done - This event is sent when the request has been accepted by the system and the interaction has been screened.
  • error.classification.screen - This event is sent when the request has failed for some reason.

Events

Event

Attributes

Description

classification.classify.done

 

This event indicates the success of the request and that the interaction has been classified.

requestid

This is the ID associated with the request.

categories

This is an array of category objects which have met the criteria associated with this request and the interaction. The array is ordered from highest relevancy to lowest.

error.classification.classify

 

This indicates that an abnormal condition occurred while trying to perform the request. This event will be sent as a result of a timeout of the request as well as due to problems with the request or the interaction itself.

requestid

This is the ID associated with the request.

error

This is the type of error that occurred:

  • Request Invalid

description

This is a more detailed description of the error.

classification.screen.done

 

This event indicates the success of the request and that the interaction has been screened.

requestid

This is the ID associated with the request.

screenrule

This is an object which contains properties of screening rule what has met the criteria associated with this request and the interaction as well as collection of matched keys.

categories

This is an array of category objects which have met the criteria associated with this request and the interaction. The array is ordered from highest relevancy to lowest.

error.classification.screen

 

This indicates that an abnormal condition occurred while trying to perform the request. This event will be sent as a result of a timeout of the request as well as due to problems with the request or interaction itself.

requestid

This is the ID associated with the request.

error

This is the type of error that occurred:

  • Request Invalid

description

This is a more detailed description of the error.

This page was last edited on September 13, 2017, at 12:03.
Comments or questions about this documentation? Contact us for support!