diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index a9fcd07c..e2c23777 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:9743664022bd63a8084be67f144898314c7ca12f0a03e422ac17c733c129d803 + digest: sha256:0ccd9f4d714d36e311f60f407199dd460e43a99a125b5ca64b1d75f6e5f8581b diff --git a/.github/sync-repo-settings.yaml b/.github/sync-repo-settings.yaml index 0ddb512d..3e98ae70 100644 --- a/.github/sync-repo-settings.yaml +++ b/.github/sync-repo-settings.yaml @@ -1,9 +1,9 @@ -# https://github.com/googleapis/repo-automation-bots/tree/master/packages/sync-repo-settings -# Rules for master branch protection +# https://github.com/googleapis/repo-automation-bots/tree/main/packages/sync-repo-settings +# Rules for main branch protection branchProtectionRules: # Identifies the protection rule pattern. Name of the branch to be protected. -# Defaults to `master` -- pattern: master +# Defaults to `main` +- pattern: main requiresCodeOwnerReviews: true requiresStrictStatusChecks: true requiredStatusCheckContexts: diff --git a/.kokoro/build.sh b/.kokoro/build.sh index 04e4d1f1..c5554cfc 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -41,7 +41,7 @@ python3 -m pip install --upgrade --quiet nox python3 -m nox --version # If this is a continuous build, send the test log to the FlakyBot. -# See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot. +# See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot. if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"continuous"* ]]; then cleanup() { chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot diff --git a/.kokoro/test-samples-impl.sh b/.kokoro/test-samples-impl.sh index 311a8d54..8a324c9c 100755 --- a/.kokoro/test-samples-impl.sh +++ b/.kokoro/test-samples-impl.sh @@ -80,7 +80,7 @@ for file in samples/**/requirements.txt; do EXIT=$? # If this is a periodic build, send the test log to the FlakyBot. - # See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot. + # See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot. if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot $KOKORO_GFILE_DIR/linux_amd64/flakybot diff --git a/CHANGELOG.md b/CHANGELOG.md index a031d48b..8954a076 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,18 @@ [1]: https://pypi.org/project/google-cloud-speech/#history +## [2.9.0](https://www.github.com/googleapis/python-speech/compare/v2.8.0...v2.9.0) (2021-09-20) + + +### Features + +* add output_config request field ([#252](https://www.github.com/googleapis/python-speech/issues/252)) ([b9f856e](https://www.github.com/googleapis/python-speech/commit/b9f856e93cbb926e9531639a9bb50c654ff1033e)) + + +### Documentation + +* **samples:** fixed model adaptation sample to correctly refer to custom classes ([#246](https://www.github.com/googleapis/python-speech/issues/246)) ([5fa2433](https://www.github.com/googleapis/python-speech/commit/5fa243358ec5688a40ef0d5abf3802acfa931ea7)) + ## [2.8.0](https://www.github.com/googleapis/python-speech/compare/v2.7.0...v2.8.0) (2021-08-19) diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index a23ded02..f42747d2 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -50,9 +50,9 @@ You'll have to create a development environment using a Git checkout: # Configure remotes such that you can pull changes from the googleapis/python-speech # repository into your local repository. $ git remote add upstream git@github.com:googleapis/python-speech.git - # fetch and merge changes from upstream into master + # fetch and merge changes from upstream into main $ git fetch upstream - $ git merge upstream/master + $ git merge upstream/main Now your local repo is set up such that you will push changes to your GitHub repo, from which you can submit a pull request. @@ -110,12 +110,12 @@ Coding Style variables:: export GOOGLE_CLOUD_TESTING_REMOTE="upstream" - export GOOGLE_CLOUD_TESTING_BRANCH="master" + export GOOGLE_CLOUD_TESTING_BRANCH="main" By doing this, you are specifying the location of the most up-to-date - version of ``python-speech``. The the suggested remote name ``upstream`` - should point to the official ``googleapis`` checkout and the - the branch should be the main branch on that remote (``master``). + version of ``python-speech``. The + remote name ``upstream`` should point to the official ``googleapis`` + checkout and the branch should be the default branch on that remote (``main``). - This repository contains configuration for the `pre-commit `__ tool, which automates checking @@ -209,7 +209,7 @@ The `description on PyPI`_ for the project comes directly from the ``README``. Due to the reStructuredText (``rst``) parser used by PyPI, relative links which will work on GitHub (e.g. ``CONTRIBUTING.rst`` instead of -``https://github.com/googleapis/python-speech/blob/master/CONTRIBUTING.rst``) +``https://github.com/googleapis/python-speech/blob/main/CONTRIBUTING.rst``) may cause problems creating links or rendering the description. .. _description on PyPI: https://pypi.org/project/google-cloud-speech @@ -234,7 +234,7 @@ We support: Supported versions can be found in our ``noxfile.py`` `config`_. -.. _config: https://github.com/googleapis/python-speech/blob/master/noxfile.py +.. _config: https://github.com/googleapis/python-speech/blob/main/noxfile.py We also explicitly decided to support Python 3 beginning with version 3.6. diff --git a/README.rst b/README.rst index 75f58941..761a2791 100644 --- a/README.rst +++ b/README.rst @@ -12,7 +12,7 @@ variants, to support your global user base. - `Product Documentation`_ .. |GA| image:: https://img.shields.io/badge/support-GA-gold.svg - :target: https://github.com/googleapis/google-cloud-python/blob/master/README.rst#general-availability + :target: https://github.com/googleapis/google-cloud-python/blob/main/README.rst#general-availability .. |pypi| image:: https://img.shields.io/pypi/v/google-cloud-speech.svg :target: https://pypi.org/project/google-cloud-speech/ .. |versions| image:: https://img.shields.io/pypi/pyversions/google-cloud-speech.svg diff --git a/docs/conf.py b/docs/conf.py index ce8d5df3..9bb17972 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -76,8 +76,8 @@ # The encoding of source files. # source_encoding = 'utf-8-sig' -# The master toctree document. -master_doc = "index" +# The root toctree document. +root_doc = "index" # General information about the project. project = "google-cloud-speech" @@ -280,7 +280,7 @@ # author, documentclass [howto, manual, or own class]). latex_documents = [ ( - master_doc, + root_doc, "google-cloud-speech.tex", "google-cloud-speech Documentation", author, @@ -314,13 +314,7 @@ # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). man_pages = [ - ( - master_doc, - "google-cloud-speech", - "google-cloud-speech Documentation", - [author], - 1, - ) + (root_doc, "google-cloud-speech", "google-cloud-speech Documentation", [author], 1,) ] # If true, show URL addresses after external links. @@ -334,7 +328,7 @@ # dir menu entry, description, category) texinfo_documents = [ ( - master_doc, + root_doc, "google-cloud-speech", "google-cloud-speech Documentation", author, diff --git a/google/cloud/speech/__init__.py b/google/cloud/speech/__init__.py index 129e45b7..4b717800 100644 --- a/google/cloud/speech/__init__.py +++ b/google/cloud/speech/__init__.py @@ -33,6 +33,7 @@ from google.cloud.speech_v1.types.cloud_speech import StreamingRecognitionResult from google.cloud.speech_v1.types.cloud_speech import StreamingRecognizeRequest from google.cloud.speech_v1.types.cloud_speech import StreamingRecognizeResponse +from google.cloud.speech_v1.types.cloud_speech import TranscriptOutputConfig from google.cloud.speech_v1.types.cloud_speech import WordInfo __all__ = ( @@ -54,5 +55,6 @@ "StreamingRecognitionResult", "StreamingRecognizeRequest", "StreamingRecognizeResponse", + "TranscriptOutputConfig", "WordInfo", ) diff --git a/google/cloud/speech_v1/__init__.py b/google/cloud/speech_v1/__init__.py index e4b1e2ea..5a9e4a6a 100644 --- a/google/cloud/speech_v1/__init__.py +++ b/google/cloud/speech_v1/__init__.py @@ -33,6 +33,7 @@ from .types.cloud_speech import StreamingRecognitionResult from .types.cloud_speech import StreamingRecognizeRequest from .types.cloud_speech import StreamingRecognizeResponse +from .types.cloud_speech import TranscriptOutputConfig from .types.cloud_speech import WordInfo from google.cloud.speech_v1.helpers import SpeechHelpers @@ -61,5 +62,6 @@ class SpeechClient(SpeechHelpers, SpeechClient): "StreamingRecognitionResult", "StreamingRecognizeRequest", "StreamingRecognizeResponse", + "TranscriptOutputConfig", "WordInfo", ) diff --git a/google/cloud/speech_v1/types/__init__.py b/google/cloud/speech_v1/types/__init__.py index 31843103..858051af 100644 --- a/google/cloud/speech_v1/types/__init__.py +++ b/google/cloud/speech_v1/types/__init__.py @@ -30,6 +30,7 @@ StreamingRecognitionResult, StreamingRecognizeRequest, StreamingRecognizeResponse, + TranscriptOutputConfig, WordInfo, ) @@ -50,5 +51,6 @@ "StreamingRecognitionResult", "StreamingRecognizeRequest", "StreamingRecognizeResponse", + "TranscriptOutputConfig", "WordInfo", ) diff --git a/google/cloud/speech_v1/types/cloud_speech.py b/google/cloud/speech_v1/types/cloud_speech.py index 51cbdd63..2fae477b 100644 --- a/google/cloud/speech_v1/types/cloud_speech.py +++ b/google/cloud/speech_v1/types/cloud_speech.py @@ -25,6 +25,7 @@ manifest={ "RecognizeRequest", "LongRunningRecognizeRequest", + "TranscriptOutputConfig", "StreamingRecognizeRequest", "StreamingRecognitionConfig", "RecognitionConfig", @@ -72,10 +73,31 @@ class LongRunningRecognizeRequest(proto.Message): request. audio (google.cloud.speech_v1.types.RecognitionAudio): Required. The audio data to be recognized. + output_config (google.cloud.speech_v1.types.TranscriptOutputConfig): + Optional. Specifies an optional destination + for the recognition results. """ config = proto.Field(proto.MESSAGE, number=1, message="RecognitionConfig",) audio = proto.Field(proto.MESSAGE, number=2, message="RecognitionAudio",) + output_config = proto.Field( + proto.MESSAGE, number=4, message="TranscriptOutputConfig", + ) + + +class TranscriptOutputConfig(proto.Message): + r"""Specifies an optional destination for the recognition + results. + + Attributes: + gcs_uri (str): + Specifies a Cloud Storage URI for the recognition results. + Must be specified in the format: + ``gs://bucket_name/object_name``, and the bucket must + already exist. + """ + + gcs_uri = proto.Field(proto.STRING, number=1, oneof="output_type",) class StreamingRecognizeRequest(proto.Message): diff --git a/renovate.json b/renovate.json index c0489556..c21036d3 100644 --- a/renovate.json +++ b/renovate.json @@ -1,6 +1,9 @@ { "extends": [ - "config:base", ":preserveSemverRanges" + "config:base", + "group:all", + ":preserveSemverRanges", + ":disableDependencyDashboard" ], "ignorePaths": [".pre-commit-config.yaml"], "pip_requirements": { diff --git a/samples/microphone/noxfile.py b/samples/microphone/noxfile.py index e73436a1..b008613f 100644 --- a/samples/microphone/noxfile.py +++ b/samples/microphone/noxfile.py @@ -39,17 +39,15 @@ TEST_CONFIG = { # You can opt out from the test for specific Python versions. - 'ignored_versions': [], - + "ignored_versions": [], # Old samples are opted out of enforcing Python type hints # All new samples should feature them - 'enforce_type_hints': False, - + "enforce_type_hints": False, # An envvar key for determining the project id to use. Change it # to 'BUILD_SPECIFIC_GCLOUD_PROJECT' if you want to opt in using a # build specific Cloud project. You can also use your own string # to use your own Cloud project. - 'gcloud_project_env': 'GOOGLE_CLOUD_PROJECT', + "gcloud_project_env": "GOOGLE_CLOUD_PROJECT", # 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT', # If you need to use a specific version of pip, # change pip_version_override to the string representation @@ -57,13 +55,13 @@ "pip_version_override": None, # A dictionary you want to inject into your test. Don't put any # secrets here. These values will override predefined values. - 'envs': {}, + "envs": {}, } try: # Ensure we can import noxfile_config in the project's directory. - sys.path.append('.') + sys.path.append(".") from noxfile_config import TEST_CONFIG_OVERRIDE except ImportError as e: print("No user noxfile_config found: detail: {}".format(e)) @@ -78,12 +76,12 @@ def get_pytest_env_vars() -> Dict[str, str]: ret = {} # Override the GCLOUD_PROJECT and the alias. - env_key = TEST_CONFIG['gcloud_project_env'] + env_key = TEST_CONFIG["gcloud_project_env"] # This should error out if not set. - ret['GOOGLE_CLOUD_PROJECT'] = os.environ[env_key] + ret["GOOGLE_CLOUD_PROJECT"] = os.environ[env_key] # Apply user supplied envs. - ret.update(TEST_CONFIG['envs']) + ret.update(TEST_CONFIG["envs"]) return ret @@ -92,11 +90,14 @@ def get_pytest_env_vars() -> Dict[str, str]: ALL_VERSIONS = ["3.6", "3.7", "3.8", "3.9"] # Any default versions that should be ignored. -IGNORED_VERSIONS = TEST_CONFIG['ignored_versions'] +IGNORED_VERSIONS = TEST_CONFIG["ignored_versions"] TESTED_VERSIONS = sorted([v for v in ALL_VERSIONS if v not in IGNORED_VERSIONS]) -INSTALL_LIBRARY_FROM_SOURCE = os.environ.get("INSTALL_LIBRARY_FROM_SOURCE", False) in ("True", "true") +INSTALL_LIBRARY_FROM_SOURCE = os.environ.get("INSTALL_LIBRARY_FROM_SOURCE", False) in ( + "True", + "true", +) # # Style Checks # @@ -141,7 +142,7 @@ def _determine_local_import_names(start_dir: str) -> List[str]: @nox.session def lint(session: nox.sessions.Session) -> None: - if not TEST_CONFIG['enforce_type_hints']: + if not TEST_CONFIG["enforce_type_hints"]: session.install("flake8", "flake8-import-order") else: session.install("flake8", "flake8-import-order", "flake8-annotations") @@ -150,9 +151,11 @@ def lint(session: nox.sessions.Session) -> None: args = FLAKE8_COMMON_ARGS + [ "--application-import-names", ",".join(local_names), - "." + ".", ] session.run("flake8", *args) + + # # Black # @@ -165,6 +168,7 @@ def blacken(session: nox.sessions.Session) -> None: session.run("black", *python_files) + # # Sample Tests # @@ -173,7 +177,9 @@ def blacken(session: nox.sessions.Session) -> None: PYTEST_COMMON_ARGS = ["--junitxml=sponge_log.xml"] -def _session_tests(session: nox.sessions.Session, post_install: Callable = None) -> None: +def _session_tests( + session: nox.sessions.Session, post_install: Callable = None +) -> None: if TEST_CONFIG["pip_version_override"]: pip_version = TEST_CONFIG["pip_version_override"] session.install(f"pip=={pip_version}") @@ -203,7 +209,7 @@ def _session_tests(session: nox.sessions.Session, post_install: Callable = None) # on travis where slow and flaky tests are excluded. # See http://doc.pytest.org/en/latest/_modules/_pytest/main.html success_codes=[0, 5], - env=get_pytest_env_vars() + env=get_pytest_env_vars(), ) @@ -213,9 +219,9 @@ def py(session: nox.sessions.Session) -> None: if session.python in TESTED_VERSIONS: _session_tests(session) else: - session.skip("SKIPPED: {} tests are disabled for this sample.".format( - session.python - )) + session.skip( + "SKIPPED: {} tests are disabled for this sample.".format(session.python) + ) # diff --git a/samples/microphone/requirements-test.txt b/samples/microphone/requirements-test.txt index b0cf7672..5d836a5c 100644 --- a/samples/microphone/requirements-test.txt +++ b/samples/microphone/requirements-test.txt @@ -1,2 +1,2 @@ -pytest==6.2.4 +pytest==6.2.5 mock==4.0.3 diff --git a/samples/microphone/requirements.txt b/samples/microphone/requirements.txt index a74cd184..08228d5b 100644 --- a/samples/microphone/requirements.txt +++ b/samples/microphone/requirements.txt @@ -1,4 +1,4 @@ -google-cloud-speech==2.7.0 +google-cloud-speech==2.8.0 pyaudio==0.2.11 six==1.16.0 diff --git a/samples/snippets/noxfile.py b/samples/snippets/noxfile.py index e73436a1..b008613f 100644 --- a/samples/snippets/noxfile.py +++ b/samples/snippets/noxfile.py @@ -39,17 +39,15 @@ TEST_CONFIG = { # You can opt out from the test for specific Python versions. - 'ignored_versions': [], - + "ignored_versions": [], # Old samples are opted out of enforcing Python type hints # All new samples should feature them - 'enforce_type_hints': False, - + "enforce_type_hints": False, # An envvar key for determining the project id to use. Change it # to 'BUILD_SPECIFIC_GCLOUD_PROJECT' if you want to opt in using a # build specific Cloud project. You can also use your own string # to use your own Cloud project. - 'gcloud_project_env': 'GOOGLE_CLOUD_PROJECT', + "gcloud_project_env": "GOOGLE_CLOUD_PROJECT", # 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT', # If you need to use a specific version of pip, # change pip_version_override to the string representation @@ -57,13 +55,13 @@ "pip_version_override": None, # A dictionary you want to inject into your test. Don't put any # secrets here. These values will override predefined values. - 'envs': {}, + "envs": {}, } try: # Ensure we can import noxfile_config in the project's directory. - sys.path.append('.') + sys.path.append(".") from noxfile_config import TEST_CONFIG_OVERRIDE except ImportError as e: print("No user noxfile_config found: detail: {}".format(e)) @@ -78,12 +76,12 @@ def get_pytest_env_vars() -> Dict[str, str]: ret = {} # Override the GCLOUD_PROJECT and the alias. - env_key = TEST_CONFIG['gcloud_project_env'] + env_key = TEST_CONFIG["gcloud_project_env"] # This should error out if not set. - ret['GOOGLE_CLOUD_PROJECT'] = os.environ[env_key] + ret["GOOGLE_CLOUD_PROJECT"] = os.environ[env_key] # Apply user supplied envs. - ret.update(TEST_CONFIG['envs']) + ret.update(TEST_CONFIG["envs"]) return ret @@ -92,11 +90,14 @@ def get_pytest_env_vars() -> Dict[str, str]: ALL_VERSIONS = ["3.6", "3.7", "3.8", "3.9"] # Any default versions that should be ignored. -IGNORED_VERSIONS = TEST_CONFIG['ignored_versions'] +IGNORED_VERSIONS = TEST_CONFIG["ignored_versions"] TESTED_VERSIONS = sorted([v for v in ALL_VERSIONS if v not in IGNORED_VERSIONS]) -INSTALL_LIBRARY_FROM_SOURCE = os.environ.get("INSTALL_LIBRARY_FROM_SOURCE", False) in ("True", "true") +INSTALL_LIBRARY_FROM_SOURCE = os.environ.get("INSTALL_LIBRARY_FROM_SOURCE", False) in ( + "True", + "true", +) # # Style Checks # @@ -141,7 +142,7 @@ def _determine_local_import_names(start_dir: str) -> List[str]: @nox.session def lint(session: nox.sessions.Session) -> None: - if not TEST_CONFIG['enforce_type_hints']: + if not TEST_CONFIG["enforce_type_hints"]: session.install("flake8", "flake8-import-order") else: session.install("flake8", "flake8-import-order", "flake8-annotations") @@ -150,9 +151,11 @@ def lint(session: nox.sessions.Session) -> None: args = FLAKE8_COMMON_ARGS + [ "--application-import-names", ",".join(local_names), - "." + ".", ] session.run("flake8", *args) + + # # Black # @@ -165,6 +168,7 @@ def blacken(session: nox.sessions.Session) -> None: session.run("black", *python_files) + # # Sample Tests # @@ -173,7 +177,9 @@ def blacken(session: nox.sessions.Session) -> None: PYTEST_COMMON_ARGS = ["--junitxml=sponge_log.xml"] -def _session_tests(session: nox.sessions.Session, post_install: Callable = None) -> None: +def _session_tests( + session: nox.sessions.Session, post_install: Callable = None +) -> None: if TEST_CONFIG["pip_version_override"]: pip_version = TEST_CONFIG["pip_version_override"] session.install(f"pip=={pip_version}") @@ -203,7 +209,7 @@ def _session_tests(session: nox.sessions.Session, post_install: Callable = None) # on travis where slow and flaky tests are excluded. # See http://doc.pytest.org/en/latest/_modules/_pytest/main.html success_codes=[0, 5], - env=get_pytest_env_vars() + env=get_pytest_env_vars(), ) @@ -213,9 +219,9 @@ def py(session: nox.sessions.Session) -> None: if session.python in TESTED_VERSIONS: _session_tests(session) else: - session.skip("SKIPPED: {} tests are disabled for this sample.".format( - session.python - )) + session.skip( + "SKIPPED: {} tests are disabled for this sample.".format(session.python) + ) # diff --git a/samples/snippets/requirements-test.txt b/samples/snippets/requirements-test.txt index 95ea1e6a..92709451 100644 --- a/samples/snippets/requirements-test.txt +++ b/samples/snippets/requirements-test.txt @@ -1 +1 @@ -pytest==6.2.4 +pytest==6.2.5 diff --git a/samples/snippets/requirements.txt b/samples/snippets/requirements.txt index 04681a0b..36664d5d 100644 --- a/samples/snippets/requirements.txt +++ b/samples/snippets/requirements.txt @@ -1,2 +1,2 @@ -google-cloud-speech==2.7.0 -google-cloud-storage==1.42.0 +google-cloud-speech==2.8.0 +google-cloud-storage==1.42.1 diff --git a/samples/snippets/speech_model_adaptation_beta.py b/samples/snippets/speech_model_adaptation_beta.py index 49fd4ad2..a3ac4e9d 100644 --- a/samples/snippets/speech_model_adaptation_beta.py +++ b/samples/snippets/speech_model_adaptation_beta.py @@ -34,7 +34,7 @@ def transcribe_with_model_adaptation( parent = f"projects/{project_id}/locations/{location}" # Create the custom class resource - custom_class_response = adaptation_client.create_custom_class( + adaptation_client.create_custom_class( { "parent": parent, "custom_class_id": custom_class_id, @@ -47,7 +47,9 @@ def transcribe_with_model_adaptation( }, } ) - custom_class_name = custom_class_response.name + custom_class_name = ( + f"projects/{project_id}/locations/{location}/customClasses/{custom_class_id}" + ) # Create the phrase set resource phrase_set_response = adaptation_client.create_phrase_set( { @@ -55,7 +57,9 @@ def transcribe_with_model_adaptation( "phrase_set_id": phrase_set_id, "phrase_set": { "boost": 10, - "phrases": [{"value": f"Visit restaurants like ${custom_class_name}"}], + "phrases": [ + {"value": f"Visit restaurants like ${{{custom_class_name}}}"} + ], }, } ) @@ -88,4 +92,5 @@ def transcribe_with_model_adaptation( print("Transcript: {}".format(result.alternatives[0].transcript)) # [END speech_transcribe_with_model_adaptation] + return response.results[0].alternatives[0].transcript diff --git a/scripts/fixup_speech_v1_keywords.py b/scripts/fixup_speech_v1_keywords.py index 385dac85..0ffcae10 100644 --- a/scripts/fixup_speech_v1_keywords.py +++ b/scripts/fixup_speech_v1_keywords.py @@ -39,7 +39,7 @@ def partition( class speechCallTransformer(cst.CSTTransformer): CTRL_PARAMS: Tuple[str] = ('retry', 'timeout', 'metadata') METHOD_TO_PARAMS: Dict[str, Tuple[str]] = { - 'long_running_recognize': ('config', 'audio', ), + 'long_running_recognize': ('config', 'audio', 'output_config', ), 'recognize': ('config', 'audio', ), 'streaming_recognize': ('streaming_config', 'audio_content', ), } diff --git a/setup.py b/setup.py index 0acb23dd..20ceadc6 100644 --- a/setup.py +++ b/setup.py @@ -22,7 +22,7 @@ name = "google-cloud-speech" description = "Google Cloud Speech API client library" -version = "2.8.0" +version = "2.9.0" # Should be one of: # 'Development Status :: 3 - Alpha' # 'Development Status :: 4 - Beta'