Diagnosis of a malfunctioning physical system is the task of identifyi
ng those component parts whose failures are responsible for discrepanc
ies between observed and correct system behavior. The result of diagno
sis is to enable system repair by replacement of failed parts. The mod
el-based approach to diagnosis has emerged as a strong alternative to
both symptom-based and fault-model-based approaches. Hypothesis genera
tion and hypothesis discrimination (action selection) are two major su
btasks of model-based diagnosis. Hypothesis generation has been partia
lly resolved by symbolic reasoning using a subjective notion of parsim
ony such as non-redundancy. Action selection has only been studied for
special cases, e.g. probes with equal cost. Little formal work has be
en done on repair selection and verification.This paper presents a pro
babilistic theory for model-based diagnosis. An objective measure is u
sed to rank hypotheses, viz., posterior probabilities, instead of subj
ective parsimony. Fault hypotheses are generated in decreasing probabi
lity order. The theory provides an estimate of the expected diagnosis
cost of an action. The result of the minimal cost action is used to ad
just hypothesis probabilities and to select further actions. The major
contributions of this paper are the incorporation of probabilistic re
asoning into model-based diagnosis and the integration of repair as pa
rt of diagnosis. The integration of diagnosis and repair makes it poss
ible to troubleshoot failures effectively in complex systems.