SamanthaStorm commited on
Commit
af48cbf
·
verified ·
1 Parent(s): afad69b

Update abuse_type_mapping.py

Browse files
Files changed (1) hide show
  1. abuse_type_mapping.py +11 -6
abuse_type_mapping.py CHANGED
@@ -5,7 +5,7 @@ def determine_abuse_type(detected_labels):
5
 
6
  labels = set(detected_labels)
7
 
8
- if {"extreme_control", "gaslighting", "dismissiveness", "physical_threat"} & labels:
9
  abuse_type = "Intimate Terrorism"
10
  abuser_profile = "Strategic and controlling"
11
  advice = (
@@ -14,7 +14,7 @@ def determine_abuse_type(detected_labels):
14
  "Placating or confronting the abuser may increase danger."
15
  )
16
 
17
- elif {"mockery", "insults", "deflection", "blame_shifting"} & labels:
18
  abuse_type = "Situational Couple Violence"
19
  abuser_profile = "Emotionally reactive"
20
  advice = (
@@ -36,11 +36,16 @@ def determine_abuse_type(detected_labels):
36
  "This may reflect a survivor reacting to coercion. Legal and psychological support may help clarify power dynamics."
37
  )
38
 
39
- elif {"gaslighting", "obscure_formal", "dismissiveness"} & labels and "physical_threat" not in labels:
40
- abuse_type = "Nonviolent Coercive Control"
41
- abuser_profile = "Controlling but covert"
 
 
 
42
  advice = (
43
- "This pattern involves emotional control without physical harm. Emotional validation, documentation, and external support are important."
 
 
44
  )
45
 
46
  return abuse_type, abuser_profile, advice
 
5
 
6
  labels = set(detected_labels)
7
 
8
+ if {"extreme_control", "gaslighting", "dismissiveness", "physical_threat", "suicidal_threat"} & labels:
9
  abuse_type = "Intimate Terrorism"
10
  abuser_profile = "Strategic and controlling"
11
  advice = (
 
14
  "Placating or confronting the abuser may increase danger."
15
  )
16
 
17
+ elif {"mockery", "insults", "deflection", "blame_shifting", "projection", "contradictory_statements"} & labels:
18
  abuse_type = "Situational Couple Violence"
19
  abuser_profile = "Emotionally reactive"
20
  advice = (
 
36
  "This may reflect a survivor reacting to coercion. Legal and psychological support may help clarify power dynamics."
37
  )
38
 
39
+ elif (
40
+ {"gaslighting", "dismissiveness", "obscure_formal", "apology_baiting"} & labels
41
+ or ("suicidal_threat" in labels and len(labels) == 1)
42
+ ):
43
+ abuse_type = "Coercive Control"
44
+ abuser_profile = "Controlling but covert or emotionally manipulative"
45
  advice = (
46
+ "This pattern involves emotional coercion without overt violence. "
47
+ "It may include guilt-tripping, chronic invalidation, or emotional blackmail. "
48
+ "External validation and trauma-informed support are recommended."
49
  )
50
 
51
  return abuse_type, abuser_profile, advice