Class: Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::ContentSearchSpec

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb

Overview

The specification that configs the desired behavior of the UCS content search.

Defined Under Namespace

Classes: ExtractiveContentSpec, SnippetSpec, SummarySpec

Instance Attribute Summary collapse

Instance Attribute Details

#extractive_content_spec::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::ContentSearchSpec::ExtractiveContentSpec



422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 422

class ContentSearchSpec
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # The specification that configs the snippet in the search results.
  # @!attribute [rw] max_snippet_count
  #   @return [::Integer]
  #     Max number of snippets returned in each search result.
  #
  #     A snippet is an infomartive summary of a content with highlighting for
  #     UI rendering.
  #
  #     If the matching snippets is less than the max_snippet_count, return all
  #     of the snippets; otherwise, return the max_snippet_count.
  #
  #     At most 5 snippets will be returned for each SearchResult.
  # @!attribute [rw] reference_only
  #   @return [::Boolean]
  #     if true, only snippet reference is returned.
  class SnippetSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the summary in the search response.
  # @!attribute [rw] summary_result_count
  #   @return [::Integer]
  #     The number of top results the summary should be generated from.
  #     If the number of returned results is less than summary_result_count,
  #     then the summary would be derived from all the results; otherwise, the
  #     summary would be derived from the top results.
  #
  #     At most 5 results can be used for generating summary.
  class SummarySpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the extractive content in search results.
  # @!attribute [rw] max_extractive_answer_count
  #   @return [::Integer]
  #     The max number of extractive answers returned in each search result.
  #
  #     An extractive answer is a verbatim answer extracted from the original
  #     document, which provides precise and contextually relevant answer to
  #     the search query.
  #
  #     If the number of matching answers is less than the
  #     extractive_answer_count, return all of the answers; otherwise, return
  #     the extractive_answer_count.
  #
  #     At most 5 answers will be returned for each SearchResult.
  # @!attribute [rw] max_extractive_segment_count
  #   @return [::Integer]
  #     The max number of extractive segments returned in each search result.
  #
  #     An extractive segment is a text segment extracted from the original
  #     document which is relevant to the search query and in general more
  #     verbose than an extrative answer. The segment could then be used as
  #     input for LLMs to generate summaries and answers.
  #
  #     If the number of matching segments is less than the
  #     max_extractive_segment_count, return all of the segments; otherwise,
  #     return the max_extractive_segment_count.
  #
  #     Currently one segment will be returned for each SearchResult.
  class ExtractiveContentSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#snippet_spec::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::ContentSearchSpec::SnippetSpec



422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 422

class ContentSearchSpec
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # The specification that configs the snippet in the search results.
  # @!attribute [rw] max_snippet_count
  #   @return [::Integer]
  #     Max number of snippets returned in each search result.
  #
  #     A snippet is an infomartive summary of a content with highlighting for
  #     UI rendering.
  #
  #     If the matching snippets is less than the max_snippet_count, return all
  #     of the snippets; otherwise, return the max_snippet_count.
  #
  #     At most 5 snippets will be returned for each SearchResult.
  # @!attribute [rw] reference_only
  #   @return [::Boolean]
  #     if true, only snippet reference is returned.
  class SnippetSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the summary in the search response.
  # @!attribute [rw] summary_result_count
  #   @return [::Integer]
  #     The number of top results the summary should be generated from.
  #     If the number of returned results is less than summary_result_count,
  #     then the summary would be derived from all the results; otherwise, the
  #     summary would be derived from the top results.
  #
  #     At most 5 results can be used for generating summary.
  class SummarySpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the extractive content in search results.
  # @!attribute [rw] max_extractive_answer_count
  #   @return [::Integer]
  #     The max number of extractive answers returned in each search result.
  #
  #     An extractive answer is a verbatim answer extracted from the original
  #     document, which provides precise and contextually relevant answer to
  #     the search query.
  #
  #     If the number of matching answers is less than the
  #     extractive_answer_count, return all of the answers; otherwise, return
  #     the extractive_answer_count.
  #
  #     At most 5 answers will be returned for each SearchResult.
  # @!attribute [rw] max_extractive_segment_count
  #   @return [::Integer]
  #     The max number of extractive segments returned in each search result.
  #
  #     An extractive segment is a text segment extracted from the original
  #     document which is relevant to the search query and in general more
  #     verbose than an extrative answer. The segment could then be used as
  #     input for LLMs to generate summaries and answers.
  #
  #     If the number of matching segments is less than the
  #     max_extractive_segment_count, return all of the segments; otherwise,
  #     return the max_extractive_segment_count.
  #
  #     Currently one segment will be returned for each SearchResult.
  class ExtractiveContentSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#summary_spec::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::ContentSearchSpec::SummarySpec



422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
# File 'proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb', line 422

class ContentSearchSpec
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # The specification that configs the snippet in the search results.
  # @!attribute [rw] max_snippet_count
  #   @return [::Integer]
  #     Max number of snippets returned in each search result.
  #
  #     A snippet is an infomartive summary of a content with highlighting for
  #     UI rendering.
  #
  #     If the matching snippets is less than the max_snippet_count, return all
  #     of the snippets; otherwise, return the max_snippet_count.
  #
  #     At most 5 snippets will be returned for each SearchResult.
  # @!attribute [rw] reference_only
  #   @return [::Boolean]
  #     if true, only snippet reference is returned.
  class SnippetSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the summary in the search response.
  # @!attribute [rw] summary_result_count
  #   @return [::Integer]
  #     The number of top results the summary should be generated from.
  #     If the number of returned results is less than summary_result_count,
  #     then the summary would be derived from all the results; otherwise, the
  #     summary would be derived from the top results.
  #
  #     At most 5 results can be used for generating summary.
  class SummarySpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The specification that configs the extractive content in search results.
  # @!attribute [rw] max_extractive_answer_count
  #   @return [::Integer]
  #     The max number of extractive answers returned in each search result.
  #
  #     An extractive answer is a verbatim answer extracted from the original
  #     document, which provides precise and contextually relevant answer to
  #     the search query.
  #
  #     If the number of matching answers is less than the
  #     extractive_answer_count, return all of the answers; otherwise, return
  #     the extractive_answer_count.
  #
  #     At most 5 answers will be returned for each SearchResult.
  # @!attribute [rw] max_extractive_segment_count
  #   @return [::Integer]
  #     The max number of extractive segments returned in each search result.
  #
  #     An extractive segment is a text segment extracted from the original
  #     document which is relevant to the search query and in general more
  #     verbose than an extrative answer. The segment could then be used as
  #     input for LLMs to generate summaries and answers.
  #
  #     If the number of matching segments is less than the
  #     max_extractive_segment_count, return all of the segments; otherwise,
  #     return the max_extractive_segment_count.
  #
  #     Currently one segment will be returned for each SearchResult.
  class ExtractiveContentSpec
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end