Class MarkdownDocumentReaderConfig.Builder
java.lang.Object
org.springframework.ai.reader.markdown.config.MarkdownDocumentReaderConfig.Builder
- Enclosing class:
- MarkdownDocumentReaderConfig
-
Method Summary
Modifier and TypeMethodDescriptionbuild()withAdditionalMetadata(String key, Object value) Adds this additional metadata to the all builtDocuments.withAdditionalMetadata(Map<String, Object> additionalMetadata) Adds this additional metadata to the all builtDocuments.withHorizontalRuleCreateDocument(boolean horizontalRuleCreateDocument) Text divided by horizontal lines will create newDocuments.withIncludeBlockquote(boolean includeBlockquote) Whatever to include blockquotes inDocuments.withIncludeCodeBlock(boolean includeCodeBlock) Whatever to include code blocks inDocuments.
-
Method Details
-
withHorizontalRuleCreateDocument
public MarkdownDocumentReaderConfig.Builder withHorizontalRuleCreateDocument(boolean horizontalRuleCreateDocument) Text divided by horizontal lines will create newDocuments. The default isfalse, meaning text separated by horizontal lines won't create a new document.- Parameters:
horizontalRuleCreateDocument- flag to determine whether new documents are created from text divided by horizontal line- Returns:
- this builder
-
withIncludeCodeBlock
Whatever to include code blocks inDocuments. The default isfalse, which means all code blocks are in separate documents.- Parameters:
includeCodeBlock- flag to include code block into paragraph document or create new with code only- Returns:
- this builder
-
withIncludeBlockquote
Whatever to include blockquotes inDocuments. The default isfalse, which means all blockquotes are in separate documents.- Parameters:
includeBlockquote- flag to include blockquotes into paragraph document or create new with blockquote only- Returns:
- this builder
-
withAdditionalMetadata
Adds this additional metadata to the all builtDocuments.- Returns:
- this builder
-
withAdditionalMetadata
public MarkdownDocumentReaderConfig.Builder withAdditionalMetadata(Map<String, Object> additionalMetadata) Adds this additional metadata to the all builtDocuments.- Returns:
- this builder
-
build
- Returns:
- the immutable configuration
-