cakiki commited on
Commit
755c3f2
1 Parent(s): 8c0cea8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -6
app.py CHANGED
@@ -7,11 +7,11 @@ st.set_page_config(
7
  layout="centered"
8
  )
9
 
10
- indexes = {"shoe-sizes": LuceneSearcher("index/cmv'-shoe-sizes-should-be-the-same-for-both-men-and-women"),
11
- "social-media": LuceneSearcher("index/cmv'-social-media-is-the-most-destructive-addiction-in-our-society"),
12
- "depression": LuceneSearcher("index/cmv'-the-others-have-it-worse-argument-is-terrible-and-should-never-be-used-in-an-actual-conversation-with-a-depressed-person"),
13
- "metric-system": LuceneSearcher("index/cmv'-there-shouldnt-be-anything-other-than-the-metric-system."),
14
- "best-time-period": LuceneSearcher("index/cmv'-today-is-the-best-time-period-in-human-history-to-be-alive-for-the-vast-majority-of-people."),
15
  }
16
 
17
  @st.cache(suppress_st_warning=True, allow_output_mutation=True, show_spinner=False)
@@ -27,7 +27,9 @@ def result_html(result):
27
  discussion = st.selectbox(
28
  'How would you like to be contacted?',
29
  indexes.keys())
30
- searcher = indexes[discussion]
 
 
31
  cola, colb, colc = st.columns([5,4,5])
32
  with colb:
33
  st.write(discussion)
 
7
  layout="centered"
8
  )
9
 
10
+ index_locations = {"shoe-sizes": "index/cmv'-shoe-sizes-should-be-the-same-for-both-men-and-women",
11
+ "social-media": "index/cmv'-social-media-is-the-most-destructive-addiction-in-our-society",
12
+ "depression": "index/cmv'-the-others-have-it-worse-argument-is-terrible-and-should-never-be-used-in-an-actual-conversation-with-a-depressed-person",
13
+ "metric-system": "index/cmv'-there-shouldnt-be-anything-other-than-the-metric-system.",
14
+ "best-time-period": "index/cmv'-today-is-the-best-time-period-in-human-history-to-be-alive-for-the-vast-majority-of-people.",
15
  }
16
 
17
  @st.cache(suppress_st_warning=True, allow_output_mutation=True, show_spinner=False)
 
27
  discussion = st.selectbox(
28
  'How would you like to be contacted?',
29
  indexes.keys())
30
+ searcher = LuceneSearcher(indexes[discussion])
31
+ searcher.set_rm3()
32
+
33
  cola, colb, colc = st.columns([5,4,5])
34
  with colb:
35
  st.write(discussion)