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

Improve turtle style #93

Closed
wants to merge 2 commits into from

Conversation

cthoyt
Copy link
Contributor

@cthoyt cthoyt commented Oct 18, 2023

Nico asked me to double check the content in #88 (comment) and I realized that the turtle was very difficult to read. This PR updates the way the turtle is output (but not its content).

It mostly rearranges indentation and where semicolons ; are put. A notable change is I use nested objects for dbxrefs, which reduces some more visual clutter such as in

NCBITaxon:121616 a owl:Class ;
    rdfs:label "Micromonospora matsumotoense"^^xsd:string ;
    rdfs:subClassOf NCBITaxon:1873 ;
    ncbitaxon:has_rank NCBITaxon:species ;
    oboInOwl:hasDbXref "PMID:8897428"^^xsd:string ,
        "PMID:8897428"^^xsd:string ,
        "PMID:10499285"^^xsd:string ,
        "GC_ID:11"^^xsd:string ;
    oboInOwl:hasOBONamespace "ncbi_taxonomy"^^xsd:string .

I checked with python3 src/ncbitaxon.py build/taxdmp.zip ncbitaxon.ttl and robot convert -i ncbitaxon.ttl -o ncbitaxon.owl that this still makes valid and correct turtle that can be converted to OWL

@jamesaoverton
Copy link
Collaborator

The new output looks nicer, but it's an exaggeration to say the old output is "very difficult to read".

It's good that this PR doesn't break the syntax (your robot convert check). It's also important to check that it doesn't change the content.

@anitacaron
Copy link
Contributor

@cthoyt Can you fix the conflict, please?

@cmungall cmungall closed this Jul 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants