SWRLDroolsTab

Zippyrate edited this page Apr 3, 2015 · 8 revisions
Clone this wiki locally

The SWRL Drools Tab is a graphical environment provided by the SWRLAPI that supports the execution of SWRL rules using the Drools rule engine.

Table of Contents

Installation

This tab is included as part of the standalone SWRLTab and by the SWRLTab Plugin so does not need to be installed separately.

Activation

The SWRL Editor will display a list of icons for registered rule engines. These icons will be displayed on the top right of the SWRL rules table. The Drools tab is activated by pressing the "D" icon.

When it is pressed, the SWRL Drools Tab will be displayed in a window under the SWRL Editor.

If the tab successfully loads the Drools rule engine, it will display a series of tabbed sub windows that can be used to interact with Drools. If it fails, an error message will be displayed indicating that the Drools rule engine was not found.

Pressing the "D" icon again will hide the tab and deactivate the Drools tab. Note that when the tab is deactivated, the associated rule engine is deactivated too so all state that it may hold will be lost.

Interacting with the SWRLDroolsTab

The interaction between OWL and the Drools rule engine is user-driven. The user controls when OWL knowledge and SWRL rules are transferred to Drools, when inference is performed using that knowledge and rules, and when the resulting inferences are transferred back to the source ontology.

The SWRL Drools Tab has subtabs that can be used to control and review this interaction. The primary tab is the Drools Control tab, which provides the control functionality. It provides a status window to display a record of the interaction between the user and Drools and three buttons to control the knowledge transfer and inference process.

The button marked "OWL+SWRL->Drools" will transfer all SWRL rules and appropriate OWL knowledge to the Drools rule engine. The status window will indicate the number of rules and OWL axioms that have been transferred. Pressing the button again will clear all previously transferred knowledge in Drools and will reinitate the transfer process.

The "Inferred Axioms" sub tab in the SWRL Drools Tab can be used to examine the OWL axioms that have been transferred to Drools.

The "Run Drools" button can then be pressed to initiate the inference process. When pressed, Drools will run its inference engine and possibly generate new knowledge. This inferred knowledge can be reviewed in the "Inferred Axioms" subtab.

At that point, this inferred knowledge can be passed back to OWL by pressing the "Drools->OWL" button.

What reasoner does the SWRL Drools Tab use?

The Drools tab uses an OWL 2 RL-based reasoner. The 'OWL 2 RL' subtab within the SWRLDroolsTab provides control of this reasoner. See here for additional details on this subtab.

Where can I get the source code for the SWRLDroolsTab?

The SWRL Drools Tab is part of the SWRLAPI Drools Engine. Its source code is available in the SWRLAPI Drools Engine Git repository.

How can I build the SWRL Drools Tab?

The SWRL Drools Tab is part of the SWRLAPI Drools Engine. See the top level project README.md file for a description of building this engine.