无法使用其余API更新QnA制造商中的知识

时间:2020-06-07 21:24:18

标签: java azure rest qnamaker

无法更新QnA制造商的知识,而添加和删除工作正常,唯一的问题是更新请求。以下是与更新有关的REQUEST对象引用:https://github.com/Azure-Samples/cognitive-services-qnamaker-java/blob/master/update-knowledge-base.java 请您查看以下信息,让我们知道我是否错过任何更新。

请求

{
"add":{
"qnaList":[
{
"id":23,
"answer":"Testing",
"source":"sample-tsv-qna.tsv",
"questions":[
"What is your Name?"
],
"metadata":[
{
"name":"category",
"value":"api"
}
]
},
{
"id":24,
"answer":"US",
"source":"sample-tsv-qna.tsv",
"questions":[
"Where are you staying?"
],
"metadata":[
{
"name":"category",
"value":"api"
}
]
},
{
"id":25,
"answer":"US1",
"source":"sample-tsv-qna.tsv",
"questions":[
"Where are you staying1?"
],
"metadata":[
{
"name":"category",
"value":"api"
}
]
},
{
"id":26,
"answer":"US2",
"source":"sample-tsv-qna.tsv",
"questions":[
"Where are you staying2?"
],
"metadata":[
{
"name":"category",
"value":"api"
}
]
}
]
}
,
"delete": {
"ids": [
26
],
"sources": [
"Editorial"
]
},
"update": {
"name": "sample details",
"qnaList": [
{
"id": 23,
"answer": "Testing",
"source": "sample-tsv-qna.tsv",
"questions": {
"add": [
"can I programmatically manage a KB?"
],
"delete": [
"What is your Name?"
]
},
"metadata": {
"delete": [
{
"name": "category",
"value": "api"
}
],
"add": [
{
"name": "category",
"value": "programmatic"
}
]
}
}
],
"urls": [

],
"files": [

]
}
}

Response:
202 Accepted

0 个答案:

没有答案