0% found this document useful (0 votes)
7 views12 pages

Artificial Intelligence

The document provides an overview of Artificial Intelligence (AI), defining it as the study of intelligent agents and categorizing AI systems into four types based on their behavior. It discusses the components of AI agents, the PEAS framework for task environments, and various types of agents, as well as the properties of environments in which they operate. Additionally, it covers the importance of AI, its application areas, and introduces concepts of Machine Learning, including its fundamentals and practical steps.

Uploaded by

Adeosun John
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views12 pages

Artificial Intelligence

The document provides an overview of Artificial Intelligence (AI), defining it as the study of intelligent agents and categorizing AI systems into four types based on their behavior. It discusses the components of AI agents, the PEAS framework for task environments, and various types of agents, as well as the properties of environments in which they operate. Additionally, it covers the importance of AI, its application areas, and introduces concepts of Machine Learning, including its fundamentals and practical steps.

Uploaded by

Adeosun John
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 12

ARTIFICIAL INTELLIGENCE

Artificial Intelligence (AI), is defined as the study and design of


intelligent agents that perceive their environment and act to maximize
success. AI aims to automate or replicate intelligent behavior.

TYPES OF AI SYSTEMS
AI systems into four types:

 Those that think like humans (e.g., neural networks),


 Act like humans (e.g., Turing test passers),
 Think rationally (e.g., logic solvers),
 Act rationally (e.g., intelligent agents)

AI Agents
An agent perceives its environment through sensors and acts upon that
environment through actuators.

Components:

 Sensors: How the agent perceives the environment (e.g., eyes, ears
for humans; cameras, sonar for robots).
 Actuators/Effectors: How the agent acts on the environment (e.g.,
hands, legs for humans; grippers, motors for robots).

Behavior: An agent's behavior is defined by a function mapping percepts


(sensor inputs) to actions.

Rationality: A rational agent aims to "do the right thing" to maximize a


performance measure given its percept sequence. Rationality doesn't
mean omniscience or clairvoyance, as environments can be partially
observable or stochastic.

PEAS Framework: Used to describe the task environment: Performance


measure, Environment, Actuators, Sensors.

Use PEAS to describe task environment

Example: Taxi driver

 Performance measure: safe, fast, comfortable (maximize profits)


 Environment: roads, other traffic, pedestrians, customers
 Actuators: steering, accelerator, brake, signal, horn
 Sensors: cameras, sonar, speedometer, GPS, odometer,
accelerometer, engine sensors

The agent's behavior is governed by an agent function that maps a


sequence of percepts to an action. The concept of rationality is key: a
rational agent acts in a way expected to maximize its goal achievement,
given its beliefs and percepts. This often involves capabilities like
perception, planning, reasoning, learning, communication, decision-
making, and acting. Goal-based agents, a type of rational agent, decide
what to do by searching for a sequence of actions that lead to their
solutions.

Types of Agents
Agents are classified into types with increasing generality and capability
to handle complex environments:

 Simple Reflex Agents: Act only based on the current percept


using simple condition-action rules.
 Reflex Agents with State: Maintain internal state based on past
percepts to inform current decisions, allowing them to handle
partially observable environments.
 Goal-Based Agents: Act to achieve explicit goals, considering the
future consequences of their actions through planning or search.
 Utility-Based Agents: Choose actions that maximize expected
utility/outcomes, using a utility function to evaluate the desirability
of outcomes, especially when goals conflict.
 Learning Agents: Can improve their performance over time by
learning from experience and adapting to unknown environments.

Environment Properties
Fully Observable vs. Partially Observable:

 Fully Observable: If everything relevant to the agent's decision-


making is perceivable, the environment is fully observable.
Examples given include Chess (with or without a clock) and
Backgammon.
 Partially Observable: If the agent cannot access the complete
state of the environment due to noisy or inaccurate sensors, or parts
of the state simply being hidden from the agent, the environment is
partially observable. Examples include Poker (opponent's cards are
hidden), Taxi driving (can't know exactly what other drivers are
thinking), and Medical diagnosis (internal state of the patient isn't
fully known).

