Enum CohereChatRequest.SafetyMode
- java.lang.Object
-
- java.lang.Enum<CohereChatRequest.SafetyMode>
-
- com.oracle.bmc.generativeaiinference.model.CohereChatRequest.SafetyMode
-
- All Implemented Interfaces:
BmcEnum
,Serializable
,Comparable<CohereChatRequest.SafetyMode>
- Enclosing class:
- CohereChatRequest
public static enum CohereChatRequest.SafetyMode extends Enum<CohereChatRequest.SafetyMode> implements BmcEnum
Safety mode: Adds a safety instruction for the model to use when generating responses.Contextual: (Default) Puts fewer constraints on the output. It maintains core protections by aiming to reject harmful or illegal suggestions, but it allows profanity and some toxic content, sexually explicit and violent content, and content that contains medical, financial, or legal information. Contextual mode is suited for entertainment, creative, or academic use. Strict: Aims to avoid sensitive topics, such as violent or sexual acts and profanity. This mode aims to provide a safer experience by prohibiting responses or recommendations that it finds inappropriate. Strict mode is suited for corporate use, such as for corporate communications and customer service. Off: No safety mode is applied. Note: This parameter is only compatible with models cohere.command-r-08-2024, cohere.command-r-plus-08-2024 and Cohere models released after these models. See release dates.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description Contextual
Off
Strict
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CohereChatRequest.SafetyMode
create(String key)
String
getValue()
static CohereChatRequest.SafetyMode
valueOf(String name)
Returns the enum constant of this type with the specified name.static CohereChatRequest.SafetyMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
Contextual
public static final CohereChatRequest.SafetyMode Contextual
-
Strict
public static final CohereChatRequest.SafetyMode Strict
-
Off
public static final CohereChatRequest.SafetyMode Off
-
-
Method Detail
-
values
public static CohereChatRequest.SafetyMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (CohereChatRequest.SafetyMode c : CohereChatRequest.SafetyMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static CohereChatRequest.SafetyMode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
create
public static CohereChatRequest.SafetyMode create(String key)
-
-