在AWS中,Lex有一个汽车插槽类型。价值是租用,出租车。对于出租车,我已经定义了像“minicab,taxicab,uber”这样的同义词。当我输入迷你车或出租车时,Lex将其识别为出租车,但是当我输入超级车时,它并不被认为是出租车的同义词。
这是我配置的同义词选项:出租车,迷你车,出租车,超级
除了超级以外,所有同义词都被识别。知道为什么吗?这是某个保留的词吗?
我按照要求为插槽添加完整的json: 这是插槽的完整json:
{
"name": "BankBotCarServiceType",
"description": "car service the user is hiring - hire or taxi or chauffeured or rickshaws",
"enumerationValues": [
{"value": "Rickshaws", "synonyms": ["tuk tuk", "scooter", "moped", "auto", "auto rickshaw"]},
{"value": "Chauffeured car", "synonyms": ["chauffeur"]},
{"value": "Hire", "synonyms": ["car hire", "rent", "self drive", "self-drive", "you-drive", "u-drive", "rent a car", "rented vehicle"]},
{"value": "Taxi", "synonyms": ["taxis", "minicab", "taxicab", "Uber", "uber", "uberX"]}
],
"checksum": "XXXXXXXX",
"valueSelectionStrategy": "TOP_RESOLUTION"
}
答案 0 :(得分:2)
我与AWS团队保持联系,他们已经确认我这是Lex的错误。这需要他们的帮助,他们正积极致力于此。我们将在推出更新时更新此内容。
亚马逊团队的最新消息:亚马逊开发团队已经确认他们已经部署了修复程序,现在应该可以正常运行。