-
Notifications
You must be signed in to change notification settings - Fork 598
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding Speech_Context to the Speech API stops Recogniztion #2036
Comments
Looks like your code specifying |
@LibertyBeta I believe @jmuk caught the issue with |
Actually, this does not seem to be resolved (at least in version 0.9.0 from npm)-trying to supply the speech context any which way (see below request config) results in the following error for me: Interestingly, passing the additional "profanityFilter" config param works fine.
|
We started using v1 of the Speech API (compared to v1beta1 previously), and it looks like it expects an array for That would mean: const request = {
config: {
encoding: encoding,
sampleRateHertz, sampleRateHertz,
profanityFilter: true,
speechContexts: [
{
phrases: ["dog", "cat"]
}
],
languageCode: languageCode
}
} Sorry for the trouble. I opened an issue to fix our links in the docs: #2219 |
Thanks for the quick reply. I can confirm that the configuration you supplied works as expected with the @google-cloud/speech NPM module version 0.9.0 |
It seems that the Speech Context config breaks the recognition stream.
Environment details
Steps to reproduce
google-cloud
.pipe()
audio stream to the Recognition StreamThe text was updated successfully, but these errors were encountered: