Hi John, Ernest,
First, thank you very much Ernest for getting involved, because I'm
absolutely the wrong person for comparing programming languages and
rule engines. I'm only trying to help out people who use Jess in
combination with Protege.
So John, all I can do is share some of my experiences when I did the
first steps with Protege and Jess. Actually, it was more a coincidence
that I'm using the Protege / Jess / JessTab combination, because I
started using Protege before I even knew that Jess existed. When I was
later looking for a rule engine, Jess was the natural choice. The
toolset is exactly what I need for my project, and the support on both
mailing lists (Jess and Protege) is just awesome.
The main reason I'm using Protege and Jess is that it is great for
prototyping, especially when your domain model is still in flux. You
can easily modify the domain model in Protege, the forms give you an
'instant' user interface, where you (or a domain experts even without
any programming knowledge) can start entering instances. With the
JessTab function mapclass, any changes are automatically made to the
Jess facts—no need to update your deftemplates—which saves you
additional effort in the early stages. As Ernest pointed out in an
earlier post, the downside of this versatility is the "(object (is-a
MyClass))"-thing.
If you are uncertain whether you really need a rule engine, have a look
at:
http://www.jessrules.com/guidelines.shtml
If you are uncertain whether you should use Protege or create you own
application from scratch, you might consider the following elements:
— Your personal knowledge and 'comfort' in using Java vs. any other
programming language, see Ernest's post.
— Size and stage of your project, see comments above on prototyping and
effort for UI programming.
— Reuse of any Protege plug-in. There are many plugins available for
Protege, they are usually well supported. Maybe you don't even realize
in the beginning that you'll be grateful for one of them (as it
happened to me when I discovered the Jess / JessTab integration ;-)
Chances are, that using Protege and Jess minimizes your development
effort to your specific problem.
Dona, I have the same questions as you do about what tools are apt.
Before I comment for Jason's reply please note that I am new to
ontology based systems, and I would be grateful if you can correct any
errors.
If you need basics on modeling ontologies, look at:
http://protege.stanford.edu/publications/ontology_development/
ontology101.html
I cannot help you with the details because I still don't know what you
are trying to achieve. When someone posts an example with a class named
'Hello' I usually presume that this person is either a beginner trying
to do a simple "Hello World" type of example where the model doesn't
matter, or that it is someone with more knowledge who is presenting a
simplified example that is reduced to the core problem. Please don't
get me wrong, but I wouldn't expect a class named 'Hello' in a serious
ontology, because I wouldn't expect it to be an actual concept of a
domain. Again, I have no clue what you are trying to achieve. Describe
your problem. It is perfectly okay to post modeling questions, both
here and on the Protege mailing list. People can help you better when
they have more background information. It is also helpful to know
whether you have a design question, or whether you have a Jess /
JessTab-specific issue (like matching multislots with Protege
instances).
If you decide to use Protege / Jess / JessTab, you should get the book
'Jess in Action'. People always tell you that rule-based systems are 'a
different story'. The book helped me to get into this alternative
mindset for organizing an application (although I'm not an expert, but
rather a struggling sophomore), and JiA has hands-on examples to 'get
things done' in Jess. In addition, I used Durkin, J. (1994). Expert
systems design and development. New York, Macmillan for more background
information. It covers basics of rule-based systems and frame-based
systems. The latter gave me some more fundamental understanding about
Protege. However, the book is not very recent, so I'd love to see an
update, complemented with chapters on ontologies. BTW: Are you using
Protege Frames or OWL? And yes, the CLIPS manual can be a helpful
resource, since both Jess and Protege have common roots in CLIPS. I
never tried the CLIPS plugin for Protege, so I have no experience with
that. I directly chose Jess for its seamless combination with Java—when
I first saw the scripting capabilities, I realized that I didn't need
to look any further for my purpose.
HTH,
Dona
On Jun 23, 2006, at 9:03 AM, friedman_hill ernest j wrote:
I think John wrote:
I hesitate to get involved in this discussion, but perhaps by
supplying some of the missing information early on, I can avoid
turmoil later.
Well...let me start will the fundamentals of rule-based programming
in both
Jess and CLIPS. Rule-based programming resembles event-based
programming
(like exceptions in Java). If we can program rules in Java or C++,
then what
is the need for Jess and Protege. What role does these tools play?
First and foremost, the right tool for any job is the one that lets
you solve the problem at hand, such that the result is fast enough,
scales well enough, and such that the resulting code can be
maintained. No one tool is right for every job.
Today, I re-programmed my entire ontology in VC++ using
MFC(event-based).
The result is faster and highly portable ontology.
I am amused to hear VC++ and MFC referred to as being more portable
than Java. But in any case, if what you've written solves whatever
problem you're solving easily enough and well enough, then indeed,
you've found the right tool for the job. No arguments there.
Rule engines are used by many companies for a number of reasons, but
among them are modularity (the individual rules are independent),
scalability (continues to work well as the number of rules and working
memory elements increases), liveness (the ability to modify a running
rulebase,) performance, and maintainability (due largely to the
modularity.) If you read up on the Rete algorithm, as described in the
Jess manual and elsewhere, you'll get an idea of the kind of
siutuation in which a good rule engine can perform much better than
the sort of code you've written.
OK ....let me compare CLIPS and Jess. Both have the same
syntax...CLIPS can
be portable to almost any language. Also, since it is built in C, the
run-time is extremely fast comparing Jess. On the other hand, Jess
depends
on Java and Java programming alone for external interface.
Jess was written to use largely the same syntax as CLIPS to make
transitioning from CLIPS to Jess easier. But Jess was (as should go
without saying) intended to improve upon CLIPS, and many people feel
that it has succeeded in that regard.
What I'm hearing from you is that you're not a Java person, and that's
really fine. The world of programming still divides fairly neatly into
Java and non-Java camps, into Microsoft and non-Microsoft camps. This
is not the place to have those kinds of discussions. Suffice to say
that for many programming shops, being Java-based is an advantage
rather than a liability.
The claims about C/C++ being intrisically faster than Java are just
FUD;
there are many benchmarks available on the Web showing that this
simply isn't true, and hasn't been since Java's earliest days. One
thing about Java that *is* slow is program startup, so if you're
writing toy programs that run for only a second, then Java is indeed
going to seem slower. For substantial programs, or even small programs
that run in a persistent application server, then this startup issue
isn't there. Of course, most code being written today falls into this
last category.
But in fact, the truth is that Jess is often much faster than CLIPS
for nontrivial programs due to the advanced algorithms is uses. Jess's
performance on the standard Miranker rule-engine benchmarks is orders
of magnitude better that CLIPS for large problem sizes, as has been
independently measured. Jess' performance really shines in situations
where there are many objects in working memory and your rules need to
make comparisons across multiple memory elements.
CLIPS (developed by NASA) is well documented and been the language of
AI
systems for almost two decades. I learned Jess syntax from CLIPS
documentation.
There are many commercial rule engines, Jess being but one; it's a
large and thriving market. You'll have to draw your own conclusions
there.
Maybe I am wrong about Jess, but with my current perspective, i dont
see any
good reasons to use Jess instead of CLIPS, C++, or even sole Java
coding.
I think you've hit the nail on the head right there: "with your
current perspective," the reasons why rule engines are used aren't
obvious to you. With some experience, you may come to understand.
---------------------------------------------------------
Ernest Friedman-Hill
Advanced Software Research Phone: (925) 294-2154
Sandia National Labs FAX: (925) 294-2234
PO Box 969, MS 9012 [EMAIL PROTECTED]
Livermore, CA 94550 http://herzberg.ca.sandia.gov
--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify
[EMAIL PROTECTED]
--------------------------------------------------------------------
--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------