将Bing Spellchecker用于Luis.ai
我试图提高路易斯意图的预测准确性。因为缺少一个字母会导致路易斯的意图错误时存在问题。 我使用 apteredquery 在JSON返回表格Luis中。
期望:
"query": "bouk me a fliht to kayro",
"prediction": {
"alteredQuery": "book me a flight to cairo",
"topIntent": "book a flight",
"intents": {
"book a flight": {
"score": 0.9480589
}
"None": {
"score": 0.0332136229
}
},
"entities": {}
}
}
现实:
"query": "bouk me a fliht to kayro",
"prediction": {
"topIntent": "book a flight",
"intents": {
"book a flight": {
"score": 0.9480589
}
"None": {
"score": 0.0332136229
}
},
"entities": {}
}
}
这就是我的使用方式:
const luisConfig: LuisApplication = {
applicationId: [APP_ID_GOES_HERE],
endpointKey: [KEY_GOES_HERE],
endpoint: [ENDPOINT_GOES_HERE],
};
const recognizerOptions: LuisRecognizerOptionsV2 = {
apiVersion: 'v2',
bingSpellCheckSubscriptionKey: [KEY_GOES_HERE];
includeAllIntents: true,
log: true,
spellCheck: true,
log: true,
includeInstanceData: true
};
const luisRecognizer = new LuisRecognizer(luisConfig, recognizerOptions, true);
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我也有同样的问题...如果直接调用API:
响应没有对象为“更改”。
我还尝试使用更多的参数,结果相同:
如果我用OCP-APIM-Subscription-key头直接调用Bing API,它们会正确响应:
I have the same issue... if I call the API directly:
The response have not the object "alteredQuery".
Im also try with more parameters with the same result:
If I call directly the BING API with the Ocp-Apim-Subscription-Key header, they response correctly: