added `misinfo war`

This commit is contained in:
Nick 2023-04-08 11:10:33 -04:00
parent ed570757b0
commit 243b43b7b5
3 changed files with 15 additions and 0 deletions

View File

@ -85,6 +85,7 @@ object TweetSafetyLabelType extends SafetyLabelType {
s.SafetyLabelType.MisinfoCivic -> MisinfoCivic, s.SafetyLabelType.MisinfoCivic -> MisinfoCivic,
s.SafetyLabelType.MisinfoGeneric -> MisinfoGeneric, s.SafetyLabelType.MisinfoGeneric -> MisinfoGeneric,
s.SafetyLabelType.MisinfoMedical -> MisinfoMedical, s.SafetyLabelType.MisinfoMedical -> MisinfoMedical,
s.SafetyLabelType.MisinfoWar -> MisinfoWar,
s.SafetyLabelType.NsfaHighPrecision -> NsfaHighPrecision, s.SafetyLabelType.NsfaHighPrecision -> NsfaHighPrecision,
s.SafetyLabelType.NsfaHighRecall -> NsfaHighRecall, s.SafetyLabelType.NsfaHighRecall -> NsfaHighRecall,
s.SafetyLabelType.NsfwCardImage -> NsfwCardImage, s.SafetyLabelType.NsfwCardImage -> NsfwCardImage,
@ -99,6 +100,7 @@ object TweetSafetyLabelType extends SafetyLabelType {
s.SafetyLabelType.Pdna -> Pdna, s.SafetyLabelType.Pdna -> Pdna,
s.SafetyLabelType.RecommendationsLowQuality -> RecommendationsLowQuality, s.SafetyLabelType.RecommendationsLowQuality -> RecommendationsLowQuality,
s.SafetyLabelType.RitoActionedTweet -> RitoActionedTweet, s.SafetyLabelType.RitoActionedTweet -> RitoActionedTweet,
s.SafetyLabelType.SafetyCrisis -> SafetyCrisis,
s.SafetyLabelType.SearchBlacklist -> SearchBlacklist, s.SafetyLabelType.SearchBlacklist -> SearchBlacklist,
s.SafetyLabelType.SearchBlacklistHighRecall -> SearchBlacklistHighRecall, s.SafetyLabelType.SearchBlacklistHighRecall -> SearchBlacklistHighRecall,
s.SafetyLabelType.SemanticCoreMisinformation -> SemanticCoreMisinformation, s.SafetyLabelType.SemanticCoreMisinformation -> SemanticCoreMisinformation,

View File

@ -114,6 +114,7 @@ object Reason {
case object MisinfoCivic extends Reason case object MisinfoCivic extends Reason
case object MisinfoGeneric extends Reason case object MisinfoGeneric extends Reason
case object MisinfoMedical extends Reason case object MisinfoMedical extends Reason
case object MisinfoWar extends Reason
case object Misleading extends Reason case object Misleading extends Reason
case object ExclusiveTweet extends Reason case object ExclusiveTweet extends Reason
case object CommunityNotAMember extends Reason case object CommunityNotAMember extends Reason

View File

@ -53,6 +53,7 @@ object PublicInterest {
PolicyInViolation.MisinformationCivic -> MisinfoCivic, PolicyInViolation.MisinformationCivic -> MisinfoCivic,
PolicyInViolation.MisinformationGeneric -> MisinfoGeneric, PolicyInViolation.MisinformationGeneric -> MisinfoGeneric,
PolicyInViolation.MisinformationMedical -> MisinfoMedical, PolicyInViolation.MisinformationMedical -> MisinfoMedical,
PolicyInViolation.MisinformationWar -> MisinfoWar,
) )
val reasonToPolicyInViolation: Map[Reason, PolicyInViolation] = Map( val reasonToPolicyInViolation: Map[Reason, PolicyInViolation] = Map(
@ -77,6 +78,7 @@ object PublicInterest {
MisinfoCivic -> PolicyInViolation.MisinformationCivic, MisinfoCivic -> PolicyInViolation.MisinformationCivic,
MisinfoGeneric -> PolicyInViolation.MisinformationGeneric, MisinfoGeneric -> PolicyInViolation.MisinformationGeneric,
MisinfoMedical -> PolicyInViolation.MisinformationMedical, MisinfoMedical -> PolicyInViolation.MisinformationMedical,
MisinfoWar -> PolicyInViolation.MisinformationWar,
) )
val ReasonToSafetyResultReason: Map[Reason, SafetyResultReason] = Map( val ReasonToSafetyResultReason: Map[Reason, SafetyResultReason] = Map(
@ -115,6 +117,7 @@ object PublicInterest {
TweetSafetyLabelType.MisinfoCivic, TweetSafetyLabelType.MisinfoCivic,
TweetSafetyLabelType.MisinfoGeneric, TweetSafetyLabelType.MisinfoGeneric,
TweetSafetyLabelType.MisinfoMedical, TweetSafetyLabelType.MisinfoMedical,
TweetSafetyLabelType.MisinfoWar,
TweetSafetyLabelType.IpiDevelopmentOnly TweetSafetyLabelType.IpiDevelopmentOnly
) )
@ -175,6 +178,9 @@ class PublicInterestActionBuilder[T <: Action]() extends ActionBuilder[T] {
case Some((TweetSafetyLabelType.MisinfoMedical, source)) => case Some((TweetSafetyLabelType.MisinfoMedical, source)) =>
(Reason.MisinfoMedical, LimitedEngagementReason.fromString(source.map(_.name))) (Reason.MisinfoMedical, LimitedEngagementReason.fromString(source.map(_.name)))
case Some((TweetSafetyLabelType.MisinfoWar, source)) =>
(Reason.MisinfoWar, LimitedEngagementReason.fromString(source.map(_.name)))
case Some((TweetSafetyLabelType.IpiDevelopmentOnly, _)) => case Some((TweetSafetyLabelType.IpiDevelopmentOnly, _)) =>
(Reason.IpiDevelopmentOnly, Some(LimitedEngagementReason.NonCompliant)) (Reason.IpiDevelopmentOnly, Some(LimitedEngagementReason.NonCompliant))
@ -219,6 +225,9 @@ class PublicInterestComplianceTweetNoticeActionBuilder
case Some((TweetSafetyLabelType.MisinfoMedical, _)) => case Some((TweetSafetyLabelType.MisinfoMedical, _)) =>
Reason.MisinfoMedical Reason.MisinfoMedical
case Some((TweetSafetyLabelType.MisinfoWar, _)) =>
Reason.MisinfoWar
case Some((TweetSafetyLabelType.IpiDevelopmentOnly, _)) => case Some((TweetSafetyLabelType.IpiDevelopmentOnly, _)) =>
Reason.IpiDevelopmentOnly Reason.IpiDevelopmentOnly
@ -253,6 +262,9 @@ class PublicInterestDropActionBuilder extends ActionBuilder[Drop] {
case Some(TweetSafetyLabelType.MisinfoMedical) => case Some(TweetSafetyLabelType.MisinfoMedical) =>
Reason.MisinfoMedical Reason.MisinfoMedical
case Some(TweetSafetyLabelType.MisinfoWar) =>
Reason.MisinfoWar
case _ => case _ =>
Reason.OneOff Reason.OneOff
} }