SYSC5103 Software Agents RoboCup and BDI Architecture Fall 2006 - PowerPoint PPT Presentation

About This Presentation
Title:

SYSC5103 Software Agents RoboCup and BDI Architecture Fall 2006

Description:

Design and Implementation of Jason Environment; ... void mainLoop(String[] a) throws IOException. void send(String message) void see(VisualInfo info) ... – PowerPoint PPT presentation

Number of Views:81
Avg rating:3.0/5.0
Slides: 20
Provided by: me6190
Category:

less

Transcript and Presenter's Notes

Title: SYSC5103 Software Agents RoboCup and BDI Architecture Fall 2006


1
SYSC5103 Software Agents RoboCup and BDI
Architecture Fall 2006
  • Yousif Al Ridhawi
  • Morvarid Sehatkar
  • Walter Kung
  • Gayathri Jayaraman

2
Outline
  • Multi-Agent System and BDI Architecture
  • Jason and AgentSpeak(L)
  • RoboCup
  • Design and Implementation of Jason Environment
  • Design and Implementation of soccer player
    behavior
  • Performance Results
  • Evaluate Jason as a BDI Programming system

3
Multi-Agent System and BDI Architecture
  • Multi-agent system is the sub field of artificial
    intelligence, which studies systems involving
    multiple agents and their coordination.
  • When a group of agents in a multi-agent system
    share a common long-term goal, they can be said
    to form a team.
  • The BDI architecture is being widely used in
    dynamic and complex scenarios where agents may
    need to act under incomplete and incorrect
    information about other agents and the
    environment where they are situated.
  • The BDI model has some philosophical basis in the
    Belief-Desire-Intention theory of human practical
    reasoning.

4
Jason and AgentSpeak(L)
  • Jason is a Java-based platform for the
    development of multi-agent systems
  • Jason is one of the interpreter for an extended
    version of AgentSpeak(L).
  • AgentSpeak(L) is the abstract languages based on
    BDI architecture.
  • AgentSpeak(L) maintains a set of beliefs and a
    set of plans.
  • The set of beliefs represents the information an
    agent presently has about the world
  • A plan is a sequence of steps the agent needs to
    execute in order to handle some perceived event.
  • A AgentSpeak(L) plan has
  • A head triggering event
  • A context predicate for the plan to be
    considered applicable.
  • A body a sequence of basic actions
  • head context lt- body
  • e.g. e true lt- !g

5
RoboCup
  • Soccer Server
  • Provides a virtual field that simulates all
    movements of a ball and players.
  • Send field information to Clients via UDP/IP
    socket.
  • Soccer Monitor
  • Display graphical representation of the game.
  • Initial kick-off command.
  • Clients
  • client controls movements of one player by
    sending commands through UDP/IP socket to the
    server.

6
Design and Implementation of Jason Environment
7
Communication between threadsActivity Chart
8
Issues and Lessons Learned
  • Issue Perceptions were added before the previous
    action could be completed.
  • Solution ? Introduced a time delay between an
    action and the next perception
    received.
  • Open Issue In multiplayer environment, multiple
    threads (one for each player) access the same
    environment methods resulting in socket
    overwrite.
  • Recommendation (from Jomi Hubner) ? Use of Agent
    Architecture class (for each agent) instead of
    using environment class (Work in Progress)
  • Open Issue Lack of good explanation of the APIs
    and examples in Jason documentation.
  • Open Issue Debugging the code using breakpoints.

9
State Diagram for Soccer Player Behavior
10
AgentSpeak(L) Code
  • // REACHBALL The ball Dir is correct and dist is
    okay. Search for the goal
  • ball(Dist, Dir, DistChng, DirChng) Dist lt 1
  • lt- checking(goal)
  • !kick(goal)
  • -ball(null).
  • // Sub Goal 1 see goal, then kick ball
  • !kick(goal) goal(GDist, GDir, GDistChng,
    GDirChng) checking(goal)
  • lt-
  • kick(100, GDir)
  • -goal(GDist, GDir, GDistChng, GDirChng)
  • -checking(goal).
  • // Sub Goal 2 do not see goal, then search for
    goal
  • !kick(goal) goal(null) checking(goal)
  • lt-
  • turn(40).
  • // if I see the goal, that means is not
    goal(null)
  • //BELIEFS
  • checking(ball).
  • //PLANS
  • // If the ball is not visible. go to
    checking(ball) state
  • ball(null) true
  • lt-
  • -ball(null)
  • -ball(Dist, Dir, DistChang, DirChng)
  • turn(40)
  • checking(ball)
  • -checking(goal).
  • // If kickOff occurs.
  • kickOff lt-
  • ?ball(Dist, Dir, DistChang, DirChng)
  • -ball(Dist, Dir, DistChang, DirChng).
  • // The ball Dir is not correct, turn to match
    dir

