Skip to content

Commit a7d6d4b

Browse files
1 parent 5f65228 commit a7d6d4b

24 files changed

+804
-63
lines changed

clients/google-api-services-aiplatform/v1/2.0.0/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Add the following lines to your `pom.xml` file:
2222
<dependency>
2323
<groupId>com.google.apis</groupId>
2424
<artifactId>google-api-services-aiplatform</artifactId>
25-
<version>v1-rev20240925-2.0.0</version>
25+
<version>v1-rev20241001-2.0.0</version>
2626
</dependency>
2727
</dependencies>
2828
</project>
@@ -35,7 +35,7 @@ repositories {
3535
mavenCentral()
3636
}
3737
dependencies {
38-
implementation 'com.google.apis:google-api-services-aiplatform:v1-rev20240925-2.0.0'
38+
implementation 'com.google.apis:google-api-services-aiplatform:v1-rev20241001-2.0.0'
3939
}
4040
```
4141

clients/google-api-services-aiplatform/v1/2.0.0/com/google/api/services/aiplatform/v1/Aiplatform.java

Lines changed: 162 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19523,6 +19523,168 @@ public UndeployModel set(String parameterName, Object value) {
1952319523
}
1952419524
}
1952519525

19526+
/**
19527+
* An accessor for creating requests from the Chat collection.
19528+
*
19529+
* <p>The typical use is:</p>
19530+
* <pre>
19531+
* {@code Aiplatform aiplatform = new Aiplatform(...);}
19532+
* {@code Aiplatform.Chat.List request = aiplatform.chat().list(parameters ...)}
19533+
* </pre>
19534+
*
19535+
* @return the resource collection
19536+
*/
19537+
public Chat chat() {
19538+
return new Chat();
19539+
}
19540+
19541+
/**
19542+
* The "chat" collection of methods.
19543+
*/
19544+
public class Chat {
19545+
19546+
/**
19547+
* Exposes an OpenAI-compatible endpoint for chat completions.
19548+
*
19549+
* Create a request for the method "chat.completions".
19550+
*
19551+
* This request holds the parameters needed by the aiplatform server. After setting any optional
19552+
* parameters, call the {@link Completions#execute()} method to invoke the remote operation.
19553+
*
19554+
* @param endpoint Required. The name of the endpoint requested to serve the prediction. Format:
19555+
* `projects/{project}/locations/{location}/endpoints/{endpoint}`
19556+
* @param content the {@link com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody}
19557+
* @return the request
19558+
*/
19559+
public Completions completions(java.lang.String endpoint, com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody content) throws java.io.IOException {
19560+
Completions result = new Completions(endpoint, content);
19561+
initialize(result);
19562+
return result;
19563+
}
19564+
19565+
public class Completions extends AiplatformRequest<com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody> {
19566+
19567+
private static final String REST_PATH = "v1/{+endpoint}/chat/completions";
19568+
19569+
private final java.util.regex.Pattern ENDPOINT_PATTERN =
19570+
java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/endpoints/[^/]+$");
19571+
19572+
/**
19573+
* Exposes an OpenAI-compatible endpoint for chat completions.
19574+
*
19575+
* Create a request for the method "chat.completions".
19576+
*
19577+
* This request holds the parameters needed by the the aiplatform server. After setting any
19578+
* optional parameters, call the {@link Completions#execute()} method to invoke the remote
19579+
* operation. <p> {@link
19580+
* Completions#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
19581+
* must be called to initialize this instance immediately after invoking the constructor. </p>
19582+
*
19583+
* @param endpoint Required. The name of the endpoint requested to serve the prediction. Format:
19584+
* `projects/{project}/locations/{location}/endpoints/{endpoint}`
19585+
* @param content the {@link com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody}
19586+
* @since 1.13
19587+
*/
19588+
protected Completions(java.lang.String endpoint, com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody content) {
19589+
super(Aiplatform.this, "POST", REST_PATH, content, com.google.api.services.aiplatform.v1.model.GoogleApiHttpBody.class);
19590+
this.endpoint = com.google.api.client.util.Preconditions.checkNotNull(endpoint, "Required parameter endpoint must be specified.");
19591+
if (!getSuppressPatternChecks()) {
19592+
com.google.api.client.util.Preconditions.checkArgument(ENDPOINT_PATTERN.matcher(endpoint).matches(),
19593+
"Parameter endpoint must conform to the pattern " +
19594+
"^projects/[^/]+/locations/[^/]+/endpoints/[^/]+$");
19595+
}
19596+
}
19597+
19598+
@Override
19599+
public Completions set$Xgafv(java.lang.String $Xgafv) {
19600+
return (Completions) super.set$Xgafv($Xgafv);
19601+
}
19602+
19603+
@Override
19604+
public Completions setAccessToken(java.lang.String accessToken) {
19605+
return (Completions) super.setAccessToken(accessToken);
19606+
}
19607+
19608+
@Override
19609+
public Completions setAlt(java.lang.String alt) {
19610+
return (Completions) super.setAlt(alt);
19611+
}
19612+
19613+
@Override
19614+
public Completions setCallback(java.lang.String callback) {
19615+
return (Completions) super.setCallback(callback);
19616+
}
19617+
19618+
@Override
19619+
public Completions setFields(java.lang.String fields) {
19620+
return (Completions) super.setFields(fields);
19621+
}
19622+
19623+
@Override
19624+
public Completions setKey(java.lang.String key) {
19625+
return (Completions) super.setKey(key);
19626+
}
19627+
19628+
@Override
19629+
public Completions setOauthToken(java.lang.String oauthToken) {
19630+
return (Completions) super.setOauthToken(oauthToken);
19631+
}
19632+
19633+
@Override
19634+
public Completions setPrettyPrint(java.lang.Boolean prettyPrint) {
19635+
return (Completions) super.setPrettyPrint(prettyPrint);
19636+
}
19637+
19638+
@Override
19639+
public Completions setQuotaUser(java.lang.String quotaUser) {
19640+
return (Completions) super.setQuotaUser(quotaUser);
19641+
}
19642+
19643+
@Override
19644+
public Completions setUploadType(java.lang.String uploadType) {
19645+
return (Completions) super.setUploadType(uploadType);
19646+
}
19647+
19648+
@Override
19649+
public Completions setUploadProtocol(java.lang.String uploadProtocol) {
19650+
return (Completions) super.setUploadProtocol(uploadProtocol);
19651+
}
19652+
19653+
/**
19654+
* Required. The name of the endpoint requested to serve the prediction. Format:
19655+
* `projects/{project}/locations/{location}/endpoints/{endpoint}`
19656+
*/
19657+
@com.google.api.client.util.Key
19658+
private java.lang.String endpoint;
19659+
19660+
/** Required. The name of the endpoint requested to serve the prediction. Format:
19661+
`projects/{project}/locations/{location}/endpoints/{endpoint}`
19662+
*/
19663+
public java.lang.String getEndpoint() {
19664+
return endpoint;
19665+
}
19666+
19667+
/**
19668+
* Required. The name of the endpoint requested to serve the prediction. Format:
19669+
* `projects/{project}/locations/{location}/endpoints/{endpoint}`
19670+
*/
19671+
public Completions setEndpoint(java.lang.String endpoint) {
19672+
if (!getSuppressPatternChecks()) {
19673+
com.google.api.client.util.Preconditions.checkArgument(ENDPOINT_PATTERN.matcher(endpoint).matches(),
19674+
"Parameter endpoint must conform to the pattern " +
19675+
"^projects/[^/]+/locations/[^/]+/endpoints/[^/]+$");
19676+
}
19677+
this.endpoint = endpoint;
19678+
return this;
19679+
}
19680+
19681+
@Override
19682+
public Completions set(String parameterName, Object value) {
19683+
return (Completions) super.set(parameterName, value);
19684+
}
19685+
}
19686+
19687+
}
1952619688
/**
1952719689
* An accessor for creating requests from the Operations collection.
1952819690
*
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
/*
2+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
3+
* in compliance with the License. You may obtain a copy of the License at
4+
*
5+
* http://www.apache.org/licenses/LICENSE-2.0
6+
*
7+
* Unless required by applicable law or agreed to in writing, software distributed under the License
8+
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
9+
* or implied. See the License for the specific language governing permissions and limitations under
10+
* the License.
11+
*/
12+
/*
13+
* This code was generated by https://github.com/googleapis/google-api-java-client-services/
14+
* Modify at your own risk.
15+
*/
16+
17+
package com.google.api.services.aiplatform.v1.model;
18+
19+
/**
20+
* Describes the options to customize dynamic retrieval.
21+
*
22+
* <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
23+
* transmitted over HTTP when working with the Vertex AI API. For a detailed explanation see:
24+
* <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
25+
* </p>
26+
*
27+
* @author Google, Inc.
28+
*/
29+
@SuppressWarnings("javadoc")
30+
public final class GoogleCloudAiplatformV1DynamicRetrievalConfig extends com.google.api.client.json.GenericJson {
31+
32+
/**
33+
* Optional. The threshold to be used in dynamic retrieval. If not set, a system default value is
34+
* used.
35+
* The value may be {@code null}.
36+
*/
37+
@com.google.api.client.util.Key
38+
private java.lang.Float dynamicThreshold;
39+
40+
/**
41+
* The mode of the predictor to be used in dynamic retrieval.
42+
* The value may be {@code null}.
43+
*/
44+
@com.google.api.client.util.Key
45+
private java.lang.String mode;
46+
47+
/**
48+
* Optional. The threshold to be used in dynamic retrieval. If not set, a system default value is
49+
* used.
50+
* @return value or {@code null} for none
51+
*/
52+
public java.lang.Float getDynamicThreshold() {
53+
return dynamicThreshold;
54+
}
55+
56+
/**
57+
* Optional. The threshold to be used in dynamic retrieval. If not set, a system default value is
58+
* used.
59+
* @param dynamicThreshold dynamicThreshold or {@code null} for none
60+
*/
61+
public GoogleCloudAiplatformV1DynamicRetrievalConfig setDynamicThreshold(java.lang.Float dynamicThreshold) {
62+
this.dynamicThreshold = dynamicThreshold;
63+
return this;
64+
}
65+
66+
/**
67+
* The mode of the predictor to be used in dynamic retrieval.
68+
* @return value or {@code null} for none
69+
*/
70+
public java.lang.String getMode() {
71+
return mode;
72+
}
73+
74+
/**
75+
* The mode of the predictor to be used in dynamic retrieval.
76+
* @param mode mode or {@code null} for none
77+
*/
78+
public GoogleCloudAiplatformV1DynamicRetrievalConfig setMode(java.lang.String mode) {
79+
this.mode = mode;
80+
return this;
81+
}
82+
83+
@Override
84+
public GoogleCloudAiplatformV1DynamicRetrievalConfig set(String fieldName, Object value) {
85+
return (GoogleCloudAiplatformV1DynamicRetrievalConfig) super.set(fieldName, value);
86+
}
87+
88+
@Override
89+
public GoogleCloudAiplatformV1DynamicRetrievalConfig clone() {
90+
return (GoogleCloudAiplatformV1DynamicRetrievalConfig) super.clone();
91+
}
92+
93+
}

clients/google-api-services-aiplatform/v1/2.0.0/com/google/api/services/aiplatform/v1/model/GoogleCloudAiplatformV1GoogleSearchRetrieval.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,30 @@
2929
@SuppressWarnings("javadoc")
3030
public final class GoogleCloudAiplatformV1GoogleSearchRetrieval extends com.google.api.client.json.GenericJson {
3131

32+
/**
33+
* Specifies the dynamic retrieval configuration for the given source.
34+
* The value may be {@code null}.
35+
*/
36+
@com.google.api.client.util.Key
37+
private GoogleCloudAiplatformV1DynamicRetrievalConfig dynamicRetrievalConfig;
38+
39+
/**
40+
* Specifies the dynamic retrieval configuration for the given source.
41+
* @return value or {@code null} for none
42+
*/
43+
public GoogleCloudAiplatformV1DynamicRetrievalConfig getDynamicRetrievalConfig() {
44+
return dynamicRetrievalConfig;
45+
}
46+
47+
/**
48+
* Specifies the dynamic retrieval configuration for the given source.
49+
* @param dynamicRetrievalConfig dynamicRetrievalConfig or {@code null} for none
50+
*/
51+
public GoogleCloudAiplatformV1GoogleSearchRetrieval setDynamicRetrievalConfig(GoogleCloudAiplatformV1DynamicRetrievalConfig dynamicRetrievalConfig) {
52+
this.dynamicRetrievalConfig = dynamicRetrievalConfig;
53+
return this;
54+
}
55+
3256
@Override
3357
public GoogleCloudAiplatformV1GoogleSearchRetrieval set(String fieldName, Object value) {
3458
return (GoogleCloudAiplatformV1GoogleSearchRetrieval) super.set(fieldName, value);

clients/google-api-services-aiplatform/v1/2.0.0/com/google/api/services/aiplatform/v1/model/GoogleCloudAiplatformV1GroundingMetadata.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,13 @@ public final class GoogleCloudAiplatformV1GroundingMetadata extends com.google.a
4949
@com.google.api.client.util.Key
5050
private java.util.List<GoogleCloudAiplatformV1GroundingSupport> groundingSupports;
5151

52+
/**
53+
* Optional. Output only. Retrieval metadata.
54+
* The value may be {@code null}.
55+
*/
56+
@com.google.api.client.util.Key
57+
private GoogleCloudAiplatformV1RetrievalMetadata retrievalMetadata;
58+
5259
/**
5360
* Optional. Google search entry for the following-up web searches.
5461
* The value may be {@code null}.
@@ -97,6 +104,23 @@ public GoogleCloudAiplatformV1GroundingMetadata setGroundingSupports(java.util.L
97104
return this;
98105
}
99106

107+
/**
108+
* Optional. Output only. Retrieval metadata.
109+
* @return value or {@code null} for none
110+
*/
111+
public GoogleCloudAiplatformV1RetrievalMetadata getRetrievalMetadata() {
112+
return retrievalMetadata;
113+
}
114+
115+
/**
116+
* Optional. Output only. Retrieval metadata.
117+
* @param retrievalMetadata retrievalMetadata or {@code null} for none
118+
*/
119+
public GoogleCloudAiplatformV1GroundingMetadata setRetrievalMetadata(GoogleCloudAiplatformV1RetrievalMetadata retrievalMetadata) {
120+
this.retrievalMetadata = retrievalMetadata;
121+
return this;
122+
}
123+
100124
/**
101125
* Optional. Google search entry for the following-up web searches.
102126
* @return value or {@code null} for none

0 commit comments

Comments
 (0)