Class HybridChunkDocumentRequest.Builder
java.lang.Object
ai.docling.serve.api.chunk.request.HybridChunkDocumentRequest.Builder
- Enclosing class:
- HybridChunkDocumentRequest
Builder for creating
HybridChunkDocumentRequest instances.
Generated by Lombok's @Builder annotation.
Builder methods:
source(Source)- Add a single document source (use with @Singular)sources(List<Source>)- Set the list of document sourcesoptions(ConvertDocumentOptions)- Set the conversion optionstarget(Target)- Set the output target specificationincludeConvertedDoc(boolean)- Set whether to include converted documentchunkingOptions(HybridChunkerOptions)- Set the hybrid chunker options
-
Method Summary
Modifier and TypeMethodDescription@NonNull HybridChunkDocumentRequestbuild()@NonNull HybridChunkDocumentRequest.BuilderchunkingOptions(@NonNull HybridChunkerOptions chunkingOptions) Options specific to the chunker.@NonNull HybridChunkDocumentRequest.Builder@NonNull HybridChunkDocumentRequest.BuilderincludeConvertedDoc(boolean includeConvertedDoc) If true, the output will include both the chunks and the converted document.@NonNull HybridChunkDocumentRequest.Builderoptions(@NonNull ConvertDocumentOptions options) Conversion options.@NonNull HybridChunkDocumentRequest.Builder@NonNull HybridChunkDocumentRequest.Buildersources(@NonNull Collection<? extends Source> sources) @NonNull HybridChunkDocumentRequest.BuilderSpecification for the type of output target.@NonNull StringtoString()
-
Method Details
-
source
-
sources
public @NonNull HybridChunkDocumentRequest.Builder sources(@NonNull Collection<? extends Source> sources) -
clearSources
-
options
public @NonNull HybridChunkDocumentRequest.Builder options(@NonNull @NonNull ConvertDocumentOptions options) Conversion options.- Parameters:
options- the conversion options- Returns:
this.
-
target
Specification for the type of output target.- Parameters:
target- the output target specification, or null if not specified- Returns:
this.
-
includeConvertedDoc
If true, the output will include both the chunks and the converted document.- Parameters:
includeConvertedDoc- true if the converted document should be included, false otherwise- Returns:
this.
-
chunkingOptions
public @NonNull HybridChunkDocumentRequest.Builder chunkingOptions(@NonNull @NonNull HybridChunkerOptions chunkingOptions) Options specific to the chunker.- Parameters:
chunkingOptions- the hybrid chunker options- Returns:
this.
-
build
-
toString
-