11
Time Comparison Jason Implementation vs Krislet
Time(ms) for first goal in each Trial Run Time(ms) for first goal in each Trial Run
Krislet SoccerPlayer
539 927
553 976
455 960
447 955
452 1019
465 967
522 915
486 1014
507 975
514 1047
12
BDI Programming System Requirements
  • The programming language has to be expressive
  • Able to describe the agent behavior without
    regarding how agent is implemented.
  • Reasoning of system has to be flexible
  • Able to decide, moment by moment, which action to
    perform in the furtherance of its goals.
  • Has to be responsive to the environment
  • Interpreter must be fast.
  • Must have correct response to all situations.

13
Expressive AgentSpeak(L) describe agent using
abstract notions.
  • // FOUND BALL The ball Dir is correct and dist
    is okay. Search for the goal
  • ball(Dist, Dir, DistChng, DirChng) Dist lt 1
  • lt- checking(goal)
  • !kick(goal)
  • -ball(null).
  • // Kick if the agent see the goal.
  • !kick(goal)
  • goal(GDist, GDir, GDistChng, GDirChng)
    checking(goal)
  • lt- kick(100, GDir)
  • -goal(GDist, GDir, GDistChng, GDirChng)
  • -checking(goal)
  • checking(ball).
  • // Turn if the agent do not see the goal.
  • !kick(goal) goal(null) checking(goal)
  • lt- turn(40).

14
Flexibility Deliberate to Select Achievable
Option.
  • // Option 1 If the ball is in range, kick the
    ball
  • ball(Dist, Dir, DistChng, DirChng) Dist lt 1
  • lt- checking(goal)
  • !kick(goal)
  • -ball(null).
  • // Option 2 If the ball is in range, find goal
  • ball(Dist, Dir, DistChng, DirChng) Dist lt 1
  • lt- checking(goal)
  • !check(goal)
  • -ball(null).
  • // SubGoal 1 Kick ball to goal
  • !kick(goal) goal(GDist, GDir, GDistChng,
    GDirChng) checking(goal)
  • lt- kick(100, GDir)
  • -goal(GDist, GDir, GDistChng, GDirChng)
  • -checking(goal).
  • // SubGoal 2 Check the goal location
  • The following perceptions are added
  • ball(0.5, 0, 0, 0)
  • goal(null)
  • There are two options that could be triggered.
  • Option 1 has an unachievable sub goal
    (!kick(goal)) which required the goal location is
    known.
  • Option 2 has achievable sub-goal. (!check(goal)).
  • The interpreter should pick option 2.
  • However, Jason pick option 1 and generate the
    following error.
  • test1 Found a goal for which there is no
    applicable plan
  • !kick(goal)
  • _at_l__4source(self) ball(Dist,Dir,DistChng,Di
    rChng)source(percept) (Dist lt 1) lt-
    !kick(goal) -ball(null). Dist1, Dir0,
    DirChng0, DistChng0
  • test1 No fail event was generated for
    !kick(goal)

15
Flexibility (cont)
  • // REACHBALL The ball Dir is correct and dist is
    okay. Search for the goal
  • ball(Dist, Dir, DistChng, DirChng) Dist lt 1
  • lt- checking(goal)
  • !kick(goal)
  • -ball(null).
  • // SubGoal 1 kick ball to goal
  • !kick(goal) goal(GDist, GDir, GDistChng,
    GDirChng) checking(goal)
  • lt- kick(100, GDir)
  • -goal(GDist, GDir, GDistChng, GDirChng)
  • -checking(goal).
  • // SubGoal 2 check goal location
  • !kick(goal) goal(null) checking(goal)
  • lt- turn(40).
  • Jason was successful in picking the achievable
    plan if the condition is specified in the context
    part of the plan.

16
Responsive to the Environment
  • // If ball is out of reach, run toward it.
  • ball(Dist, Dir, DistChang, DirChng) Dist gt 1
  • lt- -ball(null)
  • -ball(Dist, Dir, DistChang, DirChng)
  • dash(Dist 25).
  • Jason handled goal as event.
  • When event occurs, it triggers plans.
  • Advantage responds quickly to the environment.
    It behaves like reflex action.
  • Disadvantage there is no check whether the goal
    is accomplished or not.
  • Jason does not respond to incomplete goal.

RobuCup RobuCup Jason
Send Perception Action Processing Send Command
Before Kick-Off Before Kick-Off Before Kick-Off
ball(20, 10, 0, 0)   dash(500)
  Dash(500) and failed  
ball(20, 10, 0, 0)   No response to the old perception
17
Conclusions
  • Successfully implement soccer player in RoboCUP
    using BDI development framework.
  • Noticeable performance difference in terms of
    speed between the Java code implementation of
    Krislet and the Jason version
  • Agent Speak(L) can express agent behavior using
    abstract notions
  • Jason BDI reasoning engine is not flexible with
    the option deliberation
  • Jason has no verification whether the goal has
    been accomplished

18
Backup slide Jason Environment
19
Backup slide An interpretation cycle of an
AgentSpeak(L) program
Write a Comment
User Comments (0)
About PowerShow.com