Circumstance Rules
Circumstancing establishes a baseline for expected Case behavior and adds variants to address exceptions to the behavior. The goal of circumstancing is to create a variant for each anticipated situation. Pega selects the appropriate variant, or circumstance, to use based on the details of the Case.
When you circumstance a Rule, you create a set of focused Rules to address exceptions to Case processing, rather than one all-encompassing Rule. Since each Rule focuses on a specific exception, application maintenance and updates are easier and can be delegated to business users. Reusing the Rules you create at the application or enterprise level is also easier.
Circumstance a Rule
To circumstance a Rule, you create a base Rule to define the expected behavior. Pega uses the base Rule unless a circumstanced version is more appropriate.
Consider a company with different response time obligations for elite and non-elite customers. The response time for non-elite customers is the expected behavior. In this situation, the response-time goal is 24 hours. You create a base Rule — in this case, a Service-Level Agreement — to enforce the response time goal for non-elite customers. Then you identify any exceptions to the expected behavior. In the center of the following image, slide the vertical line to see the response time for elite customers compared to non-elite customers:
For each exception, you circumstance the base Rule to address the difference from the expected behavior. For example, elite customers with silver status have a response time goal of 12 hours. You circumstance the base Rule to enforce the response time goal for customers with silver status. You can then create another circumstance to address the goal time for customers with gold status, who have a Service-Level response goal of six hours.
Types of circumstancing Conditions
You can circumstance a Rule according to the value of one or more Conditions. You define a Condition based on one variable, multiple variables, date property, and as-of-date, then apply the Condition to a variant of the Rule. When using the Rule, the application evaluates the Conditions defined on all the circumstanced variants. If one of the circumstancing Conditions is satisfied, the application uses the corresponding Rule variant. Otherwise, the application uses the base Rule.
In the following table, you can learn more about the types of circumstancing conditions:
Circumstance type | Description |
---|---|
Single variant | The Rule variant is effective whenever the value of a single property satisfies the circumstancing Condition. You specify the property and the comparison value. If the property matches the specified value, the application applies the circumstanced variant. |
Multi-variant |
The Rule variant is effective when a combination of property values satisfies the condition. This involves a circumstance template and definition. Apply the template and definition to the Rule variant. If the case matches a combination in the definition, the application uses the circumstanced variant. |
Date property |
The date property Rule variant is effective whenever the value of a date property satisfies the circumstancing Condition. This Condition can be either a single date or a range of dates. |
As-of date | The as-of date Rule variant uses the current system date and is effective after a certain date, or during a range of dates. |
Examples of circumstancing Conditions
Each variant of a Rule applies one type of circumstancing Condition, though you can combine Conditions to circumstance a Rule.
The following video provides examples of each type of circumstancing Condition:
Video transcript
In Pega, you circumstance a variant of a Rule using one of four types of circumstance Conditions.
You use a single value circumstance to create a Rule variant that is effective whenever the value of a single property satisfies the circumstancing Condition. For example, many companies offer a quicker response on complaints or inquiries for customers with premium or elite status. In this situation, you circumstance a Service-Level Rule based upon the value of the property that records the customer status. If the value is silver for a Case, the application uses the circumstanced variant for customers with silver status, rather than the base Rule.
You use a multiple value circumstance to create a Rule variant that is effective whenever a combination of property values satisfies the circumstancing Condition. For example, a bank waives account fees for customers who maintain an account balance of 10000 euros. But for customers in Germany, the account balance must exceed 25000 euros. In this situation, you use a circumstance template to define the properties on which to circumstance the Rule. You then use a circumstance definition to specify the minimum balance and country for the exception — 25000 euros for customers in Germany.
You circumstance on a date property to create a Rule variant that is effective whenever the value of a specified date property satisfies the circumstancing Condition. For example, companies often update a Process in response to business conditions, but must process existing Cases under the previous version of the Process. A Process goes into effect on January 1 to reflect a more rigorous review of loan applications. But Cases created before this date are to be completed using the old Process. In this situation, you circumstance the updated Process based upon the value of the pxCreateDate property — the date a Case was created. If the value of pxCreateDate is a date after January 1, the application uses the updated Process instead of the original Process.
You circumstance a Rule using an as-of date to create a Rule that is effective after a certain date, or during a range of dates. For example, during December, a retailer offers free shipping on any order over $50. During the rest of the year, only orders over $100 receive free shipping. In this situation, you apply a date range to the Rule that calculates the shipping charge. If a customer places an order in December, then the application applies the $50 threshold for free shipping. If the customer places an order in any other month, the application applies the $100 threshold instead.
Check your knowledge with the following interaction:
This Topic is available in the following Module:
Want to help us improve this content?