Exemplo n.º 1
0
 def testGetPhraseTags(self):
     s = Sentence(TEST_TOKENS)
     self.assertListEqual(list(s.phraseTags()), [
         'NP', 'NP', 'NP', 'NP'
     ])
     self.assertListEqual(list(s.phraseTags(1, 6)), [
         'NP', 'NP'
     ])
Exemplo n.º 2
0
 def testGetPhraseTags(self):
     s = Sentence(TEST_TOKENS)
     self.assertListEqual(list(s.phraseTags()), ['NP', 'NP', 'NP', 'NP'])
     self.assertListEqual(list(s.phraseTags(1, 6)), ['NP', 'NP'])