statistical relational learning and knowledge graph reasoning

97
Statistical Relational Learning and Knowledge Graph Reasoning CSCI 699 J AY P UJARA

Upload: others

Post on 28-Nov-2021

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Statistical Relational Learning and Knowledge Graph Reasoning

Statistical Relational Learning and Knowledge Graph ReasoningCSCI 699

JAY PUJARA

Page 2: Statistical Relational Learning and Knowledge Graph Reasoning

Reminder: Basic problems

•Who are the entities (nodes) in the graph?

•What are their attributes and types (labels)?

• How are they related (edges)?

2

R 1

E1

R2

R 3

A1A2

E2

E3

A1A2

A1A2

Page 3: Statistical Relational Learning and Knowledge Graph Reasoning

Motivating Problem: New Opportunities

Internet Extraction

Knowledge Graph (KG)

Structured representation of entities, their labels and the relationships between them

Massive source of publicly available information

Cutting-edge IE methods

Page 4: Statistical Relational Learning and Knowledge Graph Reasoning

Motivating Problem: Real Challenges

Internet

Knowledge Graph

Noisy!Contains many errors and inconsistencies

Difficult!

Extraction

Page 5: Statistical Relational Learning and Knowledge Graph Reasoning

Graph Construction IssuesExtracted knowledge is:

• ambiguous:◦ Ex: Beetles, beetles, Beatles◦ Ex: citizenOf, livedIn, bornIn

5

Page 6: Statistical Relational Learning and Knowledge Graph Reasoning

Graph Construction IssuesExtracted knowledge is:

• ambiguous

• incomplete◦ Ex: missing relationships◦ Ex: missing labels◦ Ex: missing entities

6

author

auth

or

coworker

Page 7: Statistical Relational Learning and Knowledge Graph Reasoning

Graph Construction IssuesExtracted knowledge is:

• ambiguous

• incomplete

• inconsistent◦ Ex: Cynthia Lennon, Yoko Ono◦ Ex: exclusive labels (alive, dead)◦ Ex: domain-range constraints

7

spousesp

ouse

Page 8: Statistical Relational Learning and Knowledge Graph Reasoning

Graph Construction IssuesExtracted knowledge is:

• ambiguous

• incomplete

• inconsistent

8

Page 9: Statistical Relational Learning and Knowledge Graph Reasoning

NELL:The Never-Ending Language Learner

• Large-scale IE project (Carlson et al., 2010)

• Lifelong learning: aims to “read the web”

• Ontology of known labels and relations

• Knowledge base contains millions of facts

Page 10: Statistical Relational Learning and Knowledge Graph Reasoning

Examples of NELL errors

Page 11: Statistical Relational Learning and Knowledge Graph Reasoning

Kyrgyzstan has many variants:• Kyrgystan• Kyrgistan• Kyrghyzstan• Kyrgzstan• Kyrgyz Republic

Entity co-reference errors

Page 12: Statistical Relational Learning and Knowledge Graph Reasoning

Kyrgyzstan is labeled a bird and a

country

Missing and spurious labels

Page 13: Statistical Relational Learning and Knowledge Graph Reasoning

Missing and spurious relationsKyrgyzstan’s location is

ambiguous –Kazakhstan, Russia and

US are included in possible locations

Page 14: Statistical Relational Learning and Knowledge Graph Reasoning

Violations of ontological knowledge• Equivalence of co-referent entities (sameAs)• SameEntity(Kyrgyzstan, Kyrgyz Republic)

•Mutual exclusion (disjointWith) of labels• MUT(bird, country)

• Selectional preferences (domain/range) of relations• RNG(countryLocation, continent)

Enforcing these constraints require jointlyconsidering multiple extractions

Page 15: Statistical Relational Learning and Knowledge Graph Reasoning

Graph Construction approach•Graph construction cleans and completes extraction graph

•Incorporate ontological constraints and relational patterns

