Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -34,7 +34,7 @@ def get_nouns(text):
|
|
34 |
noun_p=blob_n.noun_phrases
|
35 |
json_object[f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}']={'sentence':sen_list[cnt],'nouns':noun_p}
|
36 |
for noun in noun_p:
|
37 |
-
if noun_list
|
38 |
noun_list[noun].append(f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}')
|
39 |
else:
|
40 |
noun_list[noun]=[f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}']
|
|
|
34 |
noun_p=blob_n.noun_phrases
|
35 |
json_object[f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}']={'sentence':sen_list[cnt],'nouns':noun_p}
|
36 |
for noun in noun_p:
|
37 |
+
if noun in list(noun_list.keys()):
|
38 |
noun_list[noun].append(f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}')
|
39 |
else:
|
40 |
noun_list[noun]=[f'{a}{cont_list[b]}{cont_list[c]}{cont_list[d]}']
|