0% found this document useful (0 votes)
178 views17 pages

Unit 4

This document discusses knowledge representation in artificial intelligence. It begins by defining knowledge representation and its importance for enabling AI systems to understand and utilize knowledge to solve complex problems. It then describes different types of knowledge that must be represented, including objects, events, facts, and meta-knowledge. The document also covers various approaches to knowledge representation, requirements for effective representation systems, and using semantic networks for knowledge representation.

Uploaded by

skrao
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)
178 views17 pages

Unit 4

This document discusses knowledge representation in artificial intelligence. It begins by defining knowledge representation and its importance for enabling AI systems to understand and utilize knowledge to solve complex problems. It then describes different types of knowledge that must be represented, including objects, events, facts, and meta-knowledge. The document also covers various approaches to knowledge representation, requirements for effective representation systems, and using semantic networks for knowledge representation.

Uploaded by

skrao
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/ 17

UNIT-IV

Knowledge representation

Introduction:
Humans are best at understanding, reasoning, and interpreting knowledge. Human
knows things, which is knowledge and as per their knowledge they perform various
actions in the real world. But how machines do all these things comes under
knowledge representation and reasoning Hence we can describe Knowledge
representation as following:

o Knowledge representation and reasoning (KR, KRR) is the part of Artificial


intelligence which concerned with AI agents thinking and how thinking
contributes to intelligent behavior of agents.
o It is responsible for representing information about the real world so that a
computer can understand and can utilize this knowledge to solve the complex
real world problems such as diagnosis a medical condition or communicating with
humans in natural language.
o It is also a way which describes how we can represent knowledge in artificial
intelligence. Knowledge representation is not just storing data into some
database, but it also enables an intelligent machine to learn from that knowledge
and experiences so that it can behave intelligently like a human.

Following are the kind of knowledge which needs to be represented in AI systems:

o Object: All the facts about objects in our world domain. E.g., Guitars contains
strings, trumpets are brass instruments.
o Events: Events are the actions which occur in our world.

o Performance: It describe behavior which involves knowledge about how to do


things.
o Meta-knowledge: It is knowledge about what we know.

o Facts: Facts are the truths about the real world and what we represent.

o Knowledge-Base: The central component of the knowledge-based agents is the


knowledge base. It is represented as KB. The Knowledgebase is a group of the

1
Sentences (Here, sentences are used as a technical term and not identical with
the English language).

Types of knowledge
Following are the various types of knowledge:

1. Declarative Knowledge:

o Declarative knowledge is to know about something.

o It includes concepts, facts, and objects.

o It is also called descriptive knowledge and expressed in declarativesentences.

o It is simpler than procedural language.

2. Procedural Knowledge

o It is also known as imperative knowledge.

o Procedural knowledge is a type of knowledge which is responsible for knowing


how to do something.
o It can be directly applied to any task.

o It includes rules, strategies, procedures, agendas, etc.

o Procedural knowledge depends on the task on which it can be applied.

3. Meta-knowledge:

o Knowledge about the other types of knowledge is called Meta-knowledge.

4. Heuristic knowledge:

2
o Heuristic knowledge is representing knowledge of some experts in a filed or
subject.
o Heuristic knowledge is rules of thumb based on previous experiences, awareness
of approaches, and which are good to work but not guaranteed.

5. Structural knowledge:

o Structural knowledge is basic knowledge to problem-solving.

o It describes relationships between various concepts such as kind of, part of, and
grouping of something.
o It describes the relationship that exists between concepts or objects.

The relation between knowledge and


intelligence:
Knowledge of real-worlds plays a vital role in intelligence and same for creating artificial
intelligence. Knowledge plays an important role in demonstrating intelligent behavior in
AI agents. An agent is only able to accurately act on some input when he has some
knowledge or experience about that input.

Let's suppose if you met some person who is speaking in a language which you don't
know, then how you will able to act on that. The same thing applies to the intelligent
behavior of the agents.

As we can see in below diagram, there is one decision maker which act by sensing the
environment and using knowledge. But if the knowledge part will not present then, it
cannot display intelligent behavior.

3
AI knowledge cycle:
An Artificial intelligence system has the following components for displaying intelligent
behavior:

o Perception

o Learning

o Knowledge Representation and Reasoning

o Planning

o Execution

Approaches to knowledge representation:


There are mainly four approaches to knowledge representation, which are givenbelow:

1. Simple relational knowledge:


o It is the simplest way of storing facts which uses the relational method, and each
fact about a set of the object is set out systematically in columns.
o This approach of knowledge representation is famous in database systems where
the relationship between different entities is represented.
o This approach has little opportunity for inference.

4
Example: The following is the simple relational knowledge representation.

