Creating New Reasoner/Translator Pairs

Last revised 10/21/2020.

As described here, the SADL architecture supports pluggable reasoner/translator pairs. This document describes the creation of such a reasoner/translator pair.

Requirements

In order to work correctly in the SADL IDE, a reasoner/translator pair must meet the following requirements. The SADL project com.ge.research.sadl.swi-prolog-plugin implements such a pair and may be used as an example.

  1. There must be a reasoner class that implements the com.ge.research.sadl.reasoner.IReasoner Java interface class or which extends the com.ge.research.sadl.reasoner.Reasoner class which implements that interface.
  2. There must be a translator class that implements the com.ge.research.sadl.reasoner.ITranslator Java interface class
  3. The reasoner class and the translator class must be compatible in that the translator produces output of a type and syntax which can be used by the reasoner.
  4. The Eclipse project for the translator/reasoner pair should have a META-INF folder with:

It is recommended that the Eclipse project be a Maven project and that the pom.xml file create the "services" folder and its content on build, as illustrated in the com.ge.research.sadl.swi-prolog-plugin project. The result of a Maven build should be a jar file that includes everything needed for the reasoner/translator pair to be found and used by a Java Service Provider and a Java class loader. When this is the case the jar need only be placed on the class path for the reasoner/translator pair to appear in a SADL project's SADL properties and selected as the active reasoner/translator pair.

For easier distribution and installation, it is recommended that the project be a Eclipse plug-in project with an Activator class. An associated feature project and update project can make the reasoner/translator pair easy to download and install in Eclipse.

For use in the SadlServer knowledge delivery environment, the jar file need only be on the Java classpath. The reasoner/translator pair to be used by SadlServer are identified by ReasonerFamily and ReasonerCategory attributes in the "configuration.rdf" file in the OwlModels knowledge base folder.