Skip to content
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Add the following lines to your `pom.xml` file:
<dependency>
<groupId>com.google.apis</groupId>
<artifactId>google-api-services-discoveryengine</artifactId>
<version>v1-rev20260802-2.0.0</version>
<version>v1-rev20260809-2.0.0</version>
</dependency>
</dependencies>
</project>
Expand All @@ -35,7 +35,7 @@ repositories {
mavenCentral()
}
dependencies {
implementation 'com.google.apis:google-api-services-discoveryengine:v1-rev20260802-2.0.0'
implementation 'com.google.apis:google-api-services-discoveryengine:v1-rev20260809-2.0.0'
}
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,16 @@ public final class GoogleCloudDiscoveryengineV1SearchRequest extends com.google.
@com.google.api.client.util.Key
private java.lang.String rankingExpressionBackend;

/**
* Optional. The granular relevance filtering specification. If not specified, the global
* `relevance_threshold` will be used for all sub-searches. If specified, this overrides the
* global `relevance_threshold` to use thresholds on a per sub-search basis. This feature is
* currently supported only for custom and site search.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec relevanceFilterSpec;

/**
* Optional. The specification for returning the relevance score.
* The value may be {@code null}.
Expand Down Expand Up @@ -1097,6 +1107,29 @@ public GoogleCloudDiscoveryengineV1SearchRequest setRankingExpressionBackend(jav
return this;
}

/**
* Optional. The granular relevance filtering specification. If not specified, the global
* `relevance_threshold` will be used for all sub-searches. If specified, this overrides the
* global `relevance_threshold` to use thresholds on a per sub-search basis. This feature is
* currently supported only for custom and site search.
* @return value or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec getRelevanceFilterSpec() {
return relevanceFilterSpec;
}

/**
* Optional. The granular relevance filtering specification. If not specified, the global
* `relevance_threshold` will be used for all sub-searches. If specified, this overrides the
* global `relevance_threshold` to use thresholds on a per sub-search basis. This feature is
* currently supported only for custom and site search.
* @param relevanceFilterSpec relevanceFilterSpec or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequest setRelevanceFilterSpec(GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec relevanceFilterSpec) {
this.relevanceFilterSpec = relevanceFilterSpec;
return this;
}

/**
* Optional. The specification for returning the relevance score.
* @return value or {@code null} for none
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
/*
* 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.
*/
/*
* This code was generated by https://github.com/googleapis/google-api-java-client-services/
* Modify at your own risk.
*/

package com.google.api.services.discoveryengine.v1.model;

