0

Would someone please explain the difference between the two Python modules nltk.parse.recursivedescent and nltk.parse.rd?

It seems that the former is automatically included when I import NLTK into iPython, but I am interested in using one of the methods included only in the latter (nbest_parse), which is mentioned in the the 2009 print edition of the book "Natural Language Processing with Python" but is omitted in the current on-line version. Is this method outdated, and what would I use in its place to see multiple options for parsing an ambiguous sentence without falling into an infinite loop as with "parse_all".

Thanks in advance.

Steven Barkin
  • 99
  • 1
  • 2
  • 8
  • What version of the NLTK are you using? The current version has `nltk.parse.recursivedescent` and `nltk.parse.RecursiveDescentParser` (note the capitalization), but no `nltk.parse.rd`. – alexis Nov 02 '15 at 16:57
  • This is a link to the nltk.parse.rd that I am referring to: http://www.nltk.org/_modules/nltk/parse/rd.html The web page indicates version 3.0 (same version as for the other methods mentioned here) and this contains the "nbest_parse" method that I am seeking to use (and which the hardcopy book uses), but I wonder if this method has been deprecated and what to use instead? – Steven Barkin Nov 03 '15 at 01:23

0 Answers0