Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -186,10 +186,7 @@ if matched_phrases:
|
|
186 |
result += f"• {label.replace('_', ' ').title()}: “{phrase_clean}”\n"
|
187 |
|
188 |
# Always show abuse type if available
|
189 |
-
|
190 |
-
result += f"\n\n🧠 Likely Abuse Type: {abuse_type}"
|
191 |
-
result += f"\n🧠 Abuser Profile: {abuser_profile}"
|
192 |
-
result += f"\n📘 Safety Tip: {advice}"
|
193 |
# THEN immediately follow with this:
|
194 |
if contextual_flags:
|
195 |
result += "\n\n⚠️ You indicated the following:\n" + "\n".join([f"• {flag.replace('_', ' ').title()}" for flag in contextual_flags])
|
@@ -207,7 +204,8 @@ if abuse_type:
|
|
207 |
result += f"\n\n🧠 Likely Abuse Type: {abuse_type}"
|
208 |
result += f"\n🧠 Abuser Profile: {abuser_profile}"
|
209 |
result += f"\n📘 Safety Tip: {advice}"
|
210 |
-
|
|
|
211 |
|
212 |
iface = gr.Interface(
|
213 |
fn=analyze_messages,
|
|
|
186 |
result += f"• {label.replace('_', ' ').title()}: “{phrase_clean}”\n"
|
187 |
|
188 |
# Always show abuse type if available
|
189 |
+
|
|
|
|
|
|
|
190 |
# THEN immediately follow with this:
|
191 |
if contextual_flags:
|
192 |
result += "\n\n⚠️ You indicated the following:\n" + "\n".join([f"• {flag.replace('_', ' ').title()}" for flag in contextual_flags])
|
|
|
204 |
result += f"\n\n🧠 Likely Abuse Type: {abuse_type}"
|
205 |
result += f"\n🧠 Abuser Profile: {abuser_profile}"
|
206 |
result += f"\n📘 Safety Tip: {advice}"
|
207 |
+
|
208 |
+
return result
|
209 |
|
210 |
iface = gr.Interface(
|
211 |
fn=analyze_messages,
|