Class: Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList

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

Overview

Search result list.

Defined Under Namespace

Classes: SearchResult

Instance Attribute Summary collapse

Instance Attribute Details

#search_results::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult>

Returns Search results.



565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
# File 'proto_docs/google/cloud/discoveryengine/v1/conversational_search_service.rb', line 565

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

  # Search result.
  # @!attribute [rw] unstructured_document_info
  #   @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo]
  #     Unstructured document information.
  #
  #     Note: The following fields are mutually exclusive: `unstructured_document_info`, `chunk_info`. If a field in that set is populated, all other fields in the set will automatically be cleared.
  # @!attribute [rw] chunk_info
  #   @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::ChunkInfo]
  #     Chunk information.
  #
  #     Note: The following fields are mutually exclusive: `chunk_info`, `unstructured_document_info`. If a field in that set is populated, all other fields in the set will automatically be cleared.
  class SearchResult
    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] document_contexts
    #   @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::DocumentContext>]
    #     List of document contexts. The content will be used for Answer
    #     Generation. This is supposed to be the main content of the document
    #     that can be long and comprehensive.
    # @!attribute [rw] extractive_segments
    #   @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::ExtractiveSegment>]
    #     List of extractive segments.
    # @!attribute [rw] extractive_answers
    #   @deprecated This field is deprecated and may be removed in the next major version update.
    #   @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::ExtractiveAnswer>]
    #     Deprecated: This field is deprecated and will have no effect on
    #     the Answer generation.
    #     Please use document_contexts and extractive_segments fields.
    #     List of extractive answers.
    class UnstructuredDocumentInfo
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods

      # Document context.
      # @!attribute [rw] page_identifier
      #   @return [::String]
      #     Page identifier.
      # @!attribute [rw] content
      #   @return [::String]
      #     Document content to be used for answer generation.
      class DocumentContext
        include ::Google::Protobuf::MessageExts
        extend ::Google::Protobuf::MessageExts::ClassMethods
      end

      # Extractive segment.
      # [Guide](https://cloud.google.com/generative-ai-app-builder/docs/snippets#extractive-segments)
      # Answer generation will only use it if document_contexts is empty.
      # This is supposed to be shorter snippets.
      # @!attribute [rw] page_identifier
      #   @return [::String]
      #     Page identifier.
      # @!attribute [rw] content
      #   @return [::String]
      #     Extractive segment content.
      class ExtractiveSegment
        include ::Google::Protobuf::MessageExts
        extend ::Google::Protobuf::MessageExts::ClassMethods
      end

      # Extractive answer.
      # [Guide](https://cloud.google.com/generative-ai-app-builder/docs/snippets#get-answers)
      # @!attribute [rw] page_identifier
      #   @return [::String]
      #     Page identifier.
      # @!attribute [rw] content
      #   @return [::String]
      #     Extractive answer content.
      class ExtractiveAnswer
        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] document_metadata
    #   @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::ChunkInfo::DocumentMetadata]
    #     Metadata of the document from the current chunk.
    class ChunkInfo
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods

      # Document metadata contains the information of the document of the
      # current chunk.
      # @!attribute [rw] uri
      #   @return [::String]
      #     Uri of the document.
      # @!attribute [rw] title
      #   @return [::String]
      #     Title of the document.
      class DocumentMetadata
        include ::Google::Protobuf::MessageExts
        extend ::Google::Protobuf::MessageExts::ClassMethods
      end
    end
  end
end