Practical Techniques for Resolving Conflicts among Business Rules



Similar documents
Representing and Solving Rule-Based Decision Models with Constraint Solvers

Using Decision Tables

OPENRULES. User Manual. Open Source Business Decision Management System. Release 6.3.3

Simplifying the Development of Rules Using Domain Specific Languages in DROOLS

Worldwide Business Rules Management Systems 2011 Vendor Shares

Integration of an open source rule engine to enhance the IHTSDO Workbench testing

Prescriptive Analytics. A business guide

The Mental Health Care Patient Management System (Mentcare)

Investment, Time, and Present Value

Tool-kit: Your Ticketing Systems Powered by KT Resolve SM

A methodology for graphical modeling of business rules

Chapter 7. Sealed-bid Auctions

Korean Language Evening Class Syllabus

Project Management Methodologies By Jason Charvat, published by Wiley, NJ, 2003 (A book review by R. Max Wideman)

Types of Savings Plans and Investments

The Challenge of Implementing Interoperable Electronic Medical Records

SAP InfiniteInsight Explorer Analytical Data Management v7.0

CRM Compared. CSI s Guide to Comparing On-Premise and On-Demand. Tim Agersea Managing Director, Customer Systems Scottsdale, AZ

Inside Track Research Note. In association with. Enterprise Storage Architectures. Is it only about scale up or scale out?

Investing on hope? Small Cap and Growth Investing!

Second CRM CRM Solution for Small Companies

MODULE 3 THE NEXT BIG THING

OPENRULES. Getting Started. Open Source Business Decision Management System. Release OpenRules, Inc.

2 Day In House Demand Planning & Forecasting Training Outline

Increasing marketing campaign profitability with predictive analytics

Assessing the Appropriate Level of Project, Program, and PMO Structure

Progress Corticon BRMS

A Rules Engine Experiment: Lessons Learned on When and How to use a Rules-Based Solution

CIVITAS SOLUTIONS, INC. INSIDER TRADING POLICY September 17, Adoption of Insider Trading Policy. Background

A Comprehensive Approach to Master Data Management Testing

SECTION ONE PURPOSE, SCOPE, LEGAL BASIS AND DEFINITIONS

Table of Contents. Testimonials from the MDM Alliance Group... Introduction to MDM...

What Is Probability?

A Generic business rules validation system for ORACLE Applications

Open Source Business Rules Management System Enables Active Decisions

Use Case Diagrams. Tutorial

Organise Your Business

Open source business rules management system

Construction Project Management Software UserView. Lessons from real software users

Data Warehouse. Project Process. Project Documentation. Revised Aril, 2013

JBoss Enterprise MIDDLEWARE

Introducing Python as a main Programming Language

The Enterprise Project Management Office

RAMP Marketing Automation Checklist

Call Center First Call Resolution Guide. Sponsored by

Clinical Decision Support Systems An Open Source Perspective

A HISTORICAL PERSPECTIVE ON THE TELECOMMUNICATION SERVICES INDUSTRY: LESSONS LEARNED WHITE PAPER

Speech Analytics. Whitepaper

MEETING THE OREGON STATE STANDARDS FINANCIAL AVENUE CORE CONCEPT EARNING SPENDING SAVING BORROWING PROTECT

Published April Executive Summary

Feathered, But Not Ready for Takeoff

A hybrid approach for solving real-world nurse rostering problems

Analysis of the Specifics for a Business Rules Engine Based Projects

CDC UNIFIED PROCESS PRACTICES GUIDE

>

Differential privacy in health care analytics and medical research An interactive tutorial

The CPA Way 4 - Analyze Major Issues

Achieving ITSM Excellence Through Availability Management

Solving (NP-Hard) Scheduling Problems with ovirt & OptaPlanner. Jason Brooks Red Hat Open Source & Standards SCALE13x, Feb 2015

Cisco Change Management: Best Practices White Paper

Three Asset Lifecycle Management Fundamentals for Optimizing Cloud and Hybrid Environments

Credit Card Pros and Cons

STUDENT CAN HAVE ONE LETTER SIZE FORMULA SHEET PREPARED BY STUDENT HIM/HERSELF. FINANCIAL CALCULATOR/TI-83 OR THEIR EQUIVALENCES ARE ALLOWED.

Data Quality Assessment. Approach

Looking back on how desktop support has evolved, it s interesting to see how tools

Modeling Guidelines Manual

Effective Business Requirements (Virtual Classroom Edition)

An Oracle White Paper June, Strategies for Scalable, Smarter Monitoring using Oracle Enterprise Manager Cloud Control 12c

Assuring Safety in an Air Traffic Control System with Defeasible Logic Programming

Network Configuration Management

Physical Database Design Process. Physical Database Design Process. Major Inputs to Physical Database. Components of Physical Database Design

CHAPTER 11: THE EFFICIENT MARKET HYPOTHESIS

About Troika Software, Inc.

Technology Delivery Co Ordinator

Rules and Business Rules

CS101 Lecture 19: Internetworking. What You ll Learn Today

Q&A. HP Service Anywhere Simplifying ITSM. Questions Asked by Webinar Attendee on December 12, 2012

ITIL A guide to incident management

Transcription:

Practical Techniques for Resolving Conflicts among Business Rules Presenter: Dr. Jacob Feldman OpenRules Inc., CTO jacobfeldman@openrules.com www.openrules.com 2014 OpenRules, Inc.

Motivation Contradictory business rules occur in normal business situations, and maintaining rules with exceptions is a very typical example of rule conflicts In real-world of complex decision modeling, business analysts frequently face issues related to diagnostic and resolution of business rule conflicts To avoid conflicts, business analysts have to add more and more rules making their maintenance a real problem 2014 OpenRules, Inc. 2

Questions What are the commonly used techniques for resolving rule conflicts? Is it possible to automatically resolve rule conflicts? We will discuss how traditional and modern BRMS systems address these questions 2014 OpenRules, Inc. 3

Example of Rules with Conflicts Rule 1: Birds can fly Rule 2: Chicken cannot fly Rule 3: Scared chicken can fly Even little children can apply these rules in many practical situations How will a BRMS represent these rules? 2014 OpenRules, Inc. 4

Example of Rules with Conflicts within a BRMS Decision table that avoids rule conflicts by considering ALL if-then combinations in a mutually exclusive way: Rule 1: Birds can fly Rule 2: Chicken cannot fly Rule 3: Scared chicken can fly 2014 OpenRules, Inc. 5

All possible If-Then-Else Combinations Become a Challenge Rule 1: Birds can fly Rule 2: Chicken cannot fly Rule 3: Scared chicken can fly Add two more rules: Rule 4: Penguins cannot fly Rule 5: Everybody can fly in the airplane 2014 OpenRules, Inc. 6

Expanded Single-Hit Decision Table If you try to cover all possible combinations for similar rules with conflicts, the number of rules grows exponentially! Rule 1: Birds can fly Rule 2: Chicken cannot fly Rule 3: Scared chicken can fly Rule 4: Penguins cannot fly Rule 5: Everybody can fly in the airplane 2014 OpenRules, Inc. 7

Problems with Traditional Single-Hit Decision Tables Difficult to read and understand such a decision table not mentioning a necessity to maintain it with future changes Think about adding new rules: Birds with broken wings cannot fly Ostriches would not fly even when they are scared What if we try to add more rules that cover other 40 kinds of flightless birds that are in existence today? 2014 OpenRules, Inc. 8

Switching to Multi-Hit Decision Tables Multi-Hit Decision Tables allow Rules Overrides: Rules with more specific conditions may override previously defined rules with more generic conditions! Rule 1: Birds can fly Rule 2: Chicken cannot fly Rule 3: Scared chicken can fly Rule 4: Penguins cannot fly Rule 5: Everybody can fly in the airplane 2014 OpenRules, Inc. 9

Pros and Cons of Multi-Hit Decision Tables Pros: more readable and easy to maintain to compare with single-hit decision tables you do not have to cover all possible combinations of decision variables Cons: relies on a strict sequencing of the rules inside the decision table that makes an introduction of new concepts and rules much more problematic 2014 OpenRules, Inc. 10

Real-world Examples of Rules with Conflicts Consider the following rules from the financial domain: Rule 1: Stock in debt is considered risky Rule 2: Stock in fusion with other stocks may be risky Rule 3: Stock in fusion with a strong stock is not risky Rule 4: Do not buy risky stocks unless they have a good price 2014 OpenRules, Inc. 11

More Real-world Examples No vehicles in the park (except during parades) Offer, acceptance, and memorandum produce a contract (except when the contract is illegal, the parties are minors, inebriated, or incapacitated, etc.) These rules are defeasible as they can be defeated by their exceptions 2014 OpenRules, Inc. 12

Auto-Resolution of Rules Conflicts Is it even possible to automatically resolve conflicts between business rules? The closest theory that deals with business rule conflicts is known as Defeasible Logic introduced more than 25 years ago This is a kind of reasoning that is based on reasons that are defeasible, i.e. capable of being defeated by other reasons 13

Defeasible Logic Differentiates between strict rules and defeasible rules: Strict rules are rules in the classical sense that are used in all modern BRMSs, e.g. If something is a penguin Then it is a bird. Defeasible rules are rules that can be defeated by contrary evidence, e.g. Birds typically can fly unless there is other evidence suggesting that it may not fly. Defeaters are special rules used only to defeat some defeasible rules, e.g. Heavy animals may not be able to fly. 14

Superiority Relations among Rules Used to define priorities among rules, where one rule may override the conclusion of another rule. For example, given the defeasible rules R1: Birds typically fly R2: Birds with broken wings cannot fly no conclusive decision can be made about whether a bird with broken wings can fly. But if we introduce a superiority relation R2 > R1 then we can indeed conclude that it can t fly. 15

Defeasible Logic & BRMSs The majority of BRMSs do not support the defeasible logic forcing their users to resolve all conflicts manually However, today enterprise-level rule repositories achieved a high level of maturity and internal complexity Absence of automatic conflict resolution tools will lead to unnecessary growth of rules and may gradually convert rules repositories to unmaintainable monsters Defeasible Logic becomes a must-feature 16

Open Source BR Products take a Lead Last year two major open source BRMSs announced their implementations of the Defeasible Logic: JBoss Drools implemented the classic defeasible logic with strict and defeasible rules along with the superiority relationships between rules OpenRules implemented the defeasible logic with strict and defeasible rules but using a different concepts for conflict resolution based on their constraint-based rule engine 17

Defeasible Logic by Drools JBoss Drools added the following rule annotations to their rule language (DRL): @Strict @Defeasible @Defeats( rule1, rule2, rule3 ) @Defeater A user may use @Defeats to specify a list of defeasible rules that can be defeated by the current rule 18

Defeasible Logic by Drools Rules for issuing bus tickets in DRL: Read more 19

Defeasible Logic by OpenRules While we could also list rules that can be defeated by the current rules, we believe such superiority relations will become unmaintainable after a while. If some rules directly know about other rules it may lead to macaroni relations especially when new defeasible rules need to be added 20

Defeasible Logic by OpenRules To implement Defeasible Logic but without superiority relations, we introduced a rule probability (or rule likelihood) It means instead of stating Birds typically can fly our user is able to write something like: There is a relatively high probability that birds can fly (defeasible rule) There is a very high probability that penguins cannot fly (defeasible rule) Everybody can fly in an airplane (strict rule) 21

Defeasible Logic by OpenRules Our user may assume that Rule with a higher probability will in general defeat Rule with a smaller probability The rule probabilities may be expressed as: NEVER, VERY LOW, LOW, BELOW MID, MID, ABOVE MID, HIGH, VERY HIGH, ALWAYS Or using numbers 0 (NEVER), 1, 2,, 99, and 100% (ALWAYS) A rule with probability ALWAYS (or not specified) means a strict rule 22

Defeasible Logic by OpenRules Actually we added only one optional column to our standard decision table template called ActionProbability Rule designer should be careful defining relative probabilities. For example, if we forget to specify the condition Chicken is Yes in the rule 5, it would not be clear either a scared penguin can fly or not. 23

How Does It Work The described logic is supported by OpenRules Engine known as Rule Solver that is based on a standard constraint solver Rule Solver creates a constraint satisfaction problem: Constraints for all strict rules are simply posted as hard constraints Constraints for all rules with probabilities are posted as soft constraints with a possible violation cost defined by its probability value Then Rule Solver automatically solves this problem by minimizing the total constraint violation for all defeasible rules 24

Benefits The described approach will work even when not all conflicts can be resolved: the Rule Solver will find a decision with minimal total conflicts Business analysts may express their preferences in an intuitive way as they do it in everyday life when they say: There is a high probability of rain tonight without any knowledge of the defeasible logic or the probability theory 25

Conclusion We did not want to create a false impression that all problems related to rule conflicts have been solved Our objective was to bring an attention to the importance of these issues and to show some possible ways for their resolution We expect that all major BR vendors gradually will add an automatic ability to solve rule conflicts to their product offerings 26