W3C home > Mailing lists > Public > www-rdf-rules@w3.org > September 2001

Re: What is an RDF Query?

From: Sandro Hawke <sandro@w3.org>
Date: Tue Sep 11 14:23:32 2001
Message-Id: <200109111821.f8BILkt04608@wadimousa.hawke.org>
To: pat hayes <phayes@ai.uwf.edu>
cc: www-rdf-rules@w3.org

> > > >I agree that RDF queries and RDF rule premises
> > >
> > > Er.....actually, rule consequents/conclusions are more like queries
> > > than rule premises are. Is that what you meant?
> >
> >Um, no.
> >
> >Here's a rule:  If Ralph is in his office, then Ralph is at MIT.
> >                    \                  /         \           /
> >                     \                /           \         /
> >                          Premise                 Conclusion
> >                        (Antecedent)             (Consequent)
> >
> >We could make either part into a query:
> >       Is Ralph in his office?
> There is no way to answer that, given this rule. The rule simply 
> doesn't connect to this query in any way.
> >       Is Ralph at MIT?
> He is if he is in his office, otherwise you don't know (from the rule)

Ah-ha!   I see what you think I'm talking about now.

> See any logic textbook, Sorry , but this is really very basic stuff.

Well, yes.  I was going to say the same thing to you, but I knew
better.  :-)   Everything you said in your e-mail here was, indeed,

What I think you think I'm talking about is querying a rule base.
(Or, more precisely, querying the entailment closure of a set of
axioms.)  If I were trying to do that, I would probably use backward
chaining.  Doing that, I would do what you're talking about: I would
look for rule conclusions which looked like my goal query.  And in
that effort, I would be taking advantage of some similarity between
queries and rule conclusions.    That's what you're talking about,

What I was talking about (and what I'm pretty sure what Eric
Prud'hommeaux was talking about when he started this) is even
simpler.  Here's our knowledge base:

   Fact:  Ralph is in his office.
   Fact:  The Sun is shining.
   Rule:  If Ralph is in his office, then Ralph is at MIT.

You're jumping ahead and imagining I'll ask "Is Ralph at MIT?" but in
fact I'm asking something much simpler.  I'm asking "Is Ralph in his
office".  Answering that query doesn't involve the rule (obviously).  

And then I start to think -- hey, I could forward-chain that rule!  I
could see if it's premise is true so I can maybe make some inferences!
And if I do that, the first thing I'll do is ask "Is Ralph in his
office?" so I know whether to infer he's at MIT.

This is, of course, very basic stuff (for someone familiar with formal

Eric was saying that asking "Is Ralph in his office?" is the same
thing whether it's being done directly because of a user's query or as
part of a rule-chaining processes.  Eric's RDF software (algae) and
Tim B-L's RDF software (cwm) both do forward-chaining, and I suspect
they use the same code for user queries and rules.

So I think your answer is "well, of course they're the same thing."
They're so obviously the same thing that you figured we were talking
about something else (like matching queries with rule conclusions, in
doing backward chaining).   Am I right?

In fact, I think they're probably the same thing at all when you get
into enough engineering details.  But in the abstract, they are.

     -- sandro
Received on Tuesday, 11 September 2001 14:23:32 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 2 March 2016 11:10:12 UTC