It occurred to me that instead of trying to reason with complex objects
(i.e. objects that have lots of fields, many of which contain nested
objects), one might be better of simply representing all data as RDF
statements. I suspect I'm not the first to use this approach, but
following are some examples showing how I would go about doing this. If
you can spot any possible drawbacks or fatal flaws in this approach,
please do let me know :-)
(deftemplate statement
(slot id)
(slot subject)
(slot predicate)
(slot object))
(assert (statement
(subject sptr:P1)
(predicate rdf:type)
(object v:Protein)))
(assert (statement
(id #_1)
(subject sptr:P1)
(predicate v:feature)
(object #_2)))
(assert (statement
(subject #_2)
(predicate rdf:type)
(object v:Disulfid)))
(assert (statement
(subject #_1)
(predicate v:updated)
(object 20031023)))
(defrule recent-statements
?s <- (statement (id ?id))
(statement
(subject ?id)
(predicate v:updated)
(object ?updated&:(> ?updated 20030101)))
=>
(printout t ?s ", " ?updated))
--------------------------------------------------------------------
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]
--------------------------------------------------------------------