Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT...

6
Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e- Business 2 November 2002 Revised: 26 February 2005

Transcript of Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT...

Page 1: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

Slotted RuleML forMetarole-Based Object-Centered

Knowledge Representation

Harold Boley, NRC IIT e-Business

2 November 2002Revised: 26 February 2005

Page 2: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

26-Feb-05RuleML 0.882

Slotted RuleML Via the Name-Giving Metarole slot (I)

Here is a self-explaining 'metarole' (slot) representationof the slotted, RDF-like Jess fact

(automobile (make Ford) (model Explorer) (year 1999))

in Object-Oriented (OO) RuleML – part of RuleML 0.88 –with user slots named via the first subelement:

<Atom> <opr><Rel>automobile</Rel></opr> <slot><Ind>make</Ind><Ind>Ford</Ind></slot> <slot><Ind>model</Ind><Ind>Explorer</Ind></slot> <slot><Ind>year</Ind><Ind>1999</Ind></slot></Atom>

Page 3: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

26-Feb-05RuleML 0.883

Slotted RuleML Via the Name-Giving Metarole slot (II)

This 'Slotted RuleML' notation corresponds to the'positionalized' ruleml-datalog notation

<Atom> <opr><Rel>automobile</Rel></opr> <Ind>Ford</Ind> <Ind>Explorer</Ind> <Ind>1999</Ind></Atom>

if the 'roles' of the make, model, and year positionsare remembered somewhere else (signature declaration)

Page 4: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

26-Feb-05RuleML 0.884

Slotted RuleML Via the Name-Giving Metarole slot (III)

Note that a mix of an ordered sequence of args androle-unordered args will thus be possible in facts as well:

<Atom> <opr><Rel>automobile</Rel></opr> <Ind>Ford</Ind> <Ind>Explorer</Ind> <Ind>1999</Ind> <slot><Ind>mileage</Ind><Ind>65000</Ind></slot> <slot><Ind>color</Ind><Ind>white</Ind></slot></Atom>

Also, Ind elements can be replaced by (typed) Var elements in all of the positional, slotted and mixed notations

Page 5: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

26-Feb-05RuleML 0.885

Flat Feature Terms in Slotted RuleML

The minimal 'metarole' (slot) representation of the slotted,RDF-like (untyped) feature term, similar to F-logic term,

auto[make -> Ford; model -> Explorer; year -> 1999]

in RuleML 0.88 with user slots named via the first subelement:

<Cterm> <opc><Ctor>auto</Ctor></opc> <slot><Ind>make</Ind><Ind>Ford</Ind></slot> <slot><Ind>model</Ind><Ind>Explorer</Ind></slot> <slot><Ind>year</Ind><Ind>1999</Ind></slot></Cterm>

Can also be used as an argument in facts

Page 6: Slotted RuleML for Metarole-Based Object-Centered Knowledge Representation Harold Boley, NRC IIT e-Business 2 November 2002 Revised: 26 February 2005.

26-Feb-05RuleML 0.886

Nested Feature Terms in Slotted RuleML

The representation of the nested (untyped) feature term

vehicle[winter -> auto[make -> Ford; model -> Explorer; year -> 1999] summer -> cycle[make -> Honda; model -> Magna; year -> 2002]]

in RuleML 0.88 with user slots named via the first subelement:<Cterm> <opc><Ctor>vehicle</Ctor></opc> <slot><Ind>winter</Ind> <Cterm> <opc><Ctor>auto</Ctor></opc> <slot><Ind>make</Ind><Ind>Ford</Ind></slot> <slot><Ind>model</Ind><Ind>Explorer</Ind></slot> <slot><Ind>year</Ind><Ind>1999</Ind></slot> </Cterm> </slot> <slot><Ind>summer</Ind> <Cterm> <opc><Ctor>cycle</Ctor></opc> <slot><Ind>make</Ind><Ind>Honda</Ind></slot> <slot><Ind>model</Ind><Ind>Magna</Ind></slot> <slot><Ind>year</Ind><Ind>2002</Ind></slot> </Cterm> </slot></Cterm>