Class: Google::Apis::DialogflowV2::GoogleCloudDialogflowV2beta1SessionEntityType

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/dialogflow_v2/classes.rb,
lib/google/apis/dialogflow_v2/representations.rb,
lib/google/apis/dialogflow_v2/representations.rb

Overview

A session represents a conversation between a Dialogflow agent and an end-user. You can create special entities, called session entities, during a session. Session entities can extend or replace custom entity types and only exist during the session that they were created for. All session data, including session entities, is stored by Dialogflow for 20 minutes. For more information, see the session entity guide.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDialogflowV2beta1SessionEntityType

Returns a new instance of GoogleCloudDialogflowV2beta1SessionEntityType.



20134
20135
20136
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 20134

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#entitiesArray<Google::Apis::DialogflowV2::GoogleCloudDialogflowV2beta1EntityTypeEntity>

Required. The collection of entities associated with this session entity type. Corresponds to the JSON property entities



20113
20114
20115
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 20113

def entities
  @entities
end

#entity_override_modeString

Required. Indicates whether the additional data should override or supplement the custom entity type definition. Corresponds to the JSON property entityOverrideMode

Returns:

  • (String)


20119
20120
20121
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 20119

def entity_override_mode
  @entity_override_mode
end

#nameString

Required. The unique identifier of this session entity type. Supported formats:

  • projects//agent/sessions//entityTypes/ - projects//locations//agent/ sessions//entityTypes/ - projects//agent/environments//users//sessions// entityTypes/ - projects//locations//agent/environments/ /users//sessions// entityTypes/ If Location ID is not specified we assume default 'us' location. If Environment ID is not specified, we assume default 'draft' environment. If User ID is not specified, we assume default '-' user. ` must be the display name of an existing entity type in the same agent that will be overridden or supplemented. Corresponds to the JSON propertyname`

Returns:

  • (String)


20132
20133
20134
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 20132

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



20139
20140
20141
20142
20143
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 20139

def update!(**args)
  @entities = args[:entities] if args.key?(:entities)
  @entity_override_mode = args[:entity_override_mode] if args.key?(:entity_override_mode)
  @name = args[:name] if args.key?(:name)
end