Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi @MarkEdmondson1234 ,
I found the original source of the error which was apparently due to a missing confidence score on one line of the transcript. So, to address, I updated
parse_async
with the same timings and transcripts mappings you had forparse_speech
, but addedifelse(!is.null(.x$confidence), .x$confidence,NA)
to handle the missing confidence score. Missing confidence scores are apparently a thing: https://groups.google.com/forum/#!topic/cloud-speech-discuss/LUg7Ky_Pq3s. Considering that I added the same code for transcript and updatedparse_speech
with the same changes. While I was in there I also cleaned up the alert messages onparse_async
. With this and the last pull requestparse-async
is called instead ofparse_speech
when thetype
includesLongRunningRecognize
;parse-async
should now have correct alerts and parse the result in the absence of confidence scores. I have not testedparse_speech
, but the modifications there are minimal.Note:
parse_speech
andparse_async
are now quite similar. I'm not sure of the original intention of the separation and whether both are truly needed. Prior to the last pull request it seems thatparse_speech
was being called for asynchronous transcriptions andparse_async
was unused.