Agent-Oriented Requirements Engineering

Workshop 7 in AOM & MAS
Msury Mahunnah,
Tallinn University of
Technology
Concurrent tasks of a JADE agent
An agent must be able to carry out several
concurrent tasks in response to different external
events
 Every JADE agent is composed of a single
execution thread


Concurrent tasks are modelled and can be
implemented as instances of
jade.core.behaviours.Behaviour
Agent thread in JADE
Hierarchy of behaviours
Defining JADE agent
import jade.core.*;
public class PhysicianAgent extends Agent {
//Put agent initialization here
protected void setup() {
// Adding behavours
addBehaviour(new MessageHandler(this));
...
}
//If needed, put agent clean-up operations here
protected void takeDown(){
System.out.println("Physician-agent "+getAID().getName()+" terminated");
...
}
}
OneShotBehaviour
CyclicBehaviour
Generic behaviour
Scheduling operations in JADE

Jade provides two ready-made classes for easily
implementation of behaviours that execute certain
operations at given points in time.
• WakerBehaviour
• TickerBehaviour
WakerBehaviour
TickerBehaviour
Agent Communication
The ACL Language
Specifies messages exchanged by JADE agents
according to FIPA.
 The format comprises a number of fields, including:

• Sender of the message
• List of receivers
• Communicative intention (performative)
• Content
• Content language
• Ontology
Sending messages
Receiving messages with
blocking method
The DF Agent
Publishing a service
De-register published services
Searching for services
Agent Communication
Agent Communication
Agent Communication