Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lightweight inference engine interfaceable with Ruby

I have a large Ruby application that is just crying out for the addition of an inference engine; I don't need a lot of functionality, am not afraid of integrating C libraries, and am coming up empty in my Googling.

There seem to be plenty of rules engines in Python and on the JVM; while I'd prefer to be using Python, I'm not rewriting the whole damned application just to add an inference engine, so I'd really like to see if such a thing exists.

Anyone have any ideas?

like image 760
James Felix Black Avatar asked Sep 30 '11 22:09

James Felix Black


2 Answers

Here are some pointers I found while Googling. I've added the last activity after specific gems to give an indication if they are still being maintained, and sorted by that date.

  • See this question here on stackoverflow.com: Ruby & Rules Engines
  • ruleby (July 26, 2011)
  • unruly (May 13, 2011)
  • rdfs (June 14, 2010)
  • ruby-rules (March 30, 2007)
  • khammurabi (August 4, 2005)
  • SIE (February 4, 2002)
  • treetop (irrelevant, is a parser generator)

Plenty of options, maybe there is something to your liking here?

like image 181
rdvdijk Avatar answered Nov 10 '22 04:11

rdvdijk


Adding a new answer to an old question:

The wongi-engine is currently the best (only?) choice for a Ruby rules engine. It's based on the Rete algorithm and has some following on github.

All the options given by rdvdijk above are either no longer maintained, or completely dead and gone.

Alternatively, over on Ruby Quiz there is an awesomely lightweight inference engine written entirely in Ruby using a directed graph.

like image 2
djoll Avatar answered Nov 10 '22 04:11

djoll