decision-engine | decision engine which based on fact and rules | Rule Engine library
kandi X-RAY | decision-engine Summary
kandi X-RAY | decision-engine Summary
A decision engine which based on fact and rules provided can deduce what decisions should be made. For example in an Ecommerce system, when users place orders there are multiple decisions to be made, whether the order qualifies for discount, what kind of shipping is applicable and so on. This calls for a business rule engine which decision-engine exactly is.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of decision-engine
decision-engine Key Features
decision-engine Examples and Code Snippets
Community Discussions
Trending Discussions on decision-engine
QUESTION
I'm trying to understand what is making Drools perform poorly in our use case. I read the Phreak documentation here: https://access.redhat.com/documentation/en-us/red_hat_decision_manager/7.4/html/decision_engine_in_red_hat_decision_manager/phreak-algorithm-con_decision-engine
It doesn't seem to mention anything regarding how node to node jumps are done. Here's an example to explain what I mean by that:
Let's say I have a Person object with three fields: name, lastName, SSN
I define a large number of rules this way: when lastName = 'Smith' and SSN = 'XXXXXXXXXX' then name = "Jane". Assuming I have a large number of people with "Smith" as last name, say 10,000, what is the complexity to get a single name given a last name and an SSN? Would it take 10,000 comparisons, or does the "Smith" node keep some form of hash map with all the underlying SSN?
What if instead of an SSN with an equality operator I used a range, like a date range for example, defining rules like this: "when lastName = 'Smith' and startedShool >= 2005 and finishedSchool <= 2010". Do nodes keep some fancy data structure to speed up the queries with range operators?
EDIT: Per request I'm adding an example to explain how the rules are set up
We have a single class called Evidence as both input and output. We build each Evidence instance in a different activation-group and add it to a set. We usually define a few catch-all, broad rules with low salience and add rules with more specific conditions and higher salience.
This is a sample of two rules with increasing salience. We define ~10K of these.
One can imagine a sort of tree structure where at each level the salience increases and the conditions become more stringent. The Evidence class functions as a sort of key-value pair, so many of them will have the same node in common (e.g. name = location).
To execute the rules, we would add two evidences (e.g. [name= location, stringValue='BBB'] and [name = code, stringValue = theCode]) and fire the rules.
...ANSWER
Answered 2020-May-26 at 18:41Here is the rule template
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install decision-engine
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page