public final class EntityType extends com.google.protobuf.GeneratedMessageV3 implements EntityTypeOrBuilder
Entities are extracted from user input and represent parameters that are
meaningful to your application. For example, a date range, a proper name
such as a geographic location or landmark, and so on. Entities represent
actionable data for your application.
When you define an entity, you can also include synonyms that all map to
that entity. For example, "soft drink", "soda", "pop", and so on.
There are three types of entities:
* **System** - entities that are defined by the Dialogflow API for common
data types such as date, time, currency, and so on. A system entity is
represented by the `EntityType` type.
* **Custom** - entities that are defined by you that represent
actionable data that is meaningful to your application. For example,
you could define a `pizza.sauce` entity for red or white pizza sauce,
a `pizza.cheese` entity for the different types of cheese on a pizza,
a `pizza.topping` entity for different toppings, and so on. A custom
entity is represented by the `EntityType` type.
* **User** - entities that are built for an individual user such as
favorites, preferences, playlists, and so on. A user entity is
represented by the
[SessionEntityType][google.cloud.dialogflow.cx.v3.SessionEntityType]
type.
For more information about entity types, see the [Dialogflow
documentation](https://cloud.google.com/dialogflow/docs/entities-overview).
Protobuf type google.cloud.dialogflow.cx.v3.EntityType| Modifier and Type | Class and Description |
|---|---|
static class |
EntityType.AutoExpansionMode
Represents different entity type expansion modes.
|
static class |
EntityType.Builder
Entities are extracted from user input and represent parameters that are
meaningful to your application.
|
static class |
EntityType.Entity
An **entity entry** for an associated entity type.
|
static interface |
EntityType.EntityOrBuilder |
static class |
EntityType.ExcludedPhrase
An excluded entity phrase that should not be matched.
|
static interface |
EntityType.ExcludedPhraseOrBuilder |
static class |
EntityType.Kind
Represents kinds of entities.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
AUTO_EXPANSION_MODE_FIELD_NUMBER |
static int |
DISPLAY_NAME_FIELD_NUMBER |
static int |
ENABLE_FUZZY_EXTRACTION_FIELD_NUMBER |
static int |
ENTITIES_FIELD_NUMBER |
static int |
EXCLUDED_PHRASES_FIELD_NUMBER |
static int |
KIND_FIELD_NUMBER |
static int |
NAME_FIELD_NUMBER |
static int |
REDACT_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
EntityType.AutoExpansionMode |
getAutoExpansionMode()
Indicates whether the entity type can be automatically expanded.
|
int |
getAutoExpansionModeValue()
Indicates whether the entity type can be automatically expanded.
|
static EntityType |
getDefaultInstance() |
EntityType |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
String |
getDisplayName()
Required.
|
com.google.protobuf.ByteString |
getDisplayNameBytes()
Required.
|
boolean |
getEnableFuzzyExtraction()
Enables fuzzy entity extraction during classification.
|
EntityType.Entity |
getEntities(int index)
The collection of entity entries associated with the entity type.
|
int |
getEntitiesCount()
The collection of entity entries associated with the entity type.
|
List<EntityType.Entity> |
getEntitiesList()
The collection of entity entries associated with the entity type.
|
EntityType.EntityOrBuilder |
getEntitiesOrBuilder(int index)
The collection of entity entries associated with the entity type.
|
List<? extends EntityType.EntityOrBuilder> |
getEntitiesOrBuilderList()
The collection of entity entries associated with the entity type.
|
EntityType.ExcludedPhrase |
getExcludedPhrases(int index)
Collection of exceptional words and phrases that shouldn't be matched.
|
int |
getExcludedPhrasesCount()
Collection of exceptional words and phrases that shouldn't be matched.
|
List<EntityType.ExcludedPhrase> |
getExcludedPhrasesList()
Collection of exceptional words and phrases that shouldn't be matched.
|
EntityType.ExcludedPhraseOrBuilder |
getExcludedPhrasesOrBuilder(int index)
Collection of exceptional words and phrases that shouldn't be matched.
|
List<? extends EntityType.ExcludedPhraseOrBuilder> |
getExcludedPhrasesOrBuilderList()
Collection of exceptional words and phrases that shouldn't be matched.
|
EntityType.Kind |
getKind()
Required.
|
int |
getKindValue()
Required.
|
String |
getName()
The unique identifier of the entity type.
|
com.google.protobuf.ByteString |
getNameBytes()
The unique identifier of the entity type.
|
com.google.protobuf.Parser<EntityType> |
getParserForType() |
boolean |
getRedact()
Indicates whether parameters of the entity type should be redacted in log.
|
int |
getSerializedSize() |
int |
hashCode() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static EntityType.Builder |
newBuilder() |
static EntityType.Builder |
newBuilder(EntityType prototype) |
EntityType.Builder |
newBuilderForType() |
protected EntityType.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static EntityType |
parseDelimitedFrom(InputStream input) |
static EntityType |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static EntityType |
parseFrom(byte[] data) |
static EntityType |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static EntityType |
parseFrom(ByteBuffer data) |
static EntityType |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static EntityType |
parseFrom(com.google.protobuf.ByteString data) |
static EntityType |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static EntityType |
parseFrom(com.google.protobuf.CodedInputStream input) |
static EntityType |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static EntityType |
parseFrom(InputStream input) |
static EntityType |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<EntityType> |
parser() |
EntityType.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
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, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
public static final int KIND_FIELD_NUMBER
public static final int AUTO_EXPANSION_MODE_FIELD_NUMBER
public static final int ENTITIES_FIELD_NUMBER
public static final int EXCLUDED_PHRASES_FIELD_NUMBER
public static final int ENABLE_FUZZY_EXTRACTION_FIELD_NUMBER
public static final int REDACT_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public String getName()
The unique identifier of the entity type. Required for [EntityTypes.UpdateEntityType][google.cloud.dialogflow.cx.v3.EntityTypes.UpdateEntityType]. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/entityTypes/<EntityTypeID>`.
string name = 1;getName in interface EntityTypeOrBuilderpublic com.google.protobuf.ByteString getNameBytes()
The unique identifier of the entity type. Required for [EntityTypes.UpdateEntityType][google.cloud.dialogflow.cx.v3.EntityTypes.UpdateEntityType]. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/entityTypes/<EntityTypeID>`.
string name = 1;getNameBytes in interface EntityTypeOrBuilderpublic String getDisplayName()
Required. The human-readable name of the entity type, unique within the agent.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];getDisplayName in interface EntityTypeOrBuilderpublic com.google.protobuf.ByteString getDisplayNameBytes()
Required. The human-readable name of the entity type, unique within the agent.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];getDisplayNameBytes in interface EntityTypeOrBuilderpublic int getKindValue()
Required. Indicates the kind of entity type.
.google.cloud.dialogflow.cx.v3.EntityType.Kind kind = 3 [(.google.api.field_behavior) = REQUIRED];
getKindValue in interface EntityTypeOrBuilderpublic EntityType.Kind getKind()
Required. Indicates the kind of entity type.
.google.cloud.dialogflow.cx.v3.EntityType.Kind kind = 3 [(.google.api.field_behavior) = REQUIRED];
getKind in interface EntityTypeOrBuilderpublic int getAutoExpansionModeValue()
Indicates whether the entity type can be automatically expanded.
.google.cloud.dialogflow.cx.v3.EntityType.AutoExpansionMode auto_expansion_mode = 4;
getAutoExpansionModeValue in interface EntityTypeOrBuilderpublic EntityType.AutoExpansionMode getAutoExpansionMode()
Indicates whether the entity type can be automatically expanded.
.google.cloud.dialogflow.cx.v3.EntityType.AutoExpansionMode auto_expansion_mode = 4;
getAutoExpansionMode in interface EntityTypeOrBuilderpublic List<EntityType.Entity> getEntitiesList()
The collection of entity entries associated with the entity type.
repeated .google.cloud.dialogflow.cx.v3.EntityType.Entity entities = 5;getEntitiesList in interface EntityTypeOrBuilderpublic List<? extends EntityType.EntityOrBuilder> getEntitiesOrBuilderList()
The collection of entity entries associated with the entity type.
repeated .google.cloud.dialogflow.cx.v3.EntityType.Entity entities = 5;getEntitiesOrBuilderList in interface EntityTypeOrBuilderpublic int getEntitiesCount()
The collection of entity entries associated with the entity type.
repeated .google.cloud.dialogflow.cx.v3.EntityType.Entity entities = 5;getEntitiesCount in interface EntityTypeOrBuilderpublic EntityType.Entity getEntities(int index)
The collection of entity entries associated with the entity type.
repeated .google.cloud.dialogflow.cx.v3.EntityType.Entity entities = 5;getEntities in interface EntityTypeOrBuilderpublic EntityType.EntityOrBuilder getEntitiesOrBuilder(int index)
The collection of entity entries associated with the entity type.
repeated .google.cloud.dialogflow.cx.v3.EntityType.Entity entities = 5;getEntitiesOrBuilder in interface EntityTypeOrBuilderpublic List<EntityType.ExcludedPhrase> getExcludedPhrasesList()
Collection of exceptional words and phrases that shouldn't be matched. For example, if you have a size entity type with entry `giant`(an adjective), you might consider adding `giants`(a noun) as an exclusion. If the kind of entity type is `KIND_MAP`, then the phrases specified by entities and excluded phrases should be mutually exclusive.
repeated .google.cloud.dialogflow.cx.v3.EntityType.ExcludedPhrase excluded_phrases = 6;
getExcludedPhrasesList in interface EntityTypeOrBuilderpublic List<? extends EntityType.ExcludedPhraseOrBuilder> getExcludedPhrasesOrBuilderList()
Collection of exceptional words and phrases that shouldn't be matched. For example, if you have a size entity type with entry `giant`(an adjective), you might consider adding `giants`(a noun) as an exclusion. If the kind of entity type is `KIND_MAP`, then the phrases specified by entities and excluded phrases should be mutually exclusive.
repeated .google.cloud.dialogflow.cx.v3.EntityType.ExcludedPhrase excluded_phrases = 6;
getExcludedPhrasesOrBuilderList in interface EntityTypeOrBuilderpublic int getExcludedPhrasesCount()
Collection of exceptional words and phrases that shouldn't be matched. For example, if you have a size entity type with entry `giant`(an adjective), you might consider adding `giants`(a noun) as an exclusion. If the kind of entity type is `KIND_MAP`, then the phrases specified by entities and excluded phrases should be mutually exclusive.
repeated .google.cloud.dialogflow.cx.v3.EntityType.ExcludedPhrase excluded_phrases = 6;
getExcludedPhrasesCount in interface EntityTypeOrBuilderpublic EntityType.ExcludedPhrase getExcludedPhrases(int index)
Collection of exceptional words and phrases that shouldn't be matched. For example, if you have a size entity type with entry `giant`(an adjective), you might consider adding `giants`(a noun) as an exclusion. If the kind of entity type is `KIND_MAP`, then the phrases specified by entities and excluded phrases should be mutually exclusive.
repeated .google.cloud.dialogflow.cx.v3.EntityType.ExcludedPhrase excluded_phrases = 6;
getExcludedPhrases in interface EntityTypeOrBuilderpublic EntityType.ExcludedPhraseOrBuilder getExcludedPhrasesOrBuilder(int index)
Collection of exceptional words and phrases that shouldn't be matched. For example, if you have a size entity type with entry `giant`(an adjective), you might consider adding `giants`(a noun) as an exclusion. If the kind of entity type is `KIND_MAP`, then the phrases specified by entities and excluded phrases should be mutually exclusive.
repeated .google.cloud.dialogflow.cx.v3.EntityType.ExcludedPhrase excluded_phrases = 6;
getExcludedPhrasesOrBuilder in interface EntityTypeOrBuilderpublic boolean getEnableFuzzyExtraction()
Enables fuzzy entity extraction during classification.
bool enable_fuzzy_extraction = 7;getEnableFuzzyExtraction in interface EntityTypeOrBuilderpublic boolean getRedact()
Indicates whether parameters of the entity type should be redacted in log. If redaction is enabled, page parameters and intent parameters referring to the entity type will be replaced by parameter name when logging.
bool redact = 9;getRedact in interface EntityTypeOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public 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 EntityType parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static EntityType parseFrom(InputStream input) throws IOException
IOExceptionpublic static EntityType parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static EntityType parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static EntityType parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static EntityType parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static EntityType parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic EntityType.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static EntityType.Builder newBuilder()
public static EntityType.Builder newBuilder(EntityType prototype)
public EntityType.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected EntityType.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static EntityType getDefaultInstance()
public static com.google.protobuf.Parser<EntityType> parser()
public com.google.protobuf.Parser<EntityType> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public EntityType getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2025 Google LLC. All rights reserved.