Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -43,10 +43,8 @@ topics, probs = fit_transform(topic_model, tiktok)
|
|
| 43 |
#placeholder = st.empty()
|
| 44 |
#text_input = placeholder.text_area("Enter product topic here", height=300)
|
| 45 |
text_input = st.text_area("Enter product topic here", value = "motor")
|
| 46 |
-
print(text_input)
|
| 47 |
-
print(type(text_input))
|
| 48 |
|
| 49 |
-
top_n = st.sidebar.slider("Select a number of
|
| 50 |
|
| 51 |
similar_topics, similarity = topic_model.find_topics(text_input, top_n=top_n)
|
| 52 |
|
|
|
|
| 43 |
#placeholder = st.empty()
|
| 44 |
#text_input = placeholder.text_area("Enter product topic here", height=300)
|
| 45 |
text_input = st.text_area("Enter product topic here", value = "motor")
|
|
|
|
|
|
|
| 46 |
|
| 47 |
+
top_n = st.sidebar.slider("Select a number of topics", 1, 30, 5, 1)
|
| 48 |
|
| 49 |
similar_topics, similarity = topic_model.find_topics(text_input, top_n=top_n)
|
| 50 |
|