· Deterministic vs. Stochastic / Strategic:

 Deterministic: The next state of the environment is completely


determined by the current state and the action executed by the
agent. There's no uncertainty in the outcome of an action. Image
analysis and Robot part picking are given as examples of
deterministic environments.
 Stochastic: The next state involves randomness or
unpredictability; the outcome of an action isn't guaranteed.
Backgammon (due to dice rolls), Taxi driving (unpredictable
traffic/customers), Medical diagnosis (unpredictable patient
response), and Interactive English tutor (student responses are
unpredictable) are examples.
 Strategic: This is a subtype where the environment's evolution
depends on another agent's actions. Chess and Poker are strategic
environments because the opponent's moves directly affect the
state.

· Episodic vs. Sequential:

 Episodic: The agent's experience is divided into atomic "episodes."


In each episode, the agent perceives and then performs a single
action. The choice of action in one episode does not depend on
actions taken in previous episodes. Medical diagnosis and Image
analysis are listed as examples, suggesting each patient case or
image might be treated independently.
 Sequential: The current decision can affect all future decisions.
The agent needs to think ahead because actions have long-term
consequences. Chess, Poker, Backgammon, Taxi driving, and
Interactive English tutor are sequential environments.

· Static vs. Dynamic:

 Static: The environment does not change while the agent is


deliberating or deciding on its next action. Chess without a clock,
Poker, and Backgammon are static in this sense (the board waits
for the agent's move). Medical diagnosis is also listed as static.
 Dynamic: The environment can change while the agent is
thinking. Taxi driving is a key example, as traffic conditions
change continuously. Interactive English tutor is also dynamic.
Chess with a clock is considered semi-dynamic because the clock
keeps running.

· Discrete vs. Continuous:

 Discrete: The environment's state, the way time is handled, and the
agent's percepts and actions are distinct and separate (finite or
countably infinite). Chess, Poker, Backgammon, and Interactive
English tutor are examples of discrete environments.
 Continuous: States, time, percepts, or actions flow smoothly and
can take on real-valued quantities. Taxi driving (speed, position)
and Medical diagnosis (temperature, blood pressure) involve
continuous variables.

· Single Agent vs. Multiagent:

 Single Agent: Only one agent is operating in the environment.


Medical diagnosis, Image analysis, and Robot part picking are
listed as single-agent tasks.
 Multiagent: Multiple agents interact within the environment. This
can be competitive (like Chess, Poker, Backgammon) or
cooperative. Taxi driving involves multiple agents (other drivers,
pedestrians, customers). An Interactive English tutor is also
multiagent (agent and student).

Features of AI
Based on the definitions, approaches, and examples, key features and
areas within AI include:

 Acting/Thinking Humanly/Rationally: Different philosophical


approaches to achieving intelligence.
 Perception: Using sensors to understand the environment.
 Reasoning: Logical deduction, problem-solving, planning.
 Learning: Adapting behavior based on experience.
 Knowledge Representation: Storing and structuring information.
 Problem Solving: Finding solutions to defined problems.
 Decision Making: Choosing actions to achieve goals.
 Autonomy & Flexibility: Systems that can operate independently
and adapt.
 Interaction with Environment: Operating within various types of
environments (observable, deterministic, static, discrete, etc.).
 Specific Capabilities: Natural language processing, computer
vision, robotics, search, planning, uncertainty reasoning.

Importance of AI
AI's importance is highlighted through its goals and applications:

 Utility: It makes computers more useful.


 Problem Solving: AI provides powerful tools and methodologies
for solving business and real-world problems.
 Impact: An intelligent computer would significantly impact
civilization.
 Advancement: It is considered a desirable field, yielding benefits
for computer science and other fields.
 Specific Applications: Practical applications demonstrate its
importance in areas like game playing, speech recognition, natural
language understanding, computer vision, expert systems,
consumer marketing analysis, identification technologies,
intrusion detection, and machine translation.

Application Areas of AI

 General Areas: Natural Language Processing, Machine Learning,


Planning, Robotics, Vision, Expert Systems, Game Playing,
Speech Processing, Theorem Proving.
 Specific Examples: Chess playing, Medical Diagnosis (MYCIN,
Pathfinder), Fraud Detection, Scheduling (Factory floor, Shuttle
packing), Autonomous Driving (Alvinn), Translation, Credit Card
Transaction Monitoring, Consumer Marketing, Identification
Technologies, Intrusion Detection, Military Planning.
Heuristic Functions for Solving Puzzle Questions

The term "heuristic" refers to a way of trying to discover something or an


idea embedded in a program. In the context of search and problem-
solving (like puzzles):

 Heuristic Search: Informed search methods use heuristic


functions, h(n), to estimate the cost from a state 'n' to the goal.
o A* Search: Uses an evaluation function f(n) = g(n) + h(n),
where g(n) is the cost to reach node n and h(n) is the
heuristic estimate to the goal. It's optimal if h(n) is
admissible (never overestimates the cost).
o Greedy Best-First Search: Expands the node considered
closest to the goal based on a heuristic.

 Heuristic Functions (h(n)): Used in search algorithms like A* to


measure how far a node seems to be from a goal. For example, the
straight-line distance in route finding or the Manhattan distance for
the 8-puzzle (though the 8-puzzle isn't explicitly named as a puzzle
in the text, the 8-queens problem is, and heuristics apply similarly).
 Heuristic Classification: A type of expert system that categorizes
information using multiple sources, like advising on credit card
purchases.
 Heuristics in Constraint Satisfaction (e.g., 8-Queens Puzzle):
The 8-Queens problem is presented as a Constraint Satisfaction
Problem (CSP). Heuristics help solve CSPs efficiently:

o Most-Constrained Variable: Choose the variable with the


fewest remaining legal values.
o Most-Constraining Variable: Choose the variable that
imposes the most constraints on remaining variables.
o Least-Constraining Value: Choose a value for a variable
that leaves the maximum number of choices for other
variables.
o Heuristic Repair (Min-Conflicts): Start with an initial
configuration (possibly flawed) and iteratively modify it by
choosing a conflicting variable and moving it to a state that
minimizes conflicts. This is shown to be effective for the n-
queens problem.
Fuzzy Set Theory

The core idea behind Fuzzy Set Theory, introduced by Lotfi Zadeh, is to
mathematically represent vagueness and imprecise information, which are
common in real-world knowledge and human reasoning. Unlike classical
(crisp) set theory where an element either belongs (membership 1) or
does not belong (membership 0) to a set, fuzzy set theory allows for
degrees of membership.

 Properties: Fuzzy operations retain many properties of crisp sets


like Commutativity and Associativity for Union and Intersection,
Identity, Idempotence, and Distributivity laws. However, the
standard laws of excluded middle (A ∪ A' = X) and contradiction
(A ∩ A' = Φ) do hold for fuzzy sets under the standard definitions.
 Fuzzy Relations: A fuzzy relation R between sets A and B is a
fuzzy subset of the Cartesian product A x B, defined by a
membership function µ<0xE1><0xB5><0xA1>(x, y) that gives the
degree of association between elements x ∈ A and y ∈ B. It can be
represented as a matrix.
 Composition: Operations like max-min composition (R1 ο R2)
combine relations across a shared domain (e.g., R1(x,y) and
R2(y,z) combine to relate x and z).

Fuzzy Logic

Fuzzy Logic extends classical two-valued (True/False or 1/0) logic by


allowing truth values to be continuous quantities ranging from 0 to 1. It
deals with reasoning that is approximate rather than precise.

 Fuzzy Propositions: These are statements that acquire a fuzzy


truth value T(P) between 0 and 1. T(P)=0.8 might mean "P is
partially true".
 Fuzzy Connectives: These extend logical connectives:

o ¬P (Negation): T(¬P) = 1 - T(P).


o P ∨ Q (Disjunction): T(P ∨ Q) = max(T(P), T(Q)).
o P ∧ Q (Conjunction): T(P ∧ Q) = min(T(P), T(Q)).
o P ⇒ Q (Implication): Often defined based on tautologies like
¬P ∨ Q, leading to T(P ⇒ Q) = max(1 - T(P), T(Q)). Other
definitions exist.
 Fuzzy Inference (Approximate Reasoning): This involves
evaluating linguistic descriptions, often using fuzzy IF-THEN
rules. Key inference procedures include:
 Fuzzy Rule-Based Systems: These use collections of fuzzy IF-
THEN rules (the rule base) to represent knowledge. The overall
conclusion can be derived by combining the consequents of
triggered rules, often using intersection (min) or union (max).
 Fuzzy Systems Framework:

o Fuzzification: Converts crisp input values (e.g., speed = 70


km/h) into degrees of membership in fuzzy sets (e.g., 0.75 in
"Low Speed", 0.25 in "Medium Speed").
o Fuzzy Inference: Combines fuzzified inputs with the fuzzy
rule base to derive fuzzy conclusions.
o Defuzzification: Converts the resulting fuzzy output set
back into a single crisp value (e.g., a specific control action).
Common methods include the Centroid (center of gravity)
method.

In essence, Fuzzy Set Theory provides the tools to represent vagueness,


while Fuzzy Logic provides the framework to reason with that vagueness,
enabling the creation of systems that can handle imprecise, human-like
knowledge and data.

MACHINE LEARNING
· Machine Learning (ML) Overview:

 ML is presented as a crucial technical approach within AI,


underpinning recent advances. It's shown as an interdisciplinary
field drawing from computer science, statistics, optimization,
neuroscience, etc..
 Definitions of ML are provided: extracting unknown useful
information from data and enabling computers to learn from data
without explicit programming using statistical tools. The goal is
automatic learning and action adjustment.
 Everyday examples like image recognition (tagging photos) and
voice/number recognition are mentioned. ML is contrasted with
older "expert systems," emphasizing ML's approach of deriving
rules from data. A diagram contrasts traditional programming
(Program + Data -> Output) with ML (Data + Output -> Program).
 Numerous application areas are listed, including web search,
computational biology, finance, e-commerce, health informatics,
robotics, information extraction, social networks, language
processing, and security.

ML Fundamentals:

 · The document states that ML algorithms have three core


components:

o Representation: How knowledge is represented (e.g.,


decision trees, rules, instances, graphical models, neural
networks, SVMs).
o Evaluation: How models are assessed (e.g., accuracy,
precision/recall, squared error, likelihood, cost/utility,
entropy).
o Optimization: How good models are found (e.g.,
combinatorial search, convex optimization like gradient
descent, constrained optimization).

 Types of Learning: The main paradigms are outlined: Supervised


(training data has desired outputs), Unsupervised (no desired
outputs given), Semi-supervised (few desired outputs given), and
Reinforcement learning (learning from rewards/actions). Inductive
learning (a form of supervised learning) aims to predict a function
F(X) for new X given examples (X, F(X)), covering classification,
regression, and probability estimation.

· ML in Practice & Preprocessing:

 · The practical steps of applying ML are outlined: understanding


the domain, data integration/selection, preprocessing,
transformation, modeling, interpreting results, and deployment.
 Preprocessing: Focuses on data cleaning:

o Outlier Detection: Identifying and handling unusual data


points caused by errors or abnormalities.
o Missing Data: Discusses the impact of missing data and its
causes (e.g., faulty equipment, human error). Various
treatment methods are listed: Case Deletion, Mean/Mode
Imputation, All Possible Values Imputation, Regression
Imputation, Forward/Backfill, C4.5 handling, Hot deck,
kNN imputation.
o Data Discretization/Normalization: Converting data types.
Methods mentioned include Decimal Scaling, Min-Max
Normalization, Standard Deviation Normalization, Equal-
width, Entropy, and Binarization (using mean as a
threshold).

· Feature Selection (FS):

 · FS is described as identifying relevant features, removing


noise/redundancy, and reducing computation time.
 Methods discussed include:

o Entropy-based: Using Information Gain and Gain Ratio.


Formulas for Info(D) (Entropy), Gain(S,A), Split Info, and
Gain Ratio are given. Detailed calculations are shown for the
example dataset (Table 4 description, Table 5 attributes ),
leading to a ranking of features (Table 6).
o Correlation-based (CFS): Using Pearson correlation
coefficient (formula provided) to find correlation between
features, illustrated with an example calculation showing
perfect correlation between 'state' and 'dwin' features from
the sample data.

· Supervised Learning Algorithms:

 Naïve Bayesian Classifier: Explains how it assigns the most


probable class (Maximum A Posteriori - MAP) to an instance
represented by attribute vectors. It relies on the "naïve" assumption
of conditional independence between attributes given the class. The
classification formula is provided. An illustrative example using
sample data (Table 7) demonstrates calculating prior probabilities
and conditional probabilities (using Laplace adjustment) to classify
a new tuple.
 Rough Set Theory (RST): Introduced as a mathematical tool for
imprecise knowledge, pattern finding, and data reduction. Key
concepts include:
 k-Nearest Neighbors (kNN): A supervised algorithm classifying
new instances based on the majority class among its 'k' nearest
neighbors in the training data. Closeness is measured using a
distance metric, typically Euclidean distance (formula given). The
steps (determine k, calculate distances, sort distances, gather
categories, use majority vote) are listed. An example classifies a
new instance using k=3 and the Table 7 data, showing distance
calculations (Table 8) and the sorted nearest neighbors (Table 9)
leading to the final classification. Its ease of implementation but
computational intensity are noted.

· Unsupervised Learning (Clustering):

 Clustering is defined as grouping similar objects. k-means and


fuzzy c-means are mentioned as techniques.
 k-Means: The algorithm is outlined: initialize K cluster centers
(centroids), then iteratively assign objects to the nearest centroid
and recalculate centroids based on assigned objects, until centroids
stabilize. A detailed numerical example using 4 data points (Table
10) and K=2 is walked through, showing initial centroid choice,
distance calculations, object grouping, centroid recalculation, and
subsequent iterations until convergence (G2=G1).
 Fuzzy C-Means: The algorithm steps and key formulas (objective
function J, centroid calculation c, membership update u) involving
a fuzzy coefficient 'm' are listed briefly.

· Ensemble Classifiers:

 · Ensemble methods combine multiple models (classifiers) to


achieve better accuracy and reliability than a single model. A
diagram illustrates how techniques like Bagging or Boosting create
multiple models (M1...Mk) from training data, which then
collectively predict labels for new tuples.

Deep Learning:

 Introduced as a branch of ML modeling data with complex


architectures using multiple non-linear transformations, with
Neural Networks (NNs) as the elementary bricks. NN components
(input, hidden, output layers) are listed.
 Deep Neural Networks (DNNs): NNs with more than one hidden
layer.
 Types: Feedforward (acyclic graph) and Recurrent (RNNs - cyclic
graph).
 Feedforward Example: A detailed numerical example
demonstrates the feedforward and backpropagation process (using
batch learning) for a simple network:
 Recurrent Neural Networks (RNNs): Defined by having
cycles/recurrent connections, allowing memory of previous inputs
via hidden states. Equations for computing hidden state (ht) and
output (yt) using activation functions (f, g) and weight matrices
(whh, wxh, why) are given. Training involves Backward
Propagation Through Time (BPTT). Limitations like
vanishing/exploding gradients are noted, along with the
backpropagation update rule. Strategies to overcome these issues
(gradient clipping, ReLU activation, LSTM) are mentioned.
 Long Short-Term Memory (LSTM): Presented as an improved
RNN architecture to solve the vanishing gradient problem using
gating mechanisms (forget, input, output gates) and a cell state. A
detailed numerical example walks through:

You might also like