2
votes

Every 20 or so requests, I do not get a full query result. I am using the C# .NET recommended client library.

I get:

{ \"recognitionResult\": { \"messageType\": \"TRANSCRIPT\", \"transcript\": \"yeah\" } }
{ \"recognitionResult\": { \"messageType\": \"TRANSCRIPT\", \"transcript\": \"yeah\" } }
{ \"recognitionResult\": { \"messageType\": \"END_OF_SINGLE_UTTERANCE\" } }
{ \"queryResult\": { \"languageCode\": \"en-AU\" } }

In the Dialogflow history tab, it never shows this request being made. The issue seems to occur when the audio quality is not as great. In my situation, the audio will sometimes be bad quality. No gRPC error is thrown when this happens. I am assuming that this is an issue with the speech transcription since the the recognitionResult with isFinal is absent. The most recent partial result is accurate also.

What could cause this behaviour?

Is my only workaround to retry the request using text only and the most recent partial result? My application works in real time. I'd like to try and fix the problem though before working around the problem.

1

1 Answers

0
votes

You can see that the END_OF_SINGLE_UTTERANCE message type is received. This means that the speech paused/stopped or at least, it seems to do so (due to bad audio quality).

I would suggest to set single_utterance flag to false, it could help you get a more complete transcript. Here are the InputAudioConfig options for more information.