Merge pull request #111 from rodrigorodriguez/master
fix(core.gbapp): MSFT changed again LUIS url.
This commit is contained in:
commit
9daadb2ac1
1 changed files with 2 additions and 5 deletions
|
@ -96,14 +96,11 @@ export class GBConversationalService implements IGBConversationalService {
|
||||||
// tslint:enable:no-unsafe-any
|
// tslint:enable:no-unsafe-any
|
||||||
|
|
||||||
public async routeNLP(step: GBDialogStep, min: GBMinInstance, text: string): Promise<boolean> {
|
public async routeNLP(step: GBDialogStep, min: GBMinInstance, text: string): Promise<boolean> {
|
||||||
// Invokes LUIS.
|
|
||||||
|
|
||||||
const endpoint = min.instance.nlpEndpoint.replace('/luis/v2.0', '');
|
|
||||||
|
|
||||||
const model = new LuisRecognizer({
|
const model = new LuisRecognizer({
|
||||||
applicationId: min.instance.nlpAppId,
|
applicationId: min.instance.nlpAppId,
|
||||||
endpointKey: min.instance.nlpKey,
|
endpointKey: min.instance.nlpKey,
|
||||||
endpoint: endpoint
|
endpoint: min.instance.nlpEndpoint
|
||||||
});
|
});
|
||||||
|
|
||||||
let nlp: RecognizerResult;
|
let nlp: RecognizerResult;
|
||||||
|
@ -118,7 +115,7 @@ export class GBConversationalService implements IGBConversationalService {
|
||||||
} else {
|
} else {
|
||||||
const msg = `Error calling NLP, check if you have a published model and assigned keys. Error: ${
|
const msg = `Error calling NLP, check if you have a published model and assigned keys. Error: ${
|
||||||
error.statusCode ? error.statusCode : ''
|
error.statusCode ? error.statusCode : ''
|
||||||
} {error.message; }`;
|
} {error.message; }`;
|
||||||
|
|
||||||
return Promise.reject(new Error(msg));
|
return Promise.reject(new Error(msg));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue