0% found this document useful (0 votes)
32 views

1 Introduction To AI

The document discusses key concepts in artificial intelligence including definitions of AI, intelligence, and rational thinking. It outlines different approaches to AI like systems that act like humans or think rationally. Applications of AI are also mentioned.

Uploaded by

Sawaira Kazmi
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)
32 views

1 Introduction To AI

The document discusses key concepts in artificial intelligence including definitions of AI, intelligence, and rational thinking. It outlines different approaches to AI like systems that act like humans or think rationally. Applications of AI are also mentioned.

Uploaded by

Sawaira Kazmi
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
You are on page 1/ 72

COMSATS UNIVERSITY ISLAMABAD

Attock Campus

Artificial Intelligence

Salah Ud Din
Lecturer
Department of Computer Science
Reading Material

Chapter#1
Artificial Intelligence: A Modern Approach, Russell, S., &
Norvig, P., (2013), Prentice Hall
Artificial Intelligence in the Movies
Artificial Intelligence in Real Life
A young science (≈ 50 years old)
– Exciting and dynamic field, lots of uncharted territory left
– Impressive success stories
– “Intelligent” in specialized domains
– Many application areas

Face detection Formal verification


Why the interest in AI?

Search engines
Science

Medicine/
Diagnosis
Labor
Appliances What else?
What is intelligence?
• Intelligence is the computational part of the ability to
achieve goals in the world. Varying kinds and degrees of
intelligence occur in people, many animals and some
machines.
• Is there a “holistic” definition for intelligence? Here are
some definitions:
• the ability to comprehend; to understand and profit from experience
• a general mental capability that involves the ability to reason, plan,
solve problems, think abstractly, comprehend ideas and language, and
learn
• is effectively perceiving, interpreting and responding to the environment
• None of these tells us what intelligence is, so instead,
maybe we can enumerate a list of elements that an
intelligence must be able to perform:
– perceive, reason and infer, solve problems, learn and adapt, apply
common sense, apply analogy, recall, apply intuition, reach
emotional states, achieve self-awareness
What is artificial intelligence?
• There is no clear consensus on the definition of AI
• John McCarthy coined the phrase AI in 1956
• It is the science and engineering of making intelligent
machines, especially intelligent computer programs.
• It is related to the similar task of using computers to
understand human or other intelligence, but AI does not
have to confine itself to methods that are biologically
observable.
• Computers were thought of as an electronic brains
• Term “Artificial Intelligence” coined by John McCarthy
– John McCarthy also created Lisp in the late 1950s
• Alan Turing defines intelligence as passing the Imitation
Game (Turing Test)
What is AI? (Cont’d)
What is Artificial Intelligence ?

THOUGHT Systems that think Systems that think


like humans rationally

Systems that act Systems that act


BEHAVIOUR like humans rationally

HUMAN RATIONAL
Systems that act like humans:
Turing Test
• “The art of creating machines that perform
functions that require intelligence when
performed by people.” (Kurzweil)
• “The study of how to make computers do things
at which, at the moment, people are better.”
(Rich and Knight)
Systems that act like humans

?
• You enter a room which has a computer terminal. You
have a fixed period of time to type what you want into the
terminal, and study the replies. At the other end of the
line is either a human being or a computer system.
• If it is a computer system, and at the end of the period
you cannot reliably determine whether it is a system or a
human, then the system is deemed to be intelligent.
Systems that act like humans

• The Turing Test approach


– a human questioner cannot tell if
• there is a computer or a human answering his question,
via teletype (remote communication)
– The computer must behave intelligently
• Intelligent behavior
– to achieve human-level performance in all
cognitive tasks
Systems that act like humans
• These cognitive tasks include:
– Natural language processing
• for communication with human
– Knowledge representation
• to store information effectively & efficiently
– Automated reasoning
• to retrieve & answer questions using the stored
information
– Machine learning
• to adapt to new circumstances
The total Turing Test
• Includes two more issues:
– Computer vision
• to perceive objects (seeing)
– Robotics
• to move objects (acting)
What is Artificial Intelligence ?

THOUGHT Systems that think Systems that think


like humans rationally

Systems that act Systems that act


BEHAVIOUR like humans rationally

HUMAN RATIONAL
Systems that think like humans:
cognitive modeling
• Humans as observed from ‘inside’
• How do we know how humans think?
– Introspection vs. psychological experiments
• Cognitive Science
• “The exciting new effort to make computers think …
machines with minds in the full and literal sense”
(Haugeland)
• “[The automation of] activities that we associate with
human thinking, activities such as decision-making,
problem solving, learning …” (Bellman)
Thinking Humanly: Cognitive
Science
• 1960 “Cognitive Revolution”: information-processing
psychology replaced behaviorism

• Cognitive science brings together theories and


experimental evidence to model internal activities of the
brain
– What level of abstraction? “Knowledge” or “Circuits”?
– How to validate models?
• Predicting and testing behavior of human subjects (top-down)
• Direct identification from neurological data (bottom-up)
• Building computer/machine simulated models and reproduce results
(simulation)
What is Artificial Intelligence ?

THOUGHT Systems that think Systems that think


like humans rationally

Systems that act Systems that act


BEHAVIOUR like humans rationally

HUMAN RATIONAL
Thinking Rationally: Laws of Thought
• Aristotle (~ 450 B.C.) attempted to codify “right thinking”
What are correct arguments/thought processes?
• E.g., “Socrates is a man, all men are mortal; therefore Socrates is mortal”

• Several Greek schools developed various forms of logic:


notation plus rules of derivation for thoughts.

• Problems:
1) Uncertainty: Not all facts are certain (e.g., the flight might be delayed).
2) Resource limitations: There is a difference between solving a problem in principle
and solving it in practice under various resource limitations such as time,
computation, accuracy etc. (e.g., purchasing a car)
Systems that think ‘rationally’
"laws of thought"
• Humans are not always ‘rational’
• Rational - defined in terms of logic?
• Logic can’t express everything (e.g. uncertainty)
• Logical approach is often not feasible in terms of
computation time (needs ‘guidance’)
• “The study of mental facilities through the use of
computational models” (Charniak and McDermott)
• “The study of the computations that make it possible to
perceive, reason, and act” (Winston)
What is Artificial Intelligence ?

THOUGHT Systems that think Systems that think


like humans rationally

Systems that act Systems that act


BEHAVIOUR like humans rationally

HUMAN RATIONAL
Systems that act rationally:
“Rational agent”

• Rational behavior: doing the right thing


• The right thing: that which is expected to
maximize goal achievement, given the available
information
• Giving answers to questions is ‘acting’.
• I don't care whether a system:
– replicates human thought processes
– makes the same decisions as humans
– uses purely logical reasoning
Systems that act rationally
• Logic  only part of a rational agent, not all of
rationality
– Sometimes logic cannot reason a correct
conclusion
– At that time, some specific (in domain) human
knowledge or information is used
• Thus, it covers more generally different situations
of problems
– Compensate the incorrectly reasoned
conclusion
Systems that act rationally
• Study AI as rational agent –
2 advantages:
– It is more general than using logic only
• Because: LOGIC + Domain knowledge
– It allows extension of the approach with more
scientific methodologies
Goals of AI
• To make computers more useful by letting
them take over dangerous or tedious tasks
from human
• Understand principles of human
intelligence
AI Applications
• Autonomous Planning & Scheduling:
– Autonomous rovers.
AI Applications
• Autonomous Planning & Scheduling:
– Telescope scheduling
AI Applications
• Autonomous Planning & Scheduling:
– Analysis of data:
AI Applications
• Medicine:
– Image guided surgery
AI Applications
• Medicine:
– Image analysis and enhancement
AI Applications
• Transportation:
– Autonomous
vehicle control:
AI Applications
• Transportation:
– Pedestrian detection:
AI Applications

