Role of Ontology
JThermodynamicsCloud is software service for the chemical, or more specifically, the combustion research domain. The complete service is a system with three interacting components, a user interface using Angular, a (RESTful) backend written in JAVA and the Google Firestore noSQL document database and Firebase storage. The service uses these three components to make calculations for thermodynamic quantities based on molecular species structure. The calculation itself is highly dependent on the varied types of molecular data found in the database.The primary purpose of the system is to perform the calculation and manage the data needed to make the calculation.
JThermodynamicsCloud service can be said to be an ontology driven application. The three components and the data management within these services are based on different platforms, the interface is Angular based on typescript, the RESTful backend services are written in JAVA using JSON objects for data structures and the database is Google Firestore. These different platforms are united through the ontology. All definitions and methodologies within all three systems of the service have a corresponding ontology classes. This means that communication between systems also has an ontology reference. In particular the data structures. This is particularly important because the data structure forms in each of the systems are in a free format of property name and untyped value pairs. The ontology provides the underlying structure by defining the property name and the information that field contains. The ontology definitions are translated to the exact data structures within each of the respective systems. In all systems, the data structure is a JSON like data structure.
The ontology as used by the service has three distinct purposes:
Documentation: Through annotations and the hierarchy of ontology classes a level of documentation is provided that is not inherently present within the software definitions. Through the class hierarchy a context is given to each object and through annotations are human and machine readable documentation.
Data Structure Definition: Every data object in JThermodynamicsCloud has a respective ontology definition. This gives a common reference for how each data structure is translated in the different software components of the system. Since the definition is machine readable, this allows a certain amount of automation, for example in the user interface, to take place. For the software engineer, this common reference provides the template for accessing data from the data structures which is not otherwise present because the data structures themselves are inherently non-typed and free format.
Operational Definitions: In addition to data structures within the system, there are also sets of algorithms using these data structures. Certain classes of algorithms have corresponding ontology definitions. For example, all RESTful services have a corresponding ontology definition. In addition, within the background system, certain classes of working algorithms (programmed using the enumeration class in JAVA) have ontology definitions. These are often associated with pull-down list choices within the interface or specific related manipulations dependent on classes of data types.
Motivations and Use of Ontologies
The ontology is used throughout the system in multiple capacities:
JSON data object definitions: The JSON representation is used throughout JThermodynamicsCloud. However, JSON is a an untyped and free-format language, meaning that the only information about the fields in the JSON object are the names. Use of ontologies provides context and documentation of the fields within the JSON objects. The ontology is what defines the type of the data object within the free-format context.
RESTful Service Definition: The functionality of JThermodynamicsCloud are accessed through the RESTful services. The RESTful service ontology is used to provide context, through a hierarchy of definitions and within each class definition, the input and output objects expected from the restful service. In addition, annotations to each class give further documentation. These are defined in a subclass of dataset:DatabaseServicesBase which is a subclass of the prov:Software Agent (of the PROV ontology).
Transaction Description: Transactions are another type of RESTful services which modify the database (as opposed to services which perform only queries on the ontology and the database). In the ontology
Database Structure Hierarchy: The noSQL document database of JThermodynamicsCloud is a hierarchy of collections and documents. All catalog objects are 'documents' (in the sense of the noSQL database) located at the end root nodes of the hierarchy. The hierarchy position of the collection of catalog objects types give a context to the objects. The database definition ontology is used to define this hierarchial structure. Within this definition is which catalog object type is being defined and how the nodes leading to the catalog object are to be named. These are defined in a subclass of dataset:CollectionDocumentHierarchy which is a subclass of the skos:Concept (of the SKOS ontology).
Classification Components: Some single string valued components (in the sense of the DCAT ontology definition) represent classifications (enumerations) with specific values. The ontology definition of the component points to the top of a hierarchy (for a tree classification) or the top of a set of subclasses (for a list). In the annotations of these subclasses are labels and comments that can be used for the user interface (and documentation). The subclasses can components, if the selection should be, for example types or even records or catalog object (in the sense of the DCAT ontology).
Implementation Operations by type: Often within the implementation there are set of similar operations, with the same input, but different functionalities based on type. In JAVA this is an enumeration with abstract methods. These are defined in a subclass of dataset:DataObjectManipulation which is a subclass of the prov:Software Agent (of the PROV ontology).
Units: An important aspect of scientific numerical data is units. JThermodynamicsCloud uses the QUDT ontology to enable the transformation of one unit to another. In general, the original units, i.e. that of the source data, are stored in the database. In the calculation and presentation, the user can choose the preferred units. The QUDT ontology includes all the transformation parameters needed.
Templates: Some catalog objects and records within the catalog objects are general structures and specific instances can be setup using templates defined in the ontology. The advantage of this design is that the specific domain instantiation is delegated to the ontology and not in the software implementation. This makes the software more general and adds flexibility in adding new domain information.