RE: simple rule examples and RuleML Datalog impl

From: [email protected]
Date: 05/13/03

  • Next message: pat hayes: "(no subject)"
    Hi Mike and all:
    I did a quick implementation of the examples 1 and 2 in RuleML datalog. I 
    attached the RuleML file and a trace of execution of the first example in Jess.
    Examples 2 and 3 are already implemented in RuleML by Mike Dean (GEDCOM) and 
    ported to 0.8: 
    -----Original Message-----
    From: [email protected] [mailto:owner-joint-
    [email protected]] On Behalf Of Mike Dean
    Sent: Monday, May 12, 2003 12:36 PM
    To: [email protected]
    Subject: simple rule examples
    I promised to suggest several examples to help us compare
    the Horn clause subsets of RuleML and SCL:
    1) An employee of a (subsidiary) Company is also an employee
    of its parent Company.
    2) The uncle of a Person is either the brother of their
    parent, or the husband of their aunt.
    3) 2 *distinct* children in the same Family are siblings.

    D:\ruleml\demos\datalog>rulemltransform simplerules.ruleml
    D:\ruleml\demos\datalog>java org.apache.xalan.xslt.Process -IN simplerules.ruleml.xm
    l -XSL 0.8-RuleMLTransformToJESS.xsl -OUT simplerules.ruleml.output.clp
    D:\ruleml\demos\datalog>java jess.Main
    Jess, the Java Expert System Shell
    Copyright (C) 1998 E.J. Friedman Hill and the Sandia Corporation
    Jess Version 6.0 12/7/2001
    Jess> (batch simplerules.ruleml.output.clp)
    Jess> (facts)
    f-0   (MAIN::subsidiaryof "BBN" "Verizon")
    f-1   (MAIN::employeeof "Mike Dean" "BBN")
    For a total of 2 facts.
    Jess> (rules)
    For a total of 3 rules.
    Jess> (watch all)
    Jess> (run)
    FIRE 1 MAIN::employeerule1 f-1, f-0
     ==> f-2 (MAIN::employeeof "Mike Dean" "Verizon")

    This archive was generated by hypermail 2.1.4 : 05/13/03 EST