vladkrylov / english_text_learning

0 stars 0 forks source link

python natural language processing #1

Open vladkrylov opened 10 years ago

vladkrylov commented 10 years ago

The aim is to recognize parts of speech in the text.

Tools: NLTK Framework Book Natural Language Processing with Python

vladkrylov commented 10 years ago

list of all NLTK tags:

nltk.help.upenn_tagset()
vladkrylov commented 10 years ago

Some example of wrong verbs recognition:

*We prepared a new game for you. Its name is Hangman. You can choose your level and you can play. When the game is over, you can record your top score. You can play the game here. We hope you will enjoy the game. You can write in the comments if you like the game. Have a nice day,

Read more: http://www.newsinlevels.com/products/new-game-hangman-level-3/*

127.0.0.1 - - [16/Sep/2014 21:46:03] "GET /task/34 HTTP/1.1" 200 -

* Restarting with reloader

{0: (u'We', 'PRP'), 1: (u'prepared', 'VBD'), 2: (u'a', 'DT'), 3: (u'new', 'JJ'), 4: (u'game', 'NN'), 5: (u'for', 'IN'), 6: (u'you', 'PRP'), 7: (u'.', '.'), 8: (u'Its', 'NNS'), 9: (u'name', 'VBD'), 10: (u'is', 'VBZ'), 11: (u'Hangman', 'NNP'), 13: (u'You', 'PRP'), 14: (u'can', 'MD'), 15: (u'choose', 'VB'), 16: (u'your', 'PRP$'), 17: (u'level', 'NN'), 18: (u'and', 'CC'), 21: (u'play', 'VB'), 23: (u'When', 'WRB'), 24: (u'the', 'DT'), 27: (u'over', 'IN'), 28: (u',', ','), 31: (u'record', 'VB'), 33: (u'top', 'JJ'), 34: (u'score', 'NN'), 41: (u'here', 'RB'), 44: (u'hope', 'VBP'), 46: (u'will', 'MD'), 47: (u'enjoy', 'VB'), 53: (u'write', 'VB'), 54: (u'in', 'IN'), 56: (u'comments', 'NNS'), 57: (u'if', 'IN'), 59: (u'like', 'VBP'), 63: (u'Have', 'NNP'), 65: (u'nice', 'JJ'), 66: (u'day', 'NN'), 68: (u'Read', 'NNP'), 69: (u'more', 'RBR'), 70: (u':', ':'), 71: (u'http', 'NN'), 73: (u'//www.newsinlevels.com/products/new-game-hangman-level-3/', 'JJ')}