Re: ISSUE-95: Proposed simplification and clean up of template mechanism

Holger,

Yes, we need a concrete vocabulary syntax for this. But first I wanted
to lay out the concept in general terms for the WG to discuss.

-- Arthur

On Wed, Nov 11, 2015 at 11:37 PM, Holger Knublauch
<holger@topquadrant.com> wrote:
> On 11/12/15 2:24 PM, Arthur Ryman wrote:
>>
>> The current draft uses the following design:
>>
>> 1. sh:Template is the meta-class of all templates.
>> 2. a resource of type sh:Template is a template. Each template is
>> itself a class. The template itself introduces a new set of properties
>> that parameterize the template. These are referred to as the
>> sh:Arguments of the template.
>> 3. a resource of type template is a constraint. i.e. constraints are
>> viewed as instances of templates using the property rdf:type to
>> indicate the action of instantiating a template.
>>
>> I feel that the relation between a template and the thing produced by
>> inserting actual values for the formal arguments of the template is
>> not correctly modelled by rdf:type. For example, an OO language like
>> Java has no difficulty implementing templates, but there are no
>> meta-classes in Java. An instance of a template class simply produces
>> instances of some other class.
>>
>> I feel that people have an easier time understanding models in which
>> meta-classes are absent. This is the idea behind OWL and description
>> logic in which things are either classes, properties, or individuals.
>>
>> I propose a flattened model in which there are no meta-classes.
>>
>> 1. sh:Template is the class of all templates.
>> 2. a resource of type template is not a class. Instead, it has a
>> property that gives the type of constraint that the template produces,
>> e.g. sh:produces.
>> 3. when the properties introduced by a template are used in a
>> constraint, that constraint acquires the additional type specified by
>> the sh:produces property of the template.
>
>
> I believe with that design we would lose the ability to use SHACL to
> describe its own documents, e.g. to validate shapes graphs and to drive user
> interfaces. The comparison to Java is not a strong argument - even OWL and
> RDFS use metaclasses.
>
> I also believe that the complexity of this topic means that it is not
> sufficient to just give some high-level design suggestions. Unless I am
> mistaken, you had said you would work on a specific data model, i.e. a
> specific turtle file. If that's the case, then I would appreciate seeing
> such a file. If not, I'd suggest we decide on a time frame so that we can
> eventually move on.
>
> Thanks,
> Holger
>
>

Received on Thursday, 12 November 2015 04:49:13 UTC