Gets the first item in the document. Either text or media url.
Gets the contentType of the data that is returned by data()
Media array getter.
the array of media parts.
Concatenates all text
parts present in the document with no delimiter.
A string of all concatenated text parts.
Embedders may return multiple embeddings for a single document. But storage still requires a 1:1 relationship. So we create an array of Documents from a single document - one per embedding.
The embeddings to create the documents from.
an array of documents based on this document and the embeddings.
Static
fromStatic
fromStatic
from
Document represents document content along with its metadata that can be embedded, indexed or retrieved. Each document can contain multiple parts (for example text and an image)