General architecture of the rule-based system as an expert system