•Discover statistical relationships within knowledge graph

15

Page 16: Statistical Relational Learning and Knowledge Graph Reasoning

Graph ConstructionProbabilistic Models

TOPICS:

OVERVIEW

GRAPHICAL MODELS

RANDOM WALK METHODS

16

Page 17: Statistical Relational Learning and Knowledge Graph Reasoning

Graph ConstructionProbabilistic Models

TOPICS:

OVERVIEW

GRAPHICAL MODELS

RANDOM WALK METHODS

17

Page 18: Statistical Relational Learning and Knowledge Graph Reasoning

Voter Party Classification

?

Page 19: Statistical Relational Learning and Knowledge Graph Reasoning

�Statuses & Tweets

Multiple Sources of Information

Voter Party Classification

Page 20: Statistical Relational Learning and Knowledge Graph Reasoning

�Statuses & Tweets Donations

Multiple Sources of Information

Voter Party Classification

Page 21: Statistical Relational Learning and Knowledge Graph Reasoning

�Statuses & Tweets Donations

Friends & Followers

Multiple Sources of Information

Voter Party Classification

Page 22: Statistical Relational Learning and Knowledge Graph Reasoning

�Statuses & Tweets Donations

Friends & Followers Family

Multiple Sources of Information

Voter Party Classification

Page 23: Statistical Relational Learning and Knowledge Graph Reasoning

Voter Party Classification

Page 24: Statistical Relational Learning and Knowledge Graph Reasoning

Voter Party Classification

Page 25: Statistical Relational Learning and Knowledge Graph Reasoning

Voter Party Classification

$ CarlyFiorinaforVicePresident.com

Page 26: Statistical Relational Learning and Knowledge Graph Reasoning

Voter Party Classification

$ CarlyFiorinaforVicePresident.com

Page 27: Statistical Relational Learning and Knowledge Graph Reasoning

�Statuses & Tweets Donations

Friends & Followers Family

Multiple Sources of Information

Voter Party Classification

Page 28: Statistical Relational Learning and Knowledge Graph Reasoning

Standard Classification

CarlyFiorinaforVicePresident.com

Bag-of-words features

Page 29: Statistical Relational Learning and Knowledge Graph Reasoning

Standard Classification

CarlyFiorinaforVicePresident.com

Bag-of-words features

Pr(Y )

Page 30: Statistical Relational Learning and Knowledge Graph Reasoning

Standard Classification

CarlyFiorinaforVicePresident.com

Bag-of-words features

Page 31: Statistical Relational Learning and Knowledge Graph Reasoning

�Donations Status

Updates

Friends Family

Multiple Sources of Information

Voter Party Classification

Page 32: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows

Page 33: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows

Page 34: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows

Pr(Y )

Page 35: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows

My label is likely to match that of my follower

Page 36: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows

Follows(U1, U2) & Votes(U1, P) à Votes(U2, P)

Page 37: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

� ��spouse follower

Page 38: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

� ��spouse follower

Page 39: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Follows(U1, U2) & Votes(U1, P) à Votes(U2, P)

Spouse(U1, U2) & Votes(U1, P) à Votes(U2, P)

� ��spouse follower

Page 40: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Page 41: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

Pr(Y )

Page 42: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

� ��spouse follower

�follower

Page 43: Statistical Relational Learning and Knowledge Graph Reasoning

� ��spouse follower

�follower

Collective Classification

2.0: Follows(U1, U2) & Votes(U1, P) à Votes(U2, P)

5.0: Spouse(U1, U2) ^& Votes(U1, P) à Votes(U2, P)

Page 44: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

� ��spouse follower

�follower

Page 45: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification

���

� ��

spouse

spouse

colleague

colleague

spouse friend

friend

friend

friend

? ? ?

? ??

Page 46: Statistical Relational Learning and Knowledge Graph Reasoning

Collective Classification with PSL

