Week 3 Topic 2 Intelligent Agents
Week 3 Topic 2 Intelligent Agents
Intelligent agents
❑ What is an agent ?
❑ Agents and environment
❑ Define a rational agent
❑ PEAS: Performance measure, Environment, Actuators,
Sensors
❑ Types of AI Agents
❑ Applications of intelligent agent
Intelligent agent
Function Reflex-Vacuum-Agent([location,status])
return an action
If status = Dirty then return Suck
else if location = A then return Right
else if location = B then return left
Rational agent
❑A rational agent is a type of intelligent agent that always
takes the action expected to maximize its performance
measure, based on the available evidence and built-in
knowledge.
❑A rational AI agent is a system that makes optimal
decisions to achieve its goals, while an intelligent agent
learns and adapts to its environment.
❑AI agents are rational agents.
Rational Agent
❑ Rationality of an agent depends on the following four factors:
❖ Performance measuring success.
❖ Agent’s prior knowledge of environment.
❖ Actions that agent can perform.
❖ Agent’s percept sequence to date.
percepts
(size, motion)
RULES:
(1) If small moving object,
then activate SNAP
(2) If large moving object,
then activate AVOID and inhibit SNAP
ELSE (not moving) then NO-OP
Model-based reflex
agents
❑A reflex agent with internal state use both their
current perception and memory to maintain an internal
model of the world.
❑As this agent continues to receive new information,
the model is updated. The agent’s actions depend
on its model, reflexes, previous precepts and
current state.
Model-based reflex agents
❑ The internal state information should be updated as the time
goes by, and it requires two kinds of knowledge to
be encoded in the agent program:
❖Information about how the world evolves independently of
the agent.
❖Information about how the agent's own actions affects the
world.
Example of Model-based reflex agents: A
robot vacuum cleaner
As it cleans a dirty room, it senses obstacles such as furniture and
adjusts around them. The robot also stores a model of the areas it has
already cleaned to not get stuck in a loop of repeated cleaning.
Tesla’s Autopilot: continuously process sensor data to navigate safely in
changing traffic conditions.
Model-based reflex
agents
Test your Knowledge…
A reflex agent with internal state uses both their current _______ and
memory to maintain an internal model of the world. As this agent
continues to receive new ________, the model is updated.
The agent’s actions depend on its _______, reflexes, previous _______
and current state.
Goal-based agents
❑ These agents search for action sequences to achieve a goal or set of goals e.g.
where the taxi wants to go.
❑ Goal-based agents plan these actions before acting on them. This search and
planning improve their effectiveness when compared to simple and model-
based reflex agents.
❑ Goal-based agents is not only using percept history and internal memory to
understand their environment but also considering the impact of their possible
actions before performing them. This allows goal-based agents to think beyond
the present moment and decide the best actions to take to achieve their
objectives (i.e: “what will happen if I do…?” (search and planning))
Goal-based agents
Unlike the previous reflex agents before acting this agent reviews many actions
and chooses the one which come closest to achieving its goals, whereas the
reflex agents just have an automated response for certain situations.
For example, in autonomous driving, a goal-based agent plans routes, adapts to
traffic, and ensures safe travel.
Example of Goal-based agents: Amazon’s Kiva Robots
Those robots are widely regarded as goal-based agents, planning optimal paths
to retrieve and deliver inventory efficiently.
Goal-based agents
Utility-based agent
❑ Goals are not always enough:
❖ Many action sequences get the taxi to its destination (goal)
❖ Consider other things: How fast, how safe…..
❑ Utility-based agents select the sequence of actions that reach the goal
describe maximize utility or reward.
❑ Utility is calculated using a utility function that assigns a utility value to
each scenario based on a set of fixed criteria.
❑ This value measure the degree of “happiness”, “goodness”, “success” of the
agent.
❑ If goal means success, then utility means the degree of success (how
successful it is).
Example Utility-based agent: A navigation system that
recommends the route to your destination that optimizes
fuel efficiency and minimizes the time spent in traffic and
the cost of tolls. This agent measures utility through this set
of criteria to select the most favorable route.
Utility-based agent
Learning agent
❑ In AI, Learning agents hold the same capabilities as the other agent types
but are unique in their ability to learn. New experiences are added to
their initial knowledge base, which occurs autonomously.
❑ We then say the agent learns (A learning agent).
❑ Learning also allows the agent to operate in initially unfamiliar
environments and to become more competent than its initial knowledge
alone might allow.
❑ Example of learning agent: Personalized recommendations on e-
commerce sites. These agents track user activity and preferences in their
memory. This information is used to recommend certain products and
services to the user. The cycle repeats each time new recommendations
are made. The user’s activity is continuously stored for learning purposes.
In doing so, the agent improves its accuracy over time.
Learning agent
Learning agent
Learning agents include four main elements:
❑Learning element : This improves the agent’s knowledge by
learning from the environment through its precepts and sensors.
❑ Performance element : This element is responsible for selecting
actions upon learning.
❑ Learning element uses feedback from the critic on how the
agent is doing and determines how the performance element
should be modified to do better in the future.
❑ Problem generator is responsible for suggesting actions that will
lead to a new and informative experiences
Applications of
intelligent agent
❑ AI assistants such as Alexa and Siri are examples of intelligent AI agents
that use sensors to perceive a user request and automatically collect data
from the internet without the user's help. They can gather information
about their observable environments, such as weather and time.
❑ Google Assistant is another example of an intelligent AI agent. It
uses machine learning and natural language processing technology
to answer users' questions and perform tasks, such as calling
contacts stated in voice commands.
❑ Global Positioning System navigation and cameras for reactive
decision-making in the real world to maneuver through traffic.
Thank you for you attention