VI SEM CSE CS1351 Artificial Intelligence UNIT-III Question and Answers
VI SEM CSE CS1351 Artificial Intelligence UNIT-III Question and Answers
VI SEM CSE CS1351 Artificial Intelligence UNIT-III Question and Answers
VI SEM CSE
CS1351
Artificial Intelligence
RAINING ->
SUNNY
, respectively.
Figure 7.1 shows the outline of a knowledge-based agent program. Like all our agents,
it takes a percept as input and returns an action. The agent maintains a knowledge base, KB,
which may initially contain some background knowledge. Each time the agent program is
called, it does three things. First, it TELLS the knowledge base what it perceives. Second, it
ASKS the knowledge base what action it should perform. In the process of answering this
query, extensive reasoning may be done about the current state of the world, about the
outcomes of possible action sequences, and so on.
stands for a proposition that can be true or false. We will use uppercase names for
symbols: P, Q, R, and so on.
Complex sentences are constructed from simpler sentences using logical connectives.
There are five connectives in common use:
(11)
(12)
The basic syntactic elements of first-order logic are the symbols that stand for
objects,
relations, and functions. The symbols,come in three kinds:
a) constant symbols, which stand for objects;
b) predicate symbols, which stand for relations;
c) and function symbols, which stand for functions.
We adopt the convention that these symbols will begin with uppercase letters.
Example:
Constant symbols :
Richard and John;
predicate symbols :
Brother, OnHead, Person, King, and Crown;
function symbol :
LeftLeg.
(13)
What are quantifiers?
There is need to express properties of entire collections of objects,instead of
enumerating the objects by name. Quantifiers let us do this.
FOL contains two standard quantifiers called
a) Universal () and
b) Existential ()
Universal quantification
(x) P(x) :
means that P holds for all values of x in the domain associated
with that variable
E.g., (x) dolphin(x) => mammal(x)
Existential quantification
( x)P(x) means that P holds for some value of x in the domain associated
with that variable
E.g., ( x) mammal(x) ^ lays-eggs(x)
Permits one to make a statement about some object without naming it
(14)
Explain Universal Quantifiers with an example.
Rules such as "All kings are persons,'' is written in first-order logic as
x King(x) => Person(x)
where is pronounced as For all ..
Thus, the sentence says, "For all x, if x is a king, then z is a person."
The symbol x is called a variable(lower case letters)
The sentence x P,where P is a logical expression says that P is true for every
object x.
(15)
Example-2
Everybody loves somebody means that
for every person,there is someone that person loves
x y Loves(x,y)
(17)
Explain the connection between
and
Everyone likes icecream is equivalent
there is no one who does not like ice cream
This can be expressed as :
x Likes(x,IceCream) is equivalent to
Likes(x,IceCream)
(18)
What are the steps associated with the knowledge Engineering
process?
Discuss them by applying the steps to any real world application of your choice.
Knowledge Engineering
The general process of knowledge base constructiona process is called knowledge
engineering.
A knowledge engineer is someone who investigates a particular domain, learns what
concepts are important in that domain, and creates a formal representation of the objects
and relations in the domain. We will illustrate the knowledge engineering process in an
electronic circuit domain that should already be fairly familiar,
2. Assemble the relevant knowledge. The knowledge engineer might already be an expert
in the domain, ormight need to work with real experts to extract what they know-a
process called knowledge acquisition.
3. Decide on a vocabulary of predicates, functions, and constants. That is, translate the
important domain-level concepts into logic-level names.
Once the choices have been made. the result is a vocabulary that is known as the ontology of
the domain. The word ontology means a particular theory of the nature of being or
existence.
4. Encode general /cnowledge about the domain. The knowledge engineer writes down
the axioms for all the vocabulary terms. This pins down (to the extent possible) the
meaning of the terms, enabling the expert to check the content. Often, this step reveals
misconceptions or gaps in the vocabulary that must be fixed by returning to step 3 and
iterating through the process.
5. Encode a description of the specijic problem insttznce.
For a logical agent, problem instances are supplied by the sensors, whereas a "disembodied"
knowledge base is supplied with additional sentences in the same way that traditional programs
are supplied with input data.
6. Pose queries to the inference procedure and get answers. This is where the reward is:
we can let the inference procedure operate on the axioms and problem-specific facts to
derive the facts we are interested in knowing.
7. Debug the knowledge base.
x NumOfLegs(x,4) => Mammal(x)
Is false for reptiles ,amphibians.
To understand this seven-step process better, we now apply it to an extended example-the
domain of electronic circuits.
(19)
The best way to find usage of First order logic is through examples. The examples can be taken
from some simple domains. In knowledge representation, a domain is just some part of
the world about which we wish to express some knowledge.
ASK(KB, x person(x))
(20)
(21)
Note:
(22)
What is backward chaining ? Explain with an example.
Forward chaining applies a set of rules and facts to deduce whatever conclusions can
be derived.
In backward chaining ,we start from a conclusion,which is the hypothesis we wish
to prove,and we aim to show how that conclusion can be reached from the rules and
facts in the data base.
The conclusion we are aiming to prove is called a goal ,and the reasoning in this way
is known as goal-driven.
Backward chaining example
Fig : Proof tree constructed by backward chaining to prove that West is criminal.
Note:
(a) To prove Criminal(West) ,we have to prove four conjuncts below it.
(b) Some of which are in knowledge base,and others require further backward
chaining.
(23)
Every sentence of first-order logic can be converted into an inferentially equivalent CNF
sentence. In particular, the CNF sentence will be unsatisfiable just when the original sentence
is unsatisfiable, so we have a basis for doing proofs by contradiction on the CNF sentences.
Here we have to eliminate existential quantifiers. We will illustrate the procedure by translating
the sentence "Everyone who loves all animals is loved by someone," or
(24)
Ontology refers to organizing every thing in the world into hierarch of categories.
Representing the abastract concepts such as Actions,Time,Physical Objects,and Beliefs is
called Ontological Engineering.
(25)
How categories are useful in Knowledge representation?
CATEGORIES AND OBJECTS
The organization of objects into categories is a vital part of knowledge representation. Although
interaction with the world takes place at the level of individual objects, much reasoning
takes place at the level of categories.
(26)
What is taxonomy?
(27)
(28)
Explain the Ontology of Situation calculus.
Situations are logical terms consisting of the initial situation (usually called So) and
all situations that are generated by applying an action to a situation. The function
Result(a, s) (sometimes called Do) names the situation that results when action a is
executed in situation s. Figure 10.2 illustrates this idea.
Fluents are functions and predicates that vary from one situation to the next, such as
the location of the agent or the aliveness of the wumpus. The dictionary says a fluent
is something that fllows, like a liquid. In this use, it means flowing or changing across
situations. By convention, the situation is always the last argument of a fluent. For
example, lHoldzng(G1, So) says that the agent is not holding the gold GI in the initial
situation So. Age( Wumpus, So) refers to the wumpus's age in So.
Atemporal or eternal predicates and functions are also allowed. Examples include the
predicate Gold (GI) and the function LeftLeg Of ( Wumpus).
(29)
What is event calculus?
Time and event calculus
Situation calculus works well when there is a single agent performing instantaneous, discrete
actions. When actions have duration and can overlap with each other, situation calculus
becomes somewhat awkward. Therefore, we will cover those topics with an alternative forEVENTCALCULUS malism known as event calculus, which is based on points in time rather than
on situations.
(The terms "event ' and "action" may be used interchangeably. Informally, "event" connotes
a wider class of actions, including ones with no explicit agent. These are easier to handle in
event calculus than in situation calculus.)
In event calculus, fluents hold at points in time rather than at situations, and the calculus
is designed to allow reasoning over intervals of time. The event calculus axiom says that a
fluent is true at a point in time if the fluent was initiated by an event at some time in the past
and was not terminated by an intervening event. The Initiates and Terminates relations
play a role similar to the Result relation in situation calculus; Initiates(e, f , t) means that
the occurrence of event e at time t causes fluent f to become true, while Terminates (w , f, t)
means that f ceases to be true. We use Happens(e, t) to mean that event e happens at time t,
7
(30)
What are semantic networks?
(31)
Semantic networks are capable of representing individual
objects,categories of objects,and relation among objects. Objects or Ctegory
names are represented in ovals and are connected by labeled arcs.
Semantic network example