http://cs224w.stanford.edu Last time: Decision Based Models Utility - - PowerPoint PPT Presentation

http cs224w stanford edu last time decision based models
SMART_READER_LITE
LIVE PREVIEW

http://cs224w.stanford.edu Last time: Decision Based Models Utility - - PowerPoint PPT Presentation

CS224W: Social and Information Network Analysis Jure Leskovec, Stanford University http://cs224w.stanford.edu Last time: Decision Based Models Utility based Deterministic Node centric: A node observes decisions of its


slide-1
SLIDE 1

CS224W: Social and Information Network Analysis Jure Leskovec, Stanford University

http://cs224w.stanford.edu

slide-2
SLIDE 2

 Last time:

Decision Based Models

  • Utility based
  • Deterministic
  • “Node” centric: A node observes decisions of its

neighbors and makes its own decision

  • Require us to know too much about the data

 Today: Probabilistic Models

  • Let’s you do things by observing data
  • We loose “why people do things”

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 2

slide-3
SLIDE 3
slide-4
SLIDE 4

 Epidemic Model based on Random Trees

  • (a variant of branching processes)
  • A patient meets d other people
  • With probability q > 0 infects each
  • f them

 Q: For which values of d and q

does the epidemic run forever?

  • Run forever:
  • Die out:

‐‐ || ‐‐

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 4

Root node, “patient 0” Start of epidemic d subtrees

h depth at node infected lim       

  P h

slide-5
SLIDE 5

= prob. there is an infected node at depth

 We need:

  • (based on and )

 Need recurrence for

→ = result of iterating

  • Starting at

(since )

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 5

No infected node at depth h from the root

d subtrees

slide-6
SLIDE 6

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 6

x f(x) 1 y=x=1 Going to first fixed point

0 0 1 1 1 1 ⋅ 1

y f x

  • is monotone decreasing on [0,1]!

When is this going to 0?

What do we know about f(x)?

slide-7
SLIDE 7

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 7

x f(x) 1 y=x y f x

For the epidemic to die out we need f(x) to be bellow y=x! So:

  • = expected # of people at we infect

Reproductive number

  • There is an

epidemic if

slide-8
SLIDE 8

 In this model nodes only go from

healthy  infected

 We can generalize to allow nodes to alternate

between healthy and infected state by:

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 8

slide-9
SLIDE 9
slide-10
SLIDE 10

Virus Propagation: 2 Parameters:

 (Virus) birth rate β:

  • probability than an infected neighbor attacks

 (Virus) death rate δ:

  • probability that an infected node heals

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 10

Infected Healthy N N1 N3 N2

  • Prob. β
  • Prob. δ
slide-11
SLIDE 11

 General scheme for epidemic models:

  • Each node can go through phases:
  • Transition probs. are governed by the model parameters

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

S…susceptible E…exposed I…infected R…recovered Z…immune

11

slide-12
SLIDE 12

 SIR model: Node goes through phases

  • Models chickenpox or plague:
  • Once you heal, you can never get infected again

 Assuming perfect mixing (the network is a

complete graph) the model dynamics is:

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 12

Susceptible Infected Recovered time Number of nodes

dI dt  SI I dS dt  SI dR dt  I

I(t) S(t) R(t)

slide-13
SLIDE 13

 Susceptible‐Infective‐Susceptible (SIS) model  Cured nodes immediately become susceptible  Virus “strength”: s = β / δ  Node state transition diagram:

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 13

Susceptible Infective

Infected by neighbor with prob. β Cured internally with prob. δ

slide-14
SLIDE 14

 Models flu:

  • Susceptible node

becomes infected

  • The node then heals

and become susceptible again

 Assuming perfect

mixing (complete graph):

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

Susceptible Infected

I SI dt dI    

I SI dt dS     

time Number of nodes

14

I(t) S(t)

slide-15
SLIDE 15

 SIS Model:

Epidemic threshold of an arbitrary graph G is τ, such that:

  • If virus strength s = β / δ < τ

the epidemic can not happen (it eventually dies out)

 Given a graph what is its epidemic threshold?

Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 15 10/18/2012

slide-16
SLIDE 16

 We have no epidemic if:

Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

β/δ < τ = 1/ λ1,A

► λ1,A alone captures the property of the graph!

(Virus) Birth rate (Virus) Death rate Epidemic threshold largest eigenvalue

  • f adj. matrix A

[Wang et al. 2003]

10/18/2012 16

slide-17
SLIDE 17

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 17

100 200 300 400 500 250 500 750 1000

Time Number of Infected Nodes

δ: 0.05 0.06 0.07 Oregon β = 0.001

β/δ > τ (above threshold) β/δ = τ (at the threshold) β/δ < τ (below threshold)

10,900 nodes and 31,180 edges

