nltk pos_tag usage

后端 未结 3 1905
闹比i
闹比i 2021-01-12 04:41

I am trying to use speech tagging in NLTK and have used this command:

>>> text = nltk.word_tokenize(\"And now for something completely different\")
         


        
3条回答
  •  Happy的楠姐
    2021-01-12 05:32

    If you don't want to use the downloader gui, you can just use the following commands in a python or ipython shell:

    import nltk
    nltk.download('punkt')
    nltk.download('maxent_treebank_pos_tagger')
    

提交回复
热议问题