Rule-based Systems also called Knowledge-based Systems or Expert Systems are important instances of machine learning and the artificial intelligence (AI) industry representing knowledge as facts and rules that are ‘true’.
Any Rule-based system generally contains a knowlegde base, an inferential engine and a user interface.
The knowledge base holds the ‘domain knowledge’ which is typically very specialized for a particular problem and normally provided by human experts. The system encodes a list of rules that determine what is “true” and what action needs to be initiated depending on the situation – often encoded as “if-then” rules.
Each rule has two parts:
- The Condition defines what is ‘true’ for the rule to activate an action.
- The Action defines what response is initiated when the condition is met.
A ‘conflict set’ defines all the rules that are presently matched and the system has to decide which rule within the ‘conflict set’ will activate a specific action.
A problem like this can be solved using forward chaining which is a data-driven comparison of working memory with current conditions of rules determining which rule applies (‘fire’). Forward chaining is used, for example, to diagnose an underlying disease based on a set of symptoms that are defined within the working memory/domain knowledge. A classic rule-based expert system in medicine that fits this rule-based behavior is the ‘Mycin system’ which was developed in the 1970s in Stanford to analyze blood infections. The Mycin “knowledge base” consisted of a set of “if-then” rules giving suggestive evidence for the kind of infection.
In other situations, specified goals are defined that are solved by goal-driven backward chaining systems. The system looks for the rules that are defined via a ‘then’ clause until either the available data fulfills the goals or until there are no more matching rules. In medicine and epidemiology, backward chaining can be used if it is presumed that the individual suffers from a disease so the system can attempt to determine if this diagnosis is correct. An example is “Internist”, which is a system for general disease diagnosis, with a knowledge base of disease profiles, symptoms that are associated with the disease and the strength of association. The system uses the initial symptoms to suggest possible diseases but also gives information of what other symptoms would be expected, given these diseases.
As the system obtains more knowledge there are fewer errors.