ann nowe vub 1 what are agents anyway?. ann nowe vub 2 overview agents agent environments...
TRANSCRIPT
Ann NoweVUB
1
What are agents anyway?
Ann NoweVUB
2
Overview
• Agents
• Agent environments
• Intelligent agents
• Agents versus objects
Ann NoweVUB
3
Agent – Wooldridge & Jennings
A computer system that is situated in some environment and is capable of autonomous action in its environment to meet its design
objectives.
Learning?
Ann NoweVUB
4
Agent – Russell & Norvig
• An agent is anything that can be viewed as– Perceiving its environment– Acting upon that environment
• What is the difference between the two definitions???
Ann NoweVUB
5
Autonomy
agents operate
without the direct intervention of humans or
other agents, and have some kind of
control over their actions and internal state
Ann NoweVUB
6
Agent and Environment
Agent Enviro
nment
Sensors
Effectors
autonomousprocessing
ActionOutput
SensorInput
Ann NoweVUB
7
Intelligent Agents
• Intelligent agents require flexible autonomous action
• Requires the following attributes
– reactivity
– pro-activity
– social ability
Ann NoweVUB
8
Reactive
agents perceive their environment and
respond, in a timely fashion, to changes
that occur in it
Ann NoweVUB
9
Pro-active
agents do not simply react to their
environment, they are able to exhibit
goal-directed behavior by taking the
initiative
Key is a balance between goal-directedand reactive behavior!
Ann NoweVUB
10
Social
agents interact with other agents, and
possibly humans, via an agent-
communication language
Social ability implies coordinationcooperation versus competition
Ann NoweVUB
11
Example/Non-Example
• Information seeking agent– The user tells the agent what type of
information is desired.– The agent goes to known web sites, databases,
and other sources (including other agents) to collect information about the desired subject.
– After collecting the data, the agent “fuses” the information into a succinct report and returns it to the user.
Ann NoweVUB
12
Example/Non-Example
• Print agent– The user submits documents to the agent and tells it
what printer to use.
– The agent takes the user’s document, as well as documents from other users, orders them by size and prints them one by one.
– The agent returns the current status of the document and printer when asked by the user.
– The agent tells the user when the document has been printed.
Ann NoweVUB
13
Example/Non-Example
• Contract Manager agent– The user gives the agent a task to perform– The manager agent then sends the task to a group of
contractor agents for bid– If the contractor agents want to bid, they submit a bid
on the task– The manager agent waits for a time and then selects the
best bid submitted by potential contractor agents– Upon completion, the manager agent notifies the user
Ann NoweVUB
14
Agents vs. Objects
• Aren’t agents just like objects?
• YES– Computational entities– Encapsulate state– Perform actions– Communicate via message passing
Ann NoweVUB
15
Agents vs. Objects
• Aren’t agents just like objects?
• NO– Agents embody a strong notion of autonomy– Agents are capable of flexible behavior– Agents operate in their own thread of control
Objects : invokeAgents : request
Ann NoweVUB
16
Agents vs. Objects
• Can’t you build OO systems with these characteristics?– Yes, but you have built a multiagent system
using object-oriented tools and techniques!– That makes agents a specialization of the
general notion of an object
An active object is one that encompasses its own thread of control […]. Active objects are generally autonomous, meaning that they can exhibit some behavior without being operated upon by another object. Passive objects on the other hand, can only undergo a state change when explicitly acted upon. G. Booch
Ann NoweVUB
17
Programming progression
• Programming has progressed through:
– machine code– assembly language– machine-independent programming languages– sub-routines– procedures & functions– abstract data-types– objects
to – agents
Ann NoweVUB
18
Agents vs. Expert systems
Expert systems
• do not directly act on environments, act as consultants.
• input not via sensors, but via users, who act as middle man
• cooperation? maybe backboards
Ann NoweVUB
19
Summary
• Agents are capable of autonomous action in its environment to meet its design objectives
• Intelligent agents require flexible autonomous action to meet its objectives
• Agents are a specialization of objects that are autonomous, flexible, and operate in their own thread of control
Ann NoweVUB
20
Agent Architectures
Ann NoweVUB
21
Overview
• Abstract Architectures– State, Action, Perception– Reflexive agents, Agents with state
• Concrete Architectures– Logic– Reactive– Belief-Desire-Intention– Layered
Ann NoweVUB
22
Abstract Architectures
• Formalize abstract view
– S = {s1, s2, …} – environment states
– A = {a1, a2, …} – set of possible actions
• Allows us to view an agent as a functionaction : S* A
• Interactions of agent and environment – history
a1 a2 a3 a4 an an+1 h : s0 s1 s2 s3 … sn …
Ann NoweVUB
23
Abstract Architecture
action
Environment
actionsstates
action
env : S x A (S)action : S* A
Ann NoweVUB
24
Perceiving State
• Agent can’t see state directly– Requires perception
see : S* P
• And action is actually based on perceptions, not state
action : P* A
Ann NoweVUB
25
Perceiving State
Environment
actionsstates see action
Ann NoweVUB
26
• Reflexive agents decide what to do without regard to history – purely reflexive
action : P A
• Example - thermostat
off if temp = okaction(s) =
on otherwise
Ann NoweVUB
27
Agents with State
• How do we represent the history of percepts?– Sequence of perceptions is unintuitive and
computationally inefficient An agent can maintain its perception of
the current state of the environment Equivalent to history of perceptions Requires more machinery
Ann NoweVUB
28
Abstract States
• Represent new construct - state
I = {i1, i2, i3 …} – set of internal states
• We now map internal state to actions
action : I A
• Update internal state
next : I x P I
Ann NoweVUB
29
Agents with State
Environment
actionsstates
see action
next state
Ann NoweVUB
30
Concrete Architectures
• Logic-Based Architectures
• Reflexive Architectures
• Belief-Desires-Intentions Architectures
• Layered Architectures
Ann NoweVUB
31
See and Next Functions
• See and next function stay basically the same
see : S P
next : D x P D
Internal state = set of logical expressions
e.g. In(x,y) Dirt(x,y) Facing(d)
What the agentbelieves is true
Ann NoweVUB
32
• Model decision making by a set of deduction rules for inference
action : D A
• Use logical deduction to try to prove the next action to take, given the current state. If no action can be proven, select an action that is consistent with the rules and database
Logical Decision Making
In(x,y) &Dirt(x,y) -> Do(suck)In(0,0) & notDirt(0,0) & Facing(north) -> Do(forward)In(0,1) & notDirt(0,1) & Facing(north) -> Do(forward)In(0,2) & notDirt(0,2) & Facing(north) -> Do(turn_right)
Ann NoweVUB
33
• Pro– Simple, elegant, logical semantics
• Con– Computational complexity– Representing the real world– not applicable in (fast) changing environments
Logical Agency Summary
Ann NoweVUB
34
Reactive Architectures
• Reactive Architectures do NOT use– symbolic world model
– symbolic reasoning
• Three key ideas of reactive agents (Brooks)– raw sensor data - representation of data is close to sensor
data, not symbolic (physical-symbol grounding hypothesis)– emergent functionality - no a priori specification of
behavior– task decomposition - composed of a collection of
autonomous modules, each responsible for a single task
Ann NoweVUB
35
Brook’sSubsumption Architecture
Explore
Wander
Avoid Obstacles
Sensing
Acting
Originally developed to control RobotsHierarchy of tasksTasks “compete” to exercise controlLower levels represent more primitive behaviorsLower levels have precedence
Ann NoweVUB
36
Subsumption architectuur
• A set of behaviors, one for each task.– A behavior is:
• ‘situation action’ rule, or
• a neural network, or ...
– A direct link between situation and action.
• An ordering on behaviors.– The subsumption hierarchies.– Lower levels inhibit higher levels.
Ann NoweVUB
37
Layered behaviors
sensors behavior 0
behavior 1
behavior 2
::
actions
s
s
Ann NoweVUB
38
Limitations
• Suppose the robot wants to go to the goal. Can we do this with the subsumption architecture?
Ann NoweVUB
39
emergent behavior
Pros & Cons
• Pros– Simplicity, computationally tractable, robust,
elegance
• Cons– Sufficiency of local information is needed– No accounting for non-local/long term effects– How to do learning
Ann NoweVUB
40
Belief-Desires-Intentions
• Rooted in practical reasoning– Deciding what goals to achieve– Deciding how to achieve those goals
• BDI– Beliefs = current state
– Desires = possible goals
– Intentions = chosen goals
Ann NoweVUB
41
BeliefDesires
Intentions
Beliefs
beliefrevision
generateoptions
Desires
filter Intentions
actionsee
Environment
Ann NoweVUB
42
BDI Pros & Cons
• Pros– Intuitive– Clear functional decomposition
• Cons– Efficiency– Commitment vs. reconsideration
Ann NoweVUB
43
Layered Architectures
• Based on separating reactive, pro-active and social behavior– May be other layers
• Layering– Horizontal
• I/O connected to each layer
– Vertical• I/O dealt with by single layer
Ann NoweVUB
44
TouringMachines
• Reactive layer: fast action.• Planning layer: pro-active; no planning but
predefined plans.• Modelling layer: generates goals.
Modeling layer
Planning layer
reactive layer
controle
perception action
Ann NoweVUB
45
Layered Pros & Cons
• Pros– Most popular– Natural decomposition for social, reactive, and
pro-active behavior
• Cons– Lack conceptual and semantic clarity– Complex interactions between layers
Ann NoweVUB
46
Summary
• Abstract Architectures– State, Action, Perception– Reflexive agents, Agents with state
• Concrete Architectures– Logic– Reactive– Belief-Desire-Intention– Layered