mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-11 04:08:09 +03:00
Avoid lemmatizing inappropriate tags in English lemmatizer
This commit is contained in:
parent
d528b6e36d
commit
c15d8278cb
|
@ -24,6 +24,8 @@ class Lemmatizer(object):
|
|||
univ_pos = 'adj'
|
||||
elif univ_pos == PUNCT:
|
||||
univ_pos = 'punct'
|
||||
else:
|
||||
return set([string.lower()])
|
||||
# See Issue #435 for example of where this logic is requied.
|
||||
if self.is_base_form(univ_pos, morphology):
|
||||
return set([string.lower()])
|
||||
|
|
Loading…
Reference in New Issue
Block a user