Knowledge source tracing
Function
Knowledge Source Tracing API
URI
POST /v1/{project_id}/applications/{application_id}/uni-search/multimodal/rac
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Definition: Project ID. For details about how to obtain the project ID, see Obtaining a Project ID. Constraints: N/A Value range: The value can contain 1 to 64 characters. Only digits, letters, hyphens (-), and underscores (_) are allowed. The value must start with a letter. Default value: N/A |
|
application_id |
Yes |
String |
Definition: Application ID. For details about how to obtain the application ID, see Obtaining an Application ID. Constraints: Character string Value range: The value can contain 1 to 64 characters. Only digits, letters, hyphens (-), and underscores (_) are allowed. The value must start with a letter. Default value: N/A |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
traceid |
No |
String |
Definition: Unique ID of a request Constraints: N/A Value range: 0 to 64 characters Default value: N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
query |
Yes |
String |
Definition: User query Constraints: N/A Value range: The length cannot exceed 4,096 characters. Default value: N/A |
|
answer |
Yes |
String |
Definition: Generate complete sentences. Constraints: N/A Value range: 1 to 4096 characters. Default value: N/A |
|
docs |
Yes |
Array of DocItem objects |
Definition: Reference list Constraints: N/A Value range: 1 to 40 references Default value: N/A |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
index |
Array of integers |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Definition: Value range: N/A |
|
error_msg |
String |
Definition: Error message. Value range: N/A |
Status code: 500
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Definition: Value range: N/A |
|
error_msg |
String |
Definition: Error message. Value range: N/A |
Example Requests
Request body
/v1/{project_id}/applications/{application_id}/uni-search/multimodal/rac
{
"query" : "What is the overall business process?",
"answer" : "1. **Platform signing**: The platform customer signs the e-payment agreement. The account manager enters the customer information, payment collection information, payment tool, payment method, and charging information.",
"docs" : [ {
"type" : "Document",
"metadata" : {
"title" : "Section 1 General Business Process of Chapter 2 Business Process",
"content" : "Select the settlement account and payment method, enter the related income and expenditure declaration information, and pay to the overseas payee.\n3. Payment result query\nThe enterprise online banking and enterprise mobile banking provide the functions of querying payment details and instructions for customers to meet their reconciliation requirements.",
"doc_name" : "Product Manual .doc",
"chunk_id" : "6a7b8d101d464fe093212bc2b6baf725"
}
}, {
"type" : "Document",
"metadata" : {
"title" : "Section 2 Partner Admission, Contract Signing, and Agreement Maintenance (1) of Chapter 2 Business Process",
"content" : "Payment result query\nThe enterprise online banking and enterprise mobile banking provide the functions of querying payment details and instructions for customers to meet their reconciliation requirements.",
"doc_name" : "Product Manual .doc",
"chunk_id" : "30a1b1edef1049a6b3311a3a622ff920"
}
}, {
"type" : "Document",
"metadata" : {
"title" : "Section 2 Partner Admission, Contract Signing, and Agreement Maintenance (2) of Chapter 2 Business Process",
"content" : "Payment result query\nThe enterprise online banking and enterprise mobile banking provide the functions of querying payment details and instructions for customers to meet their reconciliation requirements.",
"doc_name" : "Product Manual .doc",
"chunk_id" : "3a364d93684b4e4f8a1b18c954728c63"
}
} ]
}
Example Responses
Status code: 200
Reference response
{
"index" : [ 1 ]
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Reference response |
|
400 |
Incorrect request parameter |
|
500 |
Internal error |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot