Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Download as pdf or txt
Download as pdf or txt
You are on page 1of 21

ARTIFICIAL INTELLIGENCE

UNIT-1 INTRODUCTION OF ARTIFICIAL INTELLIGENCE

DEFINITION OF AI: Artificial intelligence (AI) is a wide-ranging branch of computer science


concerned with building smart machines capable of performing tasks that typically require human
intelligence. Artificial intelligence is the simulation of human intelligence processes by machines,
especially computer systems. Specific applications of AI include expert systems, natural language
processing, speech recognition and machine vision.
Stuart Russell and Peter Norvig then proceeded to publish, Artificial Intelligence: A Modern
Approach (link resides outside IBM), becoming one of the leading textbooks in the study of AI.
In it, they delve into four potential goals or definitions of AI, which differentiates computer
systems on the basis of rationality and thinking vs. acting:

Human approach:

 Systems that think like humans


 Systems that act like humans

Ideal approach:

 Systems that think rationally


 Systems that act rationally
At its simplest form, artificial intelligence is a field, which combines computer science and robust
datasets, to enable problem-solving. It also encompasses sub-fields of machine learning and deep
learning, which are frequently mentioned in conjunction with artificial intelligence. These
disciplines are comprised of AI algorithms which seek to create expert systems which make
predictions or classifications based on input data.

 Weak V/S Strong AI:


Weak AI also called Narrow AI or Artificial Narrow Intelligence (ANI)—is AI trained and focused
to perform specific tasks. Weak AI drives most of the AI that surrounds us today. ‘Narrow’ might
be a more accurate descriptor for this type of AI as it is anything but weak; it enables some very
robust applications, such as Apple's Siri, Amazon's Alexa, IBM Watson, and autonomous vehicles.
Strong AI is made up of Artificial General Intelligence (AGI) and
Artificial Super Intelligence (ASI). Artificial general intelligence (AGI), or general AI, is a
theoretical form of AI where a machine would have an intelligence equaled to humans; it would
have a self-aware consciousness that has the ability to solve problems, learn, and plan for the
future. Artificial Super Intelligence (ASI)—also known as superintelligence—would surpass the
intelligence and ability of the human brain. While strong AI is still entirely theoretical with no
practical examples in use today, that doesn't mean AI researchers aren't also exploring its
development. In the meantime, the best examples of ASI might be from science fiction, such as
HAL, the superhuman, rogue computer assistant in 2001: A Space Odyssey.

 History of Artificial Intelligence: Key Dates And Names:


The idea of 'a machine that thinks' dates back to ancient Greece. But since the advent of electronic
computing (and relative to some of the topics discussed in this article) important events and
milestones in the evolution of artificial intelligence include the following:

 1950: Alan Turing publishes Computing Machinery and Intelligence. In the paper,
Turing—famous for breaking the Nazi's ENIGMA code during WWII—proposes to
answer the question 'can machines think?' and introduces the Turing Test to determine if
a computer can demonstrate the same intelligence (or the results of the same intelligence)
as a human. The value of the Turing test has been debated ever since.
 1956: John McCarthy coins the term 'artificial intelligence' at the first-ever AI conference
at Dartmouth College. (McCarthy would go on to invent the Lisp language.) Later that
year, Allen Newell, J.C. Shaw, and Herbert Simon create the Logic Theorist, the first-
ever running AI software program.
 1967: Frank Rosenblatt builds the Mark 1 Perceptron, the first computer based on a
neural network that 'learned' though trial and error. Just a year later, Marvin Minsky and
Seymour Papert publish a book titled Perceptrons, which becomes both the landmark
work on neural networks and, at least for a while, an argument against future neural
network research projects.
 1980s: Neural networks which use a backpropagation algorithm to train itself become
widely used in AI applications.
 1997: IBM's Deep Blue beats then world chess champion Garry Kasparov, in a chess
match (and rematch).
 2011: IBM Watson beats champions Ken Jennings and Brad Rutter at Jeopardy!
 2015: Baidu's Minwa supercomputer uses a special kind of deep neural network called a
convolutional neural network to identify and categorize images with a higher rate of
accuracy than the average human.
 2016: DeepMind's AlphaGo program, powered by a deep neural network, beats Lee
Sodol, the world champion Go player, in a five-game match. The victory is significant
given the huge number of possible moves as the game progresses (over 14.5 trillion after
just four moves!). Later, Google purchased DeepMind for a reported $400 million.
BROAD OVERVIEW OF APPLICATION AREAS OF AI:

Artificial Intelligence has various applications in today's society. It is becoming essential for
today's time because it can solve complex problems with an efficient way in multiple industries,
such as Healthcare, entertainment, finance, education, etc. AI is making our daily life more
comfortable and fast.

1. AI in Astronomy
o Artificial Intelligence can be very useful to solve complex universe problems. AI
technology can be helpful for understanding the universe such as how it works, origin, etc.
2. AI in Healthcare
o In the last, five to ten years, AI becoming more advantageous for the healthcare industry
and going to have a significant impact on this industry.
o Healthcare Industries are applying AI to make a better and faster diagnosis than humans.
AI can help doctors with diagnoses and can inform when patients are worsening so that
medical help can reach to the patient before hospitalization.
3. AI in Gaming
o AI can be used for gaming purpose. The AI machines can play strategic games like chess,
where the machine needs to think of a large number of possible places.
4. AI in Finance
o AI and finance industries are the best matches for each other. The finance industry is
implementing automation, chatbot, adaptive intelligence, algorithm trading, and machine
learning into financial processes.
5. AI in Data Security
o The security of data is crucial for every company and cyber-attacks are growing very
rapidly in the digital world. AI can be used to make your data more safe and secure. Some
examples such as AEG bot, AI2 Platform,are used to determine software bug and cyber-
attacks in a better way.
6. AI in Social Media
o Social Media sites such as Facebook, Twitter, and Snapchat contain billions of user
profiles, which need to be stored and managed in a very efficient way. AI can organize and
manage massive amounts of data. AI can analyze lots of data to identify the latest trends,
hashtag, and requirement of different users.
7. AI in Travel & Transport
o AI is becoming highly demanding for travel industries. AI is capable of doing various travel
related works such as from making travel arrangement to suggesting the hotels, flights, and
best routes to the customers. Travel industries are using AI-powered chatbots which can
make human-like interaction with customers for better and fast response.
8. AI in Automotive Industry
o Some Automotive industries are using AI to provide virtual assistant to their user for better
performance. Such as Tesla has introduced TeslaBot, an intelligent virtual assistant.
o Various Industries are currently working for developing self-driven cars which can make
your journey more safe and secure.
9. AI in Robotics:
o Artificial Intelligence has a remarkable role in Robotics. Usually, general robots are
programmed such that they can perform some repetitive task, but with the help of AI, we
can create intelligent robots which can perform tasks with their own experiences without
pre-programmed.
o Humanoid Robots are best examples for AI in robotics, recently the intelligent Humanoid
robot named as Erica and Sophia has been developed which can talk and behave like
humans.
10. AI in Entertainment
o We are currently using some AI based applications in our daily life with some
entertainment services such as Netflix or Amazon. With the help of ML/AI algorithms,
these services show the recommendations for programs or shows.
11. AI in Agriculture
o Agriculture is an area which requires various resources, labor, money, and time for best
result. Now a day's agriculture is becoming digital, and AI is emerging in this field.
Agriculture is applying AI as agriculture robotics, solid and crop monitoring, predictive
analysis. AI in agriculture can be very helpful for farmers.
12. AI in E-commerce
o AI is providing a competitive edge to the e-commerce industry, and it is becoming more
demanding in the e-commerce business. AI is helping shoppers to discover associated
products with recommended size, color, or even brand.
13. AI in education:
o AI can automate grading so that the tutor can have more time to teach. AI chatbot can
communicate with students as a teaching assistant.
o AI in the future can be work as a personal virtual tutor for students, which will be accessible
easily at any time and any place.
AI WITH NATURAL LANGUAGE PROCESSING:
Natural Language Processing (NLP) refers to AI method of communicating with an intelligent
systems using a natural language such as English. Processing of Natural Language is required
when you want an intelligent system like robot to perform as per your instructions, when you
want to hear decision from a dialogue based clinical expert system, etc. The field of NLP involves
making computers to perform useful tasks with the natural languages humans use. The input and
output of an NLP system can be −
 Speech
 Written Text
