LexEVS 6.x provides two methods to export loaded ontologies to an OWL/RDF format. One is to use the LexEVS administration GUI; and the other is to use an export script on the command line.
- The OWL/RDF exporter is based on Jena 2.6.3. While it exports an OWL file, it also builds up a triple store. The triple store tables stored in the same same database that LexEVS uses.
- The LexEVS 6.0 retrieval API has the limitation of retrieving the association that is from an entity to a data/value. Thus, the OWL/RDF exporter, based on LexEVS retrieval API, has the limitation of handling the owl:hasValue, owl:maxCardinality, owl:minCardinality, owl:cardinality constraints as well.
The OWL/RDF exporter now can convert OWL, RDF, OBO, and UML formats to OWL/RDF. If the terminology format is not on this list, the exported OWL ontology may be incorrect.
Note that OWL2 is not currently supported, nor is an export to the OWL2 format. Much of what is loaded to LexEVS is currently OWL2, and cannot be exported. See JIRA Item LEXEVS-3661
Running an OWL/RDF Export with the Administration GUI
If you chose to install the LexEVS GUI when you installed LexEVS, you will have a 'gui' folder inside of your LexEVS home directory. Assuming you installed the GUI for all operating systems, you will have the following programs under the 'gui' folder:
1. Launch the GUI by executing the appropriate executable for your platform. You will be presented with an application that looks like this. If the Available Code System table is empty, you will need to load at least one ontology.
2. Selecting 'Enable Admin Options' provides administrative access to all commands.
3. Select an active terminology (if the code system status is 'inactive', you can use the Activate button to activate it). Click on 'Export as OWL/RDF' button on the 'Export Terminology' menu, the exporter window will pop up.
Running an OWL/RDF Export Script from the Command Line
After installing LexEVS, you will have an 'admin' folder inside of your LexEVS base installation. The OWL/RDF exporter shell script is in the following folder (for Linux or Windows):
This command will export OWL/RDF without a GUI. For detailed information please refer to the command line parameters for this command in the Administration Guide.
Administration GUI export walk-through example
This walk through will show you how to load a terminology and then export it in OWL/RDF format.
1. Launch the administration GUI.
2. Enable the administration option.
3. In this example, we use the cell.obo ontology as the example ontology, so we choose OBOloader.
4. Provide cell.obo file's path. If you don't have a manifest file or preferences file then leave these fields blank. Click on the 'Load' button. After a few minutes, the loading process is done. You can find 'End State: complete' in the Output message box. Close this window, and return to the administration GUI, a 'cell' record should show up on the Available Code Systems list.
5. Select the cell ontology row and click the 'Activate' button. The status column of 'cell' should change to active.
6. Make sure the cell ontology is still selected. Go to the 'Export Terminology' menu, click on 'Export as OWL/RDF' in the drop down menu.
7. Provide a path in the 'URI' text box. The exported file name is automatically generated by the system, so we don't need to specify the file name. Click on the 'Export' button.
8. A set of status messages will show up in the Output text box. When the 'End State: completed' statement pops up, the exporting process is complete.
9. The convention of the exported file name is: <coding system name>_<version>.owl. In this example, cell ontology has no version information, so 'UNASSIGNED' is used as the version. The name of the OWL file in this case will be cell_UNASSIGNED.owl and it is in the C drive's root directory.
Command Line Script Exporting Example
We still use the cell.obo as our example ontology and assume that it has been loaded already. It is straightforward to run a command like this instead of using the GUI:
A set of statements will show up, like the following, if it runs successfully:
A file named "cell_UNASSIGNED.owl" will be generated and saved under the specified path. The content of this file is the same as the file generated by the administration GUI.