Record Class BedrockAi21Jurassic2ChatOptions.Penalty

java.lang.Object
java.lang.Record
org.springframework.ai.bedrock.jurassic2.BedrockAi21Jurassic2ChatOptions.Penalty
Record Components:
scale - The scale of the penalty.
applyToNumbers - Whether to apply the penalty to numbers.
applyToPunctuations - Whether to apply the penalty to punctuations.
applyToStopwords - Whether to apply the penalty to stopwords.
applyToWhitespaces - Whether to apply the penalty to whitespaces.
applyToEmojis - Whether to apply the penalty to emojis.
Enclosing class:
BedrockAi21Jurassic2ChatOptions

public static record BedrockAi21Jurassic2ChatOptions.Penalty(Double scale, Boolean applyToNumbers, Boolean applyToPunctuations, Boolean applyToStopwords, Boolean applyToWhitespaces, Boolean applyToEmojis) extends Record
Penalty object for frequency, presence, and count penalties.
  • Constructor Details

    • Penalty

      public Penalty(Double scale, Boolean applyToNumbers, Boolean applyToPunctuations, Boolean applyToStopwords, Boolean applyToWhitespaces, Boolean applyToEmojis)
      Creates an instance of a Penalty record class.
      Parameters:
      scale - the value for the scale record component
      applyToNumbers - the value for the applyToNumbers record component
      applyToPunctuations - the value for the applyToPunctuations record component
      applyToStopwords - the value for the applyToStopwords record component
      applyToWhitespaces - the value for the applyToWhitespaces record component
      applyToEmojis - the value for the applyToEmojis record component
  • Method Details

    • builder

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • scale

      public Double scale()
      Returns the value of the scale record component.
      Returns:
      the value of the scale record component
    • applyToNumbers

      public Boolean applyToNumbers()
      Returns the value of the applyToNumbers record component.
      Returns:
      the value of the applyToNumbers record component
    • applyToPunctuations

      public Boolean applyToPunctuations()
      Returns the value of the applyToPunctuations record component.
      Returns:
      the value of the applyToPunctuations record component
    • applyToStopwords

      public Boolean applyToStopwords()
      Returns the value of the applyToStopwords record component.
      Returns:
      the value of the applyToStopwords record component
    • applyToWhitespaces

      public Boolean applyToWhitespaces()
      Returns the value of the applyToWhitespaces record component.
      Returns:
      the value of the applyToWhitespaces record component
    • applyToEmojis

      public Boolean applyToEmojis()
      Returns the value of the applyToEmojis record component.
      Returns:
      the value of the applyToEmojis record component