Components of NLP
There are two components of NLP as given:
Natural Language Understanding (NLU)
Understanding involves the following tasks
 Mapping the given input in natural language into useful representations.
 Analyzing different aspects of the language.
Natural Language Generation (NLG)
It is the process of producing meaningful phrases and sentences in the form of natural language
from some internal representation.
It involves −
 Text planning − It includes retrieving the relevant content from knowledge base.
 Sentence planning − It includes choosing required words, forming meaningful phrases,
setting tone of the sentence.
 Text Realization − It is mapping sentence plan into sentence structure.
AI WITH ROBOTICS:
Artificial intelligence (AI) and robotics are a powerful combination for automating tasks inside
and outside of the factory setting. In recent years, AI has become an increasingly common presence
in robotic solutions, introducing flexibility and learning capabilities in previously rigid
applications.
Robotic Applications that Use Artificial Intelligence
In today’s global manufacturing sector, there are a few main ways in which AI is deployed.
1. Assembly
AI is a highly useful tool in robotic assembly applications. When combined with advanced vision
systems, AI can help with real-time course correction, which is particularly useful in complex
manufacturing sectors like aerospace. AI can also be used to help a robot learn on its own which
paths are best for certain processes while it’s in operation.
2. Packaging
Robotic packaging uses forms of AI frequently for quicker, lower cost and more accurate
packaging. AI helps save certain motions a robotic system makes, while constantly refining them,
which makes installing and moving robotic systems easy enough for anybody to do.
3. Customer Service
Robots are now being used in a customer service capacity in retail stores and hotels around the
world. Most of these robots leverage AI natural language processing abilities to interact with
customers in a more human way. Often, the more these systems can interact with humans, the more
they learn.
4. Open Source Robotics
A handful of robotic systems are now being sold as open source systems with AI capability. This
way, users can teach their robots to do custom tasks based on their specific application, such as
small-scale agriculture. The convergence of open source robotics and AI could be a huge trend in
the future of AI robots.
When working together, robots are smarter, more accurate and more profitable. AI has yet to come
close to reaching its full potential, but as it advances, so will robotics.
INTRODUCTION OF MACHINE LEARNING AND DEEP LEARNING AS A SUBSET
OF AI

 Artificial Intelligence and Machine Learning


While AI is the broad science of mimicking human abilities, machine learning is a specific subset
of AI that trains a machine how to learn. Watch this video to better understand the relationship
between AI and machine learning. You'll see how these two technologies work, with examples
and a few funny asides.
 MACHINE LEARNING:
