0% found this document useful (0 votes)
54 views46 pages

AI Unit I

The document introduces artificial intelligence and defines it as making computers behave like humans. It discusses different approaches to AI such as thinking humanly, thinking rationally, acting humanly, and acting rationally. It also covers characteristics of intelligent agents including their environment, structure, and different types of agents.

Uploaded by

SELVAGANESH N IT
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
54 views46 pages

AI Unit I

The document introduces artificial intelligence and defines it as making computers behave like humans. It discusses different approaches to AI such as thinking humanly, thinking rationally, acting humanly, and acting rationally. It also covers characteristics of intelligent agents including their environment, structure, and different types of agents.

Uploaded by

SELVAGANESH N IT
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd

UNIT I

INTRODUCTION

Introduction–Definition - Future of Artificial Intelligence – Characteristics of Intelligent Agents–


Typical Intelligent Agents – Problem Solving Approach to Typical AI problems.
Introduction
• Artificial Intelligence is the branch of computer science concerned with making computers
behave like humans.
• Coined and defined as “The science and engineering of making intelligent machines, especially
intelligent computer programs” by John McCarthy in 1956.
• Later the definition of AI was organized into 4 categories as:

[Link] Humanly
[Link] Rationally
[Link] Humanly
[Link] Rationally
Introduction

Thinking Humanly Thinking Rationally


“The exciting new effort to make computers think ... “The study of mental facilties through the use of
machines with minds, in the full and literal sense.” computational models.” (Charniak and McDermott,
(Haugeland, 1985) 1985)

“[The automation of] activities that we associate with “The study of the computations that make it possible
human thinking, activities such as decision-making, to perceive, reason, and act.” (Winston, 1992)
problem solving, learning ...” (Bellman, 1978)
Acting Humanly Acting Rationally
“The art of creating machines that perform functions “Computational Intelligence is the study of the design
that require intelligence when performed by people.” of intelligent agents.” (Poole et al., 1998)
(Kurzweil, 1990)

“The study of how to make computers do things at “AI . . . is concerned with intelligent behavior in
which, at the moment, people are better.” (Rich and artifacts.” (Nilsson, 1998)
Knight, 1991)
Introduction
Acting Humanly: Turning Test (Alan Turning,1950)
• A computer passes the test if a human interrogator, after posing some written questions, cannot
tell whether the written responses come from a person or from a computer.
• A computer with following capabilities can pass this test:
1. Natural Language Processing (NLP)
2. Knowledge representation
3. Automated reasoning
4. Machine learning
Introduction
Thinking humanly: The cognitive modeling approach
• There are 3ways to know how a human mind think:
1. Through introspection : Trying to catch our own thoughts as they go by.
2. Through psychological experiments : Observing a person in action.
3. Through brain imaging : Observing the brain in action.

Cognitive Science brings together computer models from AI and experimental techniques from
psychology to construct precise and testable theories of the human mind.
Introduction
Thinking rationally: The “laws of thought” approach

Example: Socrates is a man; all men are mortal; therefore, Socrates is mortal.
Introduction
Acting rationally: The rational agent approach
• An agent is just something that acts
• Operate autonomously, perceive their environment, persist over a prolonged time period, adapt to
change, and create and pursue goals.
• A rational agent is one that acts so as to achieve the best outcome.
Future of Artificial Intelligence (Applications)
Future of Artificial Intelligence (Applications)
Characteristics of Intelligent Agents
Characteristics of Intelligent Agents
Agent:An agent is anything that can be viewed as perceiving its environment
through sensors and acting upon that environment through actuators, Example:
Human driving a car
Percept: Refer to the agent’s perceptual inputs at any given instant. An agent’s
percept sequence is the complete history of everything the agent has ever
perceived.
Agent function for an artificial agent will be implemented by an agent program.
The agent program is a concrete implementation, running within some physical
system.
1. Human Agent
2. Robotic agent
3. Software agent
Characteristics of Intelligent Agents
Characteristics of Intelligent Agents
• A Rational agent is one that does the right thing.
• Every entry in the table for the agent function is filled out correctly.
• It is better to design performance measures according to what one actually wants in the
environment, rather than according to how one thinks the agent should behave.

Rational agent at any given time depends on four things:


[Link] performance measure that defines the criterion of success.
[Link] agent’s prior knowledge of the environment.
[Link] actions that the agent can perform.
[Link] agent’s percept sequence to date.
Characteristics of Intelligent Agents

