Page 246 - DCAP310_INTRODUCTION_TO_ARTIFICIAL_INTELLIGENCE_AND_EXPERT_SYSTEMS
P. 246
Introduction to Artificial Intelligence & Expert Systems
Notes Two types of inference methods are commonly used – Backward chaining is the process of
starting with conclusions and working backward to the supporting facts. Forward chaining
starts with the facts and works forward to the conclusions.
13.2.1 Forward Chaining (Data-driven Rule-based Expert Systems)
A rule-based system consists of if-then rules, a bunch of facts, and an interpreter controlling the
application of the rules, given the facts. These if-then rule statements are used to formulate the
conditional statements that comprise the complete knowledge base. A single if-then rule assumes
the form ‘if x is A then y is B’ and the if-part of the rule ‘x is A’ is called the antecedent or premise,
while the then-part of the rule ‘y is B’ is called the consequent or conclusion. There are two broad
kinds of inference engines used in rule-based systems: forward chaining and backward chaining
systems. In a forward chaining system, the initial facts are processed first, and keep using the rules
to draw new conclusions given those facts. In a backward chaining system, the hypothesis (or
solution/goal) we are trying to reach is processed first, and keep looking for rules that would
allow to conclude that hypothesis. As the processing progresses, new subgoals are also set for
validation. Forward chaining systems are primarily data-driven, while backward chaining
systems are goal-driven. Consider an example with the following set of if-then rules
Rule 1: If A and C then Y
Rule 2: If A and X then Z
Rule 3: If B then X
Rule 4: If Z then D
If the task is to prove that D is true, given A and B are true. According to forward chaining, start
with Rule 1 and go on downward till a rule that fires is found. Rule 3 is the only one that fires in
the first iteration. After the first iteration, it can be concluded that A, B, and X are true. The second
iteration uses this valuable information. After the second iteration, Rule 2 fires adding Z is true,
which in turn helps Rule 4 to fire, proving that D is true. Forward chaining strategy is especially
appropriate in situations where data are expensive to collect, but few in quantity. However,
special care is to be taken when these rules are constructed.
13.2.2 Backward Chaining (Goal-driven Rule-based Expert Systems)
A rule-based system consists of if-then rules, a bunch of facts, and an interpreter controlling the
application of the rules, given the facts. These if-then rule statements are used to formulate the
conditional statements that comprise the complete knowledge base. A single if-then rule assumes
the form ‘if x is A then y is B’ and the if-part of the rule ‘x is A’ is called the antecedent or premise,
while the then-part of the rule ‘y is B’ is called the consequent or conclusion. There are two broad
kinds of inference engines used in rule-based systems: forward chaining and backward chaining
systems. In a forward chaining system, the initial facts are processed first, and keep using the
rules to draw new conclusions given those facts. In a backward chaining system, the hypothesis
(or solution/goal) we are trying to reach is processed first, and keep looking for rules that
would allow to conclude that hypothesis. As the processing progresses, new subgoals are also
set for validation. Forward chaining systems are primarily data-driven, while backward chaining
systems are goal-driven. Consider an example with the following set of if-then rules
Rule 1: If A and C then Y
Rule 2: If A and X then Z
Rule 3: If B then X
Rule 4: If Z then D
240 LOVELY PROFESSIONAL UNIVERSITY