Class SplitClassification.Builder
- java.lang.Object
-
- ai.extend.types.SplitClassification.Builder
-
- All Implemented Interfaces:
SplitClassification._FinalStage,SplitClassification.DescriptionStage,SplitClassification.IdStage,SplitClassification.TypeStage
- Enclosing class:
- SplitClassification
public static final class SplitClassification.Builder extends java.lang.Object implements SplitClassification.IdStage, SplitClassification.TypeStage, SplitClassification.DescriptionStage, SplitClassification._FinalStage
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SplitClassificationbuild()SplitClassification._FinalStagedescription(java.lang.String description)A detailed description of the classification.SplitClassification.Builderfrom(SplitClassification other)SplitClassification.TypeStageid(java.lang.String id)Unique identifier for the classification.SplitClassification._FinalStageidentifierKey(java.lang.String identifierKey)A natural-language rule describing how to extract a unique identifier for subdocuments of this type.SplitClassification._FinalStageidentifierKey(java.util.Optional<java.lang.String> identifierKey)A natural-language rule describing how to extract a unique identifier for subdocuments of this type.SplitClassification.DescriptionStagetype(java.lang.String type)Type identifier for the classification.
-
-
-
Method Detail
-
from
public SplitClassification.Builder from(SplitClassification other)
- Specified by:
fromin interfaceSplitClassification.IdStage
-
id
public SplitClassification.TypeStage id(@NotNull java.lang.String id)
Unique identifier for the classification. We recommend lowercase, underscore-separated format.
Unique identifier for the classification. We recommend lowercase, underscore-separated format.
- Specified by:
idin interfaceSplitClassification.IdStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
type
public SplitClassification.DescriptionStage type(@NotNull java.lang.String type)
Type identifier for the classification.
Type identifier for the classification.
- Specified by:
typein interfaceSplitClassification.TypeStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
description
public SplitClassification._FinalStage description(@NotNull java.lang.String description)
A detailed description of the classification.
A detailed description of the classification.
- Specified by:
descriptionin interfaceSplitClassification.DescriptionStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
identifierKey
public SplitClassification._FinalStage identifierKey(java.lang.String identifierKey)
A natural-language rule describing how to extract a unique identifier for subdocuments of this type. For example,
"Extract the invoice number from the document header".When provided, the splitter will extract the specified identifier for each subdocument of this type and include it in the output as the
identifierfield. This enables merging of related subdocuments that share the same extracted identifier.Availability: Supported on
splitting_light>= 1.3.0 andsplitting_performance>= 1.5.0. If provided on older versions, this field is accepted but ignored.- Specified by:
identifierKeyin interfaceSplitClassification._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
identifierKey
public SplitClassification._FinalStage identifierKey(java.util.Optional<java.lang.String> identifierKey)
A natural-language rule describing how to extract a unique identifier for subdocuments of this type. For example,
"Extract the invoice number from the document header".When provided, the splitter will extract the specified identifier for each subdocument of this type and include it in the output as the
identifierfield. This enables merging of related subdocuments that share the same extracted identifier.Availability: Supported on
splitting_light>= 1.3.0 andsplitting_performance>= 1.5.0. If provided on older versions, this field is accepted but ignored.- Specified by:
identifierKeyin interfaceSplitClassification._FinalStage
-
build
public SplitClassification build()
- Specified by:
buildin interfaceSplitClassification._FinalStage
-
-