Re: Shapes - sub-classes / sub-properties

On Thu, Jul 17, 2014 at 4:08 PM, Jose Emilio Labra Gayo <jelabra@gmail.com>
wrote:

>
>>>>> For example, I have found Shape Expressions are very helpful to
>>> specify the contents of the RDF graphs that I want to publish, so I can
>>> tell my team of developers that they have to produce graphs with those
>>> shapes...also, I have found that data portals documented with Shape
>>> Expressions can help consumers to know which are the shapes of the RDF
>>> graphs behind them.
>>>
>>
>> I don't see any drawback in term of readability for data consumers (there
>> might be some typos) e.g.
>> <Agent> {a foaf:Agent, foaf:mbox xsd:string}
>> <Person> {a foaf:Person, foaf:surname rdf:langString, foaf:firstName
>> rdf:langString}
>>
>> compared to
>> <Agent> {a foaf:Agent, foaf:mbox xsd:string}
>> <Person> & <Agent> {a foaf:Person, foaf:surname rdf:langString,
>> foaf:firstName rdf:langString}
>>
>> There can also be a special notation when we want to match subClasses
>> e.g. [foaf:Agent] or anything else that might fit in the relaxng syntax
>>
>>
> Reading your message, I think that I may have misunderstood your first
> question in this thread. Were you asking about sub-shapes or how we could
> extend one shape from another?
>
> In that case, there is already a proposal on that by Eric Prud'hommeaux
> and his Javascript implementation already supports it. In the case of
> Shexcala, I still didn't implement it, but I am planning to do it in the
> future.
>

No, I have already seen the subshapes definition in ShEx primer [1]

in my example :
<Agent> {a foaf:Agent, foaf:mbox xsd:string}
<Person> {a foaf:Person, foaf:surname rdf:langString, foaf:firstName
rdf:langString}

my point was that (if we infer types on validation) having a foaf:Person
without an mbox should not validate
or a separate notation could be used to mark this intention. e.g.

<Agent> {a `foaf:Agent`, foaf:mbox xsd:string}
<Person> {a `foaf:Person`, foaf:surname rdf:langString, foaf:firstName
rdf:langString}

this is random syntax choice but  `foaf:Agent` (enclosed by ``) could mean:
do type inferencing and apply to all sub classes of foaf:Agent, even if
they are not explicitly stated in the graph.
Depending on the implementation, someone could run an rdfs reasoner before
validation or try to use SPARQL property paths directly.

Best,
Dimitris

[1] http://www.w3.org/2013/ShEx/Primer


> Best regards, Jose Labra
>



-- 
Dimitris Kontokostas
Department of Computer Science, University of Leipzig
Research Group: http://aksw.org
Homepage:http://aksw.org/DimitrisKontokostas

Received on Thursday, 17 July 2014 14:19:46 UTC