Games:
AI Applications
• Games:
AI Applications
• Robotic toys:
The Foundation of AI
• Philosophy
– Dealt with questions like:
• Can formal rules be used to draw valid conclusions?
• Where does knowledge come from? How does it
lead to action?
• David Hume proposed the principle of induction
– At that time, the study of human intelligence
began with no formal expression
– Initiate the idea of mind as a machine and its
internal operations
The Foundation of AI
Mathematics formalizes the three main area
of AI: computation, logic, and probability
Computation leads to analysis of the problems
that can be computed
complexity theory
Probability contributes the “degree of belief” to
handle uncertainty in AI
Decision theory combines probability theory and
utility theory (bias)
The Foundation of AI
• Psychology
– How do humans think and act?
– The study of human reasoning and acting
– Provides reasoning models for AI
– Strengthen the ideas
• humans and other animals can be considered as
information processing machines
The Foundation of AI
• Computer Engineering
– How to build an efficient computer?
– Provides the artifact that makes AI application
possible
– The power of computer makes computation of
large and difficult problems more easily
– AI has also contributed its own work to
computer science, including: time-sharing, the
linked list data type, OOP, etc.
The Foundation of AI
• Control theory and Cybernetics
– How can artifacts operate under their own
control?
– The artifacts adjust their actions
• To do better for the environment over time
• Based on an objective function and feedback from
the environment
– Not limited only to linear systems but also
other problems
• as language, vision, and planning, etc.
The Foundation of AI
• Linguistics
– For understanding natural languages
• different approaches has been adopted from the
linguistic work
– Formal languages
– Syntactic and semantic analysis
– Knowledge representation
Other possible AI definitions
• AI is a collection of hard problems which can be solved by humans and
other living things, but for which we don’t have good algorithms for
solving.
– e. g., understanding spoken natural language, medical diagnosis,
circuit design, learning, self-adaptation, reasoning, chess playing,
proving math theories, etc.
• Russsell & Norvig: a program that
– Acts like human (Turing test)
– Thinks like human (human-like patterns of thinking steps)
– Acts or thinks rationally (logically, correctly)
• Some problems used to be thought of as AI but are now considered not
– e. g., compiling Fortran in 1955, symbolic mathematics in 1965,
pattern recognition in 1970, what for the future?
AI Purposes

"AI can have two purposes. One is to use the power of


