knowledge kbid

Joel Thomas George 1 Reputation point
2022-11-04T06:23:04.703+00:00

where can I find knowledge-based ID for azure language studio

Azure AI services
Azure AI services
A group of Azure services, SDKs, and APIs designed to make apps more intelligent, engaging, and discoverable.
2,364 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. romungi-MSFT 41,866 Reputation points Microsoft Employee
    2022-11-04T11:40:23.627+00:00

    @Joel Thomas George With the new language studio the projectName is used in the URL as a query parameter to call the KB. For example, the following is a sample request for prediction with the project details.

    URL:

    https://<resource>.cognitiveservices.azure.com/language/:query-knowledgebases?projectName=test123&api-version=2021-10-01&deploymentName=production  
    

    Query:

    curl -X POST "https://<resource>.cognitiveservices.azure.com/language/:query-knowledgebases?projectName=test123&api-version=2021-10-01&deploymentName=production" -H "Ocp-Apim-Subscription-Key: <your_key>" -H "Content-Type: application/json" -d "{\"top\":3,\"question\":\"YOUR_QUESTION_HERE\",\"includeUnstructuredSources\":true,\"confidenceScoreThreshold\":\"YOUR_SCORE_THRESHOLD_HERE\",\"answerSpanRequest\":{\"enable\":true,\"topAnswersWithSpan\":1,\"confidenceScoreThreshold\":\"YOUR_SCORE_THRESHOLD_HERE\"},\"filters\":{\"metadataFilter\":{\"logicalOperation\":\"YOUR_LOGICAL_OPERATION_HERE\",\"metadata\":[{\"key\":\"YOUR_ADDITIONAL_PROP_KEY_HERE\",\"value\":\"YOUR_ADDITIONAL_PROP_VALUE_HERE\"}]}}}"  
    

    If an answer is helpful, please click on 130616-image.png or upvote 130671-image.png which might help other community members reading this thread.

    1 person found this answer helpful.