A process rule is a general rule that guides a process. It is a special concept in atfinity, since it lives on its own.
A process rule always results in one of these outcomes:
Issue / Warning
Specify a condition under which you want atfinity to create something - and specify what you want to have created when the condition is met in a dedicated 'creation' field.
Assign a specified value, if it does not already exist.
Rules attached to processes raise issues or result in creations or assignments.
Rules attached to a document make sure the document is required in a case when conditions for it are met.
When naming a process rule, it is most effective to pick a name that says what the rule is for. Examples:
'Two account holders required for joint account'
'Applicant for entity account must be of low risk class'
'Individual account is not available for people from risk countries'
Using RuLa, describe when the process rule should be triggered, resulting in a raised issue or a warning.
The summary of the rule in English.
Describe why the situation in question is problematic and causes the raised issue or warning. If there is anything the user can do to correct the situation, suggest it here. The provided description should be in English.
Example of a condition for the process rule 'Account holder cannot have a domicile in a risk country', with outcome Issue or Warning:
p is Person, AccountHolderp.domicile not in RiskCountries
Line 2 in this example shows how a process rule works by bringing an ontology and a piece of information together. The
p refers to the ontology Person, as defined on line 1.
Then, in line 2, what follows after the period sign
. is the piece of information on that ontology you want the process to look at, in this example the domicile of the person.
A second example of a process rule that results in a warning, this time whenever a politically active person wants to open an account:
p is Personp.politically_active = true
Example of a condition for the Process Rule 'Two account holders required for joint account':
c is Contractc.account_type = joint_account
Under 'Creation', you would then write:
ensure 2 AccountHolder
If we look at this example: somewhere in the case the information field
account_type exists. The process rule looks at that field and evaluates whether or not the value that was input there is
If you would like to make sure that these account holders are not just of the role
AccountHolder, but also the ontology
Person, you can specify this in addition:
ensure 2 Person, AccountHolder
The number of instances to create doesn't have to be an integer. It can also be any RuLa expression. Instead of an integer, a calculation is also a valid number here:
ensure 1 + 1 Person, AccountHolder
It is also valid to reference any matches of the condition and use their information. Here, we use the match
c is Contract from our condition above:
ensure c.number_of_account_holders Person
Using RuLa, describe when the process rule should be triggered, resulting in the assignment of a value.
Describe what value should be assigned.
If you want to assign the value for a person's tax country to be whatever value is given as that person's domicile, first, in the condition field, write:
p is Person
Then, in the assignments field, follow that by:
p.tax_country := p.domicile
A process rule ensuring that, whenever a client indicates email is the preferred channel of communication, e-banking is offered as an additional service:
p is Personp.communication_channel = emailp.recommended_services = ebanking
A step-by-step guide on how to write process rules can be found here.
Process rules make atfinity dynamic.They interact with:
Process: process rules need to be added to a process, in order to be used and evaluated.