• No results found

5.4 Search of semantic relationships

5.4.4 Extended search algorithm

Here is presented an improved algorithm for search of indirect relationships in WordNet, where a new set R of relationship types is introduced and fuzzy relationships are considered. Specifically, 14 types of relationships listed below are considered, so that the output of the algorithm is a vector of 14 values denoting the weight with which each of them holds.

ˆ equality ˆ synonymy ˆ hypernymy ˆ hyponymy ˆ coordination ˆ holonymy ˆ meronymy ˆ co-occurrence ˆ similarity ˆ derivation ˆ antonymy ˆ domain ˆ indomain ˆ codomain

This method is based on what are hereby referred to as explorations of the WordNet synsets graph, whose set of nodes will be here denoted with S. Each exploration α starts from a set Iα ⊆ S of synsets, each s having

assigned a positive score wα(s) of 1 or less: these are the first synsets to be

explored. When exploring a synset s, for each s0 of those related to it by

certain pointer types and not previously explored, a score rα(s0) = rα(s)−εR

is assigned, where εR ≥ 0 is a decay parameter: synsets whose this score

is greater than 0 will be explored in turn, the others are discarded. In the end, an exploration yields a set Eα ⊆ S of explored nodes, each with a score

given by rα.

Given two input words waand wb, the steps performed by the algorithm

124 Chapter 5. Domain-Independent Semantic Relatedness Model algorithm and make the algorithm early terminate if given conditions are met. In the final output vector, weight for each relationship type is assumed to be 0 if not assigned.

ˆ If the two words are identical, terminate the algorithm by returning equality with weight 1.

ˆ Extract sets Sa and Sb of synsets for wa and wb. If the two share at

least one synset, return synonymy with weight 1. If at least one of the two sets is empty, return a null vector.

ˆ Two explorations ηa and ηb starting from Sa and Sb with score 1 for

all synsets are performed, each considering hypernymy and instance hypernymy pointers, with distinct decay parameters of εhyp and εinst.

If in ηa has been explored at least one synset in Sb, set score for hy-

pernymy to the maximum score within such synsets. Conversely, if in ηb at least one synset of Sa was found, do the same for hyponymy.

Only if both these conditions fail, the intersection between the sets of explored nodes of ηa and ηb is checked: if contains at least one

synset, consider the one s for which rηa(s)· rηb(s) is maximum and

use this value as score for coordination relation, indicating that the two input words have a common hypernym.

ˆ Similar steps are now taken with holonymy in place of hypernymy. Two explorations θa and θb considering all three types of holonymy

pointers are started from Sa and Sb with all synsets having score

1; decay parameters for part, member and substance holonymy are respectively εpart, εmemb, εsubst. If at least one synset explored in θawas

also explored in ηb, holonymy relationship is assigned with weight

equal to the maximum score of these synsets within θa. Symmetrically,

weight meronymy as the highest score among synsets explored in θb which were also explored in ηa, if any. If neither of these two

relationships hold, find the synset explored within both θa and θb for

which the product of its scores given by the two is higher and, if any, use this product as weight for co-occurrence relationship, expressing in practice being part of a same entity.

ˆ Explorations σa and σb are started from all synsets explored respec-

5.4. Search of semantic relationships 125

scores for initial synsets are taken (∀s ∈ Iσx : rσx(s) = rηx(s)): in

these two explorations “verb group” and “similarity” pointers are fol- lowed, with respective decay parameters εverbg and εsim. These two

relationships are considered together, as they both indicatively rep- resent similarity between concepts, which are verbs in the first case and adjectives in the second. If one or more synsets are found in both explorations, excluding their initial synsets (for which relevant rela- tionships have already been found), weight for similarity relationship is set to the product of σa and σb scores of the synset for which it is

maximum.

ˆ All couples of synsets explored in ηa and ηb are checked for lexical

relationships of type “derivationally related form”, “derived from ad- jective” and “participle” between words of synsets of one and words of synsets of the other. Weight for derivation relationship is set to the maximum product of weights of synsets across the two sets with words related by these relationships: this type of relationship generally links words with a common morphology.

ˆ Similarly to above, the hypernym synsets are checked for antonymy relationships between words in a set and words of the other. Weight for antonymy is the maximum product of weights of synsets across Eηa and Eηb with antonym words.

ˆ For last, “member of domain” relationships are considered. Explo- rations δa and δb starting from synsets explored in ηa and ηb are run,

following all three types of such pointers (topic, region and usage) with a unique decay factor εdom. Similarly to hyponymy/meronymy,

if one or more synsets are shared between Eδa and Eηb, domain re-

lationship is weighted according to the maximum score within δa of

these synsets, while indomain relationship is weighted with the max- imum score in δb of synsets also explored in ηa, if any. If none of these

two relationships holds, codomain relationship weight is set to the maximum product of scores in δaand δb of non-initial synsets explored

in both, if any.

The algorithm is parameterized by the decay factors referenced along the described steps and summarized in Table 5.2 along with their default values. These parameters have been tuned through some preliminary tests, training

126 Chapter 5. Domain-Independent Semantic Relatedness Model Table 5.2 – Decay parameters defined in the algorithm with their values

Exploration Pointer type Decay parameters

hypernyms (η) hypernym εhyp = 0.2

instance hypernym εinst = 0

holonyms (θ)

part holonym εpart = 0.2

member holonym εmemb = 0.2

substance holonym εsubst = 0.4

similar synsets (σ) verb group εverbg = 0.2 similar to εsim = 0.2

domain of synset (δ) domain (all 3 types) εdom = 0.4

the search algorithm on lists of word pairs with pre-assigned relatedness or similarity scores, cited in §5.4.2. For each pair, we compared the reference scores given by these lists with the maximum value of the output vector from the search algorithm across a subset of relationships, having picked those deemed to best represent the intended concepts of “relatedness” and “similarity”.

In general, the proposed algorithm has been designed to find various types of indirect relationships, even involving pointers of multiple types. The set of pointer types defined in WordNet and used in the previous algo- rithm is reduced to a smaller set of relevant relationship classes, grouping together similar types and defining new ones which can only be obtained by composition of primitive relationships.