Top Banner
An add-on for managing behaviours with priority in JADE Juan A. Suárez-Romero Amparo Alonso-Betanzos Bertha Guijarro-Berdiñas Laboratory for Research and Development in Artificial Intelligence Department of Computer Science, University of A Coruña, Spain
26

An add-on for managing behaviours with priority in JADE

Jun 24, 2015

Download

Technology

Presentation at IAT 2006
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: An add-on for managing behaviours with priority in JADE

An add-on for managing behaviours with priority in JADE

Juan A. Suárez-RomeroAmparo Alonso-BetanzosBertha Guijarro-Berdiñas

Laboratory for Research and Development in Artificial Intelligence

Department of Computer Science, University of A Coruña, Spain

Page 2: An add-on for managing behaviours with priority in JADE

IAT 2006 2

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

JADE

• Java Agent DEvelopment Framework

• FIPA compliant

• Agent tasks encapsulated in Behaviours

.

.

.public void action();

public boolean done();...

Page 3: An add-on for managing behaviours with priority in JADE

IAT 2006 3

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

JADE

• Behaviours can be formed by smaller sub-behaviours– Parallel scheduling– Sequential scheduling

.

.

.public void action();

public boolean done();...

.

.

.public void action();

public boolean done();...

.

.

.public void action();

public boolean done();...

.

.

.public void action();

public boolean done();...

Page 4: An add-on for managing behaviours with priority in JADE

IAT 2006 4

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

ParallelBehaviour

Page 5: An add-on for managing behaviours with priority in JADE

IAT 2006 5

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

ParallelBehaviour

Page 6: An add-on for managing behaviours with priority in JADE

IAT 2006 6

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialBehaviour

• Executes children in a sequential way

B1 B2 B3 B4

SequentialBehaviour

Page 7: An add-on for managing behaviours with priority in JADE

IAT 2006 7

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialBehaviour

• Executes children in a sequential way

B1 B2 B3 B4

SequentialBehaviour

Page 8: An add-on for managing behaviours with priority in JADE

IAT 2006 8

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialBehaviour

• Executes children in a sequential way

B1 B2 B3 B4

SequentialBehaviour

Page 9: An add-on for managing behaviours with priority in JADE

IAT 2006 9

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

Behaviours with priority

• Each Behaviour are assigned with a priority

• Priority is a positive number

• The lesser the number, the greater the priority

• Two priorities

– Static priority: assigned by the user

– Dynamic priority: used only by the

ParallelPriorityBehaviour

Page 10: An add-on for managing behaviours with priority in JADE

IAT 2006 10

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

2 1 0 1

ParallelPriorityBehaviour

Page 11: An add-on for managing behaviours with priority in JADE

IAT 2006 11

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

2 1 0 1

ParallelPriorityBehaviour

Page 12: An add-on for managing behaviours with priority in JADE

IAT 2006 12

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

1 0 0 0

ParallelPriorityBehaviour

Page 13: An add-on for managing behaviours with priority in JADE

IAT 2006 13

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

1 1 0 0

ParallelPriorityBehaviour

Page 14: An add-on for managing behaviours with priority in JADE

IAT 2006 14

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

1 1 0 1

ParallelPriorityBehaviour

Page 15: An add-on for managing behaviours with priority in JADE

IAT 2006 15

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

0 0 0 0

ParallelPriorityBehaviour

Page 16: An add-on for managing behaviours with priority in JADE

IAT 2006 16

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

ParallelPriorityBehaviour

• Executes children in a parallel way

B1 B2 B3 B4

2 1 0 1

2 0 0 0

ParallelPriorityBehaviour

Page 17: An add-on for managing behaviours with priority in JADE

IAT 2006 17

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialPriorityBehaviour

• Executes children in a sequential way

• Policy regarding blocked children

B1 B2 B3 B4

2 1 0 1

SequentialPriorityBehaviour

Page 18: An add-on for managing behaviours with priority in JADE

IAT 2006 18

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialPriorityBehaviour

• Executes children in a sequential way

• Policy regarding blocked children

B1 B2 B3 B4

2 1 0 1

SequentialPriorityBehaviour

Page 19: An add-on for managing behaviours with priority in JADE

IAT 2006 19

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialPriorityBehaviour

• Executes children in a sequential way

• Policy regarding blocked children

B1 B2 B3 B4

2 1 0 1

SequentialPriorityBehaviour

Page 20: An add-on for managing behaviours with priority in JADE

IAT 2006 20

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialPriorityBehaviour

• Executes children in a sequential way

• Policy regarding blocked children

B1 B2 B3 B4

2 1 0 1

SequentialPriorityBehaviour

Page 21: An add-on for managing behaviours with priority in JADE

IAT 2006 21

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

SequentialPriorityBehaviour

• Executes children in a sequential way

• Policy regarding blocked children

B1 B2 B3 B4

2 1 0 1

SequentialPriorityBehaviour

Page 22: An add-on for managing behaviours with priority in JADE

IAT 2006 22

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

Example of application

• Agent that uses its full time

– In normal time, it executes several specific tasks

– When it is idle (i.e. these tasks can not be executed)

it runs other tasks of maintenance.

Specific Tasks Idle Tasks

Page 23: An add-on for managing behaviours with priority in JADE

IAT 2006 23

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

Example of application

• Encapsulate specific tasks and idle tasks in two different ParallelPriorityBehaviour

ST1

p1

ST2

p2

ST3

p3

IT1

p1

IT2

p2

IT3

p3

Page 24: An add-on for managing behaviours with priority in JADE

IAT 2006 24

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

Example of application

• Insert both parallel behaviours in a SequentialPriorityBehaviour with priorities 1 and 2, and policy to skip blocked behaviours

ST1

p1

ST2

p2

ST3

p3

IT1

p1

IT2

p2

IT3

p3

SequentialPriorityBehaviour

1 2

Page 25: An add-on for managing behaviours with priority in JADE

IAT 2006 25

A n a d d – o n f o r m a n a g i n g b e h a v i o u r s w i t h p r i o r i t y i n J A D E

Hong Kong

Summary

• Two new priority-based scheduler

Behaviours are proposed

– ParallelPriorityBehaviour

– SequentialPriorityBehaviour

• They are able to run as the current

scheduler implementations

Page 26: An add-on for managing behaviours with priority in JADE

An add-on for managing behaviours with priority in JADE

Juan A. Suárez-RomeroAmparo Alonso-BetanzosBertha Guijarro-Berdiñas

Laboratory for Research and Development in Artificial Intelligence

Department of Computer Science, University of A Coruña, Spain