The **autoepistemic logic** is a formal logic for the representation and reasoning of knowledge about knowledge. While propositional logic can only express facts, autoepistemic logic can express knowledge and lack of knowledge about facts.

The stable model semantics, which is used to give a semantics to logic programming with negation as failure, can be seen as a simplified form of autoepistemic logic.

The syntax of autoepistemic logic extends that of propositional logic by a modal operator ^{[1]} indicating knowledge: if is a formula, indicates that is known. As a result, indicates that is known and indicates that is not known.

This syntax is used for allowing reasoning based on knowledge of facts. For example, means that is assumed false if it is not known to be true. This is a form of negation as failure.

The semantics of autoepistemic logic is based on the *expansions* of a theory, which have a role similar to models in propositional logic. While a propositional model specifies which atomic propositions are true or false, an expansion specifies which formulae are true and which ones are false. In particular, the expansions of an autoepistemic formula make this determination for every subformula contained in . This determination allows to be treated as a propositional formula, as all its subformulae containing are either true or false. In particular, checking whether entails in this condition can be done using the rules of the propositional calculus. In order for a specification to be an expansion, it must be that a subformula is entailed if and only if has been assigned the value true.

In terms of possible world semantics, an expansion of consists of an **S5** model of in which the possible worlds consist only of worlds where is true. [The possible worlds need not contain all such consistent worlds; this corresponds to the fact that modal propositions are assigned truth values before checking derivability of the ordinary propositions.] Thus, autoepistemic logic extends **S5**; the extension is proper, since and are tautologies of autoepistemic logic, but not of **S5**.

For example, in the formula , there is only a single “boxed subformula”, which is . Therefore, there are only two candidate expansions, assuming is true or false, respectively. The check for them being actual expansions is as follows.

is false : with this assumption, becomes tautological, as is equivalent to , and is assumed true; therefore, is not entailed. This result confirms the assumption implicit in being false, that is, that is not currently known. Therefore, the assumption that is false is an expansion.

is true : together with this assumption, entails ; therefore, the initial assumption that is implicit in being true, i.e., that is known to be true, is satisfied. As a result, this is another expansion.

The formula has therefore two expansions, one in which is not known and one in which is known. The second one has been regarded as unintuitive, as the initial assumption that is true is the only reason why is true, which confirms the assumption. In other words, this is a self-supporting assumption. A logic allowing such a self-support of beliefs is called *not strongly grounded* to differentiate them from *strongly grounded* logics, in which self-support is not possible. Strongly grounded variants of autoepistemic logic exist.

In uncertain inference, the known/unknown duality of truth values is replaced by a degree of certainty of a fact or deduction; certainty may vary from 0 (completely uncertain/unknown) to 1 (certain/known). In probabilistic logic networks, truth values are also given a probabilistic interpretation (*i.e.* truth values may be uncertain, and, even if almost certain, they may still be "probably" true (or false).)