AI & ML Atlas
Artificial IntelligencealgorithmInteractive simulation
Rule-Based Inference
Applies IF-THEN rules to known facts to derive new ones.
The idea
Knowledge is written as rules ("IF fever AND cough THEN flu-suspected"). An inference engine matches rules against working memory, picks one that fires, and adds its conclusion. This repeats until nothing new can be added or a goal is reached.
Watch it run
This is a real computation, not a drawing. Pause, step, change the settings, or try new random data.
- known / proved
- active rule or sub-goal
- unknown
Start from the known facts (green): A, B, E. Rules are the squares: all inputs on the left must be known to fire.
1/12
Circles are statements, squares are IF-THEN rules. A rule links its inputs to its conclusion.
Step by step
- 1Load facts into working memory.
- 2Find all rules whose conditions are satisfied.
- 3Choose one (conflict resolution) and add its conclusion.
- 4Repeat until no new facts appear.
Where it is used
Business rules, diagnosis assistants, configuration.
Watch out for
Large rule sets interact in surprising ways and become hard to maintain.