沃森没有得到零

DAE*_*aco 5 watson-conversation

假设我在IBM Watson中配置了一个会话服务,准备识别以单词和片段形式给出的数字.例如,如果我有号码1320,它可以作为thirteen twentythirteen two zero等发送.在第一种情况下,我会从对话服务中得到这样的信息:

{
    // ...
    "entities": [
        {
            "entity": "sys-number",
            "location": [
                0,
                5
            ],
            "value": "13",
            "confidence": 1,
            "metadata": {
                "numeric_value": 13
            }
        },
        {
            "entity": "sys-number",
            "location": [
                6,
                12
            ],
            "value": "20",
            "confidence": 1,
            "metadata": {
                "numeric_value": 20
            }
        }
    ]
    // ...
}
Run Code Online (Sandbox Code Playgroud)

在第二种情况下(thirteen two zero):

{
    // ...
    "entities": [
        {
            "entity": "sys-number",
            "location": [
                0,
                5
            ],
            "value": "13",
            "confidence": 1,
            "metadata": {
                "numeric_value": 13
            }
        },
        {
            "entity": "sys-number",
            "location": [
                6,
                14
            ],
            "value": "2",
            "confidence": 1,
            "metadata": {
                "numeric_value": 2
            }
        }
    ]
    // ...
}
Run Code Online (Sandbox Code Playgroud)

这里最大的问题是:我的零在哪里?

我知道这个问题不止一次被问过,但我找到的答案都没有解决我当前的问题.我已经看过可以使用正则表达式的例子,但这是实际的数字,这里我有单词而Watson实际上是猜测数字.

有没有办法在我的实体中获得该零的第三个条目?或另一项工作?或配置我可能缺乏?

小智 0

我刚刚在 Watson Assistant 中尝试过此操作,现在它的值为零。启用 @sys-numbers 后,我的话语是thirteen two zero,我得到这些实体:

entities: [
0: {
  entity: "sys-number", 
  location: [0, 8], 
  value: "13", 
  confidence: 1, 
  metadata: {numeric_value: 13}
}
1: {
  entity: "sys-number", 
  location: [9, 12], 
  value: "2", 
  confidence: 1, 
  metadata: {numeric_value: 2}
}
2: {
  entity: "sys-number", 
  location: [13, 17], 
  value: "0", 
  confidence: 1, 
  metadata: {numeric_value: 0}
}
]
Run Code Online (Sandbox Code Playgroud)

可能是实体匹配得到了改进。