AI Fundamentals and Applications Overview
AI Fundamentals and Applications Overview
MODULE – 1
1. Introduction to AI
Artificial Intelligence (AI) is the science and engineering of making intelligent machines, especially intelligent computer
programs. AI is the branch of computer science that deals with the creation of machines and software capable of performing
tasks that typically require human intelligence. According to John McCarthy (2004), AI is defined as “the science and
engineering of making intelligent machines, especially intelligent computer programs.”
AI enables computers to reason, learn, and make decisions. It involves a combination of algorithms, logic, and data to
simulate human-like intelligence. From a research perspective, AI refers to a set of algorithms or step-by-step instructions
that help a system make decisions or perform actions without being explicitly programmed each time.
The historical foundation of AI dates back to 1950, when Alan Turing, a British mathematician and computer scientist,
proposed the question “Can machines think?” in his paper “Computing Machinery and Intelligence.” This question led to
the concept of the Turing Test, which is used to determine whether a machine can exhibit human-like intelligence.
From a layman’s view, artificial intelligence (AI), simply means the intelligence demonstrated by machines that help them
to mimic the actions of humans. AI simulates natural intelligence in machines that are programmed to learn from
experiences, adjust to new inputs and perform human-like tasks.
From a researcher’s view, AI is a set of algorithms that generates results without having to be explicitly instructed to do so,
thereby making machines capable of thinking and acting rationally and humanely.
In essence, AI can be thought of as machines or software systems designed to learn from their environment, much like
humans learn from experience. For instance, an AI program can be trained to recognize a human face, identify objects, or
make predictions based on data.
AI applications are becoming increasingly common in everyday life. Some popular examples include:
1.2.1. Chess-playing computers – These systems use AI to evaluate millions of possible moves and strategies, enabling
them to challenge or even defeat human players.
1.2.2. Self-driving cars – These vehicles use AI systems with sensors and cameras to detect their surroundings, make
driving decisions, and navigate safely without human intervention.
Many of these systems rely on Deep Learning (a subset of machine learning that mimics the functioning of the human brain)
and Natural Language Processing (NLP), which allows computers to understand and interpret human language. Examples
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 1
Introduction to AI and Applications (1BAIA103/203)
include virtual assistants such as Siri, Alexa, and Google Assistant, which can process voice commands, answer questions,
and perform tasks.
Artificial Intelligence (AI) operates by processing large amounts of data, identifying useful patterns, and making intelligent
decisions using algorithms. In simple terms, AI systems imitate the way humans learn and make decisions, but they do so
with the help of computer programs and statistical models.
AI algorithms are trained using datasets that contain large quantities of information (text, images, or numerical data). By
analyzing this data, AI can detect patterns, correlations, and trends that allow it to make predictions or take specific actions.
For example, a spam detection system in email learns to differentiate between “spam” and “non-spam” emails by analyzing
thousands of sample emails. Over time, it becomes more accurate as it processes more data.
AI systems typically involve three major processes — Learning, Reasoning, and Self-Correction.
Learning:
● The system identifies relationships and patterns within the dataset and stores this information in its model.
● Example: In image recognition, AI learns to distinguish cats from dogs by analyzing many labeled images.
● Learning techniques include supervised learning, unsupervised learning, and reinforcement learning.
Reasoning:
● Reasoning refers to the AI’s ability to make logical decisions using the information it has learned.
● It allows the system to choose the best possible algorithm or action for a given situation.
● There are two main types of reasoning used in Artificial Intelligence and human cognition:
● Inductive Reasoning: Inductive reasoning is the process of deriving general rules or conclusions from specific
observations or examples.
● Deductive Reasoning: Deductive reasoning is the process of deriving specific conclusions from general statements
or known facts.
● Example: A navigation app like Google Maps reasons which route is the fastest based on traffic data and user
preferences.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 2
Introduction to AI and Applications (1BAIA103/203)
Self-Correction:
● When the system makes errors or inaccurate predictions, it adjusts its algorithms to enhance accuracy.
● Example: Speech recognition software like Alexa or Siri corrects itself over time as it receives more voice input
from users.
Artificial Intelligence (AI) provides machines the capability to perform tasks that normally require human intelligence. It
enables systems to reason, learn, adapt, and make decisions with minimal human intervention. Some key advantages are:
1. High Performance with Detailed Data: AI systems can process large and complex datasets quickly and efficiently.
They perform exceptionally well when detailed, structured, and high-quality data are available. Example: In
healthcare, AI can analyze thousands of patient records to identify disease patterns and suggest treatments faster
than human experts.
2. Reduced Processing Time: AI-based systems can complete time-consuming tasks much faster than humans. They
automate repetitive processes, improving efficiency. Example: Chatbots can handle multiple customer queries
simultaneously, reducing waiting time.
3. Consistency and Accuracy: Unlike humans, AI does not suffer from fatigue or emotional bias. It delivers consistent,
accurate, and objective results. Example: AI-based image recognition systems in medical imaging have shown high
accuracy in detecting anomalies.
4. 24×7 Availability: AI systems can work continuously without breaks. This is particularly beneficial in industries
like manufacturing, customer support, and online services.
5. Resource Optimization: AI helps organizations optimize resource utilization by identifying inefficiencies and
recommending improvements. Example: In logistics, AI optimizes delivery routes to save fuel and time.
6. Automation of Complex Processes: AI automates tasks that were previously considered too complex for machines,
reducing human intervention in critical systems.
7. Predictive Maintenance and Reduced Downtime: In industrial settings, AI predicts equipment failures before they
occur, minimizing downtime and improving productivity.
8. Innovation and Quality Improvement: AI enables companies to design and produce new products with better quality
and speed. Example: AI-driven design tools help engineers create innovative products faster.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 3
Introduction to AI and Applications (1BAIA103/203)
Despite its many benefits, AI also comes with certain challenges and limitations:
1. High Cost of Development and Maintenance: Designing, training, and maintaining AI systems require significant
investment in hardware, data, and skilled personnel. Continuous updates and retraining further increase costs.
2. Need for Technical Expertise: AI development demands specialized knowledge in programming, machine learning,
and data science. Lack of expertise may lead to poor implementation.
3. Shortage of Skilled Professionals: There is a global shortage of AI-trained professionals, which limits the
widespread adoption of AI technologies, especially in developing nations.
4. Dependence on Data Quality: AI systems heavily rely on data. If the input data is incomplete, biased, or inaccurate,
the system may produce unreliable or even dangerous outcomes. Example: A biased dataset in recruitment AI could
lead to unfair candidate selection.
5. Limited Generalization and Creativity: AI systems are designed for specific tasks and struggle to adapt outside their
training domain. They cannot think creatively or apply common sense as humans do. Example: An AI trained for
medical diagnosis cannot automatically work for financial predictions.
AI has evolved over several decades through the contributions of scientists, mathematicians, and engineers who worked
toward building machines capable of intelligent behavior. The timeline as shown in Fig. 1.1 highlights major milestones in
the history and development of AI.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 4
Introduction to AI and Applications (1BAIA103/203)
In 1943, Warren McCulloch and Walter Pitts proposed the first mathematical model of an artificial neuron. Their paper, “A
Logical Calculus of the Ideas Immanent in Nervous Activity,” laid the foundation for artificial neural networks (ANNs) and
machine learning.
They demonstrated how simple computational units (neurons) could be connected in networks to perform logical functions,
mimicking how biological neurons in the human brain process information. This work 1950 – Turing Test Introduced
In 1950, Alan Turing, a British mathematician, introduced the concept of the Turing Test in his famous paper “Computing
Machinery and Intelligence.”
The test was designed to determine whether a machine can exhibit intelligent behavior indistinguishable from that of a
human being. If a human interrogator cannot reliably tell the difference between a machine and a human during a text-based
conversation, the machine is said to possess intelligence.
This idea remains a fundamental benchmark in AI philosophy, emphasizing the goal of building thinking [Link]
the cornerstone for modern AI and deep learning.
In 1956, John McCarthy, known as the Father of Artificial Intelligence, organized the Dartmouth Conference, where he
officially coined the term “Artificial Intelligence.”
This event marked the birth of AI as a formal field of research. The goal of the conference was to explore how machines
could simulate aspects of human learning and intelligence.
Following this, early AI programs were developed to solve problems in mathematics and logic, such as the Logic Theorist
and General Problem Solver (GPS).
3.3. 1997 – IBM Deep Blue Defeats Chess Champion Garry Kasparov
A major breakthrough came in 1997 when IBM’s Deep Blue, a chess-playing supercomputer, defeated Garry Kasparov, the
reigning world chess champion.
This victory demonstrated the computational power and strategic decision-making ability of AI systems. Deep Blue used
advanced search algorithms and massive processing capabilities to analyze millions of possible moves per second.
This event showcased the potential of AI in game theory, optimization, and computational reasoning — areas that later
influenced autonomous systems and decision-making AI.
2016 – AlphaGo by DeepMind defeated the world Go champion, showcasing reinforcement learning and neural networks.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 5
Introduction to AI and Applications (1BAIA103/203)
2023 onwards – Generative AI tools like ChatGPT popularized conversational AI and creativity-based applications.
These advancements mark the transition from symbolic AI to deep learning and generative AI models.
4. Foundations of AI
Foundations of Artificial Intelligence are built upon key disciplines such as logic, probability, and cognitive science, which
provide the theoretical and scientific basis for intelligent behavior in machines. These foundations enable AI systems to
reason logically, handle uncertainty, and mimic human thought processes for problem-solving and decision-making.
Logic is the study of reasoning — the science of how to draw correct conclusions from a given set of facts, rules, or
assumptions. In the context of AI, logic provides a mathematical and structured language to represent knowledge and reason
about it systematically. It allows AI systems to think rationally, just like humans, but with precision and consistency.
● Foundation of Reasoning: Logic forms the backbone of reasoning in AI. It provides a framework that ensures every
conclusion drawn by the system follows rationally from the given facts. Without logic, AI cannot verify the
correctness of its decisions. For instance, a reasoning agent that determines if a patient has a fever must apply rules
consistently based on symptoms rather than guessing.
● Knowledge Representation: Logic helps in storing facts about the world in a format that machines can process.
These facts are represented as logical statements. Example:
Here, “∀x” means “for all x”, indicating that every human is mortal.
● Inference and Decision-Making: AI uses logic to infer new knowledge from existing facts and rules. Example:
This process of deriving new facts from known ones is called logical inference, which is essential in expert systems
and intelligent agents.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 6
Introduction to AI and Applications (1BAIA103/203)
● Transparency and Explainability: Logic-based reasoning is transparent and explainable, meaning every step of the
reasoning process can be traced and justified. This is very important in medicine, law, and safety-critical systems,
where decision accountability is required.
● Building Intelligent Agents: Logical agents use sets of rules to decide the best possible actions in a given situation.
● Natural Language Understanding: Logic helps in analyzing and interpreting grammar and sentence structure in
human language.
● Automated Planning and Robotics: Robots use logical reasoning to plan and execute a sequence of actions
efficiently.
Fact: It rains.
This process of linking multiple rules together is called chaining, which helps AI make multi-step logical conclusions.
Let’s take a real-world example of logic-based reasoning. An AI-based smart door unlocks only when two conditions are
true: The face is recognized (F), and The security code is correct (c). The logical rule can be represented as: D = F ∧ C
where:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 7
Introduction to AI and Applications (1BAIA103/203)
0 0 0
0 1 0
1 0 0
1 1 1
Thus, the door unlocks only when both conditions are true (F = 1 and C = 1).
This truth table helps students understand how logical reasoning operates in AI systems.
Probability is the mathematics of uncertainty. It helps us measure how likely an event is to occur, with values ranging
between 0 (impossible) and 1 (certain). In simple terms, probability gives AI systems a way to reason about the real world
even when complete information is not available. While logic deals with definite truths (true or false), probability handles
uncertain truths (how likely something is true).
● Real-World Uncertainty: The real world is full of incomplete, noisy, or ambiguous information. For example, a
medical test may produce false positives (detecting disease when absent) or false negatives (missing disease when
present). Hence, AI systems must reason about possibilities rather than absolute truths.
● Decision-Making Under Uncertainty: Logic works perfectly when facts are certain. However, AI must often make
decisions when data is uncertain or incomplete. Here, probability becomes essential. Example: A self-driving car
cannot always be 100% sure of what’s ahead, but it can assign probabilities to possibilities like “object is a
pedestrian” (0.85) or “object is a signpost” (0.15).
● Prediction: Probability helps AI predict future outcomes based on past data. Example: Weather forecasting systems
use probabilities to express uncertainty — “There is a 70% chance of rain tomorrow.”
● Risk Handling: AI uses probability to evaluate risks and select the best possible action. Example: A self-driving car
evaluates the probability of collision using sensor readings and decides whether to brake or continue safely.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 8
Introduction to AI and Applications (1BAIA103/203)
Suppose 10% of people in a city have the flu. If a person has a fever, it’s not guaranteed that they have flu—it could be a
common cold, dengue, or malaria. A probabilistic AI system might estimate:
Flu → 60%
Cold → 30%
Other → 10%
This reasoning helps AI assign confidence levels instead of making rigid yes/no conclusions.
Data:
Answer: Yes. Since the probability (0.7 or 70%) is high enough, the AI system will decide to carry an umbrella.
This simple example shows how AI uses probability to make rational decisions under uncertainty.
Cognitive Science is the interdisciplinary study of the human mind—how people think, learn, remember, perceive, and
solve problems. It explores the mental processes that lead to intelligent behavior in humans and seeks to model these
processes computationally. Cognitive science draws from multiple disciplines, including Psychology (study of behavior and
mental processes), Neuroscience (study of the brain), Linguistics (study of language), Philosophy (study of reasoning and
consciousness), Anthropology (study of human evolution and culture), and Computer Science (study of algorithms and
computation).
In simple terms, cognitive science tries to understand how the human brain works so that AI systems can be designed to
think and act in a similar way.
● Human Inspiration: Artificial Intelligence was inspired by how humans process information. For example,
Artificial Neural Networks (ANNs) are modeled after the neurons in the human brain. Just as humans learn by
adjusting neuron connections through experience, AI models learn by adjusting weights based on data. This human-
inspired approach helps machines mimic cognitive tasks such as recognizing images, understanding speech, or
learning from experience.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 9
Introduction to AI and Applications (1BAIA103/203)
● Understanding Intelligence: To create intelligent machines, we must first understand human intelligence—how
people reason, learn from mistakes, and adapt to new situations. Cognitive science provides this understanding,
helping AI developers design systems that can learn, reason, and adapt dynamically like humans. For instance,
reinforcement learning in AI was inspired by how humans learn from rewards and punishments.
● Improving Human–AI Interaction: Cognitive science helps machines understand human language, emotions, and
intentions, which is vital for building effective human–AI interaction systems. Examples include chatbots, virtual
assistants like Siri or Alexa, and emotion-recognition systems. By understanding how humans communicate, AI
can respond in a more natural and empathetic manner.
● Explaining AI Decisions: AI models inspired by human cognition are easier to interpret and more relatable.
Cognitive science helps design systems whose reasoning processes can be explained in human terms, making AI
decisions more transparent and trustworthy, especially in domains like medicine or education.
Cognitive science contributes to AI by replicating specific human mental functions in machine systems.
Perception (Vision & Computer Vision and Speech Detecting faces or recognizing
Speech) Recognition spoken words
Memory (Short-term & Working and Persistent Memory in Storing temporary and
Long-term) Agents permanent knowledge
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 10
Introduction to AI and Applications (1BAIA103/203)
Through these parallels, cognitive science bridges human intelligence and machine intelligence.
Imagine a blurred picture of a cat — even though the image is incomplete, humans can still recognize it based on prior
experience and context. Cognitive science studies why and how humans can do this through pattern recognition and memory
recall. AI systems, such as computer vision models, are designed to imitate this ability — they use neural networks to
recognize shapes, patterns, and features, even under uncertain conditions. Similarly, in speech recognition, humans can
understand sentences even if a few words are misheard. AI attempts to replicate this flexibility using probabilistic and
cognitive-inspired models.
Artificial Intelligence (AI) can be understood as a toolbox for building intelligent systems that can think, learn, and act in
real-world environments. To design such systems, AI relies on three fundamental foundations — Logic, Probability, and
Cognitive Science. Each foundation offers a unique way of representing knowledge, handling uncertainty, and modeling
intelligent behavior. Together, they form the core reasoning framework of AI, helping machines make sound decisions,
adapt to uncertainty, and interact effectively with humans.
AI systems often face three types of challenges: clear reasoning, uncertain data, and human interaction.
● Logic provides crisp rules and exact reasoning, which work well when facts are complete and unambiguous. Logic
is the formal language of reasoning used to represent facts, relationships, and rules about the world. It allows AI
systems to derive conclusions from known information using inference.
● Probability helps AI handle uncertainty, especially when information is noisy, incomplete, or ambiguous.
Probability is the mathematics of uncertainty — it helps AI estimate how likely an event is to occur, with values
between 0 (impossible) and 1 (certain). While logic works perfectly when facts are definite, real-world data is often
incomplete or noisy. In such cases, AI uses probabilistic reasoning to make the best possible decision.
● Cognitive Science contributes human-inspired ideas about perception, learning, memory, and communication,
helping AI behave more naturally and interact with people effectively. Cognitive Science is the study of how
humans think, perceive, learn, and make decisions. It combines ideas from psychology, neuroscience, linguistics,
philosophy, and computer science. AI borrows ideas from cognitive science to design systems that mimic human
reasoning and learning.
Hence, these three foundations together enable AI to reason correctly (Logic), manage uncertainty (Probability), and be
human-oriented (Cognitive Science).
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 11
Introduction to AI and Applications (1BAIA103/203)
AI systems often combine logic, probability, and cognitive science to achieve robust and reliable performance.
○ Probability: Handles uncertain sensor inputs (e.g., “There’s 85% chance that object is a pedestrian”).
○ Cognitive Science: Predicts human behavior (e.g., pedestrian crossing pattern) and designs driver-friendly
alerts.
○ Logic: Applies clinical guidelines (“If symptoms X and Y → recommend test Z”).
○ Probability: Combines patient data and test results to estimate disease likelihood.
○ Cognitive Science: Designs the interface and language so that doctors can trust and interpret the system’s
recommendations.
Artificial Intelligence is a rapidly evolving field of computer science focused on creating systems capable of performing
tasks that usually require human intelligence. These tasks include learning from experience, understanding, solving
problems, and making decisions. As AI technology advances, it is classified into different types based on their capabilities,
functionalities as shown in Fig. 1.2.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 12
Introduction to AI and Applications (1BAIA103/203)
5.1. Based on Capabilities: Artificial Intelligence (AI) systems are often classified based on their capabilities — that is,
how intelligently they can perform tasks compared to humans. This classification helps us understand how close a machine
is to replicating human-like intelligence and adaptability. There are primarily two major categories (some sources include
a third, superintelligence):
● Weak or Narrow AI: Weak AI, also known as Narrow AI, refers to artificial intelligence systems designed to
perform a single, specific task efficiently. These systems operate under a limited and pre-defined set of rules,
without true understanding or consciousness. Weak AI represents most of today’s AI applications, where machines
perform well-defined roles such as answering queries, recommending content, detecting spam, or classifying
images. Although these systems appear intelligent, they do not have true comprehension, emotions, or self-
awareness.
○ Key Characteristics:
■ Does not possess real intelligence or awareness; it only simulates intelligent behavior.
■ Operates based on pattern recognition, data analysis, and training for a specific goal.
○ Examples: Siri or Alexa → can recognize speech and respond, but cannot “think” independently. Google
Translate → converts one language to another, but doesn’t understand the meaning deeply.
Recommendation systems → like Netflix or Amazon, which suggest items based on user data.
● Strong or General AI: Strong AI, also known as Artificial General Intelligence (AGI), refers to an AI system with
the ability to understand, learn, and apply knowledge across a wide range of tasks just like a human being. In
theory, a strong AI system would possess reasoning, problem-solving ability, emotional understanding, and self-
awareness.
○ Key Characteristics:
■ Has cognitive abilities similar to humans, such as creativity, empathy, and moral judgment.
■ Can transfer learning from one domain to another (something current AI cannot do).
○ Examples (conceptual): A robot that can not only drive a car but also compose music, teach students, or
discuss philosophy. Theoretical systems like HAL 9000 (from 2001: A Space Odyssey) or Jarvis from Iron
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 13
Introduction to AI and Applications (1BAIA103/203)
Man. Research initiatives in Artificial General Intelligence (AGI) labs, such as OpenAI’s early-stage work
toward general-purpose reasoning systems. Artificial Superintelligence (ASI): An even more advanced
level beyond AGI — ASI refers to machines that could surpass human intelligence in every aspect,
including creativity, emotional intelligence, and problem-solving. This is still theoretical and raises major
ethical and safety concerns about control and alignment.
Real-World Insight: At present, all AI applications around us — from recommendation engines to autonomous vehicles —
belong to Weak AI. Researchers around the world are working toward Strong AI, but achieving true human-like reasoning,
creativity, and consciousness remains a grand challenge in computer science.
● Reactive Machines - Examples: IBM’s Deep Blue (chess-playing computer): 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. They are very basic machines with no memory to store and thus use past experiences to determine
future actions. They just perceive the world and react to it. Since it lacks capabilities
● 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.
● Limited Memory - Examples: Autonomous vehicles. Limited memory AI systems can remember data for a short
time and use it to make decisions, but they don’t keep data [Link] cannot keep adding data permanently
to a library of their experiences. limited memory AI is more complex and is used for better possibilities than reactive
machines. These machines continuously train a model to analyze and utilize new data. The model also improves
using feedback received from humans or the environment and stored as data.
● Theory of Mind: The Theory of Mind in AI aims to create machines that can understand thoughts, emotions, and
memories just like humans. However, such systems are only theoretical as of now but they may become reality very
soon. AI would need to understand feelings and emotions that influence decisions. These machines would make
choices by considering both reason and emotional context.
● Self-Awareness: Self-awareness in AI means machines that have a human-level consciousness they can understand
their own existence and feelings. They could interpret the user's feelings by learning not only what they
communicate to them but also how they communicate it.
● Agent definition: An agent is anything that perceives its environment through sensors and acts upon it through
actuators. A computer program/robot that acts autonomously to achieve goals. Formally: Agent = function from
percept sequences to actions.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 14
Introduction to AI and Applications (1BAIA103/203)
● Environment definition: The external world with which the agent interacts. Defines the problem space in which
the agent operates. The environment provides percepts (inputs) to the agent and receives actions (outputs). The Fig.
1.3 details on agent interaction with the environment.
● Human agent: A human agent has sensory organs (like eyes, ears, nose, tongue and skin) that acts as sensors, and
other organs such as hands, legs, mouth as effectors for taking actions. For example, a doctor diagnosing a disease
or a driver operating a car can be considered human agents—they sense their environment and perform actions
accordingly.
● Robotic agent: A robotic agent uses cameras and infrared range finders as sensors, and various motors and actuators
as effectors. Example: A vacuum-cleaning robot like Roomba senses dust using sensors and cleans the floor using
its actuator-driven brushes.
● Software agent: Such an agent uses bit strings as its programs and actions and executes programmed actions based
on those bit strings. Example: An AI-based email spam filter or a recommendation system on Netflix is a software
agent—it senses digital inputs and takes programmed actions.
In Artificial Intelligence, an agent is any system that can perceive its environment through sensors and act on that
environment using actuators to achieve specific goals. For example, a self-driving car senses its surroundings through
cameras and LIDAR (sensors) and acts using steering and acceleration systems (actuators). AI agents form the foundation
of intelligent behavior, as they continuously sense, decide, and act in real-time environments. Consider a very simple
example—the vacuum-cleaner world as shown in Fig.1.4 This particular world has just two locations: squares A and B. The
vacuum agent perceives which square it is in and whether there is dirt in the square. It can choose to move left, move right,
suck up the dirt, or do nothing. One very simple agent function is the following: if the current square is dirty, then suck;
otherwise, move to the other square. A partial tabulation of this agent function is shown in Figure 1.5 and an agent program
that implements it appears in Fig.1.6
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 15
Introduction to AI and Applications (1BAIA103/203)
Fig.1.5. Partial tabulation of a simple agent function for the vacuum-cleaner world
Fig.1.6. The agent program for a simple reflex agent in the two-state vacuum environment. This program implements the
agent function tabulated in Figure
The agent function defines the mapping between percepts (inputs) and actions (outputs). It specifies what the agent should
do in response to every possible sequence of percepts as shown in Eq. 1.
where, 𝑃∗: all possible percept sequences (what the agent perceives), and
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 16
Introduction to AI and Applications (1BAIA103/203)
Example: If a robot vacuum detects dust (percept), the agent function decides to move forward and clean (action). Thus, the
agent function acts like a mathematical rule that tells the agent how to behave in every situation.
The agent program is the software implementation of the agent function. It runs inside the agent’s computing system and
determines which action to take based on the percepts received.
Key Role:
Example:
In a robot vacuum, the agent program uses algorithms to process dust sensor data, detect obstacles, and plan the cleaning
path.
In simple terms:
8. Types of Environments
In Artificial Intelligence (AI), the environment refers to everything that surrounds an agent and interacts with it. The agent
perceives the environment through sensors and acts upon it using actuators. Understanding the types of environments is
essential because it helps in designing suitable agents and decision-making strategies. Different environments impose
different challenges, and hence, AI agents must be tailored accordingly.
○ Discrete Environment: The environment has a finite number of distinct states, percepts, and actions. Example:
Chess, where the board positions and moves are countable and well-defined. Each move leads to a specific new
state, making it easier for AI to plan and predict.
○ Example: Self-driving cars, where steering angles, speed, and road positions vary continuously. These
environments require real-time perception and fine-grained control mechanisms.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 17
Introduction to AI and Applications (1BAIA103/203)
○ Discrete environments are easier to model mathematically, while continuous ones require sensors, control theory,
and machine learning for accurate functioning.
○ Known Environment: The agent knows exactly how its actions affect the environment. Example: In a chess
program, the effects of each move are known.
○ Unknown Environment: The agent does not initially know the consequences of its actions and must learn through
experience.
○ Example: In reinforcement learning, the AI learns through trial and error how to maximize rewards.
○ In unknown environments, agents must explore, adapt, and learn instead of relying on pre-programmed behavior.
● Fully Observable Environment: The agent can perceive the entire state of the environment at any time. Example:
Chess — all pieces are visible to both players.
● Partially Observable Environment: The agent has limited visibility and cannot access the full state. Example:
Kriegspiel Chess or real-world driving, where some information (like blind spots) is hidden.
● Partially observable environments require state estimation, probabilistic reasoning, and memory to make decisions.
● Static Environment: The environment does not change while the agent is deciding or acting. Example: Crossword
puzzles remain fixed while being solved.
● Dynamic Environment: The environment changes during the agent’s operation. Example: Self-driving cars, where
other vehicles and pedestrians are constantly moving.
● Semi-Dynamic Environment: The environment itself does not change, but time affects performance. Example: A
chess clock — even though the board remains static, the agent’s available time reduces.
● Single-Agent Environment: Only one agent operates, and its success does not depend on others. Example: A
vacuum cleaner robot cleaning a room.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 18
Introduction to AI and Applications (1BAIA103/203)
● Multi-Agent Environment: Two or more agents interact — they may be competitive (e.g., chess, soccer) or
cooperative (e.g., autonomous traffic management).
● Multi-agent environments form the basis of game theory, negotiation systems, and multi-robot coordination.
● Accessible Environment: The agent has complete and accurate access to the environment’s state. Example: An
empty room, where the agent can sense all objects.
● Inaccessible Environment: The agent receives incomplete or noisy information. Example: Weather forecasting,
where full atmospheric data is never known.
The type of environment directly affects the design of the intelligent agent. A deterministic, discrete, and known
environment is easier to model logically. A dynamic, partially observable, and stochastic environment requires learning-
based or probabilistic AI models. Thus, classifying environments helps engineers choose suitable algorithms for perception,
reasoning, and learning.
Rationality is a key concept that distinguishes intelligent agents from non-intelligent ones. A rational agent is one that
always chooses the best possible action to achieve its goals, based on the percepts received and the knowledge it has. In
simple terms, a rational agent does the right thing at the right time. Obviously, doing the right thing is better than doing the
wrong thing, but what does it mean to do the right thing?
When an agent is plunked down in an environment, it generates a sequence of actions according to the percepts it receives.
This sequence of actions causes the environment to go through a sequence of states. If the sequence is desirable, then the
agent has performed well. This notion of desirability is captured by a performance measure that evaluates any given
sequence of environment states. Consider, for example, the vacuum-cleaner agent from the preceding section: To measure
performance by the amount of dirt cleaned up in a single eight-hour shift. With a rational agent, of course, what you ask
for is what you get. A rational agent can maximize this performance measure by cleaning up the dirt, then dumping it all
on the floor, then cleaning it up again, and so on. A more suitable performance measure would reward the agent for having
a clean floor. For example, one point could be awarded for each clean square at each time step (perhaps with a penalty for
electricity consumed and noise generated). As a general rule, it is better to design performance measures according to what
one actually wants in the environment, rather than according to how one thinks the agent should behave.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 19
Introduction to AI and Applications (1BAIA103/203)
If these changes improve the agent’s performance measure, then the agent is considered rational.
Rationality is central to AI because it ensures that an agent behaves intelligently rather than randomly. Without rationality,
an agent might take actions that reduce its performance or even harm its environment.
Importance of Rationality:
● Goal Achievement: Rational agents efficiently work toward achieving their defined goals.
● Optimal Decisions: They make the best possible decisions given the available data.
● Accountability: Rational behavior can be explained logically (important for safety-critical AI, like autonomous
vehicles or medical diagnosis systems).
For example, a rational self-driving car must decide whether to brake, accelerate, or steer based on traffic signals, road
conditions, and pedestrian behavior — all to maximize safety and efficiency.
10. Specifying the task environment PEAS (Performance, Environment, Actuators, Sensors)
In AI, PEAS stands for Performance measure, Environment, Actuators, and Sensors. It is a framework used to define and
understand an intelligent agent — basically, what the agent is supposed to do, what it perceives, and how it interacts with
its surroundings. PEAS helps us understand what an intelligent agent does, how it perceives, and how it acts in its
environment. It provides a structured way to describe any AI system before you build it.
Example: The vacuum world was a simple example; let us consider a more complex problem: an automated taxi driver. We
should point out, before the reader becomes alarmed, that a fully automated taxi is currently somewhat beyond the
capabilities of existing technology. The full driving task is extremely open-ended. There is no limit to the novel
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 20
Introduction to AI and Applications (1BAIA103/203)
combinations of circumstances that can arise—another reason we chose it as a focus for discussion. Fig 1.7 below
summarizes the PEAS description for the taxi’s task environment. We discuss each element in more detail in the following
paragraphs.
Fig 1.7. PEAS description of the task environment for an automated taxi.
First, what is the performance measure to which we would like our automated driver to aspire? Desirable qualities include
getting to the correct destination; o Minimizing fuel consumption and wear and tear; o Minimizing the trip time or cost; o
Minimizing violations of traffic laws and disturbances to other drivers; maximizing safety and passenger comfort; o
Maximizing profits. Next, what is the driving environment that the taxi will face? Any taxi driver must deal with a variety
of roads, ranging from rural lanes and urban alleys to 12-lane freeways. The roads contain other traffic, pedestrians, stray
animals, road works, police cars, puddles and potholes. The taxi must also interact with potential and actual passengers.
There are also some optional choices. The taxi might need to operate in Southern California, where snow is seldom a
problem, or in Alaska, where it seldom is not. It could always be driving on the right, or we might want it to be flexible
enough to drive on the left when in Britain or Japan. Obviously, the more restricted the environment, the easier the design
problem.
The actuators for an automated taxi include those available to a human driver: control over the engine through the accelerator
and control over steering and braking. In addition, it will need output to a display screen or voice synthesizer to talk back
to the passengers, and perhaps some way to communicate with other vehicles, politely or otherwise. The basic sensors for
the taxi will include one or more controllable video cameras so that it can see the road; it might augment these with infrared
or sonar sensors to detect distances to other cars and obstacles. To avoid speeding tickets, the taxi should have a
speedometer, and to control the vehicle properly, especially on curves, it should have an accelerometer. To determine the
mechanical state of the vehicle, it will need the usual array of engine, fuel, and electrical system sensors. Like many human
drivers, it might want a global positioning system (GPS) so that it doesn’t get lost. Finally, it will need a keyboard or
microphone for the passenger to request a destination.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 21
Introduction to AI and Applications (1BAIA103/203)
The job of AI is to design an agent program that implements the agent function— the mapping from percepts to actions.
We assume this program will run on some sort of computing device with physical sensors and actuators—we call this the
architecture:
The difference between the agent program, which takes the current percept as input, and the agent function, which takes the
entire percept history. The agent program takes just the current percept as input because nothing more is available from the
environment; if the agent’s actions need to depend on the entire percept sequence, the agent will have to remember the
percepts.
Intelligence in agents:
● Goal-oriented behavior
To understand how agents, think and act, study their mechanisms — the internal process that converts perception into
intelligent action. The architecture is the physical platform or hardware on which the agent program runs. It provides the
capability to perceive and act, including sensors, actuators, and computational hardware.
Components:
Example:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 22
Introduction to AI and Applications (1BAIA103/203)
If the program decides the action “Walk”, the architecture must include legs or wheels to carry it out. In an autonomous car,
the architecture includes cameras (sensors), motors (actuators), and a computer system that executes the agent program.
The overall relationship between architecture and program can be expressed as shown in Eq. 2. The program provides
intelligence — deciding what to do. The architecture provides capability — sensing and acting in the environment. Example:
Together, they form an autonomous driving agent capable of making and executing decisions safely.
How It Works: The agent keeps a record of all percepts received so far. For each new percept sequence, it looks up a
predefined table that maps percept sequences to actions. The corresponding action is then executed.
Example:
● Exponential Growth: The number of percept sequences grows exponentially as the environment becomes complex.
● Storage Limitations: The agent cannot store all possible percept-action combinations (e.g., self-driving cars would
require enormous memory).
● Design Complexity: Manually creating such tables for all scenarios is nearly impossible.
● No Learning or Generalization: The table-driven agent cannot adapt to new situations or learn from experience —
it only reacts based on fixed rules.
Because of these limitations, modern AI systems use intelligent agent architectures such as model-based, goal-based, or
utility-based agents that can reason, learn, and plan dynamically.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 23
Introduction to AI and Applications (1BAIA103/203)
In Artificial Intelligence, the ultimate goal is to design efficient and intelligent programs that can produce rational behavior
- that is, actions that maximize the likelihood of achieving desired goals — without relying on massive lookup tables. A
table-driven agent stores precomputed responses to every possible percept sequence (or input scenario). However, this
approach quickly becomes impractical as the number of possible situations grows exponentially with time and complexity.
For instance, an agent playing chess or driving a car cannot possibly store every possible state or move in a table.
A useful analogy can be drawn from early engineering practices. In the past, engineers used large printed tables to compute
square roots or trigonometric values. Later, these were replaced by short and efficient computational methods, such as
Newton’s Method, which could calculate results dynamically and accurately without the need for storage-heavy tables.
Similarly, in AI, instead of memorizing responses, we design compact algorithms that can reason, learn, and adapt to their
environment — enabling the agent to act intelligently even in situations it has never encountered before.
Therefore, modern AI focuses on algorithmic intelligence — where the system uses mathematical reasoning, machine
learning, and problem-solving strategies to make informed decisions. This makes the system scalable, adaptable, and
resource-efficient.
There are four key categories of agent programs that form the foundation of most intelligent systems. Each type combines
perception, reasoning, and action components in unique ways to generate intelligent behavior:
1. Simple Reflex Agents – These agents act solely based on the current percept (situation) using condition–action
rules. For example, a thermostat turning on cooling when the temperature exceeds a limit.
2. Model-Based Reflex Agents – These agents maintain an internal model of the world, allowing them to handle
partially observable environments.
3. Goal-Based Agents – These agents act not only on perception but also by considering desired outcomes or goals,
allowing for flexible decision-making.
4. Utility-Based and Learning Agents – These agents evaluate actions based on a utility function (how desirable an
outcome is) and continuously learn from past experiences to improve performance.
5. Learning agent - a learning agent is designed to improve its performance over time by learning from experience,
feedback, and interaction with its environment.
This hierarchical design shows how AI systems evolve from simple, rule-based actions to adaptive and learning-based
intelligence, closely resembling human-like rationality.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 24
Introduction to AI and Applications (1BAIA103/203)
A Simple Reflex Agent is the most basic and foundational type of intelligent agent in Artificial Intelligence. It makes
decisions solely based on the current percept—that is, what it senses at that particular moment—without considering any
past percepts or memory. In simpler terms, such an agent reacts instantly to its environment, much like how humans blink
automatically when something approaches their eyes. This immediate reaction to sensory input gives it the name “reflex”
agent.
The decision-making of a simple reflex agent follows a set of predefined Condition–Action Rules (also called If–Then or
Situation–Action Rules). Each rule specifies what action to perform when a specific condition is observed. For example, in
the classic Vacuum Cleaner World, the agent’s logic may look like this:
Here, the agent simply checks its current percept—whether the location is dirty or not—and performs the corresponding
action, without remembering whether it cleaned the same location before. This design makes the simple reflex agent
extremely fast and computationally efficient, as it does not have to process or store historical data. It is a major improvement
over the Table-Driven Agent, which required a huge lookup table to handle all possible percept sequences. By ignoring
percept history, the simple reflex agent drastically reduces complexity and becomes easier to implement. A real-world
analogy can be found in automated systems like self-driving cars. For instance, when the car’s sensor detects that the “car-
in-front-is-braking,” the reflex agent immediately performs the action “initiate-braking.” This behavior can be represented
by a simple rule:
Such direct cause-and-effect relationships between perception and action are fundamental to real-time, reactive AI systems.
In biological terms, reflexes can be innate (present from birth) or learned through experience—AI agents can exhibit similar
patterns, where certain reflex actions are pre-programmed, and others are adapted over time.
The general structure of a Simple Reflex Agent as shown in below Fig 1.8. consists of an interpreter for condition–action
rules. Instead of writing specific rules for every possible environment, a general-purpose rule interpreter can be built. This
interpreter takes a set of rules as input and executes the matching action based on the current percept. Thus, the same
architecture can be applied to different problems by simply changing the rule set.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 25
Introduction to AI and Applications (1BAIA103/203)
Although Simple Reflex Agents are easy to design and understand, they represent only the most basic form of intelligent
behavior and suffer from several important limitations. These agents act solely based on the current percept—that is, what
they sense at the moment—without using any memory or knowledge of past experiences. As a result, they can only act
rationally in situations where the current percept completely describes the environment.
In real-world environments, however, information is often partial or incomplete. Since simple reflex agents lack the ability
to remember previous states or learn from experience, they can easily become confused when faced with ambiguity. For
example, consider a vacuum cleaner agent that operates without a location sensor. If both squares (A and B) are clean, it
cannot tell where it is and may keep moving back and forth endlessly between them. This kind of repetitive behavior is
known as an infinite loop, which occurs when the agent cannot distinguish between states due to missing perceptual
information.
Another drawback is that simple reflex agents cannot adapt to changes in their environment or improve performance over
time, as they do not learn from past actions. Their behavior is entirely fixed by the predefined condition–action rules, making
them suitable only for static and fully observable environments. To reduce repetitive looping and improve performance in
uncertain or partially observable environments, designers sometimes introduce randomization into the agent’s decision-
making process. In this approach, the agent makes random choices when multiple actions appear equally valid. For instance,
when both squares in the vacuum world are clean, the agent might randomly choose to move left or right. This helps avoid
infinite loops and can occasionally produce better results in uncertain conditions.
However, randomization is not a true form of intelligence — it is more of a temporary workaround than a rational solution.
Random behavior does not guarantee optimal or goal-directed performance. For more realistic, adaptable, and rational
behavior, model-based agents (which maintain an internal model of the world) or goal-based agents (which choose actions
based on desired outcomes) are preferred. These advanced agent types can handle complex, dynamic environments much
more effectively.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 26
Introduction to AI and Applications (1BAIA103/203)
Simple Reflex Agents act only based on the current percept—what they sense at that moment—while ignoring any history
of past percepts. This makes them suitable for simple, fully observable environments, but ineffective in complex or partially
observable situations where the agent cannot perceive the entire environment at once. To overcome this limitation, AI
introduces the Model-Based Reflex Agent, which maintains an internal model of the world to keep track of relevant past
information and predict unseen aspects of the environment.
A Model-Based Reflex Agent possesses an internal state, which acts like memory. This state stores information about what
the agent has already perceived, how the world evolves over time, and how the agent’s own actions can influence the
environment. Together, these elements form the agent’s model of the world—a representation that helps it reason about
what is happening even when certain parts of the environment are not directly observable.
For example, consider an automated (self-driving) car. The car’s sensors might not always detect every nearby vehicle,
perhaps due to blind spots or obstructions. A simple reflex agent would fail in such cases, as it cannot recall previous sensor
readings. A model-based agent, on the other hand, uses stored information from earlier percepts, such as the last known
positions and motion directions of other cars, along with predictions about their likely movements. Using this internal model,
it can estimate where hidden vehicles might be and act safely, such as slowing down or changing lanes cautiously.
To maintain and update this internal model, the agent needs two kinds of knowledge:
● World Dynamics – Knowledge about how the environment naturally changes over time, regardless of the agent’s
actions. Example: “A moving car continues forward unless braking is applied.”
● Action Effects – Knowledge about how the agent’s own actions alter the environment. Example: “Turning the
steering wheel clockwise turns the car to the right.”
Using these two types of knowledge, the agent continuously updates its internal state, allowing it to handle incomplete
information and make more intelligent, context-aware decisions.
The structure of a Model-Based Reflex Agent as shown in below Fig.1.9 typically follows this cycle:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 27
Introduction to AI and Applications (1BAIA103/203)
● Update State: Modify the internal state using the latest percept, the last action, and the world model.
● Match Rule: Choose an appropriate condition–action rule that applies to the current internal state.
This process enables the agent to reason beyond the immediate percept and act more rationally and safely in dynamic
environments.
The Model-Based Reflex Agent represents a significant improvement over the simple reflex agent because it is capable of
handling partial observability—situations where the agent cannot perceive the entire environment at once. Unlike a simple
reflex agent, which reacts only to the current percept, a model-based agent remembers unseen or past aspects of the
environment using an internal state or world model. This memory allows it to make better, more informed decisions, even
when the complete environmental information is not directly available.
By maintaining an internal model of the world, the agent can reason about what might be happening in hidden areas or what
changes have occurred due to its own actions. This ability greatly reduces uncertainty in decision-making. For instance, in
a vacuum cleaner environment, if the agent lacks a location sensor, a simple reflex agent might move endlessly between
clean squares. However, a model-based reflex agent can remember its last move and estimate its current position, helping
it avoid redundant movements and clean the area more efficiently.
The combination of the models such as world model and action model enables the agent to update its internal state, predict
consequences, and act rationally. As a result, the model-based reflex agent not only responds to immediate inputs but also
uses contextual knowledge and memory to guide its actions intelligently.
Furthermore, this model-based approach serves as a foundation for more advanced AI agents, such as goal-based and
learning agents, which build upon the same internal modeling concept but incorporate higher-level reasoning and adaptive
learning. Thus, the design of model-based agents marks a critical step toward intelligent, context-aware, and autonomous
AI systems capable of operating effectively in real-world environments.
In Artificial Intelligence, we have seen that model-based reflex agents can maintain an internal model of the world and use
it to act intelligently even when the environment is partially observable. However, simply knowing what the world is like
is not always enough to decide what to do next. An agent must also know what it wants to achieve. This leads to the concept
of Goal-Based Agents, which are capable of making purposeful and goal-directed decisions.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 28
Introduction to AI and Applications (1BAIA103/203)
● The goal, which defines the desired or target states that the agent aims to achieve.
By evaluating how different actions move it closer to or further from its goal, the agent can select actions intelligently rather
than reacting reflexively. Thus, while a model-based reflex agent relies on fixed rules, a goal-based agent makes rational
decisions that depend on both the current situation and its desired outcome.
For example, consider a self-driving taxi at a road junction. It has three possible actions—turn left, turn right, or go straight.
Without knowing the goal (the passenger’s destination), the taxi cannot make a rational choice. But if the goal is to reach a
specific location, the agent can plan the correct action sequence to get there efficiently. This illustrates how goal information
is critical for intelligent and context-aware behavior.
A goal-based agent uses its model of the world to predict the outcome of possible actions. It asks itself questions such as,
“What will happen if I take this action?” and “Will this bring me closer to my goal?” Based on these predictions, it evaluates
and selects the action that best helps achieve the goal.
This process involves reasoning about future states, which allows the agent to act not just reactively, but proactively—
anticipating outcomes and planning ahead.
The architecture of a Goal-Based Agent as shown in below Fig.1.10 builds upon that of the model-based reflex agent by
introducing two new components:
● Goal Evaluation Mechanism: Determines which actions best help achieve the goal.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 29
Introduction to AI and Applications (1BAIA103/203)
Together with its existing components—sensors, internal state, world model, and actuators—the goal-based agent can
reason, plan, and act intelligently.
Unlike reflex agents, which respond only to immediate stimuli, goal-based agents can reason about the future (“What will
happen if I do X?”) and assess the desirability of outcomes (“Will this help me reach my goal?”).
● Search Algorithms: Used to find a sequence of actions leading from the current state to the goal state.
● Planning: The process of organizing and executing actions systematically to achieve the goal efficiently.
For instance, in a self-driving car, a reflex agent may only react when the vehicle ahead slows down, applying brakes
instantly. In contrast, a goal-based agent predicts that “if the car ahead slows down, I must reduce speed to maintain safe
distance,” thereby achieving the broader goal of safe and efficient driving. This shows how goal-based reasoning enables
anticipation and adaptability beyond fixed reflex behavior.
● Flexibility: Goals can be easily modified without changing the entire rule set. Example: Changing the destination
of a self-driving taxi only requires updating the goal.
● Efficiency in Knowledge Reuse: The same internal model can be applied to multiple goals.
● Improved Adaptability: When environmental conditions change (e.g., rain affecting braking), the agent can adjust
its model and actions automatically.
However, goal-based agents also have limitations. They can be computationally expensive, as they often require reasoning,
searching, or planning over many possible actions. Moreover, for simple environments with clear, repetitive tasks, a reflex
agent may still be faster and sufficient.
The goal-based agents choose actions that lead to the achievement of specific goals. However, these agents only determine
whether a goal has been achieved or not—they cannot distinguish between multiple ways of achieving it. In real-world
situations, there are often many different paths to reach the same goal, but some are faster, safer, cheaper, or more
comfortable than others. To handle such scenarios and make more refined and rational decisions, AI introduces the concept
of Utility-Based Agents.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 30
Introduction to AI and Applications (1BAIA103/203)
A Utility-Based Agent extends goal-based reasoning by incorporating the concept of utility, which represents how desirable
a particular outcome is. The term utility is borrowed from economics and refers to the degree of happiness, satisfaction, or
benefit an agent receives from being in a certain state. While goal-based agents evaluate success in a binary way (goal
achieved or not), utility-based agents assign numerical values to different states, reflecting their relative desirability. This
approach enables the agent to choose not just any action that achieves the goal, but the best possible action that maximizes
overall satisfaction or performance.
For instance, consider a self-driving taxi. While all possible routes may eventually lead to the destination, they differ in
travel time, fuel efficiency, traffic congestion, and passenger safety. A goal-based agent only ensures the taxi reaches the
destination. In contrast, a utility-based agent evaluates each route using a utility function and selects the one that provides
the highest utility—say, a route that is moderately fast, safe, and fuel-efficient. Thus, the taxi does not merely achieve its
goal but does so in the most optimal and rational way.
13.4.1. Understanding the Utility Function: A Utility Function maps each possible world state to a real number that
represents how satisfactory that state is for the agent. Higher values correspond to more desirable states. The agent’s
objective is to select actions that lead to maximum utility. If the agent’s internal utility function aligns well with the external
performance measure (how we expect it to behave), the agent can be considered rational.
However, in the real world, outcomes are uncertain. Therefore, agents use the concept of Expected Utility (EU)—the
average utility an agent expects to gain, weighted by the probabilities of different outcomes. The agent evaluates all possible
actions, estimates their expected utilities, and chooses the one with the highest expected utility. This ensures a rational
balance between risk and reward.
Example:
Here, the utility-based agent selects Route B because it offers the best trade-off between safety and efficiency, maximizing
overall satisfaction.
A utility-based agent as shown in below Fig.1.11 builds upon the model-based and goal-based architectures by adding a
utility computation mechanism.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 31
Introduction to AI and Applications (1BAIA103/203)
● Decision Mechanism – Selects the action with the maximum expected utility.
● Fine-Grained Decision-Making: Can compare multiple successful strategies based on efficiency, safety, or cost.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 32
Introduction to AI and Applications (1BAIA103/203)
● Computational Complexity: Calculating expected utility can be time-consuming in large or dynamic environments.
● Modeling Requirements: The agent must accurately understand how its actions influence the world.
● Utility Design Difficulty: Defining a realistic and consistent utility function that reflects true preferences is complex.
In Artificial Intelligence, learning agents represent the most advanced type of intelligent agents. Unlike simple, model-
based, or goal-based agents that rely on pre-defined rules, a learning agent is designed to improve its performance over time
by learning from experience, feedback, and interaction with its environment. This learning capability enables the agent to
adapt to new or changing situations — even when complete information or rules are not available.
The primary goal of a learning agent is to enhance its decision-making ability automatically, without requiring manual
reprogramming as shown in below Fig.1.12 Over time, it refines its internal model, updates its strategies, and improves the
quality of its actions — just as humans get better at tasks through practice and feedback. For example, consider a self-
driving car. Initially, it may make mistakes in judging braking distances or turning on slippery roads. However, after
repeated experience and feedback, it learns to anticipate these challenges and act more safely. Such self-improvement is
made possible because of the learning mechanism integrated into the agent’s architecture.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 33
Introduction to AI and Applications (1BAIA103/203)
A learning agent typically consists of four major components, each playing a vital role in its learning and adaptation process:
● Performance Element – This is the “acting” part of the agent responsible for interacting with the environment and
selecting actions based on percepts. It determines what the agent does at any given moment. Example: In a self-
driving car, the performance element controls acceleration, steering, and braking.
● Learning Element – This component improves the performance element by using feedback from past actions and
experiences. It refines decision-making strategies to enhance overall performance. Example: The car gradually
learns to drive more smoothly in rain or dense traffic after repeated exposure.
● Critic – The critic evaluates the agent’s performance by comparing its actions and results against a standard or
desired outcome. It provides feedback on how well the agent performed. Example: After each trip, the critic may
assess if the route taken was safe, energy-efficient, and within traffic rules.
● Problem Generator – This element suggests new exploratory actions that help the agent gather novel and useful
experiences. It encourages experimentation, enabling the agent to discover better ways to achieve goals. Example:
The car may test braking behavior on different road surfaces to learn optimal stopping distances.
The process of learning in an AI agent occurs through continuous feedback and refinement:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 34
Introduction to AI and Applications (1BAIA103/203)
● The Learning Element uses this feedback to update internal models and decision-making rules.
● The Problem Generator encourages exploration of new scenarios to gain additional learning experiences.
Through repeated iterations of this cycle, the agent becomes more accurate, adaptable, and efficient, eventually handling
complex or uncertain environments with minimal supervision.
● Performance Element: Drives the taxi using current road and traffic information.
● Critic: Monitors and evaluates each trip (e.g., passenger comfort, safety, route efficiency).
● Learning Element: Updates its driving model — for instance, avoiding sharp turns in wet conditions after prior
negative feedback.
● Problem Generator: Tests new strategies, such as experimenting with alternate routes under varying weather or
traffic conditions.
Over time, the taxi learns to balance safety, comfort, and efficiency, ultimately improving its service without any explicit
reprogramming by developers. In essence, learning in AI refers to modifying the agent’s internal structure and decision-
making logic in response to environmental feedback. This enables the agent to become more intelligent, flexible, and
autonomous with experience.
1 Reflex Agent Reacts instantly to Stops immediately Uses if–then rules (like
input; no memory. when obstacle human reflex).
detected.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 35
Introduction to AI and Applications (1BAIA103/203)
5 Learning Agent Improves with Learns better lane Becomes smarter with
experience. detection from data. feedback — like
humans.
In Artificial Intelligence, Problem-Solving Agents represent a crucial evolution beyond reflex and goal-based agents. While
simple reflex agents act only on current percepts using “if–then” rules, they fail in complex or partially observable
environments because they cannot plan or anticipate future consequences. Goal-based agents improved upon this by
reasoning about goals — they evaluate which actions lead to desirable outcomes. However, in dynamic or multi-step
environments, an agent must determine how to reach its goal through a structured sequence of actions. This leads to the
introduction of the Problem-Solving Agent, which applies systematic search and reasoning to discover a path from its initial
state to a goal state.
Problem-solving agents are designed for environments that are deterministic, observable, static, and discrete, allowing the
agent to model possible actions and outcomes precisely. Their main advantage is their ability to abstract and represent the
world as a well-defined search problem — one that can be systematically solved using search algorithms. They serve as a
foundational concept in AI education because almost every intelligent system — from a chess-playing engine to a robot
planner or GPS navigation system — relies on problem formulation as the starting point for intelligent decision-making.
Problem-solving agents is essential because it demonstrates how AI agents think systematically. Rather than responding
instantly to stimuli, these agents formulate a problem, search for solutions, and select the optimal sequence of actions to
reach a goal. It provides the bridge between reactive AI (simple rules) and deliberative AI (strategic reasoning). It forms the
basis for understanding search algorithms, game-playing, planning, and optimization — all of which depend on clear
problem formulation.
A problem-solving agent explicitly defines and reasons over the following five components:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 36
Introduction to AI and Applications (1BAIA103/203)
● Transition Model: Describes how each action changes the state of the world.
● Goal Test: Determines whether a given state satisfies the goal conditions.
● Path Cost Function: Assigns a numerical value (cost) to each path to evaluate efficiency.
With these elements, the agent can simulate different sequences of actions (search space) and identify the most cost-effective
route to success.
[Link] Principle
The operation of a problem-solving agent can be divided into three main stages:
● Problem Formulation: Clearly define the initial state, goal state, and all possible actions and costs.
● Search Process: Systematically explore possible sequences of actions to discover the goal state.
● Solution Identification: Select the optimal path — typically one that minimizes the path cost or maximizes
performance efficiency.
This process allows an agent to plan ahead and evaluate the consequences of its actions before execution.
● Uninformed (Blind) Search: The agent has no additional knowledge apart from the problem definition. Examples:
Breadth-First Search (BFS), Depth-First Search (DFS), and Uniform-Cost Search.
● Informed (Heuristic) Search: The agent uses problem-specific heuristics (estimates) to guide its search more
efficiently. Examples: Best-First Search, A* Search Algorithm.
Heuristics improve efficiency by prioritizing states that appear closer to the goal.
Problem formulation is the process of defining a problem in such a way that it can be solved computationally through search.
It serves as the first and most critical step in designing intelligent behavior. A poorly formulated problem leads to
unnecessary complexity and inefficiency, while a well-formulated problem simplifies search and enables faster, more
optimal solutions.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 37
Introduction to AI and Applications (1BAIA103/203)
● State Space: The set of all possible states reachable from the initial state by any sequence of actions.
● Actions: All operations the agent can perform to move between states.
● Transition Model: Defines how an action transforms one state into another.
● Goal Test: Determines whether a given state satisfies the goal condition.
● Path Cost Function: Measures the efficiency of a solution (e.g., shortest path, minimum time, or least cost).
A good problem formulation captures the essence of the problem while ignoring irrelevant details that do not affect the
outcome.
● Transition Model: Describes how moving along a road changes the car’s position.
● Goal Test: Checks whether the car has reached the destination (e.g., Bucharest).
The agent systematically searches through possible routes and selects the optimal path — say, the shortest or fastest —
using algorithms such as Uniform-Cost Search or A*. This same logic applies to delivery routing, robotic navigation, and
airline scheduling — all of which require problem-solving agents to plan efficient sequences of actions.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 38
Introduction to AI and Applications (1BAIA103/203)
● Formulate a Problem: Identify the possible states, actions, and cost structure.
● Search for a Solution: Use a search strategy to explore and find an optimal action sequence.
● Execute the Plan: Carry out the actions step-by-step in the environment.
Problem-solving agents are central to artificial intelligence because they formalize how intelligent behavior can be generated
from reasoning rather than direct reaction. By formulating problems, exploring search spaces, and evaluating outcomes,
these agents enable machines to operate intelligently in structured, goal-driven tasks. Their design forms the foundation for
robotics, pathfinding, planning systems, game-playing AI, and scheduling applications.
In Artificial Intelligence, a Problem-Solving Agent is a type of goal-based agent designed to determine a sequence of actions
that transforms the initial state of the world into a goal state. While reactive agents can handle simple environments through
direct responses, complex decision-making requires a formal problem definition — that is, specifying what the problem
actually is before attempting to solve it.
Understanding how and why a problem needs to be clearly defined is central to AI because machines cannot “guess” what
to do next. A well-defined problem allows the agent to systematically explore possible actions, predict their consequences,
and choose an optimal path toward achieving its goal. Therefore, problem definition is the first and most important step in
the design of intelligent systems such as navigation systems, robotic planners, and game-playing programs.
AI systems often operate in environments that contain many possible states, each resulting from a specific sequence of
actions. Without a clear definition of what the problem is — including what the agent knows, what it can do, and what it
wants to achieve — it becomes impossible to compute an effective plan or evaluate success.
Thus, problem definition converts an abstract task (“reach Bucharest” or “clean all squares”) into a formal model that a
computer can process through search.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 39
Introduction to AI and Applications (1BAIA103/203)
A problem in AI is defined by five key components. Together, these elements form the search space that a problem-solving
agent explores. Each component must be precisely described for the agent to reason about actions, outcomes, and costs.
1. Initial State: The initial state represents the starting point of the agent — where it begins the search for a solution. It
defines the agent’s knowledge of the environment at the beginning of the task. Example: In the Romania road map problem,
the agent’s initial state may be described as In(Arad) — meaning “the agent is currently in Arad.” In other examples, it
could be the position of a robot in a grid or the arrangement of tiles in a puzzle.
2. Actions: This defines the set of possible operations that the agent can perform from a given state.
● The set of actions determines how the agent can move within its environment.
3. Transition Model: The transition model (or successor function) describes how the environment changes after performing
an action.
● Represented as RESULT(s, a) — the state that results from doing action a in state s.
● The transition model enables the agent to simulate the effects of its actions — crucial for planning future steps.
4. Goal Test: The goal test specifies the condition for success — when the agent has achieved its objective.
● Example: In the Romania road map problem, the goal test checks whether the agent has reached In(Bucharest).
● In other cases, the goal might be cleaning all squares in a vacuum world, solving a puzzle, or finding a checkmate
in chess.
5. Path Cost: The path cost assigns a numerical value to the total cost of a solution path.
● It represents the cumulative sum of all step costs — written as c(s, a, s′) for each transition.
● Example: In the Romania problem, the path cost may correspond to total distance traveled in kilometers, time taken,
or fuel consumed.
● The goal of an intelligent agent is to find an optimal solution, i.e., one with the minimum path cost.
Note: A solution is an action sequence that transforms the initial state into a goal state. An optimal solution is the one that
achieves this transformation with the lowest total path cost among all possible sequences.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 40
Introduction to AI and Applications (1BAIA103/203)
● Transition Model: Defines how moving along a route changes the location.
● Goal Test: Check if the destination (e.g., Bucharest) has been reached.
The agent systematically searches through possible paths and selects the route with the minimum path cost, such as the
shortest travel time. This principle is applied in GPS systems (Google Maps), network routing algorithms, logistics, and
robot navigation.
Toy Problems Designed for research or Vacuum Cleaner World Illustrates key problem-solving
teaching; simple and — agent cleans all dirty concepts (states, actions, goal,
fully defined. squares. cost).
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 41
Introduction to AI and Applications (1BAIA103/203)
Fig. 1.13: State space for the vacuum world. Links denote actions: L = Left, R= Right, S=Suck.
Components:
● States: Defined by agent’s location and whether squares are dirty or clean.
● Transition Model: “Move Left” or “Move Right” changes position; “Suck” cleans dirt.
● Path Cost: Each step costs 1; total cost = number of actions taken.
This simple world helps to visualize how problem components interact to form a search problem.
Problem definition is the foundation of all AI problem-solving techniques. It provides a structured way for agents to reason
about their actions and consequences. A well-defined problem specifies what the agent knows (state), what it can do
(actions), how the world changes (transition), how to test success (goal), and how to measure efficiency (cost).
Without a formal problem definition, search algorithms and intelligent behavior cannot function effectively. Therefore,
defining the problem is always the first step in creating an intelligent agent.
Search algorithms as shown in below Fig.1.14 are techniques used in Artificial Intelligence (AI) and Computer Science to
find a path, solution, or specific data from a given set of possibilities or a search space. They can be broadly classified into
uninformed (blind) and informed (heuristic) search algorithms.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 42
Introduction to AI and Applications (1BAIA103/203)
● Completeness: A search algorithm is complete if it guarantees at least one solution for a given input.
● Optimality: A search algorithm is optimal if it provides the best solution with the lowest path cost.
○ Space Complexity: The amount of memory required for the search process.
A good search algorithm should use less time and less memory
In AI, a search is a process by which an agent explores different possible states to find a path from the start state (initial
condition) to the goal state (desired outcome). A search algorithm systematically looks through a problem’s state space —
that is, all possible configurations of the system.
Uninformed Search: Uninformed search, also known as blind search, refers to a category of search strategies that have no
additional information about the problem domain beyond what is provided in the problem definition. In other words, the
algorithm does not know how close it is to the goal or which direction is better to move. It searches blindly through the state
space until it finds the solution. Search algorithms are fundamental tools that help an intelligent agent explore possible states
or paths to find a solution to a given problem. These algorithms operate on a search tree or graph, where each node represents
a possible state and each edge represents an action that leads to another state.
Among the most basic search algorithms are Depth-First Search (DFS), Breadth-First Search (BFS), and Uniform Cost
Search (UCS) — all of which are part of uninformed search methods (i.e., they do not use heuristics).
● The goal test (a way to check if the goal has been reached)
There are several types of uninformed search algorithms, each with a different exploration strategy:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 43
Introduction to AI and Applications (1BAIA103/203)
Fig:1.15: DFS
Depth First Search (DFS) is a simple search algorithm used to explore a tree or graph by starting from the root node and
exploring as far down a branch as possible before backtracking. It expands the deepest unexpanded node first and continues
until the goal is found or no more nodes remain. Working Principle: DFS starts from the root node and keeps exploring
deeper along one branch. If it reaches a node with no unexplored children, it backtracks to the previous node and explores
another path. DFS uses a Stack (LIFO – Last In, First Out) data structure or recursion. Example: A DFS-based AI maze
solver moves along one corridor until it reaches a dead end, then backtracks and tries another path.
Steps of DFS:
1. Start from the root node: Begin searching from the root node (node A).
2. Explore each branch: Move from node A to its child node (B), then to the next child (D), and continue exploring
until you reach the leaf node (the last node of that branch).
3. Backtrack: If the key you're looking for isn't found at the leaf node, backtrack to the last node with unexplored
branches and explore them.
4. Repeat the process: Continue exploring each branch by backtracking and then moving to the next unexplored
branch, until the entire tree is searched or the goal is found.
● Since h is a leaf and the key aren’t found, backtrack to node b and explore node e, then node i (leaf node).
● Once all branches of node b are explored move to node c, then node f, node k, and finally node g.
Path Found: a → b → d → h → e → i → j → c → f → k → g
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 44
Introduction to AI and Applications (1BAIA103/203)
Advantages:
● Less Memory Usage: DFS stores only the nodes along the path from the root node to the current node, requiring
less memory.
● Faster to Reach Goal: It often takes less time to find a goal compared to Breadth First Search (BFS), especially
when the solution is deep in the tree.
Disadvantages:
● Recurring States: Sometimes, many states repeat. In such cases, there’s no guarantee of finding the solution.
● Infinite Loops: DFS may get stuck in an infinite loop when it keeps going deeper.
● Complexity: The algorithm's complexity depends on the number of paths it needs to explore.
● Duplicate Nodes: DFS cannot check for duplicate nodes, potentially leading to inefficiency in the search.
Breadth-First Search explores all nodes at the current level (depth) before moving to nodes at the next level. It expands the
shallowest unexpanded node first, ensuring that it explores the search tree level by level. Working Principle: BFS starts at
the root node (initial state). It explores all the neighboring nodes first, then moves on to their neighbors. It continues until
the goal state is found or all nodes are explored.
BFS uses a Queue (FIFO – First In, First Out) data structure. Example: If an AI agent is searching for the shortest route
between two cities, BFS will explore all nearby cities first before moving further.
How It Works:
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 45
Introduction to AI and Applications (1BAIA103/203)
● Start at the root node: The search begins at the root node
● Traverse level by level: First, visit the immediate children of the root
● Move to the next level: After visiting all nodes at the current level, the search moves to the next level
● Continue level-wise traversal: The algorithm continues this process, exploring all neighbor nodes (children) at
each level before moving deeper
Consider the graph shown below, where the goal is to find Node G starting from Node A.
Path Found: a → c → g
Fig.1.17 :BFS
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 46
Introduction to AI and Applications (1BAIA103/203)
Advantages:
● If there is more than one solution , then BFS can find the minimal one that requires less number of steps.
Disadvantages:
● Memory requirement: since each level of the graph must be saved in order to generate the next level.
● Slow for deep solution: if solution is located deep within graph bfs can be insufficient as it explores all nodes.
Uniform Cost Search is a search strategy that expands the node with the lowest total path cost (g(n)) from the start node.
Unlike BFS and DFS, UCS takes into account the cost of each action rather than the number of steps. Working Principle:
UCS maintains a priority queue ordered by path cost (g(n)). It always selects the node with the lowest cost so far for
expansion. The search continues until the goal node is selected for expansion. It guarantees finding the least-cost path
(optimal solution).
Example:
In a road navigation system, UCS helps find the cheapest travel path between two cities based on distance or fuel cost, not
just the fewest hops.
Unlike Breadth-First Search (BFS) or Depth-First Search (DFS), UCS does not expand nodes in a predefined order (level-
wise or depth-wise).
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 47
Introduction to AI and Applications (1BAIA103/203)
● Instead, it selects the next node to explore based on the lowest cumulative path cost from the start node.
● The algorithm always expands the node with the minimum total path cost from the root.
● It maintains a priority queue (often implemented as a min-heap) to keep track of nodes, prioritized by their
cumulative cost.
Cost Definition
● cost(root) = 0
Algorithmic Behavior
● For each child of the expanded node, compute: new cost = cost(parent) + step cost
Example
● Traversal Steps: From S, explore nodes with the least cost first.
● Sequence of exploration: S → A → C → G
● Path Cost = 4
● Optimal Path = S → A → C → G
Total Cost = 4
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 48
Introduction to AI and Applications (1BAIA103/203)
Example
● Find the path and cost to move from node S to node G in the graph given below
● Path Found: S → A → B → G
● Total Cost: 5
Advantages
● Optimal: Always finds the least-cost solution if all costs are positive.
● Complete: Guaranteed to find a solution if the state space is finite and there are no zero-cost loops.
● General Applicability: Works even when step costs vary across transitions.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 49
Introduction to AI and Applications (1BAIA103/203)
Disadvantages
● High space requirement due to maintaining a priority queue of all generated nodes.
References
[Link] Russell and Peter Norvig, Artificial Intelligence: A Modern Approach (4th Edition), Pearson Education, 2023.
[Link] Thareja, Artificial Intelligence: Beyond Classical AI, Pearson Education, 2023.
[Link] Rich, Kevin Knight, and Shivashankar B. Nair, Artificial Intelligence, McGraw Hill Education.
Summary
● Artificial Intelligence aims to make machines behave intelligently and perform human-like tasks such as reasoning,
learning, and decision-making.
● Alan Turing’s contribution in 1950 laid the foundation of AI research through the concept of the Turing Test.
● Modern AI systems are widely used in applications such as healthcare, robotics, finance, transportation, and
entertainment.
● Key AI technologies include Machine Learning, Deep Learning, and Natural Language Processing.
● AI works by collecting and analyzing large datasets, identifying useful patterns, and applying decision-making
algorithms.
● Through these stages, AI systems evolve to perform complex tasks autonomously — such as language translation,
medical diagnosis, and autonomous driving.
● AI offers enormous potential to improve accuracy, efficiency, and innovation in every field—from healthcare and
finance to agriculture and education.
● However, it also introduces challenges such as high cost, dependency on data, and limited generalization.
● To effectively use AI, industries must balance automation and human oversight.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 50
Introduction to AI and Applications (1BAIA103/203)
● Understanding both the advantages and disadvantages helps in designing responsible and ethical AI systems.
● The evolution of AI spans over eight decades, transitioning from theoretical ideas of artificial neurons to real-world
intelligent systems.
● Each milestone represents progress—from logical computation to machine learning, deep learning, and agentic AI
systems today.
● Understanding this timeline helps to appreciate how AI has grown into a multidisciplinary field impacting science,
business, healthcare, and society.
● Logic is fundamental to AI because it enables machines to reason systematically, derive new facts from old ones,
and make explainable decisions. It is the basis of knowledge representation, inference, and planning — allowing
AI to mimic human-like rationality but without human error.
● Modern AI still uses logical reasoning in combination with data-driven learning, especially in rule-based expert
systems, medical diagnostics, and automated decision support systems.
● Probability plays a central role in AI by enabling machines to deal with uncertain, incomplete, or noisy information.
● It is essential for prediction, decision-making, learning from data, and risk management. Unlike logical systems that
require exact facts, probabilistic AI can handle the complexity of real-world environments.
● Modern AI systems combine probability with data-driven learning to balance accuracy and uncertainty — for
example, in medical diagnosis, autonomous driving, and intelligent assistants. Thus, probability forms the
foundation of intelligent decision-making in the presence of uncertainty.
● Cognitive science is a key foundation of Artificial Intelligence. It provides insight into how humans think, learn,
and reason, which helps in developing intelligent systems that can imitate these capabilities. By integrating
knowledge from psychology, linguistics, neuroscience, and computer science, cognitive science allows AI to:
Perceive and understand the world, Learn from experience, Communicate using natural language, and Solve
problems effectively.
● This interdisciplinary approach ensures that AI systems are not just computationally powerful but also human-like
in behavior and reasoning.
● Thus, cognitive science is the bridge between human intelligence and artificial intelligence, guiding the
development of next-generation intelligent systems.
● The three foundations of AI — Logic, Probability, and Cognitive Science — complement one another to create
intelligent, reliable, and human-centered systems. Logic provides rules and exact reasoning → useful when facts
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 51
Introduction to AI and Applications (1BAIA103/203)
are precise. Probability manages uncertainty and noisy data → useful when information is incomplete. Cognitive
Science models human-like understanding and interaction → useful for natural communication and usability.
● AI systems are most effective when they combine all three: Logic ensures safety and explainability, Probability
ensures robustness under uncertainty, and Cognitive Science ensures human-like usability and trust. Hence,
understanding these three foundations is essential for any AI engineer to build intelligent, ethical, and practical
systems.
● An agent perceives its environment and acts upon it to achieve goals. The agent function maps percept sequences
to actions (theory). The agent program implements this mapping in software (practice).
● The architecture provides the physical means to sense and act. The relationship can be summarized as: 𝐴𝑔𝑒𝑛𝑡 =
𝐴𝑟𝑐ℎ𝑖𝑡𝑒𝑐𝑡𝑢𝑟𝑒 + 𝑃𝑟𝑜𝑔𝑟𝑎𝑚
● Modern agents overcome these limits through learning, reasoning, and adaptability.
● Understanding agent mechanisms is the first step toward building intelligent, goal-directed AI systems such as
autonomous robots, smart assistants, and self-driving cars.
● Modern agents overcome these limits through learning, reasoning, and adaptability.
● Table-driven agents are inefficient because they require large memory and lack adaptability.
● AI aims to build compact, efficient algorithms that can generalize and act rationally.
● Newton’s Method analogy illustrates how AI replaces static lookup methods with dynamic computation.
● The four agent types form the foundation for modern intelligent systems, progressing from reflexive to learning-
based behavior.
● A Simple Reflex Agent acts only on the current percept, without memory or history. It follows Condition–Action
Rules (if–then statements). It is fast and simple but not adaptable to complex or dynamic environments. The design
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 52
Introduction to AI and Applications (1BAIA103/203)
is more efficient than table-driven agents because it avoids huge percept lookup tables. Example: Vacuum Cleaner
Agent, Automated Taxi Braking System.
● Simple Reflex Agents are easy to design but lack memory, learning, and adaptability. They act only on the current
percept and fail in partially observable environments. They are susceptible to infinite loops when they cannot
distinguish between similar states.
● Randomization can help break loops but does not lead to rational intelligence. More advanced agents, such as
Model-Based and Goal-Based Agents, are required for dynamic, uncertain environments.
● Goal-Based Agents combine knowledge of the environment and specific goals to make purposeful decisions. They
evaluate future outcomes to select actions that move toward their goals. Introduce search and planning as reasoning
tools for decision-making. More flexible and adaptable than reflex agents, but computationally heavier. Examples:
Self-driving taxis, robotic path planning, and intelligent assistants that plan tasks.
● Utility-Based Agents go beyond goals, focusing on maximizing satisfaction or desirability. They are capable of
reasoning under uncertainty using expected utility. They form the foundation for decision theory, reinforcement
learning, and modern AI planning. Example: A self-driving taxi selecting the safest and most efficient route, not
merely reaching the destination.
● A rational agent in AI is not necessarily a perfect agent—it simply does the best it can given its knowledge, percepts,
and limitations.
● The design of rational behavior is the foundation for building intelligent systems in areas like robotics, self-driving
cars, and automated assistants.
● Depth-First Search (DFS), Breadth-First Search (BFS), and Uniform Cost Search (UCS) are fundamental search
algorithms in AI used for problem-solving and pathfinding.
● They differ mainly in how they explore the search space — DFS dives deep, BFS spreads wide, and UCS follows
the cheapest path.
Prepared by: Dr Roopashree S, Dr. Venkata Madhava Ram Tatabhatla and Prof. Asha 53
Advances in cognitive science have contributed to AI system development by offering insights into human perception, learning, and decision-making, enabling machines to mimic these processes. By integrating knowledge from cognitive science disciplines, AI systems are designed to perceive environments, understand language, and solve problems like humans. They employ machine learning techniques to learn from data and experiences, fostering systems that adapt and reason more naturally and effectively .
Problem-Solving Agents offer the advantage of systematically searching and reasoning to determine a sequence of actions from an initial state to a goal state, which is particularly beneficial in dynamic environments. They model actions and outcomes precisely, using search algorithms to explore possible solutions. This allows them to handle multi-step environments better than Reflex Agents, which only react to current percepts, and Goal-Based Agents, which focus primarily on achieving goals without systematic planning .
Logic plays a critical role in AI's reasoning framework by providing a formal language for representing facts, relationships, and rules. It allows AI systems to derive conclusions systematically, fostering rationality and explainability. Logic complements probability and cognitive science by addressing different challenges: it handles deterministic scenarios, while probability supports uncertain data, and cognitive science enhances human interaction. Together, these elements enable AI to function efficiently across a range of real-world environments .
Integrating cognitive science into AI systems facilitates natural language communication by using insights from fields like psychology and linguistics to develop NLP capabilities. This allows AI to perceive and communicate effectively. For problem-solving, cognitive science contributes human-inspired reasoning methods, enhancing AI's ability to learn from experiences and solve problems through pattern recognition and memory recall, resulting in more human-like and reliable interactions .
In autonomous vehicle systems, logic is used to follow traffic rules such as "If red light → stop." Probability helps the system handle uncertain sensor inputs, like estimating an 85% chance that an object is a pedestrian. Cognitive science is applied to predict human behavior, such as pedestrian crossing patterns, and design driver-friendly alerts. These three foundations enable AI to reason correctly, manage uncertainty, and provide natural interaction, leading to robust and reliable autonomous vehicle performance .
The primary difference is that a Model-Based Reflex Agent can handle partial observability by maintaining an internal model of the world, which stores past percepts and predicts unseen environmental aspects. This allows the agent to make informed decisions even when it cannot perceive the entire environment at once. In contrast, a Simple Reflex Agent acts only on current percepts without memory, making it unsuitable for complex or partially observable situations .
Balancing automation and human oversight is essential in highly sensitive domains to ensure accuracy, accountability, and ethical responsibility. AI systems can improve efficiency and innovation but may struggle with data dependency and generalization challenges. Human oversight helps address these limitations by providing ethical guidance, interpreting AI insights critically, and ensuring decisions align with societal values, crucial in healthcare, finance, and education .
Cognitive science enhances AI functionalities by replicating human mental functions like perception, memory, and language understanding. This capability helps AI interact more naturally in human contexts by using computer vision, speech recognition, and natural language processing. For example, emotion-recognition systems and chatbots can respond empathetically, creating more intuitive user experiences . Through these parallels, cognitive science bridges human intelligence and machine intelligence, allowing AI systems to make decisions transparent and trustworthy, particularly in fields like medicine and education .
Probabilistic reasoning enhances decision-making in AI systems by allowing them to handle uncertainty, noise, and incomplete information, crucial in unpredictable environments. It enables AI to estimate event likelihoods, evaluate risks, and make informed decisions even when data is ambiguous or partial. For example, probabilistic models support autonomous vehicles in predicting obstacles in their path and medical diagnosis assistants in estimating disease likelihoods from patient data .
Goal-Based Agents differ from Model-Based Reflex Agents in that they use both the current state of the environment and a defined goal to make purposeful, goal-directed decisions. While Model-Based Reflex Agents act based on fixed condition-action rules using their internal model, Goal-Based Agents evaluate how different actions bring them closer to achieving particular goals. The decision-making process thus involves selecting actions that not only respond to current conditions but also consider desired outcomes .