The Inference Process
-
Upload
micah-ross -
Category
Documents
-
view
35 -
download
3
description
Transcript of The Inference Process
![Page 1: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/1.jpg)
The Inference ProcessThe Inference Process• Rules• There are two main forms of Inferencing
• Forward Chaining
• Backward Chaining
![Page 2: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/2.jpg)
The Inference ProcessThe Inference Process• Rules• Rules follow an IF…THEN format• English
IF the pump’s temperature is hot
THEN follow maintenance instructions
• Aion DSIFMATCH pump with temperature is “hot”
THEN
send (print maintenance to pump)
END
![Page 3: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/3.jpg)
The Inference ProcessThe Inference Process
– IF– the site of the culture is Blood AND– the identity of the organism is Unknown AND– the strain of the organism is Gramneg AND– the morphology of the organism is Rod AND– the patient has been seriously burned– THEN– there is weakly suggestive evidence (0.4) that the– identity of the organism is Pseudomonas
MYCIN (an expert system to diagnose blood disorders)
![Page 4: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/4.jpg)
The Inference ProcessThe Inference Process• Forward vs. Backward Chaining• Do we drive the inference process based on the
known facts (data) or on the questions (goals) we need answers to?
• Data Driven• Starts with the known data and fires rules to infer
new information (forward chaining)
• Goal Driven• Starts with the goal and tries to match facts to the
solution (backward chaining)
![Page 5: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/5.jpg)
The Inference ProcessThe Inference Process• Forward Chaining1 Enter new data
2 Fire forward chaining rules
3 Rule actions infer new data values
4 Go to step 2
5 repeat until no new data can be inferred
6 If no solution, rule base is insufficient
![Page 6: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/6.jpg)
The Inference ProcessThe Inference Process
Get some new data
1
Fire forward chaining rules Infer new data values
from rule actions
2
3
Add new data values to knowledge base
4
Forward Chaining
![Page 7: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/7.jpg)
The Inference ProcessThe Inference Process• Cascading Rules• Only applicable in forward chaining• Rule executes causing inference of new data• New data is added to the knowledge base• New data added causes other rules to fire
• Can be very time consuming and inefficient in large systems
![Page 8: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/8.jpg)
The Inference ProcessThe Inference Process• Forward Chaining• The data is usually entered “up front”• Is usually done on a form by form basis• Relevant questions must be grouped together• Rules will only fire when all information is
available• The inference engine will not try to find out any
unknown information• All possible questions need to be asked at the
start of a consultation
![Page 9: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/9.jpg)
The Inference ProcessThe Inference Process• Why Forward Chain?Reasons to Forward Chain Examples
You want to know everything that can possibly be concluded about a set of data
Monitoring for mechanical problems on a production line
Scanning a new loan application for problem areas
Many conclusions are possible from a single data item
Filtering sensor data
It is important to communicate new conclusions to the user immediately
Advice to shut down faulty machines
Data entry errors
![Page 10: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/10.jpg)
The Inference ProcessThe Inference Process• Backward Chaining1 State a specific goal (question)
2 Find rules which resolve the goal
3 At runtime, answer questions to satisfy the antecedents of the rules as required
4 Obtain a result (goal resolved or not)
![Page 11: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/11.jpg)
The Inference ProcessThe Inference Process
State primary goal to source
1
Fire backward chaining rules
Primary goal sourced
2
4
Source sub goals
3
Backward Chaining
![Page 12: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/12.jpg)
The Inference ProcessThe Inference Process• Why Backward Chain?Reasons to Backward Chain Examples
There is a clear set of statements which must be confirmed or denied
Which machine is causing the quality control problem?
A large number of questions could be asked of the user, but typically only a few are necessary to resolve a situation
Processing of a motor claim for vandalism; not necessary to know about personal injuries
It is desirable to have interactive dialogue with the user
Asking machine operator detailed questions about suspect machinery
Rule execution depends on data gathering which may be expensive or difficult
Real-time observations by the user
![Page 13: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/13.jpg)
The Inference ProcessThe Inference Process• Backward or Forward Chaining?• Criteria to consider -• The logical reasoning process• Design features of the system• What are the inputs and where do they
come from?• What are the outputs and where do they go?• How do these map to forward or backward
chaining?
![Page 14: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/14.jpg)
The Inference ProcessThe Inference Process• ExamplesUse Forward Chaining Use Backward Chaining
Sensor indicates machine failure; want to find out what happens next
Defect observed in product; want to locate faulty machine
User types erroneous input for insurance claim; want to alert user
Suspect an overpayment; want to check form for erroneous input
Stock value suddenly drops; want to predict market response
FTSE industrials drop; want to know which stocks will be affected
![Page 15: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/15.jpg)
The Inference ProcessThe Inference Process• Chaining in Action• A list of known facts - A, B, D, G, P, Q, R, S.
![Page 16: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/16.jpg)
The Inference ProcessThe Inference Process• Chaining in Action• A list of known facts - A, B, D, G, P, Q, R, S.
Raining outside?
![Page 17: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/17.jpg)
The Inference ProcessThe Inference Process• Chaining in Action• A list of known facts - A, B, D, G, P, Q, R, S.
Cold?
![Page 18: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/18.jpg)
The Inference ProcessThe Inference Process• Chaining in - X is the goal• A list of Rules
1 A + I => X
2 A+B => C
3 C+D => E
4 F+G => H
5 E+H => X
6 A+C => F
7 P+Q => R
8 R+S => T
![Page 19: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/19.jpg)
The Inference ProcessThe Inference Process• Chaining in Action (Backward)• A list of Rules
1 A + I => X
2 A+B => C
3 C+D => E
4 F+G => H
5 E+H => X
6 A+C => F
7 P+Q => R
8 R+S => T
Rule 1 never fired because either “I” was not true or the user did not know it was true
Rules 7+8 never fired because they were not relevant to proving our goal of “X”, though they may have been used if we had another consultation with a different goal
![Page 20: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/20.jpg)
The Inference ProcessThe Inference Process• Chaining in Action (Forward)• A list of known facts - “A, B, D, P, Q, R, S”,
are all true (we asked the user) and “I” is false or not known
![Page 21: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/21.jpg)
The Inference ProcessThe Inference Process• Chaining in Action (Forward)• A list of Rules
1 A + I => X
2 A+B => C
3 C+D => E
4 F+G => H
5 E+H => X
6 A+C => F
7 P+Q => R
8 R+S => T
![Page 22: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/22.jpg)
The Inference ProcessThe Inference Process• Chaining in Action (Forward)• A list of Rules
1 A + I => X
2X A+B => C
3X C+D => E
4 F+G => H
5 E+H => X
6X A+C => F
7X P+Q => R
8X R+S => T
![Page 23: The Inference Process](https://reader030.fdocuments.in/reader030/viewer/2022032612/56812f52550346895d94e3c4/html5/thumbnails/23.jpg)
The Inference ProcessThe Inference Process• Backward or Forward Chaining?• Backward chaining was more focused but only
answered the question asked• Forward chaining found all possible results but
needed more information “up front”• Backward chaining never used rules 7 and 8