HarmProbability
public enum HarmProbability : String
extension SafetyRating.HarmProbability: Codable
The probability that a given model output falls under a harmful content category. This does not indicate the severity of harm for a piece of content.
-
Unknown. A new server value that isn’t recognized by the SDK.
Declaration
Swift
case unknown = "UNKNOWN"
-
The probability was not specified in the server response.
Declaration
Swift
case unspecified = "HARM_PROBABILITY_UNSPECIFIED"
-
The probability is zero or close to zero. For benign content, the probability across all categories will be this value.
Declaration
Swift
case negligible = "NEGLIGIBLE"
-
The probability is small but non-zero.
Declaration
Swift
case low = "LOW"
-
The probability is moderate.
Declaration
Swift
case medium = "MEDIUM"
-
The probability is high. The content described is very likely harmful.
Declaration
Swift
case high = "HIGH"
-
Declaration
Swift
public init(from decoder: Decoder) throws