jade: installation and “hello world” application fabiano dalpiaz agent-oriented software...

15
JADE: installation and “Hello World” application Fabiano Dalpiaz Agent-Oriented Software Engineering (AOSE) 2009-10

Upload: scot-ronald-joseph

Post on 22-Dec-2015

227 views

Category:

Documents


3 download

TRANSCRIPT

JADE: installation and “Hello World” application

Fabiano Dalpiaz

Agent-Oriented Software Engineering (AOSE) 2009-10

F. Dalpiaz - AOSE 2009

What is JADE?

• JADE - Java Agent DEvelopment Framework is a framework to develop and run multi-agent systems in compliance with the FIPA specifications.

– Developed by Telecom Italia @TILab

– Distributed under LGPL

Can be downloaded from http://jade.tilab.comFree registration is required

F. Dalpiaz - AOSE 2009

Again, what is JADE?

Agents JADE

F. Dalpiaz - AOSE 2009

Where can I find help?

• JADE administrator guide

http://jade.tilab.com/doc/administratorsguide.pdf

• JADE programmer guide

http://jade.tilab.com/doc/programmersguide.pdf

• Examples & tutorials

http://jade.tilab.com/doc/index.html

• The JADE bookDeveloping Multi-Agent Systems with JADEFabio Bellifemine, Giovanni Caire, Dominic GreenwoodEditor: WILEYISBN: 978-0-470-05747-6

F. Dalpiaz - AOSE 2009

Main features of JADE

• JADE is a middleware that facilitates the development of multi-agent systems. It includes

– A runtime environment where JADE agents can “live” and that must be active on a given host before one or more agents can be executed on that host.

– A library of classes that programmers have to/can use (directly or by specializing them) to develop their agents.

– A suite of graphical tools that allows administrating and monitoring the activity of running agents.

F. Dalpiaz - AOSE 2009

FIPA-compliance

• JADE complies with the FIPA standards

– FIPA = Foundation for Intelligent Physical Agents

– Its standards include:

• Agent communication (ACL)

• Agent management

• Agent message transport

• Abstract architecture

• Applications

– http://www.fipa.org/

F. Dalpiaz - AOSE 2009

JADE distributed architecture

Platforms

Containers

F. Dalpiaz - AOSE 2009

Containers and Platforms

• A JADE platform enables agents' execution. Platforms are composed of one or more containers

• A main container differs from normal containers as it holds two special agents (automatically started when the main container is launched).

• The AMS (Agent Management System) provides the naming service (i.e. ensures that each agent in the platform has a unique name) and represents the authority in the platform (for instance it is possible to create/kill agents on remote containers by requesting that to the AMS).

• The DF (Directory Facilitator) provides a Yellow Pages service by means of which an agent can find other agents providing the services he requires in order to achieve his goals.

F. Dalpiaz - AOSE 2009

Agent lifecycle

Agents are “born”, “live”, and eventually “die”

F. Dalpiaz - AOSE 2009

Installing JADE1) Download and install JAVA JDK

2) Go to http://jade.tilab.com/download.php

3) Register (create your user)

4) Login and download jadeAll.zip

5) Extract jadeAll.zip to a folder (e.g., c:\jade, /home/user/jade)

– We will refer that folder JADE_HOME from now on

6) Add the following files to CLASSPATH:

– .

– JADE_HOME/lib/http.jar

– JADE_HOME/lib/iiop.jar

– JADE_HOME/lib/jade.jar

– JADE_HOME/lib/jadeTools.jar

Windows:SET CLASSPATH=%CLASSPATH%; .; c:\jade\lib\http.jar; c:\jade\lib\iiop.jar; c:\jade\lib\jade.jar; c:\jade\lib\jadeTools.jar;

F. Dalpiaz - AOSE 2009

Installing JADE

Test your JADE installation: executejava jade.Boot -gui

F. Dalpiaz - AOSE 2009

Did it work?

JADE is running properly if this GUI is shown

JADE can runwithout GUI

F. Dalpiaz - AOSE 2009

The JADE GUI anatomy

Basic operations onagents:• Start• Kill• Suspend• Resume• Send Message• Migrate• Clone

Debugging/runtime tools:• Sniffer (“interaction spy”)• Dummy agent• Log Manager• Introspector (agents internals)• Add platform

Active agents

F. Dalpiaz - AOSE 2009

A simple exercise with the GUI

• TODO:

– Repeat the same exercise with two providers

– Run the sniffer to monitor what happens

da0

da1

F. Dalpiaz - AOSE 2009

Next classes

• We will cover the main topics of JADE

• Hands on!

– Exercises

– Discussion

• Project assignments

– Simulation of a real-life scenario as a multi-agent system

– You will receieve detailed specification

– Creativity is required to simulate at best

– 2-3 members per team

– We will give you hints and check the progress of your projects