diff --git a/CHANGELOG.md b/CHANGELOG.md index a6e387c..ee08ce5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +### [0.6.1](https://github.com/googleapis/python-data-qna/compare/v0.6.0...v0.6.1) (2022-02-26) + + +### Documentation + +* add generated snippets ([#121](https://github.com/googleapis/python-data-qna/issues/121)) ([6e1fac9](https://github.com/googleapis/python-data-qna/commit/6e1fac9085d7c9b931b121ac4969cece1d3b7fba)) + ## [0.6.0](https://github.com/googleapis/python-data-qna/compare/v0.5.1...v0.6.0) (2022-02-03) diff --git a/google/cloud/dataqna/__init__.py b/google/cloud/dataqna/__init__.py index c4b824e..cec6e4a 100644 --- a/google/cloud/dataqna/__init__.py +++ b/google/cloud/dataqna/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/__init__.py b/google/cloud/dataqna_v1alpha/__init__.py index 46b3227..a47123c 100644 --- a/google/cloud/dataqna_v1alpha/__init__.py +++ b/google/cloud/dataqna_v1alpha/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/__init__.py b/google/cloud/dataqna_v1alpha/services/__init__.py index 4de6597..e8e1c38 100644 --- a/google/cloud/dataqna_v1alpha/services/__init__.py +++ b/google/cloud/dataqna_v1alpha/services/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/__init__.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/__init__.py index 36d9bc8..db76801 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/__init__.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/async_client.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/async_client.py index b737c86..675420d 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/async_client.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/async_client.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -284,6 +284,26 @@ async def suggest_queries( r"""Gets a list of suggestions based on a prefix string. AutoSuggestion tolerance should be less than 1 second. + + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = client.suggest_queries(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.SuggestQueriesRequest, dict]): The request object. Request for query suggestions. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/client.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/client.py index bd50dfc..e978cc6 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/client.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/client.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -466,6 +466,26 @@ def suggest_queries( r"""Gets a list of suggestions based on a prefix string. AutoSuggestion tolerance should be less than 1 second. + + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = client.suggest_queries(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.SuggestQueriesRequest, dict]): The request object. Request for query suggestions. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/__init__.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/__init__.py index ef507ef..31dca25 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/__init__.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/base.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/base.py index 5445509..8d4f914 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/base.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/base.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc.py index d68fe6e..caa5d91 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc_asyncio.py b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc_asyncio.py index 87826d6..721b7aa 100644 --- a/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc_asyncio.py +++ b/google/cloud/dataqna_v1alpha/services/auto_suggestion_service/transports/grpc_asyncio.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/__init__.py b/google/cloud/dataqna_v1alpha/services/question_service/__init__.py index 8de2e92..3bea59c 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/__init__.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/async_client.py b/google/cloud/dataqna_v1alpha/services/question_service/async_client.py index a486dd1..214492e 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/async_client.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/async_client.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -240,6 +240,25 @@ async def get_question( ) -> question.Question: r"""Gets a previously created question. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = client.get_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.GetQuestionRequest, dict]): The request object. A request to get a previously @@ -315,6 +334,30 @@ async def create_question( ) -> gcd_question.Question: r"""Creates a question. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = client.create_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.CreateQuestionRequest, dict]): The request object. Request to create a question @@ -398,6 +441,26 @@ async def execute_question( ) -> question.Question: r"""Executes an interpretation. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = client.execute_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.ExecuteQuestionRequest, dict]): The request object. Request to execute an @@ -481,6 +544,25 @@ async def get_user_feedback( ) -> user_feedback.UserFeedback: r"""Gets previously created user feedback. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = client.get_user_feedback(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.GetUserFeedbackRequest, dict]): The request object. Request to get user feedback. @@ -553,6 +635,29 @@ async def update_user_feedback( r"""Updates user feedback. This creates user feedback if there was none before (upsert). + + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = client.update_user_feedback(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.UpdateUserFeedbackRequest, dict]): The request object. Request to updates user feedback. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/client.py b/google/cloud/dataqna_v1alpha/services/question_service/client.py index 73d7b33..fc0f5c0 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/client.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/client.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -449,6 +449,25 @@ def get_question( ) -> question.Question: r"""Gets a previously created question. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = client.get_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.GetQuestionRequest, dict]): The request object. A request to get a previously @@ -524,6 +543,30 @@ def create_question( ) -> gcd_question.Question: r"""Creates a question. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = client.create_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.CreateQuestionRequest, dict]): The request object. Request to create a question @@ -607,6 +650,26 @@ def execute_question( ) -> question.Question: r"""Executes an interpretation. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = client.execute_question(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.ExecuteQuestionRequest, dict]): The request object. Request to execute an @@ -690,6 +753,25 @@ def get_user_feedback( ) -> user_feedback.UserFeedback: r"""Gets previously created user feedback. + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = client.get_user_feedback(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.GetUserFeedbackRequest, dict]): The request object. Request to get user feedback. @@ -762,6 +844,29 @@ def update_user_feedback( r"""Updates user feedback. This creates user feedback if there was none before (upsert). + + .. code-block:: python + + from google.cloud import dataqna_v1alpha + + def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = client.update_user_feedback(request=request) + + # Handle the response + print(response) + Args: request (Union[google.cloud.dataqna_v1alpha.types.UpdateUserFeedbackRequest, dict]): The request object. Request to updates user feedback. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/transports/__init__.py b/google/cloud/dataqna_v1alpha/services/question_service/transports/__init__.py index dee15de..45be22a 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/transports/__init__.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/transports/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/transports/base.py b/google/cloud/dataqna_v1alpha/services/question_service/transports/base.py index 6276b04..2c4c790 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/transports/base.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/transports/base.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc.py b/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc.py index 650cb87..0eb6998 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc_asyncio.py b/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc_asyncio.py index 74a9b22..bc8b92c 100644 --- a/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc_asyncio.py +++ b/google/cloud/dataqna_v1alpha/services/question_service/transports/grpc_asyncio.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/__init__.py b/google/cloud/dataqna_v1alpha/types/__init__.py index df3351a..eeafb1f 100644 --- a/google/cloud/dataqna_v1alpha/types/__init__.py +++ b/google/cloud/dataqna_v1alpha/types/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/annotated_string.py b/google/cloud/dataqna_v1alpha/types/annotated_string.py index c144ec9..753d86e 100644 --- a/google/cloud/dataqna_v1alpha/types/annotated_string.py +++ b/google/cloud/dataqna_v1alpha/types/annotated_string.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/auto_suggestion_service.py b/google/cloud/dataqna_v1alpha/types/auto_suggestion_service.py index b33666a..05d11db 100644 --- a/google/cloud/dataqna_v1alpha/types/auto_suggestion_service.py +++ b/google/cloud/dataqna_v1alpha/types/auto_suggestion_service.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/question.py b/google/cloud/dataqna_v1alpha/types/question.py index 9b600d8..1f70933 100644 --- a/google/cloud/dataqna_v1alpha/types/question.py +++ b/google/cloud/dataqna_v1alpha/types/question.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/question_service.py b/google/cloud/dataqna_v1alpha/types/question_service.py index 2e0cfde..da1f0b7 100644 --- a/google/cloud/dataqna_v1alpha/types/question_service.py +++ b/google/cloud/dataqna_v1alpha/types/question_service.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/google/cloud/dataqna_v1alpha/types/user_feedback.py b/google/cloud/dataqna_v1alpha/types/user_feedback.py index 9fea580..cb99cb4 100644 --- a/google/cloud/dataqna_v1alpha/types/user_feedback.py +++ b/google/cloud/dataqna_v1alpha/types/user_feedback.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_async.py new file mode 100644 index 0000000..486d928 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SuggestQueries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_AutoSuggestionService_SuggestQueries_async] +from google.cloud import dataqna_v1alpha + + +async def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = await client.suggest_queries(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_AutoSuggestionService_SuggestQueries_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_sync.py new file mode 100644 index 0000000..5d28446 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_auto_suggestion_service_suggest_queries_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SuggestQueries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_AutoSuggestionService_SuggestQueries_sync] +from google.cloud import dataqna_v1alpha + + +def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = client.suggest_queries(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_AutoSuggestionService_SuggestQueries_sync] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_async.py new file mode 100644 index 0000000..9055e84 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_CreateQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = await client.create_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_CreateQuestion_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_sync.py new file mode 100644 index 0000000..d7c6c54 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_create_question_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_CreateQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = client.create_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_CreateQuestion_sync] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_async.py new file mode 100644 index 0000000..ed2cbf2 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExecuteQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_ExecuteQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = await client.execute_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_ExecuteQuestion_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_sync.py new file mode 100644 index 0000000..dae9790 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_execute_question_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExecuteQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_ExecuteQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = client.execute_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_ExecuteQuestion_sync] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_async.py new file mode 100644 index 0000000..1cb56b7 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_GetQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = await client.get_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_GetQuestion_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_sync.py new file mode 100644 index 0000000..67bb0e5 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_question_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_GetQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = client.get_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_GetQuestion_sync] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_async.py new file mode 100644 index 0000000..378c64f --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_GetUserFeedback_async] +from google.cloud import dataqna_v1alpha + + +async def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = await client.get_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_GetUserFeedback_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_sync.py new file mode 100644 index 0000000..e466d36 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_get_user_feedback_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_GetUserFeedback_sync] +from google.cloud import dataqna_v1alpha + + +def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = client.get_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_GetUserFeedback_sync] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_async.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_async.py new file mode 100644 index 0000000..b6b2608 --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_async.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_UpdateUserFeedback_async] +from google.cloud import dataqna_v1alpha + + +async def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = await client.update_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_UpdateUserFeedback_async] diff --git a/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_sync.py b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_sync.py new file mode 100644 index 0000000..abb2e8a --- /dev/null +++ b/samples/generated_samples/dataqna_generated_dataqna_v1alpha_question_service_update_user_feedback_sync.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_generated_dataqna_v1alpha_QuestionService_UpdateUserFeedback_sync] +from google.cloud import dataqna_v1alpha + + +def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = client.update_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_generated_dataqna_v1alpha_QuestionService_UpdateUserFeedback_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_async.py b/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_async.py new file mode 100644 index 0000000..f8c0f20 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SuggestQueries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_async] +from google.cloud import dataqna_v1alpha + + +async def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = await client.suggest_queries(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_sync.py new file mode 100644 index 0000000..3ccda08 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SuggestQueries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_sync] +from google.cloud import dataqna_v1alpha + + +def sample_suggest_queries(): + # Create a client + client = dataqna_v1alpha.AutoSuggestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.SuggestQueriesRequest( + parent="parent_value", + ) + + # Make the request + response = client.suggest_queries(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_async.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_async.py new file mode 100644 index 0000000..5e85d96 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_CreateQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = await client.create_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_CreateQuestion_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_sync.py new file mode 100644 index 0000000..27de918 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_create_question_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_CreateQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_create_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + question = dataqna_v1alpha.Question() + question.scopes = ['scopes_value_1', 'scopes_value_2'] + question.query = "query_value" + + request = dataqna_v1alpha.CreateQuestionRequest( + parent="parent_value", + question=question, + ) + + # Make the request + response = client.create_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_CreateQuestion_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_async.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_async.py new file mode 100644 index 0000000..cd1b1f4 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExecuteQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = await client.execute_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_sync.py new file mode 100644 index 0000000..5b4a5cc --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_execute_question_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExecuteQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_execute_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.ExecuteQuestionRequest( + name="name_value", + interpretation_index=2159, + ) + + # Make the request + response = client.execute_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_async.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_async.py new file mode 100644 index 0000000..6ae1216 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_GetQuestion_async] +from google.cloud import dataqna_v1alpha + + +async def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = await client.get_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_GetQuestion_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_sync.py new file mode 100644 index 0000000..250c851 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_question_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetQuestion +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_GetQuestion_sync] +from google.cloud import dataqna_v1alpha + + +def sample_get_question(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetQuestionRequest( + name="name_value", + ) + + # Make the request + response = client.get_question(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_GetQuestion_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_async.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_async.py new file mode 100644 index 0000000..1a05f67 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_GetUserFeedback_async] +from google.cloud import dataqna_v1alpha + + +async def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = await client.get_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_GetUserFeedback_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_sync.py new file mode 100644 index 0000000..7f7b167 --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_get_user_feedback_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_GetUserFeedback_sync] +from google.cloud import dataqna_v1alpha + + +def sample_get_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + request = dataqna_v1alpha.GetUserFeedbackRequest( + name="name_value", + ) + + # Make the request + response = client.get_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_GetUserFeedback_sync] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_async.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_async.py new file mode 100644 index 0000000..6b277bf --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_async.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_async] +from google.cloud import dataqna_v1alpha + + +async def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceAsyncClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = await client.update_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_async] diff --git a/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_sync.py b/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_sync.py new file mode 100644 index 0000000..64b2bbf --- /dev/null +++ b/samples/generated_samples/dataqna_v1alpha_generated_question_service_update_user_feedback_sync.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateUserFeedback +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-dataqna + + +# [START dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_sync] +from google.cloud import dataqna_v1alpha + + +def sample_update_user_feedback(): + # Create a client + client = dataqna_v1alpha.QuestionServiceClient() + + # Initialize request argument(s) + user_feedback = dataqna_v1alpha.UserFeedback() + user_feedback.name = "name_value" + + request = dataqna_v1alpha.UpdateUserFeedbackRequest( + user_feedback=user_feedback, + ) + + # Make the request + response = client.update_user_feedback(request=request) + + # Handle the response + print(response) + +# [END dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_sync] diff --git a/samples/generated_samples/snippet_metadata_dataqna_v1alpha.json b/samples/generated_samples/snippet_metadata_dataqna_v1alpha.json new file mode 100644 index 0000000..689aa34 --- /dev/null +++ b/samples/generated_samples/snippet_metadata_dataqna_v1alpha.json @@ -0,0 +1,538 @@ +{ + "snippets": [ + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "AutoSuggestionService" + }, + "shortName": "SuggestQueries" + } + }, + "file": "dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_async.py", + "regionTag": "dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "AutoSuggestionService" + }, + "shortName": "SuggestQueries" + } + }, + "file": "dataqna_v1alpha_generated_auto_suggestion_service_suggest_queries_sync.py", + "regionTag": "dataqna_v1alpha_generated_AutoSuggestionService_SuggestQueries_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "CreateQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_create_question_async.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_CreateQuestion_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "CreateQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_create_question_sync.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_CreateQuestion_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "ExecuteQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_execute_question_async.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "ExecuteQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_execute_question_sync.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_ExecuteQuestion_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "GetQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_get_question_async.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_GetQuestion_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "GetQuestion" + } + }, + "file": "dataqna_v1alpha_generated_question_service_get_question_sync.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_GetQuestion_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "GetUserFeedback" + } + }, + "file": "dataqna_v1alpha_generated_question_service_get_user_feedback_async.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_GetUserFeedback_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "GetUserFeedback" + } + }, + "file": "dataqna_v1alpha_generated_question_service_get_user_feedback_sync.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_GetUserFeedback_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "UpdateUserFeedback" + } + }, + "file": "dataqna_v1alpha_generated_question_service_update_user_feedback_async.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_async", + "segments": [ + { + "end": 47, + "start": 27, + "type": "FULL" + }, + { + "end": 47, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 41, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 44, + "start": 42, + "type": "REQUEST_EXECUTION" + }, + { + "end": 48, + "start": 45, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "QuestionService" + }, + "shortName": "UpdateUserFeedback" + } + }, + "file": "dataqna_v1alpha_generated_question_service_update_user_feedback_sync.py", + "regionTag": "dataqna_v1alpha_generated_QuestionService_UpdateUserFeedback_sync", + "segments": [ + { + "end": 47, + "start": 27, + "type": "FULL" + }, + { + "end": 47, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 41, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 44, + "start": 42, + "type": "REQUEST_EXECUTION" + }, + { + "end": 48, + "start": 45, + "type": "RESPONSE_HANDLING" + } + ] + } + ] +} diff --git a/scripts/fixup_dataqna_v1alpha_keywords.py b/scripts/fixup_dataqna_v1alpha_keywords.py index 8b84330..abe5eb7 100644 --- a/scripts/fixup_dataqna_v1alpha_keywords.py +++ b/scripts/fixup_dataqna_v1alpha_keywords.py @@ -1,6 +1,6 @@ #! /usr/bin/env python3 # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/setup.py b/setup.py index bb697c0..4bf63a6 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ import os import setuptools # type: ignore -version = "0.6.0" +version = "0.6.1" package_root = os.path.abspath(os.path.dirname(__file__)) diff --git a/tests/__init__.py b/tests/__init__.py index 4de6597..e8e1c38 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/tests/unit/__init__.py b/tests/unit/__init__.py index 4de6597..e8e1c38 100644 --- a/tests/unit/__init__.py +++ b/tests/unit/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/tests/unit/gapic/__init__.py b/tests/unit/gapic/__init__.py index 4de6597..e8e1c38 100644 --- a/tests/unit/gapic/__init__.py +++ b/tests/unit/gapic/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/tests/unit/gapic/dataqna_v1alpha/__init__.py b/tests/unit/gapic/dataqna_v1alpha/__init__.py index 4de6597..e8e1c38 100644 --- a/tests/unit/gapic/dataqna_v1alpha/__init__.py +++ b/tests/unit/gapic/dataqna_v1alpha/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/tests/unit/gapic/dataqna_v1alpha/test_auto_suggestion_service.py b/tests/unit/gapic/dataqna_v1alpha/test_auto_suggestion_service.py index 0b1f6e2..ce664c5 100644 --- a/tests/unit/gapic/dataqna_v1alpha/test_auto_suggestion_service.py +++ b/tests/unit/gapic/dataqna_v1alpha/test_auto_suggestion_service.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. diff --git a/tests/unit/gapic/dataqna_v1alpha/test_question_service.py b/tests/unit/gapic/dataqna_v1alpha/test_question_service.py index dc7a25a..e1d9ae6 100644 --- a/tests/unit/gapic/dataqna_v1alpha/test_question_service.py +++ b/tests/unit/gapic/dataqna_v1alpha/test_question_service.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright 2020 Google LLC +# Copyright 2022 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License.