RiskCategory Class

public final class RiskCategory
extends ExpandableStringEnum<RiskCategory>

Risk category for the attack objective.

Field Summary

Modifier and Type Field and Description
static final RiskCategory CODE_VULNERABILITY

Represents content that contains vulnerabilities in code.

static final RiskCategory HATE_UNFAIRNESS

Represents content related to hate or unfairness.

static final RiskCategory PROHIBITED_ACTIONS

Represents content that involves prohibited actions.

static final RiskCategory PROTECTED_MATERIAL

Represents content that involves illegal activities.

static final RiskCategory SELF_HARM

Represents content related to self-harm.

static final RiskCategory SENSITIVE_DATA_LEAKAGE

Represents content that involves sensitive data leakage.

static final RiskCategory SEXUAL

Represents content of a sexual nature.

static final RiskCategory TASK_ADHERENCE

Represents content that involves task adherence.

static final RiskCategory UNGROUNDED_ATTRIBUTES

Represents content that lacks a solid grounding in fact.

static final RiskCategory VIOLENCE

Represents content related to violence.

Constructor Summary

Constructor Description
RiskCategory()

Deprecated

Use the fromString(String name) factory method.

Creates a new instance of RiskCategory value.

Method Summary

Modifier and Type Method and Description
static RiskCategory fromString(String name)

Creates or finds a RiskCategory from its string representation.

static Collection<RiskCategory> values()

Gets known RiskCategory values.

Methods inherited from ExpandableStringEnum

Methods inherited from java.lang.Object

Field Details

CODE_VULNERABILITY

public static final RiskCategory CODE_VULNERABILITY

Represents content that contains vulnerabilities in code.

HATE_UNFAIRNESS

public static final RiskCategory HATE_UNFAIRNESS

Represents content related to hate or unfairness.

PROHIBITED_ACTIONS

public static final RiskCategory PROHIBITED_ACTIONS

Represents content that involves prohibited actions.

PROTECTED_MATERIAL

public static final RiskCategory PROTECTED_MATERIAL

Represents content that involves illegal activities.

SELF_HARM

public static final RiskCategory SELF_HARM

Represents content related to self-harm.

SENSITIVE_DATA_LEAKAGE

public static final RiskCategory SENSITIVE_DATA_LEAKAGE

Represents content that involves sensitive data leakage.

SEXUAL

public static final RiskCategory SEXUAL

Represents content of a sexual nature.

TASK_ADHERENCE

public static final RiskCategory TASK_ADHERENCE

Represents content that involves task adherence.

UNGROUNDED_ATTRIBUTES

public static final RiskCategory UNGROUNDED_ATTRIBUTES

Represents content that lacks a solid grounding in fact.

VIOLENCE

public static final RiskCategory VIOLENCE

Represents content related to violence.

Constructor Details

RiskCategory

@Deprecated
public RiskCategory()

Deprecated

Use the fromString(String name) factory method.

Creates a new instance of RiskCategory value.

Method Details

fromString

public static RiskCategory fromString(String name)

Creates or finds a RiskCategory from its string representation.

Parameters:

name - a name to look for.

Returns:

the corresponding RiskCategory.

values

public static Collection<RiskCategory> values()

Gets known RiskCategory values.

Returns:

known RiskCategory values.

Applies to