/* Local rules */5.0: Donates(A, P) -> Votes(A, P)0.3: Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)0.3: Mentions(A, “Tax Cuts”) -> Votes(A, “Republican”)

/* Relational rules */1.0: Votes(A,P) & Spouse(B,A) -> Votes(B,P)0.3: Votes(A,P) & Friend(B,A) -> Votes(B,P)0.1: Votes(A,P) & Colleague(B,A) -> Votes(B,P)

/* Range constraint */Votes(A, “Republican”) + Votes(A, “Democrat”) = 1.0 .

Page 47: Statistical Relational Learning and Knowledge Graph Reasoning

Beyond Pure Reasoning

•Classical AI approach to knowledge: reasoningLbl(Socrates, Man) & Sub(Man, Mortal) -> Lbl(Socrates, Mortal)

47

Page 48: Statistical Relational Learning and Knowledge Graph Reasoning

Beyond Pure Reasoning

•Classical AI approach to knowledge: reasoningLbl(Socrates, Man) & Sub(Man, Mortal) -> Lbl(Socrates, Mortal)

•Reasoning difficult when extracted knowledge has errors

48

Page 49: Statistical Relational Learning and Knowledge Graph Reasoning

Beyond Pure Reasoning

•Classical AI approach to knowledge: reasoning

Lbl(Socrates, Man) & Sub(Man, Mortal) -> Lbl(Socrates, Mortal)

•Reasoning difficult when extracted knowledge has errors

•Solution: probabilistic models

P(Lbl(Socrates, Mortal)|Lbl(Socrates,Man)=0.9)

49

Page 50: Statistical Relational Learning and Knowledge Graph Reasoning

Logic Refresher: Satisfaction

Affordable Health

Democrat Logical Satisfaction

TRUE TRUE JTRUE FALSE LFALSE TRUE JFALSE FALSE J

/* Model Snippet */Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)

Page 51: Statistical Relational Learning and Knowledge Graph Reasoning

Logic and Noisy Data/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Logical Satisfaction

[2] Logical Satisfaction

TRUE TRUE TRUE J LTRUE TRUE FALSE L J

Page 52: Statistical Relational Learning and Knowledge Graph Reasoning

Logic and Noisy Data/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Logical Satisfaction

[2] Logical Satisfaction

TRUE TRUE TRUE J LTRUE TRUE FALSE L J

In logic, much as in politics, it is hard to satisfy everyone

Page 53: Statistical Relational Learning and Knowledge Graph Reasoning

Soft Logic to the Rescue!/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Logical Satisfaction

[2] Logical Satisfaction

TRUE TRUE 0.5

TRUE TRUE 0.5!

! !

!

Page 54: Statistical Relational Learning and Knowledge Graph Reasoning

What does 0.5 MEAN?

Page 55: Statistical Relational Learning and Knowledge Graph Reasoning

What does 0.5 mean?

• Rounding probability:• Flip a coin with bias 0.5• Heads = TRUE• Tails = FALSE

• Using this method is a ¾ optimal solution to the NP hard weighted MAX SAT problem [Goemans&Williams, 94]

55

Page 56: Statistical Relational Learning and Knowledge Graph Reasoning

What does !MEAN?

Page 57: Statistical Relational Learning and Knowledge Graph Reasoning

What does !mean?

P -> Q

• /* Soft Logic Penalty */

• if P < Q

• return J• else:• return P-Q

Page 58: Statistical Relational Learning and Knowledge Graph Reasoning

!: Closed Form

P -> Q

•max(0, P-Q)

Page 59: Statistical Relational Learning and Knowledge Graph Reasoning

Q=0 Q=0.2 Q=0.4 Q=0.6 Q=0.8 Q=1

0

0.2

0.4

0.6

0.8

1

P=1P=.6

P=.2

Soft Loss

0-0.2 0.2-0.4 0.4-0.6 0.6-0.8 0.8-1

!: Closed Form

P -> Qmax(0, P-Q)

