Vertex AI V1 API - Class Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client (v0.62.0)

Reference documentation and code samples for the Vertex AI V1 API class Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.

Client for the ReasoningEngineService service.

A service for managing Vertex AI's Reasoning Engines.

Inherits

  • Object

Methods

.configure

def self.configure() { |config| ... } -> Client::Configuration

Configure the ReasoningEngineService Client class.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter
Example
# Modify the configuration for all ReasoningEngineService clients
::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.configure do |config|
  config.timeout = 10.0
end

#configure

def configure() { |config| ... } -> Client::Configuration

Configure the ReasoningEngineService Client instance.

The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.

See Configuration for a description of the configuration fields.

Yields
  • (config) — Configure the Client client.
Yield Parameter

#create_reasoning_engine

def create_reasoning_engine(request, options = nil) -> ::Gapic::Operation
def create_reasoning_engine(parent: nil, reasoning_engine: nil) -> ::Gapic::Operation

Creates a reasoning engine.

Overloads
def create_reasoning_engine(request, options = nil) -> ::Gapic::Operation
Pass arguments to create_reasoning_engine via a request object, either of type CreateReasoningEngineRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_reasoning_engine(parent: nil, reasoning_engine: nil) -> ::Gapic::Operation
Pass arguments to create_reasoning_engine via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The resource name of the Location to create the ReasoningEngine in. Format: projects/{project}/locations/{location}
  • reasoning_engine (::Google::Cloud::AIPlatform::V1::ReasoningEngine, ::Hash) — Required. The ReasoningEngine to create.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/ai_platform/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest.new

# Call the create_reasoning_engine method.
result = client.create_reasoning_engine request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#delete_reasoning_engine

def delete_reasoning_engine(request, options = nil) -> ::Gapic::Operation
def delete_reasoning_engine(name: nil) -> ::Gapic::Operation

Deletes a reasoning engine.

Overloads
def delete_reasoning_engine(request, options = nil) -> ::Gapic::Operation
Pass arguments to delete_reasoning_engine via a request object, either of type DeleteReasoningEngineRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_reasoning_engine(name: nil) -> ::Gapic::Operation
Pass arguments to delete_reasoning_engine via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the ReasoningEngine resource to be deleted. Format: projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/ai_platform/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest.new

# Call the delete_reasoning_engine method.
result = client.delete_reasoning_engine request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end

#get_reasoning_engine

def get_reasoning_engine(request, options = nil) -> ::Google::Cloud::AIPlatform::V1::ReasoningEngine
def get_reasoning_engine(name: nil) -> ::Google::Cloud::AIPlatform::V1::ReasoningEngine

Gets a reasoning engine.

Overloads
def get_reasoning_engine(request, options = nil) -> ::Google::Cloud::AIPlatform::V1::ReasoningEngine
Pass arguments to get_reasoning_engine via a request object, either of type GetReasoningEngineRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_reasoning_engine(name: nil) -> ::Google::Cloud::AIPlatform::V1::ReasoningEngine
Pass arguments to get_reasoning_engine via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameter
  • name (::String) — Required. The name of the ReasoningEngine resource. Format: projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/ai_platform/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest.new

# Call the get_reasoning_engine method.
result = client.get_reasoning_engine request

# The returned object is of type Google::Cloud::AIPlatform::V1::ReasoningEngine.
p result

#iam_policy_client

def iam_policy_client() -> Google::Iam::V1::IAMPolicy::Client

Get the associated client for mix-in of the IAMPolicy.

Returns
  • (Google::Iam::V1::IAMPolicy::Client)

#initialize

def initialize() { |config| ... } -> Client

Create a new ReasoningEngineService client object.

Yields
  • (config) — Configure the ReasoningEngineService client.
Yield Parameter
Returns
  • (Client) — a new instance of Client
Example
# Create a client using the default configuration
client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a client using a custom configuration
client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new do |config|
  config.timeout = 10.0
end

#list_reasoning_engines

def list_reasoning_engines(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>
def list_reasoning_engines(parent: nil, filter: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>

Lists reasoning engines in a location.

Overloads
def list_reasoning_engines(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>
Pass arguments to list_reasoning_engines via a request object, either of type ListReasoningEnginesRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_reasoning_engines(parent: nil, filter: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>
Pass arguments to list_reasoning_engines via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
  • parent (::String) — Required. The resource name of the Location to list the ReasoningEngines from. Format: projects/{project}/locations/{location}
  • filter (::String) — Optional. The standard list filter. More detail in AIP-160.
  • page_size (::Integer) — Optional. The standard list page size.
  • page_token (::String) — Optional. The standard list page token.
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
Returns
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/ai_platform/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest.new

# Call the list_reasoning_engines method.
result = client.list_reasoning_engines request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::AIPlatform::V1::ReasoningEngine.
  p item
end

#location_client

def location_client() -> Google::Cloud::Location::Locations::Client

Get the associated client for mix-in of the Locations.

Returns
  • (Google::Cloud::Location::Locations::Client)

#logger

def logger() -> Logger

The logger used for request/response debug logging.

Returns
  • (Logger)

#operations_client

def operations_client() -> ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Operations

Get the associated client for long-running operations.

#universe_domain

def universe_domain() -> String

The effective universe domain

Returns
  • (String)

#update_reasoning_engine

def update_reasoning_engine(request, options = nil) -> ::Gapic::Operation
def update_reasoning_engine(reasoning_engine: nil, update_mask: nil) -> ::Gapic::Operation

Updates a reasoning engine.

Overloads
def update_reasoning_engine(request, options = nil) -> ::Gapic::Operation
Pass arguments to update_reasoning_engine via a request object, either of type UpdateReasoningEngineRequest or an equivalent Hash.
Parameters
  • request (::Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
  • options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_reasoning_engine(reasoning_engine: nil, update_mask: nil) -> ::Gapic::Operation
Pass arguments to update_reasoning_engine via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above).
Parameters
Yields
  • (response, operation) — Access the result along with the RPC operation
Yield Parameters
  • response (::Gapic::Operation)
  • operation (::GRPC::ActiveCall::Operation)
Returns
  • (::Gapic::Operation)
Raises
  • (::Google::Cloud::Error) — if the RPC is aborted.
Example

Basic example

require "google/cloud/ai_platform/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest.new

# Call the update_reasoning_engine method.
result = client.update_reasoning_engine request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end