You are on page 1of 16

KNOWLEDGE REPRESENTATION USING

BAYESIAN NETWORKS AND FRAMES

Name Student Number


Onele Mabhena N0199164Y
Donald Maziva N0198074X
Bruce Thabisile Mpofu N0198103C
Mthokozisi Sibanda N0196692B
Yancy V Nthakomwa N0198789M
Basildon Shumba N0196321C
Philani Mkhwananzi N0199106M
Tapiwa Choto N0198616N
Nqaba Jabulani Sikeyi N0199637X
Bester N Sibanda N0198515L
Ozasondla Moyo N0197976F
Rapelang Mackenzie N0196861T
Tatenda Jaricha N0189062V
KNOWLEDGE REPRESENTATION

Knowledge representation refers to the process of capturing and structuring knowledge in a form that
can be used by a computer or other artificial intelligence system.
It involves identifying and formalizing the relationships between concepts, objects, and events in a
particular domain, and creating a representation of this knowledge that can be used to reason about new
situations or solve problems.
The aim of knowledge representation is to provide a framework for storing, organizing, and retrieving
knowledge, making it easier for AI systems to reason about complex situations and make informed
decisions
• use Bayes' theorem to update the probability distribution of a variable based on the values of its
parents in the network.
• The theorem states that the probability of a variable given its parents is proportional to the product of
the conditional probabilities of the variable and its parents.
BAYESIAN NETWORKS

• Bayesian Networks (probabilistic graphical models) are graphical models that represent relationships between random variables
using conditional probability distributions.
• They represent a set of random variables and their conditional dependencies using a directed acyclic graph (DAG)
• It consists of nodes representing the variables and edges connecting them to show their relationships.
• The nodes in a Bayesian Network represent random variables, and the edges between them represent the probabilistic
relationships between those variables.
• Each node has a conditional probability table that describes the probability of that node given its parents.
• Inference in Bayesian Networks involves computing the probability of a hypothesis given the evidence.
• Bayesian Networks can be used for a wide variety of tasks, including reasoning under uncertainty, decision-making, and
prediction.
• They are widely used in many fields for complex systems, such as medical diagnoses, financial predictions, or climate forecasting
• Bayesian Networks enable probabilistic reasoning and decision-making under uncertainty and when incomplete information is
availed, as they allow for the modelling of probabilistic relationships between variables.
COMPONENTS OF BAYESIAN NETWORKS
(NODES, EDGES, CONDITIONAL PROBABILITIES)

• Nodes: Nodes represent variables or events in the system being modeled. Each node is
associated with a particular state or value that the variable or event can take.
• Edges: Edges represent the probabilistic relationships between the variables or events
in the system being modeled. An edge connects two nodes and indicates that the
variable represented by the parent node has a causal effect on the variable represented
by the child node.
• Conditional probabilities: Conditional probabilities represent the likelihood of each
possible state or value of a variable, given the values of its parent variables in the
network. In a Bayesian network, the conditional probabilities are represented using
conditional probability tables (CPTs), which specify the probability of each state of a
node given the values of its parents.
EXAMPLES OF AI APPLICATIONS THAT
USE BAYESIAN NETWORKS

• Medical diagnosis: Bayesian networks are commonly used in medical diagnosis applications, where
the goal is to predict the likelihood of a patient having a particular disease or condition. For
example, a Bayesian network can be used to diagnose breast cancer by predicting the probability of
malignancy based on features such as age, family history, and the results of mammography tests.
• Fraud detection: Bayesian networks can be used in fraud detection applications to identify
suspicious activities and transactions. For example, a Bayesian network can be used to detect credit
card fraud by analysing transaction history and predicting the probability of fraud based on patterns
such as unusual spending behaviour or high-risk locations.
• Natural language processing: Bayesian networks can be used in natural language processing
applications to perform tasks such as text classification and sentiment analysis. For example, a
Bayesian network can be used to classify emails as spam or non-spam based on their content and
other features
ADVANTAGES OF BAYESIAN
NETWORKS:

