A THEORY OF THE LEARNABLE (L.G. VALIANT)
Theory ¡Lunch ¡Presentation Claire ¡Le ¡Goues 05/20/10
1
A THEORY OF THE LEARNABLE (L.G. VALIANT) Theory Lunch Presentation - - PowerPoint PPT Presentation
A THEORY OF THE LEARNABLE (L.G. VALIANT) Theory Lunch Presentation Claire Le Goues 05/20/10 1 2 HOW DO YOU KNOW THAT? 3 HOW DO YOU KNOW THAT? bool is_a_duck() { return (walks_like_a_duck() && quacks_like_a_duck()); }
1
2
3
3
4
5
6
7
✦ Present ¡a ¡general ¡framework ¡for ¡reasoning ¡
7
✦ Present ¡a ¡general ¡framework ¡for ¡reasoning ¡
✦ Introduce ¡the ¡idea ¡of ¡Probably ¡
7
✦ Present ¡a ¡general ¡framework ¡for ¡reasoning ¡
✦ Introduce ¡the ¡idea ¡of ¡Probably ¡
✦ Prove ¡3 ¡classes ¡of ¡programs ¡to ¡be ¡PAL. ¡
7
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
8 8
9
✦ Focus ¡on ¡learning ¡skills ¡that ¡involve ¡
9
✦ Focus ¡on ¡learning ¡skills ¡that ¡involve ¡
✦ Learn ¡to ¡answer ¡the ¡
9
✦ Focus ¡on ¡learning ¡skills ¡that ¡involve ¡
✦ Learn ¡to ¡answer ¡the ¡
walks ¡like ¡a ¡duck ¡= ¡true purple ¡= ¡false fluffy ¡= ¡true yellow ¡= ¡true beak ¡= ¡true big ¡= ¡false ¡ quacks ¡like ¡a ¡duck=true angry ¡= ¡false ...
10
11
✦ Given ¡t boolean ¡variables ¡p1,…,pt:
11
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
11
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
11
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
12
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
12
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
✦
Variables: ¡{walks ¡like ¡a ¡duck, ¡beak, ¡purple, ¡...}
✦
Vector ¡v: ¡{walks_like_a_duck=0, ¡beak=1, ¡purple=*, ¡...} ¡
✦
F(v) ¡= ¡is_a_duck(v) = ¡false
12
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
✦
Variables: ¡{purple, ¡walks ¡like ¡a ¡duck, ¡beak, ¡...}
✦
Vector ¡v: ¡{purple=*, ¡walks_like_a_duck=0, ¡beak=1 ¡...} ¡
✦
F(v) ¡= ¡is_a_duck(v) ¡= ¡false Variables ¡determined ¡in ¡v: ¡{walks_like_a_duck, ¡beak}
13
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
✦
Variables: ¡{purple, ¡walks ¡like ¡a ¡duck, ¡beak, ¡...}
✦
Vector ¡v: ¡{purple=*, ¡walks_like_a_duck=0, ¡beak=1 ¡...} ¡
✦
F(v) ¡= ¡is_a_duck(v) ¡= ¡false Variables ¡determined ¡in ¡is_a_duck: ¡{walks_like_a_duck, ¡quacks_like_a_duck}
14
✦ Given ¡t boolean ¡variables ¡p1,…,pt: ✦ A ¡vector ¡is ¡an ¡assignment ¡to ¡each ¡of ¡the ¡
✦ Function ¡(concept) ¡F ¡maps ¡all ¡vectors ¡
✦
t boolean variables p1,…,pt
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
15
✦
t boolean variables p1,…,pt:
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
16
✦
t boolean variables p1,…,pt:
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
✦ Assume D, a ¡probability ¡distribution ¡over ¡
16
✦
t boolean variables p1,…,pt:
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
✦ Assume D, a ¡probability ¡distribution ¡over ¡
✦ D is ¡meant ¡to ¡describe ¡the ¡relative ¡natural ¡
16
✦
t boolean variables p1,…,pt:
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
✦ Assume D, a ¡probability ¡distribution ¡over ¡
✦ D is ¡meant ¡to ¡describe ¡the ¡relative ¡natural ¡
✦ If ¡we ¡have ¡a ¡vector ¡v ¡that ¡describes ¡a ¡
16
✦
t boolean variables p1,…,pt:
✦
Vectors assign variables to one of {0,1,*}.
✦
Concept F maps vectors to {0,1}.
✦ Assume D, a ¡probability ¡distribution ¡over ¡
✦ D is ¡meant ¡to ¡describe ¡the ¡relative ¡natural ¡
✦ If ¡we ¡have ¡a ¡vector ¡v ¡that ¡describes ¡a ¡
Probability distribution D over all true vectors v. 17
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v.
18
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v.
19
20
✦ A ¡learning ¡machine ¡has ¡two ¡
20
✦ A ¡learning ¡machine ¡has ¡two ¡
20
✦ A ¡learning ¡machine ¡has ¡two ¡
20
21
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v.
22
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v.
23
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v. ✦ Learner has access to two routines (or
23
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v. ✦ Learner has access to two routines (or
✦ Probability that EXAMPLE returns any
23
t boolean variables p1,…,pt:
Vectors assign variables to one of {0,1,*}.
Concept F mapping vectors to {0,1}.
Probability distribution D over all true v. ✦ Learner has access to two routines (or
✦ Probability that EXAMPLE returns any
23
24 24
24
24
24
24
24
24
24
24
24
24
24
24
24
24
25 25
25
ORACLE( )
25
25
ORACLE( )
25
25
ORACLE( )
25
25
ORACLE( )
25
25
ORACLE( )
25
25
ORACLE({a1=0,a2=0,a3=*,a4=1})
25
25
ORACLE({a1=0,a2=0,a3=*,a4=1})
25
26
✦ A ¡class ¡of ¡problems ¡is ¡Probably ¡Approximately ¡
Learnable ¡if ¡instances ¡of ¡the ¡problem ¡can ¡be ¡learned ¡by ¡ a ¡deduction ¡algorithm ¡that:
26
✦ A ¡class ¡of ¡problems ¡is ¡Probably ¡Approximately ¡
Learnable ¡if ¡instances ¡of ¡the ¡problem ¡can ¡be ¡learned ¡by ¡ a ¡deduction ¡algorithm ¡that:
26
✦ A ¡class ¡of ¡problems ¡is ¡Probably ¡Approximately ¡
Learnable ¡if ¡instances ¡of ¡the ¡problem ¡can ¡be ¡learned ¡by ¡ a ¡deduction ¡algorithm ¡that:
parameter ¡h, ¡size ¡of ¡learned ¡program, ¡and ¡number ¡of ¡ variables ¡determined ¡in ¡the ¡learned ¡formula.
26
✦ A ¡class ¡of ¡problems ¡is ¡Probably ¡Approximately ¡
Learnable ¡if ¡instances ¡of ¡the ¡problem ¡can ¡be ¡learned ¡by ¡ a ¡deduction ¡algorithm ¡that:
parameter ¡h, ¡size ¡of ¡learned ¡program, ¡and ¡number ¡of ¡ variables ¡determined ¡in ¡the ¡learned ¡formula.
itʼ‚s ¡true ¡with ¡probability ¡no ¡greater ¡than ¡(1-h-1); ¡ never ¡says ¡that ¡ ¡something ¡is ¡true ¡when ¡itʼ‚s ¡false.
26
27 27
✦ We ¡are ¡trying ¡to ¡make ¡a ¡program ¡(learning ¡machine) ¡
27 27
✦ We ¡are ¡trying ¡to ¡make ¡a ¡program ¡(learning ¡machine) ¡
✦ The ¡learning ¡program ¡has ¡access ¡to ¡a ¡function ¡that ¡
27 27
✦ We ¡are ¡trying ¡to ¡make ¡a ¡program ¡(learning ¡machine) ¡
✦ The ¡learning ¡program ¡has ¡access ¡to ¡a ¡function ¡that ¡
✦ The ¡learning ¡machine ¡can ¡learn ¡a ¡program ¡that ¡is ¡
27 27
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
28 28
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29 29
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29
✦ The ¡paper ¡proves ¡three ¡different ¡program ¡classes ¡
probably-approximately-learnable.
29
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29
✦ The ¡paper ¡proves ¡three ¡different ¡program ¡classes ¡
probably-approximately-learnable.
✦ I ¡am ¡not ¡going ¡to ¡walk ¡through ¡the ¡proofs; ¡they ¡are ¡
by ¡construction ¡of ¡deduction ¡algorithms ¡that ¡can ¡learn ¡ the ¡given ¡programs ¡and ¡proofs ¡of ¡their ¡bounds.
29
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29
✦ The ¡paper ¡proves ¡three ¡different ¡program ¡classes ¡
probably-approximately-learnable.
✦ I ¡am ¡not ¡going ¡to ¡walk ¡through ¡the ¡proofs; ¡they ¡are ¡
by ¡construction ¡of ¡deduction ¡algorithms ¡that ¡can ¡learn ¡ the ¡given ¡programs ¡and ¡proofs ¡of ¡their ¡bounds.
✦ I ¡am ¡going ¡to ¡give ¡the ¡upper ¡bounds ¡of ¡the ¡
29
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29
✦ The ¡paper ¡proves ¡three ¡different ¡program ¡classes ¡
probably-approximately-learnable.
✦ I ¡am ¡not ¡going ¡to ¡walk ¡through ¡the ¡proofs; ¡they ¡are ¡
by ¡construction ¡of ¡deduction ¡algorithms ¡that ¡can ¡learn ¡ the ¡given ¡programs ¡and ¡proofs ¡of ¡their ¡bounds.
✦ I ¡am ¡going ¡to ¡give ¡the ¡upper ¡bounds ¡of ¡the ¡
✦ The ¡proof ¡of ¡that ¡functionʼ‚s ¡upper ¡bound ¡is ¡the ¡major ¡
lemma ¡in ¡all ¡three ¡proofs, ¡so ¡I ¡will ¡outline ¡it.
29
might ¡learn ¡to ¡write ¡a ¡program ¡that ¡recognizes ¡whether ¡a ¡ given ¡animal ¡is ¡a ¡duck.
29
✦ The ¡paper ¡proves ¡three ¡different ¡program ¡classes ¡
probably-approximately-learnable.
✦ I ¡am ¡not ¡going ¡to ¡walk ¡through ¡the ¡proofs; ¡they ¡are ¡
by ¡construction ¡of ¡deduction ¡algorithms ¡that ¡can ¡learn ¡ the ¡given ¡programs ¡and ¡proofs ¡of ¡their ¡bounds.
✦ I ¡am ¡going ¡to ¡give ¡the ¡upper ¡bounds ¡of ¡the ¡
✦ The ¡proof ¡of ¡that ¡functionʼ‚s ¡upper ¡bound ¡is ¡the ¡major ¡
lemma ¡in ¡all ¡three ¡proofs, ¡so ¡I ¡will ¡outline ¡it.
✦ This ¡means ¡the ¡next ¡3 ¡slides ¡are ¡mathy. ¡
29
30
✦ L(h,S) is ¡a ¡function ¡defined ¡for ¡all ¡real ¡numbers ¡h >
30
✦ L(h,S) is ¡a ¡function ¡defined ¡for ¡all ¡real ¡numbers ¡h >
✦ Returns ¡smallest ¡integer ¡n ¡such ¡that ¡in ¡n ¡independent ¡
30
31
31
Proof ¡by ¡algebraic ¡substitution ¡of ¡well-known ¡inequalities:
31
Proof ¡by ¡algebraic ¡substitution ¡of ¡well-known ¡inequalities:
31
Proof ¡by ¡algebraic ¡substitution ¡of ¡well-known ¡inequalities:
31
Proof ¡by ¡algebraic ¡substitution ¡of ¡well-known ¡inequalities:
¡P(successes ¡at ¡most ¡k) ¡≤ ¡ ¡
m-mp m-k)
m-k ) k
mp k
31
32
✦ L(h,S) is ¡basically ¡linear ¡in ¡both ¡h ¡and ¡S.
32
✦ L(h,S) is ¡basically ¡linear ¡in ¡both ¡h ¡and ¡S. ✦ Applies ¡to ¡using ¡EXAMPLEs ¡and ¡ORACLE ¡to ¡
32
✦ L(h,S) is ¡basically ¡linear ¡in ¡both ¡h ¡and ¡S. ✦ Applies ¡to ¡using ¡EXAMPLEs ¡and ¡ORACLE ¡to ¡
✦ An ¡algorithm ¡can ¡approximate ¡the ¡set ¡of ¡
32
✦ L(h,S) is ¡basically ¡linear ¡in ¡both ¡h ¡and ¡S. ✦ Applies ¡to ¡using ¡EXAMPLEs ¡and ¡ORACLE ¡to ¡
✦ An ¡algorithm ¡can ¡approximate ¡the ¡set ¡of ¡
32
33
34
34
34
34
35
✦ Conjunctive ¡Normal ¡form ¡(CNF): ¡
35
✦ Conjunctive ¡Normal ¡form ¡(CNF): ¡
✦ k-CNF ¡expression: ¡a ¡CNF ¡expression ¡where ¡
35
✦ Conjunctive ¡Normal ¡form ¡(CNF): ¡
✦ k-CNF ¡expression: ¡a ¡CNF ¡expression ¡where ¡
✦ Learnable ¡with ¡an ¡algorithm ¡that ¡does ¡not ¡call ¡
35
36
✦ Disjunctive ¡Normal ¡Form ¡(DNF):
36
✦ Disjunctive ¡Normal ¡Form ¡(DNF):
✦ An ¡expression ¡is ¡monotone ¡if ¡it ¡contains ¡no ¡
36
✦ Disjunctive ¡Normal ¡Form ¡(DNF):
✦ An ¡expression ¡is ¡monotone ¡if ¡it ¡contains ¡no ¡
✦ Learnable ¡with ¡an ¡algorithm ¡that ¡calls ¡
36
37
✦ General ¡expression ¡over ¡{p1,…,pt} defined ¡
37
✦ General ¡expression ¡over ¡{p1,…,pt} defined ¡
✦ A ¡μ-expression ¡is ¡an ¡expression ¡in ¡which ¡each ¡
37
✦ General ¡expression ¡over ¡{p1,…,pt} defined ¡
✦ A ¡μ-expression ¡is ¡an ¡expression ¡in ¡which ¡each ¡
✦ Learnable ¡with ¡an ¡exactly ¡correct ¡algorithm ¡
37
38
✦ Learnability ¡theory ¡is ¡concerned ¡with ¡what ¡programs ¡can ¡
be ¡learned ¡automatically.
38
✦ Learnability ¡theory ¡is ¡concerned ¡with ¡what ¡programs ¡can ¡
be ¡learned ¡automatically.
✦ We ¡should ¡reason ¡about ¡what ¡is ¡programmatically ¡
learnable ¡in ¡the ¡same ¡way ¡we ¡reason ¡about ¡what ¡is ¡ computable.
38
✦ Learnability ¡theory ¡is ¡concerned ¡with ¡what ¡programs ¡can ¡
be ¡learned ¡automatically.
✦ We ¡should ¡reason ¡about ¡what ¡is ¡programmatically ¡
learnable ¡in ¡the ¡same ¡way ¡we ¡reason ¡about ¡what ¡is ¡ computable.
✦ A ¡class ¡of ¡programs ¡is ¡Probably ¡Approximately ¡Learnable ¡
when, ¡using ¡a ¡particular ¡type ¡of ¡teacher, ¡a ¡given ¡ algorithm ¡can ¡learn ¡a ¡program ¡that ¡can ¡recognize ¡ instances ¡of ¡that ¡class ¡with ¡a ¡certain ¡probability.
38
✦ Learnability ¡theory ¡is ¡concerned ¡with ¡what ¡programs ¡can ¡
be ¡learned ¡automatically.
✦ We ¡should ¡reason ¡about ¡what ¡is ¡programmatically ¡
learnable ¡in ¡the ¡same ¡way ¡we ¡reason ¡about ¡what ¡is ¡ computable.
✦ A ¡class ¡of ¡programs ¡is ¡Probably ¡Approximately ¡Learnable ¡
when, ¡using ¡a ¡particular ¡type ¡of ¡teacher, ¡a ¡given ¡ algorithm ¡can ¡learn ¡a ¡program ¡that ¡can ¡recognize ¡ instances ¡of ¡that ¡class ¡with ¡a ¡certain ¡probability.
✦ 3 ¡examples ¡of ¡such ¡learnable ¡program ¡types ¡are ¡k-CNF ¡
expressions, ¡monotone ¡DNF ¡expressions, ¡and ¡μ- expressions.
38
✦ What ¡else ¡is ¡learnable ¡by ¡these ¡
✦ Is ¡the ¡definition ¡of ¡“learnable” ¡
✦ How ¡do ¡humans ¡learn?
39
40
✦ Assume ¡we ¡have ¡urn ¡that ¡contains ¡many ¡marbles ¡of ¡S ¡
different ¡types. ¡We ¡want ¡to ¡“learn” ¡the ¡different ¡types ¡of ¡ marbles ¡by ¡taking ¡a ¡small ¡random ¡sample ¡X, ¡of ¡size ¡ sufficient ¡that, ¡with ¡high ¡probability, ¡it ¡contains ¡at ¡least ¡ 99% ¡of ¡S ¡marble ¡type ¡representatives. ¡
40
✦ Assume ¡we ¡have ¡urn ¡that ¡contains ¡many ¡marbles ¡of ¡S ¡
different ¡types. ¡We ¡want ¡to ¡“learn” ¡the ¡different ¡types ¡of ¡ marbles ¡by ¡taking ¡a ¡small ¡random ¡sample ¡X, ¡of ¡size ¡ sufficient ¡that, ¡with ¡high ¡probability, ¡it ¡contains ¡at ¡least ¡ 99% ¡of ¡S ¡marble ¡type ¡representatives. ¡
✦ Definition ¡of ¡L(h,S) implies:
|X| = L(100,S) ⇒ P(succeeded overall) > 99%
40
✦ Assume ¡we ¡have ¡urn ¡that ¡contains ¡many ¡marbles ¡of ¡S ¡
different ¡types. ¡We ¡want ¡to ¡“learn” ¡the ¡different ¡types ¡of ¡ marbles ¡by ¡taking ¡a ¡small ¡random ¡sample ¡X, ¡of ¡size ¡ sufficient ¡that, ¡with ¡high ¡probability, ¡it ¡contains ¡at ¡least ¡ 99% ¡of ¡S ¡marble ¡type ¡representatives. ¡
✦ Definition ¡of ¡L(h,S) implies:
|X| = L(100,S) ⇒ P(succeeded overall) > 99%
✦ “Success” ¡for ¡each ¡trial ¡is ¡defined ¡as ¡picking ¡a ¡marble ¡we ¡
havenʼ‚t ¡picked ¡before. ¡Success ¡clearly ¡depends ¡on ¡ previous ¡choices, ¡but ¡the ¡probability ¡of ¡each ¡success ¡will ¡ always ¡be ¡at ¡least ¡1%, ¡independent of previous choices.
40