Text Classification Interface
Description
This interface is invoked by third-party access systems to implement the text classification capability and can be used in intelligent case classification scenarios.
Before invoking the text classification interface, commission the text classification function. For details, see OIAP VXXXRXXXCXX Product Documentation 01.
Interface Method
POST
URL
https://IP:PORT/oifde/rest/api/textClassification
Request
Parameter |
Type |
Position |
Mandatory |
Description |
---|---|---|---|---|
tenantId |
String |
Body |
Yes |
Tenant ID. |
language |
String |
Body |
Yes |
Language. The options are as follows:
Note: In intelligent case classification scenarios, the languages supported by the LODAS text classification model are used. |
text |
String |
Body |
Yes |
Statement. Basis for text classification. The value can contain a maximum of 4096 characters. |
authToken |
String |
Body |
Yes |
Authentication token. For details, see C3 OIAP Interface Authentication. |
Response
Parameter |
Type |
Position |
Mandatory |
Description |
---|---|---|---|---|
results |
TextLabel[] |
Body |
Yes |
Text classification result. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
label |
Yes |
String |
Classification tag. Intelligent case classification scenario, that is, case type name. |
probability |
Yes |
Long |
Matching degree. The value ranges from 0 to 1. |
Example
- Request
{ "tenantId":"fangyg", "language":"zh_CN", "text":"Failed to issue the invoice.", "authToken":"XI0*******************lYbYACW" }
- Response
{ "results": [ { "label": "Mobile business → Basic service → Electronic invoice → Global transfer → Function usage → Invoice printing failure → Global transfer", "probability": 0.41408610343933105 }, { "label": "Mobile business → Service touch point → One-point interconnection business → Global transfer → Business rules → Unsatisfied with business regulations/flows → Global transfer", "probability": 0.012493142858147621 }, { "label": "Mobile business → Business marketing → Tariff package → Downgrade package → Handling specifications → Restricted channel handling disapproval → Global transfer", "probability": 0.004905845504254103 } ] }
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