• Probabilistic reasoning: Bayesian networks provide a probabilistic framework for


reasoning and decision-making under uncertainty. This allows for a more realistic
representation of real-world problems, where there is often incomplete or uncertain
information.
• Transparency: The graphical structure of Bayesian networks makes them easy to interpret
and understand. The causal relationships between variables are represented explicitly,
allowing for clear identification of the most influential variables and factors.
• Learning from data: Bayesian networks can be learned directly from data, allowing for the
automatic discovery of complex relationships between variables.
• Flexibility: Bayesian networks are flexible and can be easily extended to include new
variables or factors, or to incorporate new data as it becomes available.
LIMITATIONS OF BAYESIAN
NETWORKS:

• Complexity: Bayesian networks can become very complex as the number of variables and
dependencies increases. This can make them difficult to construct and maintain, and can also
lead to computational difficulties.
• Data requirements: Bayesian networks require a large amount of data to be effective. In
situations where data is scarce or difficult to obtain, the accuracy of the network may be
compromised.
• Expert knowledge: The accuracy and effectiveness of Bayesian networks depend on the quality
of the expert knowledge used to build them. The network may be limited by the availability or
reliability of the expert knowledge.
• Interpretability: Although the graphical structure of Bayesian networks makes them easy to
interpret, the complex relationships between variables can make it difficult to understand the
exact reasons for a particular decision or outcome.
FRAMES

• Frames are a knowledge representation technique that allows for the representation of complex objects and
concepts in a structured way.
• They are used to represent objects, events, and concepts in a domain
• Frames consist of slots, which represent attributes of an object, and values, which represent the values of
those attributes
• For example, a frame representing a car might have slots for the make, model, year, color, and other
characteristics of the car.
• Frames can also include inheritance, where a new frame can inherit attributes from an existing frame.
• Used to represent complex knowledge structures, such as expert systems, natural language processing, and
cognitive modelling.
• Useful in situations where large amount of structured information is to be represented, as they allow for the
easy retrieval and manipulation of that information
COMPONENTS OF FRAMES (SLOTS
AND FILLERS)

• Slots: Slots are the attributes or properties of a frame that define the
characteristics of the object or concept being represented. Each slot has a name
and a type, and can contain one or more values. The values of a slot can be
simple data types, such as numbers or strings, or complex data types, such as
other frames.
• Fillers: Fillers are the values assigned to the slots of a frame. The values can be
either simple or complex data types, depending on the type of the slot. For
example, the slot "color" of a frame representing a car might have a filler value
of "red".
ADVANTAGES OF FRAMES:

• Structured Representation: Frames provide a structured way to represent


knowledge and concepts in artificial intelligence. The use of slots and fillers allows
for the representation of complex relationships between entities and attributes.
• Inheritance: Frames can be arranged in a hierarchical structure, where frames at
higher levels can inherit slots and fillers from their parent frames. This reduces
redundancy and simplifies the representation of complex concepts.
• Flexibility: Frames are flexible and can be easily modified or extended to
accommodate changes in the domain or application.
• Natural Language Processing: Frames are well-suited for natural language
processing applications, as they can be used to represent the meaning of words and
sentences, and the semantic relationships between them.
LIMITATIONS OF FRAMES:

• Complexity: As the number of slots and fillers in a frame increases, the


representation can become complex and difficult to manage.
• Incomplete Information: Frames may not be able to capture all the information
relevant to a particular domain or application.
• Limited Expressiveness: The use of slots and fillers may not be expressive
enough to represent certain types of knowledge or relationships.
• Ambiguity: Frames may be ambiguous in their interpretation, especially when
dealing with complex concepts or relationships
EXAMPLES OF AI APPLICATIONS THAT
USE FRAMES