For each possible percept sequence, a rational agent should select an action that is expected to
maximize its performance measure, given the evidence provided by the percept sequence and
whatever built-in knowledge the agent has.

Omniscience, learning, and autonomy:


• An omniscient agent knows the actual outcome of its actions and can act accordingly, but
omniscience is impossible in reality.
• Information gathering - Doing actions in order to modify future percepts.
• A rational agent should not only to gather information but also learn as much as possible from
what it perceives.
Characteristics of Intelligent Agents (Nature of Environment)
• Task environments are essentially the problems to which rational agents are the solutions.
• PEAS - Performance, Environment, Actuators, Sensors
Characteristics of Intelligent Agents (Nature of Environment)
Characteristics of Intelligent Agents (Nature of Environment)
Characteristics of Intelligent Agents (Nature of Environment)
Fully observable vs. partially observable:

Fully Observable Partially Observable


 The Agent’s sensors give it access to the  Noisy and inaccurate sensors or parts of the state
complete state of the environment at each point are missing from the sensor data.
in time
 The sensors detect all aspects that are relevant to  A vacuum agent with only a local dirt sensor
the choice of action which depends on cannot tell whether there is dirt in other squares.
performance measure
 Agent need not maintain any internal state to
keep track of the world.

An agent with no sensors in unobservable


Characteristics of Intelligent Agents (Nature of Environment)
Single agent vs Multiagent environment:
Single agent environment: Only one agent is involved in the environment, ex: Puzzle game.

Multiagent environment : Two or more agents are involved in the environment, ex: Chess game.

Multiagent

Cooperative Competitive
Characteristics of Intelligent Agents (Nature of Environment)
Deterministic vs. stochastic:

Deterministic: Next state of the environment is completely determined by the current state and the
action executed by the agent, ex: Vacuum cleaner.
Stochastic: Next state of environment cannot be determined by the current state and agent’s action,
ex: Taxi.
Characteristics of Intelligent Agents (Nature of Environment)
Episodic vs. Sequential:
Episodic:
 The agent’s experience is divided into atomic episodes.
 In each episode the agent receives a percept and then performs a single action.
 The next episode does not depend on the actions taken in previous episodes.
 Many classification tasks are episodic, (ex) an agent that has to spot defective parts on an
assembly line.
Sequential:
 The current decision could affect all future decisions.
 Chess and taxi driving are sequential.
 Episodic environments are much simpler than sequential environments because the agent does not
need to think ahead.
Characteristics of Intelligent Agents (Nature of Environment)
Static vs. Dynamic:
 If the environment can change while an agent is deliberating, then we say the environment is
dynamic, else it is static.
 Static environments are easy to deal with because the agent need not check the environment while
it is deciding on an action, or worry about the passage of time, ex: Puzzle
 In dynamic environments if the agent has not decided what to do, then it is counted as deciding to
do nothing, ex: Taxi driving.
 Semi dynamic: If the environment does not change with the passage of time but the agent’s
performance score does, the environment is semi dynamic, ex: chess played with clock.
Characteristics of Intelligent Agents (Nature of Environment)
Discrete vs. Continuous:
This distinction applies to the state of the environment, to the way time is handled, and to the
percepts and actions of the agent, ex: chess game and taxi.

Known vs. Unknown:


• In a known environment, the outcomes (or outcome probabilities if the environment is stochastic)
for all actions are given.
• If the environment is unknown, the agent will have to learn how it works in order to make good
decisions.
• A known environment can be partially observable, example: in solitaire card games, the player
know the rules but will not be able to see the cards that have not yet been turned over.
• An unknown environment can be fully observable, example: A new video game.
Characteristics of Intelligent Agents (Nature of Environment)
The Structure of Agents
• The job of AI is to design an agent program that implements the agent function(Mapping from
percepts to actions).
• This program will run on some sort of computing device with physical sensors and actuators, this
is known as agent architecture:
Agent = Architecture + Program
Agent Program:
• Program takes the current percept as input from the sensors and return an action to the actuators.
• The agent function takes the entire percept history.
The Structure of Agents
The agent structure can be classified into four types as follows:
1. Simple reflex agents
2. Model-based reflex agents
3. Goal-based agents
4. Utility-based agents
The Structure of Agents
The Structure of Agents
• These agents select actions on the basis of the current percept, ignoring the rest of the percept
history, ex: Vacuum cleaner.

Condition - action rule : if car-in-front-is-braking then initiate-braking.


