Class: Google::Cloud::DiscoveryEngine::V1::Chunk
- Inherits:
-
Object
- Object
- Google::Cloud::DiscoveryEngine::V1::Chunk
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/discoveryengine/v1/chunk.rb
Overview
Chunk captures all raw metadata information of items to be recommended or searched in the chunk mode.
Defined Under Namespace
Classes: ChunkMetadata, DocumentMetadata, PageSpan
Instance Attribute Summary collapse
-
#chunk_metadata ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::ChunkMetadata
readonly
Output only.
-
#content ⇒ ::String
Content is a string from a document (parsed content).
-
#derived_struct_data ⇒ ::Google::Protobuf::Struct
readonly
Output only.
-
#document_metadata ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::DocumentMetadata
Metadata of the document from the current chunk.
-
#id ⇒ ::String
Unique chunk ID of the current chunk.
-
#name ⇒ ::String
The full resource name of the chunk.
-
#page_span ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::PageSpan
Page span of the chunk.
-
#relevance_score ⇒ ::Float
readonly
Output only.
Instance Attribute Details
#chunk_metadata ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::ChunkMetadata (readonly)
Returns Output only. Metadata of the current chunk.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#content ⇒ ::String
Returns Content is a string from a document (parsed content).
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#derived_struct_data ⇒ ::Google::Protobuf::Struct (readonly)
Returns Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#document_metadata ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::DocumentMetadata
Returns Metadata of the document from the current chunk.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#id ⇒ ::String
Returns Unique chunk ID of the current chunk.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#name ⇒ ::String
Returns The full resource name of the chunk.
Format:
projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}/documents/{document_id}/chunks/{chunk_id}
.
This field must be a UTF-8 encoded string with a length limit of 1024 characters.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#page_span ⇒ ::Google::Cloud::DiscoveryEngine::V1::Chunk::PageSpan
Returns Page span of the chunk.
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#relevance_score ⇒ ::Float (readonly)
Returns Output only. Represents the relevance score based on similarity. Higher score indicates higher chunk relevance. The score is in range [-1.0, 1.0]. Only populated on [SearchService.SearchResponse][].
59 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 |
# File 'proto_docs/google/cloud/discoveryengine/v1/chunk.rb', line 59 class Chunk 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. # @!attribute [rw] struct_data # @return [::Google::Protobuf::Struct] # Data representation. # The structured JSON data for the document. It should conform to the # registered {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} or an # `INVALID_ARGUMENT` error is thrown. class DocumentMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Page span of the chunk. # @!attribute [rw] page_start # @return [::Integer] # The start page of the chunk. # @!attribute [rw] page_end # @return [::Integer] # The end page of the chunk. class PageSpan include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end # Metadata of the current chunk. This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] previous_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The previous chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_previous_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. # @!attribute [rw] next_chunks # @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Chunk>] # The next chunks of the current chunk. The number is controlled by # {::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::ChunkSpec#num_next_chunks SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks}. # This field is only populated on # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Client#search SearchService.Search} # API. class ChunkMetadata include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |