KnowledgeBase Class
- java.
lang. Object - com.
azure. search. documents. indexes. models. KnowledgeBase
- com.
Implements
public final class KnowledgeBase
implements JsonSerializable<KnowledgeBase>
Represents a knowledge base definition.
Constructor Summary
| Constructor | Description |
|---|---|
| KnowledgeBase(String name, KnowledgeSourceReference[] knowledgeSources) |
Creates an instance of Knowledge |
| KnowledgeBase(String name, List<KnowledgeSourceReference> knowledgeSources) |
Creates an instance of Knowledge |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
static
Knowledge |
fromJson(JsonReader jsonReader)
Reads an instance of Knowledge |
| String |
getAnswerInstructions()
Get the answer |
|
Cors |
getCorsOptions()
Get the cors |
| String |
getDescription()
Get the description property: The description of the knowledge base. |
|
Search |
getEncryptionKey()
Get the encryption |
| String |
getETag()
Get the e |
|
List<Knowledge |
getKnowledgeSources()
Get the knowledge |
|
List<Knowledge |
getModels()
Get the models property: Contains configuration options on how to connect to AI models. |
| String |
getName()
Get the name property: The name of the knowledge base. |
|
Knowledge |
getOutputMode()
Get the output |
| String |
getRetrievalInstructions()
Get the retrieval |
|
Knowledge |
getRetrievalReasoningEffort()
Get the retrieval |
|
Knowledge |
setAnswerInstructions(String answerInstructions)
Set the answer |
|
Knowledge |
setCorsOptions(CorsOptions corsOptions)
Set the cors |
|
Knowledge |
setDescription(String description)
Set the description property: The description of the knowledge base. |
|
Knowledge |
setEncryptionKey(SearchResourceEncryptionKey encryptionKey)
Set the encryption |
|
Knowledge |
setETag(String eTag)
Set the e |
|
Knowledge |
setModels(KnowledgeBaseModel[] models)
Set the models property: Contains configuration options on how to connect to AI models. |
|
Knowledge |
setModels(List<KnowledgeBaseModel> models)
Set the models property: Contains configuration options on how to connect to AI models. |
|
Knowledge |
setOutputMode(KnowledgeRetrievalOutputMode outputMode)
Set the output |
|
Knowledge |
setRetrievalInstructions(String retrievalInstructions)
Set the retrieval |
|
Knowledge |
setRetrievalReasoningEffort(KnowledgeRetrievalReasoningEffort retrievalReasoningEffort)
Set the retrieval |
|
Json |
toJson(JsonWriter jsonWriter) |
Methods inherited from java.lang.Object
Constructor Details
KnowledgeBase
public KnowledgeBase(String name, KnowledgeSourceReference[] knowledgeSources)
Creates an instance of KnowledgeBase class.
Parameters:
KnowledgeBase
public KnowledgeBase(String name, List<KnowledgeSourceReference> knowledgeSources)
Creates an instance of KnowledgeBase class.
Parameters:
Method Details
fromJson
public static KnowledgeBase fromJson(JsonReader jsonReader)
Reads an instance of KnowledgeBase from the JsonReader.
Parameters:
Returns:
Throws:
getAnswerInstructions
public String getAnswerInstructions()
Get the answerInstructions property: Instructions considered by the knowledge base when generating answers.
Returns:
getCorsOptions
public CorsOptions getCorsOptions()
Get the corsOptions property: Options to control Cross-Origin Resource Sharing (CORS) for the knowledge base.
Returns:
getDescription
public String getDescription()
Get the description property: The description of the knowledge base.
Returns:
getEncryptionKey
public SearchResourceEncryptionKey getEncryptionKey()
Get the encryptionKey property: A description of an encryption key that you create in Azure Key Vault.
Returns:
getETag
public String getETag()
Get the eTag property: The ETag of the knowledge base.
Returns:
getKnowledgeSources
public List<KnowledgeSourceReference> getKnowledgeSources()
Get the knowledgeSources property: Knowledge sources referenced by this knowledge base.
Returns:
getModels
public List<KnowledgeBaseModel> getModels()
Get the models property: Contains configuration options on how to connect to AI models.
Returns:
getName
public String getName()
Get the name property: The name of the knowledge base.
Returns:
getOutputMode
public KnowledgeRetrievalOutputMode getOutputMode()
Get the outputMode property: The output mode for the knowledge base.
Returns:
getRetrievalInstructions
public String getRetrievalInstructions()
Get the retrievalInstructions property: Instructions considered by the knowledge base when developing query plan.
Returns:
getRetrievalReasoningEffort
public KnowledgeRetrievalReasoningEffort getRetrievalReasoningEffort()
Get the retrievalReasoningEffort property: The retrieval reasoning effort configuration.
Returns:
setAnswerInstructions
public KnowledgeBase setAnswerInstructions(String answerInstructions)
Set the answerInstructions property: Instructions considered by the knowledge base when generating answers.
Parameters:
Returns:
setCorsOptions
public KnowledgeBase setCorsOptions(CorsOptions corsOptions)
Set the corsOptions property: Options to control Cross-Origin Resource Sharing (CORS) for the knowledge base.
Parameters:
Returns:
setDescription
public KnowledgeBase setDescription(String description)
Set the description property: The description of the knowledge base.
Parameters:
Returns:
setEncryptionKey
public KnowledgeBase setEncryptionKey(SearchResourceEncryptionKey encryptionKey)
Set the encryptionKey property: A description of an encryption key that you create in Azure Key Vault.
Parameters:
Returns:
setETag
public KnowledgeBase setETag(String eTag)
Set the eTag property: The ETag of the knowledge base.
Parameters:
Returns:
setModels
public KnowledgeBase setModels(KnowledgeBaseModel[] models)
Set the models property: Contains configuration options on how to connect to AI models.
Parameters:
Returns:
setModels
public KnowledgeBase setModels(List<KnowledgeBaseModel> models)
Set the models property: Contains configuration options on how to connect to AI models.
Parameters:
Returns:
setOutputMode
public KnowledgeBase setOutputMode(KnowledgeRetrievalOutputMode outputMode)
Set the outputMode property: The output mode for the knowledge base.
Parameters:
Returns:
setRetrievalInstructions
public KnowledgeBase setRetrievalInstructions(String retrievalInstructions)
Set the retrievalInstructions property: Instructions considered by the knowledge base when developing query plan.
Parameters:
Returns:
setRetrievalReasoningEffort
public KnowledgeBase setRetrievalReasoningEffort(KnowledgeRetrievalReasoningEffort retrievalReasoningEffort)
Set the retrievalReasoningEffort property: The retrieval reasoning effort configuration.
Parameters:
Returns: