[Pellet-users] Internal Triple Representation of owl:unionOf (a b) as rdf:List
Evren Sirin
evren at clarkparsia.com
Mon Feb 11 00:09:50 UTC 2008
On 2/7/08 5:31 AM, Wolfgang May wrote:
> Hi,
>
> constructs like
> :Person a owl:Class; owl:unionOf (:Male :Female).
> are translated to collections/rdf:List constructs.
> Although, pellet seems not to "know" that this these things are
> rdf:Lists:
>
> ***
> @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
> @prefix owl: <http://www.w3.org/2002/07/owl#>.
> @prefix : <foo://bla/>.
>
> :Male a owl:Class.
> :Female a owl:Class.
>
> :Person a owl:Class; owl:unionOf (:Male :Female).
> :EqToPerson a owl:Class;
> owl:unionOf
> [ a rdf:List; rdf:first :Male;
> rdf:rest [ a rdf:List; rdf:first :Female; rdf:rest rdf:nil]].
> :x a :Person.
> ***
>
> ***
> prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> prefix owl: <http://www.w3.org/2002/07/owl#>
> prefix : <foo://bla/>
> select ?X ?Y ?Z
> from <file:union-list.n3>
> where {?X rdf:first ?Y . OPTIONAL {?X rdf:rest ?Z}}
> ***
>
> results -as expected- in
>
> --------------------------------------------------------------------------------
> | X | Y | Z
> ================================================================================
> | _:b0 | <foo://bla/Male> | _:b1
> | _:b2 | <foo://bla/Male> | _:b3
> | _:b3 | <foo://bla/Female> | <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> |
> | _:b1 | <foo://bla/Female> | <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> |
> --------------------------------------------------------------------------------
> Successfully printed 4 query results.
>
> But, if I ask whether ?X is a list, the answer to
>
> ***
> prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> prefix owl: <http://www.w3.org/2002/07/owl#>
> prefix : <foo://bla/>
> select ?X ?Y ?Z
> from <file:union-list.n3>
> where {?X a rdf:List; rdf:first ?Y . OPTIONAL {?X rdf:rest ?Z}}
> ***
>
> is only
>
> --------------------------------------------------------------------------------
> | X | Y | Z
> ================================================================================
> | _:b0 | <foo://bla/Female> | <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> |
> | _:b1 | <foo://bla/Male> | _:b0
> --------------------------------------------------------------------------------
> Successfully printed 2 query results.
>
>
> Obviously, for
> owl:unionOf (...)
> the list *structure* is generated, but rdf:type rdf:List
> is not assigned.
>
> Is there a reason for this
The lists used inside concept expressions are part of the built-in
syntax and are not treated part of the data (ABox). The above queries
simply query the asserted triples and that is why second query returns
less answers.
> (from a previous post, I already learnt
> that rdf:first and rdf:rest cannot be used for reasoning)?
In OWL-DL, it is forbidden to use rdf:Lists outside built-in syntax
elements. This is not a necessary restriction and it is possible that
these restrictions will be relaxed in OWL 1.1 (see the use case I
proposed in the OWL WG regarding this [1]). There is still the problem
of rdf:first being both an object and data property which can be solved
by punning.
> It would
> be nice for some applications (e.g. analysis of ontologies) to
> have access to these properties for querying and processing
> collection-based concept definitions.
>
We'd be interested in hearing such use cases. These use cases help us in
the OWL WG discussions.
Cheers,
Evren
[1]
http://www.w3.org/2007/OWL/wiki/Punning#Lists_.28ObjectProperty_.E2.86.94_DatatypeProperty.29
> Best,
> Wolfgang
> _______________________________________________
> Pellet-users mailing list
> Pellet-users at lists.owldl.com
> http://lists.owldl.com/mailman/listinfo/pellet-users
> _______________________________________________
>
> Sponsored by Clark & Parsia, LLC http://clarkparsia.com/
>
More information about the Pellet-users
mailing list