Skip to content

Conversion of portion of Langual XML thesaurus to foodon ontology

Notifications You must be signed in to change notification settings

IC-FOODS/foodon-langual

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This project is an ALPHA version of the upcomming FoodOn ontology. It is mainly based on a conversion of the LanguaL.org XML thesaurus facet data, integrated with OBOFoundry terms from UBERON, ChEBI, and NCBITaxon and others. The approach allows LanguaL(tm)'s thesaurus file to be updated over time, and the owl file to be updated as needed.

##To view

Briefly, the main file to look at is foodon.owl (in Protege or another OWL ontology editor); it should import the ncbitaxon_import.owl and other imports/ files too. Use Stanford's free Protege ontology editor to load the main file, and browse the Langual hierarchy under the "Classes" tab. It should also be viewable on https://www.ebi.ac.uk/ols/ soon too.

##To edit

The /src/ontology/foodon-edit.owl and many /src/ontology/imports/ files can be edited using Protege or by hand. Note however that the uberon, ncbitaxon, and chebi ontofox .txt specification files are actually generated from templates in the /src/ontology/imports/langual/ folder, so add to those templates if you want additions to uberon, ncbitaxon and chebi.

##To regenerate the files

foodon.owl is generated by the make command when one is in the /src/ontology/ folder.

To redo the LanguaL LanguaL2014.XML file import, first issue a "python langual.py" command when in the /src/ontology/imports/langual/ folder. This compares the XML file's contents to the database.json import control data structure, adds new content and state information to the json database, and then writes the OWL file as well as an OntoFox compatible /src/ontology/imports/ncbitaxon_ontofox.txt , uberon_ontofox.txt, chebi_ontofox.txt files. The database.json file holds a representation of the LanguaL XML file contents, along with value overrides. It is created with some input from lookup.txt, which maps certain LanguaL entries over to their equivalents in other OBOFoundry ontologies; these overrides are then added to the template .txt files to create the /imports/ folder OntoFox files. A "make" command consults OntoFox to convert those files into .owl import files.

Then change directory to the "/src/ontology" folder, and run "make". That will fetch the ontofox updates if need be, producing new XYZ_import.owl files.

langual.py may need a few python modules loaded up. It can take a number of minutes to generate if database.json is already established; it will take much longer to run if database.json has been deleted since it fetches NCBITaxon related information using the EOL.org API (in batches)

About

Conversion of portion of Langual XML thesaurus to foodon ontology

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages