自然语言处理 NLP-意图理解:响应示例

时间:2024-01-17 15:35:04

响应示例

  • 成功响应示例
    {
        "result": {
            "confidence": 1,
            "label": "music",
            "slots": [
                {
                    "length": 3,
                    "normalized_word": "周杰伦",
                    "offset": 3,
                    "tag": "singer",
                    "word": "周杰伦"
                },
                {
                    "length": 3,
                    "normalized_word": "青花瓷",
                    "offset": 7,
                    "tag": "song",
                    "word": "青花瓷"
                }
            ],
            "text": "来一首周杰伦的青花瓷"
        }
    }
  • 失败响应示例
    {
        "error_code": "NLP.0101",
        "error_msg": "Authentication failed. Please verify the token"
    }
support.huaweicloud.com/api-nlp/nlp_03_0062.html