Reactive Planning Agent Programming Language - PowerPoint PPT Presentation

1 / 31
About This Presentation
Title:

Reactive Planning Agent Programming Language

Description:

School of Information Technology And Computer Science. University of ... GOLOG: alGO LOGic. Where 'algo' is an algebraic computer language for solving primarily ... – PowerPoint PPT presentation

Number of Views:28
Avg rating:3.0/5.0
Slides: 32
Provided by: dslUo
Category:

less

Transcript and Presenter's Notes

Title: Reactive Planning Agent Programming Language


1
Reactive Planning Agent Programming Language
  • Duc Vo
  • Decision Systems Laboratory
  • School of Information Technology And Computer
    Science
  • University of Wollongong

2
Index
  • Introduction
  • Review
  • BDI Agents
  • Available Agent Programming Languages
  • Default Logics
  • Reactive Planning Agent Programming Language
  • Conclusion future research

3
Introduction (1)
  • BDI Agents has been known as the best approach to
    model rational agents.
  • There have several Agent Programming Language
    (APL) available
  • 3APL (An Abstract Agent Programming Language)
  • AgentSpeak(L)
  • GOLOG (alGOl LOGic), ConGOLOG (Concurrent GOLOG)

4
Introduction (2)
  • Working environment of rational agents is
    supposed to be open, dynamic, and ever-changing,
    where the agent can never have complete
    information about its environment
  • Default logic introduced by Ray Reiter in 1981
    has been one of the most well known approach for
    reasoning when information is incomplete

5
Introduction (3)
  • Agent programmed in available APLs is not able to
  • Reasoning with incomplete information (e.g. have
    to wait until some information is discovered)
  • Reconsidering a plan once the agent has been
    already executing it (e.g. when thing goes wrong,
    or thing turns out not as expected)

6
Motivating Example
Rescue Robot (RBot). Need to rescue a person at D
then carry him back to A. RBot can only travel on
available path and when the path is clear. RBot
can only see if a path to the next node is clear
or not Condition of out-of-sight path is unknown.
7
Review 3APL (1)
  • 3APL An Abstract Agent Programming Language
  • Developed by 3APL group at Institute of
    Information and Computing Sciences at University
    of Utrecht, Netherlands (http//www.cs.uu.nl/3apl)

8
Review BDI Agent
  • Introduced by a philosopher Michael Bratman in
    1987
  • Beliefs what agent knows about environment
  • Desires what agent wants to achieve
  • Intentions the plans that the agent intends to
    execute to achieve its desired goals

9
Review 3APL (2)
10
Review 3APL (3)
  • PROGRAM "patrol_agent.3apl"
  • CAPABILITIES
  • at_east(self) WalkWest() NOT at_east(self),
    at_west(self),
  • at_west(self) WalkEast() at_east(self), NOT
    at_west(self)
  • BELIEFBASE
  • at_west(self)
  • GOALBASE
  • patrol()
  • RULEBASE
  • patrol()  at_east(self)  WalkWest()
    patrol() ,
  • patrol()  at_west(self) WalkEast() patrol()
    .

11
Review GOLOG (1)
  • GOLOG alGO LOGic
  • Where algo is an algebraic computer language
    for solving primarily mathematical and scientific
    problems using algorithms
  • Developed by Cognitive Robotics Group at
    University of Toronto, Canada (http//www.cs.toron
    to.edu/cogrobo/)
  • a logic programming language for agents

12
Review GOLOG (2)
13
Review GOLOG (3)
  • PROGRAM "patrol_agent"
  • Primitive actions WalkWest(), WalkEast()
  • Fluents
  • at_east(self, s) at situation s robot is at
    east
  • at_west(self, s) at situation s robot is at
    west
  • Primitive Action Pre Condition
  • Poss(WalkWest(), s) ?? at_east(self, s)
  • Poss(WalkEast(), s) ?? at_west(self, s)
  • Successor State Actions
  • Poss(a, s) ?
  • (a WalkWest() and at_west(self, do(a,s)) or
  • (a WalkEast() and at_east(self, do(a,s))

14
Review GOLOG (4)
  • Procedures
  • proc patrol(s)
  • at_west(self, s)? WalkEast()
  • or
  • at_east(self, s)? WalkWest()
  • endProc
  • Initial Situation at_west(self, So)
  • Run Program
  • patrol(So)

15
Review AgentSpeak(L) (1)
  • AgentSpeak(L) BDI Agents speak out in a logical
    computable language
  • Developed by Anand S. Rao in 1996

16
Review AgentSpeak(L) (2)
17
Review AgentSpeak(L) (3)
  • Plans
  • !patrol at_east(self) ? WalkWest(), !patrol.
  • !patrol at_west(self) ? WalkEast(), !patrol.
  • Events
  • lt!patrol, ltgt gt
  • Beliefs
  • at_east(self)
  • Intentions
  • lt !patrol at_east(self) ? WalkWest(),
    !patrol gt

18
Default Logic (1)
  • Developed by Ray Reiter in 1981
  • One of most well-known approach to non-monotonic
    reasoning
  • Example 1
  • Twitty is a bird (fact)
  • Bird normally flies (default 1)
  • Penguin normally does not fly (default 2)
  • Twitty is a bird, and Twitty flies (extension)

19
Default Logic (2)
  • Example 2
  • Twitty is a bird (fact 1)
  • Twitty is a penguin (fact 2)
  • Bird normally flies (default 1)
  • Penguin normally does not fly (default 2)
  • Twitty is a penguin, Twitty is a bird, and Twitty
    flies (extension 1)
  • Twitty is a penguin, Twitty is a bird, and Twitty
    does not fly (extension 2)

20
Reactive Planning APL
  • When thing turns out not as expected or turns
    wrong, agent will search for alternative plans,
    or repairing existing intentions
  • Background belief theory is used instead of just
    set of beliefs
  • Preferred extension of background belief theory
    is affected by performed actions

21
Reactive Planning APL
22
Background Belief Theory
23
Background Belief Theory
  • B (Delta, S, H, Ra)
  • Where
  • Delta is a default theory
  • S is a selection function which selection an
    extension of default theory to be agent current
    set of beliefs
  • H is an ordered set of performed actions (history
    of performed actions)
  • Ra is a set of action-predicted-result rules
  • A rule is of the form
  • action conditions ? expected result

24
Plan repository
  • Plan repository is set of pre-setup plans
  • A plan is of the form
  • trigger soft context, hard context ?
  • actions, goals.
  • Soft context needs satisfying when triggering the
    plan
  • Hard context needs satisfying when triggering the
    plan or executing the plan
  • A plan is called fail plan if its hard context
    fails during execution of the plan

25
Intentions
  • An intention is an ordered stack of plans
  • An intention is invalid if it has at least one
    fail plan
  • Agent will only execute an intention if it is
    valid

26
Events
  • Is of the form lttrigger, intentiongt
  • Where trigger is either
  • Add a goal
  • Remove a goal
  • Add a belief
  • Remove a belief
  • An event is an external event iff its intention
    is empty, it is an internal event otherwise
  • An event is invalid iff its intention is invalid

27
Agent program
  • Is of the form
  • ltB, P, E, I, Sp, Se, Sigt
  • Where
  • B is a background belief theory
  • P is a plan repository
  • E is a set of events
  • I is a set of intentions
  • Sp is a selection function which selects an
    applicable plan for a trigger
  • Se is a selection function which selects an event
    to process
  • Si is a selection function which selects an
    intention to execute

28
Operational Procedures
  • Event processing
  • Intention executing
  • Sensing procedure is a black-box in this program,
    however, result of sensing procedure or actions
    will create external events to set E of events

29
Event processing
  • Begin Procedure
  • select an event e
  • get current agent belief set BS
  • if (e is invalid) repair e end if
  • if event trigger is to add a goal then
  • select an applicable plan p
  • create an intention i from p and intention of e
  • add i to set I
  • else if event trigger is to remove a goal then
  • remove any intention to achieve that goal
  • else if event trigger is to add a belief then
  • revise background belief theory with this
    belief
  • else if event trigger is to delete a belief then
  • contract background belief theory with this
    belief
  • end if
  • Procedure

30
Intention executing
  • Begin Procedure
  • select an intention i
  • get current agent belief set BS
  • if (i is invalid) repair i end if
  • if next element to be executed is an action then
  • perform that action
  • else if next element to be executed is a goal
    then
  • create an internal event with i and that goal
    (add goal trigger)
  • else if next element to be executed is a test
    belief then
  • find the existential substitution from current
    set of beliefs for the test belief
  • else if there is no more elements
  • go to the next plan of i
  • else if the i is empty
  • remove i from I
  • end if
  • Procedure

31
Conclusion Future Research
  • Agent program can
  • Act proactively and reactively
  • Reason with incomplete information
  • Change beliefs subjectively (by means of
    selecting preferred extension of background
    belief theory and influent of history of action
    on this selection)
  • and cannot
  • Reason with time
  • Distinguish between belief revision and belief
    update (e.g. when to update, when to revise)
Write a Comment
User Comments (0)
About PowerShow.com