Skip to content

wrong semantic modeling in GS1DigitalLinkCompressionPrototype #38

@VladimirAlexiev

Description

@VladimirAlexiev

Picking up from #33.
@mgh128 (cc @philarcher )
Notes on the semantic modeling implicit in https://gs1.github.io/GS1DigitalLinkCompressionPrototype/
I understand it's just a prototype but I'd rather speak up now than later.

  • Go to last section and input this in GS1 Digital Link URI: http://example.org/01/05412345000013/21/ABC%26%2B123?7003=1903061658
  • save as DL-example.jsonld
  • convert to Turtle:
<http://example.org/01/05412345000013/21/ABC%26%2B123>
        rdf:type                schema:Product , owl:Class , gs1:Product , rdfs:Class ;
        rdfs:subClassOf         <http://example.org/01/05412345000013> ;
        dcterms:isPartOf        <http://example.org/01/05412345000013> ;
        schema:gtin             "05412345000013" ;
        owl:sameAs              "http://example.org/01/05412345000013/21/ABC%26%2B123?7003=1903061658" ;
        gs1:elementStrings      "(01)05412345000013(21)ABC&+123(7003)1903061658" ;
        gs1:expirationDateTime  "2019-03-06T16:58:00"^^xsd:dateTime ;
        gs1:gtin                "05412345000013" ;
        gs1:hasSerialNumber     "ABC&+123" .
  1. Modeling Product (and ProductBatch) as RDF classes and using subClassOf is questionable
    • Will lead to an uncontrollable proliferation of classes
    • Will mix up the defined hierarchy (eg gs1:WearableProduct<gs1:Product) with these uncontrolled classes
    • Goes against schema.org practice
    • Is certainly wrong for the above thing which is an IndividualProduct (because it hasSerialNumber)
  2. I also don't quite like dct:isPartOf. I think it's better to use specific props. Eg I've used schema:model, but maybe a new gs1:product is better:
<$SGTIN_PRODUCT1> a gs1:IndividualProduct;
  schema:model <$GTIN_PRODUCT1>;
  gs1:gtin "$GTIN1";
  gs1:hasSerialNumber "$SERIAL1".
<$LGTIN_PRODUCT2> a gs1:ProductBatch;
  schema:model <$GTIN_PRODUCT2>;
  gs1:gtin "$GTIN2";
  gs1:hasBatchLotNumber "$LOT2".
<$GTIN_PRODUCT1> a gs1:Product;
  gs1:gtin "$GTIN1".
<$GTIN_PRODUCT2> a gs1:Product;
  gs1:gtin "$GTIN2".
  1. owl:sameAs is not declared @id, that's why it's value is a string but must be a resource (URL)
  2. Using sameAs means that a Product/Batch/Individual with extra details is the same as the basic thing without these details, therefore it is an error to use the same GTIN/LGTIN/SGTIN with different sets of details.
<http://example.org/01/05412345000013/21/ABC%26%2B123>
        owl:sameAs   <http://example.org/01/05412345000013/21/ABC%26%2B123?7003=1903061658>;
        owl:sameAs   <http://example.org/01/05412345000013/21/ABC%26%2B123?7003=2103061658>. ## error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions