Rules for automatic recognition of recorded conversations (asrrule)

Description

A rule of thumb for applying automatic telephone conversation-to-text recognition.
Applies after the call ends at the set time.
Only works when configured in the master domain to connect to the recognition service (settings.record_asr_options).

In a single phone call, participants can belong to different domains.
The process of making a recognition decision consists of
(1) Identifying call participants and their domains and preparing search parameters.
(2) Definition of a recognition rule in the initiator domain.
(3) In the case of a cross-domain call, defining a recognition rule in the domain of the called party.
(4) Making a recognition decision based on a positive record decision in at least one of the domains.
(5) Generate an event in each of the domains configured to record and recognize.
By default, conversations are not sent for recognition.

Limitations

  • The collection is not available in the master domain.

Fields

Entity structure
{
  "id": uuid,
  "priority": int,
  "dir": str,
  "fromnumber": str,
  "tonumber": str,
  "crossdomain": str,
  "asr": intbool,
  "schedule": str,
  "periods": array<object>,
  "opts": {
    "title": str,
    "comment": str
  }
  "ext": {
    "ct": date,
    "lwt": date
  }
}
Table 1. Fields
Specification Description

Field: id
Mode: inout
Type: uuid
Default: generated

Identifier. Can be specified at creation, otherwise generated by the system.

Field: priority
Mode: in
Type: int
Default: required

Priority. A lower value means a higher priority.

Field: dir
Mode: in
Type: str
Default: `"*"`", "Filter by call direction.

Field: fromnumber
Mode: in
Type: str
Default: "*"

Call initiator number filter mask.
Filter operation modes.

Field: tonumber
Mode: in
Type: str
Default: "*"

Caller Filter Mask.
Filter operation modes.

Field: crossdomain
Mode: in
Type: str
Default: "*"

Other domain filter mask.
Applies only in the course of servicing cross-domain calls.
Filter operation modes.

Field: asr
Mode: in
Type: intbool
Default: required

Action qualifier.
1 – recognize, 0 - do not recognize.
In case a cross-domain call in both domains detects different actions, recognition is performed but does not reach the domain that refused recognition.

Field: schedule
Mode: in
Type: str
Default: "all"

Field: periods
Mode: in
Type: array<object>
Default: empty

Activity interval during the week.
Applies in mode schedule = custom.
Each item in the list covers a specific segment within the week: from time on a particular day of the week to time on another particular day of the week.
Based on the aggregate of these segments, an overall schedule is generated.
Weekly schedule list item.

Field: opts
Mode: in
Type: object
Composite field

Field: opts.title
Mode: in
Type: str
Default: empty

Arbitrary header

Field: opts.comment
Mode: in
Type: str
Default: empty

Arbitrary comment

Field: ext
Mode: inout
Type: object
Compound field

Allows you to extend the compound with arbitrary keys and values

Field: ext.ct
Mode: out
Type: date
Default: generated

Object creation time

Field: ext.lwt
Mode: out
Type: date
Default: generated

Filter options by call direction

Table 2. Filter options by call direction
Value Description

"inner"

The rule can only be applied to intra-domain calls where both parties are subscribers of the current domain

"incoming"

The rule can only be applied to cross-domain calls where the called party is a subscriber of the current domain

"outgoing"

The rule can only be applied to cross-domain calls where the initiating party is a subscriber of the current domain

"*"

The rule can be applied to all calls where at least one of the parties is a subscriber in the current domain

Filter operation modes

Table 3. Filter operation modes
Mode Description

Posymbolic

The value to be subjected to the conformance check is passed through the filter character by character.
The following special characters and combinations may be used:

  • X – any character;

  • ? – any character;

  • * – all remaining characters;

  • {F} and {f} is the entire From username value;

  • {T} and {t} is the entire To username value;

  • {E} and `{e}' is an empty value.

If it is necessary to specify one of the service characters as a target character, it should be enclosed in square brackets, e.g. [X].

For example, XX[X] is any three-character value, with X at the end.

Regex

The pattern is applied to the original value Pattern.

The structure of a regex pattern value:
/reg/Pattern1.

For example,- significance: "302"
- mask: "/reg/0"
- Result: true.

  • significance: "302"

  • mask: "/reg/^0$"

  • Result: false.

  • significance: "302"

  • mask: "/reg/^302$"

  • Result: true.

  • significance: "302"

  • mask: "/reg/^(301|302|305)$"

  • Result: true.

All standard regular expression rules can be applied when forming Pattern patterns.

Range

The value subject to compliance checking is a numeric integer and is within the specified numeric range.

The structure of the dia-template value:
/dia/FromValue+N - fall under the pattern of N+1 values from FromValue to FromValue+N.

For example,- significance: "302"
- mask: "/dia/300+10"
- Result: true.

Work schedule

Table 4. Work schedule
Value Description

"all"

The rule is available for use at all times

"disabled"

The rule is not available for use ever

"work"

The rule is available for use only during business hours

"non-work"

The rule is only available for use outside of business hours

"custom"

The rule defines the individual availability schedule in the field periods

Weekly schedule list item

Table 5. Weekly schedule list item
Field Value Description

daystart

17

Day of the week of the start of the segment (1 - Mon, 7 - Sun)

daystop

17

Day of the week of the end of the segment (1 - Mon, 7 - Sun)

timestart

01440

Intraday segment start time in minutes

timestop

01440

Intraday segment end time in minutes

See also

Logical roles

  • b2b conducts the application of recognition rules.

  • mware performs maintenance on the recognition queue.