Jadex 0.96

jadex.examples.garbagecollector
Agent GarbageCollector


agent GarbageCollector

Garbarge collector agent.

Runs a predefined way on the grid and searches for garbage. Whenever it sees garbage at its actual position it tries to pick it up and brings it to one of the available garbage burners (chosen randomly).


Belief Summary
belief Environment env
           Environment object as singleton.
belief boolean has_garbage
           Flag indicating if the agent currently carries garbage.
belief boolean is_dirty
           When at least one piece of waste is present on the current posistion the actual position is perceived as dirty.
belief Position pos
           The actual position on the grid world.
 
Goal Summary
performgoal check()
           Goal for running around on the grid and searching for garbage.
achievegoal go(Position pos)
           Goal for going to a specified position.
achievegoal pick()
           The goal for picking up waste.
achievegoal take()
           Goal for picking up a piece of waste, bringing it to some burner and going back.
 
Plan Summary
standard plan checking_plan()
           Plan for running on a predefined route and searching waste.
standard plan go_plan(Position pos)
           Plan for going to a target position.
standard plan pickup_plan()
           Plan for picking up some garbage.
standard plan take_plan()
           Plan for taking some waste, bringing it to a burner and going back.
 
Configuration Summary
default configuration  default
          
 

Belief Detail

env

belief Environment env
Environment object as singleton. Parameters are name and type of agent for adding it No clean solution but avoids registering of agents.

Default fact:
Environment.getInstance($agent.getType(), $agent.getName())

pos

belief Position pos
The actual position on the grid world.

Default fact: (dynamic)
$beliefbase.env.getPosition($agent.getName())

is_dirty

belief boolean is_dirty
When at least one piece of waste is present on the current posistion the actual position is perceived as dirty.

Default fact: (dynamic)
$beliefbase.env.isDirty($beliefbase.pos)

has_garbage

belief boolean has_garbage
Flag indicating if the agent currently carries garbage.

Default fact: (dynamic)
$beliefbase.env.hasGarbage($agent.getName())
Goal Detail

check

performgoal check()
Goal for running around on the grid and searching for garbage.

BDI flags:
retry: true
retry delay: 0
exclude: never
random selection: false
post to all: false

take

achievegoal take()
Goal for picking up a piece of waste, bringing it to some burner and going back. A new goal is created whenever the actual position is dirty and there is no burner present.

BDI flags:
retry: true
retry delay: 0
exclude: when_tried
random selection: false
post to all: false
Uniqueness enabled:
Creation Condition:
$beliefbase.is_dirty && !$beliefbase.env.isBurnerPresent($beliefbase.pos)
Deliberation:
inhibits check

go

achievegoal go(Position pos)
Goal for going to a specified position.

Parameters:
in parameter pos
BDI flags:
retry: true
retry delay: 0
exclude: when_tried
random selection: false
post to all: false

pick

achievegoal pick()
The goal for picking up waste. Tries endlessly to pick up.

BDI flags:
retry: true
retry delay: 100
exclude: never
random selection: false
post to all: false
Drop Condition:
!$beliefbase.is_dirty && !$beliefbase.has_garbage
Plan Detail

take_plan

standard plan take_plan()
Plan for taking some waste, bringing it to a burner and going back.

Plan body:
Plan trigger:
Goals:
take

checking_plan

standard plan checking_plan()
Plan for running on a predefined route and searching waste.

Plan body:
Plan trigger:
Goals:
check

pickup_plan

standard plan pickup_plan()
Plan for picking up some garbage.

Plan body:
Plan trigger:
Goals:
pick

go_plan

standard plan go_plan(Position pos)
Plan for going to a target position.

Parameters:
in parameter pos (goal mappings: go.pos)
Plan body:
Plan trigger:
Goals:
go
Configuration Detail

default

default configuration default
Initial Goals:
check

Jadex 0.96

Submit a bug or feature
For further API reference and developer documentation, see the Jadex User Guide and the Jadex Tutorial. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, and working code examples.

Copyright (C) 2002-2007 Lars Braubach, Alexander Pokahr - University of Hamburg. Use is subject to license terms.