23.02.2015 Views

Machine Learning - DISCo

Machine Learning - DISCo

Machine Learning - DISCo

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

more restricted than general Horn clauses, because the literals are not pennitted<br />

to contain function symbols (this reduces the complexity of the hypothesis space<br />

search). Second, FOIL rules are more expressive than Horn clauses, because the<br />

literals appearing in the body of the rule may be negated. FOIL has been applied<br />

to a variety of problem domains. For example, it has been demonstrated to learn a<br />

recursive definition of the QUICKSORT algorithm and to learn to discriminate legal<br />

from illegal chess positions.<br />

The FOIL algorithm is summarized in Table 10.4. Notice the outer loop<br />

corresponds to a variant of the SEQUENTIAL-COVERING algorithm discussed earlier;<br />

that is, it learns new rules one at a time, removing the positive examples covered by<br />

the latest rule before attempting to learn the next rule. The inner loop corresponds<br />

to a variant of our earlier LEARN-ONE-RULE algorithm, extended to accommodate<br />

first-order rules. Note also there are a few minor differences between FOIL and<br />

these earlier algorithms. In particular, FOIL seeks only rules that predict when<br />

the target literal is True, whereas our earlier algorithm would seek both rules<br />

that predict when it is True and rules that predict when it is False. Also, FOIL<br />

performs a simple hillclimbing search rather than a beam search (equivalently, it<br />

uses a beam of width one).<br />

The hypothesis space search performed by FOIL is best understood by view-<br />

ing it hierarchically. Each iteration through FOIL'S outer loop adds a new rule to<br />

its disjunctive hypothesis, Learned~ules. The effect of each new rule is to gen-<br />

--<br />

FOIL(Target-predicate, Predicates, Examples)<br />

Pos c those Examples for which the Target-predicate is True<br />

Neg c those Examples for which the Target-predicate is False<br />

while Pos, do<br />

Learn a NewRule<br />

New Rule t the rule that predicts Target-predicate with no preconditions<br />

NewRuleNeg t Neg<br />

while NewRuleNeg, do<br />

Add a new literal to specialize New Rule<br />

Candidateliterals t generate candidate new literals for NewRule, based on<br />

Predicates<br />

Bestliteralt argmax Foil-Gain(L,NewRule)<br />

LECandidateliterals<br />

add Bestliteral to preconditions of NewRule<br />

NewRuleNeg c subset of NewRuleNeg that satisfies NewRule preconditions<br />

Learned~ul es c Learned-rules + NewRule<br />

Pos t Pos - {members of Pos covered by NewRule)<br />

Return Learned-rules<br />

TABLE 10.4<br />

The basic FOIL algorithm. The specific method for generating Candidateliterals and the defini- ~<br />

tion of Foil-Gain are given in the text. This basic algorithm can be modified slightly to better<br />

accommodate noisy data, as described in the text.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!