merve HF Staff commited on
Commit
3820b00
Β·
1 Parent(s): 75ec6de

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -2
app.py CHANGED
@@ -18,7 +18,11 @@ def load_data(idx):
18
  else:
19
  input_sample="-"
20
  response = sample[3]
21
- return instruction, input_sample, response
 
 
 
 
22
 
23
 
24
  def create_record(instruction, input_sample, response, feedback):
@@ -60,7 +64,7 @@ class ArgillaLogger(FlaggingCallback):
60
  ) -> int:
61
  text = flag_data[0]
62
  inference = flag_data[1]
63
- rg.log(name=self.dataset_name, records=create_record(instruction, input_sample, response, flag_option))
64
 
65
 
66
  idx_input = gr.Slider(minimum=0, maximum=51564, label="SatΔ±r")
 
18
  else:
19
  input_sample="-"
20
  response = sample[3]
21
+ return {
22
+ "talimat": instruction,
23
+ "input": input_sample,
24
+ "response": response
25
+ }
26
 
27
 
28
  def create_record(instruction, input_sample, response, feedback):
 
64
  ) -> int:
65
  text = flag_data[0]
66
  inference = flag_data[1]
67
+ rg.log(name=self.dataset_name, records=create_record(text, flag_option))
68
 
69
 
70
  idx_input = gr.Slider(minimum=0, maximum=51564, label="SatΔ±r")