• Expert systems: Frames are commonly used in expert systems, where knowledge about a domain
needs to be represented in a structured manner. For example, an expert system for diagnosing car
engine problems can use frames to represent the various components of an engine and their
attributes, such as the spark plugs, fuel injectors, and oil pressure.
• Robotics: Frames can be used in robotics applications to model objects and their attributes in the
environment. For example, a robot that needs to navigate through a room can use frames to
represent the various objects in the room and their attributes, such as their location, size, and shape.
• Cognitive modeling: Frames can be used in cognitive modeling applications to represent knowledge
and beliefs about the world. For example, a cognitive model of human reasoning can use frames to
represent concepts such as causality, beliefs, and goals, and how they interact with each other.
SIMILARITIES AND DIFFERENCES BETWEEN
BAYESIAN NETWORKS AND FRAMES
• Similarities
• Both Bayesian networks and frames are used in artificial intelligence to represent knowledge and concepts.
• Both Bayesian networks and frames use a structured representation to capture complex relationships between
entities and attributes.
• Both Bayesian networks and frames can be used to reason about uncertainty and make informed decisions.
• Differences
• Bayesian networks use a probabilistic approach to model uncertainty, while frames do not.
• Bayesian networks represent causal relationships between variables, while frames represent object-oriented
relationships between entities.
• Bayesian networks use directed acyclic graphs to represent the relationships between variables, while frames use
slots and fillers to represent the attributes of entities.
• Bayesian networks can be used for a wide range of applications, such as decision making, prediction, and diagnosis,
while frames are often used for representing knowledge in expert systems and natural language processing.
• Bayesian networks are often used in machine learning, while frames are often used in knowledge-based systems.
HOW KNOWLEDGE REPRESENTATION IMPROVES
THE PERFORMANCE OF THESE AI APPLICATIONS

• Efficient data processing: Knowledge representation allows AI systems to process large amounts of data more efficiently by
identifying patterns and relationships between data points. For example, in a medical diagnosis application, a Bayesian network can
use prior knowledge about a patient's medical history and symptoms to efficiently diagnose their condition, without the need for
extensive testing.
• Improved accuracy: Knowledge representation enables AI systems to make more accurate predictions and decisions by taking into
account all relevant information. For example, in a fraud detection application, a Bayesian network can use prior knowledge about
fraudulent activities and patterns to accurately identify suspicious transactions, improving the accuracy of the system.
• Better human-machine interaction: Knowledge representation enables AI systems to interact more effectively with humans by
representing information in a way that is easy to understand and interpret. For example, in a natural language processing application, a
system that uses frames to represent concepts and relationships can produce more natural and understandable responses to human
queries.
• More flexible and adaptable systems: Knowledge representation allows AI systems to be more flexible and adaptable to changes in the
environment or new data. For example, in a robotics application, a system that uses frames to represent objects and their attributes can
quickly adapt to changes in the environment or the introduction of new objects.
W H I C H T E C H N I Q U E I S B E T T E R S U I T E D F O R W H I C H A I A P P L I C AT I O N S

• The choice of which technique to use, Bayesian networks or frames, depends on the specific AI application and its
requirements. Here are some guidelines on which technique is better suited for which AI application:
• Bayesian networks:
• Classification and prediction: Bayesian networks are well-suited for classification and prediction tasks where uncertainty needs
to be taken into account, such as spam filtering or medical diagnosis.
• Decision making: Bayesian networks can be used to model decision making processes, such as in finance or risk assessment.
• Image recognition: Bayesian networks can be used for image recognition tasks, such as recognizing faces or objects in images.
• Frames:
• Expert systems: Frames are well-suited for building expert systems, where knowledge about a domain needs to be represented
in a structured manner.
• Natural language processing: Frames can be used for natural language processing tasks, such as understanding the meaning of
sentences or extracting information from text.
• Robotics: Frames can be used for modeling objects and their attributes in robotics applications, such as object recognition or
scene understanding.
CONCLUSION

• Overall, the choice of which approach to use depends on the nature of the
problem being addressed and the type of knowledge that needs to be
represented.
• In many cases, a combination of both approaches may be used to create a more
comprehensive and effective representation of the knowledge.

You might also like