=Paper=
{{Paper
|id=Vol-2215/paper19
|storemode=property
|title=OntologyBeanGenerator 5.0: Extending Ontology Concepts with Methods and Exceptions
|pdfUrl=https://ceur-ws.org/Vol-2215/paper_19.pdf
|volume=Vol-2215
|authors=Daniela Briola,Viviana Mascardi,Massimilano Gioseffi
|dblpUrl=https://dblp.org/rec/conf/woa/BriolaMG18
}}
==OntologyBeanGenerator 5.0: Extending Ontology Concepts with Methods and Exceptions==
OntologyBeanGenerator 5.0:
Extending Ontology Concepts
with Methods and Exceptions
Daniela Briola Viviana Mascardi Massimiliano Gioseffi
Department of Computer Sciences, Department of Informatics, Bioengineering,
Systems and Communications. Robotics, and Systems Engineering.
University of Milano Bicocca University of Genova
Milan, Italy Genoa, Italy
daniela.briola@unimib.it viviana.mascardi@unige.it
Abstract—When modeling and implementing complex systems to e-government, at the European level the ISA program and
based on agents and artifacts, achieving semantic interoperability its ongoing continuation ISA22 (2016-2020) demonstrate the
is not only useful, but often necessary. A commonly adopted effort in developing interoperable digital solutions for public
solution to manage complex and real MASs is adopting a Model
Driven methodology, which uses an ontology as the formal administrations. The report [5] shows how standards have
representation of the domain, and then exploiting some existing become an essential part of the revolution in the information
tool to automatically generate code for agents in the MAS, to industry, aiming at interoperability for hardware and software.
let them interact according to the model. While this approach Finally, in the last few years we are witnessing an increasing
is satisfactorily supported when the target MAS environment is need for semantic interoperability also in the IoT [6], [7], [8]
Jason, less support is provided to Jade MASs, despite Jade’s
large adoption for real MASs development. So, considering the and cyber-physical systems domains [9].
great support given by the automatic code generation starting Since the advent of the ontologies first, and the Semantic
from a formal model, and the large community working on Web later, agents and ontologies have been considered as two
Jade MASs, in this work we present an extension of the sides of the same coin [10], [11], [12]. On the one hand, agents
OntologyBeanGenerator plugin for Protégé, used to generate a
Java representation of an OWL ontology for Jade. We improved
may exploit ontologies to model the environment, along with
the OntologyBeanGenerator tool to support the modeling of the involved entities therein and the services they offer, and
exceptions, formalized at the ontology level, and of methods to achieve a semantically rich message exchange [13], [14],
associated with ontology elements, to set the interface of concrete [15], [16]. On the other hand, many stages of the ontology en-
objects (artifacts) at design stage. This extension allows us to gineering process may benefit from the exploitation of agents,
integrate in a Model Driven approach a support for the formal
definition of artifacts and provide an automatic generation of
as discussed for example in [17] w.r.t. ontology alignment.
Jade code/interfaces to interact with them respecting the model. Given this close connection, all the most widespread plat-
Index Terms—Multiagent Systems; Model Driven Design; forms for MAS engineering offer some facilities to import
Jade; Automatic Code Generation; Ontologies; OntologyBean- and manage ontologies, be them used as a representation of
Generator the internal agent knowledge like in the JASDL extension [18]
of Jason [19], or as a vocabulary shared among agents and as
I. I NTRODUCTION a formal description of agents’s actions, like in Jade [20].
Semantic interoperability, namely the ability to process Jade offers facilities to directly import and manage ontolo-
digital information without losing the true intended meaning of gies, provided that they are represented as JavaBeans3 . The
the information itself, plays an increasingly important role in OntologyBeanGenerator 4.14 plugin of Protégé5 automatically
countless areas. Being explicit specifications of a shared con- creates a Java representation of the ontology coherent with
ceptualization, ontologies [1] are one of the most widespread Jade requirements, modeling domain concepts, predicates, and
tools for representing the entities characterizing a domain, in agent actions. Two features not supported by OntologyBean-
order to make applications semantically interoperable. Generator 4.1 are:
The biomedical domain is the one where the oldest and (1) the capability of associating interfaces (methods) with
largest ontologies were born1 ; closely related to that domain the ontology concepts representing entities in the domain, and
is the e-Health one that witnesses a recent boost of both
scientific [2], [3], [4] and commercial initiatives. With regard 2 http://ec.europa.eu/isa/
3 https://docs.oracle.com/javase/tutorial/javabeans/
1 See for example http://www.openclinical.org/ontologies.html 4 https://protegewiki.stanford.edu/wiki/OntologyBeanGenerator
and http://www.obofoundry.org/. 5 https://protege.stanford.edu/
116
(2) the capability of modeling the exceptions thrown by 3) identify the roles model, plus the services offered by
those methods as ontology concepts. each role;
These features are extremely relevant when the MAS under 4) identify the interaction model by describing use cases
development is as complex as a cyber-physical system, or in involving agents and artifacts;
general foresees a large set of artifacts (refering to the A&A 5) describe the programming interfaces with which artifacts
model [21]). In these cases, the ontology models physical provide their services;
devices that agents may control and act upon via some 6) describe the exceptions such services may raise;
unified interfaces (their public methods), and malfunctioning 7) associate the programming interface and its exceptions
of such devices (the exceptions they throw) must be explicitly with the ontology concepts representing artifacts and
represented in order not only to immediately react to them, move from the MAS design to its implementation.
but also to exchange information and reason about them. Depending on the agent-oriented development environment
Associating the pieces of information related with the used for the final implementation of the MAS, the last step
standard and exceptional behavior of the entities in the model, might take advantage of different supporting tools. In par-
with the ontology entities themselves, may improve semantic ticular, if the target system is Jason, the description of how
interoperability by adding compatibility between software sys- artifacts provide their services could be integrated into the
tems via reuse of standardized interfaces. environment ontology using the tool presented in [24] (see
Adopting an ontology as formal model to be used both at Section V). On the other hand, if the development environment
design time, and then as a starting point for the automatic code is Jade, some tools and languages (for example [25]) exist
generation of agents and artifacts in the MAS, is the approach which can support the modeling phase, such as the automatic
foreseen by Model Driven Engineering [22]. generation of small parts of code but, as far as we know
In this work we present OntologyBeanGenerator 5.0, an (see more details in Section V), a complete tool for a Model
extension of OntologyBeanGenerator 4.1, designed and im- Driven generated MAS developed over Jade is not available
plemented to address its shortcomings, having in mind Jade to the community, even if Jade is known to be one of the
MASs developed exploiting one (or more) ontology to model most adopted platform for developing multiagent systems.
the domain (seen as the set of environment, agents and artifacts One quite widespread solution is to use OWL to create a
involved in the MAS). So, OntologyBeanGenerator 5.0 could model of the agents, along with the services they offer, and
be used not only in those Jade MASs already exploiting an of the known artifacts, and then to automatically generate
OWL ontology – in its Java version – but also in those MASs the Jade skeletons of the agents actions and concepts to be
where a formal representation of artifacts, plus an “usage used by Jade agents. Our OntologyBeanGenerator 5.0 Protégé
interface” defined at design time, is needed to achieve a more plugin makes a step forward helping designers in the modeling
flexible solution. phase of the artifacts, letting them to model the programmable
The paper is organized as follows: Section II motivates the interfaces of the artifacts, that is, the methods to be used to
need for OntologyBeanGenerator 5.0, Section III describes manage the Java objects representing the artifacts, along with
its implementation, Section IV presents an example of use, their Exceptions, if any, as foreseen in the 7th step of the
Section V discusses the related works and concludes. “Gaia-like” methodology presented before. This feature can
be useful when modeling an artifact managed by an agent
II. M OTIVATION
which requests a specific interface to interact with and, more
When engineering a complex, safety-critical MAS, a soft- in general, can be seen as a new step towards a more solid and
ware engineer might need to pursue the two soft goals below, exhaustive platform for automatically generate code for Jade
besides the hard goals imposed by the stakeholder require- MASs. OntologyBeanGenerator 5.0 (OBG5.0 in the sequel)
ments and by privacy and security issues: seamlessly integrates with the previous OntologyBeanGener-
• reusability: (s)he should look for existing models of the ator 4.1 tool available to the community, which is one of the
domain, rather than starting from scratch; very few able to partially generate Jade-compliant code.
• semantic interoperability: (s)he should look for models To make our approach and tool clearer, let us consider
represented as ontologies, in order to exploit all the a concrete scenario where the final goal is to develop a
advantages that their adoption brings. controlling system (as we did for example in [26], [27]) for a
These soft goals may be integrated, for example, into an smart home implemented as a Jade MAS. The first six steps in
agile “Gaia-like” agent-oriented software engineering method- the above methodology can be addressed by a domain expert
ology [23] consisting of the following steps: who will design and implement the ontology modeling the
controlling system environment, along with its interactions
1) identify the Environment model, namely the appliances,
with the agents:
devices and resources – more in general, the “artifacts”
[21] – characterizing the domain; 1) (S)he realizes that the environment includes a set of
2) look for an ontology suitable for modeling that Envi- Sensors and Smart elements which can be managed
ronment: only if none can be reused, create a new one thanks to a wifi (or wired) network, plus a set of concepts
from scratch; such as Measurements and Locations;
117
2) (S)he discovers that the DogOnt ontology [28] http: adds a tab to the Protégé interface to directly export
//elite.polito.it/ontologies/dogont.owl satisfies many of ontologies in Java, meeting the requirements for
her/his needs and decides to adopt it, taking into consid- being used in Jade. An ontology containing Jade
eration the possibility to refine or extend it, if necessary; entities (OWLSimpleJADEAbstractOntology) is
3) (S)he identifies two roles in the controlling system: distributed with the plugin: the entities of the ontology
ElementController and HouseManager, along with their O we want to make availabe for Jade must be
services; reorganized under the pre-defined concepts offered by
4) (S)he creates use cases, where agents playing the roles OWLSimpleJADEAbstractOntology (Concept,
identified in step 3 interact and manage the artifacts to AgentActions, AID and Predicate), according to
solve a set of problems; their semantics. Once this refactoring has been completed,
5) (S)he lists a set of needed interfaces for Sensors and the OntologyBeanGenerator tab can be used to generate
Smart elements; the Java version of the “extended” ontology (namely, the
6) (S)he lists a set of needed exceptions to model their OWLSimpleJADEAbstractOntology extended with O
known errors/problems. entities positioned in the right place).
After this first design phase, the software engineer (possibly, OBG5.0, available from www.disi.unige.it/person/MascardiV/
with the help of an expert in Jade MAS design) faces step 7 Download/OBG5.0.zip, has been built as a Protégé plugin
and exploits OBG5.0 to create an OWL ontology able to model extending the OntologyBeanGenerator 4.1 (OBG4.1). The
the identified elements: OntologyBeanGenerator developer Chris van Aart authorized
7.1. (s)he imports into Protégé the identified DogOnt on- this extension, which aims at: 1) correcting some errors in
tology, and adds the needed new Concepts (with their OBG4.1; 2) adding a way to specify methods in the ontology;
properties); 3) adding a way to model, and then directly exploit, excep-
7.2. (s)he adds a set of Exceptions; tions. The main improvements of OBG5.0 w.r.t OBG4.1 are:
7.3. (s)he models the AgentActions; • Addition of a new tab (called Java Method Mapper)
7.4. (s)he adds the desired methods (raising Exceptions when to manage methods creation and exportation, to allow
needed) to the identified elements in the ontology; the MAS/ontology designer to add methods to the Java
7.5. (s)he uses the OBG5.0 to export the ontology into Java version of the ontology directly. This is necessary if
interfaces and classes. At this point, (s)he is able to we want to add methods that cannot be mapped into
implement the MAS by adding the real behavior of the setters/getters of a specific field (which were already
agents and implementing the AgentActions, and adding supported by OBG4.1). Methods are saved in an XML
the body to the methods defined in the ontology for the file which is loaded by the tab and overwritten when
elements managed in the MAS. exporting the ontology, and are added to the interfaces
Exceptions in our work have two meanings: the first one is and to their default implementations;
related directly to the methods we are adding to the Concepts, • Exception management: methods are allowed to raise
so we need them to let the designer, and then the programmer, Exceptions. To do this, a specific ontology has been
define the methods with their errors as normally done in Object created;
Oriented languages; the second is related to the formalization • Update of the ontology type, now is BeanOntology;
of an “Error/Exceptional State/Situation”, which in this case • Automatic import of the Default Implementations of the
should be modeled in the ontology and, if needed, should interfaces in the Java Ontology;
be sharable between agents, for example, as the result of a • Conversion of the boolean and int Protégé types into
service execution that an agent was not able to satisfy. Since the wrapper Boolean and Integer Java classes, to
we are targeting Jade, the only way an agent referring to support the exportation of multiple properties into lists
a specific ontology could answer with an Exception (as for (currently, OBG4.1 exports them as a List of Object,
example for AgentAction result, as the content of a message but this does not work with the methods for adding or
with Failure performative) is to have the Exception as subclass removing elements from the list);
of Jade:Concept. For this reason, to let the designer the • Automatic disambiguation of Java types: we now use
freedom of using the exceptions as (s)he prefers, we decided the fully qualified names when exporting types from
to model them under Concept. java.lang or java.util to avoid ambiguities with
In Sections III and IV we will use this running example to the Jade classes;
show how to extend the DogOnt ontology and to implement • Creation, after the compilation step, of the Java jar.
a simple Jade MAS exploiting it. The Java Method Mapper tab widget. Figure 1 shows the
OBG5.0 Java Method Mapper: when selecting a class from
III. O NTOLOGY B EAN G ENERATOR 5.0
the left area, the user can see the methods (if any) associated
OntologyBeanGenerator is a tab widget for Protégé with that class on the right area. Setters and getters do not
and is distributed under an open source license. The appear, since they are managed by the OBG4.1 “core” code.
last version available is 4.1. OntologyBeanGenerator If the method name is preceded by “this::”, it means that it is
118
Fig. 1: The Java Method Mapper tab with the methods list.
defined in the current class: if the method name is preceded
by another string, that string is the name of a parent class (the
method is inherited from the parent class). A user can remove
or modify methods of the selected class only: with a double
click on an inherited method, it is possible to override it.
The “Add” and “Remove” buttons add a new method to the
selected class and remove the selected method respectively. In
the lower part of the tab, the button “Method File” loads, for
the entire ontology (not only for the selected class), all the
methods previously created for the ontology. The two “Save”
buttons save the current changes or create a new XML file,
which is used when exporting the ontology using the other
tab of the plugin. (a) The Edit method window.
The add/edit method interface. When we add a new
method to a class or we edit an already existing method, the
Edit Window opens (shown in Figure 2a). The first part of the
dialog window is composed by these elements:
• Return Type of the method: allows to select the return
type from a combobox. The user can chose between
primitive Java types, Wrapper types, and the collections
List, Set and Map from java.lang. With the button
“Ontology” the user can instead select one class from
(b) The Add parameters window.
the ontology (a windows with the ontology structure is
opened, and the user can navigate it and select a class). Fig. 2: The Edit method dialog and the Add new parameter dialog.
• Method name: the user can insert a valid string as a name
(an alphanumeric string starting with or a character, not
containing a Java keyword). is performed, to verify that the types involved in the method
• Parameters: The button “+” opens the window Add/Edit exist either in Java or in the ontology, and if all is correct, the
Parameters (shown in Figure 2b). The button “-” deletes previous fields are then updated.
the selected parameter. With the “Set” button, a check over the method and param-
• Exceptions: with the button “+”, a window showing the eters names is performed. If we are adding a new method,
ontology part regarding the Exceptions is opened, so the check verifies that the method does not already exist.
that the user can select one (see below). The button “-” Overloading is permitted, and checked when adding/modifying
removes the selected Exception. a method in a class. Overriding is permitted as well: if the
In the lowest part of the window, a text area shows the user double clicks on an inherited method from the Java
resulting Java code for the method. This area can be manually Method Mapper tab, a new dialog windows will open: from
inspected and its content can be changed: with the “Apply” this, the user can redefine the exceptions or the return type,
button, a syntactic checker is performed thanks to ANTLR46 , changing them into a more specific type. If the user confirms
to verify that the method is well written, then a semantic check the changes, and they are correct, the method is added (if it
was the first time it was modified) or updated in the tab.
6 http://www.antlr.org/
119
Exception management. To let methods use Exceptions,
the user is requested to modify a template ontology modeling
the Exceptions (s)he wants to use: in this new ontology,
under the already existing Base class (that is a subclass of
Jade:Concept), the user must create all the Exceptions
(s)he will use. Then, this Exception ontology must be im-
ported in the main ontology, and must be given the prefix
Exception (that can be set up in the Metadata tab in
Protégé). During the export phase, the tool will automati-
cally modify the class Exception:Base so that it extends
java.lang.Exception: in this way, all its subclasses
will be automatically Exceptions. The Exception:Base
class is already a subclass of Jade:Concept, and can be
consequently used in the Jade MAS as the user prefers, for Fig. 3: (Part of) DogOnto ontology, extended with exceptions and
example, as content in a message. new concepts.
It is not allowed to add methods to the Exception classes.
The BeanOntology class. Starting from Jade 3.6.1, a class
called jade.content.onto.BeanOntology is adopted CoordinateInSpace (a new concept for specifying a point
by Jade to represent an ontology: this class lets the program- in the 2D area of the camera). The camera identifies the
mer to directly create ontology schemas starting from Java movement of an intruder and, thanks to the boolean method
classes (if they respect the Bean convention), without having intrusionDetected, can notify the caller – its own
to manually specify all the elements in the ontology. For controlling agent in this case – of this situation. This method
example, if we want to import a new Java implementation of raises an exception of type Exception_NotResponding
the C ontology class (called CImpl.java), we can simply if the camera is not working properly or is unable to perceive a
write the code ontology.add(CImpl.class) avoiding clear image (the image is completely filled with a unique color)
to manually create each element present in the class. because, for example, the intruder covered the camera with a
Another functionality provided by OBG5.0 is directly piece of paper. The camera may change its orientation (the
importing a package of classes (using the code pointingAT value) thanks to the new method pointAt,
ontology.add("packageName")), so that to avoid which actually rotates the camera and raises an exception if
registering every class in the package. That also means that the requested point cannot be framed.
one line of code is enough to include a new set of concrete
Use case and interactions. We consider a use case related
classes, so the user may develop its classes (implementing
to home security. We assume to have an agent associated with
the exported interfaces) and, adding one line of code, (s)he
each sensor in the house: in this very simple example, we have
can directly use them in Jade: anyway, if the user is not using
two SurveillanceCameras, each one associated with
methods (or (s)he is adopting other classes composition),
a CameraAgent (with the role ElementController),
(s)he can directly import the automatically created jar with
and a Manager agent (with the role of HouseManager)
no need to modify the code.
which receives either notifications of intrusion from the
IV. OBG5.0 E XAMPLE CameraAgents (IntrusionNotification AgentAc-
tion) or notifications of problems (for example, a cam-
Let us consider the SmartHome Controlling system domain
era not responding): when a CameraAgent sends the
presented in Section II. We started from the already available
ManagerAgent the CameraNotWorking AgentAction, it
DogOnt ontology [28], which gives a device/network indepen-
will also specify the last coordinate LastC the camera was
dent description of houses with smart entities, including both
pointing at: we could otherwise include the Exception itself
“controllable” and architectural elements, and we kept only
in the message and let the receiving agent decide what to do,
a very small subset of the existing elements (those coherent
but in this example due to space limitation, we decided to not
with our example, that is a very simple example foreseen to
exchange Exceptions between agents, and we adopt a simpler
show the capabilities of our tool and its functioning, with no
behavior where the CameraAgent already knows how to
claim to be completely realistic).
react when an Exception is raised by its associated device.
Figure 3 shows the DogOnt (part of) extended ontology,
In that situation, the Manager will select another Camera
while the methods added to SurveillanceCamera are
and will ask the associated CameraAgent to point to that
reported in Figure 1.
coordinate LastC: consequently, the camera which moved
The new concepts and the artifacts’s methods. because of this request will start patrolling that point and, if
SurveillanceCamera comes from the DogOnt existing an intrusion is detected, it will inform the Manager. In this
ontology, but the software engineer in charge for the ontol- way, if a camera is not working or has been deactivated, the
ogy modeling added to it a property pointingAT of type Manager is immediately notified and is able to coordinate
120
the other cameras to check the situation. [34], [35], [36], where the MASs were centered around the
Figure 4 provides a general overview of how agents interact domain ontology, and in many cases they were driven by it.
by means of a UML sequence diagram: agents exchange Starting from [37], a lot of effort has been devoted to the
messages containing AgentActions defined in the ontol- integration of ontologies into the AgentSpeak language [38],
ogy, and CameraAgents interact with their respective Sur- and more practically into Jason [18], [39], [40]. One of the last
veillanceCamera artifacts using methods in the ontology. works in this series [24] presents a new modeling approach
Jade implementation. We implemented this simple MAS where MASs are designed by instantiating an ontology devel-
in Jade. Figure 5 shows a screenshot from the Jade Snif- oped by the authors, and a tool uses these instances to generate
fer Agent. At the beginning of the surveillance activity, code for such systems.
Camera_1 and Camera_2 are patrolling two disjoint areas. When moving from Jason to Jade, the number of available
Then, Camera_1 (a CameraAgent) notifies the Manager tools and scientific papers dramatically decreases. Since Jade
that the camera is no longer working properly: the Manager ontologies must be represented in Java, it is common practice
requests Camera_2 (another CameraAgent) to point where to model them in OWL using Protégé, and then to use some
Camera_1 was pointing, and at that point Camera_2 per- existing tool that automatically generates the Java represen-
ceives an intruder and notifies the Manager, which will for tation of the ontology. The process of exporting an OWL
example contact the police. Later on we report the content of ontology into a Java representation was faced in similar ways
the FIPA-ACL request sent by the Manager to Camera_2, by [41]-[42] and [43]; anyway [43], which gave birth to the
so that the reader can see how the ontological concept OntologyBeanGenerator tool, was more successful, probably
(ControlAT AgentAction) is used. due to its simplicity and its direct integration into Protégé, and
is still today widely used.
ACL Message Content:
Whereas we can already add properties while modeling
((action entities in OWL aimed at being used in Jade, we have no
(agent-identifier
:name Manager@10.0.1.5:1099/JADE) way to model methods nor Exceptions.
(DefaultControlAT Our understanding of the issues raised by MAS engineering
:newCoordinate
(DefaultCoordinateInSpace along with our knowledge of the OntologyBeanGenerator tool
:x 3 and of its limitations, plus a comparison with platforms like
:y 4))))
CArtAgO [40] and JaCaMo [44], suggested us the extensions
described in this paper. The analysis of the literature confirmed
To give the reader an idea of how the Java code output by that, currently, no comprehensive Model Driven Tool with Jade
OBG5.0 looks like, we show below a fragment of the code as a target exists.
produced by the plugin. In particular, we report part of the Our implementation of OBJ5.0, freely available to the
code for adding concepts and properties to the ontology, and community, improves the previous version of the tool by
part of the code in the interface SurveillanceCamera to fixing a set of known problems; it also addresses some issues
manage the new methods. discusses for example in [45], where the authors argue that an
public class SensorsOntoOntology extends jade.content.onto.
exception ontology, along with a domain one, may increase
BeanOntology { the MAS reliability and enhance its fault tolerance capability.
private SensorsOntoOntology(){ By adding Exceptions both to methods and as Concepts in the
super(ONTOLOGY_NAME, BasicOntology.getInstance());
try { ontology, we believe OBJ5.0 may represent a very first step
// Concepts, AgentActions and Exceptions (part of code) towards the design of a Model Driven platform for developing
add(AIExportDougSensor.exceptions.Exception_Base.class);
add(AIExportDougSensor.ControlAT.class); secure and reliable Jade MASs.
//new! done to automatically add all the default classes An ideally similar approach is the one proposed by
add("AIExportDougSensor.impl");
} catch (BeanOntologyException e) {e.printStackTrace();} the W3C with OWL-S (https://www.w3.org/Submission/
} OWL-S/), which is an ontology modeling Web Services: this
}
public interface SurveillanceCamera extends Sensor { ontology is born mainly to be used for the Semantic Web, to
public boolean intrusionDetected ( ) support the semantic annotation and invocation of web services
throws Exception_Exception_NotResponding ;
public void pointAt (CoordinateInSpace newCoordinate) and also of entities in IoT environments. In this ontology,
throws Exception_Exception_OutOfScope ; each Service has a Profile, describing what the service offers,
}
a Model, to explain how to use it, and a Grounding, to
V. R ELATED W ORKS AND C ONCLUSIONS specifically describe how to interact with it. In some way, the
The research field in the intersection of multiagent systems grounding may be similar to our methods, but the difference is
and semantic web technologies is an extremely lively one. in the general approach. We created a way to add methods to
As recently observed in [24], it has also close connections Concepts in an ontology that represents agents, services and
with model-driven engineering, since the model which drives artifacts to be used in a Jade MAS, so, we are already acting in
the MAS engineering may be profitably represented as an a specific model (the one requested by Jade), foreseen for the
ontology. In our research activity, we have often used Ontol- usage inside the MAS. OWL-S is foreseen to model how an
ogyBeanGenerator, for example in [29], [30], [31], [32], [33], agent could interact with an external Web Service, so its scope
121
Fig. 4: CyclicBehaviour is always active: after Camera_2 receives the pointAt call from Manager, it starts the loop again,
calling the intrusionDetected method. We assume here that method pointAt never throws exception. Note that agents exchange
AgentActions each other, while agents manage artifacts thanks to their methods.
usage. We would also directly let the user insert the methods
code (to be automatically used in the Default concrete classes),
and static methods. Finally, since OBG5.0 does not work with
the most recent releases of Protégé, we plan to exploit the
lessons learned with its design and development, to create a
completely new version of OBG5.0 compliant with Protégé
5.2.0.
R EFERENCES
[1] T. Gruber, “Ontology,” in Encyclopedia of Database Systems, L. Liu and
M. T. Özsu, Eds. Springer, 2009, pp. 1963–1965.
[2] A. Taweel, “Semantic interoperability-enabled architecture for connected
health services,” in Reshaping medical practice and care with health
information systems. IGI Global, 2016, pp. 246–265.
Fig. 5: Screenshot from the Jade Sniffer [3] J. C. Mandel, D. A. Kreda, K. D. Mandl, I. S. Kohane, and R. B. Ramoni,
“SMART on FHIR: a standards-based, interoperable apps platform for
electronic health records,” Journal of the American Medical Informatics
Association, vol. 23, no. 5, pp. 899–908, 2016.
[4] S. Bhalla, S. Sachdeva, and S. Batra, “Semantic interoperability in
is slightly different (we do not have access on the Java object electronic health record databases: Standards, architecture and e-health
representing the Remote Web Service, while we have direct systems,” in International Conference on Big Data Analytics. Springer,
access to the Java object representing the specific artifact in the 2017, pp. 235–242.
[5] V. Peristeras, “Semantic standards: Preventing waste in the information
MAS). Nevertheless, since OWL-S is an OWL ontology, we industry,” IEEE Intelligent Systems, vol. 28, no. 4, pp. 72–75, July 2013.
could evaluate to integrate it (after understanding how to relate [6] M. Ganzha, M. Paprzycki, W. Pawłowski, P. Szmeja, and
the Jade classes with the OWL-S existing classes) and directly K. Wasielewska, “Semantic interoperability in the Internet of Things:
An overview from the INTER-IoT perspective,” Journal of Network
exploiting it in our tool, maybe as a new part (not alternative and Computer Applications, vol. 81, pp. 111–124, 2017.
but parallel to the current one): in this way, we could meet [7] S. Jabbar, F. Ullah, S. Khalid, M. Khan, and K. Han, “Semantic inter-
the requirements of a larger MAS designer community. This operability in heterogeneous IoT infrastructure for healthcare,” Wireless
Communications and Mobile Computing, vol. 2017, 2017.
study is part of the future work. [8] G. Bajaj, R. Agarwal, P. Singh, N. Georgantas, and V. Issarny, “A study
As further extensions, we plan to add more types in the of existing ontologies in the IoT-domain,” CoRR, vol. abs/1707.00112,
methods definition (the Array type and other less used Java 2017.
[9] V. Jirkovský, “Semantic integration in the context of cyber-physical
types, which could be specified by the user in a configuration systems,” czech Technical University in Prague, Doctoral Thesis.
file to get greater flexibility), and to allow the Java Generics [Online]. Available: https://dspace.cvut.cz/handle/10467/73622
122
[10] M. N. Huhns and M. P. Singh, “Ontologies for agents,” IEEE Internet [33] M. Leotta, S. Beux, V. Mascardi, and D. Briola, “My MOoD, a
computing, vol. 1, no. 6, pp. 81–83, 1997. multimedia and multilingual ontology driven MAS: Design and first
[11] J. Hendler, “Agents and the semantic web,” IEEE Intelligent Systems, experiments in the sentiment analysis domain,” in Proc. of ESSEM
vol. 16, no. 2, pp. 30–37, 2001. workshop, ser. CEUR-WS.org, vol. 1351, 2015.
[12] V. Mascardi, J. A. Hendler, and L. Papaleo, “Semantic web and [34] D. Briola, “Agents and ontologies for a smart management of heteroge-
declarative agent languages and technologies: Current and future trends neous data: The IndianaMAS system,” in Intelligent Distributed Com-
- (position paper),” in DALT, ser. Lecture Notes in Computer Science, puting IX, P. Novais, D. Camacho, C. Analide, A. El Fallah Seghrouchni,
vol. 7784. Springer, 2012, pp. 197–202. and C. Badica, Eds. Springer International Publishing, 2016, pp. 25–36.
[13] K.-t. Ng and Q. Lu, “Improve the service quality of multi-agent system: [35] M. Bozzano, D. Briola, D. Leone, A. Locoro, L. Marasso, and V. Mas-
Ontology management,” in Proc. of AAMAS. ACM, 2003, pp. 1078– cardi, “MUSE: MUltilinguality and SEmantics for the citizens of the
1079. [Online]. Available: http://doi.acm.org/10.1145/860575.860804 world,” Studies in Computational Intelligence, vol. 446, pp. 97–102,
[14] D. Briola, A. Locoro, and V. Mascardi, “Ontology agents in FIPA- 2013.
compliant platforms: A survey and a new proposal,” in Proc. of WOA [36] D. Briola, V. Mascardi, M. Martelli, R. Caccia, and C. Milani, “Dy-
2008, 2008, pp. 68–75. namic resource allocation in a MAS: A case study from the industry,”
[15] S. M. Deen and K. Ponnamperuma, “Dynamic ontology integration in Proceedings of the 10th Workshop on Objects and Agents, WOA’09,
a multi-agent environment,” in Proc. of AINA 2006, vol. 1, April 2006. 2009.
[16] R. Brena and H. G. Ceballos, “Combining local and global access to [37] Á. F. Moreira, R. Vieira, R. H. Bordini, and J. F. Hübner, “Agent-oriented
ontologies in a multiagent system,” Journal of Advanced Computational programming with underlying ontological reasoning,” in Proc. of DALT,
Intelligence, vol. 9, no. 1, 2005. ser. LNCS, vol. 3904. Springer, 2005, pp. 155–170.
[17] J. Euzenat, “Crafting ontology alignments from scratch through agent [38] A. S. Rao, “AgentSpeak(L): BDI agents speak out in a logical com-
communication,” in Proc. of PRIMA, ser. LNCS, vol. 10621. Springer, putable language,” in Proc. of MAAMAW, ser. LNCS, vol. 1038.
2017, pp. 245–262. Springer, 1996, pp. 42–55.
[39] V. Mascardi, D. Ancona, M. Barbieri, R. H. Bordini, and A. Ricci,
[18] T. Klapiscak and R. H. Bordini, “JASDL: A practical programming
“CooL-AgentSpeak: Endowing AgentSpeak-DL agents with plan ex-
approach combining agent and semantic web technologies,” in Proc.
change and ontology services,” Web Intelligence and Agent Systems,
of DALT, ser. LNCS, vol. 5397. Springer, 2008, pp. 91–110.
vol. 12, no. 1, pp. 83–107, 2014.
[19] R. H. Bordini, J. F. Hübner, and M. Wooldridge, Programming Multi-
[40] A. Freitas, A. R. Panisson, L. Hilgert, F. Meneguzzi, R. Vieira, and
Agent Systems in AgentSpeak Using Jason. John Wiley & Sons, 2007.
R. H. Bordini, “Integrating ontologies with multi-agent systems through
[20] F. L. Bellifemine, G. Caire, and D. Greenwood, Developing Multi-Agent CArtAgO artifacts,” in WI-IAT (2). IEEE Computer Society, 2015, pp.
Systems with JADE. Wiley, 2007. 143–150.
[21] A. Ricci, M. Viroli, and A. Omicini, “The A&A programming model [41] M. Tomaiuolo, F. Bergenti, A. Poggi, and P. Turci, “OWLBeans - from
and technology for developing agent environments in MAS,” in Proc. ontologies to Java classes,” in Proc. of WOA’04. Pitagora Editrice
of PROMAS, ser. LNCS, vol. 4908. Springer, 2007, pp. 89–106. Bologna, 2004, pp. 116–125.
[22] D. C. Schmidt, “Guest editor’s introduction: Model-driven engineering,” [42] M. Tomaiuolo, P. Turci, F. Bergenti, and A. Poggi, “An ontology support
IEEE Computer, vol. 39, no. 2, pp. 25–31, 2006. for semantic aware agents,” in Agent-Oriented Information Systems III,
[23] F. Zambonelli, N. R. Jennings, and M. Wooldridge, “Developing mul- M. Kolp, P. Bresciani, B. Henderson-Sellers, and M. Winikoff, Eds.
tiagent systems: The Gaia methodology,” ACM Trans. Softw. Eng. Berlin, Heidelberg: Springer Berlin Heidelberg, 2006, pp. 140–153.
Methodol., vol. 12, no. 3, pp. 317–370, 2003. [43] C. van Aart, R. Pels, G. Caire, and F. Bergenti, “Creating and using
[24] A. Freitas, R. H. Bordini, and R. Vieira, “Model-driven engineering of ontologies in agent communication,” in Proc. of OAS, 2002.
multi-agent systems based on ontologies,” Applied Ontology, vol. 12, [44] O. Boissier, R. H. Bordini, J. F. Hübner, A. Ricci, and A. Santi,
no. 2, pp. 157–188, 2017. “Multi-agent oriented programming with JaCaMo,” Science of Computer
[25] F. Bergenti, E. Iotti, S. Monica, and A. Poggi, “Agent-oriented model- Programming, vol. 78, no. 6, pp. 747 – 761, 2013, special section: The
driven development for jade with the jadel programming language,” Programming Languages track at the 26th ACM Symposium on Applied
Comput. Lang. Syst. Struct., vol. 50, no. C, pp. 142–158, Dec. 2017. Computing (SAC 2011) & Special section on Agent-oriented Design
[Online]. Available: https://doi.org/10.1016/j.cl.2017.06.001 Methods and Programming Techniques for Distributed Computing in
[26] V. Mascardi, D. Briola, M. Martelli, R. Caccia, and C. Milani, “Mon- Dynamic and Complex Environments.
itoring and diagnosing railway signalling with logic-based distributed [45] N. Shah, R. Iqbal, A. James, and K. Iqbal, “Exception representation
agents,” in Proc. of the International Workshop CISIS’08, E. Corchado, and management in open multi-agent systems,” Information Sciences,
R. Zunino, P. Gastaldo, and Á. Herrero, Eds. Springer Berlin Heidel- vol. 179, no. 15, pp. 2555 – 2561, 2009.
berg, 2009, pp. 108–115.
[27] D. Briola, V. Mascardi, M. Martelli, G. Arecco, R. Caccia, and C. Milani,
“A prolog-based mas for railway signalling monitoring : Implementation
and experiments,” in Proceedings of the Workshop on Objects and
Agents, WOA’08, 2008.
[28] D. Bonino and F. Corno, “DogOnt - ontology modeling for intel-
ligent domotic environments,” in The Semantic Web - ISWC 2008,
A. Sheth, S. Staab, M. Dean, M. Paolucci, D. Maynard, T. Finin, and
K. Thirunarayan, Eds. Berlin, Heidelberg: Springer Berlin Heidelberg,
2008, pp. 790–803.
[29] A. Locoro, V. Mascardi, D. Briola, M. Martelli, M. Ancona,
V. Deufemia, L. Paolino, G. Tortora, G. Polese, and R. Francese, “The
Indiana MAS Project: Goals and Preliminary Results,” in Proceedings
of the 13th Workshop on Objects and Agents Milano, Italy, September
17-19, 2012, G. V. Flavio De Paoli, Ed., vol. CEUR Vol-892. CEUR,
2012. [Online]. Available: http://ceur-ws.org/Vol-892/paper10.pdf
[30] Mascardi, V., Briola, D., et al., “A holonic multi-agent system for sketch,
image and text interpretation in the rock art domain,” Int. J. of Innovative
Computing, Information and Control, vol. 10, no. 1, pp. 81–100, 2014.
[31] D. Briola, V. Deufemia, V. Mascardi, and L. Paolino, “Agent-oriented
and ontology-driven digital libraries: the IndianaMAS experience,” Soft-
ware: Practice and Experience, vol. 47, no. 11, pp. 1773–1799, 2017.
[32] D. Briola, V. Deufemia, V. Mascardi, L. Paolino, and N. Bianchi,
“Ontology-driven processing and management of digital rock art objects
in IndianaMAS,” in Proc. of EuroMed 2014, 2014, pp. 217–227.
123