/**
* Relevance filtering specification.
*
* <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
* transmitted over HTTP when working with the Discovery Engine API. For a detailed explanation see:
* <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>
* </p>
*
* @author Google, Inc.
*/
@SuppressWarnings("javadoc")
public final class GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec extends com.google.api.client.json.GenericJson {

/**
* Optional. Relevance filtering threshold specification for keyword search.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec keywordSearchThreshold;

/**
* Optional. Relevance filtering threshold specification for semantic search.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec semanticSearchThreshold;

/**
* Optional. Relevance filtering threshold specification for keyword search.
* @return value or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec getKeywordSearchThreshold() {
return keywordSearchThreshold;
}

/**
* Optional. Relevance filtering threshold specification for keyword search.
* @param keywordSearchThreshold keywordSearchThreshold or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec setKeywordSearchThreshold(GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec keywordSearchThreshold) {
this.keywordSearchThreshold = keywordSearchThreshold;
return this;
}

/**
* Optional. Relevance filtering threshold specification for semantic search.
* @return value or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec getSemanticSearchThreshold() {
return semanticSearchThreshold;
}

/**
* Optional. Relevance filtering threshold specification for semantic search.
* @param semanticSearchThreshold semanticSearchThreshold or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec setSemanticSearchThreshold(GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec semanticSearchThreshold) {
this.semanticSearchThreshold = semanticSearchThreshold;
return this;
}

@Override
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec set(String fieldName, Object value) {
return (GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec) super.set(fieldName, value);
}

@Override
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec clone() {
return (GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpec) super.clone();
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
/*
* 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.
*/
/*
* This code was generated by https://github.com/googleapis/google-api-java-client-services/
* Modify at your own risk.
*/

package com.google.api.services.discoveryengine.v1.model;

/**
* Specification for relevance filtering on a specific sub-search.
*
* <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
* transmitted over HTTP when working with the Discovery Engine API. For a detailed explanation see:
* <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>
* </p>
*
* @author Google, Inc.
*/
@SuppressWarnings("javadoc")
public final class GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec extends com.google.api.client.json.GenericJson {

/**
* Pre-defined relevance threshold for the sub-search.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private java.lang.String relevanceThreshold;

/**
* Custom relevance threshold for the sub-search. The value must be in [0.0, 1.0].
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private java.lang.Float semanticRelevanceThreshold;

/**
* Pre-defined relevance threshold for the sub-search.
* @return value or {@code null} for none
*/
public java.lang.String getRelevanceThreshold() {
return relevanceThreshold;
}

/**
* Pre-defined relevance threshold for the sub-search.
* @param relevanceThreshold relevanceThreshold or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec setRelevanceThreshold(java.lang.String relevanceThreshold) {
this.relevanceThreshold = relevanceThreshold;
return this;
}

/**
* Custom relevance threshold for the sub-search. The value must be in [0.0, 1.0].
* @return value or {@code null} for none
*/
public java.lang.Float getSemanticRelevanceThreshold() {
return semanticRelevanceThreshold;
}

/**
* Custom relevance threshold for the sub-search. The value must be in [0.0, 1.0].
* @param semanticRelevanceThreshold semanticRelevanceThreshold or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec setSemanticRelevanceThreshold(java.lang.Float semanticRelevanceThreshold) {
this.semanticRelevanceThreshold = semanticRelevanceThreshold;
return this;
}

@Override
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec set(String fieldName, Object value) {
return (GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec) super.set(fieldName, value);
}

@Override
public GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec clone() {
return (GoogleCloudDiscoveryengineV1SearchRequestRelevanceFilterSpecRelevanceThresholdSpec) super.clone();
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,14 @@ public final class GoogleCloudDiscoveryengineV1SearchResponseSearchResult extend
@com.google.api.client.util.Key
private GoogleCloudDiscoveryengineV1SearchResponseSearchResultRankSignals rankSignals;

/**
* Optional. A set of signals used by the relevance filter meant for use to fine-tune the
* relevance filter thresholds.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals retrievalSignals;

/**
* The chunk data in the search response if the SearchRequest.ContentSearchSpec.search_result_mode
* is set to CHUNKS.
Expand Down Expand Up @@ -161,6 +169,25 @@ public GoogleCloudDiscoveryengineV1SearchResponseSearchResult setRankSignals(Goo
return this;
}

/**
* Optional. A set of signals used by the relevance filter meant for use to fine-tune the
* relevance filter thresholds.
* @return value or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals getRetrievalSignals() {
return retrievalSignals;
}

/**
* Optional. A set of signals used by the relevance filter meant for use to fine-tune the
* relevance filter thresholds.
* @param retrievalSignals retrievalSignals or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchResponseSearchResult setRetrievalSignals(GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals retrievalSignals) {
this.retrievalSignals = retrievalSignals;
return this;
}

@Override
public GoogleCloudDiscoveryengineV1SearchResponseSearchResult set(String fieldName, Object value) {
return (GoogleCloudDiscoveryengineV1SearchResponseSearchResult) super.set(fieldName, value);
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
/*
* 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.
*/
/*
* This code was generated by https://github.com/googleapis/google-api-java-client-services/
* Modify at your own risk.
*/

package com.google.api.services.discoveryengine.v1.model;

/**
* Contains a set of signals used by the relevance filter.
*
* <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
* transmitted over HTTP when working with the Discovery Engine API. For a detailed explanation see:
* <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>
* </p>
*
* @author Google, Inc.
*/
@SuppressWarnings("javadoc")
public final class GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals extends com.google.api.client.json.GenericJson {

/**
* Optional. Indicates how the result was retrieved.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private java.util.List<java.lang.String> retrievalSources;

/**
* Optional. Relevance score used by the filter when semantic_relevance_threshold is set.
* The value may be {@code null}.
*/
@com.google.api.client.util.Key
private java.lang.Float semanticRelevanceScore;

/**
* Optional. Indicates how the result was retrieved.
* @return value or {@code null} for none
*/
public java.util.List<java.lang.String> getRetrievalSources() {
return retrievalSources;
}

/**
* Optional. Indicates how the result was retrieved.
* @param retrievalSources retrievalSources or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals setRetrievalSources(java.util.List<java.lang.String> retrievalSources) {
this.retrievalSources = retrievalSources;
return this;
}

/**
* Optional. Relevance score used by the filter when semantic_relevance_threshold is set.
* @return value or {@code null} for none
*/
public java.lang.Float getSemanticRelevanceScore() {
return semanticRelevanceScore;
}

/**
* Optional. Relevance score used by the filter when semantic_relevance_threshold is set.
* @param semanticRelevanceScore semanticRelevanceScore or {@code null} for none
*/
public GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals setSemanticRelevanceScore(java.lang.Float semanticRelevanceScore) {
this.semanticRelevanceScore = semanticRelevanceScore;
return this;
}

@Override
public GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals set(String fieldName, Object value) {
return (GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals) super.set(fieldName, value);
}

@Override
public GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals clone() {
return (GoogleCloudDiscoveryengineV1SearchResponseSearchResultRetrievalSignals) super.clone();
}

}
Loading
Loading