Class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequest
- Inherits:
-
Object
- Object
- Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequest
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/discoveryengine_v1/classes.rb,
lib/google/apis/discoveryengine_v1/representations.rb,
lib/google/apis/discoveryengine_v1/representations.rb
Overview
Request message for ConversationalSearchService.AnswerQuery method.
Instance Attribute Summary collapse
-
#answer_generation_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestAnswerGenerationSpec
Answer generation specification.
-
#asynchronous_mode ⇒ Boolean
(also: #asynchronous_mode?)
Deprecated: This field is deprecated.
-
#grounding_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestGroundingSpec
Grounding specification.
-
#query ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1Query
Defines a user inputed query.
-
#query_understanding_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestQueryUnderstandingSpec
Query understanding specification.
-
#related_questions_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestRelatedQuestionsSpec
Related questions specification.
-
#safety_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestSafetySpec
Safety specification.
-
#search_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestSearchSpec
Search specification.
-
#session ⇒ String
The session resource name.
-
#user_labels ⇒ Hash<String,String>
The user labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64.
-
#user_pseudo_id ⇒ String
A unique identifier for tracking visitors.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1AnswerQueryRequest
constructor
A new instance of GoogleCloudDiscoveryengineV1AnswerQueryRequest.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1AnswerQueryRequest
Returns a new instance of GoogleCloudDiscoveryengineV1AnswerQueryRequest.
980 981 982 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 980 def initialize(**args) update!(**args) end |
Instance Attribute Details
#answer_generation_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestAnswerGenerationSpec
Answer generation specification.
Corresponds to the JSON property answerGenerationSpec
903 904 905 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 903 def answer_generation_spec @answer_generation_spec end |
#asynchronous_mode ⇒ Boolean Also known as: asynchronous_mode?
Deprecated: This field is deprecated. Streaming Answer API will be supported.
Asynchronous mode control. If enabled, the response will be returned with
answer/session resource name without final answer. The API users need to do
the polling to get the latest status of answer/session by calling
ConversationalSearchService.GetAnswer or ConversationalSearchService.
GetSession method.
Corresponds to the JSON property asynchronousMode
913 914 915 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 913 def asynchronous_mode @asynchronous_mode end |
#grounding_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestGroundingSpec
Grounding specification.
Corresponds to the JSON property groundingSpec
919 920 921 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 919 def grounding_spec @grounding_spec end |
#query ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1Query
Defines a user inputed query.
Corresponds to the JSON property query
924 925 926 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 924 def query @query end |
#query_understanding_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestQueryUnderstandingSpec
Query understanding specification.
Corresponds to the JSON property queryUnderstandingSpec
929 930 931 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 929 def query_understanding_spec @query_understanding_spec end |
#related_questions_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestRelatedQuestionsSpec
Related questions specification.
Corresponds to the JSON property relatedQuestionsSpec
934 935 936 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 934 def @related_questions_spec end |
#safety_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestSafetySpec
Safety specification.
Corresponds to the JSON property safetySpec
939 940 941 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 939 def safety_spec @safety_spec end |
#search_spec ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AnswerQueryRequestSearchSpec
Search specification.
Corresponds to the JSON property searchSpec
944 945 946 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 944 def search_spec @search_spec end |
#session ⇒ String
The session resource name. Not required. When session field is not set, the
API is in sessionless mode. We support auto session mode: users can use the
wildcard symbol -
as session ID. A new ID will be automatically generated
and assigned.
Corresponds to the JSON property session
952 953 954 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 952 def session @session end |
#user_labels ⇒ Hash<String,String>
The user labels applied to a resource must meet the following requirements: *
Each resource can have multiple labels, up to a maximum of 64. * Each label
must be a key-value pair. * Keys have a minimum length of 1 character and a
maximum length of 63 characters and cannot be empty. Values can be empty and
have a maximum length of 63 characters. * Keys and values can contain only
lowercase letters, numeric characters, underscores, and dashes. All characters
must use UTF-8 encoding, and international characters are allowed. * The key
portion of a label must be unique. However, you can use the same key with
multiple resources. * Keys must start with a lowercase letter or international
character. See Google Cloud Document for more details.
Corresponds to the JSON property userLabels
967 968 969 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 967 def user_labels @user_labels end |
#user_pseudo_id ⇒ String
A unique identifier for tracking visitors. For example, this could be
implemented with an HTTP cookie, which should be able to uniquely identify a
visitor on a single device. This unique identifier should not change if the
visitor logs in or out of the website. This field should NOT have a fixed
value such as unknown_visitor
. The field must be a UTF-8 encoded string with
a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT
error is
returned.
Corresponds to the JSON property userPseudoId
978 979 980 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 978 def user_pseudo_id @user_pseudo_id end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
985 986 987 988 989 990 991 992 993 994 995 996 997 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 985 def update!(**args) @answer_generation_spec = args[:answer_generation_spec] if args.key?(:answer_generation_spec) @asynchronous_mode = args[:asynchronous_mode] if args.key?(:asynchronous_mode) @grounding_spec = args[:grounding_spec] if args.key?(:grounding_spec) @query = args[:query] if args.key?(:query) @query_understanding_spec = args[:query_understanding_spec] if args.key?(:query_understanding_spec) @related_questions_spec = args[:related_questions_spec] if args.key?(:related_questions_spec) @safety_spec = args[:safety_spec] if args.key?(:safety_spec) @search_spec = args[:search_spec] if args.key?(:search_spec) @session = args[:session] if args.key?(:session) @user_labels = args[:user_labels] if args.key?(:user_labels) @user_pseudo_id = args[:user_pseudo_id] if args.key?(:user_pseudo_id) end |