Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change rdfs:Literal to rdf:PlainLiteral #405

Closed
VladimirAlexiev opened this issue Nov 6, 2022 · 6 comments
Closed

change rdfs:Literal to rdf:PlainLiteral #405

VladimirAlexiev opened this issue Nov 6, 2022 · 6 comments
Assignees
Labels
act: for closing it can be closed but an additional confirmation is needed act: for implementation it can be implemented and closed, all is clear module: none no module in particular because the issue is of technical or documentation nature type: feature request something requested to be implemented in a future release
Milestone

Comments

@VladimirAlexiev
Copy link

You use rdfs:Literal for string fields. However, that datatype is overly wide. You won't be happy about a company name having values like:

  • "2022-11-06"^^xsd:date
  • "POINT(10 20)"^^geo:wktLiteral
  • or even "<html><title>foo bar</title></html>"^^rdf:XMLLiteral

Please use rdf:PlainLiteral instead, which in effect is a union of xsd:string and rdf:langString.
See the spec: https://www.w3.org/TR/rdf-plain-literal/

@andreea-pasare andreea-pasare added this to the 2023 Q1 milestone Jan 10, 2023
@andreea-pasare andreea-pasare self-assigned this Feb 23, 2023
@andreea-pasare andreea-pasare added type: feature request something requested to be implemented in a future release act: for implementation it can be implemented and closed, all is clear module: none no module in particular because the issue is of technical or documentation nature labels Feb 23, 2023
@AchillesDougalis
Copy link
Contributor

In the glossary of ePO 4.0.0 there are only rdf:PlainLiteral and not rdfs:Literal.

@AchillesDougalis AchillesDougalis added the act: for closing it can be closed but an additional confirmation is needed label Jan 26, 2024
@VladimirAlexiev
Copy link
Author

https://github.com/search?q=org%3AOP-TED+rdfs%3ALiteral&type=code shows 30 occurrences of rdfs:Literal:

  • in model2owl configurations (cc @costezki )
  • in SHACL shapes, eg epo:hasShippingMark, epo:concernsBeneficiary, foaf:name

Commits that make such a change:

  • 5052225 modifies analysis_and_design/conceptual_model/ePO_CM.eap but I don't know what is its effect
  • 65b01ac is a hotfix to just one field.

@AchillesDougalis , you trust that Glossary too much! Please reopen.

@andreea-pasare
Copy link
Collaborator

@VladimirAlexiev, indeed, we do have some occurrences of rdfs:Literal in all OP-TED repositories, and in ePO we only have it mentioned in the model2owl-config folders, in config-parameters.xsl files (https://github.com/search?q=repo%3AOP-TED%2FePO++rdfs%3ALiteral&type=code). Those are variables that are not used anymore by model2owl when generating the RDF outputs for ePO.

We do want to have a proper clean-up of the entire model2owl configuration files in the ePO repository in a future release and it will be tracked in a separate discussion: #588 (from which we will create an appropriate github issue once we get started). So thank you for this feedback, I will make sure to add it in our discussion.

Regarding the other issue (#447) it was converted into a discussion, but in my opinion we should also close that since it became a discussion about a different repository (https://github.com/OP-TED/ted-rdf-mapping) and an appropriate issue to track it was created: OP-TED/ted-rdf-mapping#407.

@VladimirAlexiev
Copy link
Author

VladimirAlexiev commented Apr 2, 2024

@andreea-pasare

in ePO we only have it mentioned in the model2owl-config folder

That's not true, there are numerous semantic files with this defect. Here are the number of occurrences:

  • 16 src/validation/shacl/epo/eCatalogue_shacl_shapes.ttl
  • 99 src/validation/shacl/epo/ePO_shacl_shapes.ttl
  • 1 src/validation/shacl/epo/eOrdering_shacl_shapes.ttl
  • 86 test/reasoning-investigation/model-2020-12-16/epo-restrictions(-[124])?.ttl

There are also numerous occurrences in EA.html files, i.e. directly in the UML models (cc @costezki).

I'm happy if this will be addressed in OP-TED/ted-rdf-mapping#407

@andreea-pasare
Copy link
Collaborator

@VladimirAlexiev, the files mentioned above are not part of the ePO repository and:

  • the files having src/validation/shacl/epo path come from ted-rdf-mapping project where they have old ePO files that were used for validation purposes (last commit being last year),
  • while the last path test/reasoning-investigation/model-2020-12-16/ is from a test folder of model2owl project (last commit being 3 years ago).

Thank you for catching this :) Both of those projects would benefit from having general "clean-up repository" tickets as we have in ePO, so I will make sure to sync with them on this topic.

@VladimirAlexiev
Copy link
Author

Thanks for the clarification! For the record, here are the occurrences of rdf:PlainLiteral:

  • 1 implementation/eCatalogue/owl_ontology/eCatalogue.ttl
  • 11 implementation/eCatalogue/owl_ontology/eCatalogue_restrictions.ttl
  • 14 implementation/eCatalogue/shacl_shapes/eCatalogue_shapes.ttl
  • 1 implementation/eContract/owl_ontology/eContract.ttl
  • 2 implementation/eContract/owl_ontology/eContract_restrictions.ttl
  • 2 implementation/eContract/shacl_shapes/eContract_shapes.ttl
  • 1 implementation/eFulfilment/owl_ontology/eFulfilment.ttl
  • 10 implementation/eFulfilment/owl_ontology/eFulfilment_restrictions.ttl
  • 13 implementation/eFulfilment/shacl_shapes/eFulfilment_shapes.ttl
  • 1 implementation/eNotice/owl_ontology/eNotice.ttl
  • 1 implementation/eOrdering/owl_ontology/eOrdering.ttl
  • 6 implementation/eOrdering/owl_ontology/eOrdering_restrictions.ttl
  • 7 implementation/eOrdering/shacl_shapes/eOrdering_shapes.ttl
  • 1 implementation/ePO_core/owl_ontology/ePO_core.ttl
  • 97 implementation/ePO_core/owl_ontology/ePO_core_restrictions.ttl
  • 100 implementation/ePO_core/shacl_shapes/ePO_core_shapes.ttl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
act: for closing it can be closed but an additional confirmation is needed act: for implementation it can be implemented and closed, all is clear module: none no module in particular because the issue is of technical or documentation nature type: feature request something requested to be implemented in a future release
Projects
None yet
Development

No branches or pull requests

3 participants