The Zeus Agent Building Toolkit

The Application Realisation Guide

Contents Introduction Ontologies Building
Task Agents
Utility Agents Task Agent
Configuration
Agent Implementation


2     The Ontology Creation Stage

An ontology is a set of declarative knowledge representing every significant concept within a particular application domain.  The significance of a concept is easily assessed, if meaningful interaction can not occur between agents without both parties being aware of it, then the concept is significant and must be modelled.  Note that for convenience we use the term 'fact' throughout ZEUS to describe an individual domain concept.

Prior to attempting this stage you should have already identified the following:

  • the key concepts within the problem domain

  • the significant attributes of each concept

  • the types of each attribute

  • any constraints on the attributes


    The remainder of this section describes how to enter this information into the ZEUS Ontology Editor. This can be launched from the ZEUS Agent Generator tool, which displays the following panel:

    Figure 2.1: A screenshot of the Ontology Options panel of the Generator tool




    ONT-1: How to Create a New Ontology

      If the Ontology Editor is not running, click on the "Edit" button in the Generator tools' Ontology Options toolbar, or select the "New Ontology" menu option from the Ontology Menu.  This will create a new (empty) ontology and launch the Ontology Editor.  From now onward all facts entered through this editor will become part of this ontology.

      If the Ontology Editor is already running, select the "New" menu option; if there is currently an ontology in memory you will be asked whether you want to save it.  Clicking on the "New" button in the Generator tools' Ontology Options toolbar will clear the current ontology without opening the Editor.



    ONT-2: How to Load an Ontology

      If the Ontology Editor is not running, click on the "Load" button in the Generator tools' Ontology Options toolbar, or select the "Load Ontology" menu option from the Ontology Menu. 

  • If the Ontology Editor is already open, a new ontology can be loaded by choosing the "Load…" menu option. 

  • This will summon a file requester, locate the file containing the Ontology and click "OK".  If there is already an ontology in memory, you will be asked if you want to save it before it is removed.

  • When the ontology has been loaded and parsed, its contents will appear in the Ontology Editor's windows.  A screenshot of the Ontology Editor is shown in Figure 2.1.

    Note that the fact pane of the Ontology Editor is divided into two, an upper panel that displays the Fact Hierarchy, and a lower panel that displays the attributes of the currently selected fact.  The panels are separated by a split-pane that can be moved up or down to enlarge one panel at the expense of the other.


    Figure 2.2: A Screenshot of one of the panels of the Ontology Editor.  Notice how the one of the nodes in the fact hierarchy (Monitor) has been selected, and its attributes are being shown in the table below.



    ONT-3: How to Create a New Fact

    The first stage in creating a new fact is to determine its position within the existing fact hierarchy:

      If the new fact has no parents in the existing hierarchy you will typically choose the Entity node and click on the "Add New Child Fact" button.

    The Entity fact is used to represent concepts that have physical realisations, like objects and commodities.  Where this is not appropriate the ZEUS fact hierarchy also has a fact called Abstract that does not possess cardinality and value attributes.

      If the new fact inherits from an existing fact, select the parent node and click on the "Add New Child Fact" button.

      To make the new fact share the same parent as another, (a useful short cut), select the existing fact and click the "Add New Peer Fact" button.

    A new entry will now appear in the fact tree, double click on it and rename to whatever is appropriate.



    ONT-4: How to Create a New Attribute

    Ensure that the fact to which the attribute will be added is the selected node of the fact hierarchy,  if not, clicking on the fact selects it.  The existing attributes for the selected fact will then appear in the Attribute Table beneath the Fact Hierarchy window.

      Click on the "New" button in the toolbar above the Attribute Table.  This will create a new entry in the table, double-click on it to rename it as appropriate.

      Clicking on the 'Toggle Shown Attributes' will hide or show the attributes inherited from the fact's parents.  This can be useful for determining whether an attribute has already been declared higher in the fact hierarchy.



    ONT-5: How to Set the Type of an Attribute

    Types serve to restrict the set of valid values the attribute can take, and will be one of the basic types, a restriction or another fact.

    Figure 2.3: A screenshot of the Type Selection window

    Double-click on an entry in the Attribute Table, this will summon a window showing all a hierarchy of currently known types, as shown in Figure 2.3.

    The basic types have been predefined, they are:


    Restrictions are custom types used to further restrict the values possible for basic types.  These are entered separately, see 'How to Create a Restriction'.  All previously entered restrictions are listed under the "Restrictions" node of the type selection window.

    Where attributes need to assume more complex values, their type can be specified as a particular fact.  All previously entered facts are listed under the "Facts" node of the type selection window.



    ONT-6: How to Restrict an Attribute

    An alternative to creating a restriction rule is to restrict each attribute individually, this is achieved by double clicking on the "Restriction" cell of the attribute entry, which opens a small green-coloured panel through which the restriction can be typed.

    The syntax of restrictions is that of a simplified expression, full details will be included in a later release.



    ONT-7: How to Set Attribute Defaults

    To give an attribute a default value, double click on the "Default" cell of the attribute entry, this opens a small green-coloured panel through which the default value can be typed. 

    The syntax of the value is dependent on the attribute type.  Defaults can not be set for attributes whose type is a restriction or another fact.



    ONT-8: How to Create a Restriction

    Restrictions are types that have been constrained to a particular set or range of values.  Although it is possible to restrict attributes without creating a restriction (see 'How to Restrict an Attribute'), restrictions allow for reuse, and provide meaningful names.  Restrictions are entered through the 'Restriction Definitions' pane of the Ontology Editor.



    ONT-9: How to Save an Ontology

    Ontologies are currently saved in an ASCII file using our own format; saving ontology in a more standardised format, like XML is under consideration.

      If the Ontology Editor is not open, click on the "Save" button in the Generator's Ontology Options toolbar, or select the "Save Ontology" menu option from the Ontology Menu.



    Merging Ontologies

    This function is not yet supported in the current Ontology Editor. 




    Contents Introduction Ontologies Building
    Task Agents
    Utility Agents Task Agent
    Configuration
    Agent Implementation