public static final class SearchRequest.NaturalLanguageQueryUnderstandingSpec extends com.google.protobuf.GeneratedMessage implements SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilder
Specification to enable natural language understanding capabilities for search requests.Protobuf type
google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec| Modifier and Type | Class and Description |
|---|---|
static class |
SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder
Specification to enable natural language understanding capabilities for
search requests.
|
static class |
SearchRequest.NaturalLanguageQueryUnderstandingSpec.ExtractedFilterBehavior
Enum describing how extracted filters are applied to the search.
|
static class |
SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition
Enum describing under which condition filter extraction should occur.
|
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message,T>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
ALLOWED_FIELD_NAMES_FIELD_NUMBER |
static int |
EXTRACTED_FILTER_BEHAVIOR_FIELD_NUMBER |
static int |
FILTER_EXTRACTION_CONDITION_FIELD_NUMBER |
static int |
GEO_SEARCH_QUERY_DETECTION_FIELD_NAMES_FIELD_NUMBER |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashFields, toStringaddAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int FILTER_EXTRACTION_CONDITION_FIELD_NUMBER
public static final int GEO_SEARCH_QUERY_DETECTION_FIELD_NAMES_FIELD_NUMBER
public static final int EXTRACTED_FILTER_BEHAVIOR_FIELD_NUMBER
public static final int ALLOWED_FIELD_NAMES_FIELD_NUMBER
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessagepublic int getFilterExtractionConditionValue()
The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.
.google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition filter_extraction_condition = 1;
getFilterExtractionConditionValue in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition getFilterExtractionCondition()
The condition under which filter extraction should occur. Server behavior defaults to `DISABLED`.
.google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition filter_extraction_condition = 1;
getFilterExtractionCondition in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic com.google.protobuf.ProtocolStringList getGeoSearchQueryDetectionFieldNamesList()
Field names used for location-based filtering, where geolocation filters are detected in natural language search queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. If this field is set, it overrides the field names set in [ServingConfig.geo_search_query_detection_field_names][google.cloud.discoveryengine.v1.ServingConfig.geo_search_query_detection_field_names].
repeated string geo_search_query_detection_field_names = 2;getGeoSearchQueryDetectionFieldNamesList in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic int getGeoSearchQueryDetectionFieldNamesCount()
Field names used for location-based filtering, where geolocation filters are detected in natural language search queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. If this field is set, it overrides the field names set in [ServingConfig.geo_search_query_detection_field_names][google.cloud.discoveryengine.v1.ServingConfig.geo_search_query_detection_field_names].
repeated string geo_search_query_detection_field_names = 2;getGeoSearchQueryDetectionFieldNamesCount in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic String getGeoSearchQueryDetectionFieldNames(int index)
Field names used for location-based filtering, where geolocation filters are detected in natural language search queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. If this field is set, it overrides the field names set in [ServingConfig.geo_search_query_detection_field_names][google.cloud.discoveryengine.v1.ServingConfig.geo_search_query_detection_field_names].
repeated string geo_search_query_detection_field_names = 2;getGeoSearchQueryDetectionFieldNames in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderindex - The index of the element to return.public com.google.protobuf.ByteString getGeoSearchQueryDetectionFieldNamesBytes(int index)
Field names used for location-based filtering, where geolocation filters are detected in natural language search queries. Only valid when the FilterExtractionCondition is set to `ENABLED`. If this field is set, it overrides the field names set in [ServingConfig.geo_search_query_detection_field_names][google.cloud.discoveryengine.v1.ServingConfig.geo_search_query_detection_field_names].
repeated string geo_search_query_detection_field_names = 2;getGeoSearchQueryDetectionFieldNamesBytes in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderindex - The index of the value to return.public int getExtractedFilterBehaviorValue()
Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if [SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition][google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition] is set to [FilterExtractionCondition.ENABLED][google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition.ENABLED].
.google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.ExtractedFilterBehavior extracted_filter_behavior = 3 [(.google.api.field_behavior) = OPTIONAL];
getExtractedFilterBehaviorValue in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic SearchRequest.NaturalLanguageQueryUnderstandingSpec.ExtractedFilterBehavior getExtractedFilterBehavior()
Optional. Controls behavior of how extracted filters are applied to the search. The default behavior depends on the request. For single datastore structured search, the default is `HARD_FILTER`. For multi-datastore search, the default behavior is `SOFT_BOOST`. Location-based filters are always applied as hard filters, and the `SOFT_BOOST` setting will not affect them. This field is only used if [SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition][google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition] is set to [FilterExtractionCondition.ENABLED][google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition.ENABLED].
.google.cloud.discoveryengine.v1.SearchRequest.NaturalLanguageQueryUnderstandingSpec.ExtractedFilterBehavior extracted_filter_behavior = 3 [(.google.api.field_behavior) = OPTIONAL];
getExtractedFilterBehavior in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic com.google.protobuf.ProtocolStringList getAllowedFieldNamesList()
Optional. Allowlist of fields that can be used for natural language filter extraction. By default, if this is unspecified, all indexable fields are eligible for natural language filter extraction (but are not guaranteed to be used). If any fields are specified in allowed_field_names, only the fields that are both marked as indexable in the schema and specified in the allowlist will be eligible for natural language filter extraction. Note: for multi-datastore search, this is not yet supported, and will be ignored.
repeated string allowed_field_names = 4 [(.google.api.field_behavior) = OPTIONAL];
getAllowedFieldNamesList in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic int getAllowedFieldNamesCount()
Optional. Allowlist of fields that can be used for natural language filter extraction. By default, if this is unspecified, all indexable fields are eligible for natural language filter extraction (but are not guaranteed to be used). If any fields are specified in allowed_field_names, only the fields that are both marked as indexable in the schema and specified in the allowlist will be eligible for natural language filter extraction. Note: for multi-datastore search, this is not yet supported, and will be ignored.
repeated string allowed_field_names = 4 [(.google.api.field_behavior) = OPTIONAL];
getAllowedFieldNamesCount in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderpublic String getAllowedFieldNames(int index)
Optional. Allowlist of fields that can be used for natural language filter extraction. By default, if this is unspecified, all indexable fields are eligible for natural language filter extraction (but are not guaranteed to be used). If any fields are specified in allowed_field_names, only the fields that are both marked as indexable in the schema and specified in the allowlist will be eligible for natural language filter extraction. Note: for multi-datastore search, this is not yet supported, and will be ignored.
repeated string allowed_field_names = 4 [(.google.api.field_behavior) = OPTIONAL];
getAllowedFieldNames in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderindex - The index of the element to return.public com.google.protobuf.ByteString getAllowedFieldNamesBytes(int index)
Optional. Allowlist of fields that can be used for natural language filter extraction. By default, if this is unspecified, all indexable fields are eligible for natural language filter extraction (but are not guaranteed to be used). If any fields are specified in allowed_field_names, only the fields that are both marked as indexable in the schema and specified in the allowlist will be eligible for natural language filter extraction. Note: for multi-datastore search, this is not yet supported, and will be ignored.
repeated string allowed_field_names = 4 [(.google.api.field_behavior) = OPTIONAL];
getAllowedFieldNamesBytes in interface SearchRequest.NaturalLanguageQueryUnderstandingSpecOrBuilderindex - The index of the value to return.public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessagepublic void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageIOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessagepublic boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(InputStream input) throws IOException
IOExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder newBuilder()
public static SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder newBuilder(SearchRequest.NaturalLanguageQueryUnderstandingSpec prototype)
public SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected SearchRequest.NaturalLanguageQueryUnderstandingSpec.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
newBuilderForType in class com.google.protobuf.AbstractMessagepublic static SearchRequest.NaturalLanguageQueryUnderstandingSpec getDefaultInstance()
public static com.google.protobuf.Parser<SearchRequest.NaturalLanguageQueryUnderstandingSpec> parser()
public com.google.protobuf.Parser<SearchRequest.NaturalLanguageQueryUnderstandingSpec> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessagepublic SearchRequest.NaturalLanguageQueryUnderstandingSpec getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2026 Google LLC. All rights reserved.