When using the google speech to text API and utter a string of characters rather than words Google tries to derive words so if i say : okyjtbrx it transcribes that to Okay Why Jay brtx . Is there a way to force it to understand characters instead of words ?
-
1I'd recommend adding the tag GCP to this post, you might get some more responses. GCP is Google Cloud Platform which I'm assuming is hosting the Google Speech to text API. – Lucas Raza Feb 28 '20 at 19:03
1 Answers
You cannot directly force it to understand it as a string of characters; however, here are two suggestions you can follow that might help getting the desired result:
Speech-to-Text API
If you are using Speech API directly, you can use speech adaptation in your requests. This feature allows you to provide additional context to your recognition request giving phrases or classes that can help the recognition.
For your specific use case, you should take a look at the $OOV_CLASS_ALPHANUMERIC_SEQUENCE
, one of the class tokens available for some languages.
This option will tell the model that you're expecting in the request a sequence of letters [a-z] and digits.
Dialogflow
I'm adding this option because you included Dialogflow in the tags of the question. If the recognition is being done with Dialogflow, then you can use regex entities to try to match the user intent with a pattern defined by the regex.

- 2,760
- 1
- 12
- 18