Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
  "config": {
    "parameters": {
      "maxQueryRange": 86400000,
      "commission": 0.1,
      "tolerance": 0.1
    },
  }

If a rule processor does not use any parameters, the parameters object may either be empty (parameters{}) or omitted entirely.

The configuration object - exit conditions

A rule processor’s exit conditions ensure that a rule processor is always able to produce a result, even if the rule processor is unable to reach a definitive, deterministic outcome. Exit conditions account for non-deterministic exceptions in the rule processor’s behavior. The exit conditions are coded into the rule processor and each exit condition must be provided in the configuration for the rule processor to deliver a successful outcome. If any of the exit conditions are missing, the rule processor will still deliver a result, but it will be error outcome complaining about the missing exit condition related to the specific exit condition code.

By convention, exit condition codes are prefaced with an 'x' to differentiate them from regular rule results that have no prefix.

From a configuration perspective, the only real purpose for including the exit conditions in the configuration file is to accommodate implementation-specific and user-defined descriptions for the exit conditions, and, in a future release, accommodate multi-language support.

A rule processor may use zero or many different exit conditions. Exit conditions are arranged in an array object inside the configuration object. The exit conditions array object may be an empty placeholder if no exit conditions are defined, or omitted altogether.

Exit conditions cover a number of different exception conditions for rule processors. In principle, each distinct exit condition code relates to a specific type or class of exit condition and this principle has been generally applied to all rule processors that share common exit conditions as follows:

Code

Description

Example(s)

.x00

This condition applies to rule processors that rely on the current transaction being successful in order for the rule to produce a meaningful result. Unsuccessful transactions are often not processed to spare system resources or because the unsuccessful transaction means that the rule processor is unable to function as designed.

Unsuccessful transaction

.x01

For certain rules, a specific minimum number of historical transactions are required for the rule processor to produce an effective result. This exit condition will be reported if the minimum number of historical records cannot be retrieved in the rule processor.

Insufficient transaction history

At least 50 historical transactions are required

.x02

Currently unused.

.x03

The statistical analyses employed in some rule processors evaluate trends in behavior over a number of transactions over a period of time. While the trend itself can be categorized and reported by the regular rule results, some results are not part of an automatable scaled result. This exception provides an outcome when the historical period does not show a clear trend, but the most recent period shows an upturn.

No variance in transaction history and the volume of recent incoming transactions shows an increase

.x04

Similar to .x03, but this exception provides an outcome when the historical period does not show a clear trend, but the most recent period shows an downturn.

No variance in transaction history and the volume of recent incoming transactions is less than or equal to the historical average

Example:

Code Block
  "config": {
    "exitConditions": [
      {
        "subRuleRef": ".x00",
        "outcome": false,
        "reason": "Unsuccessful transaction"
      },
      {
        "subRuleRef": ".x01",
        "outcome": false,
        "reason": "Insufficient transaction history"
      }
    ]
Info

The .err exit condition

All rule processors are encoded with an error condition outcome that accounts for exceptions that do not fall into the category of the exit conditions above, or the rule results below. These conditions are effectively an error that occurred during the execution of the rule processor, such as, for example, if the database is inaccessible or if some expected data dependency had not been met due to an error during data ingestion or transformation.

These error conditions are too numerous and diverse to explicitly define and is not required for the rule configuration anyway. The error conditions are handled exclusively in the rule code; however the error condition outcome will still be produced as a rule result to ensure continuity and end-to-end robustness in the platform. A rule processor will, if an error occurs, deliver a very unique .err rule result with a specific reason description that describes the error. In rare instances, where an error condition was not anticipated during development, the reason might be a generic Unhandled rule result outcome message.

The configuration object - rule results

While the parameters and exit conditions may be optional for a specific rule processor, the core function and output of a rule processor is contained in the results object. Rule processors offer two different kinds of rule results:

Banded results, where the result from the rule processor is categorized into one out of a number of discrete bands that partition a contiguous range of possible results.

...

Cased results, where the result from the rule processor is an explicit value from a list of discrete and explicit values.

...

The rule processor’s core purpose is to produce a definitive deterministic result based on its programmed behavioral analysis of historical data. The rule configuration defines the bands or values for which rule results can be provided.

Rule results - banded results

Rule results - cased results

3. Version Management

3.1. Introduction and Basics

...