Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions google/cloud/aiplatform_v1/types/reasoning_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,9 @@ class ReasoningEngineSpec(proto.Message):
If not specified, the ``service_account`` field will be used
if set, otherwise the default Vertex AI Reasoning Engine
Service Agent in the project will be used.
build_spec (google.cloud.aiplatform_v1.types.ReasoningEngineSpec.BuildSpec):
Optional. Configuration for building
container image.
"""

class IdentityType(proto.Enum):
Expand Down Expand Up @@ -444,6 +447,37 @@ class ContainerSpec(proto.Message):
number=1,
)

class BuildSpec(proto.Message):
r"""Specification for building container image.

Attributes:
worker_pool (str):
Optional. The resource name of the Cloud Build WorkerPool to
use for the build. Format:
``projects/{project}/locations/{location}/workerPools/{worker_pool}``
service_account (str):
Optional. The service account that Cloud Build uses to run
the build.

This field is only applicable when ``worker_pool`` is
specified (i.e., for custom worker pools). If
``worker_pool`` is not specified, this field is ignored and
the build runs using the Google-managed service agent.

Format:
``projects/{project}/serviceAccounts/{service_account}`` or
``{service_account}@{project}.iam.gserviceaccount.com``
"""

worker_pool: str = proto.Field(
proto.STRING,
number=1,
)
service_account: str = proto.Field(
proto.STRING,
number=2,
)

source_code_spec: SourceCodeSpec = proto.Field(
proto.MESSAGE,
number=11,
Expand Down Expand Up @@ -485,6 +519,11 @@ class ContainerSpec(proto.Message):
number=12,
enum=IdentityType,
)
build_spec: BuildSpec = proto.Field(
proto.MESSAGE,
number=16,
message=BuildSpec,
)


class ReasoningEngine(proto.Message):
Expand Down
39 changes: 39 additions & 0 deletions google/cloud/aiplatform_v1beta1/types/reasoning_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ class ReasoningEngineSpec(proto.Message):
If not specified, the ``service_account`` field will be used
if set, otherwise the default Vertex AI Reasoning Engine
Service Agent in the project will be used.
build_spec (google.cloud.aiplatform_v1beta1.types.ReasoningEngineSpec.BuildSpec):
Optional. Configuration for building
container image.
"""

class IdentityType(proto.Enum):
Expand Down Expand Up @@ -446,6 +449,37 @@ class ContainerSpec(proto.Message):
number=1,
)

class BuildSpec(proto.Message):
r"""Specification for building container image.

Attributes:
worker_pool (str):
Optional. The resource name of the Cloud Build WorkerPool to
use for the build. Format:
``projects/{project}/locations/{location}/workerPools/{worker_pool}``
service_account (str):
Optional. The service account that Cloud Build uses to run
the build.

This field is only applicable when ``worker_pool`` is
specified (i.e., for custom worker pools). If
``worker_pool`` is not specified, this field is ignored and
the build runs using the Google-managed service agent.

Format:
``projects/{project}/serviceAccounts/{service_account}`` or
``{service_account}@{project}.iam.gserviceaccount.com``
"""

worker_pool: str = proto.Field(
proto.STRING,
number=1,
)
service_account: str = proto.Field(
proto.STRING,
number=2,
)

source_code_spec: SourceCodeSpec = proto.Field(
proto.MESSAGE,
number=11,
Expand Down Expand Up @@ -487,6 +521,11 @@ class ContainerSpec(proto.Message):
number=12,
enum=IdentityType,
)
build_spec: BuildSpec = proto.Field(
proto.MESSAGE,
number=16,
message=BuildSpec,
)


class ReasoningEngine(proto.Message):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4102,7 +4102,7 @@ def test_create_reasoning_engine_rest_call_success(request_type):

