Interface SourceAttribution.Builder
- All Superinterfaces:
Buildable
,CopyableBuilder<SourceAttribution.Builder,
,SourceAttribution> SdkBuilder<SourceAttribution.Builder,
,SourceAttribution> SdkPojo
- Enclosing class:
SourceAttribution
-
Method Summary
Modifier and TypeMethodDescriptioncitationNumber
(Integer citationNumber) The number attached to a citation in an Amazon Q Business generated response.datasourceId
(String datasourceId) The identifier of the data source from which the document was ingested.documentId
(String documentId) The unique identifier of the source document used in the citation, obtained from the Amazon Q Business index during chat response generation.The identifier of the index containing the source document's metadata and access control information.The content extract from the document on which the generated response is based.textMessageSegments
(Collection<TextSegment> textMessageSegments) A text extract from a source document that is used for source attribution.textMessageSegments
(Consumer<TextSegment.Builder>... textMessageSegments) A text extract from a source document that is used for source attribution.textMessageSegments
(TextSegment... textMessageSegments) A text extract from a source document that is used for source attribution.The title of the document which is the source for the Amazon Q Business generated response.The Unix timestamp when the Amazon Q Business application was last updated.The URL of the document which is the source for the Amazon Q Business generated response.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
Method Details
-
title
The title of the document which is the source for the Amazon Q Business generated response.
- Parameters:
title
- The title of the document which is the source for the Amazon Q Business generated response.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
snippet
The content extract from the document on which the generated response is based.
- Parameters:
snippet
- The content extract from the document on which the generated response is based.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
url
The URL of the document which is the source for the Amazon Q Business generated response.
- Parameters:
url
- The URL of the document which is the source for the Amazon Q Business generated response.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
citationNumber
The number attached to a citation in an Amazon Q Business generated response.
- Parameters:
citationNumber
- The number attached to a citation in an Amazon Q Business generated response.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
updatedAt
The Unix timestamp when the Amazon Q Business application was last updated.
- Parameters:
updatedAt
- The Unix timestamp when the Amazon Q Business application was last updated.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
textMessageSegments
A text extract from a source document that is used for source attribution.
- Parameters:
textMessageSegments
- A text extract from a source document that is used for source attribution.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
textMessageSegments
A text extract from a source document that is used for source attribution.
- Parameters:
textMessageSegments
- A text extract from a source document that is used for source attribution.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
textMessageSegments
A text extract from a source document that is used for source attribution.
This is a convenience method that creates an instance of theTextSegment.Builder
avoiding the need to create one manually viaTextSegment.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed totextMessageSegments(List<TextSegment>)
.- Parameters:
textMessageSegments
- a consumer that will call methods onTextSegment.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
documentId
The unique identifier of the source document used in the citation, obtained from the Amazon Q Business index during chat response generation. This ID is used as input to the
GetDocumentContent
API to retrieve the actual document content for user verification.- Parameters:
documentId
- The unique identifier of the source document used in the citation, obtained from the Amazon Q Business index during chat response generation. This ID is used as input to theGetDocumentContent
API to retrieve the actual document content for user verification.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
indexId
The identifier of the index containing the source document's metadata and access control information. This links the citation back to the specific Amazon Q Business index where the document's searchable content and permissions are stored.
- Parameters:
indexId
- The identifier of the index containing the source document's metadata and access control information. This links the citation back to the specific Amazon Q Business index where the document's searchable content and permissions are stored.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
datasourceId
The identifier of the data source from which the document was ingested. This field is not present if the document is ingested by directly calling the BatchPutDocument API (similar to checkDocumentAccess). If the document is from a file-upload data source, the datasource will be "uploaded-docs-file-stat-datasourceid".
- Parameters:
datasourceId
- The identifier of the data source from which the document was ingested. This field is not present if the document is ingested by directly calling the BatchPutDocument API (similar to checkDocumentAccess). If the document is from a file-upload data source, the datasource will be "uploaded-docs-file-stat-datasourceid".- Returns:
- Returns a reference to this object so that method calls can be chained together.
-