W3C home > Mailing lists > Public > www-rdf-rules@w3.org > November 2003

Re: Rules WG -- draft charter -- NAF

From: Sandro Hawke <sandro@w3.org>
Date: Thu, 13 Nov 2003 00:57:47 -0500
Message-Id: <200311130557.hAD5vlX7004125@roke.hawke.org>
To: adrianw@snet.net
Cc: www-rdf-rules@w3.org


[Converted from HTML to plain text]
> On another point though, you may like to think a bit before
> legislating against negation-as-failure in the core language. NAF is
> similar in concept to the way most applications use relational
> databases.  Roughly speaking, it allows you to deduce, from a
> database table of people in W3C, that if Fred is not listed, then
> Fred is not a member of W3C. Again roughly speaking, if you stick to
> classical logic instead of using NAF, you are required to list in
> your database tables all the people who are NOT members of
> W3C. Obviously, this can quickly get completely out of hand when you
> have tables with more than one column. The same kinds of problems
> arise with declaratively interpreted rules, unless you allow NAF.

This is an excellent point for discussion, and comes up in Benjamin's
proposed changes [1] as well.

I think it hinges on a basic point: being a Semantic Web rule language
means more than just being a "standard" rule language.  If the goal
were just to make a common language that Prolog, OPS-5, and SQL
systems could use, then where would the Web come in?  No, the point I
think is to allow everyone to publish their rules as reusable data, as
assertions of one's belief about the world.  Others can then wander by
a pick up a random rule or two as being useful.  (Whether they chose
to believe it is a separate matter.)

This makes NAF rather more tricky, I think, than in traditional rule
systems.  This is the motivation for calling it out-of-scope.  Let's
see....  Imagine the rule "If a game has no errors, it's a perfect
game."

     { ?game a Game.
       Not { ?game error ?e }.
     }
     =>
     { ?game a PerfectGame }

But, as you say, this means someone has to SAY the game has no errors,
they can't just not list any errors and still have the conclusion be
supported.    So you want something more like:

     { ?game a Game.
       NotKnown { ?game error ?e }.
     }
     =>
     { ?game a PerfectGame }

But... Well, at very least that's non-monotonic.   Any conclusion you
reach like this MUST NOT be re-published, right?  Or, they must always
carry with them the warning "if we assume my knowledge of the world is
complete, then...."   And people wondering by and picking up this rule
... well, do you have any reason to think they would know where to
look for errors?   The naive user/software is almost certain to get
false results from NAF rules like this.

So what can you do?  W3C SWAD (mostly TimBL) has been looking at this
for a while, and Cwm implements two solutions via built-ins [2]:

    log:includes + log:notIncludes statements depend on whether some
    web-accessible RDF graph includes some subgraph.  This lets you
    say the game has no errors if http://foo.bar doesn't list any
    errors.

    log:definitiveDocument approaches this from the other side,
    letting you say http://foo.bar lists all "errors", by the very
    definition of "errors".   An exported SQL database with usual
    closed-world semantics can simply include that it's a
    log:definitiveDocument for all its predicates/columns, and the
    expected NAF-like behavior should ensue.

I'm sure there are other approaches, and I don't think the performance
issues are well-understood yet, but it makes me think something is
doable.   It also reminds me that the rule language here, even if very
like Prolog, etc, in some ways, also needs to be quite different to
be good for the Semantic Web.

       -- sandro

[1] http://lists.w3.org/Archives/Public/www-rdf-rules/2003Nov/att-0069/SWRulesWGCharter-v3-by-Benj.htm
[2] http://www.w3.org/2000/10/swap/doc/Reach
Received on Thursday, 13 November 2003 00:55:12 UTC

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