2

给定一个单词,是否可以使用 NLTK 将该单词转换为特定的词性 (POS) 形式?例如,给定单词“run”,我可以要求 NLTK 将其转换为以下任何一种:

VBZ: runs, as in "George runs to the store."
VBD: ran,  as in "George ran to the store."
VB:  run,  as in "George wants to run."

等等如果是的话,名词也一样吗?例如:

NN:  run,  as in "George wants to run."
NNS: runs, as in "George went for two runs."
NNP: Run,  as in "George had dinner at Run."
4

1 回答 1

4

你应该尝试模式

它具有以下功能:

  • 复数+单数
  • 比较+最高级
  • 动词变位
  • 量化

希望这可以帮助。

于 2013-09-01T05:51:14.447 回答