From f0a7c99554db884aa602120d3a709f6f77419639 Mon Sep 17 00:00:00 2001 From: Matthew Honnibal Date: Thu, 27 Aug 2015 10:26:19 +0200 Subject: [PATCH] * Relax rule-requirement in lemmatizer --- spacy/lemmatizer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spacy/lemmatizer.py b/spacy/lemmatizer.py index 05029391b..5e08e80a4 100644 --- a/spacy/lemmatizer.py +++ b/spacy/lemmatizer.py @@ -35,7 +35,7 @@ class Lemmatizer(object): pos = 'adj' else: return string - lemmas = lemmatize(string, self.index[pos], self.exc[pos], self.rules[pos]) + lemmas = lemmatize(string, self.index[pos], self.exc[pos], self.rules.get(pos, [])) return min(lemmas) def noun(self, string):