Re: Manually checking entailment tests (ACTION-685) - part1

Hi Axel,

thanks for looking at the tests. I comment inline below.

Birte

On 2 October 2012 14:52, Polleres, Axel <axel.polleres@siemens.com> wrote:

[snip]
> bind06 ... looks ok, but why do we need both bind06, and bind01 (seems the only diff is the select clause)

The tests are adapted tests from the standard SPARQL test suite and,
indeed, the only difference is the SELECT * versus SELECT ?var clause.
Nevertheless it might be useful to test that since some entaiment
implementations probably don't run the standard tests (e.g., most test
data cannot be used with OWL's Direct Semantics).

> bind07 ... don't understand, the bind07.srx file has no bindings for z at all. shouldn't this have for each ?o two entries, one binding z to o+1
> and one to o+2?!

No. This is due to the definition of the BIND semantics (see 18.2.2.6
of the Query spec): "Each BIND element is translated to an extend
algebra operator where the graph pattern is the immediately preceding
basic graph pattern. If the immediately preceding syntax element is
not a TriplesBlock, an empty basic graph pattern is introduced. "

In this case the query pattern is:
 ?s ?p ?o .
  ?p a owl:DatatypeProperty .
  { BIND(?o+1 AS ?z) } UNION { BIND(?o+2 AS ?z) }

In the algebra translation, we first translate a GroupGraphPattern and get:
Join(Z, Bgp(?s ?p ?o . ?p a owl:DataProperty))
simplified to:
Bgp(?s ?p ?o . ?p a owl:DataProperty)

Then we have to translate a GroupOrUnionGraphPattern. This means we
start with an empty algebra element A and then have to translate the
BIND element. Since A is empty, we introduce empty graph pattern for
the bind translation. This happens again when we translate the second
element of the union clause and overall we get:
Join(
    Bgp(?s ?p ?o . ?p a owl:DatatypeProperty),
    Union(
      Extend(Z, ?z, ?o+1),
      Extend(Z, ?z, ?o+1)
    )
)
We separately evaluate the Bgp(.) and the Union(.) elements and then
join the results. The Union(.) element, however, just gives the empty
mapping since we cannot extend ?o from an empty mapping. Joining then
gives the results as given in the test.

Note that this test is again just copied over from the standard test
suite and made suitable for OWL's Direct Semantics by adding typing
triples. Should the test be wrong, then also all standard SPARQL
systems should not pass it.

> lang ... looks ok, small remark: why is it called "lang" whereas the mf:name says "Literal lang test 2", I suppose because "lang test 1" is actually :plainLit?

Yes. This is a test I got from C&P and since I already had this plain
literal test named plainLit with all the files named plainLang.xxx, I
just added the index 2. I cleaned this up now and we have now
plainLit.rq, plainLit.srx and plainLit.ttl for the test plainLit and
lang.rq, lang.srx and lang.ttl for the lang test.


> paper-sparqldl-Q1 ... looks ok, it would be nice to have an RDFS variant of thant one that does NOT return owl:Nothing, additionally.
done (paper-sparqldl-Q1-rdfs)

-- 
Jun. Prof. Dr. Birte Glimm            Tel.:    +49 731 50 24125
Inst. of Artificial Intelligence         Secr:  +49 731 50 24258
University of Ulm                         Fax:   +49 731 50 24188
D-89069 Ulm                               birte.glimm@uni-ulm.de
Germany

Received on Monday, 8 October 2012 10:56:41 UTC