diff --git a/backend/app/analysis/parts_of_speech.py b/backend/app/analysis/parts_of_speech.py index 298a067..74d8667 100644 --- a/backend/app/analysis/parts_of_speech.py +++ b/backend/app/analysis/parts_of_speech.py @@ -168,7 +168,13 @@ def get_parts_of_speech_tags(text): 'noun': ['NN', 'NNS', 'NNP', 'NNPS'], 'verb': ['VB', 'VBD', 'VBG', 'VBN', 'VBP', 'VBZ'], 'adverb': ['RB', 'RBR', 'RBS'], - 'adjective': ['JJ', 'JJR', 'JJS'] + 'adjective': ['JJ', 'JJR', 'JJS'], + 'adposition': ['IN', 'TO', 'PRT'], + 'conjunctive': ['CC', 'CONJ'], + 'pronouns': ['PRP', 'PRON'], + 'determiner': ['DT', 'DET'], + 'numeral': ['NUM'], + 'other': ['X'] } @@ -262,7 +268,7 @@ def punct_in_word(word): """ Checks if there are punctuations in the word """ - quotes = ["“", '"', "'", "’", ".", "?", "!"] + quotes = ["“", '"', "'", "’", ".", "?", "!", ":", ";", "-", ","] for quote in quotes: if quote in word: return True