Skip to content
Damion Dooley edited this page Jun 23, 2023 · 14 revisions

To edit FoodOn

The /src/ontology/foodon-edit.owl is the main OWL file to be edited using Protege or by hand. Files in /src/ontology/imports/ folder that can be edited by hand are the Ontofox specification files (ending in .txt) which prepare the import of terms from other OBOFoundry.org ontologies into the corresponding [ontology]_import.owl files.

To build (regenerate) the FoodOn release files

  1. Open a linux terminal and cd to the FoodOn github repo's /src/ontology/ folder
  2. type "make" to generate the /src/ontology/foodon.owl file. This also updates any /imports/ .owl files based on changes to their [ontology]_ontofox.txt specification files - according to a list given in the Makefile file.
  3. type "make prepare_release" to generate the root folder foodon.owl file and copy all the /src/imports/ .owl files to the main /imports/ folder.

Encountering bad RDF datatype literal values

If when running make or when running "robot" directly you encounter obscure robot OWLAPI errors such as "java.lang.IllegalArgumentException: URI is not absolute", install Apache jena and use the "riot" command to validate an owl/xml version of foodon-edit.owl. (For Mac users, to install riot, use "> brew install jena"). In Protege, save a copy of foodon-edit.owl (which is in rdf/xml syntax) to an owl/xml syntax as foodon-validate.owl :

riot -v --validate foodon-validate.owl

After a successful make build, you can test that robot is able to read genepio correctly via:

robot convert -i foodon-merged.owl -o foodon.json

Clone this wiki locally