1
Department of Mechanical Engineering
National Institute of Technology Jamshedpur
Deepak Kumar,
Department of Mechanical Engineering, NIT Jamshedpur
deepak.me@nitjsr.ac.in
Artificial Intelligence and Machine Learning
2
• What is Artificial Intelligence?
• A Brief History
• Intelligent agents
• State of the art
Department of Mechanical Engineering
Summary of the Previous Class
3
• What is Agents?
• Agent Types
• PEAS
Department of Mechanical Engineering
Today’s Class
4
Logic
• Logical systems
– Theorem provers
– NASA fault diagnosis
– Question answering
• Methods:
– Deduction systems
– Constraint satisfaction
– Satisfiability solvers (huge
advances!)
Image from Bart Selman
Department of Mechanical Engineering
5
Game Playing
• Classic Moment: May, '97: Deep Blue vs. Kasparov
– First match won against world champion
– “Intelligent creative” play
– 200 million board positions per second
– Humans understood 99.9 of Deep Blue's moves
– Can do about the same now with a PC cluster
• Open question:
– How does human cognition deal with the
search space explosion of chess?
– Or: how can humans compete with computers at all??
• 1996: Kasparov Beats Deep Blue
“I could feel --- I could smell --- a new kind of intelligence across the table.”
• 1997: Deep Blue Beats Kasparov
“Deep Blue hasn't proven anything.”
• Huge game-playing advances recently, e.g. in Go!
Text from Bart Selman, image from IBM’s Deep Blue pages
Department of Mechanical Engineering
6
Decision Making
– Applied AI involves many kinds of automation
• Scheduling, e.g. airline routing, military
• Route planning, e.g. Google maps
• Medical diagnosis
• Web search engines
• Spam classifiers
• Automated help desks
• Fraud detection
• Product recommendations
• … Lots more!
Department of Mechanical Engineering
7
Agents
• Agents and environments
• Rationality
• PEAS (Performance measure, Environment, Actuators,
Sensors)
• Environment types
• Agent types
Department of Mechanical Engineering
8
Agents
• An agent is anything that can be viewed as perceiving its
environment through sensors and acting upon that
environment through actuators
• Human agent: eyes, ears, and other organs for sensors;
hands,
• legs, mouth, and other body parts for actuators
• Robotic agent: cameras and infrared range finders for
sensors;
• various motors for actuators
Department of Mechanical Engineering
9
Agents and environments
• The agent function maps from percept histories to actions:
•
[f: P* → A]
• The agent program runs on the physical architecture to
produce f
• agent = architecture + program
Department of Mechanical Engineering
10
Vacuum-cleaner world
• Percepts: location and contents, e.g., [A,Dirty]
• Actions: Left, Right, Suck, NoOp
Department of Mechanical Engineering
11
Designing Rational Agents
• An agent is an entity that perceives and acts.
• A rational agent selects actions that maximize
its (expected) utility.
• Characteristics of the percepts, environment,
and action space dictate techniques for
selecting rational actions
Agent
?
Sensors
Actuators
Environment
Percepts
Actions
Department of Mechanical Engineering
12
Rational agents
• An agent should strive to "do the right thing", based on
what it can perceive and the actions it can perform. The
right action is the one that will cause the agent to be
most successful
• Performance measure: An objective criterion for success
of an agent's behavior
• E.g., performance measure of a vacuum-cleaner agent
could be amount of dirt cleaned up, amount of time
taken, amount of electricity consumed, amount of noise
generated, etc.
Department of Mechanical Engineering
13
Rational agents
• Rational Agent: 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.
Department of Mechanical Engineering
14
What’s involved in Intelligence? Intelligent agents
• Ability to interact with the real world
– to perceive, understand, and act
– e.g., speech recognition and understanding and synthesis
– e.g., image understanding
– e.g., ability to take actions, have an effect
• Knowledge Representation, Reasoning and Planning
– modeling the external world, given input
– solving new problems, planning and making decisions
– ability to deal with unexpected problems, uncertainties
• Learning and Adaptation
– we are continuously learning and adapting
– our internal models are always being “updated”
• e.g. a baby learning to categorize and recognize
animals
Department of Mechanical Engineering
15
Implementing agents
• Table look-ups
• Autonomy
– All actions are completely specified
– no need in sensing, no autonomy
– example: Monkey and the banana
• Structure of an agent
– agent = architecture + program
– Agent types
• medical diagnosis
• Satellite image analysis system
• part-picking robot
• Interactive English tutor
• cooking agent
• taxi driver
Department of Mechanical Engineering
16
Department of Mechanical Engineering
Vacuum Cleaner Problems
17
Department of Mechanical Engineering
18
Department of Mechanical Engineering
19
Agent types
• Example: Taxi driver
• Simple reflex
– If car-in-front-is-breaking then initiate-breaking
• Agents that keep track of the world
– If car-in-front-is-breaking and on fwy then initiate-breaking
– needs internal state
• goal-based
– If car-in-front-is-breaking and needs to get to hospital then
go to adjacent lane and plan
– search and planning
• utility-based
– If car-in-front-is-breaking and on fwy and needs to get to
hospital alive then search of a way to get to the hospital
that will make your passengers happy.
– Needs utility function that map a state to a real function (am
I happy?)
Department of Mechanical Engineering
20
Autonomy in Agents
• Extremes
– No autonomy – ignores environment/data
– Complete autonomy – must act randomly/no program
• Example: baby learning to crawl
• Ideal: design agents to have some autonomy
– Possibly become more autonomous with experience
The autonomy of an agent is the extent to which its
behaviour is determined by its own experience,
rather than knowledge of designer.
Department of Mechanical Engineering
21
PEAS
a modern approach
1
• PEAS: Performance measure, Environment,
Actuators, Sensors
• Must first specify the setting for intelligent agent
design
• Consider, e.g., the task of designing an automated
taxi driver:
– Performance measure: Safe, fast, legal, comfortable trip,
maximize profits
– Environment: Roads, other traffic, pedestrians, customers
– Actuators: Steering wheel, accelerator, brake, signal, horn
– Sensors: Cameras, sonar, speedometer, GPS, odometer, engine
sensors, keyboard
Department of Mechanical Engineering
22
PEAS
a modern approach
2
• Agent: Part-picking robot
• Performance measure: Percentage of parts in correct bins
• Environment: Conveyor belt with parts, bins
• Actuators: Jointed arm and hand
• Sensors: Camera, joint angle sensors
Department of Mechanical Engineering
23
PEAS
a modern approach
3
• Agent: Interactive English tutor
• Performance measure: Maximize student's score on test
• Environment: Set of students
• Actuators: Screen display (exercises, suggestions,
corrections)
• Sensors: Keyboard
Department of Mechanical Engineering

Machine Learning Lecture Number two

  • 1.
    1 Department of MechanicalEngineering National Institute of Technology Jamshedpur Deepak Kumar, Department of Mechanical Engineering, NIT Jamshedpur deepak.me@nitjsr.ac.in Artificial Intelligence and Machine Learning
  • 2.
    2 • What isArtificial Intelligence? • A Brief History • Intelligent agents • State of the art Department of Mechanical Engineering Summary of the Previous Class
  • 3.
    3 • What isAgents? • Agent Types • PEAS Department of Mechanical Engineering Today’s Class
  • 4.
    4 Logic • Logical systems –Theorem provers – NASA fault diagnosis – Question answering • Methods: – Deduction systems – Constraint satisfaction – Satisfiability solvers (huge advances!) Image from Bart Selman Department of Mechanical Engineering
  • 5.
    5 Game Playing • ClassicMoment: May, '97: Deep Blue vs. Kasparov – First match won against world champion – “Intelligent creative” play – 200 million board positions per second – Humans understood 99.9 of Deep Blue's moves – Can do about the same now with a PC cluster • Open question: – How does human cognition deal with the search space explosion of chess? – Or: how can humans compete with computers at all?? • 1996: Kasparov Beats Deep Blue “I could feel --- I could smell --- a new kind of intelligence across the table.” • 1997: Deep Blue Beats Kasparov “Deep Blue hasn't proven anything.” • Huge game-playing advances recently, e.g. in Go! Text from Bart Selman, image from IBM’s Deep Blue pages Department of Mechanical Engineering
  • 6.
    6 Decision Making – AppliedAI involves many kinds of automation • Scheduling, e.g. airline routing, military • Route planning, e.g. Google maps • Medical diagnosis • Web search engines • Spam classifiers • Automated help desks • Fraud detection • Product recommendations • … Lots more! Department of Mechanical Engineering
  • 7.
    7 Agents • Agents andenvironments • Rationality • PEAS (Performance measure, Environment, Actuators, Sensors) • Environment types • Agent types Department of Mechanical Engineering
  • 8.
    8 Agents • An agentis anything that can be viewed as perceiving its environment through sensors and acting upon that environment through actuators • Human agent: eyes, ears, and other organs for sensors; hands, • legs, mouth, and other body parts for actuators • Robotic agent: cameras and infrared range finders for sensors; • various motors for actuators Department of Mechanical Engineering
  • 9.
    9 Agents and environments •The agent function maps from percept histories to actions: • [f: P* → A] • The agent program runs on the physical architecture to produce f • agent = architecture + program Department of Mechanical Engineering
  • 10.
    10 Vacuum-cleaner world • Percepts:location and contents, e.g., [A,Dirty] • Actions: Left, Right, Suck, NoOp Department of Mechanical Engineering
  • 11.
    11 Designing Rational Agents •An agent is an entity that perceives and acts. • A rational agent selects actions that maximize its (expected) utility. • Characteristics of the percepts, environment, and action space dictate techniques for selecting rational actions Agent ? Sensors Actuators Environment Percepts Actions Department of Mechanical Engineering
  • 12.
    12 Rational agents • Anagent should strive to "do the right thing", based on what it can perceive and the actions it can perform. The right action is the one that will cause the agent to be most successful • Performance measure: An objective criterion for success of an agent's behavior • E.g., performance measure of a vacuum-cleaner agent could be amount of dirt cleaned up, amount of time taken, amount of electricity consumed, amount of noise generated, etc. Department of Mechanical Engineering
  • 13.
    13 Rational agents • RationalAgent: 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. Department of Mechanical Engineering
  • 14.
    14 What’s involved inIntelligence? Intelligent agents • Ability to interact with the real world – to perceive, understand, and act – e.g., speech recognition and understanding and synthesis – e.g., image understanding – e.g., ability to take actions, have an effect • Knowledge Representation, Reasoning and Planning – modeling the external world, given input – solving new problems, planning and making decisions – ability to deal with unexpected problems, uncertainties • Learning and Adaptation – we are continuously learning and adapting – our internal models are always being “updated” • e.g. a baby learning to categorize and recognize animals Department of Mechanical Engineering
  • 15.
    15 Implementing agents • Tablelook-ups • Autonomy – All actions are completely specified – no need in sensing, no autonomy – example: Monkey and the banana • Structure of an agent – agent = architecture + program – Agent types • medical diagnosis • Satellite image analysis system • part-picking robot • Interactive English tutor • cooking agent • taxi driver Department of Mechanical Engineering
  • 16.
    16 Department of MechanicalEngineering Vacuum Cleaner Problems
  • 17.
  • 18.
  • 19.
    19 Agent types • Example:Taxi driver • Simple reflex – If car-in-front-is-breaking then initiate-breaking • Agents that keep track of the world – If car-in-front-is-breaking and on fwy then initiate-breaking – needs internal state • goal-based – If car-in-front-is-breaking and needs to get to hospital then go to adjacent lane and plan – search and planning • utility-based – If car-in-front-is-breaking and on fwy and needs to get to hospital alive then search of a way to get to the hospital that will make your passengers happy. – Needs utility function that map a state to a real function (am I happy?) Department of Mechanical Engineering
  • 20.
    20 Autonomy in Agents •Extremes – No autonomy – ignores environment/data – Complete autonomy – must act randomly/no program • Example: baby learning to crawl • Ideal: design agents to have some autonomy – Possibly become more autonomous with experience The autonomy of an agent is the extent to which its behaviour is determined by its own experience, rather than knowledge of designer. Department of Mechanical Engineering
  • 21.
    21 PEAS a modern approach 1 •PEAS: Performance measure, Environment, Actuators, Sensors • Must first specify the setting for intelligent agent design • Consider, e.g., the task of designing an automated taxi driver: – Performance measure: Safe, fast, legal, comfortable trip, maximize profits – Environment: Roads, other traffic, pedestrians, customers – Actuators: Steering wheel, accelerator, brake, signal, horn – Sensors: Cameras, sonar, speedometer, GPS, odometer, engine sensors, keyboard Department of Mechanical Engineering
  • 22.
    22 PEAS a modern approach 2 •Agent: Part-picking robot • Performance measure: Percentage of parts in correct bins • Environment: Conveyor belt with parts, bins • Actuators: Jointed arm and hand • Sensors: Camera, joint angle sensors Department of Mechanical Engineering
  • 23.
    23 PEAS a modern approach 3 •Agent: Interactive English tutor • Performance measure: Maximize student's score on test • Environment: Set of students • Actuators: Screen display (exercises, suggestions, corrections) • Sensors: Keyboard Department of Mechanical Engineering