Knowledge Representation and Reasoning | Chapter 2- Ways of Representing Knowledge

In Chapter 1, we covered the basic things of knowledge representation and reasoning. In this chapter, we will see the different ways in which we represent knowledge.

Techniques of knowledge representation

There are different ways of knowledge representation which are given as follows:

  • Symbols representation

Let see each of them and analyze the ways of representation:-

  1. Symbolic representation:-
  • Imperative language: Very Weak approach. Groups of symbols with values assigned to them. Data structures are used to convey some relationships between the symbols — e.g. classes in OOP

2. Logical representation:- Logical representation is a language with some concrete rules which deal 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:- Syntaxes are the rules which decide how we can construct legal sentences in the logic. It determines which symbol we can use in knowledge representation.

Semantics:- Semantics are the rules by which we can interpret the sentence in the logic. Semantic also involves assigning a meaning to each sentence.

A logical representation can be categorized into mainly two Logics:

  • Propositional Logics

3. Attribute-value representation:- The object-attribute-value triplets (OAV-triplets) method represent knowledge using three tuples : (0, A, V).

0 is the set of objects, which may be physical or conceptual entities.

A represents the set of attributes characterizing the general properties associated with objects.

V (values) specify the nature of the attributes.

Knowledge can be divided into dynamic and static portions. The triplet values are the dynamic portion. These ·values may change, but the static portion (usually facts and rules) remains unchanged for different consultations.

4. Production Rules:- Production rules system consists of (condition, action) pairs which mean, “If condition” and “then action”.

In production rules agent checks for the condition and if the condition exists then production rule applies and the 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.

Example of Production Rule representation of KR.

The working memory contains the description of the current state of problems-solving and rule can write knowledge to the working memory.

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.

5. Semantic networks:- In Semantic networks, we can represent knowledge in the form of graphical networks. It stores the relationships between objects in a graph-like manner. Nodes represent concepts and Edges describe relationships between them.

Semantic network Representation

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.

We will see more details in the last article.

6. Frames representation:- A frame is used to describe an object. It is composed of slots storing information associated with the object. It consists of a collection of slots and slot values. These slots may be of any type and size. Slots have names and values which are called facets.

Facets are features of frames that enable us to put constraints on the frames. A-frame may consist of any number of slots, and a slot may include any number of facets and facets that may have any number of values.

Frames are derived from semantic networks and later evolved into our modern-day classes and objects.

Frames system consists of a collection of frames that are connected. In the frame, knowledge about an object or event can be stored together in the knowledge base.

7. List Representation:- In this similar objects are gathered together in a list. We can envision list operators almost like the operators from set theory: union, intersection, member-of, complement, etc. Also considered a symbolic representation.

List Representation is a powerful and natural representation, we keep lists of things, sort lists, etc.

8. Script Representation:- Scripts are composed of a series of slots that describe, in sequence, the events that we expect to take place in familiar situations. A script is a knowledge representation scheme similar to a frame, but instead of describing an object, the script describes a sequence of events.

Let see the Example, Visiting a restaurant is composed of a series of scenes, for example, an entering scene, a sitting scene, an ordering scene, an eating scene, a bill payment scene, etc. Fig. shows a script for entering the scene.

script for entering the scene

To describe a sequence of events, the script uses a series of slots containing information about the people, objects, and actions that are involved in the events.

Some of the elements of a typical script include entry conditions, props, roles, tracks, and scenes.

  • The entry conditions describe situations that must be satisfied before events in this script can occur or be valid.

Some Other Approaches are Object-Oriented approach. An object is an independent entity represented by some data and a set of operations. Therefore, an object can be used to represent a variety of knowledge. Knowledge (K) can be formally represented by three tuples, K = (C, I, A).

  • C is a set of classes represented by class objects.

There are a lot more in Object-oriented approaches, we will see it in a separate article. That’s all from different ways of knowledge representation.

Now the question is when did you say, Any Knowledge representation technique is a good technique of representation?

  • Good representations make important things explicit.


  • Different ways of representing knowledge.

In the next chapter, we will learn more about one of the knowledge representation techniques and learn to represent it with code.

I hope this has been helpful! If you are looking for any more help, please reach out.

I am a person which is enthusiastic about the work related to machine learning and deep learning. I am also a Kaggle Notebook master.