Unit 1 Introduction To AI
Unit 1 Introduction To AI
Unit 1 6 hrs.
Introduction to AI
1|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
John McCarthy, who coined the term in 1956, defines it as "it is the science and engineering
of making intelligent machines, especially intelligent computer program." i.e. it is the branch
of computer science dedicated to develop program that enable the computer system to
reproduce the human activities to perform some task or try to imitate the activities.
2|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
o Year 1950: The Alan Turing who was an English mathematician and pioneered
Machine learning in 1950. Alan Turing publishes "Computing Machinery and
Intelligence" in which he proposed a test. The test can check the machine's
ability to exhibit intelligent behavior equivalent to human intelligence, called
a Turing test.
At that time high-level computer languages such as FORTRAN, LISP, or COBOL were
invented. And the enthusiasm for AI was very high at that time.
A boom of AI (1980-1987)
o Year 1980: After AI winter duration, AI came back with "Expert System". Expert
systems were programmed that emulate the decision-making ability of a human
expert.
o In the Year 1980, the first national conference of the American Association of
Artificial Intelligence was held at Stanford University.
3|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Now, AI has developed to a remarkable level. The concept of Deep learning, big data, and
data science are now trending like a boom. Nowadays companies like Google, Facebook,
IBM, and Amazon are working with AI and creating amazing devices. The future of Artificial
Intelligence is inspiring and will come with high intelligence.
4|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Artificial Intelligence is the machines which are designed and programmed in such a manner
that they can think and act like a human.
Artificial Intelligence becomes the important part of our daily life. Our life is changed by AI
because this technology is used in a wide area of day to day services.
These technologies reduce human effort. Now in many industries, people are using this
technology to develop machine slaves to perform the different activity. Using the machine for
the work speed up your process of doing work and give you an accurate result.
The introduction of AI brings the idea of error free world. This technology will slowly
introduce in all the sector to reduce human effort and give accurate and faster result.
AI is important because it can help solve immensely difficult issues in various industries, such
as entertainment, education, health, commerce, transport, and utilities. AI applications can be
grouped into five categories:
Reasoning: The ability to solve problems through logical deduction. e.g. financial asset
management, legal assessment, financial application processing, autonomous weapons
systems, games
Knowledge: The ability to present knowledge about the world. e.g. financial market
trading, purchase prediction, fraud prevention, drug creation, medical diagnosis, media
recommendation
Planning: The ability to set and achieve goals. e.g. inventory management, demand
forecasting, predictive maintenance, physical and digital network optimization,
navigation, scheduling, logistics
Communication: The ability to understand spoken and written language. e.g. real-time
translation of spoken and written languages, real-time transcription, intelligent
assistants, voice control
Perception: The ability to infer things about the world via sounds, images, and other
sensory inputs. e.g. medical diagnosis, autonomous vehicles, surveillance
5|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Heavy Industries
Today in most of the big manufacturing company AI are mostly used in the production unit.
They are used as a robot who give a different shape to an object, who displace object from one
place to another, they are used as a convey belt and much more.
If they are used in management system also. They are used to keep the records of the employee.
They are used to extract correct data for decision making of the company. Using AI in the big
industry help them to complete their task in time and helps business to get proper leads
generation.
6|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
7|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Conclusion
AI technology becomes the part of everyone’s life. From small to big work everyone is using
AI to generate leads and remove the work pressure. These technologies are so advanced that
you don’t have to write code for every activity. They understand the motion of work
automatically.
1. Healthcare
AI and ML technology has been particularly useful in the healthcare industry because it
generates massive amounts of data to train with and enables algorithms to spot patterns faster
than human analysts.
Medecision developed an algorithm that detects 8 variables in diabetes patients to
determine if hospitalization is required.
An app called BiliScreen utilizes a smartphone camera, ML tools, and computer vision
algorithms to detect increased levels of bilirubin in the sclera (white portion) of a
person’s eye, which is used to screen people for pancreatic cancer. This cancer has no
telltale symptoms; hence it has one of the worst prognoses of all cancers.
NuMedii, a biopharma company, has developed a platform called Artificial Intelligence
for Drug Discovery (AIDD), which uses big data and AI to detect the link between
diseases and drugs at the systems level.
GNS Healthcare uses ML algorithms to match patients with the most effective
treatments for them.
8|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
2. Entertainment
A familiar application of AI in everyday life is seen with services like Netflix or Amazon,
wherein ML algorithms analyze the user’s activity and compare it with that of other users to
determine which shows or products to recommend. The algorithms are becoming intelligent
with time—to the extent of understanding that a user may want to buy a product as a gift and
not for himself/herself, or that different family members have different watching preferences.
3. Finance
Financial services companies use AI-based natural language processing tools to analyze
brand sentiment from social media platforms and provide actionable advice.
Investment companies like Aidya and Nomura Securities use AI algorithms to conduct
trading autonomously and robo-traders to conduct high-frequency trading for greater
profits, respectively.
Fintech firms like Kensho and Forward Lane use AI-powered B2C robo-advisors to
augment rebalancing decisions and portfolio management performed by human
analysts. Wealthfront uses AI algorithms to track account activity and help financial
advisors customize their advice.
Chatbots, powered by natural language processing, can serve banking customers
quickly and efficiently by answering common queries and providing information
promptly.
Fraud detection is an important application of AI in financial services. For example,
Mastercard uses Decision Intelligence technology to analyze various data points to
detect fraudulent transactions, improve real-time approval accuracy, and reduce false
declines.
4. Data security
Cyber-attacks are becoming a growing reality with the move to a digital world. There are also
concerns about AI programs themselves turning against systems.
Automatic exploit generation (AEG) is a bot that can determine whether a software
bug, which may cause security issues, is exploitable. If a vulnerability is found, the bot
automatically secures it. AEG systems help develop automated signature generation
algorithms that can predict the likelihood of cyberattacks.
PatternEx and MIT’s Computer Science and Artificial Intelligence Laboratory (CSAIL)
have developed an AI platform called AI2 which claims to predict cyber-attacks better
than existing systems. The platform uses Active Contextual Modeling, a continuous
feedback loop between a human analyst and the AI system, to provide an attack
detection rate that is better than ML-only solutions by a factor of 10.
9|Page
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Deep Instinct, an institutional intelligence company, says that malware code varies
between 2% - 10% in every iteration and that its AI model is able to handle the
variations and accurately predict which files are malware.
5. Manufacturing
Landing.ai claims to have created machine-vision tools to find microscopic defects in
objects like circuit boards using an ML algorithm trained using tiny volumes of sample
images. In the future, self-driving robots may be created which can move finished goods
around without endangering anyone or anything around.
Robots in factories are often stationary but are still in danger of crashing into objects
around it. A new concept called collaborative robots or “cobots, enabled by AI, can
take instructions from humans, including instructions that the robot has not been
previously exposed to, and work productively with them.
AI algorithms can influence the manufacturing supply chain by detecting the patterns
of demand for products across geographies, socioeconomic segments, and time,
and predicting market demand. This, in turn, will affect inventory, raw material
sourcing, financing decisions, human staffing, energy consumption, and maintenance
of equipment.
AI tools help in predicting malfunctions and breakdown of equipment and taking
or recommending preemptive actions as well as tracking operating conditions and
performance of factory tooling.
6. Automotive industry
Tesla introduced TeslaBot, an intelligent virtual assistant integrated with Tesla models
S and X, allows users to interact with their car from their phone or desktop.
Uber AI Labs is working on developing self-driven cars with the help of the best
engineers and scientists. Uber has already tested a batch of self-driving cars in 2016.
Nvidia has partnered with Volkswagen to develop “intelligent co-pilot systems” in
cars that will enable safety warnings, gesture control, and voice and facial recognition.
Ericsson predicts that 5G technology will improve vehicle-to-vehicle communication
wherein sensors will be implanted in airport runways, railways, and roads.
10 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
What is Knowledge?
Knowledge is the information about a domain that can be used to solve problems in that
domain. To solve many problems requires much knowledge, and this knowledge must be
represented in the computer. As part of designing a program to solve problems, we must define
how the knowledge will be represented. A representation scheme is the form of the
knowledge that is used in an agent. A representation of some piece of knowledge is the
internal representation of the knowledge. A representation scheme specifies the form of the
knowledge. A knowledge base is the representation of all of the knowledge that is stored by
an agent.
A good representation scheme is a compromise among many competing objectives. A
representation should be
rich enough to express the knowledge needed to solve the problem.
as close to the problem as possible; it should be compact, natural, and maintainable. It
should be easy to see the relationship between the representation and the domain being
represented, so that it is easy to determine whether the knowledge represented is correct.
A small change in the problem should result in a small change in the representation of
the problem.
able to be acquired from people, data and past experiences.
What is learning?
According to Herbert Simon, learning denotes changes in a system that enable a system to
do the same task more efficiently the next time.
Arthur Samuel stated that, "Machine learning is the subfield of computer science, that gives
computers the ability to learn without being explicitly programmed ".
In 1997, Mitchell proposed that, " A computer program is said to learn from
experience 'E' with respect to some class of tasks 'T' and performance measure 'P', if its
performance at tasks in 'T', as measured by 'P', improves with experience E ".
The main purpose of machine learning is to study and design the algorithms that can be used
to produce the predicates from the given dataset.
Besides these, the machine learning includes the agent’s percepts for acting as well as to
improve their future performance.
11 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
1. Rote learning
For Example:
Consider that 'ƒ' is the target function and example is a pair (x ƒ(x)), where 'x' is input and ƒ(x)
is the output function applied to 'x'.
12 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
13 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
As the outcomes have to be evaluated, this type of learning also involves the definition of a utility
function. This function shows how much is a particular outcome worth?
There are several research issues which include the identification of the learning rate, time and
algorithm complexity, convergence, representation (frame and qualification problems), handling
of uncertainty (ramification problem), adaptivity and "unlearning" etc.
In reinforcement learning, the system (and thus the developer) know the desirable outcomes but
does not know which actions result into desirable outcomes.
In such a problem or domain, the effects of performing the actions are usually compounded with
side-effects. Thus, it becomes impossible to specify the actions to be performed in accordance to
the given parameters.
Q-Learning is the most widely used reinforcement learning algorithm.
The main part of an algorithm is a simple value iteration update. For each state 'S', from the state
set S, and for each action, a, from the action set 'A', it is possible to calculate an update to its
expected reduction reward value, with the following expression:
An AI system can be defined as the study of the rational agent and its environment. The
agents sense the environment through sensors and act on their environment through actuators.
An AI agent can have mental properties such as knowledge, belief, intention, etc. An agent
can be anything that perceive its environment through sensors and act upon that environment
through actuators. An Agent runs in the cycle of perceiving, thinking, and acting.
An agent can be:
Human-Agent: A human agent has eyes, ears, and other organs which work for sensors and
hand, legs, vocal tract work for actuators.
Robotic Agent: A robotic agent can have cameras, infrared range finder, NLP for sensors
and various motors for actuators.
Software Agent: Software agent can have keystrokes, file contents as sensory input and act
on those inputs and display output on the screen.
Hence the world around us is full of agents such as thermostat, cellphone, camera, and even
we are also agents.
Before moving forward, we should first know about sensors, effectors, and actuators.
14 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
Sensor: Sensor is a device which detects the change in the environment and sends the
information to other electronic devices. An agent observes its environment through sensors.
Actuators: Actuators are the component of machines that converts energy into motion. The
actuators are only responsible for moving and controlling a system. An actuator can be an
electric motor, gears, rails, etc.
Effectors: Effectors are the devices which affect the environment. Effectors can be legs,
wheels, arms, fingers, wings, fins, and display screen.
Intelligent Agents:
An intelligent agent is an autonomous entity which act upon an environment using sensors
and actuators for achieving goals. An intelligent agent may learn from the environment to
achieve their goals. A thermostat is an example of an intelligent agent.
Following are the main four rules for an AI agent:
Rule 1: An AI agent must have the ability to perceive the environment.
Rule 2: The observation must be used to make decisions.
Rule 3: Decision should result in an action.
Rule 4: The action taken by an AI agent must be a rational action.
Rational Agent:
A rational agent is an agent which has clear preference, models uncertainty, and acts in a way
to maximize its performance measure with all possible actions.
A rational agent is said to perform the right things. AI is about creating rational agents to use
for game theory and decision theory for various real-world scenarios.
15 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
For an AI agent, the rational action is most important because in AI reinforcement learning
algorithm, for each best possible action, agent gets the positive reward and for each wrong
action, an agent gets a negative reward.
Rationality:
The rationality of an agent is measured by its performance measure. Rationality can be judged
on the basis of following points:
Note: Rationality differs from Omniscience because an Omniscient agent knows the
actual outcome of its action and act accordingly, which is not possible in reality.
Structure of an AI Agent
The task of AI is to design an agent program which implements the agent function. The
structure of an intelligent agent is a combination of architecture and agent program. It can be
viewed as:
Following are the main three terms involved in the structure of an AI agent:
1. f:P* → A
16 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
PEAS Representation
PEAS is a type of model on which an AI agent works upon. When we define an AI agent or
rational agent, then we can group its properties under PEAS representation model. It is made
up of four words:
o P: Performance measure
o E: Environment
o A: Actuators
o S: Sensors
Here performance measure is the objective for the success of an agent's behavior.
Performance: Safety, Time, Legal drive, Comfort, Getting the correct destination, Less Cost
Environment: Roads, Traffic Other Vehicles, Road Signs, Pedestrian, Different types of
Passenger
17 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
o Staff symptoms)
THE END
Turing Test in AI
In 1950, Alan Turing introduced a test to check whether a machine can think like a human or
not, this test is known as the Turing Test. In this test, Turing proposed that the computer can
be said to be an intelligent if it can mimic (imitating or copying something) human response
under specific conditions.
Turing Test was introduced by Turing in his 1950 paper, "Computing Machinery and
Intelligence," which considered the question, "Can Machine think?"
18 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
The Turing test is based on a party game "Imitation game," with some modifications. This
game involves three players in which one player is Computer, another player is human
responder, and the third player is a human Interrogator, who is isolated from other two players
and his jobs are to find that which player is machine among two of them.
The conversation between all players is via keyboard and screen so the result would not depend
on the machine's ability to convert words as speech.
The test result does not depend on each correct answer, but only how closely its responses like
a human answer. The computer is permitted to do everything possible to force a wrong
identification by the interrogator.
Player A (Computer): No
In this game, if an interrogator would not be able to identify which is a machine and which is
human, then the computer passes the test successfully, and the machine is said to be
intelligent and can think like a human.
19 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]
AI - Unit: 1 Introduction to AI
"In 1991, the New York businessman Hugh Loebner announces the prize competition, offering
a $100,000 prize for the first computer to pass the Turing test. However, no AI program to till
date, come close to passing an undiluted Turing test".
ELIZA: ELIZA was a Natural language processing computer program created by Joseph
Weizenbaum. It was created to demonstrate the ability of communication between machine
and humans. It was one of the first chatterbots, which has attempted the Turing Test.
Parry: Parry was a chatterbot created by Kenneth Colby in 1972. Parry was designed to
simulate a person with Paranoid schizophrenia(most common chronic mental disorder).
Parry was described as "ELIZA with attitude." Parry was tested using a variation of the Turing
Test in the early 1970s.
Eugene Goostman: Eugene Goostman was a chatbot developed in Saint Petersburg in 2001.
This bot has competed in the various number of Turing Test. In June 2012, at an event,
Goostman won the competition promoted as largest-ever Turing test content, in which it has
convinced 29% of judges that it was a human. Goostman resembled as a 13-year old virtual
boy.
There were many philosophers who really disagreed with the complete concept of Artificial
Intelligence. The most famous argument in this list was "Chinese Room."
In the year 1980, John Searle presented "Chinese Room" thought experiment, in his paper
"Mind, Brains, and Program," which was against the validity of Turing's Test. According to
his argument, "Programming a computer may make it to understand a language, but it
will not produce a real understanding of language or consciousness in a computer."
He argued that Machine such as ELIZA and Parry could easily pass the Turing test by
manipulating keywords and symbol, but they had no real understanding of language. So it
cannot be described as "thinking" capability of a machine such as a human.
20 | P a g e
Deepak Bhatta Kaji (MCA)
Department of Computer Science – DEC [NAST]