I have historical transactional data. The requirement is to evaluate all the conditions on the historical data for the new transaction (such as a new payment transaction)
For eg: The new Payment transaction will evaluate the following conditions: - If payment is made by credit card - If there were multiple payment failures (considering historical data) - If the credit card in the payment is used by some other account.(considering historical data)
There are above 100 relationship based conditions that need to run on such historical data (spanning several years). Thus, I was assuming to use a Graph DB to store the tuples and then create a condition statement covering it all? But, I need to know also which condition held true. Thus, the only other option is to run the queries per condition which is a challenge for real-time use-cases.
Is there another alternative, performant approach to this?
Max De Marzi has written a post on building rules engines that you may find interesting:
He has also written a couple of posts on finding fraud based on linking irregular purchase behaviours together, along with detecting fraud rings, which sounds similar to the theme you are looking to explore.