Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Forward Chaining vs Backward Chaining

What is one good for that the other's not in practice? I understand the theory of what they do, but what are their limitations and capabilities in practical use? I'm considering Drools vs a java prolog for a new AI project, but open to other suggestions. What are some popular approaches for inferencing on a complicated relational data set or alternatives?

like image 343
gtrak Avatar asked Jul 29 '10 15:07

gtrak


People also ask

What is an example of forward chaining?

Using Forward Chaining With Task Analysis An example that is often cited is brushing their teeth. The child may learn each step of taking the toothpaste out of the cabinet, putting it on a wet toothbrush, and scrubbing for a certain amount of time.

What is an example of backward chaining?

Use backward chaining (i.e., breaking a skill down into smaller steps, then teaching and reinforcing the last step in the sequence first, then the second to the last step, and so on). For example, have the child wash his/her hands in the sink near the toilet.

What are the 3 types of chaining?

There are three different types of chaining which can be used and they are forward chaining, backward chaining, and total task chaining (not to be confused with a task analysis).


2 Answers

Backward chaining (a la Prolog) is more like finding what initial conditions form a path to your goal. At a very basic level it is a backward search from your goal to find conditions that will fulfil it.

Backward chaining is used for interrogative applications (finding items that fulfil certain criteria) - one commercial example of a backward chaining application might be finding which insurance policies are covered by a particular reinsurance contract.

Forward chaining (a la CLIPS) matches conditions and then generates inferences from those conditions. These conditions can in turn match other rules. Basically, this takes a set of initial conditions and then draws all inferences it can from those conditions.

The inferences (if asserted) can also be actions or events that can trigger external actions. This is useful in event driven systems, as the rule sets can be configured to (for example) initiate a workflow or some other action. This type of rule engine is the most commonly used in commercial applications.

Event driven systems are a common application of forward chaining rule engines. One example of a forward chaining application might be a telecoms plan provisioning engine (typically used for administering mobile phone plans). Entering a particular user with a particular plan will trigger a range of items to be set up in various phone switches, billing systems, financials, CRM systems etc.

like image 114
ConcernedOfTunbridgeWells Avatar answered Oct 03 '22 04:10

ConcernedOfTunbridgeWells


Concerned's answer is very good. When asked to boil the difference down to a sound bite, I usually say something like:

Lots of Output Hypotheses + Lots of Data Up Front => Use Forward Chaining

Fewer Output Hypotheses + Must Query for Data => Use Backward Chaining

But it's just a rule of thumb, not a commandment.

like image 42
TechNeilogy Avatar answered Oct 03 '22 05:10

TechNeilogy