innoq / iqvoc

iQvoc - A SKOS(-XL) Vocabulary Management System for the Semantic Web
http://iqvoc.net/
Other
117 stars 44 forks source link

Second import repeats labels #438

Open EwaSniegowskaPCSS opened 2 years ago

EwaSniegowskaPCSS commented 2 years ago
  1. I import data. Example data:
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2004/02/skos/core#Concept> .
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/2004/02/skos/core#topConceptOf> <https://opensubjects.org/terms/scheme> .
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/2004/02/skos/core#inScheme> <https://opensubjects.org/terms/scheme> .
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/2004/02/skos/core#prefLabel> "klocek LEGO"@pl .
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/2004/02/skos/core#altLabel> "klocuszek LEGO"@pl .
    <https://opensubjects.org/terms/lego_brick> <http://www.w3.org/2004/02/skos/core#prefLabel> "LEGO brick"@en .
  2. I import same data again. No new concepts added (expected). Preferred and alternative labels in concepts are duplicated (not expected). I attach the screenshot. doublelabels
  3. I export data. Labels are also duplicated in exported data (not expected, but not a big problem).

I think adding new labels for alreading existing concepts is useful, for example if you enriched the imported data with new labels, from new languages, etc. But duplicating labels is not necessary, it also causes problems with consistency check for a concept. You get errors:

"The alternative label %{label} is used twice."
"There must be only one preferred Label per language."

I think it would be better if iQvoc compared strings during import and not added duplicated labels (maybe if preferred label does not match it should be overriden?).

Is the described behaviour intended or it needs fixing?