[Wang et al. 2003]

slide-18
SLIDE 18

 Does it matter how many people are

initially infected?

Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 10/18/2012 18

slide-19
SLIDE 19
slide-20
SLIDE 20

 Initially some nodes S are active  Each edge (u,v) has probability (weight) puv  When node v becomes active:

  • It activates each out‐neighbor v with prob. puv

 Activations spread through the network

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 20

0.4 0.4 0.4 0.4 0.2 0.2 0.2 0.4 0.3 0.3 0.3 0.3 0.3 0.3 0.2

e g f c b a d h i f g e

slide-21
SLIDE 21

 Independent cascade model

is simple but requires many parameters!

  • Estimating them from

data is very hard [Goyal et al. 2010]

 Solution: Make all edges have the same

weight (which brings us back to the SIR model)

  • Simple, but too simple

 Can we do something better?

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 21

0.4 0.4 0.4 0.4 0.2 0.2 0.2 0.4 0.3 0.3 0.3 0.3 0.3 0.3 0.2

e g f c b a d h i f g e

slide-22
SLIDE 22

 From exposures to adoptions

  • Exposure: Node’s neighbor exposes the

node to the contagion

  • Adoption: The node acts on the contagion

22

[KDD ‘12]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-23
SLIDE 23

 Exposure curve:

  • Probability of adopting new

behavior depends on the number

  • f friends who have already adopted

 What’s the dependence?

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 23

k = number of friends adopting

  • Prob. of adoption

k = number of friends adopting

  • Prob. of adoption

Diminishing returns: Viruses, Information Critical mass: Decision making … adopters

slide-24
SLIDE 24

 From exposures to adoptions

  • Exposure: Node’s neighbor exposes the node to

information

  • Adoption: The node acts on the information

 Adoption curve:

24

Prob(Infection) # exposures Probability of infection ever increases Nodes build resistance [KDD ‘12]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-25
SLIDE 25

 Marketing agency would like you

to adopt/buy product X

 They estimate the adoption

curve

 Should they expose you

to X three times?

 Or, is it better to expose you X,

then Y and then X again?

25

3

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-26
SLIDE 26

 Senders and followers of recommendations

receive discounts on products

 Data: Incentivized Viral Marketing program

  • 16 million recommendations
  • 4 million people, 500k products
  • [Leskovec‐Adamic‐Huberman, 2007]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 26

10% credit 10% off

[Leskovec et al., TWEB ’07]

slide-27
SLIDE 27

2 4 6 8 10 0.01 0.02 0.03 0.04 0.05 0.06 Incoming Recommendations Probability of Buying

Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 27

Probability of purchasing

0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 10 20 30 40

DVD recommendations (8.2 million observations) # recommendations received

[Leskovec et al., TWEB ’07]

Books

slide-28
SLIDE 28

 What is the effectiveness of subsequent

recommendations?

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 28

5 10 15 20 25 30 35 40 4 6 8 10 12x 10

  • 3

Exchanged recommendations Probability of buying 5 10 15 20 25 30 35 40 0.02 0.03 0.04 0.05 0.06 0.07 Exchanged recommendations Probability of buying

BOOKS DVDs

slide-29
SLIDE 29

 Group memberships spread over the

network:

  • Red circles represent

existing group members

  • Yellow squares may join

 Question:

  • How does prob. of joining

a group depend on the number of friends already in the group?

Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 29

[Backstrom et al. KDD ‘06]

10/18/2012

slide-30
SLIDE 30

 LiveJournal group membership

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 30

k (number of friends in the group)

  • Prob. of joining

[Backstrom et al., KDD ’06]

slide-31
SLIDE 31

 For viral marketing:

  • We see that node v receiving the i‐th

recommendation and then purchased the product

 For groups:

  • At time t we see the behavior of node v’s friends

 Good questions:

  • When did v become aware of recommendations
  • r friends’ behavior?
  • When did it translate into a decision by v to act?
  • How long after this decision did v act?

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 31

slide-32
SLIDE 32

 Twitter [Romero et al. ‘11]

  • Aug ‘09 to Jan ’10, 3B tweets, 60M users
  • Avg. exposure curve for the top 500 hashtags
  • What are the most important aspects of the shape
  • f exposure curves?
  • Curve reaches peak fast, decreases after!

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 32

slide-33
SLIDE 33

 Persistence of P is the

ratio of the area under the curve P and the area

  • f the rectangle of length

max(P), width max(D(P))

  • D(P) is the domain of P

 Persistence measures the

decay of exposure curves

 Stickiness of P is max(P).  Stickiness is the probability of

usage at the most effective exposure

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 33

slide-34
SLIDE 34

 Manually identify 8

broad categories with at least 20 HTs in each

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 34

