n.NoMatch) {
                            reject("No speech could be recognized");
                        } else if (result.reason == SpeechSDK.ResultReason.Canceled) {
                            reject(`Speech Recognition canceled: ${result.errorDetails}`);
                        }
                        resolve(convertReferenceWords(referenceText, referenceWords));
                        speechRecognizer.close();
                    },
                    (err) => {
                        reject(err)