INTRODUCTION TO
AI AND APPLICATION
S
Module
1
Definition of Arti fi cial Intelligence
Artificial Intelligence (AI( Historical Background: The concept The Role of John McCarthy (2004(:
is the science and of AI was first explored in 1950 by Alan Later, in 2004, John
engineering of making Turing, a British mathematician and defined McCarthy AI as
intelligent machines, computer scientist, who asked the the of science
engineering and
making intelligent
especially intelligent question "Can machines think?" This machines—basically, how we can
computer programs, John was a groundbreaking idea and led him program computers to act smart like
McCarthy (2004). to propose the Turing Test. humans.
A Researcher’s Perspective: Understanding AI from a Simple Everyday AI Examples: Some well-
For researchers, AI refers to View: Think of AI as machines or known examples of AI include chess-
a set of algorithms (step-by- software that are designed to learn playing computers or self-driving cars.
step instructions) that help from their environment, just like These systems depend on deep learning
a machine make decisions humans learn from their experiences. (a type of AI that mimics the human
and act without being For example, an AI program can be brain) and natural language processing
explicitly told what to do trained to recognize your face. (helping computers understand human
each time. language, like Siri or Google Assistant).
How Does AI Work?
AI works by processing large datasets, recognizing patterns, and making decisions
using algorithms.
It involves learning, reasoning, and self-correction:
a.Learning - AI learns from data
b. Reasoning - AI chooses the correct algorithm
c. Self-Correction - AI refines algorithms for accuracy
Advantages and Disadvantages of AI
Advantages: Disadvantages:
1.Performs well on tasks that uses detailed data. 1.Involves more cost.
2.Takes less time to perform tasks that needs to 2.Technical expertise required to develop and
process huge volumes of data. use AI applications.
3.Generates consistent and accurate results. 3.Lack of trained professionals.
4. Can be used 24 X 7.
4. Incomplete or inaccurate data may result in
5.Optimizes tasks by better utilizing resources.
disastrous results.
6. Automates complex processes. 5.Lacks the capability to generalize tasks
7.Minimizes downtime by
predicting maintenance needs.
8. Enables companies to produce new
products having better quality and speed.
History of AI
1943 - First Neural Network Model Proposed: By
Warren McCullough and Walter Pitts to lay the
foundation for artificial neural networks and machine
learning.
1950 - Turing Test Introduced: By Alan Turing to
measure a machine's ability to exhibit intelligent
behavior indistinguishable from humans.
1956 - John McCarthy Coins the Term 'Artificial
Intelligence': By John McCarthy during the Dartmouth
Conference, marking the birth of AI as a formal field.
1997 - IBM Deep Blue Defeats Chess Champion Garry
Kasparov: By IBM's team to demonstrate AI’s capability
in strategic decision-making through computational
power.
2011 - Siri Introduced by Apple: By Apple to
revolutionize personal assistants using natural language
processing and AI for everyday tasks.
Types of AI
AI can be categorized into:
Weak AI (Narrow AI(
Weak AI, also known as narrow AI, is designed to do one
specific task.
Siri and Alexa are examples.
Strong AI (Artificial General Intelligence(
Strong AI, also called Artificial General Intelligence (AGI) or Superintelligence (ASI), tries to mimic human
thinking.
Can perform tasks it hasn’t been specifically trained for.
Requires abilities like visual perception, speech recognition, decision-making, and language translation.
Reactive Machines
Reactive Machines are the simplest type of AI that react to situations based on immediate input, but they have
no memory or ability to learn from past experiences.
Examples: IBM’s Deep Blue (chess-playing computer) is a reactive machine. It makes decisions based on the
current state of the game but doesn’t remember past games.
Types of AI
AI can be categorized into:
Based on Capabilities
Weak AI (Narrow AI(
Weak AI, also known as narrow AI, is
designed to do one specific task.
Strong AI
Strong AI, also called Artificial General
Intelligence (AGI) or Superintelligence
(ASI), tries to mimic human thinking
Types of AI
AI can be categorized into:
Based on Functionalities
Reactive Machines
Reactive Machines are the simplest type of AI that react to situations based on immediate
input, but they have no memory or ability to learn from past experiences.
Limited Memory
Limited memory AI systems can remember data for a short time and use it to make
decisions, but they don’t keep data permanently.
Theory of Mind
The Theory of Mind in AI aims to create machines that can understand thoughts, emotions, and
memories—just like humans.
Self-Awareness
Self-awareness in AI means machines that have a human-level consciousness—they can
understand their own existence and feelings.
Types of AI
1. Weak AI (Narrow AI(
Weak AI, also known as narrow AI, is designed to do one specific task.
Examples:
Siri and Alexa are examples. When you tell Alexa to play a song, it does so because it’s trained to
understand that specific command.
Other examples include weather forecasting, predicting stock prices, and Google search.
How it works: These systems are great at doing one thing really well, but they don’t work outside their
specific task. For example, Alexa can’t drive a car; it’s just built for voice commands.
Why it's important: Weak AI has helped make many tasks easier and more efficient, and it is the most
common type of AI in use today.
Types of AI
2. Strong AI (Artificial General Intelligence - AGI(
Strong AI, also called Artificial General Intelligence (AGI) or Superintelligence (ASI), tries to mimic
human thinking.
Can perform tasks it hasn’t been specifically trained for.
Requires abilities like visual perception, speech recognition, decision-making, and language translation.
Future potential: Experts believe that Strong AI might one day surpass human intelligence, but it’s not
expected to happen anytime soon.
Concerns: While some fear that Strong AI could be dangerous, experts say we don’t need to worry about
it in the near future, as it’s still far from becoming a reality.
Types of AI
3. Reactive Machines
Reactive Machines are the simplest type of AI that react to situations based on immediate input, but they
have no memory or ability to learn from past experiences.
Examples: IBM’s Deep Blue (chess-playing computer) is a reactive machine. It makes decisions based
on the current state of the game but doesn’t remember past games.
Types of AI
4. Limited Memory
What it is: Limited memory AI systems can remember data for a short time and use it to make decisions, but
they don’t keep data permanently.
Examples:
Autonomous vehicles use limited memory to track information like speed of nearby cars, distance
between cars, and speed limits to navigate safely.
AlphaGo, the AI that defeated the world champion in the game Go, also used limited memory to play
and improve during the game.
These systems learn and improve continuously by analyzing new data and adjusting based on feedback.
Key Models:
Reinforcement Learning: AI learns by trial and error, improving over time.
Long Short-Term Memory (LSTM(: AI uses past data to predict the next step, but it focuses more on
recent data.
Evolutionary GANs (E-GAN(: The AI evolves over time, using data and feedback to make better
decisions and predict outcomes.
Types of AI
5 Theory of Mind
The Theory of Mind in AI aims to create machines that can understand thoughts, emotions, and memories—
just like humans.
How it works: AI would need to understand feelings and emotions that influence decisions. These machines
would make choices by considering both reason and emotional context.
Current Status: This is still theoretical, meaning it’s an idea for the future, but it could become a reality soon.
Types of AI
6 Self-Awareness
What it is: Self-awareness in AI means machines that have a human-level consciousness—they can understand
their own existence and feelings.
How it works: These machines would not only understand what someone says but also how they feel based
on the way they communicate. They could learn and adapt their responses to the emotions of others.
Current Status: Self-awareness in AI doesn’t exist yet, but it might happen in the future.
Machine Learning (ML(
Machine Learning is a branch of AI that teaches machines to learn from data and make decisions without
being explicitly programmed.
How it works:
a.Finding patterns: ML algorithms analyze data to identify patterns.
b. Learning from experience: Machines improve automatically by learning from their past output.
c.Self-correction: If the machine makes a mistake, it adjusts and learns to improve accuracy over
time. Real-life examples:
Number series problem: Finding the missing number in 10, 20, 30, 40 → 50. Machines learn patterns just
like humans do.
Relationship between Arti fi cial Intelligence, Machine Learning, Deep
Learning and Natural Language Processing
H O W IS AI R E L AT E D T O M AC H I N E LEARNING?
AI vs ML:
AI is the larger goal (the superset) that aims to make machines intelligent.
Machine Learning is a subset of AI, used specifically for learning from data to make decisions.
In simple terms, ML helps achieve AI by making machines learn and adapt.
Example:
If you want a robot that can see, talk, walk, and learn, you would use AI because it requires many different
technologies.
Machine Learning would only be used to help the robot learn from its environment or past experiences.
Traditional Programming vs Machine Learning
Traditional Programming: Machine Learning Programming:
Manual Coding: In traditional programming, the Data-Driven Approach: Machine learning
programmer manually writes code that accepts input programming learns automatically from data
data and returns output based on pre-defined rules. Predictive Modeling: For example, if we input
Languages Used: It uses procedural programming customer data and transactions, machine learning
languages like C, C++, Java, Python, etc., where the logic can create a predictive model to forecast
and rules are explicitly coded by the programmer. Automated Learning: Adapt and improve over
Algorithm-Dependent: The program is created based on time as more data is processed.
specific algorithms chosen by the programmer, who also Embedded Analytics: Machine learning
analyzes their performance to pick the best one for the introduces embedded analytics, like natural
task. language processing, automatic anomaly
Static Rules: The rules and logic of the program are detection, and recommendation systems, to make
fixed and cannot change unless modified by the intelligent predictions
programmer.
Traditional Programming vs Machine Learning
Key Differences:
Traditional Programming: It uses fixed logic and pre-written rules defined by the programmer.
Machine Learning: It learns from data, automatically creates its own rules, and improves over time based on
experience.
Example:
Traditional Programming: To filter images manually, you would have to write code comparing each pixel value in
the image. This approach can be slow and inaccurate.
Machine Learning: You simply provide photos of a person, and the model learns to recognize that person based
on patterns in the images, making the task much easier and more efficient.
Machine Learning and Deep Learning
Artificial Intelligence (AI(: Machine Learning (ML(: Deep Learning (DL(:
AI is the broad concept ML is a specific subset of AI that Deep learning is a subset of machine
of creating machines or involves teaching machines to learn learning that uses neural networks with
systems that mimic from data. multiple layers (known as deep neural
human intelligence. It ML techniques can be divided into: networks) to analyze and process large
involves a variety of Supervised Learning: Uses amounts of data. These networks are
algorithms and labeled data (data with known inspired by the way the human brain
approaches, one of outcomes) to train the model. processes information.
which is machine Unsupervised Learning: Uses Deep learning allows machines to learn in
learning. unlabeled data (data without much more complex ways, making
predefined outcomes) to connections between layers of data to
discover patterns or structure in improve decision-making.
the data. It is particularly powerful for tasks like image
recognition, speech processing, and other
complex tasks.
How Does AI Work?
Study Large Data: AI analyzes large amounts of data to find patterns.
Make Predictions: AI makes predictions based on the data it has studied.
Autonomous Decision Making: AI can make decisions on its own, learning from past data and experiences.
Adapt and Improve: AI systems continuously adapt and learn from new data to improve over time.
React to Problems: AI systems perceive problems and respond accordingly, using the patterns they have
learned.
Data-Driven: AI relies on large amounts of data to make decisions, with cheap data storage and fast
processors making it easier to use.
Make Accurate Predictions: AI can make accurate predictions based on past data and experience.
Growing and Evolving: AI is being applied in many different areas and its scope is continuously
expanding.
3.1 Defi ning Intelligence
Linguisti c Intelligence:
The ability to speak and understand language (e.g., narrators, orators).
Musical Intelligence:
The ability to create and understand music, like recognizing rhythm and pitch (e.g., musicians, singers).
Logical-Mathematical Intelligence:
The ability to understand abstract concepts and use logic (e.g., mathematicians, scientists).
Spatial Intelligence:
The ability to visualize and manipulate images in your mind (e.g., map readers, astronauts).
Bodily-Kinesthetic Intelligence:
The ability to use your body to solve problems or manipulate objects (e.g., dancers, athletes).
Intrapersonal Intelligence:
The ability to understand your own feelings and motivations (e.g., spiritual leaders, philosophers).
Interpersonal Intelligence:
The ability to understand other people’s feelings and intentions (e.g., mass communicators, interviewers).
Artifi cial Intelligence (AI(: A system or machine is said to be artificially intelligent if it can exhibit one or more of these
types of intelligence.
3.2 Components of Intelligence
Reasoning
Learning
Problem solving
Perception
Linguistic
intelligence
3.2 Components of Intelligence - 1. Reasoning
Reasoning is the process used to make decisions and predictions. It involves analyzing information and
drawing conclusions based on evidence. There are two main types of reasoning:
1. Inductive Reasoning:
What it is: Making generalizations based on specific observations or examples.
How it works: Starts with specific facts or observations and moves to a general conclusion.
Example: If you see 10 white swans, you might conclude that all swans are white.
2. Deductive Reasoning:
What it is: Drawing a specific conclusion based on general principles or facts.
How it works: Starts with a general statement or premise, and moves to a specific conclusion.
Example: All swans are birds. A swan is a bird. Therefore, the swan is a bird.
3.2 Components of Intelligence - 2. Learning
Learning is the process of gaining knowledge or skills by studying, practicing, or experiencing
something. It helps humans, animals, and even AI systems to improve their understanding of different
subjects.
There are different types of learning:
1.Auditory Learning:
2.Episodic Learning:
3.Motor Learning:
4. Observational Learning:
5.Perceptual Learning:
6. Relational Learning:
7.Spatial Learning:
8. Stimulus-Response Learning:
3.2 Components of Intelligence - 2. Learning
There are different types of learning:
1.Auditory Learning:
Learning by hearing and listening.
Example: Listening to recorded lectures to understand a concept.
2. Episodic Learning:
Learning by remembering events or experiences in a specific order.
Example: Recalling what happened in a sequence, like remembering steps in a recipe.
3. Motor Learning:
Learning through physical movement of muscles.
Example: Learning how to pick up objects correctly.
4. Observational Learning:
Learning by watching and imitating others.
Example: Children learn by copying their parents’
actions.
3.2 Components of Intelligence - 2. Learning
5. Perceptual Learning:
Learning by recognizing things that have been seen before.
Example: Identifying objects and situations based on prior experiences.
6. Relational Learning:
Learning by recognizing patterns in relationships between things.
Example: Adjusting the amount of spices in a dish after remembering how much was used last time.
7. Spatial Learning:
Learning through visual stimuli like images, maps, and colors.
Example: Creating a mental map of a route before actually driving.
8. Stimulus-Response Learning:
Learning by reacting to a specific stimulus.
Example: Shouting when touching a hot pan, because it causes
pain.
3.2 Components of Intelligence - 3. Problem Solving
Problem solving is the process of finding a solution to a challenge or issue. It involves:
Identifying the problem: Understanding the situation and recognizing the obstacles (either known or
unknown).
Making decisions: Choosing the best approach or method to overcome the obstacles and reach the
goal.
3.2 Components of Intelligence - 4. Perception
Perception is the process of:
Acquiring information through the senses (like sight, hearing, etc.).
Interpreting that information to understand what’s happening around us.
Selecting important details and organizing them to form a clear picture.
Humans use sensory organs (like eyes, ears) to perceive the world.
AI systems use sensors (like cameras, microphones) to gather data and
understand their environment.
3.2 Components of Intelligence - 5. Linguisti c Intelligence
It is used in in interpersonal communication and defines one’s ability to use, comprehend, speak and write
the verbal and written language
3.3 Differences Between Human and Machine Intelligence
3.4 Agent and Environment
AI agents act in their environment, which may include other agents.
They perceive their environment using sensors.
They act upon the environment using effectors.
Types of Agents in an AI System:
1.Human Agent:
Sensors: Sensory organs like eyes, ears, nose, skin, etc.
Effectors: Hands, legs, mouth for taking action.
2.Robotic Agent:
Sensors: Cameras, infrared range finders.
Effectors: Motors, actuators to perform actions.
3.Software Agent:
Sensors: Uses bit strings as its programs.
Effectors: Executes programmed actions based
on those bit strings.
3.4 Agent and Environment - 3.4.1 Key Terminology
Performance Measure of Agent:
It helps determine how successful an agent is based on its actions.
Behaviour of Agent:
The action performed by an agent after receiving a percept (input).
Percept:
Perceptual input received by an agent at a specific moment in time.
Percept Sequence:
A list of all percepts an agent has received up until now.
Agent Function:
A map that connects the percept sequence to an action performed by the agent.
3.4 Agent and Environment - 3.4.2 Rationality
Rationality is the ability to make responsible and sensible decisions.
A rational agent makes decisions that maximize its performance based on:
a.Performance measure (how successful the agent is).
b. Percept sequence (the inputs it has received).
c. Prior knowledge (what the agent already knows about the environment).
d. Possible actions (what the agent can do).
A rational agent always performs the right action to maximize its performance.
Problem Solved by Agent (PEAS):
Performance measure, Environment, Actuators, and Sensors are used to define
a problem that an agent will solve.
3.4 Agent and Environment - 3.4.4 Types of Agents
1.Simple Reflex Agents
2.Model-Based Reflex Agents
3.Goal-Based Agents
4. Utility-Based Agents
5.Learning Agent
3.4 Agent and Environment - 3.4.4 Types of Agents
1. Simple Reflex Agents
Simple reflex agents choose actions based only on the current percept (the data they receive at a specific moment).
They are rational only if they make the correct decision based on the current percept.
Working:
They use a condition-action rule that maps a state (condition) to an action.
If the condition is true, the agent performs the action; otherwise, it does nothing.
Limitations:
They require the environment to be fully observable (the agent must have access to complete information).
If the environment is partially observable, the agent might get stuck in infinite loops.
In such cases, the agent can only escape the loop if it randomizes its actions.
Other Issues:
Simple reflex agents have very limited intelligence.
They don’t know anything about states other than the current one.
If the environment changes, the rules they follow might need to be updated.
3.4 Agent and Environment - 3.4.4 Types of Agents
2.Model-Based Reflex Agents
Model-based reflex agents use a model of the world to choose their actions, which requires them to maintain an internal
state.
Internal State:
The internal state represents aspects of the current situation that are not directly observable but can be inferred based
on the history of percepts.
Working
a.The agent updates its internal state by understanding two things:
b.How the world evolves (what happens over time in the environment).
c.How the agent’s actions affect the world (the consequences of the agent's actions).
3.4 Agent and Environment - 3.4.4 Types of Agents
3. Goal-Based Agents
A description of desirable situations or outcomes.
Function: Goal-based agents choose their actions to achieve specific goals.
Flexibility: Provides more flexibility than reflex agents as the decision-making knowledge is explicitly
modeled.
Modifications: Allows modifications to adapt to changing conditions.
3.4 Agent and Environment - 3.4.4 Types of Agents
4. Utility-Based Agents
Purpose: Used when goals are conflicting or diffi cult to achieve.
Function: These agents choose actions based on a preference (utility) for each state.
Goal: They help prioritize goals by choosing actions that lead to the most preferred outcome.
Flexibility: Provides a way to handle multiple goals by considering their relative importance.
3.4 Agent and Environment - 3.4.4 Types of Agents
5.Learning Agent
Purpose: A learning agent learns from past experiences and adapts over time.
Starting Point: It begins with basic knowledge and gradually improves by learning from its environment.
Four Main Components:
1.Learning Element:
Responsible for making improvements by learning from the environment.
2.Critic:
Provides feedback to the learning element, evaluating how well the agent is performing against a set performance standard.
3.Performance Element:
Selects the external action to be taken based on the current situation.
4.Problem Generator:
Suggests actions that lead to new experiences for the agent, promoting further learning.
3.4 Agent and Environment - 3.4.5 The Nature of Environments
Artificial Intelligence Systems:
Some AI programs are confined to limited environments like keyboard input, databases, and file systems.
Others, like software robots (softbots), operate in unlimited domains with complex environments.
Turing Test
Purpose: The Turing Test is used to determine if a machine can exhibit intelligent behavior.
Test Setup:
a.Two humans and a software agent (machine) participate.
b.One human is the tester, unaware of which participant is the machine.
c.The tester sends typed questions to both humans and the software agent.
3.4 Agent and Environment - 3.4.6 Types of Environments
1.Discrete/Continuous:
a. Discrete: Limited, well-defined states (e.g., chess).
b. Continuous: No limitations on percepts or actions (e.g., self-driving car).
2.Known vs Unknown:
a. Known: Agent knows results for all actions.
b. Unknown: Agent must learn how to act (e.g., reinforcement learning).
3.Observable/Partially Observable:
a. Observable: Agent can perceive the complete state (e.g., chess).
b. Partially Observable: Agent cannot perceive everything (e.g., Kriegspiel chess).
4. Static/Dynamic:
a. Static: Environment does not change while acting (e.g., crossword puzzle).
b. Dynamic: Environment changes during action (e.g., self-driving car).
c. Semi-dynamic: Environment doesn’t change, but agent’s performance can change.
3.4 Agent and Environment - 3.4.6 Types of Environments
5. Single Agent/Multiple Agents:
Single Agent: One agent in the environment (e.g., vacuum cleaner).
Multiple Agents: More than one agent, can be competitive or cooperative (e.g., chess, taxi driving).
6. Accessible/Inaccessible:
Accessible: Agent has full access to environment information (e.g., empty room).
Inaccessible: Agent cannot get complete information (e.g., global events).
7. Deterministic/Non-deterministic:
Deterministic: Next state can be determined from current state (e.g., chess).
Non-deterministic: Uncertainty about outcomes (e.g., ludo, dice roll).
8. Episodic/Non-episodic:
Episodic: Each episode is independent (e.g., simple tasks).
Non-episodic: Current actions affect future actions (e.g., long-term decision
making).