spaCy Documentation for [ orth , pos , tag, lema and text ]

前端 未结 2 1451
夕颜
夕颜 2021-02-13 19:34

I am new to spaCy. I added this post for documentation and make it simple for new starters as me.

import spacy
nlp = spacy.load(\'en\')
doc = nlp(u\'KEEP CALM be         


        
2条回答
  •  别跟我提以往
    2021-02-13 19:59

    1) When you print word, you basically print Token class from spacy which is set to print out string from the class. You can see more here. So it's different from printing out word.orth_ or word.text where these will print out string directly.

    2) I'm not sure about word.orth_, seems like it is word.text for most cases. For word.lemma_, it's the lemmatize of the given word e.g. is, am, are will map to be in word.lemma_.

提交回复
热议问题