Jacob starts his talk with an overview of the evolution of rule technology.
- It all started with Dr. Charles Forgy’s Rete algorithm for Inference
- Neuron Data (upon Carlos’s technical leadership) and ILOG were pioneers in Business Rules Technology
- Soon those vendors started focusing primarily on Rules Management rather than execution
- Recently the industry evolved towards Decision Management
I appreciated Jacob’s answer to my Blog series on how Rete works. I asked back then why the Rete algorithm dominated so widely the Business Rules world. His answer makes a lot of sense: because there was no need. Rete is the best for the execution of Business Rules as we are conceiving them and Commercial products are available.
OpenRules announced earlier this year its integration with the Decision Model — which Larry Goldberg presented at Rules Fest 2010. Jacob provides a quick overview for those that are not as familiar with it.
Decision Models offer a representation for business people to capture their decisioning logic in a structured table format. They can be deployed into a rule engine for execution:
- Either converting the spreadsheets into a rule language that can be interpreted and executed by a Rete-based engine.
- Or by generating an intermediate constraint satisfaction problem that is deployed in a constraint-based rule engine
We know quite a lot about Rete-based rule engines; so Jacob focuses his presentation to constraint-based rule engine which we may not all know about.
CP and rule-based programming are both declarative technologies with a different input — rule language versus constraints.
JSR331 is the constraint programming API standard developed within the JCP. It is already 2.5 years-old, in draft mode currently.
Jacob’s open source product, OpenRules has always supported both engines. FYI Jacob used to be very close to our friends at ILOG in the early days and has always been a passionate expert and advocate for both technologies.
More recently, Jacob has added inference ability in the solver. With both capabilities, he is now able to deploy Decision Models in there.
You may want to download a copy of the slides when they are available to go through the “Greeting” example step by step to better understand the details.
After defining the rule families, the business vocabulary and some test data, you can run the decision model. Jacob is showing us both execution in Eclipse — Java knowledge required 😉
Success! Eclipse tells us “Good Afternoon Little Smith” both ways!
Next step is to change the order of those words so that the salutation comes last in the rule family table… The inference engine shows “null” instead of the expected “little”, which worries me a bit… Do we really expect the business users to understand the impact of this ordering? A decision flow is visually clear. I did not expect the failure just by moving a decision family down in the spreadsheet. Jacob points out that the constraint-based engine works fine.
Last demo stresses another problem with inference-based approach. Detecting overlaps is trivial for a constraint engine while rules could hide the inconsistency.
Constraints are good at finding the BEST
Constraint satisfaction solvers are optimization technologies that are good at minimizing or maximizing objective functions of course. But they can also relax constraints and provide solution to an impossible problem with some indication of the violation cost. This is a great point to make as rules really drive a heuristic and do not know how to backtrack (as an over-simplifying perspective); they do not know either how to “relax” rules unless you have created the alternative options.
Quoting again my Sports presentation that compares rules and optimization (http://www.slideshare.net/cmatignon/the-science-of-sports-matignon-2009), the latter is much better suited in general for “constrained” problems where there is a difference in quality for different answers.
Jacob, we love you… But be careful that the Rules Fest police may jump on you for doing a product demo on stage… okay… it is open source… Taking Mark’s lead?
Learn more about Decision management and Sparkling Logic’s SMARTS™ Data-Powered Decision Manager