Integrating Algorithmic Debugging and Unfolding Transformation in an Interactive Learner

Abstract. The algorithm SPECTREspecializes logic programs withrespect topositive and negativeexamples by applying the transforma-tionruleunfolding together withclauseremoval. Themethod IMPUTpresented in this paper gives a modified version of this algorithm byintegrating the algorithmic debugging system IDTS with SPECTRE.The main idea of the IMPUT method is that the identification ofaclause to be unfolded has a crucial importance in the effectivenessof the specialization process. The debugging system IDTS is used toidentify this buggy clause 4. Keywords. Logic and Constraint Programming, Machine Learning 1 Introduction In this paper we present a method for the interactive revision ofmultiple predicates of logic programs. The method (called IMPUT)is based on the interactive debugging technique IDTS introduced in[6] and the specialization algorithm SPECTRE presented in [4]. Themainidea ofIMPUT isthat by combining adebugger withSPECTREan improvement of the specialization process can be achieved.The IDTS system improves Shapiro’s original algorithmic debug-ging method [12] by reducing the number of questions put to theoracle. The validity of results of a procedure call is not asked fromthe oracle if it can be inferred from a Category Partition Test con-figuration [9]. Another improvement in IDTS is that only relevantprogram execution paths that may affect the value of an incorrectoutput are analyzed [10].The problem of specializing a logic program w.r.t positive andnegative examples can be viewed as the problem of pruning an SLD-tree so that all refutations of negative examples and no refutationsof positive examples are excluded. The actual pruning can be per-formed by applying unfolding and clause removal. The algorithmSPECTRE is based on this idea, and it specializes clauses defining atarget predicate by using different strategies for selecting the literal toapply unfolding upon (e.g. the leftmost, randomly, using an impuritymeasure).The main idea of the IMPUT system is that the identification ofa clause to be unfolded has a crucial importance in the effectivenessof the specialization process. If a negative example is covered by thecurrent version of the initial program there is supposedly at least one