# send a request that will satisfy transcoding
request_init = {'parent': 'projects/sample1/locations/sample2'}
request_init["reasoning_engine"] = {'name': 'name_value', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
request_init["reasoning_engine"] = {'name': 'name_value', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2, 'build_spec': {'worker_pool': 'worker_pool_value', 'service_account': 'service_account_value'}}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
# The version of a generated dependency at test runtime may differ from the version used during generation.
# Delete any fields which are not present in the current runtime dependency
# See https://github.com/googleapis/gapic-generator-python/issues/1748
Expand Down Expand Up @@ -4485,7 +4485,7 @@ def test_update_reasoning_engine_rest_call_success(request_type):

# send a request that will satisfy transcoding
request_init = {'reasoning_engine': {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3'}}
request_init["reasoning_engine"] = {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
request_init["reasoning_engine"] = {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2, 'build_spec': {'worker_pool': 'worker_pool_value', 'service_account': 'service_account_value'}}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
# The version of a generated dependency at test runtime may differ from the version used during generation.
# Delete any fields which are not present in the current runtime dependency
# See https://github.com/googleapis/gapic-generator-python/issues/1748
Expand Down Expand Up @@ -5423,7 +5423,7 @@ async def test_create_reasoning_engine_rest_asyncio_call_success(request_type):

# send a request that will satisfy transcoding
request_init = {'parent': 'projects/sample1/locations/sample2'}
request_init["reasoning_engine"] = {'name': 'name_value', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
request_init["reasoning_engine"] = {'name': 'name_value', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2, 'build_spec': {'worker_pool': 'worker_pool_value', 'service_account': 'service_account_value'}}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
# The version of a generated dependency at test runtime may differ from the version used during generation.
# Delete any fields which are not present in the current runtime dependency
# See https://github.com/googleapis/gapic-generator-python/issues/1748
Expand Down Expand Up @@ -5827,7 +5827,7 @@ async def test_update_reasoning_engine_rest_asyncio_call_success(request_type):

# send a request that will satisfy transcoding
request_init = {'reasoning_engine': {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3'}}
request_init["reasoning_engine"] = {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
request_init["reasoning_engine"] = {'name': 'projects/sample1/locations/sample2/reasoningEngines/sample3', 'display_name': 'display_name_value', 'description': 'description_value', 'spec': {'source_code_spec': {'inline_source': {'source_archive': b'source_archive_blob'}, 'developer_connect_source': {'config': {'git_repository_link': 'git_repository_link_value', 'dir_': 'dir__value', 'revision': 'revision_value'}}, 'python_spec': {'version': 'version_value', 'entrypoint_module': 'entrypoint_module_value', 'entrypoint_object': 'entrypoint_object_value', 'requirements_file': 'requirements_file_value'}, 'image_spec': {'build_args': {}}}, 'container_spec': {'image_uri': 'image_uri_value'}, 'service_account': 'service_account_value', 'package_spec': {'pickle_object_gcs_uri': 'pickle_object_gcs_uri_value', 'dependency_files_gcs_uri': 'dependency_files_gcs_uri_value', 'requirements_gcs_uri': 'requirements_gcs_uri_value', 'python_version': 'python_version_value'}, 'deployment_spec': {'env': [{'name': 'name_value', 'value': 'value_value'}], 'secret_env': [{'name': 'name_value', 'secret_ref': {'secret': 'secret_value', 'version': 'version_value'}}], 'psc_interface_config': {'network_attachment': 'network_attachment_value', 'dns_peering_configs': [{'domain': 'domain_value', 'target_project': 'target_project_value', 'target_network': 'target_network_value'}]}, 'min_instances': 1387, 'max_instances': 1389, 'resource_limits': {}, 'container_concurrency': 2253}, 'class_methods': [{'fields': {}}], 'agent_framework': 'agent_framework_value', 'identity_type': 2, 'build_spec': {'worker_pool': 'worker_pool_value', 'service_account': 'service_account_value'}}, 'create_time': {'seconds': 751, 'nanos': 543}, 'update_time': {}, 'etag': 'etag_value', 'encryption_spec': {'kms_key_name': 'kms_key_name_value'}, 'labels': {}}
# The version of a generated dependency at test runtime may differ from the version used during generation.
# Delete any fields which are not present in the current runtime dependency
# See https://github.com/googleapis/gapic-generator-python/issues/1748
Expand Down
Loading
Loading