Arthur Samuel, a pioneer in the field of artificial intelligence and computer gaming, coined the
term “Machine Learning”. He defined machine learning as: “Field of study that gives computers
the capability to learn without being explicitly programmed”.
In a very layman manner, Machine Learning (ML) can be explained as automating and
improving the learning process of computers based on their experiences without being actually
programmed i.e. without any human assistance. The process starts with feeding good quality
data and then training our machines (computers) by building machine learning models using the
data and different algorithms. The choice of algorithms depends on what type of data do we have
and what kind of task we are trying to automate.
Machine learning (ML) is the study of computer algorithms that can improve automatically
through experience and by the use of data. It is seen as a part of artificial intelligence. Machine
learning algorithms build a model based on sample data, known as training data, in order to make
predictions or decisions without being explicitly programmed to do so. Machine learning
algorithms are used in a wide variety of applications, such as in medicine, email filtering, speech
recognition, and computer vision, where it is difficult or unfeasible to develop conventional
algorithms to perform the needed tasks. A subset of machine learning is closely related
to computational statistics, which focuses on making predictions using computers; but not all
machine learning is statistical learning. The study of mathematical optimization delivers methods,
theory and application domains to the field of machine learning. Data mining is a related field of
study, focusing on exploratory data analysis through unsupervised learning. Some
implementations of machine learning use data and neural networks in a way that mimics the
working of a biological brain. In its application across business problems, machine learning is also
referred to as predictive analytics.
Example: Training of students during exam: While preparing for the exams students don’t
actually cram the subject but try to learn it with complete understanding. Before the examination,
they feed their machine (brain) with a good amount of high-quality data (questions and answers
from different books or teachers notes or online video lectures). Actually, they are training their
brain with input as well as output i.e. what kind of approach or logic do they have to solve a
different kind of questions. Each time they solve practice test papers and find the performance
(accuracy /score) by comparing answers with answer key given, Gradually, the performance
keeps on increasing, gaining more confidence with the adopted approach. That’s how actually
models are built, train machine with data (both inputs and outputs are given to model) and when
the time comes test on data (with input only) and achieves our model scores by comparing its
answer with the actual output which has not been fed while training. Researchers are working
with assiduous efforts to improve algorithms, techniques so that these models perform even
much better.
 Artificial Intelligence and Deep Learning:
The field of artificial intelligence is essentially when machines can do tasks that typically require
human intelligence. It encompasses machine learning, where machines can learn by experience
and acquire skills without human involvement. Deep learning is a subset of machine learning
where artificial neural networks, algorithms inspired by the human brain, learn from large amounts
of data. Similarly to how we learn from experience, the deep learning algorithm would perform a
task repeatedly, each time tweaking it a little to improve the outcome. We refer to ‘deep learning’
because the neural networks have various (deep) layers that enable learning. Just about any
problem that requires “thought” to figure out is a problem deep learning can learn to solve.

 Practical examples of deep learning:


Now that we’re in a time when machines can learn to solve complex problems without human
intervention, what exactly are the problems they are tackling? Here are just a few of the tasks that
deep learning supports today and the list will just continue to grow as the algorithms continue to
learn via the infusion of data.

 Virtual Assistants: Whether it’s Alexa or Siri or Cortana, the virtual assistants of online
service providers use deep learning to help understand your speech and the language
humans use when they interact with them.
 Translations: In a similar way, deep learning algorithms can automatically translate
between languages. This can be powerful for travelers, business people and those in
government.
 Vision for driverless delivery trucks, drones and autonomous cars: The way an
autonomous vehicle understands the realities of the road and how to respond to them
whether it’s a stop sign, a ball in the street or another vehicle is through deep learning
algorithms. The more data the algorithms receive, the better they are able to act human-
like in their information processing—knowing a stop sign covered with snow is still a stop
sign.
 Chatbot’s and Service bots: Chatbots and service bots that provide customer service for
a lot of companies are able to respond in an intelligent and helpful way to an increasing
amount of auditory and text questions thanks to deep learning.
 Image colorization: Transforming black-and-white images into color was formerly a task
done meticulously by human hand. Today, deep learning algorithms are able to use the
context and objects in the images to color them to basically recreate the black-and-white
image in color. The results are impressive and accurate.
 Facial recognition: Deep learning is being used for facial recognition not only for security
purposes but for tagging people on Facebook posts and we might be able to pay for items
in a store just by using our faces in the near future. The challenges for deep-learning
algorithms for facial recognition is knowing it’s the same person even when they have
changed hairstyles, grown or shaved off a beard or if the image taken is poor due to bad
lighting or an obstruction.
 Medicine and Pharmaceuticals: From disease and tumor diagnoses to personalized
medicines created specifically for an individual’s genome, deep learning in the medical
field has the attention of many of the largest pharmaceutical and medical companies.
 Personalized Shopping and Entertainment: Ever wonder how Netflix comes up with
suggestions for what you should watch next? Or where Amazon comes up with ideas for
what you should buy next and those suggestions are exactly what you need but just never
knew it before? Yep, it’s deep-learning algorithms at work.
 5 Key Differences between Machine Learning And Deep Learning
While there are many differences between these two subsets of artificial intelligence, here are five
of the most important:
1. Human Intervention: Machine learning requires more ongoing human intervention to get
results. Deep learning is more complex to set up but requires minimal intervention thereafter.
2. Hardware: Machine learning programs tend to be less complex than deep learning algorithms
and can often run on conventional computers, but deep learning systems require far more powerful
hardware and resources. This demand for power has driven has meant increased use of graphical
processing units. GPUs are useful for their high bandwidth memory and ability to hide latency
(delays) in memory transfer due to thread parallelism (the ability of many operations to run
efficiently at the same time.)
3. Time: Machine learning systems can be set up and operate quickly but may be limited in the
power of their results. Deep learning systems take more time to set up but can generate results
instantaneously (although the quality is likely to improve over time as more data becomes
available).
4. Approach: Machine learning tends to require structured data and uses traditional algorithms
like linear regression. Deep learning employs neural networks and is built to accommodate large
volumes of unstructured data.
5. Applications: Machine learning is already in use in your email inbox, bank, and doctor’s office.
Deep learning technology enables more complex and autonomous programs, like self-driving cars
or robots that perform advanced surgery.
INTELLIGENT AGENTS:
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.
 What is an Agent?
An agent can be anything that perceiveits 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:
o Human-Agent: A human agent has eyes, ears, and other organs which work for sensors
and hand, legs, vocal tract work for actuators.
o Robotic Agent: A robotic agent can have cameras, infrared range finder, NLP for sensors
and various motors for actuators.
o 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.
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:


o Rule 1: An AI agent must have the ability to perceive the environment.
o Rule 2: The observation must be used to make decisions.
o Rule 3: Decision should result in an action.
o Rule 4: The action taken by an AI agent must be a rational action.

 The Structure of Intelligent Agents


Agent’s structure can be viewed as:
 Agent = Architecture + Agent Program
 Architecture = the machinery that an agent executes on.
 Agent Program = an implementation of an agent function.
Simple Reflex Agents
 They choose actions only based on the current percept.
 They are rational only if a correct decision is made only on the basis of current precept.
 Their environment is completely observable.
Condition-Action Rule − It is a rule that maps a state (condition) to an action.
Model Based Reflex Agents
They use a model of the world to choose their actions. They maintain an internal state.
Model − knowledge about “how the things happen in the world”.
Internal State − It is a representation of unobserved aspects of current state depending on percept
history.
Updating the state requires the information about −
 How the world evolves.
 How the agent’s actions affect the world.
Goal Based Agents
They choose their actions in order to achieve goals. Goal-based approach is more flexible than
reflex agent since the knowledge supporting a decision is explicitly modeled, thereby allowing for
modifications.
Goal − It is the description of desirable situations.

Utility Based Agents


They choose actions based on a preference (utility) for each state.
Goals are inadequate when −
 There are conflicting goals, out of which only few can be achieved.
 Goals have some uncertainty of being achieved and you need to weigh likelihood of
success against the importance of a goal.
 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. 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:
