SamanthaStorm commited on
Commit
ad04ec8
·
verified ·
1 Parent(s): 73582bd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -10
app.py CHANGED
@@ -138,16 +138,17 @@ if high_risk_context:
138
  return result
139
 
140
  iface = gr.Interface(
141
- fn=analyze_messages,
142
- inputs=[
143
- gr.Textbox(lines=10, placeholder="Enter message here"),
144
- gr.CheckboxGroup(label="Do any of these apply to your situation?", choices=[
145
- "Theyve threatened harm", "They isolate me", "I’ve changed my behavior out of fear",
146
- "They monitor/follow me", "I feel unsafe when alone with them"
147
- ])
148
- ],
149
- outputs=[gr.Textbox(label="Analysis Result")],
150
- title="Abuse Pattern Detector"
 
151
  )
152
 
153
  if name == "main":
 
138
  return result
139
 
140
  iface = gr.Interface(
141
+ fn=analyze_messages,
142
+ inputs=[
143
+ gr.Textbox(lines=10, placeholder="Enter message here..."),
144
+ gr.CheckboxGroup(label="Do any of these apply to your situation?", choices=[
145
+ "They've threatened harm", "They isolate me", "I’ve changed my behavior out of fear",
146
+ "They monitor/follow me", "I feel unsafe when alone with them"
147
+ ])
148
+ ],
149
+ outputs=[gr.Textbox(label="Analysis Result")],
150
+ title="Abuse Pattern Detector",
151
+ live=True # ← 🔥 this is the missing key for .queue().launch() to work
152
  )
153
 
154
  if name == "main":