Class Chunk (0.13.4)

Chunk(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Chunk captures all raw metadata information of items to be recommended or searched in the chunk mode.

.. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields

Attributes

Name Description
name str
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 str
Unique chunk ID of the current chunk.
content str
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][]. This field is a member of oneof_ _relevance_score.
document_metadata google.cloud.discoveryengine_v1alpha.types.Chunk.DocumentMetadata
Metadata of the document from the current chunk.
derived_struct_data google.protobuf.struct_pb2.Struct
Output only. This field is OUTPUT_ONLY. It contains derived data that are not in the original input document.
page_span google.cloud.discoveryengine_v1alpha.types.Chunk.PageSpan
Page span of the chunk.
chunk_metadata google.cloud.discoveryengine_v1alpha.types.Chunk.ChunkMetadata
Output only. Metadata of the current chunk.

Classes

ChunkMetadata

ChunkMetadata(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Metadata of the current chunk. This field is only populated on SearchService.Search API.

DocumentMetadata

DocumentMetadata(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Document metadata contains the information of the document of the current chunk.

PageSpan

PageSpan(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Page span of the chunk.