Class: Google::Cloud::DiscoveryEngine::V1::Answer
- Inherits:
-
Object
- Object
- Google::Cloud::DiscoveryEngine::V1::Answer
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/discoveryengine/v1/answer.rb
Overview
Defines an answer.
Defined Under Namespace
Modules: AnswerSkippedReason, State Classes: Citation, CitationSource, QueryUnderstandingInfo, Reference, Step
Instance Attribute Summary collapse
-
#answer_skipped_reasons ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::AnswerSkippedReason>
Additional answer-skipped reasons.
-
#answer_text ⇒ ::String
The textual answer.
-
#citations ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Citation>
Citations.
-
#complete_time ⇒ ::Google::Protobuf::Timestamp
readonly
Output only.
-
#create_time ⇒ ::Google::Protobuf::Timestamp
readonly
Output only.
-
#name ⇒ ::String
Immutable.
-
#query_understanding_info ⇒ ::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo
Query understanding information.
-
#references ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference>
References.
-
#related_questions ⇒ ::Array<::String>
Suggested related questions.
-
#state ⇒ ::Google::Cloud::DiscoveryEngine::V1::Answer::State
The state of the answer generation.
-
#steps ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step>
Answer generation steps.
Instance Attribute Details
#answer_skipped_reasons ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::AnswerSkippedReason>
Returns Additional answer-skipped reasons. This provides the reason for ignored cases. If nothing is skipped, this field is not set.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#answer_text ⇒ ::String
Returns The textual answer.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#citations ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Citation>
Returns Citations.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#complete_time ⇒ ::Google::Protobuf::Timestamp (readonly)
Returns Output only. Answer completed timestamp.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#create_time ⇒ ::Google::Protobuf::Timestamp (readonly)
Returns Output only. Answer creation timestamp.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#name ⇒ ::String
Returns Immutable. Fully qualified name
projects/{project}/locations/global/collections/{collection}/engines/{engine}/sessions/*/answers/*
.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#query_understanding_info ⇒ ::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo
Returns Query understanding information.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#references ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference>
Returns References.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#related_questions ⇒ ::Array<::String>
Returns Suggested related questions.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#state ⇒ ::Google::Cloud::DiscoveryEngine::V1::Answer::State
Returns The state of the answer generation.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |
#steps ⇒ ::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step>
Returns Answer generation steps.
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 |
# File 'proto_docs/google/cloud/discoveryengine/v1/answer.rb', line 60 class Answer include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Citation info for a segment. # @!attribute [rw] start_index # @return [::Integer] # Index indicates the start of the segment, measured in bytes (UTF-8 # unicode). # @!attribute [rw] end_index # @return [::Integer] # End of the attributed segment, exclusive. # @!attribute [rw] sources # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>] # Citation sources for the attributed segment. class Citation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Citation source. # @!attribute [rw] reference_id # @return [::String] # ID of the citation source. class CitationSource include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Reference. # @!attribute [rw] unstructured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo] # Unstructured document information. # @!attribute [rw] chunk_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo] # Chunk information. # @!attribute [rw] structured_document_info # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo] # Structured document information. class Reference include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Unstructured document information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] chunk_contents # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo::ChunkContent>] # List of cited chunk contents derived from document content. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class UnstructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Chunk content. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkContent include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from 0.0 # (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. # @!attribute [rw] document_metadata # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata] # Document metadata. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Document metadata. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] page_identifier # @return [::String] # Page identifier. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # The structured JSON metadata for the document. # It is populated from the struct data from the Chunk in search result. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Structured search information. # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Structured search data. class StructuredDocumentInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end # Step information. # @!attribute [rw] state # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::State] # The state of the step. # @!attribute [rw] description # @return [::String] # The description of the step. # @!attribute [rw] thought # @return [::String] # The thought of the step. # @!attribute [rw] actions # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action>] # Actions. class Step include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Action. # @!attribute [rw] search_action # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::SearchAction] # Search action. # @!attribute [rw] observation # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation] # Observation. class Action include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Search action. # @!attribute [rw] query # @return [::String] # The query to search. class SearchAction include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Observation. # @!attribute [rw] search_results # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult>] # Search results observed by the search action, it can be snippets info # or chunk info, depending on the citation type set by the user. class Observation include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # @!attribute [rw] document # @return [::String] # Document resource name. # @!attribute [rw] uri # @return [::String] # URI for the document. # @!attribute [rw] title # @return [::String] # Title. # @!attribute [rw] snippet_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::SnippetInfo>] # If citation_type is DOCUMENT_LEVEL_CITATION, populate document # level snippets. # @!attribute [rw] chunk_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Step::Action::Observation::SearchResult::ChunkInfo>] # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, # populate chunk info. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. # It's populated from the struct data from the Document, or the # Chunk in search result. class SearchResult include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Snippet information. # @!attribute [rw] snippet # @return [::String] # Snippet content. # @!attribute [rw] snippet_status # @return [::String] # Status of the snippet defined by the search team. class SnippetInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Chunk information. # @!attribute [rw] chunk # @return [::String] # Chunk resource name. # @!attribute [rw] content # @return [::String] # Chunk textual content. # @!attribute [rw] relevance_score # @return [::Float] # The relevance of the chunk for a given query. Values range from # 0.0 (completely irrelevant) to 1.0 (completely relevant). # This value is for informational purpose only. It may change for # the same query and chunk at any time due to a model retraining or # change in implementation. class ChunkInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end end end # Enumeration of the state of the step. module State # Unknown. STATE_UNSPECIFIED = 0 # Step is currently in progress. IN_PROGRESS = 1 # Step currently failed. FAILED = 2 # Step has succeeded. SUCCEEDED = 3 end end # Query understanding information. # @!attribute [rw] query_classification_info # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo>] # Query classification information. class QueryUnderstandingInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification information. # @!attribute [rw] type # @return [::Google::Cloud::DiscoveryEngine::V1::Answer::QueryUnderstandingInfo::QueryClassificationInfo::Type] # Query classification type. # @!attribute [rw] positive # @return [::Boolean] # Classification output. class QueryClassificationInfo include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Query classification types. module Type # Unspecified query classification type. TYPE_UNSPECIFIED = 0 # Adversarial query classification type. ADVERSARIAL_QUERY = 1 # Non-answer-seeking query classification type, for chit chat. NON_ANSWER_SEEKING_QUERY = 2 # Jail-breaking query classification type. JAIL_BREAKING_QUERY = 3 # Non-answer-seeking query classification type, for no clear intent. NON_ANSWER_SEEKING_QUERY_V2 = 4 end end end # Enumeration of the state of the answer generation. module State # Unknown. STATE_UNSPECIFIED = 0 # Answer generation is currently in progress. IN_PROGRESS = 1 # Answer generation currently failed. FAILED = 2 # Answer generation has succeeded. SUCCEEDED = 3 end # An enum for answer skipped reasons. module AnswerSkippedReason # Default value. The answer skipped reason is not specified. ANSWER_SKIPPED_REASON_UNSPECIFIED = 0 # The adversarial query ignored case. ADVERSARIAL_QUERY_IGNORED = 1 # The non-answer seeking query ignored case # # Google skips the answer if the query is chit chat. NON_ANSWER_SEEKING_QUERY_IGNORED = 2 # The out-of-domain query ignored case. # # Google skips the answer if there are no high-relevance search results. OUT_OF_DOMAIN_QUERY_IGNORED = 3 # The potential policy violation case. # # Google skips the answer if there is a potential policy violation # detected. This includes content that may be violent or toxic. POTENTIAL_POLICY_VIOLATION = 4 # The no relevant content case. # # Google skips the answer if there is no relevant content in the # retrieved search results. NO_RELEVANT_CONTENT = 5 # The jail-breaking query ignored case. # # For example, "Reply in the tone of a competing company's CEO". # Google skips the answer if the query is classified as a jail-breaking # query. JAIL_BREAKING_QUERY_IGNORED = 6 # The customer policy violation case. # # Google skips the summary if there is a customer policy violation # detected. The policy is defined by the customer. CUSTOMER_POLICY_VIOLATION = 7 # The non-answer seeking query ignored case. # # Google skips the answer if the query doesn't have clear intent. NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8 # The low-grounded answer case. # # Google skips the answer if a well grounded answer was unable to be # generated. LOW_GROUNDED_ANSWER = 9 end end |