Package TEES :: Package ExampleBuilders :: Package FeatureBuilders :: Module WordNetFeatureBuilder :: Class WordNetFeatureBuilder
[hide private]

Class WordNetFeatureBuilder

source code

FeatureBuilder.FeatureBuilder --+
                                |
                               WordNetFeatureBuilder

Instance Methods [hide private]
 
__init__(self, featureSet=None) source code
 
pennPOSToWordNet(self, pos) source code
 
getSynset(self, text, wordNetPos) source code
 
getHypernyms(self, synset) source code
 
getTokenFeatures(self, tokenText, pennPos)
Token features are features describing an isolated word token.
source code

Inherited from FeatureBuilder.FeatureBuilder: getEntityType, getPOSSuperType, getTokenAnnotatedType, normalizeFeatureVector, setFeature, setFeatureVector, setTag

Method Details [hide private]

__init__(self, featureSet=None)
(Constructor)

source code 
Parameters:
  • featureSet - feature ids
Overrides: FeatureBuilder.FeatureBuilder.__init__
(inherited documentation)

getTokenFeatures(self, tokenText, pennPos)

source code 

Token features are features describing an isolated word token. These subfeatures are often merged into such features like n-grams. This method produces and caches a set of feature names for a token in the sentenceGraph sentence. The various flags can be used to choose which attributes will be included in the feature name list.

Parameters:
  • token - a word token
  • sentenceGraph - the sentence to which the token belongs
Overrides: FeatureBuilder.FeatureBuilder.getTokenFeatures
(inherited documentation)