linkml / schema-automator

Automated assistance for the schema development lifecycle
https://linkml.io/schema-automator/
BSD 3-Clause "New" or "Revised" License
33 stars 12 forks source link

OWL language tags not escaped #125

Open sneakers-the-rat opened 5 months ago

sneakers-the-rat commented 5 months ago

Describe the bug

OWL (and I think a lot of linked data formats?) functional notation language allows a languageTag following a string, but they are not escaped when translating from OWL

Source owl (turtle)

as:Activity a owl:Class ;
  rdfs:label "Activity"@en ;
  rdfs:subClassOf as:Object ;
  rdfs:comment "An Object representing some form of Action that has been taken"@en .

OWL converted to functional syntax with robot per the docs:

# Class: as:Activity (Activity)

AnnotationAssertion(rdfs:comment as:Activity "An Object representing some form of Action that has been taken"@en)
AnnotationAssertion(rdfs:label as:Activity "Activity"@en)
SubClassOf(as:Activity as:Object)

Linkml:

classes:
  Activity:
    comments:
    - An Object representing some form of Action that has been taken@en
    is_a: Object

To Reproduce

schemauto import-owl activitystreams2.ofn -o ./activitystreams.yaml

Expected behavior

Not include the language tag! I'm not sure how linkML handles language information, ideally it would be preserved, but in any case not concatenated with the string :)