Runtime - Train
將建議新增至知識庫的訓練呼叫。
POST {RuntimeEndpoint}/qnamaker/knowledgebases/{kbId}/train
URI 參數
名稱 | 位於 | 必要 | 類型 | Description |
---|---|---|---|---|
kb
|
path | True |
string |
知識庫標識碼。 |
Runtime
|
path | True |
string |
QnA Maker App Service 端點(例如:https://{qnaservice-hostname}.azurewebsites.net)。 |
要求標頭
名稱 | 必要 | 類型 | Description |
---|---|---|---|
Authorization | True |
string |
要求本文
名稱 | 類型 | Description |
---|---|---|
feedbackRecords |
意見反應記錄的清單。 |
回應
名稱 | 類型 | Description |
---|---|---|
204 No Content |
HTTP 204 無內容。 |
|
Other Status Codes |
錯誤回應。 |
安全性
Authorization
類型:
apiKey
位於:
header
範例
Successful query
範例要求
POST {RuntimeEndpoint}/qnamaker/knowledgebases/9d091697-fb8c-4ed5-9ac0-35bf8273bfff/train
{
"feedbackRecords": [
{
"userId": "sd53lsY=",
"userQuestion": "qna maker with luis",
"qnaId": 4
}
]
}
範例回覆
定義
名稱 | Description |
---|---|
Error |
error 物件。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。 |
Error |
其中一組伺服器定義的錯誤碼。 |
Error |
錯誤回應。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。 |
Feedback |
主動式學習意見反應記錄。 |
Feedback |
主動式學習意見反應記錄。 |
Inner |
物件,包含有關錯誤的更特定資訊。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。 |
Error
error 物件。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。
名稱 | 類型 | Description |
---|---|---|
code |
其中一組伺服器定義的錯誤碼。 |
|
details |
Error[] |
導致此錯誤之特定錯誤的詳細數據陣列。 |
innerError |
物件,包含與目前對象有關錯誤更具體的資訊。 |
|
message |
string |
錯誤的人類可讀取表示法。 |
target |
string |
錯誤的目標。 |
ErrorCodeType
其中一組伺服器定義的錯誤碼。
值 | Description |
---|---|
BadArgument | |
EndpointKeysError | |
ExtractionFailure | |
Forbidden | |
KbNotFound | |
NotFound | |
OperationNotFound | |
QnaRuntimeError | |
QuotaExceeded | |
SKULimitExceeded | |
ServiceError | |
Unauthorized | |
Unspecified | |
ValidationFailure |
ErrorResponse
錯誤回應。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。
名稱 | 類型 | Description |
---|---|---|
error |
error 物件。 |
FeedbackRecordDTO
主動式學習意見反應記錄。
名稱 | 類型 | Description |
---|---|---|
qnaId |
integer (int32) |
提供建議問題的 qnaId 作為意見反應。 |
userId |
string |
使用者的唯一標識碼。 |
userQuestion |
string maxLength: 1000 |
提供意見反應的建議問題。 |
FeedbackRecordsDTO
主動式學習意見反應記錄。
名稱 | 類型 | Description |
---|---|---|
feedbackRecords |
意見反應記錄的清單。 |
InnerErrorModel
物件,包含有關錯誤的更特定資訊。 根據Microsoft一個 API 指導方針 - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses。
名稱 | 類型 | Description |
---|---|---|
code |
string |
比包含的錯誤所提供更明確的錯誤碼。 |
innerError |
物件,包含與目前對象有關錯誤更具體的資訊。 |