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