Skip to content

Commit

Permalink
🦉 Updates from OwlBot post-processor
Browse files Browse the repository at this point in the history
  • Loading branch information
gcf-owl-bot[bot] committed Nov 18, 2023
1 parent e9abdb4 commit afdb5e0
Show file tree
Hide file tree
Showing 1,396 changed files with 1,194 additions and 325,396 deletions.
Binary file modified AiPlatform/metadata/V1/Model.php
Binary file not shown.
Binary file modified AiPlatform/metadata/V1/PredictionService.php
Binary file not shown.
103 changes: 103 additions & 0 deletions AiPlatform/src/V1/Client/PredictionServiceClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
namespace Google\Cloud\AIPlatform\V1\Client;

use Google\ApiCore\ApiException;
use Google\ApiCore\BidiStream;
use Google\ApiCore\CredentialsWrapper;
use Google\ApiCore\GapicClientTrait;
use Google\ApiCore\PagedListResponse;
Expand All @@ -35,6 +36,10 @@
use Google\ApiCore\ValidationException;
use Google\Api\HttpBody;
use Google\Auth\FetchAuthTokenInterface;
use Google\Cloud\AIPlatform\V1\DirectPredictRequest;
use Google\Cloud\AIPlatform\V1\DirectPredictResponse;
use Google\Cloud\AIPlatform\V1\DirectRawPredictRequest;
use Google\Cloud\AIPlatform\V1\DirectRawPredictResponse;
use Google\Cloud\AIPlatform\V1\ExplainRequest;
use Google\Cloud\AIPlatform\V1\ExplainResponse;
use Google\Cloud\AIPlatform\V1\PredictRequest;
Expand Down Expand Up @@ -68,6 +73,8 @@
*
* @experimental
*
* @method PromiseInterface directPredictAsync(DirectPredictRequest $request, array $optionalArgs = [])
* @method PromiseInterface directRawPredictAsync(DirectRawPredictRequest $request, array $optionalArgs = [])
* @method PromiseInterface explainAsync(ExplainRequest $request, array $optionalArgs = [])
* @method PromiseInterface predictAsync(PredictRequest $request, array $optionalArgs = [])
* @method PromiseInterface rawPredictAsync(RawPredictRequest $request, array $optionalArgs = [])
Expand Down Expand Up @@ -274,6 +281,59 @@ public function __call($method, $args)
return call_user_func_array([$this, 'startAsyncCall'], $args);
}

/**
* Perform an unary online prediction request for Vertex first-party products
* and frameworks.
*
* The async variant is {@see PredictionServiceClient::directPredictAsync()} .
*
* @example samples/V1/PredictionServiceClient/direct_predict.php
*
* @param DirectPredictRequest $request A request to house fields associated with the call.
* @param array $callOptions {
* Optional.
*
* @type RetrySettings|array $retrySettings
* Retry settings to use for this call. Can be a {@see RetrySettings} object, or an
* associative array of retry settings parameters. See the documentation on
* {@see RetrySettings} for example usage.
* }
*
* @return DirectPredictResponse
*
* @throws ApiException Thrown if the API call fails.
*/
public function directPredict(DirectPredictRequest $request, array $callOptions = []): DirectPredictResponse
{
return $this->startApiCall('DirectPredict', $request, $callOptions)->wait();
}

/**
* Perform an online prediction request through gRPC.
*
* The async variant is {@see PredictionServiceClient::directRawPredictAsync()} .
*
* @example samples/V1/PredictionServiceClient/direct_raw_predict.php
*
* @param DirectRawPredictRequest $request A request to house fields associated with the call.
* @param array $callOptions {
* Optional.
*
* @type RetrySettings|array $retrySettings
* Retry settings to use for this call. Can be a {@see RetrySettings} object, or an
* associative array of retry settings parameters. See the documentation on
* {@see RetrySettings} for example usage.
* }
*
* @return DirectRawPredictResponse
*
* @throws ApiException Thrown if the API call fails.
*/
public function directRawPredict(DirectRawPredictRequest $request, array $callOptions = []): DirectRawPredictResponse
{
return $this->startApiCall('DirectRawPredict', $request, $callOptions)->wait();
}

/**
* Perform an online explanation.
*
Expand Down Expand Up @@ -395,6 +455,49 @@ public function serverStreamingPredict(StreamingPredictRequest $request, array $
return $this->startApiCall('ServerStreamingPredict', $request, $callOptions);
}

/**
* Perform a streaming online prediction request for Vertex first-party
* products and frameworks.
*
* @example samples/V1/PredictionServiceClient/streaming_predict.php
*
* @param array $callOptions {
* Optional.
*
* @type int $timeoutMillis
* Timeout to use for this call.
* }
*
* @return BidiStream
*
* @throws ApiException Thrown if the API call fails.
*/
public function streamingPredict(array $callOptions = []): BidiStream
{
return $this->startApiCall('StreamingPredict', null, $callOptions);
}

/**
* Perform a streaming online prediction request through gRPC.
*
* @example samples/V1/PredictionServiceClient/streaming_raw_predict.php
*
* @param array $callOptions {
* Optional.
*
* @type int $timeoutMillis
* Timeout to use for this call.
* }
*
* @return BidiStream
*
* @throws ApiException Thrown if the API call fails.
*/
public function streamingRawPredict(array $callOptions = []): BidiStream
{
return $this->startApiCall('StreamingRawPredict', null, $callOptions);
}

/**
* Gets information about a location.
*
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit afdb5e0

Please sign in to comment.