o Performance measure which defines the success criterion.
o Agent prior knowledge of its environment.
o Best possible actions that an agent can perform.
o The sequence of percepts.
ENVIRONMENT:
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.
ENVIRONMENT AND PROPERTIES OF TASK ENVIRONMENT:
An environment is everything in the world which surrounds the agent, but it is not a part of an
agent itself. An environment can be described as a situation in which an agent is present. Some
programs operate in the entirely artificial environment confined to keyboard input, database,
computer file systems and character output on a screen. In contrast, some software agents
(software robots or softbots) exist in rich, unlimited softbots domains. The simulator has a very
detailed, complex environment. The software agent needs to choose from a long array of actions
in real time. A softbot designed to scan the online preferences of the customer and show
interesting items to the customer works in the real as well as an artificial environment. The most
famous artificial environment is the Turing Test environment, in which one real and other
artificial agents are tested on equal ground. This is a very challenging environment as it is highly
difficult for a software agent to perform as well as a human. The environment is where agent
lives, operate and provide the agent with something to sense and act upon it. An environment is
mostly said to be non-feministic.

 Features of Environment

As per Russell and Norvig, an environment can have various features from the point of view of an
agent:
1. Fully observable vs Partially Observable
2. Static vs Dynamic
3. Discrete vs Continuous
4. Deterministic vs Stochastic
5. Single-agent vs Multi-agent
6. Episodic vs sequential
7. Known vs Unknown
8. Accessible vs Inaccessible
1. Fully observable vs Partially Observable:
o If an agent sensor can sense or access the complete state of an environment at each point
of time then it is a fully observable environment, else it is partially observable.
o A fully observable environment is easy as there is no need to maintain the internal state to
keep track history of the world.
o An agent with no sensors in all environments then such an environment is called
as unobservable.

2. Deterministic vs Stochastic:
o If an agent's current state and selected action can completely determine the next state of
the environment, then such environment is called a deterministic environment.
o A stochastic environment is random in nature and cannot be determined completely by an
agent.
o In a deterministic, fully observable environment, agent does not need to worry about
uncertainty.

3. Episodic vs Sequential:
o In an episodic environment, there is a series of one-shot actions, and only the current
percept is required for the action.
o However, in Sequential environment, an agent requires memory of past actions to
determine the next best actions.

4. Single-agent vs Multi-agent
o If only one agent is involved in an environment, and operating by itself then such an
environment is called single agent environment.
o However, if multiple agents are operating in an environment, then such an environment is
called a multi-agent environment.
o The agent design problems in the multi-agent environment are different from single agent
environment.

5. Static vs Dynamic:
o If the environment can change itself while an agent is deliberating then such environment
is called a dynamic environment else it is called a static environment.
o Static environments are easy to deal because an agent does not need to continue looking at
the world while deciding for an action.
o However for dynamic environment, agents need to keep looking at the world at each action.
o Taxi driving is an example of a dynamic environment whereas Crossword puzzles are an
example of a static environment.
6. Discrete vs Continuous:
o If in an environment there are a finite number of percepts and actions that can be performed
within it, then such an environment is called a discrete environment else it is called
continuous environment.
o A chess game comes under discrete environment as there is a finite number of moves that
can be performed.
o A self-driving car is an example of a continuous environment.

7. Known vs Unknown
o Known and unknown are not actually a feature of an environment, but it is an agent's state
of knowledge to perform an action.
o In a known environment, the results for all actions are known to the agent. While in
unknown environment, agent needs to learn how it works in order to perform an action.
o It is quite possible that a known environment to be partially observable and an Unknown
environment to be fully observable.

8. Accessible vs Inaccessible
o If an agent can obtain complete and accurate information about the state's environment,
then such an environment is called an Accessible environment else it is called inaccessible.
o An empty room whose state can be defined by its temperature is an example of an
accessible environment.
o Information about an event on earth is an example of Inaccessible environment.

REAL WORLD PROBLEMS OF AGENTS AND ENVIRONMENT:


Self-Driving Car:
Let's suppose a self-driving car then PEAS representation will be:
Performance: Safety, time, legal drive, comfort
Environment: Roads, other vehicles, road signs, pedestrian
Actuators: Steering, accelerator, brake, signal, horn
Sensors: Camera, GPS, speedometer, odometer, accelerometer, sonar

You might also like