Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Decision models provides a common notation that is readily understandable by all business users, from the business analysts needing to create initial decision requirements and then more detailed decision models, to the technical developers responsible for automating the decisions in processes, and finally, to the business people who will manage and monitor those decisions. Emakin decision model based on DMN standard is published by Object Management Group.

A decision is the act of determining an output value, from a number of input values, using logic defining how the output is determined from the inputs. This decision logic may include one or more business knowledge models which encapsulate business know-how in the form of business rules, analytic models, or other formalisms. Authorities also may be defined for decisions or business knowledge models, which might be (for example) domain experts responsible for defining or maintaining them, or source documents from which business knowledge models are derived, or sets of test cases with which the decisions must be consistent. These are called knowledge sources.

Decision Model

This basic structures can modeled as following graphical language;

Decision inputs may be input data, or the outputs of other decisions. If the inputs of a decision Decision1 include the output of another decision Decision2, Decision1 “requires” Decision2. Decisions may therefore be connected in a network called a decision model graph.

A simple example of decision model with only two decisions is shown below;

In this example "Decision2" requires the "Input Data2" input, similarly "Decision1" is requires "Input Data 1" and requires "Decision 2" therefore "Input Data 2" also is required.

Model Notation

NotationElementDescription


Decision
A decision denotes the act of determining an output from a number of inputs, using decision logic which may reference one or more business knowledge models.

Business Knowledge Model

A business knowledge model denotes a function encapsulating business knowledge, e.g., as business rules, a decision table, or an analytic model.

Input Data

An input data element denotes information used as an input by one or more decisions. When enclosed within a knowledge model, it denotes the parameters to the knowledge model.

Knowledge Source

A knowledge source denotes an authority for a business knowledge model or decision.

Decision Model Constructs

Input Data

Input data specifies the an requirement for other elements. Has following properties;

Name
Name of textual description of input data.

Variable Name
Name of input to be referred in other elements.

Variable Type
Optional type of input. (i.e. string, number, date, any..)

Allowed Values
Expression of acceptable range of input data. Which is can be enumeration of strings ("A","B","C") or number range (1...50) If input is not in allowed range InputNotAllowed exception is thrown.

Decision

Decision logic currently only supported as decision table expression to construct outputs by input data. Please refer the decision table for more details. Decision element has following properties;

Name
Name of textual description of decision.

Business Knowledge Model

Business knowledge models are mathematical formulations to apply referenced documents. BKM functions written in FEEL syntax and a example PMT (calculates the payment for a loan) function can be defined as BKM function.

(amount * rate / 12) / (1 – (1 + rate / 12) ** -term)

Business knowledge model has following properties;

Name
Name of textual description of decision.

Variable Name
Name of result to be referred in other elements.

Variable Type
Optional type of result.

Feel

For decision logic modeling it provides a language called FEEL for defining and assembling decision tables, calculations, if/then/else logic, simple data structures. Please see the FEEL reference for more details.

Decision Table

Decision table is a logical expression for decision elements in model. Please refer to Decision Table for more details.

Executing Decisions

Decisions can be called as a "decision service" from scripting environment and also can be called from emakin rest service

Scripting Environment

To call a decision from scripting calling convention is;

var result = $Decisions.<DecisionName>( inputData );

DecisionName donates the name of decision in graph.

InputData can be a javascript object or xml data. Also combining xml data and JSON objects is supported.

Please note If decision is has one output expression result is direct value of resulting output. If decision has more than one output expression, result is always an javascript object and output expressions are property of resulting object.

Javascript Object Example 

var result = $Decisions.MyDecision({
  Product : 'Candy',
  Units : 30
});

Xml Data Example

var result = $Decisions.MyDecision( $Xml.SelectSingle('Order' );

Please refer to scripting reference for more details and examples.

Rest Service

Please refer to the rest service documentation for more details.

A Example Decision Model

Dish decision table

Beverages decision table




  • No labels