Page 60: Statistical Relational Learning and Knowledge Graph Reasoning

What does !mean?/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

/* Soft Logic Penalty */

if Mentions(A, “Tax Cuts”) < !Votes(A, “Democrat”):

return 0else:

return Mentions(A, “Tax Cuts”) - !Votes(A, “Democrat”)

Page 61: Statistical Relational Learning and Knowledge Graph Reasoning

Computing !/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Penalty [2] Penalty

1 1 0.71 1 0.2

!Q = 1-QP -> Q = max(0, P-Q)

Page 62: Statistical Relational Learning and Knowledge Graph Reasoning

Computing !/* Model Snippet */[1] Mentions(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Mentions(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Penalty [2] Penalty

1 1 0.7 0.3 0.71 1 0.2 0.8 0.2

!Q = 1-QP -> Q = max(0, P-Q)

Page 63: Statistical Relational Learning and Knowledge Graph Reasoning

Computing ! with soft evidence/* Model Snippet */[1] Supports(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Supports(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Penalty [2] Penalty

0.4 0.1 0.650.4 0.1 0.20.4 0.1 0.9

!Q = 1-QP -> Q = max(0, P-Q)

Page 64: Statistical Relational Learning and Knowledge Graph Reasoning

Computing ! with soft evidence/* Model Snippet */[1] Supports(A, “Affordable Health”) -> Votes(A, “Democrat”)[2] Supports(A, “Tax Cuts”) -> !Votes(A, “Democrat”)

Affordable Health

TaxCuts

Democrat [1] Penalty [2] Penalty

0.4 0.1 0.65 0 00.4 0.1 0.2 0.2 00.4 0.1 0.9 0.5 0

!Q = 1-QP -> Q = max(0, P-Q)

Page 65: Statistical Relational Learning and Knowledge Graph Reasoning

Computing ! for arbitrary formulas

!Q = 1-QP -> Q = max(0, P-Q)P & Q = max(0, P+Q-1)P | Q = min(1, P+Q)

Page 66: Statistical Relational Learning and Knowledge Graph Reasoning

Underlying Probability Distribution

p(Y|X) =1

Z(w,X)exp

2

4�mX

j=1

wj

hmax {�j(Y,X), 0}]{1,2}

i3

5

Joint probability over soft-truth assignments

Sum over rule penalties

Page 67: Statistical Relational Learning and Knowledge Graph Reasoning

Optimizing PSL models

• PSL finds optimal assignment for all unknowns

• Optimal = minimizes the soft-logic penalty

• Fast, joint convex optimization using ADMM

• Supports learning rule weights and latent variables

Page 68: Statistical Relational Learning and Knowledge Graph Reasoning

Graph ConstructionProbabilistic Models

TOPICS:

OVERVIEW

GRAPHICAL MODELS

RANDOM WALK METHODS

69

Page 69: Statistical Relational Learning and Knowledge Graph Reasoning

Graphical Models: Overview•Define joint probability distribution on knowledge graphs

•Each candidate fact in the knowledge graph is a variable

•Statistical signals, ontological knowledge and rules parameterize the dependencies between variables

•Find most likely knowledge graph by optimization/sampling

70

Page 70: Statistical Relational Learning and Knowledge Graph Reasoning

Motivating Problem (revised)

Internet

(noisy) Extraction GraphKnowledge Graph

=Large-scale IE

Joint Reasoning

Page 71: Statistical Relational Learning and Knowledge Graph Reasoning

Knowledge Graph Identification

Performs graph identification:◦ entity resolution◦ collective classification◦ link prediction

Enforces ontological constraints

Incorporates multiple uncertain sources

Knowledge Graph Identification

Knowledge Graph

=

Problem:

Solution: Knowledge Graph Identification (KGI)Extraction Graph

Page 72: Statistical Relational Learning and Knowledge Graph Reasoning

Knowledge Graph IdentificationDefine a graphical model to perform all three of these tasks simultaneously!

•Who are the entities (nodes) in the graph?

•What are their attributes and types (labels)?

• How are they related (edges)?

73

R 1

E1

R2

R 3

A1A2

E2

E3

A1A2

A1A2

PUJARA+ISWC13

Page 73: Statistical Relational Learning and Knowledge Graph Reasoning

Knowledge Graph Identification

P(Who, What, How|Extractions)

74

R 1

E1

R2

R 3

A1A2

E2

E3

A1A2

A1A2

PUJARA+ISWC13

Page 74: Statistical Relational Learning and Knowledge Graph Reasoning

Probabilistic Models•Use dependencies between facts in KG

•Probability defined jointly over facts

75

P=0 P=0.25 P=0.75

Page 75: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

76

Page 76: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

• P(R(John,Spouse,Yoko))=0.75; P(R(John,Spouse,Cynthia))=0.25• LevenshteinSimilarity(Beatles, Beetles) = 0.9

77

Page 77: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

•Ontological knowledge about domain

78

Page 78: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

•Ontological knowledge about domain• Functional(Spouse) & R(A,Spouse,B) -> !R(A,Spouse,C)• Range(Spouse, Person) & R(A,Spouse,B) -> Type(B, Person)

79

Page 79: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

•Ontological knowledge about domain

•Rules and patterns mined from data

80

Page 80: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

•Ontological knowledge about domain

•Rules and patterns mined from data• R(A, Spouse, B) & R(A, Lives, L) -> R(B, Lives, L)• R(A, Spouse, B) & R(A, Child, C) -> R(B, Child, C)

81

Page 81: Statistical Relational Learning and Knowledge Graph Reasoning

What determines probability?•Statistical signals from text extractors and classifiers

• P(R(John,Spouse,Yoko))=0.75; P(R(John,Spouse,Cynthia))=0.25• LevenshteinSimilarity(Beatles, Beetles) = 0.9

•Ontological knowledge about domain• Functional(Spouse) & R(A,Spouse,B) -> !R(A,Spouse,C)• Range(Spouse, Person) & R(A,Spouse,B) -> Type(B, Person)

•Rules and patterns mined from data• R(A, Spouse, B) & R(A, Lives, L) -> R(B, Lives, L)• R(A, Spouse, B) & R(A, Child, C) -> R(B, Child, C)

82

Page 82: Statistical Relational Learning and Knowledge Graph Reasoning

Example: The Fab Four

83

Page 83: Statistical Relational Learning and Knowledge Graph Reasoning

Illustration of KG IdentificationUncertain Extractions:.5: Lbl(Fab Four, novel).7: Lbl(Fab Four, musician).9: Lbl(Beatles, musician)

.8: Rel(Beatles,AlbumArtist, Abbey Road)

PUJARA+ISWC13; PUJARA+AIMAG15

Page 84: Statistical Relational Learning and Knowledge Graph Reasoning

Illustration of KG IdentificationUncertain Extractions:.5: Lbl(Fab Four, novel).7: Lbl(Fab Four, musician).9: Lbl(Beatles, musician)

.8: Rel(Beatles,AlbumArtist, Abbey Road)

musician

Fab Four Beatles

novel

Abbey Road

Lbl

Rel(A

lbumArtist)

LblLbl

(Annotated) Extraction Graph

PUJARA+ISWC13; PUJARA+AIMAG15

Page 85: Statistical Relational Learning and Knowledge Graph Reasoning

Illustration of KG Identification

Ontology:Dom(albumArtist, musician)Mut(novel, musician)

Uncertain Extractions:.5: Lbl(Fab Four, novel).7: Lbl(Fab Four, musician).9: Lbl(Beatles, musician)

.8: Rel(Beatles,AlbumArtist, Abbey Road)

musician

Fab Four Beatles

novel

Abbey Road

Dom

Mut

Lbl

LblLbl

Extraction Graph

PUJARA+ISWC13; PUJARA+AIMAG15

Rel(A

lbumArtist)

Page 86: Statistical Relational Learning and Knowledge Graph Reasoning

Illustration of KG Identification

Ontology:Dom(albumArtist, musician)Mut(novel, musician)

Uncertain Extractions:.5: Lbl(Fab Four, novel).7: Lbl(Fab Four, musician).9: Lbl(Beatles, musician)

.8: Rel(Beatles,AlbumArtist, Abbey Road)

Entity Resolution:SameEnt(Fab Four, Beatles)

musician

Fab Four Beatles

novel

Abbey Road

SameEnt

Mut

Lbl

LblLbl

(Annotated) Extraction Graph

Dom

PUJARA+ISWC13; PUJARA+AIMAG15

Rel(A

lbumArtist)

Page 87: Statistical Relational Learning and Knowledge Graph Reasoning

Illustration of KG Identification

Ontology:Dom(albumArtist, musician)Mut(novel, musician)

Uncertain Extractions:.5: Lbl(Fab Four, novel).7: Lbl(Fab Four, musician).9: Lbl(Beatles, musician)

.8: Rel(Beatles,AlbumArtist, Abbey Road)

Entity Resolution:SameEnt(Fab Four, Beatles)

Beatles

Fab FourAbbey Roadmusician

Rel(AlbumArtist)Lbl

musician

Fab Four Beatles

novel

Abbey Road

SameEnt

Mut

Lbl

LblLbl

(Annotated) Extraction Graph

After Knowledge Graph Identification

Dom

PUJARA+ISWC13; PUJARA+AIMAG15

Rel(A

lbumArtist)

Page 88: Statistical Relational Learning and Knowledge Graph Reasoning

Probabilistic graphical model for KG

Lbl(Fab Four, musician)

Lbl(Beatles, musician)

Rel(Beatles, AlbumArtist, Abbey Road)

Rel(Fab Four, AlbumArtist, Abbey Road)

Lbl(Beatles, novel)

Lbl(Fab Four, novel)

Page 89: Statistical Relational Learning and Knowledge Graph Reasoning

Defining graphical models•Many options for defining a graphical model

•We focus on two approaches, MLNs and PSL, that use rules

•MLNs treat facts as Boolean, use sampling for satisfaction

•PSL infers a “truth value” for each fact via optimization

90

Page 90: Statistical Relational Learning and Knowledge Graph Reasoning

100: Subsumes(L1,L2) & Label(E,L1) -> Label(E,L2)100: Exclusive(L1,L2) & Label(E,L1) -> !Label(E,L2)

100: Inverse(R1,R2) & Relation(R1,E,O) -> Relation(R2,O,E)100: Subsumes(R1,R2) & Relation(R1,E,O) -> Relation(R2,E,O)100: Exclusive(R1,R2) & Relation(R1,E,O) -> !Relation(R2,E,O)

100: Domain(R,L) & Relation(R,E,O) -> Label(E,L)100: Range(R,L) & Relation(R,E,O) -> Label(O,L)

10: SameEntity(E1,E2) & Label(E1,L) -> Label(E2,L)10: SameEntity(E1,E2) & Relation(R,E1,O) -> Relation(R,E2,O)

1: Label_OBIE(E,L) -> Label(E,L)1: Label_OpenIE(E,L) -> Label(E,L)1: Relation_Pattern(R,E,O) -> Relation(R,E,O)1: !Relation(R,E,O)1: !Label(E,L)

Rules for KG Model

JIANG+ICDM12; PUJARA+ISWC13, PUJARA+AIMAG15 91

Page 91: Statistical Relational Learning and Knowledge Graph Reasoning

Rules to Distributions•Rules are grounded by substituting literals into formulas

•Each ground rule has a weighted satisfaction derived from the formula’s truth value

•Together, the ground rules provide a joint probability distribution over knowledge graph facts, conditioned on the extractions

P (G|E) =1

Zexp

"X

r2R

wr�r(G,E)

#

wr : SameEnt(Fab Four,Beatles) ^Lbl(Beatles,musician) ) Lbl(Fab Four,musician)

JIANG+ICDM12; PUJARA+ISWC13

Page 92: Statistical Relational Learning and Knowledge Graph Reasoning

Probability Distribution over KGs

P(G | E) = 1Zexp − wrr∈R∑ ϕr (G)$

%&'

CandLblT (FabFour, novel) ) Lbl(FabFour, novel)

Mut(novel, musician) ^ Lbl(Beatles, novel)

) ¬Lbl(Beatles, musician)

