Module Values.GuardrailTopicSource

Details about topics for the guardrail to identify and deny. This data type is used in the following API operations: GetGuardrail response body

Sourcetype nonrec t = {
  1. name : GuardrailTopicName.t option;
    (*

    The name of the topic to deny.

    *)
  2. definition : GuardrailTopicDefinition.t option;
    (*

    A definition of the topic to deny.

    *)
  3. examples : GuardrailTopicExamples.t option;
    (*

    A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.

    *)
  4. type_ : GuardrailTopicType.t option;
    (*

    Specifies to deny the topic.

    *)
  5. inputAction : GuardrailTopicAction.t option;
    (*

    The action to take when harmful content is detected in the input. Supported values include: BLOCK – Block the content and replace it with blocked messaging. NONE – Take no action but return detection information in the trace response.

    *)
  6. outputAction : GuardrailTopicAction.t option;
    (*

    The action to take when harmful content is detected in the output. Supported values include: BLOCK – Block the content and replace it with blocked messaging. NONE – Take no action but return detection information in the trace response.

    *)
  7. inputEnabled : Boolean.t option;
    (*

    Indicates whether guardrail evaluation is enabled on the input. When disabled, you aren't charged for the evaluation. The evaluation doesn't appear in the response.

    *)
  8. outputEnabled : Boolean.t option;
    (*

    Indicates whether guardrail evaluation is enabled on the output. When disabled, you aren't charged for the evaluation. The evaluation doesn't appear in the response.

    *)
}
Sourceval make : ?name:??? -> ?definition:??? -> ?examples:??? -> ?type_:??? -> ?inputAction:??? -> ?outputAction:??? -> ?inputEnabled:??? -> ?outputEnabled:??? -> unit -> t
Sourceval to_value : t -> [> `Structure of (string * [> `Boolean of Boolean.t | `Enum of string | `List of [> `String of GuardrailTopicExample.t ] list | `String of GuardrailTopicName.t ]) list ]
Sourceval to_query : t -> Awso.Client.Query.t
Sourceval of_xml : Awso.Xml.t -> t
Sourceval of_string : string -> t
Sourceval of_json : Yojson.Safe.t -> t
Sourceval to_json : t -> Yojson.Safe.t