Persistence  Idioms and Music have lower persistence than that of a random subset of hashtags of the same size  Politics and Sports have higher persistence than that of a random subset of hashtags of the same size True

  • Rnd. subset
slide-35
SLIDE 35

 Technology and Movies have lower stickiness than that of a

random subset of hashtags

 Music has higher stickiness than that of a random subset of

hashtags (of the same size)

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 35

slide-36
SLIDE 36

 Two sources of exposures

[Myers et al., KDD, 2012]

  • Exposures from the network
  • External exposures

36

External effects

[KDD ‘12]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-37
SLIDE 37

37

[KDD ‘12]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-38
SLIDE 38

 Given:

  • Network G
  • A set of node adoption

times (u, t) single piece of info

 Goal: Infer

  • External event profile:

λext(t) … # external exposures over time

  • Adoption curve:

38 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-39
SLIDE 39

 In social networks people post

links to interesting articles

  • You hear about an article from a friend
  • You read the article and then post it

 Data from Twitter

  • Complete data from Jan 2011:

3 billion tweets

  • Trace the emergence of URLs
  • Label each URL by its topic

39

[KDD ‘12]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-40
SLIDE 40

 Adoption of URLs across Twitter:  More in Myers et al., KDD, 2012

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 40

[KDD ‘12] max P(k) k at max P(k)

slide-41
SLIDE 41
slide-42
SLIDE 42

 So far we considered pieces of information as

independently propagating

 Do pieces of information

interact?

  • Does being exposed

to blue change the probability of talking about red?

42 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-43
SLIDE 43

 Goal: Model interaction between

many pieces of information

  • Some pieces of information may help

each other in adoption

  • Other may compete for attention

43 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-44
SLIDE 44

 You are reading posts on Twitter:

  • You examine posts one by one
  • Currently you are examining X
  • How does your probability of reposting X

depend on what you have seen in the past?

44

P(post X | exposed to X, Y1, Y2, Y3) = ?

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-45
SLIDE 45

 Goal: Model P(post X | exp. X, Y1, Y2, Y3)  Assume contagions are independent:  How many parameters?

2 Too many!

  • … history size
  • … number of contagions

45 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-46
SLIDE 46

 Goal: Model P(post X | exp. X, Y1, Y2, Y3)  First, assume:  Next, assume “topics”:

  • Each contagion

has a vector

  • Entry models how much belongs to topic
  • models the change in infection prob. given that

is on topic and exposure k‐steps ago was on topic

46 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

Prior infection prob. Interaction term (still has w2 entries!)

slide-47
SLIDE 47

 So we arrive to the full model:  And then:

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu 47

slide-48
SLIDE 48

 Model parameters:

  • … topic interaction matrix
  • , ... topic membership vector
  • ... Prior infection prob.

 Maximize data likelihood:

,,

  • … contagions X that resulted in infections
  • Solve using stochastic coordinate ascent:
  • Alternate between optimizing

and

48 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-49
SLIDE 49

 Data from Twitter

  • Complete data from Jan 2011: 3 billion tweets
  • All URLs tweeted by at least 50 users: 191k

 Task:

Predict whether a user will post URL X

  • Train on 90% of the data, test on 10%

 Baselines:

  • Infection Probability (IP):
  • IP + Node bias (NB):
  • Exposure curve (EC): = P(X | # times exposed to X)

49 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-50
SLIDE 50

 Bottom line: Model works great!

50 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-51
SLIDE 51

 How P(post u2| exp. u1) changes if …

  • u2 and u1 are similar/different in the content?
  • u1 is highly viral?

51

Observations:  If u1 is not viral, this boost u2  If u1 is highly viral, this kills u2 BUT: Only if u1 and u2 are

  • f low content

similarity (LCS) else, u1 helps u2

Relative change in infection prob.

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-52
SLIDE 52

 Modeling contagion interactions

  • 71% of the adoption probability comes

from the topic interactions!

  • Modeling user bias does not matter

 Detecting external events

  • Overall, 69% exposures on Twitter come from the

network and 29% from external sources

  • About the same for URLs as well as hashtags!

52 10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-53
SLIDE 53

 Methodology:

  • Each node of the cascade is a blog

post that belongs to a blog

  • For each blog compute the baseline

sentiment (over all its posts)

  • Subjectivity: deviation in sentiment from

the baseline (in positive or negative direction)

 Question:

  • Does sentiment flow in cascade?

53

Information flow [ICWSM ‘11]

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu

slide-54
SLIDE 54

 Cascades “heats” up early, then cool off

54

[ICWSM ‘11]

Subjectivity of the child and the parent are correlated. Sentiment flows!

10/18/2012 Jure Leskovec, Stanford CS224W: Social and Information Network Analysis, http://cs224w.stanford.edu