SameEnt(Beatles, FabFour) ^ Lbl(Beatles, musician)

) Lbl(FabFour, musician)

Page 93: Statistical Relational Learning and Knowledge Graph Reasoning

Lbl(Fab Four,musician)

φ1

Lbl(Fab Four,novel)

Lbl(Beatles,novel)

Lbl(Beatles,musician)

Rel(Beatles, albumArtist, Abbey Road)

φ5 φ

φ2

φ3 φ4

φ

φ

φ

φ[�1] CandLblstruct(FabFour, novel)

) Lbl(FabFour, novel)

[�2] CandRelpat(Beatles, AlbumArtist, AbbeyRoad)

) Rel(Beatles, AlbumArtist, AbbeyRoad)

[�3] SameEnt(Beatles, FabFour)

^ Lbl(Beatles, musician)

) Lbl(FabFour, musician)

[�4] Dom(AlbumArtist, musician)

^Rel(Beatles, AlbumArtist, AbbeyRoad)

) Lbl(Beatles, musician)

[�5] Mut(musician, novel)

^ Lbl(FabFour, musican)

) ¬Lbl(FabFour, novel)

PUJARA+ISWC13; PUJARA+AIMAG15

Page 94: Statistical Relational Learning and Knowledge Graph Reasoning

How do we get a knowledge graph?Have: P(KG) forall KGs Need: best KG

95

MAP inference: optimizing over distribution to find the best knowledge graph

R 1

R2

R 3

A1

A2

E2

E3

A1

A2

A1

A2

E1

P( ) R 1

R2

R 3

A1

A2

E2

E3

A1

A2

A1

A2

E1

Page 95: Statistical Relational Learning and Knowledge Graph Reasoning

Inference and KG optimization•Finding the best KG satisfying weighed rules: NP Hard

•MLNs [discrete]: Monte Carlo sampling methods• Solution quality dependent on burn-in time, iterations, etc.

•PSL [continuous]: optimize convex linear surrogate•Fast optimization, ¾-optimal MAX SAT lower bound

96

Page 96: Statistical Relational Learning and Knowledge Graph Reasoning

Graphical Models ExperimentsData: ~1.5M extractions, ~70K ontological relations, ~500 relation/label types

Task: Collectively construct a KG and evaluate on 25K target facts

Comparisons:Extract Average confidences of extractors for each fact in the NELL candidates

Rules Default, rule-based heuristic strategy used by the NELL project

MLN Jiang+, ICDM12 – estimates marginal probabilities with MC-SAT

PSL Pujara+, ISWC13 – convex optimization of continuous truth values with ADMM

Running Time: Inference completes in 10 seconds, values for 25K facts

JIANG+ICDM12; PUJARA+ISWC13

AUC F1

Extract .873 .828

Rules .765 .673

MLN (Jiang, 12) .899 .836

PSL (Pujara, 13) .904 .853

Page 97: Statistical Relational Learning and Knowledge Graph Reasoning

Graphical Models: Pros/ConsBENEFITS

• Define probability distribution over KGs

• Easily specified via rules

• Fuse knowledge from many different sources

DRAWBACKS

98

• Requires optimization over all KG facts - overkill

• Dependent on rules from ontology/expert

• Require probabilistic semantics - unavailable