1

/annotateText Concept Insights 调用示例提供以下示例输出:

curl -H 'Content-Type: text/plain' -d 'IBM announces new Watson services.' 

'https://watson-api-explorer.mybluemix.net/concept-insights/api/v2/graphs/wikipedia/en-20120601/annotate_text'

{
  "annotations": [
    {
      "concept": {
        "id": "/graphs/wikipedia/en-20120601/concepts/Watson_(computer)",
        "label": "Watson (computer)"
      },
      "score": 0.99832845,
      "text_index": [
        18,
        24
      ]
    },
    {
      "concept": {
        "id": "/graphs/wikipedia/en-20120601/concepts/IBM",
        "label": "IBM"
      },
      "score": 0.9980473,
      "text_index": [
        0,
        3
      ]
    }
  ]
}

text_index返回的参数的含义是什么?

4

1 回答 1

2

text_index告诉您已识别概念的开始和结束位置。

在您的示例中,该概念IBM_Watson已在片段中标识IBM announces new Watson

于 2015-12-11T07:28:42.777 回答