computers to augment human thinking, just as we use motors
to augment human or horse power. Robotics and expert
systems are major branches of that. The other is to use a
computer's artificial intelligence to understand how humans
think. In a humanoid way. If you test your programs not
merely by what they can accomplish, but how they accomplish
it, they you're really doing cognitive science; you're using AI
to understand the human mind."
- Herb Simon
What’s easy and what’s hard?
• It’s been easier to mechanize many of the high level cognitive tasks we
usually associate with “intelligence” in people
– e. g., symbolic integration, proving theorems, playing chess, some
aspect of medical diagnosis, etc.
• It’s been very hard to mechanize tasks that animals can do easily
– walking around without running into things
– catching prey and avoiding predators
– interpreting complex sensory information (visual, aural, …)
– modeling the internal states of other animals from their behavior
– working as a team (ants, bees)
• Is there a fundamental difference between the two categories?
• Why are some complex problems (e.g., solving differential equations,
database operations) are not subjects of AI?
History of AI
• AI has roots in a number of scientific disciplines
– computer science and engineering (hardware and software)
– philosophy (rules of reasoning)
– mathematics (logic, algorithms, optimization)
– cognitive science and psychology (modeling high level human/animal
thinking)
– neural science (model low level human/animal brain activity)
– linguistics
• The birth of AI (1943 – 1956)
– McCulloch and Pitts (1943): simplified mathematical model of neurons
(resting/firing states) can realize all propositional logic primitives (can
compute all Turing computable functions)
– Alan Turing: Turing machine and Turing test (1950)
– Claude Shannon: information theory; possibility of chess playing
computers
– Boole, Aristotle, Euclid (logics, syllogisms)
• Early enthusiasm (1952 – 1969)
– 1956 Dartmouth conference
John McCarthy (Lisp);
Marvin Minsky (first neural network machine);
Alan Newell and Herbert Simon (GPS);
– Emphasis on intelligent general problem solving
GSP (means-ends analysis);
Lisp (AI programming language);
Resolution by John Robinson (basis for automatic theorem
proving);
heuristic search (A*, AO*, game tree search)
• Emphasis on knowledge (1966 – 1974)
– domain specific knowledge is the key to overcome existing
difficulties
– knowledge representation (KR) paradigms
– declarative vs. procedural representation
• Knowledge-based systems (1969 – 1999)
– DENDRAL: the first knowledge intensive system (determining 3D
structures of complex chemical compounds)
– MYCIN: first rule-based expert system (containing 450 rules for
diagnosing blood infectious diseases)
EMYCIN: an ES shell
– PROSPECTOR: first knowledge-based system that made significant
profit (geological ES for mineral deposits)
• AI became an industry (1980 – 1989)
– wide applications in various domains
– commercially available tools
– AI winter
• Current trends (1990 – present)
– more realistic goals
– more practical (application oriented)
– distributed AI and intelligent software agents
– resurgence of natural computation - neural networks and emergence of
genetic algorithms – many applications
– dominance of machine learning (big apps)
AI is Controversial
• AI Winter – too much promised
• 1966: the failure of machine translation,
• 1970: the abandonment of connectionism,
• 1971−75: DARPA's frustration with the Speech Understanding Research program at
Carnegie Mellon University
• 1973: the large decrease in AI research in the United Kingdom in response to the
Lighthill report,
• 1973−74: DARPA's cutbacks to academic AI research in general,
• 1987: the collapse of the Lisp machine market,
• 1988: the cancellation of new spending on AI by the Strategic Computing Initiative
• 1993: expert systems slowly reaching the bottom
• 1990s: the quiet disappearance of the fifth-generation computer project's original goals,
• AI will cause
– social ills, unemployment
– End of humanity
Strong AI
"I find it useful to distinguish what I will call "strong" AI
from "weak" or "cautious" AI. According to weak AI, the
principle value of the computer in the study of the mind is
that it gives us a very powerful tool. For example, it enables
us to formulate and test hypothesis in a more rigourous and
precise fashion. But according to strong AI, the computer is
not merely a tool in the study of the mind; rather, the
appropriately programmed computer really is a mind, in the
sense that computers given the right programs can be literally
said to understand and have other cognitive states."
[Searle, 1980, Minds, Brains and Programs]
Weak and Strong AI Claims
• Weak AI:
– Machines can be made to act as if they were
intelligent.
• Strong AI:
– Machines that act intelligently have real,
conscious minds.
Eliza
• Called after Eliza Doolittle of Pygmalion
fame.
• Developed in 1964-1966 by Joseph
Weizenbaum in MIT
• Models (parodies) the rôle of a Rogerian
psychotherapist engaged in an initial
interview with a patient. Much or the
technique of the Rogerian psychotherapist
involves drawing the patient out by
reflecting the patient’s statements back at
him.

http://www-ai.ijs.si/eliza/eliza.html
Eliza

Men are all alike


IN WHAT WAY
They’re always bugging us about something or other.
CAN YOU THINK OF A SPECIFIC EXAMPLE
Well, my boyfriend made me come here.
YOUR BOYFRIEND MADE YOU COME HERE
He says I am depressed much of the time.
I AM SORRY TO HEAR YOU ARE DEPRESSED
It’s true. I am unhappy.
DO YOU THINK COMING HERE WILL HELP YOU NOT TO BE UNHAPPY
I need some help, that much seems certain.
WHAT WOULD IT MEAN TO YOU IF YOU GOT SOME HELP
Perhaps I could learn to get along with my mother.
Eliza
TELL ME MORE ABOUT YOUR FAMILY
My mother takes care of me.
WHO ELSE IN YOUR FAMILY TAKES CARE OF YOU
My father.
YOUR FATHER
You are like my father in some ways
WHAT RESEMBLANCE DO YOU SEE
You are not very aggressive but I think you don’t want me to notice that.
WHAT MAKES YOU THINK I AM NOT VERY AGGRESSIVE
You don’t argue with me
WHY DO YOU THINK I DON’T ARGUE WITH YOU
What is/was Eliza?
• A chatterbot
• Turing test competitor
• A friend
• A model for other bots
What is a chatterbot?
• A chatter robot, chatterbot, chatbot, or chat bot is a
computer program designed to simulate an intelligent
conversation with one or more human users via auditory or
textual methods, primarily for engaging in small talk.
– The primary aim of such simulation has been to fool the user into
thinking that the program's output has been produced by a human (the
Turing test).
– Programs playing this role are sometimes referred to as Artificial
Conversational Entities, talk bots or chatterboxes.
– Uses:
• chatterbots are often integrated into dialog systems for various practical purposes such
as online help, personalised service, or information acquisition.
• Spam in chatrooms
– Some chatterbots use sophisticated natural language processing
systems, but many simply scan for keywords within the input and pull a
reply with the most matching keywords, or the most similar wording
pattern, from a textual database.
– Collections:

http://www.simonlaven.com/
A.L.I.C.E
Honda Humanoid Robot

Walk

Turn

Stairs
Domestic Robots
Military robots
Robocup

www.robocup.org
How far have we got?
• General intelligence of a frog?
But then ask Garry K.

But don’t try to ask Deep Blue


Watson

• “The goal is to have computers start to interact


in natural human terms across a range of
applications and processes, understanding the
questions that humans ask and providing answers
that humans can understand and justify” - IBM
Watson

• IBM’s Artificial
Intelligence
computer system
• Capable of
answering
questions in
natural language
• Competed against
champions on
Jeopardy and won
Watson
• IBM describes this AI as:
"an application of advanced Natural
Language Processing, Information
Retrieval, Knowledge
Representation and Reasoning,
and Machine Learning technologies to
the field of open domain question
answering“
• What this means…
Watson
• Specifics
– 16 Terabytes of RAM
– Can process 500 gigabytes (1 million books) per
second
– Content was stored in Watson’s RAM rather
than memory to be more easily accessed
– Cost about $3 Million
Watson’s sources of
information
• Encyclopedias
• Dictionaries
• Thesauri
• Newswire articles
• Literary works
• Databases, taxonomies, and
ontologies.
• Wikipedia articles
• And more
How Watson Works
• Receives the clues (questions) as electronic
texts
• It then divides these texts into different
keywords and sentence fragments and
searches for statistically related phrases
• Quickly executes thousands of language
analysis algorithms
• The more algorithms that find the same
answer increase Watson’s confidence of his
answer and it calculates whether or not to
make a guess
How to achieve AI?
• How is AI research and engineering done?
• AI research has both theoretical and experimental sides.
The experimental side has both basic and applied aspects.
• Competitions!
• There are two main lines of research:
– One is biological, based on the idea that since humans are
intelligent, AI should study humans and imitate their
psychology or physiology.
– The other is phenomenal, based on studying and formalizing
common sense facts about the world and the problems that the
world presents to the achievement of goals.
• The two approaches interact to some extent, and both
should eventually succeed. It is a race, but both racers seem
to be walking. [John McCarthy]
Strong vs Weak AI
• Strong AI is artificial intelligence that matches or exceeds human
intelligence — the intelligence of a machine that can successfully
perform any intellectual task that a human being can.[1]
– It is a primary goal of artificial intelligence research and an important topic for
science fiction writers and futurists.
– Strong AI is also referred to as "artificial general intelligence"[2] or as the ability
to perform "general intelligent action".[3]
– Science fiction associates strong AI with such human traits as consciousness,
sentience, sapience and self-awareness.

• Weak AI is an artificial intelligence system which is not intended to


match or exceed the capabilities of human beings, as opposed to
strong AI, which is. Also known as applied AI or narrow AI.
– The weak AI hypothesis: the philosophical position that machines can demonstrate
intelligence, but do not necessarily have a mind, mental states or consciousness.
(See philosophy of artificial intelligence or John Searle's definition of Strong AI
in Chinese Room)
AI State of the art - applications
• AI achievements:
– Facilitate and replace human decision making
World-class chess and game playing
– Robots
– Automatic process control
– Understand limited spoken language
– Smarter search engines
– Engage in a meaningful conversation
– Observe and understand human emotions
– Solving mathematical problems
– Discover and prove mathematical theories
–…

You might also like