@@ -74,6 +74,7 @@ def write():
7474 column_name = column_select .selectbox (
7575 "columns" , options = ["-" ] + dataset .columns .tolist ()
7676 )
77+
7778 sample_data = column_select .checkbox ("Sample a smaller dataset" )
7879 remove_stopwords = column_select .checkbox ("Remove stopwords" )
7980 column_select .info (
@@ -145,16 +146,6 @@ def write():
145146 else :
146147 xi_value = 0.01
147148
148- ##############################
149- # VARIOUS BUTTONS #
150- ##############################
151-
152- space = streamlit .sidebar .text ("" )
153- compute = streamlit .sidebar .button ("Compute embeddings" )
154- show_labeled = streamlit .sidebar .checkbox ("Show labeled data" )
155- clear_cache_button = streamlit .sidebar .button ("Clear cache" )
156- clear_labels_button = streamlit .sidebar .button ("Clear labels" )
157- generate_sample_wordcloud = streamlit .sidebar .checkbox ("Generate wordcloud" )
158149
159150 ##################################
160151 # EXPORTING DATA #
@@ -172,6 +163,20 @@ def write():
172163 "Exported data is saved by default to data/labeled_data/your_name.csv. modify this in the config file"
173164 )
174165
166+ ##############################
167+ # VARIOUS BUTTONS #
168+ ##############################
169+
170+ space = streamlit .sidebar .text ("" )
171+ compute = streamlit .sidebar .button ("Compute embeddings" )
172+ clear_cache_button = streamlit .sidebar .button ("Clear cache" )
173+ clear_labels_button = streamlit .sidebar .button ("Clear labels" )
174+
175+ show_labeled = streamlit .sidebar .checkbox ("Show labeled data" )
176+
177+ generate_sample_wordcloud = streamlit .sidebar .checkbox ("Generate wordcloud" )
178+
179+
175180 if clear_cache_button :
176181 clear_cache ()
177182
@@ -194,6 +199,8 @@ def write():
194199 #####################################
195200
196201 if column_name != "-" :
202+
203+ dataset [column_name ]= dataset [column_name ].astype (str )
197204 embedding_df = compute_cache (
198205 progress_bar ,
199206 embedding_language ,
0 commit comments