Spaces:
Runtime error
Runtime error
azaninello
commited on
Commit
•
7398647
1
Parent(s):
e51f461
Update app.py
Browse files
app.py
CHANGED
@@ -55,7 +55,7 @@ def search_engine_collocations(target = 'scarto' , colloc = 'azioni' , nlp = nlp
|
|
55 |
for n,r in enumerate(verbs_fdist.most_common()):
|
56 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
57 |
|
58 |
-
return f"Ho trovato {len(verbs)} azioni legate a '{target}'\n{stringed_results}"
|
59 |
|
60 |
elif verbs == []:
|
61 |
return f"Non ho trovato azioni legate a '{target}'"
|
@@ -68,7 +68,7 @@ def search_engine_collocations(target = 'scarto' , colloc = 'azioni' , nlp = nlp
|
|
68 |
for n,r in enumerate(adj_fdist.most_common()):
|
69 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
70 |
|
71 |
-
return f"Ho trovato {len(adjectives)} caratteristiche legate a '{target}'\n{stringed_results}"
|
72 |
|
73 |
elif adjectives == []:
|
74 |
return f"Non ho trovato caratteristiche legate a '{target}'"
|
@@ -81,7 +81,7 @@ def search_engine_collocations(target = 'scarto' , colloc = 'azioni' , nlp = nlp
|
|
81 |
for n,r in enumerate(nouns_fdist.most_common()):
|
82 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
83 |
|
84 |
-
return f"Ho trovato {len(nouns)} concetti legati a '{target}'\n{stringed_results}"
|
85 |
|
86 |
elif nouns == []:
|
87 |
return f"Non ho trovato concetti legati a '{target}'"
|
|
|
55 |
for n,r in enumerate(verbs_fdist.most_common()):
|
56 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
57 |
|
58 |
+
return f"Ho trovato {len(verbs)} azioni legate a '{target}'\n{stringed_results}\n\n"
|
59 |
|
60 |
elif verbs == []:
|
61 |
return f"Non ho trovato azioni legate a '{target}'"
|
|
|
68 |
for n,r in enumerate(adj_fdist.most_common()):
|
69 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
70 |
|
71 |
+
return f"Ho trovato {len(adjectives)} caratteristiche legate a '{target}'\n{stringed_results}\n\n"
|
72 |
|
73 |
elif adjectives == []:
|
74 |
return f"Non ho trovato caratteristiche legate a '{target}'"
|
|
|
81 |
for n,r in enumerate(nouns_fdist.most_common()):
|
82 |
stringed_results += str(n+1) + ': ' + str(r) + '\n\n'
|
83 |
|
84 |
+
return f"Ho trovato {len(nouns)} concetti legati a '{target}'\n{stringed_results}\n\n"
|
85 |
|
86 |
elif nouns == []:
|
87 |
return f"Non ho trovato concetti legati a '{target}'"
|