Reference documentation and code samples for the Google Cloud Discovery Engine V1 Client class Chunk.
Chunk captures all raw metadata information of items to be recommended or searched in the chunk mode.
Generated from protobuf message google.cloud.discoveryengine.v1.Chunk
Namespace
Google \ Cloud \ DiscoveryEngine \ V1Methods
__construct
Constructor.
data
array
Optional. Data for populating the Message object.
↳ 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.
↳ id
string
Unique chunk ID of the current chunk.
↳ content
string
Content is a string from a document (parsed content).
↳ 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 .
↳ document_metadata
↳ derived_struct_data
Google\Protobuf\Struct
Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document.
↳ page_span
↳ chunk_metadata
getName
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.
string
setName
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.
var
string
$this
getId
Unique chunk ID of the current chunk.
string
setId
Unique chunk ID of the current chunk.
var
string
$this
getContent
Content is a string from a document (parsed content).
string
setContent
Content is a string from a document (parsed content).
var
string
$this
getRelevanceScore
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 .
float
hasRelevanceScore
clearRelevanceScore
setRelevanceScore
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 .
var
float
$this
getDocumentMetadata
Metadata of the document from the current chunk.
hasDocumentMetadata
clearDocumentMetadata
setDocumentMetadata
Metadata of the document from the current chunk.
$this
getDerivedStructData
Output only. This field is OUTPUT_ONLY.
It contains derived data that are not in the original input document.
hasDerivedStructData
clearDerivedStructData
setDerivedStructData
Output only. This field is OUTPUT_ONLY.
It contains derived data that are not in the original input document.
$this
getPageSpan
Page span of the chunk.
hasPageSpan
clearPageSpan
setPageSpan
Page span of the chunk.
$this
getChunkMetadata
Output only. Metadata of the current chunk.
hasChunkMetadata
clearChunkMetadata
setChunkMetadata
Output only. Metadata of the current chunk.
$this