Truth maintenance system

Also known as: TMS · reason maintenance system

On this page 7

A truth maintenance system (TMS), also called a reason maintenance system, is a component of a reasoning program that records the justifications for every derived belief and automatically revises the set of current beliefs when assumptions are added or withdrawn. Within the field of Symbolic AI & reasoning, part of classical artificial intelligence, it separates two jobs: a problem solver draws inferences, while the TMS keeps track of why each conclusion holds and whether it still holds.

The idea was introduced by Jon Doyle in 1979 and generalized by Johan de Kleer in 1986 with the assumption-based variant. Truth maintenance remains the standard answer to a practical question in non-monotonic reasoning: how can a system change its mind efficiently without recomputing everything from scratch?

How a truth maintenance system tracks dependencies

A truth maintenance system works by storing a dependency network in which each node is a proposition and each justification links a conclusion to the beliefs that support it. When the problem solver derives a fact, it hands the TMS both the fact and the reason, so the system knows exactly which premises would bring the conclusion down.

Each node receives a label that states its current status. In the classic design, a node is IN when at least one of its justifications is valid and OUT otherwise. Premises are always IN, assumptions are IN until retracted, and derived nodes inherit their status from their supporters. When an assumption changes, the TMS propagates the change through the network and relabels only the affected nodes, a process known as incremental belief revision.

The following table lists the core elements of the dependency network and the role each one plays.

ElementWhat it representsRole in maintenance
NodeA proposition or datumCarries the current belief status
JustificationA reason linking supporters to a conclusionExplains why a node is believed
PremiseA fact that is always trueNever retracted by the TMS
AssumptionA belief adopted tentativelyCan be withdrawn to restore consistency
Contradiction nodeA marker for an inconsistent stateTriggers dependency-directed backtracking
Core elements of a dependency network

When a contradiction node becomes IN, the TMS traces the justifications backward to find the set of assumptions responsible and retracts one of them. This technique, called dependency-directed backtracking, avoids the blind chronological backtracking that wastes effort revisiting choices unrelated to the conflict.

Main variants of truth maintenance

Truth maintenance systems differ mainly in how they represent justifications and how many contexts they hold at once. Four families appear in the literature and in practical reasoning engines.

VariantJustification formContexts heldTypical strength
Justification-based TMS (JTMS)Horn-clause style IN listsOne current contextSimple and fast for single-scenario reasoning
Non-monotonic JTMS (Doyle)IN lists plus OUT listsOne current contextSupports default assumptions
Assumption-based TMS (ATMS)Labels as sets of assumption environmentsMany contexts in parallelComparing alternative hypotheses
Logic-based TMS (LTMS)Arbitrary propositional clausesOne current contextRicher inference through clause propagation
Families of truth maintenance systems

The ATMS deserves particular attention because it changes the computational model. Instead of maintaining one belief state, it labels every node with the minimal environments, that is the minimal sets of assumptions, under which the node holds. Inconsistent environments are recorded as nogoods and removed from every label. Switching between hypotheses then costs almost nothing, although the labels themselves can grow exponentially in the worst case.

Doyle’s original design introduced OUT lists, which let a justification say that a conclusion holds as long as some other belief is not held. This is the mechanism that encodes default reasoning, such as assuming a valve is open unless evidence says otherwise.

How truth maintenance relates to neighboring concepts

A truth maintenance system is not a reasoner on its own; it is bookkeeping infrastructure that works alongside other components of symbolic AI. Comparing it with related ideas clarifies its scope.

ConceptMain purposeRelationship to a TMS
Forward chainingDerive new facts from rulesSupplies justifications to the TMS
Rete algorithmMatch rules efficiently against factsOptimizes matching, not belief revision
Non-monotonic reasoningAllow conclusions to be withdrawnThe TMS is a practical implementation tool
Boolean satisfiability solversFind consistent truth assignmentsClause learning resembles nogood recording
Blackboard systemCoordinate independent knowledge sourcesOften uses a TMS to keep shared data consistent
Truth maintenance compared with related techniques

The parallel with modern SAT solvers is instructive. Conflict-driven clause learning records the reasons behind a conflict and avoids repeating it, which is essentially the nogood mechanism of an ATMS applied to search. Similarly, production systems built on forward chaining can feed their rule firings to a TMS so that retracting a fact also retracts every conclusion derived from it, a feature some rule engines call logical insertion.

Where truth maintenance is applied

Truth maintenance is applied wherever a system must reason under changing assumptions and explain its conclusions. The strongest use cases share a need for both efficient revision and traceable explanations.

  • Model-based diagnosis, where the General Diagnostic Engine uses an ATMS to identify minimal sets of faulty components.
  • Qualitative physics and engineering design, where alternative operating modes must be compared side by side.
  • Planning and scheduling, where a changed constraint should invalidate only the dependent parts of a plan.
  • Expert system shells and rule engines, where justified facts disappear automatically when their premises are removed.
  • Explanation generation, where the stored justifications answer the question of why a conclusion was reached.

Choosing a variant depends on the shape of the problem. A single evolving scenario suits a JTMS, while a task that weighs many competing hypotheses, such as fault diagnosis, benefits from the multi-context ATMS despite its memory cost.

Limitations and common pitfalls

Truth maintenance systems carry real costs that practitioners must manage. The table below summarizes the most frequent problems and how experienced designers address them.

ProblemCauseCommon remedy
Label explosionToo many assumption combinations in an ATMSFocus the ATMS on a few environments
Memory growthEvery justification is stored permanentlyGarbage-collect unsupported nodes
Odd loopsCircular non-monotonic justificationsRestrict or detect unstable dependency cycles
Poor retraction choiceSeveral assumptions explain one contradictionUse preferences or priorities among assumptions
Weak inferenceJTMS sees justifications only as linksPair it with an LTMS or a stronger solver
Typical problems and remedies

A common misconception is that a TMS guarantees logical consistency of the whole knowledge base. In fact, it only maintains consistency relative to the justifications it receives; if the problem solver omits a reason, the TMS cannot retract the right belief. Another frequent mistake is to expect it to perform deduction, when its actual task is bookkeeping and propagation.

The simple explanation

A truth maintenance system is like a careful notebook. Each time a program reaches a conclusion, it writes down the conclusion and the reasons for it. Later, one of those reasons may turn out to be wrong.

Then the notebook does the cleanup. It crosses out every conclusion that depended on the wrong reason. Everything else stays in place. The program does not have to start over. It can also show you exactly why it believes something.

How it is used in practice

Consider a diagnostic tool for an industrial cooling loop with 12 sensors and 8 components. The tool assumes each pump, valve and heat exchanger works correctly. From these assumptions and the sensor readings, a rule engine predicts flow rates and temperatures, and every prediction is recorded in an assumption-based TMS together with the assumptions it relies on.

When a temperature sensor reports 18 degrees Celsius where the model predicts 12, the mismatch becomes a contradiction. The ATMS records the responsible assumption sets as nogoods and returns the minimal candidate faults, for example either the second pump or the bypass valve. The engineer tests the valve first, finds it stuck half open, and the tool retracts only the beliefs tied to that valve. The diagnosis takes minutes instead of a full manual inspection of the loop.