nanom commited on
Commit
ad92024
1 Parent(s): 4562440

Update interfaces/interface_biasPhrase.py

Browse files
Files changed (1) hide show
  1. interfaces/interface_biasPhrase.py +20 -20
interfaces/interface_biasPhrase.py CHANGED
@@ -1,7 +1,7 @@
1
  import gradio as gr
2
  import pandas as pd
3
  from tool_info import TOOL_INFO
4
- from modules.module_logsManager import HuggingFaceDatasetSaver
5
  from modules.module_connection import PhraseBiasExplorerConnector
6
 
7
 
@@ -19,10 +19,10 @@ def interface(
19
  from examples.examples_en import examples_sesgos_frases
20
 
21
  # --- Init logs ---
22
- log_callback = HuggingFaceDatasetSaver(
23
- available_logs=available_logs,
24
- dataset_name=f"logs_edia_lmodels_{lang}"
25
- )
26
 
27
  # --- Init vars ---
28
  connector = PhraseBiasExplorerConnector(
@@ -130,21 +130,21 @@ def interface(
130
  )
131
 
132
  # --- Logs ---
133
- save_field = [sent, word_list]
134
- log_callback.setup(
135
- components=save_field,
136
- flagging_dir="logs_phrase_bias"
137
- )
138
 
139
- btn.click(
140
- fn=lambda *args: log_callback.flag(
141
- flag_data=args,
142
- flag_option="phrase_bias",
143
- username="vialibre"
144
- ),
145
- inputs=save_field,
146
- outputs=None,
147
- preprocess=False
148
- )
149
 
150
  return iface
 
1
  import gradio as gr
2
  import pandas as pd
3
  from tool_info import TOOL_INFO
4
+ #from modules.module_logsManager import HuggingFaceDatasetSaver
5
  from modules.module_connection import PhraseBiasExplorerConnector
6
 
7
 
 
19
  from examples.examples_en import examples_sesgos_frases
20
 
21
  # --- Init logs ---
22
+ # log_callback = HuggingFaceDatasetSaver(
23
+ # available_logs=available_logs,
24
+ # dataset_name=f"logs_edia_lmodels_{lang}"
25
+ # )
26
 
27
  # --- Init vars ---
28
  connector = PhraseBiasExplorerConnector(
 
130
  )
131
 
132
  # --- Logs ---
133
+ # save_field = [sent, word_list]
134
+ # log_callback.setup(
135
+ # components=save_field,
136
+ # flagging_dir="logs_phrase_bias"
137
+ # )
138
 
139
+ # btn.click(
140
+ # fn=lambda *args: log_callback.flag(
141
+ # flag_data=args,
142
+ # flag_option="phrase_bias",
143
+ # username="vialibre"
144
+ # ),
145
+ # inputs=save_field,
146
+ # outputs=None,
147
+ # preprocess=False
148
+ # )
149
 
150
  return iface