The Structure of Agents
Characteristics
 Only works if the environment is fully observable.
 Lacking history, easily get stuck in infinite loops
 One solution is to randomize actions
The Structure of Agents
Model-based reflex agents
The Structure of Agents
The Structure of Agents
Goal based agent
The Structure of Agents
Utility based agent
The Structure of Agents
• Goals alone are not enough to generate high-quality behavior in most
environments.
• An agent’s utility function is essentially an internalization of the performance
measure.
• If the internal utility function and the external performance measure are in
agreement, then an agent that chooses actions to maximize its utility will be
rational.
• In two kinds of cases, goals are inadequate but a utility-based agent can still make
rational decisions:
1. There are conflicting goals.
2. There are several goals that the agent can aim for.
The Structure of Agents
• A rational utility-based agent chooses the action that maximizes the expected
utility of the action outcomes.
• An agent that possesses an explicit utility function can make rational decisions
with a general-purpose algorithm.
The Structure of Agents
Learning agents:
The Structure of Agents
• Turing (1950) considers the idea of actually programming his intelligent machines
by hand.
• The method he proposes is to build learning machines and then to teach them.
• Learning allows the agent to operate in initially unknown environments and to
become more competent than its initial knowledge alone might allow.
1. Learning element - Responsible for making improvements.
2. Performance element -Responsible for selecting external actions. The
performance element is what we have previously considered to be the entire
agent, it takes in percepts and decides on actions.
3. Critic - Tells the learning element how well the agent is doing with respect to a
fixed performance standard.
The Structure of Agents
4. Problem generator - Responsible for suggesting actions that will lead to new and
informative experiences.
How the components of agent programs work?
The Structure of Agents
Atomic:
• In an atomic representation each state of the world is indivisible—it has no
internal structure.
• Consider the problem of finding a driving route from one end of a country to the
other via some sequence of cities
• For the purposes of solving this problem, it may suffice to reduce the state of
world to just the name of the city we are in—a single atom of knowledge;
• Searching and game playing algo work in atomic nature.
The Structure of Agents
Factored:
• A factored representation splits up each state into a fixed set of variables or
attributes, each of which can have a value.
• Consider the detailed description of the same problem, with fuel, toll expense etc.
• Classification algorithms follow factored method of working
The Structure of Agents
Structured:
• We need to understand the world as having things in it that are related to each
other, not just variables with values.
• For example, we might notice that a large truck ahead of us is reversing into the
driveway of a dairy farm but a cow has got loose and is blocking the truck’s path.
• A factored representation is unlikely to be pre-equipped with the attributes.
• In a structured representation, in which objects such as cows and trucks and their
various and varying relationships can be described explicitly.
• First Order Logic follow structured working.
Problem Solving Approach to Typical AI problems
• Goals help to organize the behavior by limiting the objectives that the agent is
trying to achieve and hence the actions it needs to consider.
• Goal formulation is the first step in problem solving based on the current situation
and the agent’s performance measure.
• Problem formulation is the process of deciding what actions and states to
consider, given a goal.
• The process of looking for a sequence of actions that reaches the goal is called
search.
Problem Solving Approach to Typical AI problems
• A search algorithm takes a problem as input and returns a solution in the form of
an action sequence.
• Once a solution is found, the actions it recommends can be carried out. This is
called the execution phase.
Problem Solving Approach to Typical AI problems
Well-defined problems and solutions:
A problem can be defined formally by five components as follows,
1. The initial state that the agent starts in.
2. A description of the possible actions available to the agent.
3. A description of what each action does, it is known as the transition model.
• Together, the initial state, actions, and transition model implicitly define the state
space of the problem - the set of all states reachable from the initial state by any
sequence of actions.
• The state space forms a directed network or graph in which the nodes are states
and the links between nodes are actions.
• A path in the state space is a sequence of states connected by a sequence of
actions.
Problem Solving Approach to Typical AI problems
4. The goal test, which determines whether a given state is a goal state.
5. A path cost function that assigns a numeric cost to each path.

• A solution to a problem is an action sequence that leads from the initial state to a
goal state.
• Solution quality is measured by the path cost function, and an optimal solution has
the lowest path cost among all solutions.
Problem Solving Approach to Typical AI problems
Problems discussed in class:
1. Water jug problem
2. Magic square problem

Home works:
3. 8 queen problem
4. Tower of Hanoi problem
5. Tic-Tac-Toe problem

You might also like