2. Inheritable knowledge:
o In the inheritable knowledge approach, all data must be stored into a hierarchy
of classes.
o All classes should be arranged in a generalized form or a hierarchal manner.

o In this approach, we apply inheritance property.

o Elements inherit values from other members of a class.

o This approach contains inheritable knowledge which shows a relation between


instance and class, and it is called instance relation.
o Every individual frame can represent the collection of attributes and its value.

o In this approach, objects and values are represented in Boxed nodes.

o We use Arrows which point from objects to their values.

3. Inferential knowledge:
o Inferential knowledge approach represents knowledge in the form of formal
logics.
o This approach can be used to derive more facts.

5
o It guaranteed correctness.

o Example: Let's suppose there are two statements:

a. Marcus is a man

b. All men are mortal


Then it can represent as;

man(Marcus)
∀x = man (x) ----------> mortal (x)s

4. Procedural knowledge:
o Procedural knowledge approach uses small programs and codes which describes
how to do specific things, and how to proceed.
o In this approach, one important rule is used which is If-Then rule.

o In this knowledge, we can use various coding languages such as LISP


language and Prolog language.
o We can easily represent heuristic or domain-specific knowledge using this
approach.
o But it is not necessary that we can represent all cases in this approach.

Requirements for knowledge Representation


system:
A good knowledge representation system must possess the following properties.

1. 1. Representational Accuracy:
KR system should have the ability to represent all kind of required knowledge.

2. 2. Inferential Adequacy:
KR system should have ability to manipulate the representational structures to
produce new knowledge corresponding to existing structure.

3. 3. Inferential Efficiency:
The ability to direct the inferential knowledge mechanism into the most
productive directions by storing appropriate guides.

6
4. 4. Acquisitional efficiency- The ability to acquire the new knowledge easily
using automatic methods.

knowledge representation using semantic network


Semantic networks are alternative of predicate logic for knowledge representation. In
Semantic networks, we can represent our knowledge in the form of graphical networks.
This network consists of nodes representing objects and arcs which describe the
relationship between those objects. Semantic networks can categorize the object in
different forms and can also link those objects. Semantic networks are easy to
understand and can be easily extended.

This representation consist of mainly two types of relations:

IS-A relation (Inheritance)

Kind-of-relation

Example: Following are some statements which we need to represent in the form of
nodes and arcs.

Statements:
a. Jerry is a cat.
b. Jerry is a mammal
c. Jerry is owned by Priya.
d. Jerry is brown colored.
e. All Mammals are animal.

7
Drawbacks in Semantic representation:
1. Semantic networks take more computational time at runtime as we need to
traverse the complete network tree to answer some questions. It might be
possible in the worst case scenario that after traversing the entire tree, we find
that the solution does not exist in this network.

2. Semantic networks try to model human-like memory (Which has 1015 neurons
and links) to store the information, but in practice, it is not possible to build such
a vast semantic network.

3. These types of representations are inadequate as they do not have any


equivalent quantifier, e.g., for all, for some, none, etc.

4. Semantic networks do not have any standard definition for the link names.

5. These networks are not intelligent and depend on the creator of the system.

Advantages of Semantic network:


1. Semantic networks are a natural representation of knowledge.

2. Semantic networks convey meaning in a transparent manner.

3. These networks are simple and easily understandable.

extended semantic networks for KR


Six Mostly Used Types Of Semantic Networks
Definitional Networks- These networks emphasises and deals with only the subtype or is a
relation between a concept type and a newly defined subtype. A producing network is referred to
as generalization hierarchy. It supports the inheritance rule for duplicating attributes.

Assertion Networks – Designed to assert propositions is intended to state recommendations.


Mostly data in an assertion network is genuine unless it is marked with a modal administrator.

8
Some assertion systems are even considered as the model of the reasonable structures underlying
the characteristic semantic natural languages.

Implicational Networks – Uses Implication as the primary connection for connecting nodes. These
networks are also used to explain patterns of convictions, causality and even deductions.

Executable Network- Contains mechanisms that can cause some changes to the network itself
by incorporating some techniques, for example, such as attached procedures or marker passing
which can perform path messages, or associations and searches for patterns

Learning Networks – These are the networks that build and extend their representations by
acquiring knowledge through examples. Contain mechanisms in such networks brings changes
within the network itself through representation by securing information. A classic example
could be like, the changing of new information from the old system by including and
excluding nodes and arcs, or by changing numerical qualities called weights, and connected with
the arcs and nodes.

9
Hybrid Networks – Networks that combine two or more of previous techniques, either in a
single network or in a separate, but closely interacting network Hybrid network has been clearly
created to implement ideas regarding human cognitive mechanisms, while some are created
generally for computer performance.

