Task 2: Ensuring completeness
A decision logic must determine a value for its decision node in every possible case. When expressed as rules, ensuring complete coverage is challenging because each rule applies to specific cases only. A complete decision logic requires at least one applicable rule for every scenario.
- Defining a default value that is applied when no rules match.
- Generating missing rules through logical analysis.
Default values
In Decision Designer, default values are specified by using default rules. Default rules have no conditions and are applied when no business rules or decision tables are applicable. Their action sets the value of the decision node to a predefined fallback value.
A decision logic can have only one default rule.
Take the following decision table:

The following default rule specifies APS-C as the fallback value:
set decision to APS-C ;
While default rules satisfy the completeness requirement, they have a significant drawback: all uncovered cases receive the same decision value. It prevents differentiation between distinct missing cases.
For example, if you remove the fifth row (portrait photography with low budget) from the previous decision table, it creates two families of missing cases:
- Beginners in sports or portrait photography with high budgets
- Photographers in portrait photography with low budgets
If APS-C suits the first case but Micro Four Thirds is needed
for the second, a single default value is insufficient. The decision logic requires refinement
through missing rules.
Missing rules
Finding missing rules manually is difficult, even for small rule sets. Decision Designer provides automated computation through logical rule analysis.
To conduct the completeness analysis and generate missing rules for a decision node, click
Analyze the decision logic
in the Logic tab.
For the decision table with two missing cases, three missing rules are generated:
- Invalid budget range
-
if budget is less than 0 then -- This is a generated rule. Choose a meaningful value for the decision variable. set decision to APS-C ;This rule can be ignored as budgets cannot be negative.
- Portrait photography with low budget
-
if subject is not sports and subject is not landscape and budget is less than 500 then -- This is a generated rule. Choose a meaningful value for the decision variable. set decision to APS-C ;This rule describes the second case that is listed before. While the generated rule contains a meaningful condition, its action is a placeholder. Decision Designer automatically inserts the default value for the type of the decision node. In this case, it is
APS-C. A comment prompts the rule author to replace this placeholder with an appropriate value.As discussed before,
Micro Four Thirdsshould be used for this missing rule.APS-Ccan be replaced withMicro Four Thirds. Then, the comment can be removed and the rule can be approved to be added to the decision logic. - High budget nonlandscape cases
-
if subject is not landscape and level is not professional and budget is at least 1500 then -- This is a generated rule. Choose a meaningful value for the decision variable. set decision to APS-C ;This rule describes a case that the default rule can cover. Approving it is optional.
There is a benefit to using business rules rather than default rules. Business rules provide explicit conditions, while default rules have implicit conditions, namely that no other rules applied. Explicit conditions improve decision explanations by clearly showing which conditions triggered the rule. For transparent decision-making, prefer approving missing rules even when the default produces the same result.
Exercise 1: Defining a default value
- Import the Step4 solution for Decision Modeling practice tutorial sample from the New decision service wizard. For more information about importing samples, see Building decision services.
- Open the Step 4 - Exercise 2 decision model.
- Create a new decision table named DT with overlaps in the sensor format node.
- Populate the table with values from the Decision table with a missing case (Fig. 1) available above.
- Go to the Run tab.
- Create a test data set with the following values:
- level: beginner
- subject: portrait
- budget: 3000
- Click Run. Is a sensor format proposed?
- Return to the Logic tab.
- Click Create rule artifact
and select Default rule.
- Enter the following
rule:
set decision to APS-C - Return to the Run tab and run the test data set again. Is the same sensor format returned?
- Expand the sensor format section in the run history. Which rule determined the value?
Exercise 2: Generating missing rules
- Create a new decision table named DT with two missing cases in the sensor format node.
- Populate the table with values from the Decision table with a missing case (Fig. 1) available above, except row 5.
- Go to the Run tab.
- Create a test data set with the following values:
- level: professional
- subject: portrait
- budget: 400
- Click Run and note the proposed sensor format.
- Return to the Logic view and click Analyze the decision
logic
to generate missing rules.
- Modify the second missing rule by replacing
APS-CwithMicro Four Thirds. Then, approve the rule. - Return to the Run tab and run the test data set again. Is the same sensor format returned?
- Expand the sensor format section in the run history. Which rule determined the value?
Lessons learned
A decision logic based on an overlap-free rule set with a default value has the following characteristics:
- Each rule independently makes decisions for all applicable cases.
- At most, one rule applies in any given case.
- The default value handles cases where no rules apply.
Missing rules can be generated when a single default value cannot adequately cover all missing cases.
Limitations
Some decision-making problems involve infeasible cases where no decision is possible. In these scenarios, default values can incorrectly provide decisions for invalid cases. Also, generating missing rules may not be meaningful as no valid decision can be determined for infeasible cases.
The next task extends decision logic requirements to accommodate intentional incompleteness.