Re: Importing RIF documents from RDF - last attempt

On 18 Mar 2010, at 16:01, Jos de Bruijn wrote:

> I see what you mean. An implementation that does not take one of the
> imports into account does not follow the spec.

Actually, the other way around: 
An implementation that takes rif:imports (that is the imports directive 
in the RDF Graph G) into account in the way I proposed, does - strictly 
speaking - not follow the SWC spec.

However, I hope we can get around this, if we define in SPARQL just 
what the "corresponding RIF-RDF-combination" to a graph mentioning 
rif:imports is.

> Now, concerning the rif:imports. Could you explain me again why it is a
> good idea to extend the RDF semantics to include RIF-RDF combinations?

We want a handle from RDF to RIF,  just as "Imports()" gives you a handle 
from RIF to RDF. We don't want to extend the RDF semantics, but the semantics 
of RIF-RDF combinations.

> I understand that you want to use SPARQL to query RIF-RDF combinations.
> How does the syntactic construct in RDF help?

From SPARQL we can only query RDF Graphs, or, more precisely RDF Datasets.
Entailment regimes, can only extend Basic GHraph pattern matching in SPARQL, 
i.e. what a graph means. [1]:
That is, an entailment regime  can define the scoping graph for an 
RDF Graph G under RDFS Entailment to be a particulalar 
canonically defined RDFS entailed graph G'. Similar for OWL.  

So, in a RIF-Entailment regime, we need to say what the Graph "means" wrt. RIF,
but there we need a handle to RIF, such that we can define that scoping graph 
as a graph entailed by the RIF-RDF-combination defined by rif:imports triples. 
We have no means to refer directly to a RIF ruleset from SPARQL, but only to 
RDF Datasets.

>  Why not have implicit
> rulesets (like the implicit datasets) and give the user the possibility
> to refer to a RIF ruleset from the query?

You also don't want to fix the ontology for OWL Entailment, but anyways 
OWL fits a bit better with the RDF dataset idea, since you can express OWL 
in RDF, or import OWL ontologies, so we are safe there.

Extending the definition of Dataset towards something else then RDF Graphs
is outside the scope of entailment extensions in SPARQL.

Hope that clarifies matters,
Axel

1. http://www.w3.org/TR/rdf-sparql-query/#sparqlBGPExtend

> Jos
> 
> On 2010-03-18 11:18, Axel Polleres wrote:
> >> I'm not sure what you mean with the imports mechanism having a
> >> semantics. The semantics of the combination (R2,G) is clearly defined in
> >> the SWC spec.
> >
> > Yes it is clearly defined, and it wouldn't take the import of R1 from G
> > into account. So, in case we define a semantics for importing rulesets
> > from graphs, an implementation that takes this imports-mechanism into
> > account will not be compatible to the SWC spec on this example.
> >
> > Axel
> >
> > On 18 Mar 2010, at 10:10, Jos de Bruijn wrote:
> >
> >>
> >>
> >> On 2010-03-12 15:32, Axel Polleres wrote:
> >>> On 12 Mar 2010, at 14:09, Chris Welty wrote:
> >>>> Axel,
> >>>>
> >>>> I really really really do not understand why it matters whether RIF specifies this or SPARQL.
> >>>> RIF should be viewed as read-only right now unless there is an error.
> >>>
> >>> 1) the *main issue* is the URI we use for dereferencing, which we think should be in the rif: namespace, i.e. we need
> >>>    rif:'s blessing if we do so.
> >>>
> >>>
> >>> I mentioned in the mail already that it would probably be an alternative if we could just produce a (joint?)
> >>> note or separate (rec?) document on this. That would mean we wouldn't touch the rif-rdf-owl spec as such. However ...
> >>>
> >>> 2) ... as I see it there is *potential issue* around a separate spec which worries me a lot...
> >>> if we *don't* specify the importing from RDF within rif-rdf-owl, then whatever we write in that note separate spec
> >>> would be potentially incompatible with rif-rdf-owl ... here's why:
> >>>
> >>> Say you have two rulesets R1, R2 and one graph G:
> >>>
> >>>   G:
> >>>      G <> rif:imports [rif:ruleset R1 rif:profile <...simple...> ].
> >>>
> >>>   R2:
> >>>     Imports( G <...simple...> )
> >>>     ... some rules ...
> >>>
> >>>   R1:
> >>>     (Imports R2)
> >>>     ... some other rules ... no imports clause
> >>>
> >>> Now... depending on whether or not the imports-mechanism in RDF has a semantics, the RIF-RDF combination  (R2,G)
> >>> has different semantics.
> >>
> >> I'm not sure what you mean with the imports mechanism having a
> >> semantics. The semantics of the combination (R2,G) is clearly defined in
> >> the SWC spec.
> >>
> >>
> >> Cheers, Jos
> >>
> >>>
> >>> So, my worry is, if we postpone that issue to post-RIF, we can't define it in an upwards compatible way at all...
> >>> besides, I think it is a very minor change, which makes live much easier for applications coming from the RDF side
> >>> doing something with RIF and doesn't seem to affect 99% of those caring from the RIF side only.
> >>>
> >>> Axel
> >>>
> >>>
> >>>> -Chris
> >>>>
> >>>> Axel Polleres wrote:
> >>>>> Hi all,
> >>>>>
> >>>>> We had the topic of "rif:imports" coming up in SPARQL again in our Entailment regimes taskforce call this week.
> >>>>>
> >>>>> The reason why we (from the SPARQL side) would prefer to have that imports mechanism defined in RIF,
> >>>>> is mainly that we think that the URIs to use for defining this imports mechanism should be in  the rif:
> >>>>> namespace, since this imports mechanism is likely useful not only for SPARQL but also for other
> >>>>> RDF applications that wnat to interact with RIF.
> >>>>>
> >>>>> Thus, I wanted to inquire again, whether we'd have a chance to get that an import mechanism for RIF from RDF into
> >>>>> http://www.w3.org/TR/rif-rdf-owl/ ?
> >>>>>
> >>>>> If the group overall still thinks that it is too late to get this into the spec, in turn, I wanted to ask/raise
> >>>>> again how/whether we could proceed to publish this text as a WG Note?
> >>>>>
> >>>>> I have earlier made a simple proposal to add a new section to the current spec, which we elaborated a bit now:
> >>>>>
> >>>>> 1) In the introduction of http://www.w3.org/2005/rules/wiki/SWC,
> >>>>> I would suggest to add:
> >>>>>
> >>>>> "RDF Graphs in RIF-RDF-combinations are assumed to not contain any triples using the predicates
> >>>>> rif:imports, rif:ruleset and rif:profile we refer to Section 6 for treatment of such graphs.
> >>>>> "
> >>>>>
> >>>>> 2) Further, I would suggest to add a new section:
> >>>>> ====================================================================================
> >>>>>
> >>>>> = 6 Importing RIF rulesets in RDF =
> >>>>>
> >>>>> The definitions so far, only covered RIF-RDF-combinations where the RDF graphs did not contain
> >>>>> triples using rif:usingRuleset in predicate positions. To lift this restriction, we define
> >>>>> RIF-X-combinations (R,S) where any of the graphs in S contains triples with the predicates
> >>>>> rif:imports, rif:ruleset and rif:profile
> >>>>> by a reduction to combbinations without such triples as follows.
> >>>>>
> >>>>> Let (R, S) be a combination as above. The reduction of R is defined as the
> >>>>> RIF-X-combinations (R', S') where
> >>>>>  (i) S' is identical to S with all rif:imports, rif:ruleset and rif:profile triples removed,
> >>>>>      and
> >>>>>  (ii) R' is identical to the RIF document R,
> >>>>>       with the addition that R' has additional imports clauses
> >>>>>       Imports( R1 )
> >>>>>       Imports( G P )
> >>>>>      for any triples
> >>>>>
> >>>>>        <> rif:imports [rif:ruleset R rif:profile P ].
> >>>>>
> >>>>>      in (simple entailed by) S, such that R1 is an IRI referring to a RIF document and
> >>>>>      P is a URI referring to an imports profile as defined in
> >>>>>      Section http://www.w3.org/2005/rules/wiki/SWC#Profiles_of_Imports
> >>>>>
> >>>>> Together with the conditions in section 5.2 this ensures that RIF-X-combinations where R is empty, i.e. which
> >>>>> are only defined by a set of RDF graphs, can also import RIF rulesets.
> >>>>>
> >>>>> ====================================================================================
> >>>>>
> >>>>> In case there is a chance to get this on one of the next agendas, please let me know, since I have recently not
> >>>>> really had time to be follow the RIF TCs, but I'd be joining for that.
> >>>>>
> >>>>> best,
> >>>>> Axel
> >>>>>
> >>>>> P.S.: Condition (i) which removes all the rif:usingruleSet triples, i.e.,
> >>>>> just treats these triples as a directive rather than part of the graph, may be dropped, i.e. simply
> >>>>> keeping S as is, accepting the rif:imports, rif:ruleset and rif:profile triples as part of the graph.
> >>>>>
> >>>>
> >>>> --
> >>>> Dr. Christopher A. Welty                    IBM Watson Research Center
> >>>> +1.914.784.7055                             19 Skyline Dr.
> >>>> cawelty@gmail.com                           Hawthorne, NY 10532
> >>>> http://www.research.ibm.com/people/w/welty
> >>>>
> >>>
> >>>
> >>
> >> --
> >> Jos de Bruijn
> >>   Web:          http://www.debruijn.net/
> >>   LinkedIn:     http://it.linkedin.com/in/josdebruijn
> >>   Skype:        josdebruijn
> >>   Google Talk:  jos.debruijn@gmail.com
> >>   Mobile phone: +43 660 313 5733
> >>
> >
> 
> --
> Jos de Bruijn
>   Web:          http://www.debruijn.net/
>   LinkedIn:     http://it.linkedin.com/in/josdebruijn
>   Skype:        josdebruijn
>   Google Talk:  jos.debruijn@gmail.com
>   Mobile phone: +43 660 313 5733
> 

Received on Thursday, 18 March 2010 16:36:12 UTC