Knowledge Representation using Frames


Frames are more structured form of packaging knowledge, - used for representing
objects, concepts etc.
Frames are organized into hierarchies or network of frames.
Lower level frames can inherit information from upper level frames in network.
Nodes are connected using links viz.,
→ subc (links two class frames, one of which is subclass of other e.g.,
science_faculty class is ako of faculty class),
→ is_a (connects a particular instance of a class frame e.g., Renuka is_a
science_faculty)
→ a_part_of (connects two class frames one of which is contained in other
e.g., faculty class is_part_of department class).
→ Property link of semantic net is replaced by SLOT fields.

A frame may have any number of slots needed for describing object. e.g.,
- faculty frame may have name, age, address, qualification etc as slot names.

Each frame includes two basic element : slots and facets.

10
- Each slot may contain one or more facets (called fillers) which may take
many forms such as :
⇒value (value of the slot),
⇒default (default value of the slot),
⇒range (indicates the range of integer or enumerated values, a slot can
have),
⇒demons (procedural attachments such as if_needed, if_deleted,
if_added etc.) and
⇒other (may contain rules, other frames, semantic net or any type of
other information).
Frame Network – Example

Detailed Representation of Frame Network

11
Description of Frames
 Each frame represent either a class or an instance.
 Class frame represents a general concept whereas instance frame
represents a specific occurrence of the class instance.
 Class frame generally have default values which can be redefined
at lower levels.
 If class frame has actual value facet then decedent frames can not
modify that value.
 Value remains unchanged for subclasses and instances.

Inheritance in Frames
 Suppose we want to know nationality or phone of an instance-
frame13.
 These information are not given in this frame.
 Search will start from frame13 in upward direction till we get our
answer or have reached root frame.
 The frame can be easily represented in prolog by choosing
predicate name as frame with two arguments.
 First argument is the name of the frame and second argument is a
list of slot - facet pair.
Features of Frame Representations
 Frames can support values more naturally than semantic nets (e.g.
the value 25)
 Frames can be easily implemented using object-oriented
programming techniques.
 Demons allow for arbitrary functions to be embedded in a
representation.
 But a price is paid in terms of efficiency, generality, and
modularity !
 Inheritance can be easily controlled.
advanced knowledge representation techniques
Logical Representation:

12
Logical representation is a language with some concrete rules which deals with
propositions and has no ambiguity in representation. Logical representation means
drawing a conclusion based on various conditions. This representation lays down some
important communication rules. It consists of precisely defined syntax and semantics
which supports the sound inference. Each sentence can be translated into logics using
syntax and semantics

Syntax:
o Syntaxes are the rules which decide how we can construct legal sentences in the
logic.
o It determines which symbol we can use in knowledge representation.

o How to write those symbols.

Semantics:
o Semantics are the rules by which we can interpret the sentence in the logic.

o Semantic also involves assigning a meaning to each sentence.

Advantages of logical representation:


1. Logical representation enables us to do logical reasoning.

2. Logical representation is the basis for the programming languages.

Disadvantages of logical Representation:


1. Logical representations have some restrictions and are challenging to work with.

2. Logical representation technique may not be very natural, and inference may not
be so efficient.

Production Rules
Production rules system consist of (condition, action) pairs which mean, "If condition
then action". It has mainly three parts:

o The set of production rules

o Working Memory

o The recognize-act-cycle

13
In production rules agent checks for the condition and if the condition exists then
production rule fires and corresponding action is carried out. The condition part of the
rule determines which rule may be applied to a problem. And the action part carries out
the associated problem-solving steps. This complete process is called a recognize-act
cycle.

The working memory contains the description of the current state of problems-solving
and rule can write knowledge to the working memory. This knowledge match and may
fire other rules.

If there is a new situation (state) generates, then multiple production rules will be fired
together, this is called conflict set. In this situation, the agent needs to select a rule
from these sets, and it is called a conflict resolution.

Example:
o IF (at bus stop AND bus arrives) THEN action (get into the bus)

o IF (on the bus AND paid AND empty seat) THEN action (sit down).

o IF (on bus AND unpaid) THEN action (pay charges).

o IF (bus arrives at destination) THEN action (get down from the bus).

Advantages of Production rule:


1. The production rules are expressed in natural language.

2. The production rules are highly modular, so we can easily remove, add or modify
an individual rule.

Disadvantages of Production rule:


1. Production rule system does not exhibit any learning capabilities, as it does not
store the result of the problem for the future uses.

2. During the execution of the program, many rules may be active hence rule-
based production systems are inefficient.

conceptual dependency theory


