Professional Documents
Culture Documents
About Knowledge
• 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.
• 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.
• 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.
Environment
Agent
Then If temp is above 100 cel
trigger Humidity
alarm Carbon monoxide in air
Carbon dioxide
Domain
Expert Knowledge Knowledge
Engineer Base
Doc
Specialist Anmol System
Artificial
Senses Intelligent Knowledge
System
Action
KNOWLEDGE CYCLE IN ARTIFICIAL
INTELLIGENCE
• Perception
• Learning
• Knowledge Representation and Reasoning
• Planning
• Execution
Learning
Perception
Knowledge Planning
Representation
Execution
Types of Knowledge Representation
• Logics
Types of Logics
• Propositional Logic
• Predicate Logic
Logics
• Whether the given statement is true or false
5+3 = 9 (False)
Sun rises in the east. (True)
Knowledge Representation
• I is going to school. (Wrong)
• I are going to school. (Wrong)
• I am going to school. ( Correct Knowledge)
True False
Knowledge Representation
• I went to Bus by Delhi. (Logically Incorrect)
• I went to Delhi by Bus. (Logically Correct)
True False
Syntax vs. Semantic
I is going to school. I went to Bus by Delhi.
I are going to school.
Grammatically Correct
Grammatically Incorrect
But Logically Incorrect
Logically Correct
Semantic Error
Syntax Error
Structure of a Sentence
• <Sentence> <Subject><Predicate>
• <Subject> <Noun><Noun-Phrase>
• <Predicate> <Verb><Noun-Phrase>
• < Noun-Phrase > <Adjective><Noun>
• <Adjectives> Smart | Shy | Intelligent
• <Articles> A | An | The
Machine Processing
• <Sentence> <Subject><Predicate>
• <Noun> Ram | Sham | Mohan | The Boy
• <Adjective> Intelligent | shy | dull
• <Article> A | An | The
Sentence Processing
<Sentence> <Subject><Predicate>
< Noun-Phrase> <Predicate>
<Article><Noun><Predicate>
The <Noun> <Predicate>
The boy <Predicate>
The boy <Verb><adjective>
The boy is very <adjective>
The boy is very intelligent
Proposition
A proposition is any given statement. This can be ether true
or false, but can`t be partially true or partially false.
• If value of x is 5
• And value of y is 4
• Then the value of z will be 9
x Y Z=9
3 5 False
5 4 True
2 5 False
5 3 False
2 4 False
Example 2
• If there are no clouds today and the
temperature is above 24 degree C. Then it will
be sunny tomorrow.
UV radiation Survival
Yes (T) Not Possible (F)
NO (F) Possible (T)
Yes (T) Not Possible (F)
ADVANTAGES OF USING LOGIC?
• Logic is the basics of programming.
• It helps us in reasoning.
DISADVANTAGES?
• Logics have certain restrictions and it
challenging to work with.
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.
Is-A
B.Tech GNA
7
Big
Data GNA
Example Mouse
Cat
• Tom is a cat
Is-A
• Tom is mammal
Is-A
• Tom is owned by Jerry
• Tom is brown in color TOM Mammal
• All mammals are animals
Is-Owned
Is-A
Is-Color
Jerry
Animals
Brown
Semantic Network vs Logic
LOGIC
Tom is a cat and cat is mammal
and tom has two eyes.
A V ~A
A B A ꓵ B
T F F
F T F
F F F
T T T
Disjunction
A disjunction is true when at-least one value in
the formula is true.
A B A ꓵ B
T F T
F T T
F F F
T T T
Resolution
• Clause :: {C}, {D}, {B,~D},{A,~B,~C}
• Prove :: {A} True
• ~ ( ~A )
Clause :: {C}, {D}, {B,~D},{A,~B,~C}
~A
A,~B,~C
~B,~C
B,~D
~C,~D
C
~D
D
NULL