Package com.google.genai.types
Class RougeSpec
java.lang.Object
com.google.genai.JsonSerializable
com.google.genai.types.RougeSpec
Spec for rouge metric.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class com.google.genai.JsonSerializable
MAX_READ_LENGTH_PROPERTY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic RougeSpec.Builderbuilder()Instantiates a builder for RougeSpec.static RougeSpecDeserializes a JSON string to a RougeSpec object.Optional.Optional.abstract RougeSpec.BuilderCreates a builder with the same values as this instance.Optional.Methods inherited from class com.google.genai.JsonSerializable
fromJsonNode, fromJsonString, objectMapper, setMaxReadLength, stringToJsonNode, toJson, toJsonNode, toJsonString
-
Constructor Details
-
RougeSpec
public RougeSpec()
-
-
Method Details
-
rougeType
Optional. Supported rouge types are rougen[1-9], rougeL, and rougeLsum. -
splitSummaries
Optional. Whether to split summaries while using rougeLsum. -
useStemmer
Optional. Whether to use stemmer to compute rouge score. -
builder
Instantiates a builder for RougeSpec. -
toBuilder
Creates a builder with the same values as this instance. -
fromJson
Deserializes a JSON string to a RougeSpec object.
-