mskov commited on
Commit
18d712a
1 Parent(s): dc2eabd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -37,7 +37,8 @@ emo_dict = {
37
  class_options = {
38
  "racism": ["racism", "hate speech", "bigotry", "racially targeted", "racial slur", "ethnic slur", "ethnic hate", "pro-white nationalism"],
39
  "LGBTQ+ hate": ["gay slur", "trans slur", "homophobic slur", "transphobia", "anti-LBGTQ+", "hate speech"],
40
- "sexually explicit": ["sexually explicit", "sexually coercive", "sexual exploitation", "vulgar", "raunchy", "sexist", "sexually demeaning", "sexual violence", "victim blaming"]
 
41
  }
42
 
43
  pipe = pipeline("automatic-speech-recognition", model="openai/whisper-large")
@@ -133,9 +134,9 @@ def positive_affirmations():
133
  with gr.Blocks() as iface:
134
  show_state = gr.State([])
135
  with gr.Column():
136
- anxiety_class = gr.Radio(["racism", "LGBTQ+ hate", "sexually explicit"])
137
  explit_preference = gr.Radio(choices=["N-Word", "B-Word", "All Explitives"], label="Words to omit from general anxiety classes", info="certain words may be acceptible within certain contects for given groups of people, and some people may be unbothered by explitives broadly speaking.")
138
- emo_class = gr.Radio(choices=["negaitve emotionality"], label="label", info="Select if you would like explitives to be considered anxiety-indiucing in the case of anger/ negative emotionality.")
139
  sense_slider = gr.Slider(minimum=1, maximum=5, step=1.0, label="How readily do you want the tool to intervene? 1 = in extreme cases and 5 = at every opportunity")
140
  with gr.Column():
141
  aud_input = gr.Audio(source="upload", type="filepath", label="Upload Audio File")
 
37
  class_options = {
38
  "racism": ["racism", "hate speech", "bigotry", "racially targeted", "racial slur", "ethnic slur", "ethnic hate", "pro-white nationalism"],
39
  "LGBTQ+ hate": ["gay slur", "trans slur", "homophobic slur", "transphobia", "anti-LBGTQ+", "hate speech"],
40
+ "sexually explicit": ["sexually explicit", "sexually coercive", "sexual exploitation", "vulgar", "raunchy", "sexist", "sexually demeaning", "sexual violence", "victim blaming"],
41
+ "alcohol use": ["alcohol", "drinking", "drinks", "under the influence", "liquor", "beer", "wine"]
42
  }
43
 
44
  pipe = pipeline("automatic-speech-recognition", model="openai/whisper-large")
 
134
  with gr.Blocks() as iface:
135
  show_state = gr.State([])
136
  with gr.Column():
137
+ anxiety_class = gr.Radio(["racism", "LGBTQ+ hate", "sexually explicit", "alcohol use"])
138
  explit_preference = gr.Radio(choices=["N-Word", "B-Word", "All Explitives"], label="Words to omit from general anxiety classes", info="certain words may be acceptible within certain contects for given groups of people, and some people may be unbothered by explitives broadly speaking.")
139
+ emo_class = gr.Radio(choices=["negaitve emotionality"], label="Negative Emotionality", info="Select if you would like explitives to be considered anxiety-indiucing in the case of anger/ negative emotionality.")
140
  sense_slider = gr.Slider(minimum=1, maximum=5, step=1.0, label="How readily do you want the tool to intervene? 1 = in extreme cases and 5 = at every opportunity")
141
  with gr.Column():
142
  aud_input = gr.Audio(source="upload", type="filepath", label="Upload Audio File")