Uploaded by Lam Tommy

Lecture6

advertisement
COMP3121 Social and
Collaborative Computing
Dan Wang
Department of Computing,
The Hong Kong Polytechnic University
March 29, 2023
The Hong Kong Polytechnic University
1
Hubs and Authorities (中樞和權威)
March 29, 2023
The Hong Kong Polytechnic University
2
A basic problem of search engine

A webpage can only show 6 – 7 search results,
yet a typical search engine can return 1 billion
results

How to show a few “right” results out of a huge
number of candidates
March 29, 2023
The Hong Kong Polytechnic University
3
Information retrieval (IR)


IR has been there in 1940’s: e.g., used in library,
search for information/books
Conventional IR:



Information (e.g., books) have regular format
Customer: librarians, knowledgeable and corporate
Search is based on keywords, where the content
contains the keywords
March 29, 2023
The Hong Kong Polytechnic University
4
Searching for books

The content contains
the book title

What about
searching for The
Hong Kong
Polytechnic
University?

Still content
matching?
March 29, 2023
The Hong Kong Polytechnic University
5
Searching for general information

Why Google
returns the
homepage of The
Hong Kong
Polytechnic
University?
March 29, 2023
The Hong Kong Polytechnic University
6
Searching for general information

Why Google
returns the
homepage of The
Hong Kong
Polytechnic
University?

Maybe a lot of links
are pointed to
PolyU? – hidden
knowledge in the
linkage information
March 29, 2023
The Hong Kong Polytechnic University
7
Information retrieval

Use the (hidden) knowledge (e.g., relationship
and the structure) provided by the linkage
information is a big progress (of modern search
engine) in information retrieval (as compared to
conventional IR)

Irrelevant to content!
March 29, 2023
The Hong Kong Polytechnic University
8
Recommend for restaurants
A
March 29, 2023
B
C
The Hong Kong Polytechnic University
D
9
Recommend for restaurants
A
B
C
D
3
3
1
2
2
Can not
tell the
difference
March 29, 2023
The Hong Kong Polytechnic University
10
Recommend for restaurants
A
B
C
D
3
3
1
2
2
8
6
6
The “quality” of recommenders
March 29, 2023
The Hong Kong Polytechnic University
7
Can not
tell the
difference
11
Recommend for restaurants
A
B
C
D
3
3
1
2
2
8
6
6
The “quality” of recommenders
March 29, 2023
The Hong Kong Polytechnic University
7
21
20
6
15
13
Can not
Can now
tell the
tell the
difference difference
12
The principle of repeated improvement

Assume that the keyword is newspaper

The left is the homepage of newspapers
The right is the # of votes – representing recognition

March 29, 2023
The Hong Kong Polytechnic University
13
The principle of repeated improvement


We can future re-weight the quality of the recommenders
Then we re-weight the webpages given the re-weighting
of the recommenders
March 29, 2023
The Hong Kong Polytechnic University
14
The principle of repeated improvement

This process can be repeated continuously
March 29, 2023
The Hong Kong Polytechnic University
15
Hubs and Authorities

Two properties of a webpage



being pointed – high authority, good recognition
Pointed to others – strong hub
The HITS algorithm (Hyperlink-Induced Topic
Search)


Compute the values of the hubs
Compute the values of the authorities
March 29, 2023
The Hong Kong Polytechnic University
16
auth(p) and hub(p)

Input: a directed graph
Initialization: for every p, auth(p)=1, hub(p)=1

Authority Update Rule:



Hub Update Rule:


For each page p, update auth(p) to be the sum of the hub
scores of all pages that point to it.
For each page p, update hub(p) to be the sum of the
authority scores of all pages that it points to.
Repeat k times
March 29, 2023
The Hong Kong Polytechnic University
17
Example

Compute the authority and hub scores of the
following graph, run for 3 rounds
March 29, 2023
The Hong Kong Polytechnic University
18
Example

Compute the authority and hub scores of the
following graph, run for 3 rounds
March 29, 2023
The Hong Kong Polytechnic University
19
Example

Compute the authority and hub scores of the
following graph, run for 3 rounds
March 29, 2023
The Hong Kong Polytechnic University
20
Example

Compute the authority and hub scores of the
following graph, run for 3 rounds

When to stop?
March 29, 2023
The Hong Kong Polytechnic University
21
Normalization and Convergence


The purpose of auth and hub is their relative value
Normalization:



Divide each authority score by the sum of all authority scores
Divide each hub score by the sum of all hub scores
It can be proven that when k goes to infinity, the scores
converge to a limit
March 29, 2023
The Hong Kong Polytechnic University
22
Summary

In a social network with the relationship of “cited by” and
“recommend”, each node has two roles: authority and
hub.

Hub and authority can be materialized by the HITS
algorithm

Repeated improvement is the key spirit of HITS
March 29, 2023
The Hong Kong Polytechnic University
23
PageRank
March 29, 2023
The Hong Kong Polytechnic University
24
PageRank: An importance Metric


PageRank has the same spirit with HITS
Each page divides its current PageRank equally across
its out-going links, and passes these equal shares to the
pages it points to.
March 29, 2023
The Hong Kong Polytechnic University
25
The PageRank algorithm



In a network with n nodes, we assign all nodes the same
initial PageRank, set to be 1/n.
We choose a number of steps k.
Basic PageRank Update Rule:



Each page divides its current PageRank equally across its outgoing links
Passes these equal shares to the pages it points to. (If a page has
no out-going links, it passes all its current PageRank to itself.)
Each page updates its new PageRank to be the sum of the
shares it receives.
March 29, 2023
The Hong Kong Polytechnic University
26
PageRank: An importance Metric

After 70 iterations: A=0.615, B=0.923, C=D=1.231
March 29, 2023
The Hong Kong Polytechnic University
27
Summary

In a social network with the relationship of “cited by” and
“recommend”, the importance of each node can be
decided by the number of recommenders, and the
importance of the recommenders

Such importance can be materialized by the PageRank
algorithm

The key spirit of PageRank is, based on the structure of
the graph, repeated improvement
March 29, 2023
The Hong Kong Polytechnic University
28
Game Theory (博弈)
Modern game theory started by the works of von
Neumann in 1928
March 29, 2023
The Hong Kong Polytechnic University
29
Game theory

Still emphasize that “scenario  game 
solution”


Math people emphasize more on “game  solution”
But also terminologies, concepts, math, etc
March 29, 2023
The Hong Kong Polytechnic University
30
Game
令狐沖:我要退出江湖。
任我行:有人的地方就有江湖,你怎麽退出啊?
--- 金庸《笑傲江湖》
March 29, 2023
The Hong Kong Polytechnic University
31
Starting from an example

Presentation or exam



Assume you have two things to do before a deadline
tomorrow: study for exam or prepare presentation, and
you can do only one
Study for exam is predictable, if you study, your grade
will be 92, no study, 80
Presentation depends on both you and your partner




If both prepare presentation, each of you will get 100
If only one prepare presentation, each of you will get 92
If none of you prepare presentation, each of you will get 84
What do you do? (we assume that you and your partner
make decisions independently)
March 29, 2023
The Hong Kong Polytechnic University
32
Game between Presentation and Exam

Assume that both of you try to maximize your grades



You and your partner all prepare presentation  average
grade is (80 + 100) / 2 = 90
You and your partner all study the exam  average grade
is (92 + 84) / 2 = 88
One studies exam and one prepares presentation 
 The one prepares presentation (80 + 92) / 2 = 86
 The one studies exam (92 + 92) / 2 = 92
March 29, 2023
The Hong Kong Polytechnic University
33
Payoff Table/Payoff Matrix
The first one is your pay-off, the second one is your
partners pay-off
March 29, 2023
The Hong Kong Polytechnic University
34
Basic ingredients of a Game



A set of participants (at least two), whom we call the
players
Each player has a set of options for how to behave; we
will refer to these as the player’s possible strategies
For each choice of strategies, each player receives a
payoff


The payoff depends on the strategies adopted by others
When we can clearly define these three ingredients,
we say we have a game
March 29, 2023
The Hong Kong Polytechnic University
35
Basic ingredients of a Game

Strategy profile (or strategy combination), is a set of
strategies for all players which fully specifies all actions in
a game.


A strategy profile must include one and only one strategy for
every player.
Notation for payoff: P1(S, T), P2(S, T)
March 29, 2023
The Hong Kong Polytechnic University
36
Assumptions for game reasoning

We probably ask: presentation or exam?
March 29, 2023
The Hong Kong Polytechnic University
37
Assumptions for game reasoning

Assumptions on behaviors


Every player understands the structure of the game,
e.g., pay-off matrix
Every player is rational





Given choices, can tell which one is better
Consistent, i.e., A > B, B > C, and he must say, A > C
Maximize his own profit
Know that others also act like this
Independent


March 29, 2023
Make decision independently, no coalition, etc
Most of the time: win-win situation, only one type of game is
zero-sum, i.e., 你死我活
The Hong Kong Polytechnic University
38
Exam-Presentation game: how to choose?



Strictly dominant strategy: When a player has a strategy
that is strictly better than all other options regardless of
what the other player does, we will refer to it as a strictly
dominant strategy
By our assumptions, every player will select strictly
dominant strategy if there is one.
Study the exam is the strictly dominant strategy for both
March 29, 2023
The Hong Kong Polytechnic University
39
Exam-Presentation game: how to choose?



It is natural if you ask a question, why not (presentation,
presentation)
It cannot stable there, the two players have the incentive
to change if it is at (presentation, presentation)
Our reasoning is rigid, otherwise it violates our
assumptions (players are rational)
March 29, 2023
The Hong Kong Polytechnic University
40
Prisoner’s dilemma



Suppose that two suspects have been apprehended by the
police and are being interrogated in separate rooms
The police strongly suspect that these two individuals are
responsible for a robbery, but there is not enough evidence
to convict either of them of the robbery.
Each of the suspects is told




If you confess, and your partner doesn‘t, then you will be released
and your partner will be charged and sent to prison for 10 years.
If you both confess, then you will both be convicted and sent to
prison for 4 years
Finally, if neither of you confesses, then you will be charged for 1
year of resistance.
Do you want to confess or not?
March 29, 2023
The Hong Kong Polytechnic University
41
Prisoner’s dilemma

C: confess, NC: non-confess

The strictly dominant strategy for both suspect 1 and 2 is
confess
Even though if two NC, they will be sentenced less

When there is selfishness, cooperation is difficult
March 29, 2023
The Hong Kong Polytechnic University
42
Performance enhancing drugs
March 29, 2023
The Hong Kong Polytechnic University
43
Performance enhancing drugs


Also called arms races game: no good or even harmful
for each one internally, but to make sure that each is
competitive, have to stay in the competition.
If we don’t develop weapons, the money can go to areas
to benefit people …
March 29, 2023
The Hong Kong Polytechnic University
44
A summary

Game ingredients:




Game assumptions:


Two players
A set of strategies
Pay-off functions
Rational
Gaming reasoning basics:

Dominant strategy
March 29, 2023
The Hong Kong Polytechnic University
45
Download