Package nltk_lite :: Package chunk :: Class ChunkParseI
[hide private]
[frames] | no frames]

Class ChunkParseI

source code

  object --+    
           |    
parse.ParseI --+
               |
              ChunkParseI
Known Subclasses:
regexp.Regexp, regexp.RegexpChunk

A processing interface for identifying non-overlapping groups in unrestricted text. Typically, chunk parsers are used to find base syntactic constituants, such as base noun phrases. Unlike ParseI, ChunkParseI guarantees that the parse method will always generate a parse.

Instance Methods [hide private]
 
parse(self, tokens)
Find the best chunk structure for the given tokens and return a tree
source code

Inherited from parse.ParseI: get_parse, get_parse_dict, get_parse_list, get_parse_probs

Inherited from object: __delattr__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

parse(self, tokens)

source code 

Find the best chunk structure for the given tokens and return a tree

Parameters:
  • tokens (list of tuple) - The list of (word, tag) tokens to be chunked.
Overrides: parse.ParseI.parse