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