Conceptual dependency theory is a model of natural language
understanding used in artificial intelligence systems.
Roger Schank at Stanford University introduced the model in 1969, in the early
days of artificial intelligence.[1] This model was extensively used by Schank's

14
students at Yale University such as Robert Wilensky, Wendy Lehnert, and Janet
Kolodner.
Schank developed the model to represent knowledge for natural language input
into computers. Partly influenced by the work of Sydney Lamb, his goal was to
make the meaning independent of the words used in the input, i.e. two sentences
identical in meaning, would have a single representation. The system was also
intended to draw logical inferences.[2]
The model uses the following basic representational tokens:[3]

 real world objects, each with some attributes.


 real world actions, each with attributes
 times
 locations
A set of conceptual transitions then act on this representation, e.g. an ATRANS
is used to represent a transfer such as "give" or "take" while a PTRANS is used
to act on locations such as "move" or "go". An MTRANS represents mental
acts such as "tell", etc.
A sentence such as "John gave a book to Mary" is then represented as the
action of an ATRANS on two real world objects John and Mary.

script structure
Script theory is a psychological theory which posits that human behaviour largely
falls into patterns called "scripts" because they function analogously to the way a
written script does, by providing a program for action. Silvan Tomkins created
script theory as a further development of his affect theory, which regards human
beings' emotional responses to stimuli as falling into categories called "affects": he
noticed that the purely biological response of affect may be followed by awareness
and by what we cognitively do in terms of acting on that affect so that more was
needed to produce a complete explanation of what he called "human being theory".
In script theory, the basic unit of analysis is called a "scene", defined as a sequence
of events linked by the affects triggered during the experience of those events.
Tomkins recognized that our affective experiences fall into patterns that we may
group together according to criteria such as the types of persons and places
involved and the degree of intensity of the effect experienced, the patterns of
which constitute scripts that inform our behavior in an effort to maximize positive
affect and to minimize negative affect.

15
cyc theory
Cyc (pronounced /ˈsaɪk/ SYKE) is a long-term artificial intelligence project that aims to assemble
a comprehensive ontology and knowledge base that spans the basic concepts and rules about how
the world works. Hoping to capture common sense knowledge, Cyc focuses on implicit
knowledge that other AI platforms may take for granted. This is contrasted with facts one might
find somewhere on the internet or retrieve via a search engine or Wikipedia. Cyc
enables semantic reasoners to perform human-like reasoning and be less "brittle" when
confronted with novel situations.

case grammars
Case grammar is a system of linguistic analysis, focusing on the link between the valence, or
number of subjects, objects, etc., of a verb and the grammatical context it requires. The system
was created by the American linguist Charles J. Fillmore in the context of Transformational
Grammar (1968). This theory analyzes the surface syntactic structure of sentences by studying
the combination of deep cases (i.e. semantic roles, such as Agent, Object, Benefactor, Location
or Instrument etc.) which are required by a specific verb. For instance, the verb "give" in English
requires an Agent (A) and Object (O), and a Beneficiary (B); e.g. "Jones (A) gave money (O) to
the school (B).
According to Fillmore, each verb selects a certain number of deep cases which form its case
frame. Thus, a case frame describes important aspects of semantic valency of verbs, adjectives
and nouns. Case frames are subject to certain constraints, such as that a deep case can occur only
once per sentence. Some of the cases are obligatory and others are optional. Obligatory cases
may not be deleted, at the risk of producing ungrammatical sentences. For example, Mary gave
the apples is ungrammatical in this sense.
A fundamental hypothesis of case grammar is that grammatical functions, such
as subject or object, are determined by the deep, semantic valence of the verb, which finds its
syntactic correlate in such grammatical categories as Subject and Object, and in grammatical
cases such as Nominative and Accusative. Fillmore (1968) puts forwards the following hierarchy
for a universal subject selection rule:
Agent < Instrumental < Objective
That means that if the case frame of a verb contains an agent, this one is realized as the subject of
an active sentence; otherwise, the deep case following the agent in the hierarchy (i.e.
Instrumental) is promoted to subject.

semantic web
The Semantic Web leads to smarter, more effortless customer experiences by
giving content the ability to understand and present itself in the most useful forms
matched to a customer’s need. Semantic standards unlock a crucial evolution of the
web towards intelligence that allows the content we post online to be presented in a
way that can be understood, connected, and remixed by machines.

Semantic Web content structures form an essential basis for a reliable graph, or

16
map of knowledge, necessary for true artificial intelligence (AI) beyond basic
Natural Language Processing (NLP) and Natural Language Understanding (NLU).
AI will always remain niche applications built against a limited corpus of content
until structure and semantic standards exist across content sets. Adopting Semantic
Web approaches to content gets publishers closer to globally-machinable sets of
content.

17

You might also like