Enum FinishReason.Known

  • All Implemented Interfaces:

    
    public enum FinishReason.Known
    
                        

    Enum representing the known values for FinishReason.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      FINISH_REASON_UNSPECIFIED

      The finish reason is unspecified.

      STOP

      Token generation reached a natural stopping point or a configured stop sequence.

      MAX_TOKENS

      Token generation reached the configured maximum output tokens.

      SAFETY

      Token generation stopped because the content potentially contains safety violations. NOTE: When streaming, [content][] is empty if content filters blocks the output.

      RECITATION

      The token generation stopped because of potential recitation.

      LANGUAGE

      The token generation stopped because of using an unsupported language.

      OTHER

      All other reasons that stopped the token generation.

      BLOCKLIST

      Token generation stopped because the content contains forbidden terms.

      PROHIBITED_CONTENT

      Token generation stopped for potentially containing prohibited content.

      SPII

      Token generation stopped because the content potentially contains Sensitive Personally Identifiable Information (SPII).

      MALFORMED_FUNCTION_CALL

      The function call generated by the model is invalid.

      IMAGE_SAFETY

      Token generation stopped because generated images have safety violations.

      UNEXPECTED_TOOL_CALL

      The tool call generated by the model is invalid.

      IMAGE_PROHIBITED_CONTENT

      Image generation stopped because the generated images have prohibited content.

      NO_IMAGE

      The model was expected to generate an image, but none was generated.

      IMAGE_RECITATION

      Image generation stopped because the generated image may be a recitation from a source.

      IMAGE_OTHER

      Image generation stopped for a reason not otherwise specified.

    • Method Summary

      Modifier and Type Method Description
      static Array<FinishReason.Known> values() Returns an array containing the constants of this enum type, in the order they're declared.
      static FinishReason.Known valueOf(String name) Returns the enum constant of this type with the specified name.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • values

         static Array<FinishReason.Known> values()

        Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants.

        Returns:

        an array containing the constants of this enum type, in the order they're declared

      • valueOf

         static FinishReason.Known 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.)

        Returns:

        the enum constant with the specified name