|
Hi Kendall and All,
thanks for this thoughtful article. Yes, the Web
Rules and Open Source communities should learn
more from each other. In RuleML, Said
(http://home.comcast.net/~stabet) has started
a Dev Group with members active in the Apache
effort. You may also find Jess useful
(http://herzberg.ca.sandia.gov/jess).
Just another look here at the DATA snippet from an
early-stage Lisp/Prolog-inspired RuleML extension
(http://www.ruleml.org/indoo#Programs-as-Data):
<cterm>
<_opc><ctor>atom</ctor></_opc>
<_r n="opr"><rel>buy</rel></_r>
<var>person</var>
<var>merchant</var>
<var>object</var>
</cterm>
This is an *encoding* of the PROGRAM snippet
<atom>
<_opr><rel>buy</rel></_opr>
<var>person</var>
<var>merchant</var>
<var>object</var>
</atom>
such that an additional level of
evaluation/meta-interpretation
of the former acts like the normal
evaluation/interpretation of the latter
(checking whether a ternary buy relation
holds).
The element "_r" is the ubiquitous meta-role.
It is used so often in conjunction with
user-provided names like status, price, etc.
that we currently keep these user roles
<_r n="status">, <_r n="price">, etc. as short
as possible: almost as if they were system roles
<_status>, <_price>, etc. (however, _r can be
given a generic XML DTD/Schema, unlike
_status, _price, etc.)
Now, if you look at <_r n="status">,
<_r n="price">, etc. you will 'see'
<_status>, <_price>, etc., knowing that a rule like
<imp>
<_head>
<atom>
<_opr><rel>discount</rel></_opr>
<_r n="offer name"><var>off</var></_r>
<_r n="customer name"><var>cust</var></_r>
<_r n="awarded amount"><ind>10</ind></_r>
</atom>
</_head>
<_body>
<and>
<atom>
<_opr><rel>offer</rel></_opr>
<_r n="name"><var>off</var></_r>
<_r n="category"><ind>special</ind></_r>
<_r n="price"><var/></_r>
</atom>
<atom>
<_opr><rel>customer</rel></_opr>
<_r n="name"><var>cust</var></_r>
<_r n="status"><ind>gold</ind></_r>
</atom>
</and>
</_body>
</imp>
can still be validated independent of the
application domain (and RDF Schema), hence be
embedded, e.g., into valid XHTML.
Best,
Harold (http://www.cs.unb.ca/~boley)
|