KnowledgeBaseRetrievalOptions Class
- java.
lang. Object - com.
azure. search. documents. knowledgebases. models. KnowledgeBaseRetrievalOptions
- com.
Implements
public final class KnowledgeBaseRetrievalOptions
implements JsonSerializable<KnowledgeBaseRetrievalOptions>
The input contract for the retrieval request.
Constructor Summary
| Constructor | Description |
|---|---|
| KnowledgeBaseRetrievalOptions() |
Creates an instance of Knowledge |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
static
Knowledge |
fromJson(JsonReader jsonReader)
Reads an instance of Knowledge |
|
List<Knowledge |
getIntents()
Get the intents property: A list of intended queries to execute without model query planning. |
|
List<Knowledge |
getKnowledgeSourceParams()
Get the knowledge |
| Integer |
getMaxOutputDocuments()
Get the max |
| Integer |
getMaxOutputSize()
Get the max |
| Integer |
getMaxOutputSizeInTokens()
Get the max |
| Integer |
getMaxRuntimeInSeconds()
Get the max |
|
List<Knowledge |
getMessages()
Get the messages property: A list of chat message style input. |
|
Knowledge |
getOutputMode()
Get the output |
| String |
getQuerySourceAuthorization()
Get the query |
|
Knowledge |
getRetrievalReasoningEffort()
Get the retrieval |
| String |
getToolName()
Get the tool |
| Boolean |
isIncludeActivity()
Get the include |
|
Knowledge |
setIncludeActivity(Boolean includeActivity)
Set the include |
|
Knowledge |
setIntents(KnowledgeRetrievalIntent[] intents)
Set the intents property: A list of intended queries to execute without model query planning. |
|
Knowledge |
setIntents(List<KnowledgeRetrievalIntent> intents)
Set the intents property: A list of intended queries to execute without model query planning. |
|
Knowledge |
setKnowledgeSourceParams(List<KnowledgeSourceParams> knowledgeSourceParams)
Set the knowledge |
|
Knowledge |
setMaxOutputDocuments(Integer maxOutputDocuments)
Set the max |
|
Knowledge |
setMaxOutputSize(Integer maxOutputSize)
Set the max |
|
Knowledge |
setMaxOutputSizeInTokens(Integer maxOutputSizeInTokens)
Set the max |
|
Knowledge |
setMaxRuntimeInSeconds(Integer maxRuntimeInSeconds)
Set the max |
|
Knowledge |
setMessages(List<KnowledgeBaseMessage> messages)
Set the messages property: A list of chat message style input. |
|
Knowledge |
setOutputMode(KnowledgeRetrievalOutputMode outputMode)
Set the output |
|
Knowledge |
setQuerySourceAuthorization(String querySourceAuthorization)
Set the query |
|
Knowledge |
setRetrievalReasoningEffort(KnowledgeRetrievalReasoningEffort retrievalReasoningEffort)
Set the retrieval |
|
Knowledge |
setToolName(String toolName)
Set the tool |
|
Json |
toJson(JsonWriter jsonWriter) |
Methods inherited from java.lang.Object
Constructor Details
KnowledgeBaseRetrievalOptions
public KnowledgeBaseRetrievalOptions()
Creates an instance of KnowledgeBaseRetrievalOptions class.
Method Details
fromJson
public static KnowledgeBaseRetrievalOptions fromJson(JsonReader jsonReader)
Reads an instance of KnowledgeBaseRetrievalOptions from the JsonReader.
Parameters:
Returns:
Throws:
getIntents
public List<KnowledgeRetrievalIntent> getIntents()
Get the intents property: A list of intended queries to execute without model query planning.
Returns:
getKnowledgeSourceParams
public List<KnowledgeSourceParams> getKnowledgeSourceParams()
Get the knowledgeSourceParams property: A list of runtime parameters for the knowledge sources.
Returns:
getMaxOutputDocuments
public Integer getMaxOutputDocuments()
Get the maxOutputDocuments property: Limits the maximum number of documents in the output.
Returns:
getMaxOutputSize
public Integer getMaxOutputSize()
Get the maxOutputSize property: Limits the maximum size of the content in the output.
Returns:
getMaxOutputSizeInTokens
public Integer getMaxOutputSizeInTokens()
Get the maxOutputSizeInTokens property: Limits the maximum size of the content in the output.
Returns:
getMaxRuntimeInSeconds
public Integer getMaxRuntimeInSeconds()
Get the maxRuntimeInSeconds property: The maximum runtime in seconds.
Returns:
getMessages
public List<KnowledgeBaseMessage> getMessages()
Get the messages property: A list of chat message style input.
Returns:
getOutputMode
public KnowledgeRetrievalOutputMode getOutputMode()
Get the outputMode property: The output configuration for this retrieval.
Returns:
getQuerySourceAuthorization
public String getQuerySourceAuthorization()
Get the querySourceAuthorization property: Token identifying the user for which the query is being executed. This token is used to enforce security restrictions on documents. It is only sent as the x-ms-query-source-authorization request header and is never part of the request body. A non-null authorization passed explicitly to a retrieve method overrides this value; a null explicit authorization falls back to it.
Returns:
getRetrievalReasoningEffort
public KnowledgeRetrievalReasoningEffort getRetrievalReasoningEffort()
Get the retrievalReasoningEffort property: The retrieval reasoning effort configuration.
Returns:
getToolName
public String getToolName()
Get the toolName property: The tool to select. Omit for KB-wide retrieval.
Returns:
isIncludeActivity
public Boolean isIncludeActivity()
Get the includeActivity property: Indicates retrieval results should include activity information.
Returns:
setIncludeActivity
public KnowledgeBaseRetrievalOptions setIncludeActivity(Boolean includeActivity)
Set the includeActivity property: Indicates retrieval results should include activity information.
Parameters:
Returns:
setIntents
public KnowledgeBaseRetrievalOptions setIntents(KnowledgeRetrievalIntent[] intents)
Set the intents property: A list of intended queries to execute without model query planning.
Parameters:
Returns:
setIntents
public KnowledgeBaseRetrievalOptions setIntents(List<KnowledgeRetrievalIntent> intents)
Set the intents property: A list of intended queries to execute without model query planning.
Parameters:
Returns:
setKnowledgeSourceParams
public KnowledgeBaseRetrievalOptions setKnowledgeSourceParams(List<KnowledgeSourceParams> knowledgeSourceParams)
Set the knowledgeSourceParams property: A list of runtime parameters for the knowledge sources.
Parameters:
Returns:
setMaxOutputDocuments
public KnowledgeBaseRetrievalOptions setMaxOutputDocuments(Integer maxOutputDocuments)
Set the maxOutputDocuments property: Limits the maximum number of documents in the output.
Parameters:
Returns:
setMaxOutputSize
public KnowledgeBaseRetrievalOptions setMaxOutputSize(Integer maxOutputSize)
Set the maxOutputSize property: Limits the maximum size of the content in the output.
Parameters:
Returns:
setMaxOutputSizeInTokens
public KnowledgeBaseRetrievalOptions setMaxOutputSizeInTokens(Integer maxOutputSizeInTokens)
Set the maxOutputSizeInTokens property: Limits the maximum size of the content in the output.
Parameters:
Returns:
setMaxRuntimeInSeconds
public KnowledgeBaseRetrievalOptions setMaxRuntimeInSeconds(Integer maxRuntimeInSeconds)
Set the maxRuntimeInSeconds property: The maximum runtime in seconds.
Parameters:
Returns:
setMessages
public KnowledgeBaseRetrievalOptions setMessages(List<KnowledgeBaseMessage> messages)
Set the messages property: A list of chat message style input.
Parameters:
Returns:
setOutputMode
public KnowledgeBaseRetrievalOptions setOutputMode(KnowledgeRetrievalOutputMode outputMode)
Set the outputMode property: The output configuration for this retrieval.
Parameters:
Returns:
setQuerySourceAuthorization
public KnowledgeBaseRetrievalOptions setQuerySourceAuthorization(String querySourceAuthorization)
Set the querySourceAuthorization property: Token identifying the user for which the query is being executed. This token is used to enforce security restrictions on documents. It is only sent as the x-ms-query-source-authorization request header and is never part of the request body. A non-null authorization passed explicitly to a retrieve method overrides this value; a null explicit authorization falls back to it. An empty string is treated as a value.
Parameters:
Returns:
setRetrievalReasoningEffort
public KnowledgeBaseRetrievalOptions setRetrievalReasoningEffort(KnowledgeRetrievalReasoningEffort retrievalReasoningEffort)
Set the retrievalReasoningEffort property: The retrieval reasoning effort configuration.
Parameters:
Returns:
setToolName
public KnowledgeBaseRetrievalOptions setToolName(String toolName)
Set the toolName property: The tool to select. Omit for KB-wide retrieval.
Parameters:
Returns: