generalize

Purpose

Finds documents that contain hypernym of the specified level of the argument term(s).

Y is hypernym of X, if X is a kind of Y

This function is an alias for the hypernym function.

Syntax

generalize([level], term, …​)

Arguments

The first optional argument level is an integer, specifies distance between the function’s argument and the function’s output in the semantic net used (WordNet). The default value of level is 1.

The word itself (given as an argument) is not searched for, only the hypernyms of the word are searched.

Returned Value

Documents matching the query.

Examples

generalize(village) = generalize(1, village) matches the word community that is a direct hyperonym of village, i.e. the distance between village and 'community' is 1.

generalize(2, village) matches the word assemblage, because it is a direct hypernym of community that is a direct hyperonym of village, i.e. the distance between village and assemblage is 2.