=Paper=
{{Paper
|id=Vol-3739/paper-3
|storemode=property
|title=Defeasible Justification for KML-Style Logic
|pdfUrl=https://ceur-ws.org/Vol-3739/paper-3.pdf
|volume=Vol-3739
|authors=Victoria Chama,Steve Wang,Thomas Meyer,Giovanni Casini
|dblpUrl=https://dblp.org/rec/conf/dlog/ChamaWMC24
}}
==Defeasible Justification for KML-Style Logic==
Defeasible Justification for KLM-Style Logic Victoria Chama1,2 , Steve Wang1,2 , Thomas Meyer1,2,3 and Giovanni Casini3,1,2 1 University of Cape Town, South Africa 2 CAIR, South Africa 3 CNR-ISTI, Italy Abstract Research in description logics (DLs) and formal ontologies has dedicated quite an effort to the investigation of the notion of explanation for DL reasoning, for example relying on the notion of justification [1]. There has also been some effort dedicated to the definition of defeasible reasoning for DLs that, contrary to the classical monotonic reasoning, is appropriate for dealing with incomplete/uncertain information. In the present paper, we extend the notion of justification to the framework of defeasible reasoning for DLs; specifically, we consider rational closure [2], an entailment relation that is of particular importance in the area of defeasible reasoning. Here we present the main theoretical results for the DL πβπ, and an implementation of our solution, at the moment developed for propositional logic. Keywords Defeasible entailment, rational closure, justification-based explanations 1. Introduction Knowledge Representation and Reasoning (KRR) is an essential aspect of Artificial Intelligence (AI). Logics such as Propositional Logic (PL) and Description Logic (DL) provide a way to formulate and represent knowledge in a structured manner. Reasoning with such formalised knowledge representations allows us to deduce new information from explicit knowledge. In monotonic (classical) reasoning adding new knowledge cannot cause the retraction of previously drawn deductions. This characteristic of monotonic reasoning is not appropriate for reasoning with rules and generalisations that admit exceptions. Consider the classic βpenguin exampleβ: βpenguins are birdsβ, βpenguins cannot flyβ and βbirds can flyβ. Monotonic reasoning concludes that there are no instances of penguins because birds can both fly and not fly. However, penguins legitimately are birds that cannot fly. Non-monotonic reasoning can overcome such restriction, in particular the approach to non-monotonicity that is known as defeasible reasoning. We use a non-monotonic extension of the DL πβπ to perform defeasible reasoning, for which software tools already exist [3]. Conclusions produced by reasoning tools are often difficult to understand due to the volume and complexity of the statements, and there is a need for algorithms and tools that provide explanations for conclusions. In recent years, research has been done to provide explanations for conclusions in monotonic reasoning [1, 4]. Consequently, various algorithms to compute explanations and implemen- tations of these algorithms for DL are available as plugins in ProtΓ©gΓ© [1]. However, little research has gone into providing explanations for defeasible reasoning systems. Defeasible reasoning introduces well-defined and systematic approaches to reasoning with incomplete information and rules that admit exceptions [5]. Some popular defeasible reasoning systems are based on the semantics developed by Kraus, Lehmann, and Magidor (KLM) [6]. We focus here on rational closure, originally defined for PL [7], but has also been lifted to the case for DLs [2, 8, 9]. In this paper we introduce an algorithm that DL 2024: 37th International Workshop on Description Logics, June 18β21, 2024, Bergen, Norway $ vchama@cs.uct.ac.za (V. Chama); wngshu003@myuct.ac.za (S. Wang); tmeyer@cs.uct.ac.za (T. Meyer); giovanni.casini@isti.cnr.it (G. Casini) Β https://github.com/SteveWang7596 (S. Wang) 0000-0003-3641-4849 (V. Chama); 0000-0002-8741-2213 (S. Wang); 0000-0003-2204-6969 (T. Meyer); 0002-4267-4447 (G. Casini) Β© 2024 Copyright for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0). CEUR ceur-ws.org Workshop ISSN 1613-0073 Proceedings computes explanations for conclusions drawn using rational closure. The logic we use for this algorithm is a KLM extension to DL πβπ. We also present an implementation of the algorithm in PL. The rest of the paper is structured as follows. The next section introduces the necessary preliminaries. In Section 3, we use the concepts provided in Section 2 to construct a defeasible justification algorithm. Then, we present an implementation of the defeasible justification algorithm for the propositional case in Section 4. Lastly, we conclude the paper in Section 5. 2. Preliminaries In this section, we introduce the foundational notions and concepts required to build an algorithm that computes explanations for conclusions produced by reasoning services. After a brief introduction to the DL πβπ, we present the notion of justification defined by Horridge which serves as an explanation for classical reasoning services. Then we introduce the defeasible logic that we are going to use throughout the paper. Lastly, we provide details on the form of defeasible reasoning known as rational closure. 2.1. Description Logic πβπ Description logics (DLs) are a family of logical formalisms that can represent conceptual knowledge in a structured and formally well-understood way. πβπ is a basic formalism of DL and stands for Attributive (Concept) Language with Complements [10]. It includes concept names, concept intersection, concept union, complement, existential and universal qualifiers. This section provides the syntax and semantics of πβπ that will be used in the rest of this paper. Definition 1 (Syntax). The language of πβπ is built from a finite set of atomic concept names, π΄, and a finite set of atomic role names, π . Complex concepts are denoted with πΆ and are built inductively according to the following rule: πΆ ::= β€|β₯|π|Β¬πΆ|πΆ β πΆ|πΆ β πΆ|βπ.πΆ|βπ.πΆ where β€ is the universal concept, β₯ is the bottom concept, Β¬ is the unary negation operation, β is the binary intersection operation, β is the binary union operation, β is the existential qualifier, β is the universal qualifier, π β π΄ and π β π [11]. We use β to denote the language of all πβπ concepts. The semantics of β is given by the notion of interpretation. Definition 2 (Semantics). An interpretation is a structure β = β¨ββ , Β·β β©, where ββ is a non-empty set called the domain, and Β·β is an interpretation function. For every π β πΆ, πβ β ββ , β€β = ββ , β₯β = β and for every π β π , πβ β ββ Γ ββ . For some complex concepts πΆ and π· β β, the interpretation function Β·β extends to interpret all complex concepts of β in the following way: (Β¬πΆ)β = ββ /πΆ β , (πΆ β π·)β = πΆ β β© π·β , (πΆ β π·)β = πΆ β βͺ π·β , (βπ.πΆ)β = {π₯|π¦ β πΆ β for every π¦ s.t (π₯, π¦) β πβ }, (βπ.πΆ)β = {π₯|(π₯, π¦) β πβ for some π¦ β πΆ β } Given πΆ, π· β β, πΆ β π· is called a subsumption statement (or a statement). Concept equivalence, denoted πΆ β‘ π·, is the abbreviation for πΆ β π· and π· β πΆ. An πβπ TBox π― is a finite set of statements. We refer to such statements in π― as axioms. We use πΌ, π½, ... to denote statements in π― . An interpretation β satisfies a statement, πΆ β π·, denoted β β© πΆ β π·, if πΆ β β π·β . An interpretation β is a model of TBox π― if β satisfies every statement in π― . Given a TBox π― and a statement πΌ, π― entails πΌ, denoted π― |= πΌ, if and only if for every interpretation β such that β β© π― , it also holds that β β© πΌ. In this paper, we are not interested in the ABox π which is a finite set of concept assertions (instantiation of concepts) and role assertions (instantiation of roles). 2.2. Justifications Given an entailment, π― |= πΌ, an explanation for π― |= πΌ is a subset of π― such that it entails πΌ. Intuitively, we want to identify the axioms in the π― that contributed towards the entailment. There are several approaches to computing explanations for entailments [1, 12]. In this paper, we base the explanation for entailment on the notion of justification defined by Horridge [1]. Horridge defines justification for an entailment as the minimal subsets of the knowledge base that entails the query. Definition 3 (Justification). Let π― be a TBox and πΌ be a statement. π₯ is a justification for π― |= πΌ if π₯ β π― , π₯ |= πΌ and, for all π₯ β² βπ₯ , it holds that π₯ β² ΜΈ|= πΌ. Example 1. Let us consider the penguin example that we mentioned in the introduction. We can formalise it in a classical TBox, π― , about birds, penguins and a special penguin that has flying capabilities. β§ β« βͺ βͺ Bird β Fly, βͺ βͺ βͺ βͺ βͺ βͺ Bird β Wings, βͺ βͺ βͺ βͺ Penguin β Β¬Fly, βͺ βͺ βͺ βͺ β¨ β¬ π― = SpecialPenguin β Fly, Penguin β Bird, βͺ βͺ βͺ βͺ βͺ βͺ βͺ βͺ SpecialPenguin β Penguin, βͺ βͺ βͺ βͺ βͺ βͺ βͺ βͺ Robin β Bird β© β Such a TBox entails that special penguins fly (π― β¨ SpecialPenguin β Fly). We can identify two justifications for such a conclusion, that is, two minimal subsets of π― that allow the derivation of SpecialPenguin β Fly: π₯1 = {SpecialPenguin β Fly} π₯2 = {SpecialPenguin β Penguin, Penguin β Bird, Bird β Fly} π₯1 is a valid justification because the query, SpecialPenguin β Fly, is an axiom in π― , and π₯2 is also valid according to Definition 3. Horridge presents an implementation for computing justifications in ProtΓ©gΓ© [1, Algorithm 4.1]. In what follows we will refer to it as Algorithm ComputeAllJustifications (Algorithm 4.1), that, given a TBox π― and a statement πΆ β π· entailed by π― , returns all associated justifications. 2.3. Defeasible Reasoning In this section, we discuss how defeasible reasoning has been implemented in DLs. Defeasible logic enables us to reason with rules and generalisations that model typical scenarios that admit exceptions. For example, birds typically fly but penguins are atypical birds that do not fly. There is existing work for extending description logics with defeasible reasoning [2, 3, 8, 9, 13, 14, 15, 16, 17, 18]. As mentioned in the introduction our work is based on the so-called KLM approach to defeasible reasoning [6], and in particular on a specific entailment relation, rational closure [7]. We focus on rational closure since it is a particularly significant entailment relation in defeasible reasoning: other relevant entailment relations are based on it [19, 20, 21], it has already been redefined for description logics [2, 8, 9, 22], moreover it can be implemented just using a relatively simple procedure on top of some classical DL reasoner [3]. We introduce our explanations for defeasible reasoning using a well-known extension of the DL πβπ to model defeasible reasoning [2]. Such an extension allows for an additional type of subsumption statement: βπΆ β βΌ π·β is a defeasible statement which is read βTypically, πΆβs are π·βs, as opposed to βall πΆβs are π·βsβ for the classical subsumptions βπΆ β π·β. Definition 4. (Defeasible Inclusion) For πΆ, π· β β, a defeasible inclusion is a statement of the form πΆ β βΌ π·. A defeasible statement πΆ β βΌ π· can be read as βusually, an instance of the class πΆ is also an instance of the class π·β. A statement like βbirds typically flyβ, formally represented by Bird β βΌ Fly in defeasible πβπ, indicates that if something is a bird then it is reasonable to infer that it flies, if we are not informed of the contrary. β β βΌ β is meant to be the defeasible counterpart of the classical subsumption β [2]. We define a DBox π as a finite set of defeasible statements, and a defeasible knowledge base π¦ = π― βͺ π as consisting of a TBox and DBox. We refer to statements stated in π¦ as axioms. The statements that have a defeasible form are those that can have exceptions to the statements: since most birds fly, but there are exceptions such as penguins and ostriches, we use Bird β βΌ Fly instead of Bird β Fly. Example 2. Consider the following defeasible version of TBox π― shown in Example 1. β§ β« β¨ Penguin β Bird, β¬ π― = Robin β Bird SpecialPenguin β Penguin β© β Bird β β§ β« βͺ βΌ Fly, βͺ Bird β βͺ βͺ Wings, β¨ β¬ π= βΌ βͺ βͺ Penguin β βΌ Β¬Fly βͺ βͺ SpecialPenguin β Fly β© β βΌ 2.3.1. Rational Closure As mentioned, we focus our attention on rational closure, a specific form of defeasible entailment. For the full description, the semantics, and the motivation for the use of rational closure in πβπ, the reader is directed to the work of Britz et al. [2], while here we focus only on the description of the algorithmic procedure to decide rational closure. In essence, given a knowledge base π¦ = π― βͺ π, the algorithm produces a ranking of the defeasible axioms in π, all of which are then converted to classical axioms, from which defeasible entailment (rational closure) can then be computed by a series of classical entailment checks. The ranking of axioms is based on their exceptionality. Intuitively, in case of potential conflicts exceptionality arranges axioms in the knowledge base according to specificity: if we have conflictual information, (e.g., birds fly, penguins are birds, and penguins do not fly), the axioms that are considered less specific than others will be discarded first (e.g., βbirds flyβ is discarded in favour of βpenguins do not flyβ since information about penguins is more specific than information about birds in general). In [2, Sect. 5.2] the procedure Exceptional is aimed at deciding which defeasible axioms are more exceptional w.r.t. a knowledge base. Exceptionality is based on the specificity among classes in case we have a conflict: for example βpenguins usually do not flyβ (Penguin β βΌ Β¬Fly) is more exceptional than βbirds usually flyβ (Bird βΌ Fly), since there is a potential conflict and the antecedent of the former β (Penguin) is a subclass (more specific) than the antecedent of the latter (Bird). We do not provide the procedure Exceptional here, referring the reader to [2, Sect. 5.2]. On top of procedure Exceptional we build Algorithm 1, that takes as input a knowledge base π¦ = π― βͺ π and returns a ranking of the axioms in π according to exceptionality: from rank 0, with β°0 containing all the defeasible axioms in π, to some rank π, with β°π , containing the most exceptional axioms in π. Algorithm 1 is taken from [23, Sect. 5.2]. We again refer the reader to this paper for proper explanations and analysis. Here we present the algorithm and go through an example to give a sense of how the algorithm works. Example 3. For the defeasible knowledge base π¦ from Example 2, ComputeRanking will be executed as follows.1 1. The algorithm takes as input π¦ and creates a hierarchy of defeasible axioms w.r.t their exceptionality. First it considers the entire set π, associating it with β°0 (line 6): 1 Note that the algorithm also introduces a knowledge base π¦* = π― * βͺ π* . π¦* is a reformulation of the input π¦ that is needed for knowledge bases with a particular form, which is not the case for our example. Here the reader can just assume that π¦* = π¦ and, again, we refer to [2] for an explanation. Algorithm 1: ComputeRanking(π¦) Input: π¦ = π― βͺ π Output: π¦* = π― * βͺ π* , an exceptionality sequence β°0 , . . . , β°π and a partitioning π = {π0 , . . . , ππ } for π* * 1 π― βπ― 2 π* β π 3 π ββ 4 repeat 5 πβ0 6 β°0 β π * 7 β°1 β Exceptional(π― * , β°0 ) 8 while β°π+1 ΜΈ= β°π do 9 πβπ+1 10 β°π+1 β Exceptional(π― * , β°π ) 11 πβ* ββ° π 12 π― β π― * βͺ {πΆ β π· | πΆ β * * βΌ π· β πβ } 13 π * β π * β πβ* * 14 until πβ = β 15 for π β 1 to π do 16 ππβ1 β β°πβ1 β β°π 17 π β π βͺ {ππβ1 } 18 β° β (β°0 , ..., β°πβ1 ) 19 return π¦* = π― * βͺ π * , β°, π β°0 = {Bird β β β β βΌ Fly, Bird βΌ Wings, Penguin βΌ Β¬Fly, SpecialPenguin βΌ Fly} 2. Then it applies the algorithm Exceptional to it (line 7). Exceptional identifies all the potential conflicts in π― , that in our case are two: (1) birds fly, but penguins, that are birds, do not; (2) penguins do not fly, but special penguins, that are penguins, do. From such two conflicts, the algorithm Exceptional identifies the most specific pieces of defeasible information that play a role in it: penguins do not fly for (1) and special penguins fly for (2). Such axioms are associated with the first level of exceptionality: β°1 = {Penguin β β βΌ Β¬Fly, SpecialPenguin βΌ Fly}. 3. Now, since β°1 ΜΈ= β°0 , we apply the Exceptional algorithm iteratively until we reach a fixed point (lines 9-12). More in detail, we apply it to π― , β°1 , and Exceptional identifies a potential conflict corresponding to case (2) above: (2) penguins do not fly, but special penguins, that are penguins, do. Again, the algorithm identifies the most specific defeasible axioms playing a role in the potential conflicts (in this case, special penguins fly), and associates them with a new exceptionality level β°2 (line 11): β°2 = {SpecialPenguin β βΌ Fly}. 4. Since β°2 ΜΈ= β°1 (line 9) we again apply the Exceptional algorithm to π― , β°2 , and Exceptional checks that there are no more potential conflicts, and β°3 = β . (line 11). The empty set is trivially a fixed point of our procedure. Now we have the exceptionality sequence {β°0 , β°1 , β°2 }. The algorithm uses this sequence to assign a ranking value to each axiom in π (line 18): all the axioms that are not exceptional go into rank 0: π0 = β°0 β β°1 = Bird β β βΌ Fly, Bird βΌ Wings. The axioms that are exceptional only w.r.t. β°0 go into rank 1 (π1 ), and so on: π1 = β°1 β β°2 = Penguin β βΌ Β¬Fly. π2 = β°2 β β°3 = β°2 = SpecialPenguin β βΌ Fly. Now we move to Algorithm 2, that, given a knowledge base π¦ and a query πΆ β βΌ π·, decides whether π¦ entails πΆ ββΌ π· under rational closure. The original algorithm is in [2, Sect. 5.2], and once again we refer the reader to this publication for proper explanations and analysis. Here we simply go through our guiding example, while pointing out the following about Algorithm 2: β’ The symbol β°π indicates the materialisation of a set of defeasible axioms: given a set π = {πΆ1 ββΌ π·1 , . . . , πΆπ βΌ π·π }, the set π = {Β¬πΆ1 β π·1 , . . . , Β¬πΆπ β π·π } is the set of concepts β expressing the implications that correspond to the defeasible subsumptions. β’ Algorithm 2 is slightly different w.r.t. the Function RationalClosure in [2], since it returns not only the answer to the query, but also a value π that provides the exceptionality ranking of the query. This information is needed for the creation of the justifications (see Section 2.3). Example 4. Consider the rankings obtained in Example 3 with the query SpecialPenguin β βΌ Fly. The rational closure algorithm starts with β°0 (line 2), and checks whether the antecedent in the query is in a conflict w.r.t. β°0 . That is the case since (line 3): l π― |= {Β¬Bird β Fly, Β¬Bird β Wings, Β¬Penguin β Β¬Fly, Β¬SpecialPenguin β Fly} β SpecialPenguin β β₯ The algorithms goes on checking for increasing values of β°π (lines 3-4), until it finds an exceptionality level s.t. SpecialPenguin is not part of any conflict. That is the case fo β°2 , since π― ΜΈ|= (Β¬SpecialPenguin β Fly) β SpecialPenguin β β₯ Now the algorithm associates the information in β°2 with the query, and checks whether the query is implied using materialisation and classical DL reasoning (line 6). That is the case since π― |= (Β¬SpecialPenguin β Fly) β SpecialPenguin β Fly. The algorithm returns true and the value 2 (the exceptionality level associated with the query). Algorithm 2: RationalClosureForJustifications(π¦, πΌ) Input: π¦ = π― βͺ π and a query πΌ = πΆ β βΌ π·. Output: true if πΆ ββΌ π· is in the rat. clos. of π¦, false otherwise; and a rank value i * * * 1 (π¦ = π― βͺ π , β°π πππ’ππππ = (β°0 , . . . , β°π )) β ComputeRanking(π¦) 2 πβ0 3 while π― * |= d β°π β πΆ β β₯ and π β€ π do 4 πβπ+1 5 if π β€ π then return π― * |= β° πβπΆ βπ·,i d 6 7 else 8 return π― * |= πΆ β π·, i 3. Defeasible Justification We now define a procedure that calculates justifications for defeasible entailment: ComputeDefeasibleJustifications. It is obtained by using RationalClosureForJustifications and ComputeAllJustifications* as sub-procedures. ComputeAllJustifications* is a simple modification of ComputeAllJustifications [1, Algorithm 4.1]. We will not present it here. It is sufficient to know that, given π¦ = π― βͺ π and a defeasible inclusion πΆ β βΌ π·, dComputeAllJustifications* (π¦, πΆ β βΌ π·) returns every minimal set π₯ = π― βͺ π s.t. π₯ β π¦ and π― |= π β πΆ β π·. β² β² β² β² The algorithm first determines whether a particular query is in the rational closure of the knowledge base (line 1), and only if it is the case, does it proceed to calculate the justifications (lines 3-15). From RationalClosureForJustifications we know the rank π that is associated to the query (line 6), and we consider only the information in β°π to calculate the justifications using RationalClosureForJustifications (lines 8 or 15, depending on the value of the rank π). Example 5. Consider the defeasible knowledge base π¦ = π― βͺ π from Example 2. In Example 4 we have seen that SpecialPenguin β βΌ Fly is defeasibly entailed by π¦. We see now how Algorithm 3 explains why β SpecialPenguin βΌ Fly is defeasibly entailed by π¦: 1. Line 1 checks whether SpecialPenguin β βΌ Fly is in the rational closure of π¦. From Example 4 we know that it is the case, and the algorithm moves to line 3. 2. We initialise a variable i to 0 (line 4) and a set π₯πππ π’ππ‘ to an empty set (line 5). In line 6 we obtain the value ππππ = 2, since, as we have seen in Example 4, SpecialPenguin is associated to β°2 . Due to that, the If-statement block on lines 7-9 is skipped since ππππ > 0. 3. Once we obtain the ranking π from ComputeRanking (line 11), the while-loop in lines 12-14 removes axioms contained in π0 and π1 . Therefore, we can only use only axioms in π2 and in the TBox π― to compute the justifications. 4. On line 15 we compute all the justifications for the query SpecialPenguin β βΌ Fly w.r.t π― βͺ π2 . The only justification in π₯πππ π’ππ‘ is π₯1 = {SpecialPenguin β βΌ Fly}. Algorithm 3: ComputeDefeasibleJustifications(π¦, π) Input: π¦ = π― βͺ π and a query π = πΆ β βΌ π·. Output: RationalClosureForJustifications(π¦, π); the set of justifications π₯ 1 if RationalClosureForJustifications(π¦, π) = false then 2 return RationalClosureForJustifications(π¦, π) 3 else 4 πβ0 5 π₯πππ π’ππ‘ β β 6 ππππ β value π from RationalClosureForJustifications(π¦, π) 7 if ππππ = 0 then 8 π₯πππ π’ππ‘ β ComputeAllJustifications* (π¦, π) 9 return RationalClosureForJustifications(π¦, π), π₯πππ π’ππ‘ 10 else 11 π = {π0 , . . .} β π from ComputeRanking(π¦) 12 while π < ππππ do 13 π¦πππ€ β π¦πππ€ β ππ 14 πβπ+1 15 π₯πππ π’ππ‘ β ComputeAllJustifications* (π¦πππ€ , π) 16 return RationalClosureForJustifications(π¦, π), π₯πππ π’ππ‘ We return to Example 1 given in Section 2.2. Recall that using the knowledge base in Example 1 there are two justifications that support the query SpecialPenguin β Fly: π₯1 = { SpecialPenguin β Fly } and π₯2 = { SpecialPenguin β Penguin, Penguin β Bird, Bird β Fly }. Once converted the knowledge base to the defeasible formalism (Example 2), the corresponding justification sets are π₯1 = { SpecialPenguin β βΌ Fly } and π₯2 = { SpecialPenguin β Penguin, Penguin β Bird, Bird β βΌ Fly }. However, our algorithm eliminates from the potential justifications all the axioms that have rank lower than 2, hence eliminating Bird β βΌ Fly, that is required for π₯2 . Eventually, only justification π₯1 is eligible. Everett et al. [24] extended the principle of justifications for both Relevant and Lexicographic Closure. 4. Implementation In this section we present an implementation of Algorithm 3, but at the moment just for Propositional Logic (PL)[25]. The original formulation of rational closure was for PL [7], and was developed in the formal framework introduced by Kraus, Lehmann and Magidor (KLM) [6]. They use defeasible conditionals πΌ |βΌ π½, where πΌ and π½ are propositional formulas, and that are read as βif πΌ, usually π½β. A knowledge base in this framework is a finite set of defeasible implications and propositional formulas. Since any propositional formula can be rewritten as a classical implication of the form πΌ β π½ (trivially, πΌ can be rewritten as β€ β πΌ or Β¬πΌ β β₯), a knowledge base in the KLM Framework can be seen as a finite set of classical implications and defeasible implications. The correspondence with our defeasible knowledge base in πβπ, which is a finite set of classical subsumption statements and defeasible subsumption statements, is quite immediate. Example 6. The knowledge base below is the PL version of the knowledge base presented in Example 2. π¦ = {Penguin β Bird, Robin β Bird, SpecialPenguin β Bird, Bird |βΌ Fly, Bird |βΌ Wings, Penguin |βΌ Β¬Fly, SpecialPenguin |βΌ Fly} The notion of defeasible entailment used in the previous sections in this paper fully corresponds to rational closure in the propositional case, as shown by Britz et al. [23]. In other words, rational closure in the propositional case is a simplified version of rational closure in the DL πβπ case. Similarly, the defeasible justification algorithm in the propositional case (Algorithm 4) is a simplified version of Algorithm 3. π¦β and (πΌ |βΌ π½)β are obtained substituting every instance of a defeasible conditional πΌ |βΌ π½ with πΌ β π½. Algorithm 4: ComputePropositionalDefeasibleJustifications(π¦, πΌ |βΌ π½) Input: Defeasible knowledge base π¦ and query πΌ |βΌ π½ Output: the set of justifications π₯ 1 πβ0 2 π₯πππ π’ππ‘ β β 3 ππππ β value π from RationalClosureForJustifications(π¦, πΌ |βΌ π½) 4 if ππππ = 0 then 5 π₯ = ComputeAllJustifications(π¦β , (πΌ |βΌ π½)β ) 6 return π₯ 7 π = {π0 , . . .} β π from ComputeRanking(π¦) 8 while π < ππππ do 9 π¦πππ€ β π¦πππ€ β ππ 10 π=π+1 β , (πΌ |βΌ π½)β ) 11 π₯ = ComputeAllJustifications(π¦πππ€ 12 return π₯ Example 7. If we run the algorithm with the knowledge base π¦ from Example 6 and the query SpecialPenguin |βΌ Fly, we obtain the result that corresponds to the one of Example 5, that is, the only justifi- cation is {SpecialPenguin |βΌ Fly}, while the potential justification {Penguin β Bird, SpecialPenguin β Bird, Bird |βΌ Fly} is not considered since the rank of Bird |βΌ Fly is too low w.r.t. the query. Wang et al. [25] provide more detailed examples of defeasible justification in the propositional case. The software that implements the defeasible justification algorithm for the KLM frame- work is coded in Java. We refer to the software tool as KLMDefeasibleJustificationTool. The KLMDefeasibleJustificationTool follows the Model View Controller (MVC) software architecture pattern and is composed of objects, a graphical user interface (GUI) and algorithm implementations. The GUI is constructed using Java Swing packages. The KLMDefeasibleJustificationTool takes two input parameters: a text file that consists of a KLM-style propositional knowledge base and a query string. The resulting justification(s) and statement rankings are displayed in a text area of the GUI. Two external packages are used to compute the defeasible justification: the Tweety Project [26, 27] and SAT4J SAT solver [28, 29]. The Tweety Project is a software framework that provides models and operations for a number of logics, including PL. Our implementation extends the PL models to construct models and operations required by the KLM Framework. Due to the constraints defined by the Tweety Project, we cannot denote the KLM Framework operations with conventional symbols. Instead, the negation symbol. Β¬ is replaced with ! and the binary operations β§, β¨, β, β and |βΌ are replaced with &&, ||, =>, <=> and βΌ>, respectively. Furthermore, we constructed a parser that reads strings such as βπΌ βΌ> π½β and produces an instance of DefeasibleImplication, which allows the software to perform operations such as materialisation. Classical entailment computation is needed as a sub-procedure to the defeasible justification calculations. The SAT4J SAT solver is used to compute this. The source code of the defeasible justification tool for the KLM Framework can be found on Github [30]. 5. Conclusion The two main contributions of this paper are: (i) a defeasible justification algorithm for the DL πβπ and (ii) an implementation of the defeasible justification algorithm in the propositional case. The obvious next step is to provide an implementation of the defeasible justification algorithm for πβπ as a ProtΓ©gΓ© plugin. Further future work includes the definition and implementation of defeasible justification algorithms for other logics equipped with KLM-style defeasibility. One such logic is the restricted version of first-order logic with KLM-style defeasibility presented by Casini et al. [31]. Finally, here we have focused on a procedural definition of defeasible justification in the form of Algorithm 3. An investigation into a declarative definition of defeasible justification is left as future work. Acknowledgments This work has been partially supported by the H2020 STARWARS Project (GA No. 101086252), a type of action HORIZON TMA MSCA Staff Exchanges. References [1] M. Horridge, Justification based explanation in ontologies, PhD Thesis, University of Manchester, 2011. [2] K. Britz, G. Casini, T. Meyer, K. Moodley, U. Sattler, I. Varzinczak, Principles of KLM-style Defeasible Description Logics, ACM Transactions on Computational Logic (TOCL) 22 (2020) 1 β 46. doi:10.1145/3420258. [3] G. Casini, T. Meyer, K. Moodley, U. Sattler, I. Varzinczak, Introducing defeasibility into OWL ontologies, in: International Semantic Web Conference, Springer, 2015, pp. 409β426. [4] S. P. Bail, The justificatory structure of OWL ontologies, PhD Thesis, University of Manchester, 2013. [5] J. L. Pollock, A theory of defeasible reasoning, International Journal of Intelligent Systems 6 (1991) 33β54. [6] S. Kraus, D. Lehmann, M. Magidor, Nonmonotonic reasoning, preferential models and cumulative logics, Artificial intelligence 44 (1990) 167β207. [7] D. Lehmann, M. Magidor, What does a conditional knowledge base entail?, Artificial Intelligence 55 (1992) 1β60. [8] L. Giordano, V. Gliozzi, N. Olivetti, G. L. Pozzato, Semantic characterization of rational closure: From propositional logic to description logics, Artificial Intelligence 226 (2015) 1β33. URL: https: //doi.org/10.1016/j.artint.2015.05.001. doi:10.1016/J.ARTINT.2015.05.001. [9] P. A. Bonatti, Rational closure for all description logics, Artificial Intelligence 274 (2019) 197β223. URL: https://doi.org/10.1016/j.artint.2019.04.001. doi:10.1016/J.ARTINT.2019.04.001. [10] M. Schmidt-SchauΓ, G. Smolka, Attributive concept descriptions with complements, Artificial intelligence 48 (1991) 1β26. [11] F. Baader, D. Calvanese, D. McGuinness, P. Patel-Schneider, D. Nardi, The Description Logic Handbook: Theory, Implementation and Applications, 2 ed., Cambridge university press, 2007. [12] F. Baader, R. Penaloza, Axiom pinpointing in general tableaux, Journal of Logic and Computation 20 (2010) 5β34. [13] K. Moodley, T. Meyer, I. J. Varzinczak, A defeasible reasoning approach for description logic ontologies, in: Proceedings of the South African Institute for Computer Scientists and Information Technologists Conference, ACM, 2012, pp. 69β78. [14] L. Botha, T. Meyer, R. PeΜnaloza, The Probabilistic Description Logic β¬πβπ, Theory and Practice of Logic Programming (2020). doi:10.1017/s1471068420000460. [15] P. Ke, U. Sattler, Next Steps for Description Logics of Minimal Knowledge and Negation as Failure, Description Logics 353 (2008). [16] L. Giordano, V. Gliozzi, A reconstruction of multipreference closure, Artificial Intelligence 290 (2021) 103398. URL: https://doi.org/10.1016/j.artint.2020.103398. doi:10.1016/J.ARTINT.2020. 103398. [17] P. A. Bonatti, C. Lutz, F. Wolter, Description Logics with Circumscription., in: KR, 2006, pp. 400β410. [18] P. A. Bonatti, M. Faella, I. M. Petrova, L. Sauro, A new semantics for overriding in description logics, Artificial Intelligence 222 (2015) 1β48. URL: https://doi.org/10.1016/j.artint.2014.12.010. doi:10.1016/J.ARTINT.2014.12.010. [19] D. Lehmann, Another Perspective on Default Reasoning, Annals of Mathetics and Artificial Intel- ligence 15 (1995) 61β82. URL: https://doi.org/10.1007/BF01535841. doi:10.1007/BF01535841. [20] G. Casini, U. Straccia, Defeasible Inheritance-Based Description Logics, J. Artificial Intelligence Res. 48 (2013) 415β473. URL: https://doi.org/10.1613/jair.4062. doi:10.1613/JAIR.4062. [21] G. Casini, T. Meyer, I. Varzinczak, Taking Defeasible Entailment Beyond Rational Closure, in: F. Calimeri, N. Leone, M. Manna (Eds.), Logics in Artificial Intelligence - 16th European Conference, JELIA 2019, Rende, Italy, May 7-11, 2019, Proceedings, volume 11468 of Lecture Notes in Computer Science, Springer, 2019, pp. 182β197. URL: https://doi.org/10.1007/978-3-030-19570-0_12. doi:10. 1007/978-3-030-19570-0\_12. [22] G. Casini, U. Straccia, Rational closure for defeasible description logics, in: European Workshop on Logics in Artificial Intelligence, Springer, 2010, pp. 77β90. [23] K. Britz, G. Casini, T. Meyer, I. Varzinczak, A KLM Perspective on Defeasible Reasoning for Description Logics, in: Description Logic, Theory Combination, and All That, Springer, 2019, pp. 147β173. [24] L. Everett, E. Morris, T. Meyer, Explanation for klm-style defeasible reasoning, in: Southern African Conference for Artificial Intelligence Research, Springer, 2021, pp. 192β207. [25] S. Wang, T. Meyer, D. Moodley, Defeasible Justification Using the KLM Framework, in: Southern African Conference for Artificial Intelligence Research, Springer, 2022, pp. 187β201. [26] M. Thimm, Tweety - A Comprehensive Collection of Java Libraries for Logical Aspects of Artificial Intelligence and Knowledge Representation, in: Proceedings of the 14th International Conference on Principles of Knowledge Representation and Reasoning (KRβ14), 2014, pp. 528β537. [27] M. Thimm, The Tweety Project, Available online, 2014. URL: https://tweetyproject.org/. [28] N. EΓ©n, N. SΓΆrensson, An extensible SAT-solver, in: International conference on theory and applications of satisfiability testing, Springer, 2003, pp. 502β518. [29] N. EΓ©n, N. SΓΆrensson, SAT4J SAT Solver, 2003. URL: https://www.sat4j.org/index.php. [30] S. Wang, GitHub - KLM Defeasible Justification Tool, Available online, 2023. URL: https://github. com/SteveWang7596/DefeasibleJustificationForPropositionalLogic. [31] G. Casini, T. Meyer, G. Paterson-Jones, I. Varzinczak, KLM-Style Defeasibility for Restricted First-Order Logic, in: International Joint Conference on Rules and Reasoning, Springer, 2022, pp. 81β94.