Class: Google::Apis::DialogflowV2::GoogleCloudDialogflowV2Agent

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 Dialogflow agent is a virtual agent that handles conversations with your end- users. It is a natural language understanding module that understands the nuances of human language. Dialogflow translates end-user text or audio during a conversation to structured data that your apps and services can understand. You design and build a Dialogflow agent to handle the types of conversations required for your system. For more information about agents, see the Agent guide.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDialogflowV2Agent

Returns a new instance of GoogleCloudDialogflowV2Agent.



5527
5528
5529
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5527

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

Instance Attribute Details

#api_versionString

Optional. API version displayed in Dialogflow console. If not specified, V2 API is assumed. Clients are free to query different service endpoints for different API versions. However, bots connectors and webhook calls will follow the specified API version. Corresponds to the JSON property apiVersion

Returns:

  • (String)


5455
5456
5457
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5455

def api_version
  @api_version
end

#avatar_uriString

Optional. The URI of the agent's avatar. Avatars are used throughout the Dialogflow console and in the self-hosted Web Demo integration. Corresponds to the JSON property avatarUri

Returns:

  • (String)


5462
5463
5464
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5462

def avatar_uri
  @avatar_uri
end

#classification_thresholdFloat

Optional. To filter out false positive results and still get variety in matched natural language inputs for your agent, you can tune the machine learning classification threshold. If the returned score value is less than the threshold value, then a fallback intent will be triggered or, if there are no fallback intents defined, no intent will be triggered. The score values range from 0.0 (completely uncertain) to 1.0 (completely certain). If set to 0. 0, the default of 0.3 is used. Corresponds to the JSON property classificationThreshold

Returns:

  • (Float)


5473
5474
5475
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5473

def classification_threshold
  @classification_threshold
end

#default_language_codeString

Required. The default language of the agent as a language tag. See Language Support for a list of the currently supported language codes. This field cannot be set by the Update method. Corresponds to the JSON property defaultLanguageCode

Returns:

  • (String)


5481
5482
5483
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5481

def default_language_code
  @default_language_code
end

#descriptionString

Optional. The description of this agent. The maximum length is 500 characters. If exceeded, the request is rejected. Corresponds to the JSON property description

Returns:

  • (String)


5487
5488
5489
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5487

def description
  @description
end

#display_nameString

Required. The name of this agent. Corresponds to the JSON property displayName

Returns:

  • (String)


5492
5493
5494
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5492

def display_name
  @display_name
end

#enable_loggingBoolean Also known as: enable_logging?

Optional. Determines whether this agent should log conversation queries. Corresponds to the JSON property enableLogging

Returns:

  • (Boolean)


5497
5498
5499
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5497

def enable_logging
  @enable_logging
end

#match_modeString

Optional. Determines how intents are detected from user queries. Corresponds to the JSON property matchMode

Returns:

  • (String)


5503
5504
5505
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5503

def match_mode
  @match_mode
end

#parentString

Required. The project of this agent. Format: projects/. Corresponds to the JSON property parent

Returns:

  • (String)


5508
5509
5510
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5508

def parent
  @parent
end

#supported_language_codesArray<String>

Optional. The list of all languages supported by this agent (except for the default_language_code). Corresponds to the JSON property supportedLanguageCodes

Returns:

  • (Array<String>)


5514
5515
5516
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5514

def supported_language_codes
  @supported_language_codes
end

#tierString

Optional. The agent tier. If not specified, TIER_STANDARD is assumed. Corresponds to the JSON property tier

Returns:

  • (String)


5519
5520
5521
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5519

def tier
  @tier
end

#time_zoneString

Required. The time zone of this agent from the time zone database, e.g., America/New_York, Europe/Paris. Corresponds to the JSON property timeZone

Returns:

  • (String)


5525
5526
5527
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5525

def time_zone
  @time_zone
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5532
5533
5534
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544
5545
# File 'lib/google/apis/dialogflow_v2/classes.rb', line 5532

def update!(**args)
  @api_version = args[:api_version] if args.key?(:api_version)
  @avatar_uri = args[:avatar_uri] if args.key?(:avatar_uri)
  @classification_threshold = args[:classification_threshold] if args.key?(:classification_threshold)
  @default_language_code = args[:default_language_code] if args.key?(:default_language_code)
  @description = args[:description] if args.key?(:description)
  @display_name = args[:display_name] if args.key?(:display_name)
  @enable_logging = args[:enable_logging] if args.key?(:enable_logging)
  @match_mode = args[:match_mode] if args.key?(:match_mode)
  @parent = args[:parent] if args.key?(:parent)
  @supported_language_codes = args[:supported_language_codes] if args.key?(:supported_language_codes)
  @tier = args[:tier] if args.key?(:tier)
  @time_zone = args[:time_zone] if args.key?(:time_zone)
end