Module detect
source code
Functions for detecting a token's features. Features are stored in a dictionary
which maps feature names to feature values.
(Not yet ported from NLTK: A feature encoder can then be used to translate the
feature dictionary into a homogenous representation (such as a sparse
boolean list), suitable for use with other processing tasks.)
|
feature(functions)
Return a feature detector that applies the supplied functions to each
token. |
source code
|
|
|
get_features(str)
takes a string returns a list of tuples (feature type, feature value) |
source code
|
|
|
|
|
|
|
|
Return a feature detector that applies the supplied functions to each
token.
- Parameters:
functions (dictionary of functions) - one or more functions in one string argument to compute the
features.
|