Skip to content

Commit d1c6340

Browse files
committed
Always normalise output to lowercase
Avoid eg "President" in addition to "president", same with "Death".
1 parent 4bd4cd5 commit d1c6340

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

word_forms/word_forms.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,8 @@ def get_word_forms(word):
106106
pos = lemma.synset().pos()
107107
if pos == "s":
108108
pos = "a"
109-
related_words_dict[pos].add(lemma.name())
110-
# TODO: This will add the plural of eg "politics", which according to inflect is "politicss"
109+
related_words_dict[pos].add(lemma.name().lower())
110+
111111
for noun in related_words_dict["n"].copy():
112112
related_words_dict["n"].add(inflect.engine().plural_noun(noun))
113113

0 commit comments

Comments
 (0)