Class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1Chunk
- Inherits:
-
Object
- Object
- Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1Chunk
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/discoveryengine_v1/classes.rb,
lib/google/apis/discoveryengine_v1/representations.rb,
lib/google/apis/discoveryengine_v1/representations.rb
Overview
Chunk captures all raw metadata information of items to be recommended or searched in the chunk mode.
Instance Attribute Summary collapse
-
#chunk_metadata ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkChunkMetadata
Metadata of the current chunk.
-
#content ⇒ String
Content is a string from a document (parsed content).
-
#derived_struct_data ⇒ Hash<String,Object>
Output only.
-
#document_metadata ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkDocumentMetadata
Document metadata contains the information of the document of the current chunk.
-
#id ⇒ String
Unique chunk ID of the current chunk.
-
#name ⇒ String
The full resource name of the chunk.
-
#page_span ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkPageSpan
Page span of the chunk.
-
#relevance_score ⇒ Float
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1Chunk
constructor
A new instance of GoogleCloudDiscoveryengineV1Chunk.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1Chunk
Returns a new instance of GoogleCloudDiscoveryengineV1Chunk.
2235 2236 2237 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2235 def initialize(**args) update!(**args) end |
Instance Attribute Details
#chunk_metadata ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkChunkMetadata
Metadata of the current chunk. This field is only populated on SearchService.
Search API.
Corresponds to the JSON property chunkMetadata
2191 2192 2193 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2191 def @chunk_metadata end |
#content ⇒ String
Content is a string from a document (parsed content).
Corresponds to the JSON property content
2196 2197 2198 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2196 def content @content end |
#derived_struct_data ⇒ Hash<String,Object>
Output only. This field is OUTPUT_ONLY. It contains derived data that are not
in the original input document.
Corresponds to the JSON property derivedStructData
2202 2203 2204 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2202 def derived_struct_data @derived_struct_data end |
#document_metadata ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkDocumentMetadata
Document metadata contains the information of the document of the current
chunk.
Corresponds to the JSON property documentMetadata
2208 2209 2210 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2208 def @document_metadata end |
#id ⇒ String
Unique chunk ID of the current chunk.
Corresponds to the JSON property id
2213 2214 2215 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2213 def id @id end |
#name ⇒ String
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.
Corresponds to the JSON propertyname`
2221 2222 2223 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2221 def name @name end |
#page_span ⇒ Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1ChunkPageSpan
Page span of the chunk.
Corresponds to the JSON property pageSpan
2226 2227 2228 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2226 def page_span @page_span end |
#relevance_score ⇒ Float
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.
Corresponds to the JSON property relevanceScore
2233 2234 2235 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2233 def relevance_score @relevance_score end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 |
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 2240 def update!(**args) @chunk_metadata = args[:chunk_metadata] if args.key?(:chunk_metadata) @content = args[:content] if args.key?(:content) @derived_struct_data = args[:derived_struct_data] if args.key?(:derived_struct_data) @document_metadata = args[:document_metadata] if args.key?(:document_metadata) @id = args[:id] if args.key?(:id) @name = args[:name] if args.key?(:name) @page_span = args[:page_span] if args.key?(:page_span) @relevance_score = args[:relevance_score] if args.key?(:relevance_score) end |