Expert system

On this page 7

An expert system is a computer program that reproduces the decision-making of a human specialist in a narrow domain by applying an explicit knowledge base of facts and rules through an inference engine. In artificial intelligence, expert systems are the best-known product of symbolic AI: instead of learning patterns from data, they reason over knowledge that engineers elicited from experts and wrote down as logic.

Expert systems dominated applied artificial intelligence from the mid-1970s to the late 1980s, in diagnosis, configuration and credit decisions. Their commercial boom and collapse contributed to the second AI winter, yet their core ideas survive today in business rules engines, clinical decision support and the symbolic half of neuro-symbolic AI.

How an expert system reasons

An expert system reasons by matching rules against known facts and adding the conclusions to its working memory until it reaches an answer. The classic architecture separates what the system knows from how it reasons, so that domain knowledge can be edited without rewriting the reasoning code.

The following table lists the standard components of the architecture and the role each one plays.

ComponentRoleTypical form
Knowledge baseStores domain expertiseIF-THEN rules, frames, ontologies
Working memoryHolds facts about the current caseAssertions such as patient symptoms
Inference engineApplies rules to factsForward or backward chaining
Explanation facilityShows why a conclusion was reachedTrace of fired rules
Knowledge acquisition interfaceLets engineers add and test rulesRule editor, test cases
User interfaceAsks questions and presents adviceDialog or form
Components of a classic expert system

Two control strategies drive the inference engine. Forward chaining is data-driven: it starts from known facts and fires every rule whose conditions hold, which suits configuration and monitoring. Backward chaining is goal-driven: it starts from a hypothesis and works back to the facts that would prove it, asking the user only for missing evidence, which suits diagnosis. Production systems with many rules rely on efficient matching algorithms such as Rete, which avoids re-testing every rule on every cycle.

Real expertise is rarely certain, so many systems attach certainty factors, probabilities or fuzzy logic memberships to rules. MYCIN, the Stanford system for bacterial infection therapy, combined certainty factors on a scale from -1 to +1, an approach later criticized as probabilistically inconsistent and largely replaced by Bayesian networks.

Types of expert systems

Expert systems differ mainly in how knowledge is represented and which inference method they use. The choice follows the structure of the expertise being captured.

VariantKnowledge representationBest suited to
Rule-based systemIF-THEN production rulesClassification, compliance checks
Frame-based systemObjects with slots and inheritanceStructured domains with taxonomies
Case-based reasoningLibrary of solved past casesHelp desks, legal precedent search
Model-based systemCausal or physical model of a deviceFault diagnosis in engineered systems
Probabilistic systemBayesian network with conditional probabilitiesMedical diagnosis under uncertainty
Hybrid systemRules combined with statistical modelsFraud screening, triage
Main variants and where they fit

Most deployed systems were built with an expert system shell, a reusable inference engine and editor without domain content. Shells such as EMYCIN, OPS5 and later CLIPS let knowledge engineers focus on encoding rules rather than on writing search code.

Expert systems compared with machine learning

An expert system encodes knowledge supplied by people, while machine learning induces knowledge from training data. This single difference explains most of their contrasting strengths and weaknesses.

PropertyExpert systemMachine learning model
Source of knowledgeInterviews with domain expertsLabeled or unlabeled examples
TransparencyHigh, every rule is readableOften low, especially for deep learning
Data requirementLittle or no dataLarge, representative datasets
Handling novel inputsFails outside encoded rulesGeneralizes within the data distribution
Maintenance costGrows with rule countGrows with data drift and retraining
AuditabilityStrong, decisions trace to rulesRequires explainability methods
Expert systems and machine learning models side by side

Neither approach dominates. Explainability and auditability keep rule-based logic attractive in regulated decisions, whereas perception tasks such as image or speech recognition proved nearly impossible to capture as hand-written rules, an observation echoed by Moravec’s paradox and the bitter lesson.

Building and choosing an expert system

Building an expert system is mostly knowledge engineering: eliciting, structuring, validating and maintaining expert knowledge. Engineers interview specialists, analyze worked cases, draft rules, and then test the rule base against cases with known correct outcomes.

The decision table below summarizes when a symbolic approach is still the sensible choice today.

SituationRecommended approachReason
Stable, well-documented regulationsRules engineLogic changes rarely and must be auditable
Scarce data, available expertsExpert systemKnowledge can be elicited directly
Abundant data, fuzzy patternsMachine learningRules cannot capture the variation
High-stakes advice needing justificationHybrid systemRules constrain and explain model output
Language-heavy, open-ended tasksFoundation model with guardrailsRules cannot cover open text
When to choose an expert system approach

A practical rule base starts small, often with 50 to 300 rules, and grows only with tested cases. Systems such as XCON, used to configure computer orders, eventually exceeded 10,000 rules, which shows both the scalability of the approach and its maintenance burden.

Limitations and failure modes

The central weakness of expert systems is the knowledge acquisition bottleneck: experts struggle to articulate tacit judgment, and every rule must be elicited, written and verified by hand.

  • Brittleness: performance collapses abruptly at the edge of the encoded domain instead of degrading gracefully.
  • Lack of commonsense reasoning: a system knows only what it was told and cannot notice an absurd input.
  • Rule interaction: in large rule bases, new rules silently conflict with old ones, so regression testing is essential.
  • Maintenance cost: knowledge decays as practice changes, and the original experts may leave.
  • Overstated confidence: certainty factors can look precise while resting on subjective estimates.

These problems, together with expensive specialized hardware, caused many 1980s projects to be abandoned. Modern practice addresses them by keeping rule bases small, versioned and tested, and by combining rules with statistical models where data exists.

A non-technical view

An expert system is like a very detailed rulebook written with the help of a specialist. People ask an experienced doctor, engineer or loan officer how they decide, write down their reasoning as many small if-then steps, and give that rulebook to a computer.

When a new case arrives, the computer checks the facts against the rules, one step after another, until it reaches a recommendation. Because every step is written down, it can explain exactly why it gave its answer. The catch is that it knows only what it was told: if a situation falls outside the rulebook, it cannot improvise the way a human expert can.

A concrete example

A regional insurance company handles about 2,000 small property claims each week. Experienced adjusters agree that most claims follow predictable patterns, so a team of knowledge engineers spends three months interviewing six senior adjusters and encodes their judgment as roughly 240 rules covering policy coverage, damage type, claim amount and fraud signals.

The system uses forward chaining on each new claim. A claim for water damage under 3,000 dollars, on an active policy, with no prior claims in two years, fires a rule chain that recommends automatic approval; a claim filed days after a coverage increase fires a rule that routes it to a human investigator, together with the list of rules that triggered.

After six months, about 60 percent of claims are approved without manual review, and auditors can trace every decision to named rules. Adjusters spend their time on complex cases, and the rule base is reviewed quarterly as policy wording changes.